VideoHelp Forum




+ Reply to Thread
Results 1 to 5 of 5
  1. Member brassplyer's Avatar
    Join Date
    Apr 2008
    Location
    United States
    Search Comp PM
    Someone just tipped me off to WinFF, works great, but there are some elements of the command line I'm not clear on.

    Here's the default preset for an .flv file. Some of it I get, some isn't clear to me.

    -vcodec flv -f flv -r 29.97 -s 320x240 -aspect 4:3 -b 300kb -g 160 -cmp 2 -subcmp 2 -mbd 2 -flags +aic+cbp+mv0+mv4+trell -ac 1 -ar 22050 -ab 56k

    vcodec flv - I get that this and the one below have to do with telling it to produce an flv but why the apparent two references to flv?

    f flv - see above

    r 29.97 - rate

    s 320x240 - size/dimension

    aspect 4:3 - aspect ratio

    b 300kb - video bitrate

    g 160 - ?

    cmp 2 - ?

    subcmp 2 - ?

    mbd 2 - ?

    flags +aic+cbp+mv0+mv4+trell - ?

    ac 1 - I assume "audio channels" in this case 1 for mono?

    ar 22050 -audio sample rate

    ab 56k - audio bit rate


    Thanks for all input
    Quote Quote  
  2. Member vhelp's Avatar
    Join Date
    Mar 2001
    Location
    New York
    Search Comp PM
    I dont' use winff, so I can't help you there. But..

    You can remove it, the -f flv param. As long as your OUTPUT video includes the proper extention
    (ie, .flv) then you don't need it. If memory serves me.., the -f is the video format specifier. You
    tell it that you want to encode an flash video, I think. Anyway, you don't need it, though. I don't
    use it in my flv encodes.

    ..couple of tips for improving quality..

    1 -- To improve the quality of your flash encoded videos, you should consider a 2-pass method.
    2 -- If you are tying to go the <350kb way, aim for no higher than a finished 346/7k (and, see below)
    3 -- And, consider post-processing your video with a tuned NR application, then write out a new
    video stream that way -- will have to be huffy because mencoder and ffmpeg will not take in a
    Lagarith codec video.

    For post-process your videos with a noise reduction application, this is usually a very time consuming
    task, but worth it if you know what you are doing and your source is cooperative, and you are
    not posting more than 2 or 3 videos a week on youtube This is how I do it.. the 2-pass way,
    that is

    Thats about it, and good luck.

    -vhelp 4656
    Quote Quote  
  3. Member brassplyer's Avatar
    Join Date
    Apr 2008
    Location
    United States
    Search Comp PM
    Originally Posted by vhelp
    If you are tying to go the <350kb way, aim for no higher than a finished 346/7k (and, see below)

    Thanks for all the good info.

    Actually for a 5 minute video, I'm able to go to around 700 kbps appending a 5:59 black segment that's been stripped down to around 31 kbps which yields a video with bitrate of 337kpbs.
    Quote Quote  
  4. g 160 - ?

    cmp 2 - ?

    subcmp 2 - ?

    mbd 2 - ?

    flags +aic+cbp+mv0+mv4+trell - ?
    from ffmpeg manual

    g: max size of gop
    cmp: full pel me compare function
    subcmp: sub pel me compare function
    mbd: macroblock decision algorithm
    aic: activate the h263 advanced intra coding / mpeg4 ac prediction
    cbp: use rate distortion optimization for cbp
    mv0: always try a mb with mv=<0,0>
    mv4: use four motion vector by macroblock (mpeg4)
    trell: use trellis quantization

    also, from mencoder manual

    mv0: Try to encode each MB with MV=<0,0> and choose the better one. This has no effect if mbd=0.

    cbp, mv0: Controls the selection of macroblocks. Small speed cost for small quality gain.

    cmp, subcmp, precmp: Comparison function for motion estimation. Experiment with values of 0 (default), 2 (hadamard), 3 (dct), and 6 (rate distortion). 0 is fastest, and sufficient for precmp. For cmp and subcmp, 2 is good for anime, and 3 is good for live action. 6 may or may not be slightly better, but is slow.

    mbd: Macroblock decision algorithm (high quality mode), encode each macro block in all modes and choose the best. This is slow but results in better quality and file size. When mbd is set to 1 or 2, the value of mbcmp is ignored when comparing macroblocks (the mbcmp value is still used in other places though, in particular the motion search algorithms). If any comparison setting (precmp, subcmp, cmp, or mbcmp) is nonzero, however, a slower but better half-pel motion search will be used, regardless of what mbd is set to. If qpel is set, quarter-pel motion search will be used regardless.
    0: Use comparison function given by mbcmp (default).
    1:Select the MB mode which needs the fewest bits (=vhq).
    2:Select the MB mode which has the best rate distortion.

    the mplayer/mencoder and ffmpeg documentation are very good. take a ride and read it

    BHH
    HDConvertToX, AutoMen, AutoMKV Developer
    Quote Quote  
  5. Member vhelp's Avatar
    Join Date
    Mar 2001
    Location
    New York
    Search Comp PM
    I'm sorry. I was always confused about the black frame bit.. you know.. do I put one frame at the
    end, or calc a certain number of blank frames to insert.. and then setting the actual encoding
    bitrate for that scheme -- I don't know the bitrate calc to arrive at to use for the encoding. Anyway,
    That's what confused me and why I didn't bother with that trick. I've just been putting it off, though
    it looks like a very good one, indeed.

    ...

    But getting back to your situation.. Yeah, I forgot. I should have given you a 2-pass setup for your
    ffmpeg response. Sorry bout that.. It's actually very easy, so I'll just give you the basic approach
    and then you add in your own home-brew of params and go from there

    For (FLV) 2-pass encodes, I use the following:

    --> ffmpeg ... -passlogfile "c:\log.txt" -pass 1 ...
    --> ffmpeg ... -passlogfile "c:\log.txt" -pass 2 ...

    where ... is your params.

    I always follow it like this in this order because in my GUI tool I keep a journal log open of all my
    encoding scripts so that I can refer back to any prev encoding setups. Plus, I can see the first
    parts of the encoding params (on screen) that I'm most interested in at the time while browsing
    around param setups. This really helps me out a lot, but you can change your param order around
    to your liking i guess.

    ...

    Personally, I prefer ffmpeg over mencoder. I don't know. I seem to recall having much better
    video quality when using ffmpeg. Anyway. Just so you know, I am not an ffmpeg guru. There
    are many things I still don't know about or might not be properly using command/param for, but
    I get by most of the times. Anyway.

    ...

    My last youtube endeavor was with x264. IMHO, a complete failure for youtube videos because
    YT re-encode your videos no matter how close or spot-on you are in preparing them. In fact, I
    just took one (an x264 encoded vid) off cause it was so bad. I just might consider that blank
    clip trick maybe. I don't now.

    -vhelp 4657
    Quote Quote  



Similar Threads

Visit our sponsor! Try DVDFab and backup Blu-rays!