[FFmpeg-devel] [PATCH] reduce score returned by FLIC format

Mike Melanson mike
Wed Mar 26 15:14:52 CET 2008


Mike Melanson wrote:
> Aurelien Jacobs wrote:
>>> The first 4 bytes of the file should match the total size of the file.
>> But you can't check this unless the stream is seekable.
> 
> And it also doesn't work for the bastardized FLIC variant found on a
> particular game. There are maybe 7 files in existence that depend on
> that hack. But one of them is a FATE test, so we can't break it. :)
> 
>>> The width and height could also be sanity-checked (this is part of
>>> how the id CIN demuxer detects a file).
>> This might be enough...
>>
>> Still this test would be a bit week, and maybe it would be better to
>> make it return 9*AVPROBE_SCORE_MAX/10 or something like that.
> 
> I'll take that into account.

Here's a patch. Sane enough? I declared that each dimension must be
between 4..2048. That should be generous enough. And I also used Aurel's
suggestion (90% sure).

-- 
	-Mike Melanson
-------------- next part --------------
A non-text attachment was scrubbed...
Name: flic-better-probe.patch
Type: text/x-patch
Size: 883 bytes
Desc: not available
URL: <http://lists.mplayerhq.hu/pipermail/ffmpeg-devel/attachments/20080326/b9ecb5de/attachment.bin>



More information about the ffmpeg-devel mailing list