VideoHelp Forum




+ Reply to Thread
Results 1 to 13 of 13
  1. Hi,

    Hopefully a quick question here.

    My school uses Adobe Connect to stream Powerpoint lectures. I use the 'output/file.zip?download=zip' trick to grab the output files (.flv) and encode them into MP4 for offline viewing.

    What are the fastest x264 parameters I could use for these conversions? They are still-image Powerpoints so I am not so concerned about smooth motion and such. Below is what I'm using so far. It encodes pretty quickly, about 450-500 fps on my Surface Pro 2, but I'm just wondering if I could speed it up even further given my fairly minimal requirements.

    Code:
    -f mp4 -r 29.97 -vcodec libx264 -preset ultrafast -crf 40 -vf scale=1024:768 -aspect 4:3
    I am using WinFF because it seemed easier than compiling x264 on Windows and still allows me to use the command line.

    Thank you so much for your input.
    Last edited by paukenschlagel; 31st Oct 2014 at 09:42.
    Quote Quote  
  2. ultrafast is the fastest. Almost everything is disabled

    I know you were asking about x264 parameters, but do you really need 29.97 fps for a powerpoint presentation ? For example if you took half the frames, it would still encode at the same speed but you would finish about 2x faster
    Quote Quote  
  3. Good point. This is the kind of adjustment in efficiency I am looking for, so your comment is much appreciated.
    Quote Quote  
  4. Since you are using ffmpeg, an easy way would be to use -vf framestep. It automatically adjusts the FPS to keep sync and duration. So 29.97 source with -vf framestep=2 would select every 2nd frame (0,2,4,6...), and yield 14.985 FPS . No need to use -r. Depending on the type of ppt presentation, you might even choose a higher framestep (and finish faster)
    Quote Quote  
  5. Thank you. Yes, I just noticed the -b:v when I posted here. Thanks for catching that.
    Quote Quote  
  6. Originally Posted by paukenschlagel View Post
    Thank you. Yes, I just noticed the -b:v when I posted here. Thanks for catching that.
    LOl I deleted that comment, because I just saw you edited it before that last post
    Quote Quote  
  7. Originally Posted by poisondeathray View Post
    Since you are using ffmpeg, an easy way would be to use -vf framestep. It automatically adjusts the FPS to keep sync and duration. So 29.97 source with -vf framestep=2 would select every 2nd frame (0,2,4,6...), and yield 14.985 FPS . No need to use -r. Depending on the type of ppt presentation, you might even choose a higher framestep (and finish faster)
    Hmm, for some reason substituting -vf framestep=2 for the -r flag slows it down quite a bit. What could be missing?
    Quote Quote  
  8. Really? What are the source characteristics, fps etc...? You can use mediainfo if you don' t know
    Quote Quote  
  9. Originally Posted by poisondeathray View Post
    Really? What are the source characteristics, fps etc...? You can use mediainfo if you don' t know
    Format : Flash Video
    File size : 59.2 MiB
    _code : NetStream.Data.Start

    Video
    Format : VP6
    Codec ID : 4
    Width : 1 024 pixels
    Height : 768 pixels
    Display aspect ratio : 4:3
    Frame rate mode : Variable
    Bit depth : 8 bits
    Quote Quote  
  10. I can confirm your observations - it's counterintutive, but it is slower encoding with the filter. I don't know why. The code is probably not optimized or it's wasting time seeking. The VFR nature of the source file might be causing difficulty as well

    The avisynth version is faster (e.g. SelectEven(), or SelectEvery() for other selections), but even that isn't much faster than default (default avisynth isn't multithreaded). ffmpeg has .avs support, but there is a slight learning curve if you're not familar with avisynth

    Did you try adding -r ? Because forcing the rate seems to be slower here
    Quote Quote  
  11. Ahhh, I see. Would I have roughly the same result with -r 14.985 or would this likely lead to sync issues?
    Quote Quote  
  12. Originally Posted by paukenschlagel View Post
    Ahhh, I see. Would I have roughly the same result with -r 14.985 or would this likely lead to sync issues?
    Difficult to say, because of the VFR source (variable frame rate)

    This means some frames are displayed longer or shorter than others. In a static section, the FPS might drop down to fractional FPS's, e.g 1 frame might last a minute, instead of physically encoding 1800 frames for a 30FPS source (30 fps * 60 sec = 1800 frames). During activity, the FPS ramps up. This is great for saving bandwith, not so great if the video is meant to be edited. VFR causes many many problems when trying to edit

    Normally, when you don't force -r , ffmpeg copies timecodes over , so if source is VFR, output will use same timestamps and be VFR as well . You're probably best off not fiddling with the FPS with a VFR source, unless you need to convert it to CFR to edit it



    But eitherway, something else is going on with -vf framestep, because even on a CFR source, it encoded slower in my test
    Last edited by poisondeathray; 31st Oct 2014 at 11:26.
    Quote Quote  
  13. Gotcha. I will see what happens. Thanks again for your time.
    Quote Quote  
Visit our sponsor! Try DVDFab and backup Blu-rays!