Hey everyone!
I'm creating a series of videos (flv for the web) witch are mostly still images, but occasionally will have spots of full motion video. Imagine these videos are like a power point or something. They're mostly just a single frame repeated. Sometimes though, there are full motion video clips.
If I create one of these videos from stills without motion video, I get a perfect video quality, and a final bitrate of about 75kbps. If I recreate that same video, but insert a 30 second full motion video, the quality of the entire length of the video is degraded.
What I'm looking for is a way to keep the bitrate super low during the still parts, and bump it up during the motion parts.
Here's my current command:
Thanks!Code:ffmpeg -y -r 1 -loop_input -g 3 -i "image.png" -s 656x492 -vcodec mpeg4 -qscale 1 -g 300 -i audio.wav -r 25 -acodec copy output.flv
+ Reply to Thread
Results 1 to 5 of 5
-
-
you will get much better quality/compression by using h.264 than mpeg-4asp (at very low bitrates it can be 4-5x better)
for ffmpeg encoding guide
http://rob.opendot.cl/index.php/useful-stuff/ffmpeg-x264-encoding-guide/
if this is for embedded flash videos in flv container, you need to inject metadata for it to play immediately (instead of downloading completely before playing). You could use flvtool++ , flvtool2, yamdi, or flvmdi to do this
lengthening the gop interval and using more consecutive b-frames can significantly help compression for still image sequences as well -
Thanks for the info! Very helpful. I've been using a smaller gop (-g 3) for the stills, and a larger gop for the high motion clips (-g 300) and then just using the default when rendering my avi of combined clips into the flv. What would you recommend for a gop?
-
They will be dynamically placed. So specifying a max GOP size of , say, 300 doesn't mean you necessarily get 300 all the time, it will vary on the content complexity. IDR-frames will be inserted as necessary, and it will vary between min and max.
For still sequences, a longer GOP with many consecutive max b-frames will immensely help compression probably many times more. This is because long GOP formats code the differences between frames. Since your still sequence has zero difference between each still, you can see how this would help compression. This is also why you say deterioration with the motion sequences; whenever there is motion, each frames is different than the next, so the larger the difference, the more bitrate is required to code the differences to keep a certain level of quality. So I would leave it at 300 for everything
I don't use ffmpeg for encoding x264, but if you want a small description of what the commands do (the switches are labelled slightly differently in ffmpeg)
http://mewiki.project357.com/wiki/X264_SettingsLast edited by poisondeathray; 21st May 2010 at 08:29.
-
Use a constant quality encode with large GOPs. The still shots will hardly take any bitrate. The motion shots will get whatever they need to deliver the quality you request.
Similar Threads
-
best motion search option to increase encoding speed while keeping quality?
By visualhippocracy in forum Video ConversionReplies: 4Last Post: 13th Jan 2011, 10:40 -
Mpeg4 Settings for TMPGenc give poor quality for motion.. see pic's
By drewzor in forum Video ConversionReplies: 14Last Post: 13th May 2009, 08:37 -
Mixed Video Formats in Vegas
By SCDVD in forum EditingReplies: 0Last Post: 21st May 2008, 10:10 -
How to add pulldown flags to a clip of mixed film/video?
By Mizkreant in forum Video ConversionReplies: 6Last Post: 14th Aug 2007, 06:05 -
Motion Blur/Bad Quality when capturing uncompressed
By Ezekiel 4:12 in forum Capturing and VCRReplies: 4Last Post: 15th Jul 2007, 01:44