AnimeSuki Forums

Register Forum Rules FAQ Community Today's Posts Search

Go Back   AnimeSuki Forum > Support > Tech Support

Notices

Reply
 
Thread Tools
Old 2006-10-23, 09:34   Link #1
Starks
I see what you did there!
*Scanlator
 
 
Join Date: Apr 2004
Age: 36
Send a message via AIM to Starks
Why does h.264 prefer 704x400 over 704.x396?

Just wondering.
__________________
Starks is offline   Reply With Quote
Old 2006-10-23, 10:06   Link #2
[darkfire]
Give them the What For!
*Fansubber
 
 
Join Date: Feb 2006
Location: Cave of Evil- Invite Only
Age: 36
Send a message via AIM to [darkfire] Send a message via Yahoo to [darkfire]
google it. Its something about Mod16 values
__________________
"Lepers, women are Lepers" - Sheriff of Nottingham
[darkfire] is offline   Reply With Quote
Old 2006-10-23, 10:11   Link #3
TheFluff
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.
__________________
| ffmpegsource
17:43:13 <~deculture> Also, TheFluff, you are so fucking slowpoke.jpg that people think we dropped the DVD's.
17:43:16 <~deculture> nice job, fag!

01:04:41 < Plorkyeran> it was annoying to typeset so it should be annoying to read
TheFluff is offline   Reply With Quote
Old 2006-10-23, 18:42   Link #4
Nicholi
King of Hosers
 
Join Date: Dec 2005
Age: 41
TheFluff preaches the word! And the word is good.

His religion is mod16 ya know :P.
Nicholi is offline   Reply With Quote
Old 2006-10-24, 02:00   Link #5
Zero1
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.
Zero1 is offline   Reply With Quote
Old 2006-10-24, 02:14   Link #6
Quarkboy
Translator, Producer
 
 
Join Date: Nov 2003
Location: Tokyo, Japan
Age: 44
Quote:
Originally Posted by Zero1 View Post
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.
I get the suboptimal thing... but then the question is: HOW sub optimal?

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.
__________________
Read Light Novels in English at J-Novel Club!
Translator, Producer, Japan Media Export Expert
Founder and Owner of J-Novel Club
Sam Pinansky
Quarkboy is offline   Reply With Quote
Old 2006-10-24, 03:24   Link #7
Zero1
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.
__________________
Zero1 is offline   Reply With Quote
Reply


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -5. The time now is 23:13.


Powered by vBulletin® Version 3.8.11
Copyright ©2000 - 2024, vBulletin Solutions Inc.
We use Silk.