2011-08-18 139 views
0

关于此主题有很多问题,我已经阅读了其中的大部分内容以及我可以提供的大部分Google搜索结果。通过ffmpeg和x264(质量问题)flv reencode到mp4 for iphone/ipod

当我使用FFMPEG将FLV转换为iphone3兼容MP4文件时,它只是不能保证足够的质量。是的,我已经工作了-sameq-b-bt设置,文本只是不可读。

接着我试图直接拆分视频输出并进行处理,使用以下指令: https://sites.google.com/site/linuxencoding/x264-encoding-guide

问题是myplayer(经由FFMPEG)无法确定FLV(即使元数据的持续时间被设置)。

(我假设)由于这段时间未知,当我创建MP4文件时,产生的x264文件通过超快速播放,而音频以正常速率播放。

[email protected]:/tmp# mplayer -nosound -benchmark -sws 9 -vf dsize=640:480:0,scale=0:0,expand=640:480 -vo yuv4mpeg:file=>(x264 --demuxer y4m --crf 0 --preset slow --threads auto --output output.264 - 2>x264.log) 'input.flv' 
MPlayer 1.0rc4-4.4.5 (C) 2000-2010 MPlayer Team 
mplayer: could not connect to socket 
mplayer: No such file or directory 
Failed to open LIRC support. You will not be able to use your remote control. 

Playing input.flv. 
libavformat file format detected. 
[flv @ 0x1202460]Estimating duration from bitrate, this may be inaccurate 
[lavf] stream 0: video (vp6f), -vid 0 
[lavf] stream 1: audio (nellymoser), -aid 0 
VIDEO: [VP6F] 1680x992 0bpp 1000.000 fps 33.4 kbps (4.1 kbyte/s) 
Clip info: 
audiocodecid: 6 
audiodatarate: 86 
audiosamplerate: 44100 
audiosamplesize: 16 
audiosize: 6097005 
canSeekToEnd: true 
datasize: 8609138 
duration: 567 
framerate: 2 
hasAudio: true 
hasCuePoints: false 
hasKeyframes: true 
hasMetadata: true 
hasVideo: true 
height: 992 
lasttimestamp: 567 
metadatacreator: flvtool++ (Facebook, Motion project, dweatherford) 
stereo: false 
totalframes: 1043 
videocodecid: 4 
videodatarate: 33 
videosize: 2316256 
width: 1680 
Using (default) progressive frame mode.Opening video filter: [expand w=640 h=480] 
Expand: 640 x 480, -1 ; -1, osd: 0, aspect: 0.000000, round: 1 
Opening video filter: [scale w=0 h=0] 
Opening video filter: [dsize=640:480:0] 
========================================================================== 
Opening video decoder: [ffmpeg] FFmpeg's libavcodec codec family 
Selected video codec: [ffvp6f] vfm: ffmpeg (FFmpeg VP6 Flash) 
========================================================================== 
Audio: no sound 
Starting playback... 
Movie-Aspect is undefined - no prescaling applied. 
[swscaler @ 0x7f0c738b9620]Lanczos scaler, from yuv420p to yuv420p using MMX2 
VO: [yuv4mpeg] 640x480 => 641x480 Planar YV12 

我自己也尝试指定FPS,但结果没有变化

[email protected]:/tmp# mplayer -nosound -fps 25-benchmark -sws 9 -vf dsize=640:480:0,scale=0:0,expand=640:480 -vo yuv4mpeg:file=>(x264 --demuxer y4m --fps 25 --crf 0 --preset slow --threads auto --output output.264 - 2>x264.log) 'input.flv' 

谁能告诉我如何可以:

  1. 解决我的拆分A/V处理/定时/期限问题?
  2. 提高 质量的FFMPEG转换FLV到iphone3兼容 格式?

回答

1

我会建议尝试handbreak(http://handbrake.fr/),我认为它可以编码的FLV形式以及几乎所有其他文件甲酸我曾经尝试过,和我心中已经从未有过任何麻烦质量。