[FFmpeg-devel] [PATCH] RoQ video encoder (take 4)

Loren Merritt lorenm
Fri Jun 15 04:56:50 CEST 2007


On Thu, 14 Jun 2007, Eric Lasota wrote:
> Loren Merritt wrote:
>
>> Lambda (or equivalently, quantizer) is the only thing that a ratecontrol
>> algorithm can decide. Distortion isn't known until after you encode the
>> frame.
>
> The old progressive reducer (which got dropped in favor of lambda-based
> rate control) could simultaneously target output size, distortion, or
> lambda.  When I modified it to target distortion, it hit within 1% of
> its target every time the target was achievable.

Ok, I was speaking of ffmpeg's generic ratecontrol. A RoQ-specific 
algorithm can control other variables.
Then the reason for using lambda as opposed to an a-priori bitrate or 
distortion target is that lambda is optimal in the sense of minimizing 
total distortion over several frames for any given total size of those 
frames. That's only mathematical distortion, it doesn't prove that the 
resulting video looks better than a constant distortion encode... but then 
the constant distortion encode is also only using mathematical distortion. 
And my experiments (which do not include RoQ) indicate that constant 
lambda doesn't vary the quality _enough_. That's why qcomp<1 in the 
generic ratecontrol.

--Loren Merritt




More information about the ffmpeg-devel mailing list