Views: 6,860,832 Homepage | Main | Rules/FAQ | Memberlist | Active users | Last posts | Calendar | Stats | Online users | Search 04-19-24 07:01 PM
Guest:

0 users reading DS 3D: clipping notes | 1 bot

Main - Development - DS 3D: clipping notes Hide post layouts | New reply


Arisotura
Posted on 07-16-18 01:40 AM (rev. 3 of 07-16-18 02:16 AM) Link | #634
when giving a polygon a vertex with W=0: it goes through the clipping stage normally

BUT

when that vertex has a negative Y, something weird happens

like

when the segment made of it and the previous vertex is clipped

the new vertex gets a positive Y, when it should be negative

only happens with W=0. as if it were trying to use -W somewhere and it shat itself due to 0 remaining positive, causing something to get the wrong sign


observation on large W values:

W=0x1000000: polygon is 'skipped'. it's still stored in RAM, but it isn't rendered. might be W getting truncated to 24 bits later on and triggering some W=0 safeguard.

W=0x1000001: rendered, but color interpolation is unusual. value is getting truncated in some way before getting to the rasterizer.



it's probably causing overflow somewhere in the viewport transform.

W=0xFFFFFF is normal. W=0x1FFFFFF is fucked. so W is not getting truncated.

larger power-of-two values result in nothing showing up, too.

0x7FFFFFFF fucks up even more. causes bogus clipping (extra vertices stored).

0x80000001 is clipped/culled out (nothing stored).

0x2000001 to 0x40000001 are same as 0x1000001. coordinates are fine.

____________________
Kuribo64


Main - Development - DS 3D: clipping notes Hide post layouts | New reply

Page rendered in 0.029 seconds. (2048KB of memory used)
MySQL - queries: 26, rows: 73/73, time: 0.017 seconds.
[powered by Acmlm] Acmlmboard 2.064 (2018-07-20)
© 2005-2008 Acmlm, Xkeeper, blackhole89 et al.