VideoHelp Forum
+ Reply to Thread
Results 1 to 4 of 4
Thread
  1. I wish to convert in a single pass videos (often mpeg4 that I will crop) to x264.

    How to best achieve this with FFmpeg 1.x ?

    Quality encoding x264 : http://ffmpeg.org/trac/ffmpeg/wiki/x264EncodingGuide
    Lossless H.264
    You can use -qp 0 or -crf 0 to encode a lossless output.

    Lossless Example (fastest encoding but not best compression)

    ffmpeg -i input -c:v libx264 -preset ultrafast -qp 0 output.mkv

    Lossless Example (best compression)

    ffmpeg -i input -c:v libx264 -preset veryslow -qp 0 output.mkv
    Now, if I set -crf 0 even on a cropped video, I see the resulting output larger in Mb than the orginal!!! I have to choose something like -crf 20 to see a compression.

    What's a non trial an error method ?
    I try with preset slower only, this is good compression, but is it the best near lossless compression???
    Code:
    ffmpeg -i input -c:a copy -c:v libx264 -preset slower output.mkv
    Or should I use some bitrate specifier such as -b:v 1800k

    I'm looking for some -sameq specifier...

    Thanks.

    P.S. http://mewiki.project357.com/wiki/X264_Settings#qp
    Quote Quote  
  2. Lossless output will vastly increase the size of any video that's compressed with a lossy codec. Filtering video requires that the source be decompressed, then filtered. If you then compress with a lossless codec you will get something only a little smaller than a completely uncompressed video.
    Quote Quote  
  3. Member bat999's Avatar
    Join Date
    Feb 2008
    Location
    United Kingdom
    Search Comp PM
    Originally Posted by feelart View Post
    I'm looking for some -sameq specifier...
    Forget it.
    Quote Quote  
  4. Banned
    Join Date
    Oct 2004
    Location
    New York, US
    Search Comp PM
    You inflict even more damage by filtering with lossy compressed video. For cleanup you decompress and save with a lossless codec (or uncompressed), then re-encode when you're finished. You don't have to keep the lossless work files, just keep the final output.
    Last edited by sanlyn; 25th Mar 2014 at 03:14.
    Quote Quote  



Similar Threads