Reducing video size with same format and reducing frame size

前端 未结 6 2307
眼角桃花
眼角桃花 2020-12-04 06:55

This question might be very basic

Is there a way to reduce the frame size/rate of Lossy compressed (WMV, MPEG) format, to get a smaller video, of lesser size, with s

6条回答
  •  难免孤独
    2020-12-04 07:34

    Instead of chosing fixed bit rates, with the H.264 codec, you can also chose a different preset as described at https://trac.ffmpeg.org/wiki/x264EncodingGuide. I also found Video encoder comparison at KeyJ's blog (archived version) an interesting read, it compares H.264 against Theora and others.

    Following is a comparison of various options I tried. The recorded video was originally 673M in size, taken on an iPad using RecordMyScreen. It has a duration of about 20 minutes with a resolution of 1024x768 (with half of the video being blank, so I cropped it to 768x768). In order to reduce size, I lowered the resolution to 480x480. There is no audio.

    The results, taking the same 1024x768 as base (and applying cropping, scaling and a filter):

    • With no special options: 95M (encoding time: 1m19s).
    • With only -b 512k added, the size dropped to 77M (encoding time: 1m17s).
    • With only -preset veryslow (and no -b), it became 70M (encoding time: 6m14s)
    • With both -b 512k and -preset veryslow, the size becomes 77M (100K smaller than just -b 512k).
    • With -preset veryslow -crf 28, I get a file of 39M which took 5m47s (with no visual quality difference to me).

    N=1, so take the results with a grain of salt and perform your own tests.

提交回复
热议问题