Are there any disadvantages (like worse image quality/more compression artefacts) when encoding a video in H.265 with dimensions that are not a multiple of 16 or 8, but instead a multiple of 4 or 2? For example 1920x816 vs. 1920x818.

At least in file size there seems to be no difference, as far as my tests go.

1 Answer 1


Personally I always stick to multiple of 8 but here it is:

Multiple of 4: In H.265, DCT can be done in 4x4 Transform Units, so it's not a problem for that. It can also use motion vectors for 8x4 or 4x8 Prediction Units if there is only a single reference frame, or 8x8 if there are 2 reference frames. I suspect this causes some inefficiency, but nowhere near as bad as not-divisible-by-16 was for MPEG-4.

Multiple of 2: I would not do that. Both PUs and TUs have to be padded. (I suspect it's still better than MPEG-4, just because the "bad" blocks are not that huge.) Also, what are you gaining? Cutting off 2 pixels is not going to be noticeable.

Multiple of 1: You can't even do it unless the pixel format is YUV444. Don't do it unless it's a really low resolution video, like maybe you are using it as a replacement for GIFs.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.