[FFmpeg-user] Aspect ratio preservation in WMV

Paul-Antoine Arras listes at defendingthemusic.fr
Sun Sep 25 18:48:34 CEST 2011


Le 24/09/2011 04:17, Rodney Baker a écrit :
> On Sat, 24 Sep 2011 04:50:52 Paul-Antoine Arras wrote:
>> Hello,
>>
>> I'm trying to convert the sound of a video from WMA to MP3. To do so, I
>> use the following command line:
>>
>>      ffmpeg -i input.wmv -acodec libmp3lame -aq 4 -vcodec copy output.wmv
>>
>> The sound is converted correctly but the aspect ratio (AR) becomes 4:3
>> instead of 16:9. Then I've tried to force the AR with:
>>
>>      -aspect 16:9
>>
>> without success.
>>
>> Why does ffmpeg modify the AR while all it has to do in this case is a
>> simple copy of the video part? How to make it preserve the original AR
>> (16:9)?
>>
>> Thanks in advance for your help.
>
> You need to provide the full output from ffmpeg.
>

Here is the full output from ffmpeg:

FFmpeg version 0.6.2-4:0.6.2-1ubuntu1.1, Copyright (c) 2000-2010 the 
Libav developers
   built on Sep 16 2011 16:57:46 with gcc 4.5.2
   configuration: --extra-version=4:0.6.2-1ubuntu1.1 --prefix=/usr 
--enable-avfilter --enable-avfilter-lavf --enable-vdpau --enable-bzlib 
--enable-libgsm --enable-libschroedinger --enable-libspeex 
--enable-libtheora --enable-libvorbis --enable-pthreads --enable-zlib 
--enable-libvpx --disable-stripping --enable-runtime-cpudetect 
--enabl-libdirac --enable-libfaad --enable-libmp3lame --enable-librtmp 
--enable-libx264 --enable-libxvid --enable-libdc1394 
--shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared 
--disable-static --disable-ffmpeg --disable-ffplay
   libavcodec  configuration: --extra-version=4:0.6.2-1ubuntu2 
--prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau 
--enable-bzlib --enable-libdirac --enable-libgsm --enable-libopenjpeg 
--enable-libschroedinger --enable-libspeex --enable-libtheora 
--enable-libvorbis --enable-pthreads --enable-zlib --enable-libvpx 
--disable-stripping --enable-runtime-cpudetect --enable-vaapi 
--enable-libopenjpeg --enable-gpl --enable-postproc --enable-swscale 
--enable-x11grab --enable-libfaad --enable-libdirac --enable-libfaad 
--enable-libmp3lame --enable-librtmp --enable-libx264 --enable-libxvid 
--enable-libdc1394 --shlibdir=/usr/lib/i686/cmov --cpu=i686 
--enable-shared --disable-static --disable-ffmpeg --disable-ffplay
   libavformat configuration: --extra-version=4:0.6.2-1ubuntu1.1 
--prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau 
--enable-bzlib --enable-libgsm --enable-libschroedinger 
--enable-libspeex --enable-libtheora --enable-libvorbis 
--enable-pthreads --enable-zlib --enable-libvpx --disable-stripping 
--enable-runtime-cpudetect --enable-vaapi --enable-gpl --enable-postproc 
--enable-swscale --enable-x11grab --enable-libdc1394 
--shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared 
--disable-static --disable-ffmpeg --disable-ffplay
   libavdevice configuration: --extra-version=4:0.6.2-1ubuntu1.1 
--prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau 
--enable-bzlib --enable-libgsm --enable-libschroedinger 
--enable-libspeex --enable-libtheora --enable-libvorbis 
--enable-pthreads --enable-zlib --enable-libvpx --disable-stripping 
--enable-runtime-cpudetect --enable-vaapi --enable-gpl --enable-postproc 
--enable-swscale --enable-x11grab --enable-libdc1394 
--shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared 
--disable-static --disable-ffmpeg --disable-ffplay
   libavfilter configuration: --extra-version=4:0.6.2-1ubuntu1.1 
--prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau 
--enable-bzlib --enable-libgsm --enable-libschroedinger 
--enable-libspeex --enable-libtheora --enable-libvorbis 
--enable-pthreads --enable-zlib --enable-libvpx --disable-stripping 
--enable-runtime-cpudetect --enable-vaapi --enable-gpl --enable-postproc 
--enable-swscale --enable-x11grab --enable-libdc1394 
--shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared 
--disable-static --disable-ffmpeg --disable-ffplay
   libswscale  configuration: --extra-version=4:0.6.2-1ubuntu1.1 
--prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau 
--enable-bzlib --enable-libgsm --enable-libschroedinger 
--enable-libspeex --enable-libtheora --enable-libvorbis 
--enable-pthreads --enable-zlib --enable-libvpx --disable-stripping 
--enable-runtime-cpudetect --enable-vaapi --enable-gpl --enable-postproc 
--enable-swscale --enable-x11grab --enable-libdc1394 
--shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared 
--disable-static --disable-ffmpeg --disable-ffplay
   libpostproc configuration: --extra-version=4:0.6.2-1ubuntu1.1 
--prefix=/usr --enable-avfilter --enable-avfilter-lavf --enable-vdpau 
--enable-bzlib --enable-libgsm --enable-libschroedinger 
--enable-libspeex --enable-libtheora --enable-libvorbis 
--enable-pthreads --enable-zlib --enable-libvpx --disable-stripping 
--enable-runtime-cpudetect --enable-vaapi --enable-gpl --enable-postproc 
--enable-swscale --enable-x11grab --enable-libdc1394 
--shlibdir=/usr/lib/i686/cmov --cpu=i686 --enable-shared 
--disable-static --disable-ffmpeg --disable-ffplay
   libavutil     50.15. 1 / 50.15. 1
   libavcodec    52.72. 2 / 52.72. 2
   libavformat   52.64. 2 / 52.64. 2
   libavdevice   52. 2. 0 / 52. 2. 0
   libavfilter    1.19. 0 /  1.19. 0
   libswscale     0.11. 0 /  0.11. 0
   libpostproc   51. 2. 0 / 51. 2. 0
[wmv3 @ 0x80f41f0]Extra data: 8 bits left, value: 0

Seems stream 1 codec frame rate differs from container frame rate: 
1000.00 (1000/1) -> 25.00 (25/1)
Input #0, asf, from '[NoDRM]-Les Guignols de l'info Episode 14 - Les 
Guignols de l'info (prod7600121mpp6Id).wmv':
   Metadata:
     WMFSDKVersion   : 12.0.7600.16385
     WMFSDKNeeded    : 0.0.0.0000
     IsVBR           : 0
     title           :
     author          :
     copyright       :
     comment         :
   Duration: 00:07:46.51, start: 3.000000, bitrate: 1494 kb/s
     Stream #0.0: Audio: wmav2, 48000 Hz, 2 channels, s16, 128 kb/s
     Stream #0.1: Video: wmv3, yuv420p, 720x576, 25 tbr, 1k tbn, 1k tbc
Output #0, asf, to 'output.wmv':
   Metadata:
     WM/EncodingSettings: Lavf52.64.2
     Stream #0.0: Video: WMV3 / 0x33564D57, yuv420p, 720x576 [PAR 64:45 
DAR 16:9], q=2-31, 1k tbn, 1k tbc
     Stream #0.1: Audio: libmp3lame, 48000 Hz, 2 channels, s16, 64 kb/s
Stream mapping:
   Stream #0.1 -> #0.0
   Stream #0.0 -> #0.1
Press [q] to stop encoding
frame=11663 fps=808 q=-1.0 Lsize=   87185kB time=466.44 
bitrate=1531.2kbits/s
video:76705kB audio:8558kB global headers:0kB muxing overhead 2.253658%

***
Thanks
-- 
Paul-Antoine ARRAS


More information about the ffmpeg-user mailing list