1

This question is based on the software Handbrake.

Being a newbie to video editing/conversion and Handbrake, I understand that the RF values are used to select quality.

Lower the RF value, higher is the quality.

RF = 51 means fast encoding while very low quality. RF = 0 means very very slow but lossless.

So from this logic it would mean that if I want to encode a 360p video for YouTube I would have to select higher RF value because it is lower quality and conversely, it I want a 1080p video then I must go for a lower RF value.

But Handbrake itself recommends RF=23 for HD and RF=18 for SD. How is this possible? I'm confused.

1

Resolution != quality, at least, not in the sense referred to by RF. What the RF primarily modulates is the quantization parameter (QP).


Let's say you have a 2x2 array of pixels and each pixel is represented by one floating-point value e.g. 3.98, 2.10, 1.05, 7.88. If your goal is to compress the video, then storing these values with full precision and fidelity will be more expensive than if you could store 4,2,1,8. Given the limitations of human vision, it turns out this is an acceptable compromise in the service of video compression. The greater the quantization parameter, the greater the 'smoothing out' of values. Such smoothing out reduces spatial detail i.e. sharpness and subtle color variation in the picture. Of course, this is just one strategy among the many used.

(The above is just a thematic illustration and not an example of the result of an actual quantization)


Before RF, video encoders would apply a single QP across the entire video, so a scene with a lot of diversity of visual forms would have the same smoothing applied as a simple scene. If the degree of smoothing is low, the bitrate will shoot up in complex scenes. If it's high, it will degrade simpler scenes more than desired. What RF does is analyze the video content and modulate QP so that visual details appreciated by the human eye are not highly quantized but neglected details are. The RF value determines how much latitude the encoder has to vary the QP.

Now, to your question. A group of pixels, say a 16x16 block, forms a larger part of an SD image than of a HD image, so it will play a larger role in the subjective visual perception of the image (and have greater variation within), so you ought to smooth it out less.

  • Oh I seeee... After wrapping my head around what you just told here's what I understood :: RF value is (very roughly) inversely proportional to "amount of useful information held in every pixel". HD videos have more pixels to begin with so each pixel can hold lesser information. But since SD videos have fewer pixels, then each pixel must be more detailed. Hope I got that right! – Macindows Jan 13 '17 at 9:07

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.