@@ -96,9 +96,7 @@ func buildUpscalingParams(anime Anime, resolution Resolution, shader Shader, out
96
96
"-y" , // Override output file
97
97
}
98
98
99
- if ! settings .CompatibilityMode {
100
- params = append (params , hwaccelParams ... ) // Apply selected video encoder and hardware acceleration parameters
101
- }
99
+ params = append (params , hwaccelParams ... ) // Apply selected video encoder and hardware acceleration parameters
102
100
103
101
params = append (params ,
104
102
"-i" , fmt .Sprintf ("%s" , anime .Path ), // Path to input file
@@ -118,18 +116,17 @@ func buildUpscalingParams(anime Anime, resolution Resolution, shader Shader, out
118
116
}
119
117
120
118
params = append (params ,
121
- "-crf" , fmt .Sprintf ("%d" , settings .Crf ), // Constant Rate Factor (CRF) for encoder)
119
+ "-crf" , fmt .Sprintf ("%d" , settings .Crf ), // Apply Constant Rate Factor (CRF) for encoder
122
120
)
123
121
124
- if ! settings .CompatibilityMode {
125
- params = append (params , "-c:v" , videoCodec ) // Apply selected video codec
122
+ params = append (params , "-c:v" , videoCodec ) // Apply selected video codec
126
123
127
- // Preset for encoder, supported only by H264/H265
128
- if videoCodec != "libsvtav1" {
129
- params = append (params , "-preset" , "slow" )
130
- }
124
+ // Preset for encoder, supported only by H264/H265
125
+ if videoCodec != "libsvtav1" {
126
+ params = append (params , "-preset" , "slow" )
131
127
}
132
128
129
+ // Threads limit for CPU based encoders
133
130
if videoCodec == "libx264" && settings .CpuThreads != int32 (runtime .NumCPU ()) {
134
131
params = append (params , "-threads" , fmt .Sprintf ("%d" , settings .CpuThreads ))
135
132
}
0 commit comments