4

I have a raw video. I need it to compress it losslessly. There are two ways to do this. Setting the parameters crf or qp to 0. crf achieves constant bitrate while qp has constant quantization. I've two questions:

  1. Do the options -crf 0 and -qp 0 achieve the same result (lossless compression)?
  2. If not, what is the difference? Which is recommended to have lossless compression?

This question asks about crf and qp, but doesn't talk about lossless compression.

Nagabhushan S N
  • 6,407
  • 8
  • 44
  • 87

1 Answers1

1

x264 binary itself mandates that only qp 0 is true lossless, because for 8 bit x264 it is the same as in ffmpeg from 0 to 51, for 10 bit CRF of minus 12 is lossless or qp 0. But ffmpeg has changed level of crf for 10 bit from -12, 51 to 0, 63. They also seem to forget that for 10 bit high 10, high422 profiles do not support lossless, only high444 does. So for 10 bit in ffmpeg only qp 0 is true lossless, crf 0 can fail if (and it is possible, see https://trac.ffmpeg.org/ticket/9573#comment:11) ffmpeg will go to high 10.