Labels:text | screenshot | font | black and white | document OCR: VIRGE Integrated 3D Accelerator 33 Incorporated The following registers are associated with the X axis and side D1. Note that the X component of side 01 ID in Figure 15-6), is always the maximum width of the rendered triangle. Spatial Dimensions [X axis) Color Dimensions [X axis) Texture Dimensions [X axis) TdXdYC1 TdGdX_cBdX TODEX 1d/dX TdAdX_dRdx TOUAX Tď'vďx TOwdX The TXEnd12 register is associated with point E in Figure 15-6. The Taxdy12 register is associated with side 12 (F in Figure 15 6). The TbU and TbV registers contain the common offset values for the U and V texture dimensions, i.c ., these values are added to all U and V specifications. Triangles can be drawn with perspective correction bits 30-27 of the Command Set register = 0101 or 0110h. Perspective correction uses the W parameters. In addition, the U and V parameters have different bit codings when perspective correction is specified than when it is not. These are explained in the register descriptions. Using automatic perspective correction will normally cause some decrease in performance, but can in some circumstances provide dramatic increases in picture quality. 15.4.6 Z-Buffering Z-buffering allows the programmer to eliminate rendering of hidden lines and surfaces. It is enabled when bits 25-24 of the Command Set register are Dob and bits 22-20 of the Command Set register are not 000b. Use of z buffering requires that space be allocated in video memory for the z-buffer. The starting location is specified in the Z_BASE register. For each graphics pixel, the z-buffer contains a corresponding 16 bits of depth information, Bits 22-20 of the Command Set register specify the relational operator used to compare the z value of the source pixel with its corresponding z-buffer value, as follow: 000 = 2 compare never passes 001 = Pass if Zs > Zzb 010 = Pass if Zs = Zzb 011 - Pass if Zs 2 Zzb 100 - Pass if Zs < Zzb 101 = Pass if Zs # Zzb 110 = Pass if 25 < 2zb 111 = Z compare always passes For example, a setting of 110 means that the source pixel will replace the current pixel in video memory only if its source z value is less than the corresponding z-buffer value. This is the normal comparison, as it allows the pixel closer to the viewer to be drawn. If bit 23 of the Command Set register is set to 1, the source pixel z value will replace the current z-buffer value. If bit 23 of the Command Set register is cleared to 0, the z-buffer value remains unchanged. The z-buffer comparison occurs before any of the pixel coloring operations described below. If the z comparison fails, no further coloring operations will be done on that pixel. Similarly, if the operator is set to never pass, z-buffering is effectively disabled. This can improve performance. ENHANCED PROGRAMMING 15-25