fix GIF speed: remove capture-side fps filter, let encoder handle conversion
The capture pipeline was applying fps=N to drop frames from monitor refresh rate to user fps. Then the GIF encoder applied fps=M on the already-converted file. Double fps conversion = broken frame timestamps = wrong playback speed. Fix: remove fps filter from capture. Intermediate files keep monitor's native refresh rate (e.g. 120fps). The GIF/video encoder's fps filter handles the conversion correctly in one clean step. Also removed redundant -r flag from GIF encoder (already done), and restored the 16:9 preset and low FPS options that were removed earlier.
This commit is contained in:
@@ -465,7 +465,7 @@ fn encode_gif_pass(
|
||||
};
|
||||
|
||||
// Single-pass approach: split the stream, generate palette from one copy,
|
||||
// apply palette to the other. Uses -r for output framerate.
|
||||
// apply palette to the other. The fps filter handles frame rate conversion.
|
||||
let filter_complex = format!(
|
||||
"{cprefix}{kprefix}fps={fps},{sprefix}scale={w}:-1:flags=lanczos,split[s0][s1];[s0]palettegen=stats_mode=diff:max_colors={colors}[p];[s1][p]paletteuse=dither={d}",
|
||||
cprefix = crop_prefix,
|
||||
|
||||
Reference in New Issue
Block a user