FORUMS: list search recent posts

empty file when converting .flv to .mp4

COW Forums : FFmpeg

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
Raul Benitez
empty file when converting .flv to .mp4
on Jul 28, 2014 at 8:28:11 pm

After upgrading to the newest version of ffmpeg I ran a test convert to see if it was working. The output came out with an empty file. So my script is working but I think I'm missing a step hence the empty file. Take a look at what I did

CODE: SELECT ALL
@node1 [/home/ebaitbiz/www/ebait_images/myd13Yv]# ffmpeg -i credit_app_1.flv
ffmpeg version 2.2.git Copyright (c) 2000-2014 the FFmpeg developers
built on Jul 26 2014 10:29:10 with gcc 4.1.2 (GCC) 20080704 (Red Hat 4.1.2-54)
configuration: --enable-version3 --enable-libopencore-amrnb --enable-libmp3lame --enable-libx264 --enable-libxvid --enable-gpl --enable-postproc --enable-nonfree
libavutil 52. 92.101 / 52. 92.101
libavcodec 55. 69.100 / 55. 69.100
libavformat 55. 49.100 / 55. 49.100
libavdevice 55. 13.102 / 55. 13.102
libavfilter 4. 11.102 / 4. 11.102
libswscale 2. 6.100 / 2. 6.100
libswresample 0. 19.100 / 0. 19.100
libpostproc 52. 3.100 / 52. 3.100
Input #0, flv, from 'credit_app_1.flv':
Metadata:
hasKeyframes : true
hasMetadata : true
datasize : 2919345
hasVideo : true
canSeekToEnd : false
lasttimestamp : 21
lastkeyframetimestamp: 21
audiosize : 96337
hasAudio : true
audiodelay : 0
videosize : 2821526
metadatacreator : inlet media FLVTool2 v1.0.5 - http://www.inlet-media.de/flvtool2
hasCuePoints : false
Duration: 00:00:21.50, start: 0.000000, bitrate: 1088 kb/s
Stream #0:0: Video: flv1, yuv420p, 640x360, 1075 kb/s, 24 fps, 24 tbr, 1k tbn, 1k tbc
Stream #0:1: Audio: mp3, 22050 Hz, mono, s16p, 33 kb/s
At least one output file must be specified

@node1 [/home/ebaitbiz/www/ebait_images/myd13Yv]# ffmpeg -i credit_app_1.flv -b 1088k -ab 33k credit_app_1_.mp4
ffmpeg version 2.2.git Copyright (c) 2000-2014 the FFmpeg developers
built on Jul 26 2014 10:29:10 with gcc 4.1.2 (GCC) 20080704 (Red Hat 4.1.2-54)
configuration: --enable-version3 --enable-libopencore-amrnb --enable-libmp3lame --enable-libx264 --enable-libxvid --enable-gpl --enable-postproc --enable-nonfree
libavutil 52. 92.101 / 52. 92.101
libavcodec 55. 69.100 / 55. 69.100
libavformat 55. 49.100 / 55. 49.100
libavdevice 55. 13.102 / 55. 13.102
libavfilter 4. 11.102 / 4. 11.102
libswscale 2. 6.100 / 2. 6.100
libswresample 0. 19.100 / 0. 19.100
libpostproc 52. 3.100 / 52. 3.100
Input #0, flv, from 'credit_app_1.flv':
Metadata:
hasKeyframes : true
hasMetadata : true
datasize : 2919345
hasVideo : true
canSeekToEnd : false
lasttimestamp : 21
lastkeyframetimestamp: 21
audiosize : 96337
hasAudio : true
audiodelay : 0
videosize : 2821526
metadatacreator : inlet media FLVTool2 v1.0.5 - http://www.inlet-media.de/flvtool2
hasCuePoints : false
Duration: 00:00:21.50, start: 0.000000, bitrate: 1088 kb/s
Stream #0:0: Video: flv1, yuv420p, 640x360, 1075 kb/s, 24 fps, 24 tbr, 1k tbn, 1k tbc
Stream #0:1: Audio: mp3, 22050 Hz, mono, s16p, 33 kb/s
Please use -b:a or -b:v, -b is ambiguous
[libx264 @ 0x979d4a0] using cpu capabilities: MMX2 SSE2Fast SSSE3 SSE4.2
[libx264 @ 0x979d4a0] profile High, level 3.0
[libx264 @ 0x979d4a0] 264 - core 142 r2453 ea0ca51 - H.264/MPEG-4 AVC codec - Copyleft 2003-2014 - http://www.videolan.org/x264.html - options: cabac=1 ref=3 deblock=1:0:0 analyse=0x3:0x113 me=hex subme=7 psy=1 psy_rd=1.00:0.00 mixed_ref=1 me_range=16 chroma_me=1 trellis=1 8x8dct=1 cqm=0 deadzone=21,11 fast_pskip=1 chroma_qp_offset=-2 threads=24 lookahead_threads=2 sliced_threads=0 nr=0 decimate=1 interlaced=0 bluray_compat=0 constrained_intra=0 bframes=3 b_pyramid=2 b_adapt=1 b_bias=0 direct=1 weightb=1 open_gop=0 weightp=2 keyint=250 keyint_min=24 scenecut=40 intra_refresh=0 rc_lookahead=40 rc=abr mbtree=1 bitrate=1088 ratetol=1.0 qcomp=0.60 qpmin=0 qpmax=69 qpstep=4 ip_ratio=1.40 aq=1:1.00
[aac @ 0x9804920] The encoder 'aac' is experimental but experimental codecs are not enabled, add '-strict -2' if you want to use it.
[libx264 @ 0x979d4a0] final ratefactor: 21.37


The result was
-rw-r--r-- 1 ebaitbiz ebaitbiz 2924756 Jul 25 15:47 credit_app_1.flv
-rw-r--r-- 1 root root 0 Jul 28 15:49 credit_app_1_.mp4

Im sure its something simple I"m missing.

Thanks!


Return to posts index

Jim Sustacek
Re: empty file when converting .flv to .mp4
on Jul 29, 2014 at 12:49:01 pm

Notice the experimental AAC encoder warning? I'd try satisfying that first as described, by adding "-strict -2" to your command:

ffmpeg -i credit_app_1.flv -b 1088k -ab 33k -strict -2 credit_app_1_.mp4

Probably also worth heeding the "-b"/"-ab" ambiguous warnings too, and updating those options to "-b:v" and "-b:a" respectively, although it shouldn't be causing the blank file:

ffmpeg -i credit_app_1.flv -b:v 1088k -b:a 33k -strict -2 credit_app_1_.mp4

Also your blank file was created by the "root" user -- are you running ffmpeg as root? Normally you should get warnings about overwriting and permission errors, but just to be sure, delete the mp4 file before running the command, and maybe add a "-y" option to your command so it overwrites without prompting too.


Return to posts index

Raul Benitez
Re: empty file when converting .flv to .mp4
on Jul 29, 2014 at 2:23:29 pm

This actually worked!

Thank you so much.


Return to posts index

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
© 2017 CreativeCOW.net All Rights Reserved
[TOP]