[FFmpeg-soc] [soc]: r1489 - rv40/rv34.c

Michael Niedermayer michaelni at gmx.at
Sat Dec 1 18:05:43 CET 2007


On Sat, Dec 01, 2007 at 05:23:38PM +0200, Kostya wrote:
> On Sat, Dec 01, 2007 at 03:01:53PM +0100, Michael Niedermayer wrote:
> > On Sat, Dec 01, 2007 at 02:47:01PM +0100, Michael Niedermayer wrote:
> > > On Sat, Dec 01, 2007 at 03:53:15PM +0200, Kostya wrote:
> > > > On Sat, Dec 01, 2007 at 01:57:29PM +0100, kostya wrote:
> > > > > Author: kostya
> > > > > Date: Sat Dec  1 13:57:28 2007
> > > > > New Revision: 1489
> > > > > 
> > > > > Log:
> > > > > More generic MC function
> > > > > 
> > > > > Modified:
> > > > >    rv40/rv34.c
> > > > 
> > > > As a side effect I think it will be easier to add RV30
> > > > motion compensation (it uses thirdpel MC)
> > > 
> > > for a h.264 draft with 1/3 1/2 and 1/6 pel MC see:
> > > 
> > > http://ftp3.itu.int/av-arch/video-site/0005_Osa/q15j08d0.doc
> > > 
> > > (note just a random pick iam sure many of the early drafts contained 1/3 pel)
> > 
> > and here is one with just 1/3 pel MC
> > http://ftp3.itu.int/av-arch/video-site/9908_Ber/q15h36d2.doc
> 
> maybe upcoming RV5 will use 1/5pel MC

only if some h.26* draft uses that :)


> 
> as for RV30 I know it uses filter [-1 12 6 -1] for luma and [5 3] for chroma

from the draft above:
1 Fractional pixel accuracy


In the present coding method, 1/3 pixel accuracy is used to define motion
vectors.  In the figure below, capital letters indicate pixel positions
whereas lower case letters represent interpolated 1/3 pixel positions.

  A     B     C     D


  E     F a b G     H
        c d e
        f g h
  I     J     K     L


  M     N     O     P

For interpolation of a,b,c,d,e,f,g filters with one dimensional impulse
response (1,  (-1 12 6 -1)/16 and (-1 6 12 -1)/16) are used in horizontal
and vertical directions as appropriate.  To interpolate h a 'stronger'
filter with impulse response (0 6 9 1)/16 is used.  The exact expressions
for interpolation areis written below.  All integer positions are used
without any change.
...
3 Chroma vectors


Chroma vectors are derived from the luma vectors.  Since chroma has half
resolution compared to luma, the chroma vectors are obtained by a division
of two:

Croma_vector = Luma_vector/2 (with truncation. Both vectors in 1/3 pixel
units)

Due to the half resolution, a croma vector applies to 1/4 as many pixels as
the luma vector.  For example if the luma vector applies to 8x16 luma
pixels, the corresponding chroma vector applies to 4x8 chroma pixels and if
the luma vector applies to 4x4 luma pixels, the corresponding chroma vector
applies to 2x2 chroma pixel.

For fractional pixel interpolation for chroma prediction, the two tap
filters (5 3)/8 and (3 5)/8 are used as appropriate for all fractional
pixel positions (a - h) above.


[...]
-- 
Michael     GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB

The worst form of inequality is to try to make unequal things equal.
-- Aristotle
-------------- next part --------------
A non-text attachment was scrubbed...
Name: not available
Type: application/pgp-signature
Size: 189 bytes
Desc: Digital signature
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-soc/attachments/20071201/8b83026a/attachment.pgp>


More information about the FFmpeg-soc mailing list