[FFmpeg-devel] dia, dia_size and the rest
Michael Niedermayer
michaelni
Fri Jan 23 17:56:19 CET 2009
On Fri, Jan 23, 2009 at 03:47:44PM +0000, vmrsss wrote:
> Hello.
>
> I have tried to use me_method hex with mpeg2video and got:
>
> > [mpeg2video @ 0x101005800]me_method is only allowed to be set to
> > zero and epzs; for hex,umh,full and others see dia_size
>
> I suppose there are precise rules on which video codecs support which
> motion estimation algorithms. What are they?
the rule is above, what part of it is unclear?
Do you have some suggestion how to make it clearer?
The rule is not dependant on the used codec.
>
> I have looked for documentation or exchanges on this list about epzs/
> dia, there is almost none (except one from 2004). In
> motion_estimation_template.c I found this relevant branching.
>
> > if(c->dia_size==-1) ==> funny_diamond_search
> > else if(c->dia_size<-1) ==> sab_diamond_search
> > else if(c->dia_size<2) ==> small_diamond_search
> > else if(c->dia_size>1024) ==> full_search
> > else if(c->dia_size>768) ==> umh_search
> > else if(c->dia_size>512) ==> hex_search
> > else if(c->dia_size>256) ==> l2s_dia_search
> > else ==> var_diamond_search
>
> Can anybody explain schematically the differences between the
> "funny_", "sab_", "ls2_" and "var_" algorithms are and how the values
> of dia_size affect them?
IIRC the mplayer docs might contain some more info ...
>
> A few more questions: with abs( dia_size ) > 4 I get
>
> > [mpeg2video @ 0x101005800]ME_MAP size may be a little small for the
> > selected diamond size
>
> Is this something to worry about? ME_MAP is the constant 64 (so this
> is not easily dealt with from the command line). In fact,
>
> with -dia_size -65
>
> > mpeg2video @ 0x101005800]ME_MAP size is too small for SAB diamond
> > Video encoding failed
>
> Also, with -dia_size 7 and -cmp satd (as well as with other
> combinations) I get:
>
> > [mpeg2video @ 0x101005800]ME_MAP size may be a little small for the
> > selected diamond size
> > Assertion failed: (map[(index-(1<<ME_MAP_SHIFT))&(ME_MAP_SIZE-1)] ==
> > key), function hpel_motion_search, file libavcodec/
> > motion_est_template.c, line 168.
> > Abort trap
>
>
> Is this something to worry about? Below is my full ouput.
nothing to worry here, you just used parameters that are not compatible
with the ME_MAP value, lavc warned you and encoding failed
Ideally lavc should of course fail cleanly, not by assert() of course
[...]
--
Michael GnuPG fingerprint: 9FF2128B147EF6730BADF133611EC787040B0FAB
Asymptotically faster algorithms should always be preferred if you have
asymptotical amounts of data
-------------- 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-devel/attachments/20090123/8685a337/attachment.pgp>
More information about the ffmpeg-devel
mailing list