[Ffmpeg-devel] DVD compliance, limited vertical range of motion vectors

Sven Over svenover
Wed Jul 27 15:55:55 CEST 2005


Am Mittwoch, 27. Juli 2005 15:20 schrieb Michael Niedermayer:

> well me_range is in subpel units (1/2 for mpeg1/2) the numbers in the
> standard are in fullpell units, and we dont support field pictures so 256
> seems to be the correct limit if not iam sure someone will complain and we
> now know what to try first if someones poineer dvd player dislikes ffmpeg
> ...

So I tried -me_range 256 already, and it worked fine, but I was not sure if it 
was by accident. But I think, if 256 was not correct, it would be off at 
least by a factor of 2 (numbers inbetween don't make sense)... but if so, the 
Pioneer player should have choked on 256. So at the moment, I have the strong 
feeling that 256 is the right number.

Ah... we could be off by one (the standard says -128 to 127.5), so we may need 
255 as an upper limit. (In this case, I could accept that the Pioneer player 
did not complain... when limitting the range to 256 the chance is high, that 
there are no vectors >255, just by coincidence.)

> yes, patch welcome, but 256 is already quite large so i wouldnt expect much
> improvement from a higher limit for the horizontal component

Sounds reasonable. As I said, I don't see a big difference in quality, even 
between unlimited motion vectors and "-me_range 63".

Maybe I'll write a patch to introduce "-vert_me_range" at the weekend... well, 
maybe...

> well the limitation is not a dvd limit but a mpeg2 one so its on by default
> now and can be disabled with -strict -1 (all just theory nothingt tested as
> no dvd writer or dvd player here ...)

Well, yes, you are right, now that I think about it. Since the mpeg2 codec of 
ffmpeg states in one of the headers (picture extension or something similar), 
that the stream is MP at ML (a value of 72 in the profile_and_level field), it 
should of course conform to MP at ML, which means that motion vectors (at least 
the vertical component) have to be within the range given by the standard. So 
it should be on by default. If someone wants to gain a little bit of quality 
at the cost of incompliance (although 99% of the DVD players will probably 
still be happy with it), one can use the "-strict" option.

-- 
Sven Over
Stephanienstr. 9
76133 Karlsruhe
GERMANY

Telefon: 0721-9204199

http://www.svenover.de/





More information about the ffmpeg-devel mailing list