摘要 |
<p>An object's Z-buffered primitives are determined using a floating point Z = wF/W, where wF is the value the W coordinate achieves at the front clipping plane F. This representation produces Z-values ranging from 1 to APPROX 0 as W varies from W=wF to W-> INFINITY . Z-values for distances near the back clipping plane advantageously have leading zeros and are more amenable to floating point representation and exhibit less information loss. Primitive vertices are examined and the largest vertex floating point exponent is stored and associated with the entire primitive as that triangle's float point Z exponent. The stored exponent is subtracted from all the vertices' exponents and the results converted to fixed point, which format advantageously typically has few or no loading zeroes. After normal fixed point set-up and scan conversion operations occur, each pixel's final Z fixed-point value is converted back to floating point, and the relevant stored exponent for the polygon is added back in before distance comparisons are made. <IMAGE></p> |