[FFmpeg-devel] [RFC] Fixing libx264.c
Fri May 22 11:55:59 CEST 2009
On Fri, 22 May 2009, Michael Niedermayer wrote:
> On Thu, May 21, 2009 at 06:57:41PM -0700, Jason Garrett-Glaser wrote:
>> 3. ffmpeg sets directpred to "temporal".
>> Why it's broken currently: directpred temporal breaks horrifically
>> when b-pyramid is applied, so it's easy to mix the two improperly
>> (spatial is a better default anyways, and is the one x264 uses).
>> Solution: set the default to spatial in options.c (which it should be).
> its a little annying semantically as mpeg4 asp has no spatial and thus
> strictly mpeg4 should fail with the default.
> maybe none or auto would be better defaults.
> though i have no real objection to change it to spatial if you want, its
> just a little dirty for codecs that dont support spatial
Is that an official ffmpeg policy: codecs should refuse to encode if you
enable any option they don't support? Every time anyone adds a new option
for one codec, they have to modify all the other codecs to check it too?
Should intra-only codecs refuse to encode with the default gop_size of 12?
Should codecs that don't have quantizers refuse to encode if qmin/qmax
are set to anything at all?
Surely the only sane thing to do is to ignore all options that are
irrelevant to the format being encoded. mpeg4 doesn't have any choice of
direct modes, so the direct mode option shouldn't matter.
With the common mpegvideo codepath we do have to check that options used
by some mpeglike codecs but not the one in use aren't enabled. But once
we're checking that, is it better to error out or to disable the option?
More information about the ffmpeg-devel