[XviD-devel] inter48x48

Christoph Lampert xvid-devel@xvid.org
Fri, 26 Jul 2002 10:00:33 +0200 (CEST)


> yes, its dependant on motion estimation. the frame_drop_ratio simply checks 
> the number of skipped-macroblocks. when given two identical frames, xvid 
> "should" drop the second frame.

If internally two frames are 100% identical, all implemented ME routines
should return a motion vector field of constant (0,0) and _all_ blocks
should be SKIPed. So it would be no problem to base the skip decision on ME.

The problem in your case is, that the _internal copy_ of a frame is
_not_ 100% identical to the new frame that is to be encoded, because it's
motion compensated, iDCTed etc. 

So you can't simply check if the new frame is identical to the internal
one. You would have to save a backup copy of the last source frame (which
is stupid overhead). 
Of course, you could do image based MAD between internal and new frame,
but where do you put the threshhold? It can't be too low, because it
should cover differences between internal and new pic, but if you put it 
higher, frame which hardly differ except for a small region (japanimation
where only moving mouths...) will completely be skiped.

Please note that it is _wanted_ that you can feed the same frame in the
codec twice and _not_ have the second one skipped. Think e.g. of high
quantizers, then after processing the first frame, there will be large
errors. The second frame (in theory identical frame) will be much closer 
to the internal, so after processing the second step, the internal image
will match the "real" image much closer, which is good for future ME. 

> if you want a frame dropping solution that operates independant of m.e., 
> then we have to perform a simularity check between the current and reference 
> frames within xvid. what algorithm does your filter use to identifiy simular 
> frames?

If you have a filter anyway that "creates" the identical frames, wouldn't
it be easier to simply skip them in the application instead of feeding
them to the codec? Or if that is not wanted because of ratecontrol, 
at least give a flag to the codec, _forcing_ the codec to skip a frame.


-- 
Christoph H. Lampert chl@math.uni-bonn.de | Diese Signature wurde maschi-     
Beringstr. 6, Raum 14 Tel. (0228) 73-2948 | nell erstellt und bedarf
Sprechstunden: keine, aber meistens da    | keiner Unterschrift. AZ 27B-6