[FFmpeg-user] ffmpeg get video from video file of avi
Jacky
690271929 at qq.com
Mon Oct 14 04:19:22 CEST 2013
hi:
i use the command:" ffmpeg -t 20 -i /data/test/media/1789035.avi -an -vcodec copy video.avi " to get the video data. i get the ffmpeg info is:
[root at cdn 2269968]# ./ffmpeg -i audio.avi -i video.avi -c copy av.avi
ffmpeg version 2.0 Copyright (c) 2000-2013 the FFmpeg developers
built on Jul 31 2013 10:34:48 with gcc 4.4.6 (GCC) 20110731 (Red Hat 4.4.6-3)
configuration: --prefix=/data/test/jh/ffmpeg --extra-cflags=-I/data/test/jh/src/ffmpeg/include --extra-ldflags=-L/data/test/jh/src/ffmpeg/lib --enable-gpl --enable-version3 --enable-nonfree --enable-debug --enable-memalign-hack --enable-libfaac --enable-libaacplus --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxvid
libavutil 52. 38.100 / 52. 38.100
libavcodec 55. 18.102 / 55. 18.102
libavformat 55. 12.100 / 55. 12.100
libavdevice 55. 3.100 / 55. 3.100
libavfilter 3. 79.101 / 3. 79.101
libswscale 2. 3.100 / 2. 3.100
libswresample 0. 17.102 / 0. 17.102
libpostproc 52. 3.100 / 52. 3.100
Input #0, avi, from 'audio.avi':
Metadata:
encoder : Lavf55.12.100
Duration: 01:49:24.68, start: 0.000000, bitrate: 264 kb/s
Stream #0:0: Audio: aac ([255][0][0][0] / 0x00FF), 44100 Hz, stereo, fltp, 256 kb/s
Input #1, avi, from 'video.avi':
Metadata:
encoder : Lavf55.12.100
Duration: 00:00:20.04, start: 0.000000, bitrate: 17246 kb/s
Stream #1:0: Video: h264 (Main) (avc1 / 0x31637661), yuv420p, 1920x1080, 24 fps, 24 tbr, 24 tbn, 48 tbc
Output #0, avi, to 'av.avi':
Metadata:
ISFT : Lavf55.12.100
Stream #0:0: Video: h264 (avc1 / 0x31637661), yuv420p, 1920x1080, q=2-31, 24 fps, 24 tbn, 24 tbc
Stream #0:1: Audio: aac ([255][0][0][0] / 0x00FF), 44100 Hz, stereo, 256 kb/s
Stream mapping:
Stream #1:0 -> #0:0 (copy)
Stream #0:0 -> #0:1 (copy)
Press [q] to stop, [?] for help
frame= 481 fps= 92 q=-1.0 Lsize= 254107kB time=01:49:24.67 bitrate= 317.1kbits/s
video:42175kB audio:205146kB subtitle:0 global headers:0kB muxing overhead 2.743437%
and i test the video.avi use the command: /ffmpeg -i video.avi
i get:
ffmpeg version 2.0 Copyright (c) 2000-2013 the FFmpeg developers
built on Jul 31 2013 10:34:48 with gcc 4.4.6 (GCC) 20110731 (Red Hat 4.4.6-3)
configuration: --prefix=/data/test/jh/ffmpeg --extra-cflags=-I/data/test/jh/src/ffmpeg/include --extra-ldflags=-L/data/test/jh/src/ffmpeg/lib --enable-gpl --enable-version3 --enable-nonfree --enable-debug --enable-memalign-hack --enable-libfaac --enable-libaacplus --enable-libfreetype --enable-libmp3lame --enable-libopencore-amrnb --enable-libopencore-amrwb --enable-libvo-amrwbenc --enable-libvorbis --enable-libvpx --enable-libx264 --enable-libxvid
libavutil 52. 38.100 / 52. 38.100
libavcodec 55. 18.102 / 55. 18.102
libavformat 55. 12.100 / 55. 12.100
libavdevice 55. 3.100 / 55. 3.100
libavfilter 3. 79.101 / 3. 79.101
libswscale 2. 3.100 / 2. 3.100
libswresample 0. 17.102 / 0. 17.102
libpostproc 52. 3.100 / 52. 3.100
Input #0, avi, from 'video.avi':
Metadata:
encoder : Lavf55.12.100
Duration: 00:00:20.04, start: 0.000000, bitrate: 17246 kb/s
Stream #0:0: Video: h264 (Main) (avc1 / 0x31637661), yuv420p, 1920x1080, 24 fps, 24 tbr, 24 tbn, 48 tbc
At least one output file must be specified
and i use mediainfo :
mediainfo video.avi
General
Complete name : video.avi
Format : AVI
Format/Info : Audio Video Interleave
File size : 41.2 MiB
Duration : 20s 42ms
Overall bit rate : 17.2 Mbps
Writing application : Lavf55.12.100
Video
ID : 0
Format : AVC
Format/Info : Advanced Video Codec
Format profile : Main at L4.1
Format settings, CABAC : No
Format settings, ReFrames : 2 frames
Codec ID : avc1
Duration : 20s 42ms
Bit rate : 17.2 Mbps
Width : 1 920 pixels
Height : 1 080 pixels
Display aspect ratio : 16:9
Frame rate : 24.000 fps
Color space : YUV
Chroma subsampling : 4:2:0
Bit depth : 8 bits
Scan type : Progressive
Bits/(Pixel*Frame) : 0.346
Stream size : 41.2 MiB (100%)
Color primaries : BT.709
Transfer characteristics : BT.709
Matrix coefficients : BT.709
it seem no problem of this video.avi, but when i play this file, it has no picture. i try more than one player, but no one can play it.
thank you very much.
More information about the ffmpeg-user
mailing list