2006-10-23, 10:11 | Link #3 |
Excessively jovial fellow
Join Date: Dec 2005
Location: ISDB-T
Age: 37
|
400 is evenly divisible by 16, 396 is not.
H.264 isn't any more particular about this than XviD is, really. Technically, all DCT-based codecs want widths and heights that are evenly divisible by 16 (since a DCT block is 16x16 pixels), but for some reason most of them aren't very strict with this requirement. The compression gets somewhat worse if you use a non-mod16 resolution, but apparently not many people care. Another reason to use mod-16 resolution is that non-mod16 can occasionally cause bizarre problems with the decoder; some variants seen on the CCCP playback help forums include green diagonal lines all over the picture or the edges turning weird colors. IIRC (very) early versions of x264 refused non-mod16 input altogether, but this has been fixed for a long time now.
__________________
|
2006-10-24, 02:00 | Link #5 |
Two bit encoder
Fansubber
Join Date: Jan 2006
Location: Chesterfield, UK
Age: 39
|
DCT is 8x8, 4x4 and possibly combinations of that (I don't know off hand, but I think stuff like 8x4 is feasible; unless I'm just mixing things up with the different MB sizes).
The real reason is down to macroblocks which they tend to be 16x16 at largest. You can also get smaller macroblocks, but turning off 16x16 MBs as a workaround for non mod16 is just as suboptimal, if not more, than using a non mod16 resolution with 16x16 MBs. The only saving grace is that in theory, it wouldn't "break" or be such an ugly thing. Practically every prediction based codec is more optimal with mod16, but I suppose (certain?) lossless codecs may be an exception.
__________________
Last edited by Zero1; 2006-10-24 at 02:11. |
2006-10-24, 02:14 | Link #6 | |
Translator, Producer
Join Date: Nov 2003
Location: Tokyo, Japan
Age: 44
|
Quote:
Can someone do a test? Are we talking 1% here? 0.1%? Basically, I want to know whether I should really care . Since, from what I know of x264's behavior, I believe that what it does is internally "fill out" the edge with extra pixels to make it mod 16. by mirroring the edge.
__________________
|
|
2006-10-24, 03:24 | Link #7 |
Two bit encoder
Fansubber
Join Date: Jan 2006
Location: Chesterfield, UK
Age: 39
|
I can only speculate without being able to test right now, but I would say that disabling 16x16 MBs would do more harm efficiency wise than just using 16x16 with a non mod 16 resolution. You see in areas where a 16x16 might have been fine before, it could end up using 4 8x8's instead (as an example), so that's more motion vectors.
Personally I would still use mod16, since either method results in suboptimal compression.
__________________
|
|
|