ffmpeg 视频左侧和右侧出现黑条

ffmpeg 视频左侧和右侧出现黑条

我在使用 ffmpeg 的分辨率方面遇到了奇怪的问题。在下面的输出中我有两个文件“test1”和“test2”。

“测试1.flv”我从网站上下载了它,并且已经转换成了 flv,并且测试2.flv我已经自己转换了。现在的问题是,我的文件在视频的左侧和右侧都有黑条。虽然它们的分辨率相同,但 test1 根本没有任何黑条。

fmpeg -loglevel panic -i "test.avi" -vf "movie=/storage/conv_sctipt/watermark.mov  [watermark]; [in][watermark] overlay=main_w-overlay_w-10:main_h-overlay_h-10, fade=in:0:20 [out]" -map 0:0 -map 0:1 -y -acodec libfaac -ab 64K -ac 1 -vcodec libx264 -b 555K -bt 666k -threads 0 "test2.flv"

ffmpeg -i 测试2.flv

**test2.flv**
ffmpeg version git-2012-05-17-a99a3b1 Copyright (c) 2000-2012 the FFmpeg developers
  built on May 17 2012 23:39:57 with gcc 4.6.2
  configuration: --enable-gpl --enable-libfaac --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora --enable-libvorbis --enable-libx264 --enable-nonfree --enable-postproc --enable-version3 --enable-x11grab
  libavutil      51. 53.100 / 51. 53.100
  libavcodec     54. 21.101 / 54. 21.101
  libavformat    54.  5.100 / 54.  5.100
  libavdevice    53.  4.100 / 53.  4.100
  libavfilter     2. 74.100 /  2. 74.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 11.100 /  0. 11.100
  libpostproc    52.  0.100 / 52.  0.100
  Metadata:
    metadatacreator : Yet Another Metadata Injector for FLV - Version 1.4
    hasKeyframes    : true
    hasVideo        : true
    hasAudio        : true
    hasMetadata     : true
    canSeekToEnd    : true
    datasize        : 103188591
    videosize       : 91604369
    audiosize       : 11214994
    lasttimestamp   : 1303
    lastkeyframetimestamp: 1303
    lastkeyframelocation: 103194425
  Duration: 00:21:42.72, start: 0.021000, bitrate: 633 kb/s
    Stream #0:0: Video: h264 (High), yuv420p, 720x400 [SAR 1:1 DAR 9:5], 560 kb/s, 23.98 tbr, 1k tbn, 47.95 tbc
    Stream #0:1: Audio: aac, 48000 Hz, mono, s16, 64 kb/s
At least one output file must be specified
root@host-37:/# 
root@host-37:/# 

ffmpeg -i 测试1.flv

**test1.flv**
ffmpeg version git-2012-05-17-a99a3b1 Copyright (c) 2000-2012 the FFmpeg developers
  built on May 17 2012 23:39:57 with gcc 4.6.2
  configuration: --enable-gpl --enable-libfaac --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libtheora --enable-libvorbis --enable-libx264 --enable-nonfree --enable-postproc --enable-version3 --enable-x11grab
  libavutil      51. 53.100 / 51. 53.100
  libavcodec     54. 21.101 / 54. 21.101
  libavformat    54.  5.100 / 54.  5.100
  libavdevice    53.  4.100 / 53.  4.100
  libavfilter     2. 74.100 /  2. 74.100
  libswscale      2.  1.100 /  2.  1.100
  libswresample   0. 11.100 /  0. 11.100
  libpostproc    52.  0.100 / 52.  0.100
  Metadata:
    metadatacreator : Yet Another Metadata Injector for FLV - Version 1.8
    hasKeyframes    : true
    hasVideo        : true
    hasAudio        : true
    hasMetadata     : true
    canSeekToEnd    : false
    datasize        : 116774820
    videosize       : 95577067
    audiosize       : 20591541
    lasttimestamp   : 2435
    lastkeyframetimestamp: 2433
    lastkeyframelocation: 116745006
  Duration: 00:40:34.52, start: 0.040000, bitrate: 383 kb/s
    Stream #0:0: Video: h264 (High), yuv420p, 720x400 [SAR 1:1 DAR 9:5], 311 kb/s, 25 tbr, 1k tbn, 50 tbc
    Stream #0:1: Audio: mp3, 44100 Hz, mono, s16, 64 kb/s
At least one output file must be specified

相关内容