


If your input has a bit rate of up to 65,000 kBit/s, chances are it'll still look pretty good after conversion though. The default value here is 23, while values between 18 and 28 are considered sane. Try setting the -crf option to influence the constant quality parameter. Of course, reencoding the video will degrade its quality to some extent, given that you're applying a lossy conversion again. MediaInfo can also help you analyze container and codec details. You can check this while encoding, where x264 says something like: profile High, level 4.0 The output will have the correct profile and level set in its metadata. How can I pass the same options to it I googled and came to following command: ffmpeg -i input.mp4 -vcodec h264nvenc -rc constqp -qp 23 -acodec copy h264nvenc.mp4 But the file I get is much larger. mkv This modifies the video to 1280x720 in the output, but you can set the width and height manually if. Here we've just copied the audio stream since it won't be affected. Encoding on CPU can be done via: ffmpeg -i input.mp4 -vcodec h264 -crf 23 -acodec copy h264.mp4 GPU's alternative for the codec is h264nvenc. Ffmpeg Usage To Encode A Video To H264 Codec Format.
