本文介绍了打开编码器输出流#0时出错:1 - 可能是不正确的参数,如bit_rate,速率,宽度或高度的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我正在尝试通过以下命令通过FFMPEG将avi视频文件转换为flv格式:

  -i C: \files\input\test.avi -y -ab 448k -ar 48000 -vcodec mpeg4 -s 640x480 -f flv C:\files\output\test.flv 

这是从ffmpeg获得的回复:



输入:

 输入#0,avi,来自'C:\files\input\test.avi':
元数据:
编码器:VirtualDubMod 1.5.10.2(build 2540 / release)
持续时间:00:01:00.00,开始:0.000000,比特率:1813 kb / s
流#0:0:视频: mpeg4(高级简单配置文件)(XVID / 0x44495658),yuv420p,640x272 [SAR 1:1 DAR 40:17],25 tbr,25 tbn,25 tbc
流#0:1:音频:ac3([0 ] [0] [0] / 0x2000),48000 Hz,5.1(侧),s16,448 kb / s

输出:

 输出#0,flv,到'C:\files\output\test。 flv':
元数据:
编码器:VirtualDubMod 1.5.10.2(build 2540 / release)
流#0:0:视频:mpeg4,yuv420p,640x480 [SAR 30:17 DAR 40:17],q = 2-31,200 kb / s,90k tbn,25 tbc
流#0:1:音频:mp3,48000Hz,5.1(side),s16,448 kb / s
流映射:
流# 0:0 - > #0:0(mpeg4 - > mpeg4)
流#0:1 - > #0:1(ac3 - > libmp3lame)
打开编码器输出流#0时出错:1 - 可能是不正确的参数,如bit_rate,rate,width或height
你可以告诉我这里有什么可以在这里吗?上面有什么问题?

解决方案

您必须指定所有编解码器显式:-c:v mpeg4 参数 -c:副本-c:s副本(如果有字幕)


I am trying to convert an avi video file to flv format via FFMPEG with the following command:

-i C:\files\input\test.avi -y -ab 448k -ar 48000 -vcodec mpeg4 -s 640x480 -f flv C:\files\output\test.flv

Here is the response I am getting from ffmpeg:

Input:

Input #0, avi, from 'C:\files\input\test.avi':
  Metadata:
    encoder         : VirtualDubMod 1.5.10.2 (build 2540/release)
  Duration: 00:01:00.00, start: 0.000000, bitrate: 1813 kb/s
    Stream #0:0: Video: mpeg4 (Advanced Simple Profile) (XVID / 0x44495658), yuv420p, 640x272 [SAR 1:1 DAR 40:17], 25 tbr, 25 tbn, 25 tbc
    Stream #0:1: Audio: ac3 ([0] [0][0] / 0x2000), 48000 Hz, 5.1(side), s16, 448 kb/s

Output:

Output #0, flv, to 'C:\files\output\test.flv':
  Metadata:
    encoder         : VirtualDubMod 1.5.10.2 (build 2540/release)
    Stream #0:0: Video: mpeg4, yuv420p, 640x480 [SAR 30:17 DAR 40:17], q=2-31, 200 kb/s, 90k tbn, 25 tbc
    Stream #0:1: Audio: mp3, 48000 Hz, 5.1(side), s16, 448 kb/s
Stream mapping:
  Stream #0:0 -> #0:0 (mpeg4 -> mpeg4)
  Stream #0:1 -> #0:1 (ac3 -> libmp3lame)
Error while opening encoder for output stream #0:1 - maybe incorrect parameters such as bit_rate, rate, width or height

Can you tell me what is MAY BE here? and what is wrong above?

解决方案

You must specify all codecs explicit: -c:v mpeg4 parameters -c:a copy -c:s copy(for subtitles if present)

这篇关于打开编码器输出流#0时出错:1 - 可能是不正确的参数,如bit_rate,速率,宽度或高度的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!

10-20 20:24