scripts:ffmpeg:fix_color_space_convering_from_jpeg

Fix color space issues when converting from jpeg

If you're taking a sequence of jpg images into video, you can have color issues.

Just add

ffmpeg ... -c:v libx264 -crf 20 -pix_fmt yuv420p -colorspace bt709 -color_trc bt709 -color_primaries bt709 -color_range tv

Example:

ffmpeg -framerate 119.88 -i interpolated-4x/%08d.jpg -i audio.mka -map 0:v -map 1:a -c:v libx264 -crf 20 -pix_fmt yuv420p -colorspace bt709 -color_trc bt709 -color_primaries bt709 -color_range tv -c:a copy -vf "scale=3840x2160:flags=lanczos+full_chroma_inp+full_chroma_int,unsharp=luma_msize_x=3:luma_msize_y=3:luma_amount=1.05" why_did_i_do_this_120fps_4k.mkv
  • scripts/ffmpeg/fix_color_space_convering_from_jpeg.txt
  • Last modified: 2023-12-20 08:13
  • by Tony