I have been into video transcoding lately and my sole goal is to reduce video file size to the point that it does not hamper the video quality. I am comfortable with the FFmpeg tool for video transcoding tasks. I have heard that HEVC (H.265) gives better compression than H.264 video codec but when I try to transcode videos with HEVC codec my video file size does not reduce much compared to the same video transcoded with H.264 codec, is there any way to reduce video file size further with HEVC codec?
It is true that the HEVC codec gives better compression compared AVC codec. An important point is to understand that HEVC takes less bitrate compared to AVC to give the same visual quality which allows it to produce video files in lower size.
But output video file size depends a lot on the rate control method you are using to transcode your video. If you are using CRF (Constant Rate Factor) rate control method with specifying -crf option in FFmpeg, you have to set -crf value lower compared to which you are setting with H.264 codec which will allow FFmpeg to set target bitrate such that it produces video file lower in size.
Keep that in mind, when you are using the rate control method which involves specifying target bitrates such as CBR (Constant Bitrate) and VBR (Variable Bitrate). You need to set bitrate 10-15% lower than what you are setting for AVC codec which will result in 10-15% better compression with HEVC codec.
I am trying this out but why does encoding HEVC in the “Quality” option take ages?
Because HEVC is trying out new techniques to enhance quality. It will experiment with various techniques until it can minimize the file size while maintaining the highest quality possible.