Log in

View Full Version : How to improve my ffmpeg setting to encode in flv?


mczero
1st October 2006, 11:03
Hi all,

first of all, I'm glad to joint this community!

Okay so, here's my settings to encode a 8min video in flv using ffmpeg :

-i video.wmv -acodec mp3 -ab 48 -ar 22050 -s 512x384 -g 50 -qblur 1 -pass 1 -b 800 -r 25 -y encodedvideo.flv

then

-i video.wmv -acodec mp3 -ab 48 -ar 22050 -s 512x384 -g 50 -qblur 1 -pass 2 -b 800 -r 25 -y encodedvideo.flv

The encoded video quality is not that great and i would like to improve the quality without changing the bitrate. So ,what can I do?

Thanks for your Help (^-^)

mczero
3rd October 2006, 06:28
Is anybody can help me?

ilovejedd
3rd October 2006, 07:24
Just wanted to ask, what's the quality of the source? You might want to clean up the source prior to encoding. I tried encoding a very short clip (45 sec anime promo) to flv using your settings and found the quality to be acceptable enough.

mczero
3rd October 2006, 09:18
I made my own movie maker profile using windows media coder. The wmv quality is smooth without any macroblocks (bitrate : 1600kbp/s, 25fps). But when i convert the video, they are to many artefacts on it.

mczero
3rd October 2006, 10:32
I made some new settings, i don't really know if the quality is better :

-i video.wmv -acodec mp3 -ab 48 -ar 22050 -s 512x384 -g 50 -b_qfactor 2 -i_qfactor 1 -pass 1 -rc_init_cplx 500 -b 800 -r 25 -y encodedvideo.flv

then

-i video.wmv -acodec mp3 -ab 48 -ar 22050 -s 512x384 -g 50 -b_qfactor 2 -i_qfactor 1 -pass 2 -b 800 -r 25 -y encodedvideo.flv

foxyshadis
3rd October 2006, 17:48
ffmpeg's wmv decoder was pretty bad until recently, and still isn't perfect. If you write it out to codec rawvideo, does it still have the artifacts? If so, you might need to extract it to huffman or ffv1 via virtualdub or something like that, first.

vincente13
4th October 2006, 01:49
pardon me for this question

is the flv encoding using raster based or vector based?

mczero
4th October 2006, 09:26
i'll try to convert the wmv files into avi using Movie Maker then i'll tell you.

@vincente13 : I guess it's raster based because ffmpeg convert the file into mpeg.
@foxyshadis : So, what do you think about my settings?

mczero
4th October 2006, 15:21
unfortunately, it don't solve the problem. But i made some new settings who seems to be a bit better :

-i source.avi -pass 1 -g 240 -qcomp 0.6 -qmax 15 -qdiff 4 -i_qfactor 0.71428572 -b_qfactor 0.76923078 -maxrate 950 -bufsize 485 -s 512x384 -b 800 -refs 1 -subq 1 -r 25 -acodec mp3 -ab 48 -ar 22050 -ac 1 -y output.flv
then
-i source.avi -pass 2 -g 240 -qcomp 0.6 -qmax 15 -qdiff 4 -i_qfactor 0.71428572 -b_qfactor 0.76923078 -maxrate 950 -bufsize 485 -s 512x384 -b 800 -refs 5 -me x1 -subq 6 -r 25 -acodec mp3 -ab 48 -ar 22050 -ac 1 -y output.flv

mczero
4th October 2006, 20:41
So guys i found a patch who allow us to use vp6 and avisynth with ffmpeg! The quality is awesome!

Check it out!
http://forum.doom9.org/showthread.php?t=116493&highlight=ffmpeg+flv

vincente13
7th October 2006, 16:30
@vincente13 : I guess it's raster based because ffmpeg convert the file into mpeg.



sorry
what does it mean tt ffmpeg convert the file into mpeg?