[FFmpeg-devel] [PATCH] ffh264: stop trying to decode colorspaces it doesn't support

Jason Garrett-Glaser jason
Tue Jan 11 03:02:16 CET 2011

On Mon, Jan 10, 2011 at 5:52 PM, Michael Niedermayer <michaelni at gmx.at> wrote:
> On Mon, Jan 10, 2011 at 03:30:18PM -0800, Jason Garrett-Glaser wrote:
>> This works with one problem: I can't get ffh264 to stop trying to
>> decode. ?It will simply keep spamming and spamming if it encounters an
>> unsupported file, instead of printing the error once and exiting.
>> What's the right way to fix this?
> you have to fail from ?ff_h264_decode_init()
> but is it really fatal if one SPS has a unsupported chroma_format ?
> there can be multiple SPS and that one maybe isnt even used in the whole
> file

That's so rare that probably no files exist in the world that do that.

Maybe it's not the "right" thing to do, but I think that ffmpeg should
not try to decode streams it doesn't support: it just confuses users.
I also don't think that the H.264 spec lets you switch chroma formats
randomly between frames, as that would make inter prediction slightly


More information about the ffmpeg-devel mailing list