FORUMS: list search recent posts

Enceded Video Not playing Properly!

COW Forums : FFmpeg

<< PREVIOUS   •   VIEW ALL   •   PRINT   •   NEXT >>
MD Kamrul Hassan
Enceded Video Not playing Properly!
on Mar 8, 2013 at 5:05:17 am

Greetings everyone on this forum..
i m facing a wired issue..
i m trying to encode mp4 file from a avi and mp3 file with high quality. I get the CLI (command line) parameters from winFF (windows GUI for ffmpeg) and using it.
but the problem is encoded video does not play on most player (like jetaudio, windows media player) only audio plays. But it only plays ok on vlc player

please download the file from the following link:
http://www.siamcomputer-bd.com/downloads/ffmpeg_error.zip

in the zip file the main video (avi) file is compressed with 7z as the video is too big 131mb but after 7z compress it is only 1mb.

so, you need 7z or winRar 4+ version to extract that 7z file..

it would be great if anyone kindly help me out

thanks again in advance to all active users
best regards
kamrul hassan


Return to posts index

Jim Sustacek
Re: Enceded Video Not playing Properly!
on Mar 8, 2013 at 3:35:47 pm

I think there was some odd issue with your source files? I had to process them individually first, then combine them, so it took three commands:
ffmpeg -y -i "Render.avi" -crf 35.0 -vcodec libx264 -vf scale=320:240 -aspect 4:3 -coder 1 -flags +loop -cmp +chroma -partitions +parti4x4+partp8x8+partb8x8 -me_method hex -subq 6 -me_range 16 -g 250 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -b_strategy 1 -qcomp 0.6 -qmin 0 -qmax 69 -qdiff 4 -bf 3 -refs 5 -direct-pred 3 -trellis 1 -wpredp 2 -rc_lookahead 50 -threads 0 "video.mp4"

ffmpeg.exe -y -i "Kalimba.mp3" -vn -acodec libvo_aacenc -ar 48000 -b:a 128k "audio.mp4"

ffmpeg.exe -y -i video.mp4 -i audio.mp4 -c copy -shortest "Sample.mp4"

Let us know if that works for you.


Return to posts index

Lou Logan
Re: Enceded Video Not playing Properly!
on Mar 12, 2013 at 9:19:46 pm

[Jim Sustacek] "ffmpeg -y -i "Render.avi" -crf 35.0 -vcodec libx264 -vf scale=320:240 -aspect 4:3 -coder 1 -flags +loop -cmp +chroma -partitions +parti4x4+partp8x8+partb8x8 -me_method hex -subq 6 -me_range 16 -g 250 -keyint_min 25 -sc_threshold 40 -i_qfactor 0.71 -b_strategy 1 -qcomp 0.6 -qmin 0 -qmax 69 -qdiff 4 -bf 3 -refs 5 -direct-pred 3 -trellis 1 -wpredp 2 -rc_lookahead 50 -threads 0 "video.mp4""

Declaring a bewildering multitude of various libx264 options is not recommended. That's what the encoding presets are for. The presets were designed by the x264 developers so users would not have to create such massive (and often incorrect) commands. Additionally, the presets keep up with any changes, new features, etc; unlike manually setting a million options.

So instead of your long command you could use:
ffmpeg -i input -codec:v libx264 -preset slow -crf 23 -vf scale=320:-1 output.mp4

A crf value of 35 is fairly low quality so I used a value that will provide higher quality, and "-threads 0" is now default, so that is not required.

Also see the FFmpeg and x264 Encoding Guide for more details and examples.


Return to posts index


Lou Logan
Re: Enceded Video Not playing Properly!
on Mar 12, 2013 at 9:32:45 pm

You are experiencing the same issue as described in FFmpeg output is black video, with audio. Basically, you need to add the following option:
-pix_fmt yuv420p
or
-vf format=yuv420p
...and read my response in this thread to Jim Sustacek about your command (I now realize that was your command that Jim provided).

So your command can look like:
ffmpeg.exe -i Render.avi -i Kalimba.mp3 -codec:v libx264 -crf 23 -preset slow -filter:v format=yuv420p,scale=320:-1,setdar=4:3 -codec:a libvo_aacenc -ar 48000 -b:a 128k -shortest Sample.mp4

Next time please simply include your ffmpeg command and the complete console output in your message on this forum.


Return to posts index

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