[Ffmpeg-devel] Bug in FLV video size recognition?

Baptiste Coudurier baptiste.coudurier
Tue Jan 23 16:54:32 CET 2007


Michael Niedermayer wrote:
> Hi
> 
> On Tue, Jan 23, 2007 at 12:30:01PM +0100, deadhead wrote:
>> Using latest svn version of ffmpeg I'm experiencing a strange
>> behaviour: ffmpeg misrecognize the size (H x L) of some FLV video.
>> If I use an older version, that doesn't happen and the size is
>> correctly recognized! The original size of the video is 384x288 .
>>
>> Here some output that will clarify the situation:
>>
>> *OLD FFMpeg - Lastest stable Gentoo Version 0.4.9_p20061016*
>>
>> ffmpeg -y -i ./1172.flv
>> FFmpeg version SVN-rUNKNOWN, Copyright (c) 2000-2006 Fabrice Bellard, et al.
>>  configuration:  --prefix=/usr --libdir=/usr/lib --shlibdir=/usr/lib
>> --mandir=/usr/share/man --enable-static --enable-shared
>> --cc=i686-pc-linux-gnu-gcc --disable-altivec --disable-debug
>> --disable-audio-oss --disable-v4l --disable-v4l2 --disable-network
>> --disable-opts --enable-mp3lame --enable-a52 --enable-dc1394
>> --enable-pthreads --enable-xvid --enable-vorbis --enable-libogg
>> --enable-dts --enable-x264 --enable-faad --enable-faac --enable-gpl
>> --enable-pp --disable-strip
>>  libavutil version: 49.0.1
>>  libavcodec version: 51.20.0
>>  libavformat version: 50.6.0
>>  built on Jan 23 2007 11:15:49, gcc: 4.1.1 (Gentoo 4.1.1-r3)
>>
>> Seems that stream 1 comes from film source: 1000.00 (1000/1) -> 25.00 (25/1)
>> Input #0, flv, from './1172.flv':
>>  Duration: 00:00:17.3, start: 0.000000, bitrate: 96 kb/s
>>  Stream #0.0: Audio: mp3, 44100 Hz, mono, 96 kb/s
>>  Stream #0.1: Video: flv, yuv420p, 384x288, 25.00 fps(r)
>>
>> *Latest Version Compiled by me*
>>
>> ./bin/ffmpeg -i ./1172_original.flv
>> FFmpeg version SVN-r7658, Copyright (c) 2000-2006 Fabrice Bellard, et al.
>>  configuration:  --prefix=/tmp/ffmpe/a --enable-mp3lame --enable-pp
>> --enable-pthreads --cpu=pentium4 --disable-altivec --disable-bktr
>> --disable-debug --disable-dv1394 --disable-v4l --disable-v4l2
>> --disable-audio-oss --disable-audio-beos --disable-mpegaudio-hp
>> --disable-ipv6 --enable-gpl --enable-static
>>  libavutil version: 49.2.0
>>  libavcodec version: 51.29.0
>>  libavformat version: 51.8.0
>>  built on Jan 23 2007 11:17:13, gcc: 4.1.1 (Gentoo 4.1.1-r3)
>>
>> Seems stream 0 codec frame rate differs from container frame rate:
>> 1000.00 (1000/1) -> 25.00 (25/1)
>> Input #0, flv, from './1172_original.flv':
>>  Duration: 00:00:17.3, start: 0.000000, bitrate: 96 kb/s
>>  Stream #0.0: Video: flv, yuv420p, 384x384, 25.00 fps(r)
> 
> the flv file has a height=384 field in the header, guess the
> same alzheimer patients who designed quicktime have written the software
> which created this one ...
> 
> ffmpeg now ignores the width/height like it does for mov
> 
> i could just have ignored it and said the file is broken but thats
> not going to solve the problem, whatever did generate this file wont
> stop generating such trash ... sadly
> 

I think those wrong width/height are for crop on codecs which only
support specific resolutions, like h263.

One idea:
mov/flv set display_width, display_height, and width/height should be
set to display ones if decoder is not present or decoder could not
provide bitstream real height/width.

-- 
Baptiste COUDURIER                              GnuPG Key Id: 0x5C1ABAAA
SMARTJOG S.A.                                    http://www.smartjog.com
Key fingerprint                 8D77134D20CC9220201FC5DB0AC9325C5C1ABAAA
Phone: +33 1 49966312




More information about the ffmpeg-devel mailing list