• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
1 #ifndef NV20_3D_XML
2 #define NV20_3D_XML
3 
4 /* Autogenerated file, DO NOT EDIT manually!
5 
6 This file was generated by the rules-ng-ng headergen tool in this git repository:
7 http://0x04.net/cgit/index.cgi/rules-ng-ng
8 git clone git://0x04.net/rules-ng-ng
9 
10 The rules-ng-ng source files this header was generated from are:
11 - nv20_3d.xml    (  21073 bytes, from 2010-11-15 02:24:38)
12 - copyright.xml  (   6452 bytes, from 2010-11-15 15:10:58)
13 - nv10_3d.xml    (  18449 bytes, from 2010-11-15 02:24:38)
14 - nv_defs.xml    (   4437 bytes, from 2010-11-01 00:28:46)
15 - nv_3ddefs.xml  (  16394 bytes, from 2010-11-01 00:28:46)
16 - nv_object.xml  (  11547 bytes, from 2010-11-13 23:32:57)
17 - nvchipsets.xml (   3074 bytes, from 2010-11-13 23:32:57)
18 
19 Copyright (C) 2006-2010 by the following authors:
20 - Artur Huillet <arthur.huillet@free.fr> (ahuillet)
21 - Ben Skeggs (darktama, darktama_)
22 - B. R. <koala_br@users.sourceforge.net> (koala_br)
23 - Carlos Martin <carlosmn@users.sf.net> (carlosmn)
24 - Christoph Bumiller <e0425955@student.tuwien.ac.at> (calim, chrisbmr)
25 - Dawid Gajownik <gajownik@users.sf.net> (gajownik)
26 - Dmitry Baryshkov
27 - Dmitry Eremin-Solenikov <lumag@users.sf.net> (lumag)
28 - EdB <edb_@users.sf.net> (edb_)
29 - Erik Waling <erikwailing@users.sf.net> (erikwaling)
30 - Francisco Jerez <currojerez@riseup.net> (curro)
31 - imirkin <imirkin@users.sf.net> (imirkin)
32 - jb17bsome <jb17bsome@bellsouth.net> (jb17bsome)
33 - Jeremy Kolb <kjeremy@users.sf.net> (kjeremy)
34 - Laurent Carlier <lordheavym@gmail.com> (lordheavy)
35 - Luca Barbieri <luca@luca-barbieri.com> (lb, lb1)
36 - Maarten Maathuis <madman2003@gmail.com> (stillunknown)
37 - Marcin Kościelnicki <koriakin@0x04.net> (mwk, koriakin)
38 - Mark Carey <mark.carey@gmail.com> (careym)
39 - Matthieu Castet <matthieu.castet@parrot.com> (mat-c)
40 - nvidiaman <nvidiaman@users.sf.net> (nvidiaman)
41 - Patrice Mandin <patmandin@gmail.com> (pmandin, pmdata)
42 - Pekka Paalanen <pq@iki.fi> (pq, ppaalanen)
43 - Peter Popov <ironpeter@users.sf.net> (ironpeter)
44 - Richard Hughes <hughsient@users.sf.net> (hughsient)
45 - Rudi Cilibrasi <cilibrar@users.sf.net> (cilibrar)
46 - Serge Martin
47 - Simon Raffeiner
48 - Stephane Loeuillet <leroutier@users.sf.net> (leroutier)
49 - Stephane Marchesin <stephane.marchesin@gmail.com> (marcheu)
50 - sturmflut <sturmflut@users.sf.net> (sturmflut)
51 - Sylvain Munaut <tnt@246tNt.com>
52 - Victor Stinner <victor.stinner@haypocalc.com> (haypo)
53 - Wladmir van der Laan <laanwj@gmail.com> (miathan6)
54 - Younes Manton <younes.m@gmail.com> (ymanton)
55 
56 Permission is hereby granted, free of charge, to any person obtaining
57 a copy of this software and associated documentation files (the
58 "Software"), to deal in the Software without restriction, including
59 without limitation the rights to use, copy, modify, merge, publish,
60 distribute, sublicense, and/or sell copies of the Software, and to
61 permit persons to whom the Software is furnished to do so, subject to
62 the following conditions:
63 
64 The above copyright notice and this permission notice (including the
65 next paragraph) shall be included in all copies or substantial
66 portions of the Software.
67 
68 THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
69 EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
70 MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
71 IN NO EVENT SHALL THE COPYRIGHT OWNER(S) AND/OR ITS SUPPLIERS BE
72 LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
73 OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
74 WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
75 */
76 
77 
78 #define NV20_VERTEX_ATTR_POS					0x00000000
79 #define NV20_VERTEX_ATTR_NORMAL					0x00000002
80 #define NV20_VERTEX_ATTR_COLOR0					0x00000003
81 #define NV20_VERTEX_ATTR_COLOR1					0x00000004
82 #define NV20_VERTEX_ATTR_FOG					0x00000005
83 #define NV20_VERTEX_ATTR_TEX0					0x00000009
84 #define NV20_VERTEX_ATTR_TEX1					0x0000000a
85 #define NV20_VERTEX_ATTR_TEX2					0x0000000b
86 #define NV20_VERTEX_ATTR_TEX3					0x0000000c
87 
88 
89 
90 #define NV20_3D_FLIP_SET_READ					0x00000120
91 
92 #define NV20_3D_FLIP_SET_WRITE					0x00000124
93 
94 #define NV20_3D_FLIP_MAX					0x00000128
95 
96 #define NV20_3D_FLIP_INCR_WRITE					0x0000012c
97 
98 #define NV20_3D_FLIP_WAIT					0x00000130
99 
100 #define NV20_3D_DMA_NOTIFY					0x00000180
101 
102 #define NV20_3D_DMA_TEXTURE0					0x00000184
103 
104 #define NV20_3D_DMA_TEXTURE1					0x00000188
105 
106 #define NV20_3D_DMA_COLOR					0x00000194
107 
108 #define NV20_3D_DMA_ZETA					0x00000198
109 
110 #define NV20_3D_RT_HORIZ					0x00000200
111 #define NV20_3D_RT_HORIZ_X__MASK				0x0000ffff
112 #define NV20_3D_RT_HORIZ_X__SHIFT				0
113 #define NV20_3D_RT_HORIZ_W__MASK				0xffff0000
114 #define NV20_3D_RT_HORIZ_W__SHIFT				16
115 
116 #define NV20_3D_RT_VERT						0x00000204
117 #define NV20_3D_RT_VERT_Y__MASK					0x0000ffff
118 #define NV20_3D_RT_VERT_Y__SHIFT				0
119 #define NV20_3D_RT_VERT_H__MASK					0xffff0000
120 #define NV20_3D_RT_VERT_H__SHIFT				16
121 
122 #define NV20_3D_RT_FORMAT					0x00000208
123 #define NV20_3D_RT_FORMAT_TYPE__MASK				0x00000f00
124 #define NV20_3D_RT_FORMAT_TYPE__SHIFT				8
125 #define NV20_3D_RT_FORMAT_TYPE_LINEAR				0x00000100
126 #define NV20_3D_RT_FORMAT_TYPE_SWIZZLED				0x00000200
127 #define NV20_3D_RT_FORMAT_DEPTH__MASK				0x00000030
128 #define NV20_3D_RT_FORMAT_DEPTH__SHIFT				4
129 #define NV20_3D_RT_FORMAT_DEPTH_Z16				0x00000010
130 #define NV20_3D_RT_FORMAT_DEPTH_Z24S8				0x00000020
131 #define NV20_3D_RT_FORMAT_COLOR__MASK				0x0000000f
132 #define NV20_3D_RT_FORMAT_COLOR__SHIFT				0
133 #define NV20_3D_RT_FORMAT_COLOR_R5G6B5				0x00000003
134 #define NV20_3D_RT_FORMAT_COLOR_X8R8G8B8			0x00000005
135 #define NV20_3D_RT_FORMAT_COLOR_A8R8G8B8			0x00000008
136 #define NV20_3D_RT_FORMAT_COLOR_B8				0x00000009
137 
138 #define NV20_3D_RT_PITCH					0x0000020c
139 #define NV20_3D_RT_PITCH_COLOR_PITCH__MASK			0x0000ffff
140 #define NV20_3D_RT_PITCH_COLOR_PITCH__SHIFT			0
141 #define NV20_3D_RT_PITCH_ZETA_PITCH__MASK			0xffff0000
142 #define NV20_3D_RT_PITCH_ZETA_PITCH__SHIFT			16
143 
144 #define NV20_3D_COLOR_OFFSET					0x00000210
145 
146 #define NV20_3D_ZETA_OFFSET					0x00000214
147 
148 #define NV20_3D_UNK0290						0x00000290
149 
150 #define NV20_3D_VIEWPORT_CLIP_MODE				0x000002b4
151 
152 #define NV20_3D_VIEWPORT_CLIP_HORIZ(i0)			       (0x000002c0 + 0x4*(i0))
153 #define NV20_3D_VIEWPORT_CLIP_HORIZ__ESIZE			0x00000004
154 #define NV20_3D_VIEWPORT_CLIP_HORIZ__LEN			0x00000008
155 #define NV20_3D_VIEWPORT_CLIP_HORIZ_CLIP_L__MASK		0x000007ff
156 #define NV20_3D_VIEWPORT_CLIP_HORIZ_CLIP_L__SHIFT		0
157 #define NV20_3D_VIEWPORT_CLIP_HORIZ_CLIP_R__MASK		0x07ff0000
158 #define NV20_3D_VIEWPORT_CLIP_HORIZ_CLIP_R__SHIFT		16
159 
160 #define NV20_3D_VIEWPORT_CLIP_VERT(i0)			       (0x000002e0 + 0x4*(i0))
161 #define NV20_3D_VIEWPORT_CLIP_VERT__ESIZE			0x00000004
162 #define NV20_3D_VIEWPORT_CLIP_VERT__LEN				0x00000008
163 #define NV20_3D_VIEWPORT_CLIP_VERT_CLIP_T__MASK			0x000007ff
164 #define NV20_3D_VIEWPORT_CLIP_VERT_CLIP_T__SHIFT		0
165 #define NV20_3D_VIEWPORT_CLIP_VERT_CLIP_B__MASK			0x07ff0000
166 #define NV20_3D_VIEWPORT_CLIP_VERT_CLIP_B__SHIFT		16
167 
168 #define NV20_3D_ALPHA_FUNC_ENABLE				0x00000300
169 
170 #define NV20_3D_BLEND_FUNC_ENABLE				0x00000304
171 
172 #define NV20_3D_CULL_FACE_ENABLE				0x00000308
173 
174 #define NV20_3D_DEPTH_TEST_ENABLE				0x0000030c
175 
176 #define NV20_3D_DITHER_ENABLE					0x00000310
177 
178 #define NV20_3D_LIGHTING_ENABLE					0x00000314
179 
180 #define NV20_3D_POINT_PARAMETERS_ENABLE				0x00000318
181 
182 #define NV20_3D_POINT_SMOOTH_ENABLE				0x0000031c
183 
184 #define NV20_3D_LINE_SMOOTH_ENABLE				0x00000320
185 
186 #define NV20_3D_POLYGON_SMOOTH_ENABLE				0x00000324
187 
188 #define NV20_3D_STENCIL_ENABLE					0x0000032c
189 
190 #define NV20_3D_POLYGON_OFFSET_POINT_ENABLE			0x00000330
191 
192 #define NV20_3D_POLYGON_OFFSET_LINE_ENABLE			0x00000334
193 
194 #define NV20_3D_POLYGON_OFFSET_FILL_ENABLE			0x00000338
195 
196 #define NV20_3D_ALPHA_FUNC_FUNC					0x0000033c
197 #define NV20_3D_ALPHA_FUNC_FUNC_NEVER				0x00000200
198 #define NV20_3D_ALPHA_FUNC_FUNC_LESS				0x00000201
199 #define NV20_3D_ALPHA_FUNC_FUNC_EQUAL				0x00000202
200 #define NV20_3D_ALPHA_FUNC_FUNC_LEQUAL				0x00000203
201 #define NV20_3D_ALPHA_FUNC_FUNC_GREATER				0x00000204
202 #define NV20_3D_ALPHA_FUNC_FUNC_NOTEQUAL			0x00000205
203 #define NV20_3D_ALPHA_FUNC_FUNC_GEQUAL				0x00000206
204 #define NV20_3D_ALPHA_FUNC_FUNC_ALWAYS				0x00000207
205 
206 #define NV20_3D_ALPHA_FUNC_REF					0x00000340
207 
208 #define NV20_3D_BLEND_FUNC_SRC					0x00000344
209 #define NV20_3D_BLEND_FUNC_SRC_ZERO				0x00000000
210 #define NV20_3D_BLEND_FUNC_SRC_ONE				0x00000001
211 #define NV20_3D_BLEND_FUNC_SRC_SRC_COLOR			0x00000300
212 #define NV20_3D_BLEND_FUNC_SRC_ONE_MINUS_SRC_COLOR		0x00000301
213 #define NV20_3D_BLEND_FUNC_SRC_SRC_ALPHA			0x00000302
214 #define NV20_3D_BLEND_FUNC_SRC_ONE_MINUS_SRC_ALPHA		0x00000303
215 #define NV20_3D_BLEND_FUNC_SRC_DST_ALPHA			0x00000304
216 #define NV20_3D_BLEND_FUNC_SRC_ONE_MINUS_DST_ALPHA		0x00000305
217 #define NV20_3D_BLEND_FUNC_SRC_DST_COLOR			0x00000306
218 #define NV20_3D_BLEND_FUNC_SRC_ONE_MINUS_DST_COLOR		0x00000307
219 #define NV20_3D_BLEND_FUNC_SRC_SRC_ALPHA_SATURATE		0x00000308
220 #define NV20_3D_BLEND_FUNC_SRC_CONSTANT_COLOR			0x00008001
221 #define NV20_3D_BLEND_FUNC_SRC_ONE_MINUS_CONSTANT_COLOR		0x00008002
222 #define NV20_3D_BLEND_FUNC_SRC_CONSTANT_ALPHA			0x00008003
223 #define NV20_3D_BLEND_FUNC_SRC_ONE_MINUS_CONSTANT_ALPHA		0x00008004
224 
225 #define NV20_3D_BLEND_FUNC_DST					0x00000348
226 #define NV20_3D_BLEND_FUNC_DST_ZERO				0x00000000
227 #define NV20_3D_BLEND_FUNC_DST_ONE				0x00000001
228 #define NV20_3D_BLEND_FUNC_DST_SRC_COLOR			0x00000300
229 #define NV20_3D_BLEND_FUNC_DST_ONE_MINUS_SRC_COLOR		0x00000301
230 #define NV20_3D_BLEND_FUNC_DST_SRC_ALPHA			0x00000302
231 #define NV20_3D_BLEND_FUNC_DST_ONE_MINUS_SRC_ALPHA		0x00000303
232 #define NV20_3D_BLEND_FUNC_DST_DST_ALPHA			0x00000304
233 #define NV20_3D_BLEND_FUNC_DST_ONE_MINUS_DST_ALPHA		0x00000305
234 #define NV20_3D_BLEND_FUNC_DST_DST_COLOR			0x00000306
235 #define NV20_3D_BLEND_FUNC_DST_ONE_MINUS_DST_COLOR		0x00000307
236 #define NV20_3D_BLEND_FUNC_DST_SRC_ALPHA_SATURATE		0x00000308
237 #define NV20_3D_BLEND_FUNC_DST_CONSTANT_COLOR			0x00008001
238 #define NV20_3D_BLEND_FUNC_DST_ONE_MINUS_CONSTANT_COLOR		0x00008002
239 #define NV20_3D_BLEND_FUNC_DST_CONSTANT_ALPHA			0x00008003
240 #define NV20_3D_BLEND_FUNC_DST_ONE_MINUS_CONSTANT_ALPHA		0x00008004
241 
242 #define NV20_3D_BLEND_COLOR					0x0000034c
243 #define NV20_3D_BLEND_COLOR_B__MASK				0x000000ff
244 #define NV20_3D_BLEND_COLOR_B__SHIFT				0
245 #define NV20_3D_BLEND_COLOR_G__MASK				0x0000ff00
246 #define NV20_3D_BLEND_COLOR_G__SHIFT				8
247 #define NV20_3D_BLEND_COLOR_R__MASK				0x00ff0000
248 #define NV20_3D_BLEND_COLOR_R__SHIFT				16
249 #define NV20_3D_BLEND_COLOR_A__MASK				0xff000000
250 #define NV20_3D_BLEND_COLOR_A__SHIFT				24
251 
252 #define NV20_3D_BLEND_EQUATION					0x00000350
253 #define NV20_3D_BLEND_EQUATION_FUNC_ADD				0x00008006
254 #define NV20_3D_BLEND_EQUATION_MIN				0x00008007
255 #define NV20_3D_BLEND_EQUATION_MAX				0x00008008
256 #define NV20_3D_BLEND_EQUATION_FUNC_SUBTRACT			0x0000800a
257 #define NV20_3D_BLEND_EQUATION_FUNC_REVERSE_SUBTRACT		0x0000800b
258 
259 #define NV20_3D_DEPTH_FUNC					0x00000354
260 #define NV20_3D_DEPTH_FUNC_NEVER				0x00000200
261 #define NV20_3D_DEPTH_FUNC_LESS					0x00000201
262 #define NV20_3D_DEPTH_FUNC_EQUAL				0x00000202
263 #define NV20_3D_DEPTH_FUNC_LEQUAL				0x00000203
264 #define NV20_3D_DEPTH_FUNC_GREATER				0x00000204
265 #define NV20_3D_DEPTH_FUNC_NOTEQUAL				0x00000205
266 #define NV20_3D_DEPTH_FUNC_GEQUAL				0x00000206
267 #define NV20_3D_DEPTH_FUNC_ALWAYS				0x00000207
268 
269 #define NV20_3D_COLOR_MASK					0x00000358
270 #define NV20_3D_COLOR_MASK_B					0x00000001
271 #define NV20_3D_COLOR_MASK_G					0x00000100
272 #define NV20_3D_COLOR_MASK_R					0x00010000
273 #define NV20_3D_COLOR_MASK_A					0x01000000
274 
275 #define NV20_3D_DEPTH_WRITE_ENABLE				0x0000035c
276 
277 #define NV20_3D_STENCIL_MASK					0x00000360
278 
279 #define NV20_3D_STENCIL_FUNC_FUNC				0x00000364
280 #define NV20_3D_STENCIL_FUNC_FUNC_NEVER				0x00000200
281 #define NV20_3D_STENCIL_FUNC_FUNC_LESS				0x00000201
282 #define NV20_3D_STENCIL_FUNC_FUNC_EQUAL				0x00000202
283 #define NV20_3D_STENCIL_FUNC_FUNC_LEQUAL			0x00000203
284 #define NV20_3D_STENCIL_FUNC_FUNC_GREATER			0x00000204
285 #define NV20_3D_STENCIL_FUNC_FUNC_NOTEQUAL			0x00000205
286 #define NV20_3D_STENCIL_FUNC_FUNC_GEQUAL			0x00000206
287 #define NV20_3D_STENCIL_FUNC_FUNC_ALWAYS			0x00000207
288 
289 #define NV20_3D_STENCIL_FUNC_REF				0x00000368
290 
291 #define NV20_3D_STENCIL_FUNC_MASK				0x0000036c
292 
293 #define NV20_3D_STENCIL_OP_FAIL					0x00000370
294 #define NV20_3D_STENCIL_OP_FAIL_ZERO				0x00000000
295 #define NV20_3D_STENCIL_OP_FAIL_INVERT				0x0000150a
296 #define NV20_3D_STENCIL_OP_FAIL_KEEP				0x00001e00
297 #define NV20_3D_STENCIL_OP_FAIL_REPLACE				0x00001e01
298 #define NV20_3D_STENCIL_OP_FAIL_INCR				0x00001e02
299 #define NV20_3D_STENCIL_OP_FAIL_DECR				0x00001e03
300 #define NV20_3D_STENCIL_OP_FAIL_INCR_WRAP			0x00008507
301 #define NV20_3D_STENCIL_OP_FAIL_DECR_WRAP			0x00008508
302 
303 #define NV20_3D_STENCIL_OP_ZFAIL				0x00000374
304 #define NV20_3D_STENCIL_OP_ZFAIL_ZERO				0x00000000
305 #define NV20_3D_STENCIL_OP_ZFAIL_INVERT				0x0000150a
306 #define NV20_3D_STENCIL_OP_ZFAIL_KEEP				0x00001e00
307 #define NV20_3D_STENCIL_OP_ZFAIL_REPLACE			0x00001e01
308 #define NV20_3D_STENCIL_OP_ZFAIL_INCR				0x00001e02
309 #define NV20_3D_STENCIL_OP_ZFAIL_DECR				0x00001e03
310 #define NV20_3D_STENCIL_OP_ZFAIL_INCR_WRAP			0x00008507
311 #define NV20_3D_STENCIL_OP_ZFAIL_DECR_WRAP			0x00008508
312 
313 #define NV20_3D_STENCIL_OP_ZPASS				0x00000378
314 #define NV20_3D_STENCIL_OP_ZPASS_ZERO				0x00000000
315 #define NV20_3D_STENCIL_OP_ZPASS_INVERT				0x0000150a
316 #define NV20_3D_STENCIL_OP_ZPASS_KEEP				0x00001e00
317 #define NV20_3D_STENCIL_OP_ZPASS_REPLACE			0x00001e01
318 #define NV20_3D_STENCIL_OP_ZPASS_INCR				0x00001e02
319 #define NV20_3D_STENCIL_OP_ZPASS_DECR				0x00001e03
320 #define NV20_3D_STENCIL_OP_ZPASS_INCR_WRAP			0x00008507
321 #define NV20_3D_STENCIL_OP_ZPASS_DECR_WRAP			0x00008508
322 
323 #define NV20_3D_SHADE_MODEL					0x0000037c
324 #define NV20_3D_SHADE_MODEL_FLAT				0x00001d00
325 #define NV20_3D_SHADE_MODEL_SMOOTH				0x00001d01
326 
327 #define NV20_3D_LINE_WIDTH					0x00000380
328 
329 #define NV20_3D_POLYGON_OFFSET_FACTOR				0x00000384
330 
331 #define NV20_3D_POLYGON_OFFSET_UNITS				0x00000388
332 
333 #define NV20_3D_POLYGON_MODE_FRONT				0x0000038c
334 #define NV20_3D_POLYGON_MODE_FRONT_POINT			0x00001b00
335 #define NV20_3D_POLYGON_MODE_FRONT_LINE				0x00001b01
336 #define NV20_3D_POLYGON_MODE_FRONT_FILL				0x00001b02
337 
338 #define NV20_3D_POLYGON_MODE_BACK				0x00000390
339 #define NV20_3D_POLYGON_MODE_BACK_POINT				0x00001b00
340 #define NV20_3D_POLYGON_MODE_BACK_LINE				0x00001b01
341 #define NV20_3D_POLYGON_MODE_BACK_FILL				0x00001b02
342 
343 #define NV20_3D_DEPTH_RANGE_NEAR				0x00000394
344 
345 #define NV20_3D_DEPTH_RANGE_FAR					0x00000398
346 
347 #define NV20_3D_CULL_FACE					0x0000039c
348 #define NV20_3D_CULL_FACE_FRONT					0x00000404
349 #define NV20_3D_CULL_FACE_BACK					0x00000405
350 #define NV20_3D_CULL_FACE_FRONT_AND_BACK			0x00000408
351 
352 #define NV20_3D_FRONT_FACE					0x000003a0
353 #define NV20_3D_FRONT_FACE_CW					0x00000900
354 #define NV20_3D_FRONT_FACE_CCW					0x00000901
355 
356 #define NV20_3D_DMA_FENCE					0x000001a4
357 
358 #define NV20_3D_DMA_QUERY					0x000001a8
359 
360 
361 #define NV20_3D_VERTEX_POS_3F					0x00001500
362 
363 
364 #define NV20_3D_VERTEX_POS_3F_X					0x00001500
365 
366 #define NV20_3D_VERTEX_POS_3F_Y					0x00001504
367 
368 #define NV20_3D_VERTEX_POS_3F_Z					0x00001508
369 
370 #define NV20_3D_VERTEX_POS_4F					0x00001518
371 
372 
373 #define NV20_3D_VERTEX_POS_4F_X					0x00001518
374 
375 #define NV20_3D_VERTEX_POS_4F_Y					0x0000151c
376 
377 #define NV20_3D_VERTEX_POS_4F_Z					0x00001520
378 
379 #define NV20_3D_VERTEX_POS_4F_W					0x00001524
380 
381 #define NV20_3D_VERTEX_POS_3I					0x00001528
382 
383 
384 #define NV20_3D_VERTEX_POS_3I_XY				0x00001528
385 #define NV20_3D_VERTEX_POS_3I_XY_X__MASK			0x0000ffff
386 #define NV20_3D_VERTEX_POS_3I_XY_X__SHIFT			0
387 #define NV20_3D_VERTEX_POS_3I_XY_Y__MASK			0xffff0000
388 #define NV20_3D_VERTEX_POS_3I_XY_Y__SHIFT			16
389 
390 #define NV20_3D_VERTEX_POS_3I_Z					0x0000152c
391 #define NV20_3D_VERTEX_POS_3I_Z_Z__MASK				0x0000ffff
392 #define NV20_3D_VERTEX_POS_3I_Z_Z__SHIFT			0
393 
394 #define NV20_3D_VERTEX_NOR_3F					0x00001530
395 
396 
397 #define NV20_3D_VERTEX_NOR_3F_X					0x00001530
398 
399 #define NV20_3D_VERTEX_NOR_3F_Y					0x00001534
400 
401 #define NV20_3D_VERTEX_NOR_3F_Z					0x00001538
402 
403 #define NV20_3D_VERTEX_NOR_3I					0x00001540
404 
405 
406 #define NV20_3D_VERTEX_NOR_3I_XY				0x00001540
407 #define NV20_3D_VERTEX_NOR_3I_XY_X__MASK			0x0000ffff
408 #define NV20_3D_VERTEX_NOR_3I_XY_X__SHIFT			0
409 #define NV20_3D_VERTEX_NOR_3I_XY_Y__MASK			0xffff0000
410 #define NV20_3D_VERTEX_NOR_3I_XY_Y__SHIFT			16
411 
412 #define NV20_3D_VERTEX_NOR_3I_Z					0x00001544
413 #define NV20_3D_VERTEX_NOR_3I_Z_Z__MASK				0x0000ffff
414 #define NV20_3D_VERTEX_NOR_3I_Z_Z__SHIFT			0
415 
416 #define NV20_3D_VERTEX_COL_4F					0x00001550
417 
418 
419 #define NV20_3D_VERTEX_COL_4F_R					0x00001550
420 
421 #define NV20_3D_VERTEX_COL_4F_G					0x00001554
422 
423 #define NV20_3D_VERTEX_COL_4F_B					0x00001558
424 
425 #define NV20_3D_VERTEX_COL_4F_A					0x0000155c
426 
427 #define NV20_3D_VERTEX_COL_3F					0x00001560
428 
429 
430 #define NV20_3D_VERTEX_COL_3F_R					0x00001560
431 
432 #define NV20_3D_VERTEX_COL_3F_G					0x00001564
433 
434 #define NV20_3D_VERTEX_COL_3F_B					0x00001568
435 
436 #define NV20_3D_VERTEX_COL_4I					0x0000156c
437 #define NV20_3D_VERTEX_COL_4I_R__MASK				0x000000ff
438 #define NV20_3D_VERTEX_COL_4I_R__SHIFT				0
439 #define NV20_3D_VERTEX_COL_4I_G__MASK				0x0000ff00
440 #define NV20_3D_VERTEX_COL_4I_G__SHIFT				8
441 #define NV20_3D_VERTEX_COL_4I_B__MASK				0x00ff0000
442 #define NV20_3D_VERTEX_COL_4I_B__SHIFT				16
443 #define NV20_3D_VERTEX_COL_4I_A__MASK				0xff000000
444 #define NV20_3D_VERTEX_COL_4I_A__SHIFT				24
445 
446 #define NV20_3D_VERTEX_COL2_3F					0x00001580
447 
448 
449 #define NV20_3D_VERTEX_COL2_3F_R				0x00001580
450 
451 #define NV20_3D_VERTEX_COL2_3F_G				0x00001584
452 
453 #define NV20_3D_VERTEX_COL2_3F_B				0x00001588
454 
455 #define NV20_3D_VERTEX_COL2_3I					0x0000158c
456 #define NV20_3D_VERTEX_COL2_3I_R__MASK				0x000000ff
457 #define NV20_3D_VERTEX_COL2_3I_R__SHIFT				0
458 #define NV20_3D_VERTEX_COL2_3I_G__MASK				0x0000ff00
459 #define NV20_3D_VERTEX_COL2_3I_G__SHIFT				8
460 #define NV20_3D_VERTEX_COL2_3I_B__MASK				0x00ff0000
461 #define NV20_3D_VERTEX_COL2_3I_B__SHIFT				16
462 
463 #define NV20_3D_VERTEX_TX0_2F					0x00001590
464 
465 
466 #define NV20_3D_VERTEX_TX0_2F_S					0x00001590
467 
468 #define NV20_3D_VERTEX_TX0_2F_T					0x00001594
469 
470 #define NV20_3D_VERTEX_TX0_2I					0x00001598
471 #define NV20_3D_VERTEX_TX0_2I_S__MASK				0x0000ffff
472 #define NV20_3D_VERTEX_TX0_2I_S__SHIFT				0
473 #define NV20_3D_VERTEX_TX0_2I_T__MASK				0xffff0000
474 #define NV20_3D_VERTEX_TX0_2I_T__SHIFT				16
475 
476 #define NV20_3D_VERTEX_TX0_4F					0x000015a0
477 
478 
479 #define NV20_3D_VERTEX_TX0_4F_S					0x000015a0
480 
481 #define NV20_3D_VERTEX_TX0_4F_T					0x000015a4
482 
483 #define NV20_3D_VERTEX_TX0_4F_R					0x000015a8
484 
485 #define NV20_3D_VERTEX_TX0_4F_Q					0x000015ac
486 
487 #define NV20_3D_VERTEX_TX0_4I					0x000015b0
488 
489 
490 #define NV20_3D_VERTEX_TX0_4I_ST				0x000015b0
491 #define NV20_3D_VERTEX_TX0_4I_ST_S__MASK			0x0000ffff
492 #define NV20_3D_VERTEX_TX0_4I_ST_S__SHIFT			0
493 #define NV20_3D_VERTEX_TX0_4I_ST_T__MASK			0xffff0000
494 #define NV20_3D_VERTEX_TX0_4I_ST_T__SHIFT			16
495 
496 #define NV20_3D_VERTEX_TX0_4I_RQ				0x000015b4
497 #define NV20_3D_VERTEX_TX0_4I_RQ_R__MASK			0x0000ffff
498 #define NV20_3D_VERTEX_TX0_4I_RQ_R__SHIFT			0
499 #define NV20_3D_VERTEX_TX0_4I_RQ_Q__MASK			0xffff0000
500 #define NV20_3D_VERTEX_TX0_4I_RQ_Q__SHIFT			16
501 
502 #define NV20_3D_VERTEX_TX1_2F					0x000015b8
503 
504 
505 #define NV20_3D_VERTEX_TX1_2F_S					0x000015b8
506 
507 #define NV20_3D_VERTEX_TX1_2F_T					0x000015bc
508 
509 #define NV20_3D_VERTEX_TX1_2I					0x000015c0
510 #define NV20_3D_VERTEX_TX1_2I_S__MASK				0x0000ffff
511 #define NV20_3D_VERTEX_TX1_2I_S__SHIFT				0
512 #define NV20_3D_VERTEX_TX1_2I_T__MASK				0xffff0000
513 #define NV20_3D_VERTEX_TX1_2I_T__SHIFT				16
514 
515 #define NV20_3D_VERTEX_TX1_4F					0x000015c8
516 
517 
518 #define NV20_3D_VERTEX_TX1_4F_S					0x000015c8
519 
520 #define NV20_3D_VERTEX_TX1_4F_T					0x000015cc
521 
522 #define NV20_3D_VERTEX_TX1_4F_R					0x000015d0
523 
524 #define NV20_3D_VERTEX_TX1_4F_Q					0x000015d4
525 
526 #define NV20_3D_VERTEX_TX1_4I					0x000015d8
527 
528 
529 #define NV20_3D_VERTEX_TX1_4I_ST				0x000015d8
530 #define NV20_3D_VERTEX_TX1_4I_ST_S__MASK			0x0000ffff
531 #define NV20_3D_VERTEX_TX1_4I_ST_S__SHIFT			0
532 #define NV20_3D_VERTEX_TX1_4I_ST_T__MASK			0xffff0000
533 #define NV20_3D_VERTEX_TX1_4I_ST_T__SHIFT			16
534 
535 #define NV20_3D_VERTEX_TX1_4I_RQ				0x000015dc
536 #define NV20_3D_VERTEX_TX1_4I_RQ_R__MASK			0x0000ffff
537 #define NV20_3D_VERTEX_TX1_4I_RQ_R__SHIFT			0
538 #define NV20_3D_VERTEX_TX1_4I_RQ_Q__MASK			0xffff0000
539 #define NV20_3D_VERTEX_TX1_4I_RQ_Q__SHIFT			16
540 
541 #define NV20_3D_VERTEX_TX2_2F					0x000015e0
542 
543 
544 #define NV20_3D_VERTEX_TX2_2F_S					0x000015e0
545 
546 #define NV20_3D_VERTEX_TX2_2F_T					0x000015e4
547 
548 #define NV20_3D_VERTEX_TX2_2I					0x000015e8
549 #define NV20_3D_VERTEX_TX2_2I_S__MASK				0x0000ffff
550 #define NV20_3D_VERTEX_TX2_2I_S__SHIFT				0
551 #define NV20_3D_VERTEX_TX2_2I_T__MASK				0xffff0000
552 #define NV20_3D_VERTEX_TX2_2I_T__SHIFT				16
553 
554 #define NV20_3D_VERTEX_TX2_4F					0x000015f0
555 
556 
557 #define NV20_3D_VERTEX_TX2_4F_S					0x000015f0
558 
559 #define NV20_3D_VERTEX_TX2_4F_T					0x000015f4
560 
561 #define NV20_3D_VERTEX_TX2_4F_R					0x000015f8
562 
563 #define NV20_3D_VERTEX_TX2_4F_Q					0x000015fc
564 
565 #define NV20_3D_VERTEX_TX2_4I					0x00001600
566 
567 
568 #define NV20_3D_VERTEX_TX2_4I_ST				0x00001600
569 #define NV20_3D_VERTEX_TX2_4I_ST_S__MASK			0x0000ffff
570 #define NV20_3D_VERTEX_TX2_4I_ST_S__SHIFT			0
571 #define NV20_3D_VERTEX_TX2_4I_ST_T__MASK			0xffff0000
572 #define NV20_3D_VERTEX_TX2_4I_ST_T__SHIFT			16
573 
574 #define NV20_3D_VERTEX_TX2_4I_RQ				0x00001604
575 #define NV20_3D_VERTEX_TX2_4I_RQ_R__MASK			0x0000ffff
576 #define NV20_3D_VERTEX_TX2_4I_RQ_R__SHIFT			0
577 #define NV20_3D_VERTEX_TX2_4I_RQ_Q__MASK			0xffff0000
578 #define NV20_3D_VERTEX_TX2_4I_RQ_Q__SHIFT			16
579 
580 #define NV20_3D_VERTEX_TX3_2F					0x00001608
581 
582 
583 #define NV20_3D_VERTEX_TX3_2F_S					0x00001608
584 
585 #define NV20_3D_VERTEX_TX3_2F_T					0x0000160c
586 
587 #define NV20_3D_VERTEX_TX3_2I					0x00001610
588 #define NV20_3D_VERTEX_TX3_2I_S__MASK				0x0000ffff
589 #define NV20_3D_VERTEX_TX3_2I_S__SHIFT				0
590 #define NV20_3D_VERTEX_TX3_2I_T__MASK				0xffff0000
591 #define NV20_3D_VERTEX_TX3_2I_T__SHIFT				16
592 
593 #define NV20_3D_VERTEX_TX3_4F					0x00001620
594 
595 
596 #define NV20_3D_VERTEX_TX3_4F_S					0x00001620
597 
598 #define NV20_3D_VERTEX_TX3_4F_T					0x00001624
599 
600 #define NV20_3D_VERTEX_TX3_4F_R					0x00001628
601 
602 #define NV20_3D_VERTEX_TX3_4F_Q					0x0000162c
603 
604 #define NV20_3D_VERTEX_TX3_4I					0x00001630
605 
606 
607 #define NV20_3D_VERTEX_TX3_4I_ST				0x00001630
608 #define NV20_3D_VERTEX_TX3_4I_ST_S__MASK			0x0000ffff
609 #define NV20_3D_VERTEX_TX3_4I_ST_S__SHIFT			0
610 #define NV20_3D_VERTEX_TX3_4I_ST_T__MASK			0xffff0000
611 #define NV20_3D_VERTEX_TX3_4I_ST_T__SHIFT			16
612 
613 #define NV20_3D_VERTEX_TX3_4I_RQ				0x00001634
614 #define NV20_3D_VERTEX_TX3_4I_RQ_R__MASK			0x0000ffff
615 #define NV20_3D_VERTEX_TX3_4I_RQ_R__SHIFT			0
616 #define NV20_3D_VERTEX_TX3_4I_RQ_Q__MASK			0xffff0000
617 #define NV20_3D_VERTEX_TX3_4I_RQ_Q__SHIFT			16
618 
619 #define NV20_3D_VERTEX_FOG_1F					0x00001698
620 
621 #define NV20_3D_EDGEFLAG_ENABLE					0x000016bc
622 
623 #define NV20_3D_VERTEX_ATTR_4F(i0)			       (0x00001a00 + 0x10*(i0))
624 #define NV20_3D_VERTEX_ATTR_4F__ESIZE				0x00000010
625 #define NV20_3D_VERTEX_ATTR_4F__LEN				0x00000010
626 
627 
628 #define NV20_3D_VERTEX_ATTR_4F_X(i0)			       (0x00001a00 + 0x10*(i0))
629 
630 #define NV20_3D_VERTEX_ATTR_4F_Y(i0)			       (0x00001a04 + 0x10*(i0))
631 
632 #define NV20_3D_VERTEX_ATTR_4F_Z(i0)			       (0x00001a08 + 0x10*(i0))
633 
634 #define NV20_3D_VERTEX_ATTR_4F_W(i0)			       (0x00001a0c + 0x10*(i0))
635 
636 
637 #define NV20_3D_DMA_VTXBUF0					0x0000019c
638 
639 #define NV20_3D_DMA_VTXBUF1					0x000001a0
640 
641 #define NV20_3D_VTXBUF_VALIDATE					0x00001710
642 
643 
644 #define NV20_3D_VTXBUF_OFFSET(i0)			       (0x00001720 + 0x4*(i0))
645 #define NV20_3D_VTXBUF_OFFSET_DMA1				0x80000000
646 #define NV20_3D_VTXBUF_OFFSET_OFFSET__MASK			0x0fffffff
647 #define NV20_3D_VTXBUF_OFFSET_OFFSET__SHIFT			0
648 
649 #define NV20_3D_VTXBUF_FMT(i0)				       (0x00001760 + 0x4*(i0))
650 #define NV20_3D_VTXBUF_FMT_TYPE__MASK				0x0000000f
651 #define NV20_3D_VTXBUF_FMT_TYPE__SHIFT				0
652 #define NV20_3D_VTXBUF_FMT_TYPE_FLOAT				0x00000002
653 #define NV20_3D_VTXBUF_FMT_TYPE_UBYTE				0x00000004
654 #define NV20_3D_VTXBUF_FMT_TYPE_USHORT				0x00000005
655 #define NV20_3D_VTXBUF_FMT_SIZE__MASK				0x000000f0
656 #define NV20_3D_VTXBUF_FMT_SIZE__SHIFT				4
657 #define NV20_3D_VTXBUF_FMT_STRIDE__MASK				0x0000ff00
658 #define NV20_3D_VTXBUF_FMT_STRIDE__SHIFT			8
659 
660 #define NV20_3D_VERTEX_BEGIN_END				0x000017fc
661 #define NV20_3D_VERTEX_BEGIN_END_STOP				0x00000000
662 #define NV20_3D_VERTEX_BEGIN_END_POINTS				0x00000001
663 #define NV20_3D_VERTEX_BEGIN_END_LINES				0x00000002
664 #define NV20_3D_VERTEX_BEGIN_END_LINE_LOOP			0x00000003
665 #define NV20_3D_VERTEX_BEGIN_END_LINE_STRIP			0x00000004
666 #define NV20_3D_VERTEX_BEGIN_END_TRIANGLES			0x00000005
667 #define NV20_3D_VERTEX_BEGIN_END_TRIANGLE_STRIP			0x00000006
668 #define NV20_3D_VERTEX_BEGIN_END_TRIANGLE_FAN			0x00000007
669 #define NV20_3D_VERTEX_BEGIN_END_QUADS				0x00000008
670 #define NV20_3D_VERTEX_BEGIN_END_QUAD_STRIP			0x00000009
671 #define NV20_3D_VERTEX_BEGIN_END_POLYGON			0x0000000a
672 
673 #define NV20_3D_VTXBUF_ELEMENT_U16				0x00001800
674 #define NV20_3D_VTXBUF_ELEMENT_U16_I0__MASK			0x0000ffff
675 #define NV20_3D_VTXBUF_ELEMENT_U16_I0__SHIFT			0
676 #define NV20_3D_VTXBUF_ELEMENT_U16_I1__MASK			0xffff0000
677 #define NV20_3D_VTXBUF_ELEMENT_U16_I1__SHIFT			16
678 
679 #define NV20_3D_VTXBUF_ELEMENT_U32				0x00001808
680 
681 #define NV20_3D_VTXBUF_BATCH					0x00001810
682 #define NV20_3D_VTXBUF_BATCH_OFFSET__MASK			0x00ffffff
683 #define NV20_3D_VTXBUF_BATCH_OFFSET__SHIFT			0
684 #define NV20_3D_VTXBUF_BATCH_COUNT__MASK			0xff000000
685 #define NV20_3D_VTXBUF_BATCH_COUNT__SHIFT			24
686 
687 #define NV20_3D_VTXBUF_DATA					0x00001818
688 
689 
690 #define NV20_3D_ENGINE						0x00001e94
691 #define NV20_3D_ENGINE_VP					0x00000002
692 #define NV20_3D_ENGINE_FIXED					0x00000004
693 
694 #define NV20_3D_VP_UPLOAD_INST(i0)			       (0x00000b00 + 0x4*(i0))
695 #define NV20_3D_VP_UPLOAD_INST__ESIZE				0x00000004
696 #define NV20_3D_VP_UPLOAD_INST__LEN				0x00000004
697 
698 #define NV20_3D_VP_UPLOAD_CONST(i0)			       (0x00000b80 + 0x4*(i0))
699 #define NV20_3D_VP_UPLOAD_CONST__ESIZE				0x00000004
700 #define NV20_3D_VP_UPLOAD_CONST__LEN				0x00000004
701 
702 #define NV20_3D_VP_UPLOAD_FROM_ID				0x00001e9c
703 
704 #define NV20_3D_VP_START_FROM_ID				0x00001ea0
705 
706 #define NV20_3D_VP_UPLOAD_CONST_ID				0x00001ea4
707 
708 
709 
710 #define NV20_3D_MODELVIEW_MATRIX(i0, i1)		       (0x00000480 + 0x40*(i0) + 0x4*(i1))
711 #define NV20_3D_MODELVIEW_MATRIX__ESIZE				0x00000004
712 #define NV20_3D_MODELVIEW_MATRIX__LEN				0x00000010
713 
714 #define NV20_3D_INVERSE_MODELVIEW_MATRIX(i0, i1)	       (0x00000580 + 0x40*(i0) + 0x4*(i1))
715 #define NV20_3D_INVERSE_MODELVIEW_MATRIX__ESIZE			0x00000004
716 #define NV20_3D_INVERSE_MODELVIEW_MATRIX__LEN			0x00000010
717 
718 #define NV20_3D_PROJECTION_MATRIX(i0)			       (0x00000680 + 0x4*(i0))
719 #define NV20_3D_PROJECTION_MATRIX__ESIZE			0x00000004
720 #define NV20_3D_PROJECTION_MATRIX__LEN				0x00000010
721 
722 #define NV20_3D_VIEWPORT_TRANSLATE				0x00000a20
723 
724 
725 #define NV20_3D_VIEWPORT_TRANSLATE_X				0x00000a20
726 
727 #define NV20_3D_VIEWPORT_TRANSLATE_Y				0x00000a24
728 
729 #define NV20_3D_VIEWPORT_TRANSLATE_Z				0x00000a28
730 
731 #define NV20_3D_VIEWPORT_TRANSLATE_W				0x00000a2c
732 
733 #define NV20_3D_VIEWPORT_SCALE					0x00000af0
734 
735 
736 #define NV20_3D_VIEWPORT_SCALE_X				0x00000af0
737 
738 #define NV20_3D_VIEWPORT_SCALE_Y				0x00000af4
739 
740 #define NV20_3D_VIEWPORT_SCALE_Z				0x00000af8
741 
742 #define NV20_3D_VIEWPORT_SCALE_W				0x00000afc
743 
744 
745 #define NV20_3D_NORMALIZE_ENABLE				0x000003a4
746 
747 #define NV20_3D_SEPARATE_SPECULAR_ENABLE			0x000003b8
748 
749 #define NV20_3D_LIGHT_MODEL_TWO_SIDE_ENABLE			0x000017c4
750 
751 #define NV20_3D_LIGHT_MODEL					0x00000294
752 #define NV20_3D_LIGHT_MODEL_VIEWER__MASK			0x00030000
753 #define NV20_3D_LIGHT_MODEL_VIEWER__SHIFT			16
754 #define NV20_3D_LIGHT_MODEL_VIEWER_NONLOCAL			0x00020000
755 #define NV20_3D_LIGHT_MODEL_VIEWER_LOCAL			0x00030000
756 #define NV20_3D_LIGHT_MODEL_SEPARATE_SPECULAR			0x00000001
757 
758 #define NV20_3D_ENABLED_LIGHTS					0x000003bc
759 #define NV20_3D_ENABLED_LIGHTS_0__MASK				0x00000003
760 #define NV20_3D_ENABLED_LIGHTS_0__SHIFT				0
761 #define NV20_3D_ENABLED_LIGHTS_0_DISABLED			0x00000000
762 #define NV20_3D_ENABLED_LIGHTS_0_NONPOSITIONAL			0x00000001
763 #define NV20_3D_ENABLED_LIGHTS_0_POSITIONAL			0x00000002
764 #define NV20_3D_ENABLED_LIGHTS_0_DIRECTIONAL			0x00000003
765 #define NV20_3D_ENABLED_LIGHTS_1__MASK				0x0000000c
766 #define NV20_3D_ENABLED_LIGHTS_1__SHIFT				2
767 #define NV20_3D_ENABLED_LIGHTS_1_DISABLED			0x00000000
768 #define NV20_3D_ENABLED_LIGHTS_1_NONPOSITIONAL			0x00000004
769 #define NV20_3D_ENABLED_LIGHTS_1_POSITIONAL			0x00000008
770 #define NV20_3D_ENABLED_LIGHTS_1_DIRECTIONAL			0x0000000c
771 #define NV20_3D_ENABLED_LIGHTS_2__MASK				0x00000030
772 #define NV20_3D_ENABLED_LIGHTS_2__SHIFT				4
773 #define NV20_3D_ENABLED_LIGHTS_2_DISABLED			0x00000000
774 #define NV20_3D_ENABLED_LIGHTS_2_NONPOSITIONAL			0x00000010
775 #define NV20_3D_ENABLED_LIGHTS_2_POSITIONAL			0x00000020
776 #define NV20_3D_ENABLED_LIGHTS_2_DIRECTIONAL			0x00000030
777 #define NV20_3D_ENABLED_LIGHTS_3__MASK				0x000000c0
778 #define NV20_3D_ENABLED_LIGHTS_3__SHIFT				6
779 #define NV20_3D_ENABLED_LIGHTS_3_DISABLED			0x00000000
780 #define NV20_3D_ENABLED_LIGHTS_3_NONPOSITIONAL			0x00000040
781 #define NV20_3D_ENABLED_LIGHTS_3_POSITIONAL			0x00000080
782 #define NV20_3D_ENABLED_LIGHTS_3_DIRECTIONAL			0x000000c0
783 #define NV20_3D_ENABLED_LIGHTS_4__MASK				0x00000300
784 #define NV20_3D_ENABLED_LIGHTS_4__SHIFT				8
785 #define NV20_3D_ENABLED_LIGHTS_4_DISABLED			0x00000000
786 #define NV20_3D_ENABLED_LIGHTS_4_NONPOSITIONAL			0x00000100
787 #define NV20_3D_ENABLED_LIGHTS_4_POSITIONAL			0x00000200
788 #define NV20_3D_ENABLED_LIGHTS_4_DIRECTIONAL			0x00000300
789 #define NV20_3D_ENABLED_LIGHTS_5__MASK				0x00000c00
790 #define NV20_3D_ENABLED_LIGHTS_5__SHIFT				10
791 #define NV20_3D_ENABLED_LIGHTS_5_DISABLED			0x00000000
792 #define NV20_3D_ENABLED_LIGHTS_5_NONPOSITIONAL			0x00000400
793 #define NV20_3D_ENABLED_LIGHTS_5_POSITIONAL			0x00000800
794 #define NV20_3D_ENABLED_LIGHTS_5_DIRECTIONAL			0x00000c00
795 #define NV20_3D_ENABLED_LIGHTS_6__MASK				0x00003000
796 #define NV20_3D_ENABLED_LIGHTS_6__SHIFT				12
797 #define NV20_3D_ENABLED_LIGHTS_6_DISABLED			0x00000000
798 #define NV20_3D_ENABLED_LIGHTS_6_NONPOSITIONAL			0x00001000
799 #define NV20_3D_ENABLED_LIGHTS_6_POSITIONAL			0x00002000
800 #define NV20_3D_ENABLED_LIGHTS_6_DIRECTIONAL			0x00003000
801 #define NV20_3D_ENABLED_LIGHTS_7__MASK				0x0000c000
802 #define NV20_3D_ENABLED_LIGHTS_7__SHIFT				14
803 #define NV20_3D_ENABLED_LIGHTS_7_DISABLED			0x00000000
804 #define NV20_3D_ENABLED_LIGHTS_7_NONPOSITIONAL			0x00004000
805 #define NV20_3D_ENABLED_LIGHTS_7_POSITIONAL			0x00008000
806 #define NV20_3D_ENABLED_LIGHTS_7_DIRECTIONAL			0x0000c000
807 
808 #define NV20_3D_COLOR_MATERIAL					0x00000298
809 #define NV20_3D_COLOR_MATERIAL_FRONT_EMISSION__MASK		0x00000003
810 #define NV20_3D_COLOR_MATERIAL_FRONT_EMISSION__SHIFT		0
811 #define NV20_3D_COLOR_MATERIAL_FRONT_EMISSION_OFF		0x00000000
812 #define NV20_3D_COLOR_MATERIAL_FRONT_EMISSION_COL1		0x00000001
813 #define NV20_3D_COLOR_MATERIAL_FRONT_EMISSION_COL2		0x00000002
814 #define NV20_3D_COLOR_MATERIAL_FRONT_AMBIENT__MASK		0x0000000c
815 #define NV20_3D_COLOR_MATERIAL_FRONT_AMBIENT__SHIFT		2
816 #define NV20_3D_COLOR_MATERIAL_FRONT_AMBIENT_OFF		0x00000000
817 #define NV20_3D_COLOR_MATERIAL_FRONT_AMBIENT_COL1		0x00000004
818 #define NV20_3D_COLOR_MATERIAL_FRONT_AMBIENT_COL2		0x00000008
819 #define NV20_3D_COLOR_MATERIAL_FRONT_DIFFUSE__MASK		0x00000030
820 #define NV20_3D_COLOR_MATERIAL_FRONT_DIFFUSE__SHIFT		4
821 #define NV20_3D_COLOR_MATERIAL_FRONT_DIFFUSE_OFF		0x00000000
822 #define NV20_3D_COLOR_MATERIAL_FRONT_DIFFUSE_COL1		0x00000010
823 #define NV20_3D_COLOR_MATERIAL_FRONT_DIFFUSE_COL2		0x00000020
824 #define NV20_3D_COLOR_MATERIAL_FRONT_SPECULAR__MASK		0x000000c0
825 #define NV20_3D_COLOR_MATERIAL_FRONT_SPECULAR__SHIFT		6
826 #define NV20_3D_COLOR_MATERIAL_FRONT_SPECULAR_OFF		0x00000000
827 #define NV20_3D_COLOR_MATERIAL_FRONT_SPECULAR_COL1		0x00000040
828 #define NV20_3D_COLOR_MATERIAL_FRONT_SPECULAR_COL2		0x00000080
829 #define NV20_3D_COLOR_MATERIAL_BACK_EMISSION__MASK		0x00000300
830 #define NV20_3D_COLOR_MATERIAL_BACK_EMISSION__SHIFT		8
831 #define NV20_3D_COLOR_MATERIAL_BACK_EMISSION_OFF		0x00000000
832 #define NV20_3D_COLOR_MATERIAL_BACK_EMISSION_COL1		0x00000100
833 #define NV20_3D_COLOR_MATERIAL_BACK_EMISSION_COL2		0x00000200
834 #define NV20_3D_COLOR_MATERIAL_BACK_AMBIENT__MASK		0x00000c00
835 #define NV20_3D_COLOR_MATERIAL_BACK_AMBIENT__SHIFT		10
836 #define NV20_3D_COLOR_MATERIAL_BACK_AMBIENT_OFF			0x00000000
837 #define NV20_3D_COLOR_MATERIAL_BACK_AMBIENT_COL1		0x00000400
838 #define NV20_3D_COLOR_MATERIAL_BACK_AMBIENT_COL2		0x00000800
839 #define NV20_3D_COLOR_MATERIAL_BACK_DIFFUSE__MASK		0x00003000
840 #define NV20_3D_COLOR_MATERIAL_BACK_DIFFUSE__SHIFT		12
841 #define NV20_3D_COLOR_MATERIAL_BACK_DIFFUSE_OFF			0x00000000
842 #define NV20_3D_COLOR_MATERIAL_BACK_DIFFUSE_COL1		0x00001000
843 #define NV20_3D_COLOR_MATERIAL_BACK_DIFFUSE_COL2		0x00002000
844 #define NV20_3D_COLOR_MATERIAL_BACK_SPECULAR__MASK		0x0000c000
845 #define NV20_3D_COLOR_MATERIAL_BACK_SPECULAR__SHIFT		14
846 #define NV20_3D_COLOR_MATERIAL_BACK_SPECULAR_OFF		0x00000000
847 #define NV20_3D_COLOR_MATERIAL_BACK_SPECULAR_COL1		0x00004000
848 #define NV20_3D_COLOR_MATERIAL_BACK_SPECULAR_COL2		0x00008000
849 
850 #define NV20_3D_MATERIAL_FACTOR_FRONT				0x000003a8
851 
852 
853 #define NV20_3D_MATERIAL_FACTOR_FRONT_R				0x000003a8
854 
855 #define NV20_3D_MATERIAL_FACTOR_FRONT_G				0x000003ac
856 
857 #define NV20_3D_MATERIAL_FACTOR_FRONT_B				0x000003b0
858 
859 #define NV20_3D_MATERIAL_FACTOR_BACK				0x000017b0
860 
861 
862 #define NV20_3D_MATERIAL_FACTOR_BACK_R				0x000017b0
863 
864 #define NV20_3D_MATERIAL_FACTOR_BACK_G				0x000017b4
865 
866 #define NV20_3D_MATERIAL_FACTOR_BACK_B				0x000017b8
867 
868 #define NV20_3D_MATERIAL_FACTOR_FRONT_A				0x000003b4
869 
870 #define NV20_3D_MATERIAL_FACTOR_BACK_A				0x000017ac
871 
872 #define NV20_3D_LIGHT_MODEL_FRONT_AMBIENT			0x00000a10
873 
874 
875 #define NV20_3D_LIGHT_MODEL_FRONT_AMBIENT_R			0x00000a10
876 
877 #define NV20_3D_LIGHT_MODEL_FRONT_AMBIENT_G			0x00000a14
878 
879 #define NV20_3D_LIGHT_MODEL_FRONT_AMBIENT_B			0x00000a18
880 
881 #define NV20_3D_LIGHT_MODEL_BACK_AMBIENT			0x000017a0
882 
883 
884 #define NV20_3D_LIGHT_MODEL_BACK_AMBIENT_R			0x000017a0
885 
886 #define NV20_3D_LIGHT_MODEL_BACK_AMBIENT_G			0x000017a4
887 
888 #define NV20_3D_LIGHT_MODEL_BACK_AMBIENT_B			0x000017a8
889 
890 #define NV20_3D_FRONT_MATERIAL_SHININESS(i0)		       (0x000009e0 + 0x4*(i0))
891 #define NV20_3D_FRONT_MATERIAL_SHININESS__ESIZE			0x00000004
892 #define NV20_3D_FRONT_MATERIAL_SHININESS__LEN			0x00000006
893 
894 #define NV20_3D_BACK_MATERIAL_SHININESS(i0)		       (0x00001e28 + 0x4*(i0))
895 #define NV20_3D_BACK_MATERIAL_SHININESS__ESIZE			0x00000004
896 #define NV20_3D_BACK_MATERIAL_SHININESS__LEN			0x00000006
897 
898 
899 
900 #define NV20_3D_LIGHT_FRONT_AMBIENT(i0)			       (0x00001000 + 0x80*(i0))
901 
902 
903 #define NV20_3D_LIGHT_FRONT_AMBIENT_R(i0)		       (0x00001000 + 0x80*(i0))
904 
905 #define NV20_3D_LIGHT_FRONT_AMBIENT_G(i0)		       (0x00001004 + 0x80*(i0))
906 
907 #define NV20_3D_LIGHT_FRONT_AMBIENT_B(i0)		       (0x00001008 + 0x80*(i0))
908 
909 #define NV20_3D_LIGHT_FRONT_DIFFUSE(i0)			       (0x0000100c + 0x80*(i0))
910 
911 
912 #define NV20_3D_LIGHT_FRONT_DIFFUSE_R(i0)		       (0x0000100c + 0x80*(i0))
913 
914 #define NV20_3D_LIGHT_FRONT_DIFFUSE_G(i0)		       (0x00001010 + 0x80*(i0))
915 
916 #define NV20_3D_LIGHT_FRONT_DIFFUSE_B(i0)		       (0x00001014 + 0x80*(i0))
917 
918 #define NV20_3D_LIGHT_FRONT_SPECULAR(i0)		       (0x00001018 + 0x80*(i0))
919 
920 
921 #define NV20_3D_LIGHT_FRONT_SPECULAR_R(i0)		       (0x00001018 + 0x80*(i0))
922 
923 #define NV20_3D_LIGHT_FRONT_SPECULAR_G(i0)		       (0x0000101c + 0x80*(i0))
924 
925 #define NV20_3D_LIGHT_FRONT_SPECULAR_B(i0)		       (0x00001020 + 0x80*(i0))
926 
927 
928 #define NV20_3D_LIGHT_BACK_AMBIENT(i0)			       (0x00000c00 + 0x40*(i0))
929 
930 
931 #define NV20_3D_LIGHT_BACK_AMBIENT_R(i0)		       (0x00000c00 + 0x40*(i0))
932 
933 #define NV20_3D_LIGHT_BACK_AMBIENT_G(i0)		       (0x00000c04 + 0x40*(i0))
934 
935 #define NV20_3D_LIGHT_BACK_AMBIENT_B(i0)		       (0x00000c08 + 0x40*(i0))
936 
937 #define NV20_3D_LIGHT_BACK_DIFFUSE(i0)			       (0x00000c0c + 0x40*(i0))
938 
939 
940 #define NV20_3D_LIGHT_BACK_DIFFUSE_R(i0)		       (0x00000c0c + 0x40*(i0))
941 
942 #define NV20_3D_LIGHT_BACK_DIFFUSE_G(i0)		       (0x00000c10 + 0x40*(i0))
943 
944 #define NV20_3D_LIGHT_BACK_DIFFUSE_B(i0)		       (0x00000c14 + 0x40*(i0))
945 
946 #define NV20_3D_LIGHT_BACK_SPECULAR(i0)			       (0x00000c18 + 0x40*(i0))
947 
948 
949 #define NV20_3D_LIGHT_BACK_SPECULAR_R(i0)		       (0x00000c18 + 0x40*(i0))
950 
951 #define NV20_3D_LIGHT_BACK_SPECULAR_G(i0)		       (0x00000c1c + 0x40*(i0))
952 
953 #define NV20_3D_LIGHT_BACK_SPECULAR_B(i0)		       (0x00000c20 + 0x40*(i0))
954 
955 
956 #define NV20_3D_LIGHT_HALF_VECTOR(i0)			       (0x00001028 + 0x80*(i0))
957 
958 
959 #define NV20_3D_LIGHT_HALF_VECTOR_X(i0)			       (0x00001028 + 0x80*(i0))
960 
961 #define NV20_3D_LIGHT_HALF_VECTOR_Y(i0)			       (0x0000102c + 0x80*(i0))
962 
963 #define NV20_3D_LIGHT_HALF_VECTOR_Z(i0)			       (0x00001030 + 0x80*(i0))
964 
965 #define NV20_3D_LIGHT_DIRECTION(i0)			       (0x00001034 + 0x80*(i0))
966 
967 
968 #define NV20_3D_LIGHT_DIRECTION_X(i0)			       (0x00001034 + 0x80*(i0))
969 
970 #define NV20_3D_LIGHT_DIRECTION_Y(i0)			       (0x00001038 + 0x80*(i0))
971 
972 #define NV20_3D_LIGHT_DIRECTION_Z(i0)			       (0x0000103c + 0x80*(i0))
973 
974 #define NV20_3D_LIGHT_SPOT_CUTOFF(i0, i1)		       (0x00001040 + 0x80*(i0) + 0x4*(i1))
975 #define NV20_3D_LIGHT_SPOT_CUTOFF__ESIZE			0x00000004
976 #define NV20_3D_LIGHT_SPOT_CUTOFF__LEN				0x00000007
977 
978 #define NV20_3D_LIGHT_POSITION(i0)			       (0x0000105c + 0x80*(i0))
979 
980 
981 #define NV20_3D_LIGHT_POSITION_X(i0)			       (0x0000105c + 0x80*(i0))
982 
983 #define NV20_3D_LIGHT_POSITION_Y(i0)			       (0x00001060 + 0x80*(i0))
984 
985 #define NV20_3D_LIGHT_POSITION_Z(i0)			       (0x00001064 + 0x80*(i0))
986 
987 #define NV20_3D_LIGHT_ATTENUATION(i0)			       (0x00001068 + 0x80*(i0))
988 
989 #define NV20_3D_LIGHT_ATTENUATION_CONSTANT(i0)		       (0x00001068 + 0x80*(i0))
990 
991 #define NV20_3D_LIGHT_ATTENUATION_LINEAR(i0)		       (0x0000106c + 0x80*(i0))
992 
993 #define NV20_3D_LIGHT_ATTENUATION_QUADRATIC(i0)		       (0x00001070 + 0x80*(i0))
994 
995 
996 #define NV20_3D_FOG_MODE					0x0000029c
997 #define NV20_3D_FOG_MODE_LINEAR_UNSIGNED			0x00000804
998 #define NV20_3D_FOG_MODE_LINEAR_SIGNED				0x00002601
999 #define NV20_3D_FOG_MODE_EXP_UNSIGNED				0x00000802
1000 #define NV20_3D_FOG_MODE_EXP_SIGNED				0x00000800
1001 #define NV20_3D_FOG_MODE_EXP2_UNSIGNED				0x00000803
1002 #define NV20_3D_FOG_MODE_EXP2_SIGNED				0x00000801
1003 
1004 #define NV20_3D_FOG_COORD					0x000002a0
1005 #define NV20_3D_FOG_COORD_DIST_RADIAL				0x00000001
1006 #define NV20_3D_FOG_COORD_DIST_ORTHOGONAL			0x00000002
1007 #define NV20_3D_FOG_COORD_DIST_ORTHOGONAL_ABS			0x00000003
1008 #define NV20_3D_FOG_COORD_FOG					0x00000006
1009 
1010 #define NV20_3D_FOG_ENABLE					0x000002a4
1011 
1012 #define NV20_3D_FOG_COLOR					0x000002a8
1013 #define NV20_3D_FOG_COLOR_R__MASK				0x000000ff
1014 #define NV20_3D_FOG_COLOR_R__SHIFT				0
1015 #define NV20_3D_FOG_COLOR_G__MASK				0x0000ff00
1016 #define NV20_3D_FOG_COLOR_G__SHIFT				8
1017 #define NV20_3D_FOG_COLOR_B__MASK				0x00ff0000
1018 #define NV20_3D_FOG_COLOR_B__SHIFT				16
1019 #define NV20_3D_FOG_COLOR_A__MASK				0xff000000
1020 #define NV20_3D_FOG_COLOR_A__SHIFT				24
1021 
1022 #define NV20_3D_FOG_COEFF(i0)				       (0x000009c0 + 0x4*(i0))
1023 #define NV20_3D_FOG_COEFF__ESIZE				0x00000004
1024 #define NV20_3D_FOG_COEFF__LEN					0x00000003
1025 
1026 
1027 
1028 #define NV20_3D_TEX_GEN_MODE(i0, i1)			       (0x000003c0 + 0x10*(i0) + 0x4*(i1))
1029 #define NV20_3D_TEX_GEN_MODE__ESIZE				0x00000004
1030 #define NV20_3D_TEX_GEN_MODE__LEN				0x00000004
1031 #define NV20_3D_TEX_GEN_MODE_FALSE				0x00000000
1032 #define NV20_3D_TEX_GEN_MODE_EYE_LINEAR				0x00002400
1033 #define NV20_3D_TEX_GEN_MODE_OBJECT_LINEAR			0x00002401
1034 #define NV20_3D_TEX_GEN_MODE_SPHERE_MAP				0x00002402
1035 #define NV20_3D_TEX_GEN_MODE_NORMAL_MAP				0x00008511
1036 #define NV20_3D_TEX_GEN_MODE_REFLECTION_MAP			0x00008512
1037 
1038 
1039 #define NV20_3D_TEX_GEN_COEFF(i0, i1)			       (0x00000840 + 0x40*(i0) + 0x10*(i1))
1040 #define NV20_3D_TEX_GEN_COEFF__ESIZE				0x00000010
1041 #define NV20_3D_TEX_GEN_COEFF__LEN				0x00000004
1042 
1043 #define NV20_3D_TEX_GEN_COEFF_A(i0, i1)			       (0x00000840 + 0x40*(i0) + 0x10*(i1))
1044 
1045 #define NV20_3D_TEX_GEN_COEFF_B(i0, i1)			       (0x00000844 + 0x40*(i0) + 0x10*(i1))
1046 
1047 #define NV20_3D_TEX_GEN_COEFF_C(i0, i1)			       (0x00000848 + 0x40*(i0) + 0x10*(i1))
1048 
1049 #define NV20_3D_TEX_GEN_COEFF_D(i0, i1)			       (0x0000084c + 0x40*(i0) + 0x10*(i1))
1050 
1051 #define NV20_3D_TEX_MATRIX_ENABLE(i0)			       (0x00000420 + 0x4*(i0))
1052 #define NV20_3D_TEX_MATRIX_ENABLE__ESIZE			0x00000004
1053 #define NV20_3D_TEX_MATRIX_ENABLE__LEN				0x00000004
1054 
1055 
1056 #define NV20_3D_TEX_MATRIX(i0, i1)			       (0x000006c0 + 0x40*(i0) + 0x4*(i1))
1057 #define NV20_3D_TEX_MATRIX__ESIZE				0x00000004
1058 #define NV20_3D_TEX_MATRIX__LEN					0x00000010
1059 
1060 #define NV20_3D_TEX_SHADER_CULL_MODE				0x000017f8
1061 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_S__MASK		0x00000001
1062 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_S__SHIFT		0
1063 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_S_GEQUAL		0x00000000
1064 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_S_LESS			0x00000001
1065 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_T__MASK		0x00000002
1066 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_T__SHIFT		1
1067 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_T_GEQUAL		0x00000000
1068 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_T_LESS			0x00000002
1069 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_R__MASK		0x00000004
1070 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_R__SHIFT		2
1071 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_R_GEQUAL		0x00000000
1072 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_R_LESS			0x00000004
1073 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_Q__MASK		0x00000008
1074 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_Q__SHIFT		3
1075 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_Q_GEQUAL		0x00000000
1076 #define NV20_3D_TEX_SHADER_CULL_MODE_TX0_Q_LESS			0x00000008
1077 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_S__MASK		0x00000010
1078 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_S__SHIFT		4
1079 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_S_GEQUAL		0x00000000
1080 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_S_LESS			0x00000010
1081 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_T__MASK		0x00000020
1082 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_T__SHIFT		5
1083 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_T_GEQUAL		0x00000000
1084 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_T_LESS			0x00000020
1085 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_R__MASK		0x00000040
1086 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_R__SHIFT		6
1087 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_R_GEQUAL		0x00000000
1088 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_R_LESS			0x00000040
1089 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_Q__MASK		0x00000080
1090 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_Q__SHIFT		7
1091 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_Q_GEQUAL		0x00000000
1092 #define NV20_3D_TEX_SHADER_CULL_MODE_TX1_Q_LESS			0x00000080
1093 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_S__MASK		0x00000100
1094 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_S__SHIFT		8
1095 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_S_GEQUAL		0x00000000
1096 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_S_LESS			0x00000100
1097 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_T__MASK		0x00000200
1098 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_T__SHIFT		9
1099 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_T_GEQUAL		0x00000000
1100 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_T_LESS			0x00000200
1101 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_R__MASK		0x00000400
1102 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_R__SHIFT		10
1103 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_R_GEQUAL		0x00000000
1104 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_R_LESS			0x00000400
1105 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_Q__MASK		0x00000800
1106 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_Q__SHIFT		11
1107 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_Q_GEQUAL		0x00000000
1108 #define NV20_3D_TEX_SHADER_CULL_MODE_TX2_Q_LESS			0x00000800
1109 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_S__MASK		0x00001000
1110 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_S__SHIFT		12
1111 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_S_GEQUAL		0x00000000
1112 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_S_LESS			0x00001000
1113 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_T__MASK		0x00002000
1114 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_T__SHIFT		13
1115 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_T_GEQUAL		0x00000000
1116 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_T_LESS			0x00002000
1117 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_R__MASK		0x00004000
1118 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_R__SHIFT		14
1119 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_R_GEQUAL		0x00000000
1120 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_R_LESS			0x00004000
1121 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_Q__MASK		0x00008000
1122 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_Q__SHIFT		15
1123 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_Q_GEQUAL		0x00000000
1124 #define NV20_3D_TEX_SHADER_CULL_MODE_TX3_Q_LESS			0x00008000
1125 
1126 #define NV20_3D_TEX_SHADER_CONST_EYE				0x0000181c
1127 
1128 
1129 #define NV20_3D_TEX_SHADER_CONST_EYE_X				0x0000181c
1130 
1131 #define NV20_3D_TEX_SHADER_CONST_EYE_Y				0x00001820
1132 
1133 #define NV20_3D_TEX_SHADER_CONST_EYE_Z				0x00001824
1134 
1135 
1136 #define NV20_3D_TEX_SHADER_OFFSET_MATRIX(i0, i1)	       (0x00001b28 + 0x40*(i0) + 0x4*(i1))
1137 #define NV20_3D_TEX_SHADER_OFFSET_MATRIX__ESIZE			0x00000004
1138 #define NV20_3D_TEX_SHADER_OFFSET_MATRIX__LEN			0x00000004
1139 
1140 #define NV20_3D_TEX_RCOMP					0x00001e6c
1141 #define NV20_3D_TEX_RCOMP_NEVER					0x00000000
1142 #define NV20_3D_TEX_RCOMP_GREATER				0x00000001
1143 #define NV20_3D_TEX_RCOMP_EQUAL					0x00000002
1144 #define NV20_3D_TEX_RCOMP_GEQUAL				0x00000003
1145 #define NV20_3D_TEX_RCOMP_LESS					0x00000004
1146 #define NV20_3D_TEX_RCOMP_NOTEQUAL				0x00000005
1147 #define NV20_3D_TEX_RCOMP_LEQUAL				0x00000006
1148 #define NV20_3D_TEX_RCOMP_ALWAYS				0x00000007
1149 
1150 #define NV20_3D_TEX_SHADER_OP					0x00001e70
1151 #define NV20_3D_TEX_SHADER_OP_TX0__MASK				0x0000001f
1152 #define NV20_3D_TEX_SHADER_OP_TX0__SHIFT			0
1153 #define NV20_3D_TEX_SHADER_OP_TX0_NONE				0x00000000
1154 #define NV20_3D_TEX_SHADER_OP_TX0_TEXTURE_2D			0x00000001
1155 #define NV20_3D_TEX_SHADER_OP_TX0_PASS_THROUGH			0x00000004
1156 #define NV20_3D_TEX_SHADER_OP_TX0_CULL_FRAGMENT			0x00000005
1157 #define NV20_3D_TEX_SHADER_OP_TX0_OFFSET_TEXTURE_2D		0x00000006
1158 #define NV20_3D_TEX_SHADER_OP_TX0_DOT_PRODUCT_TEXTURE_2D	0x00000009
1159 #define NV20_3D_TEX_SHADER_OP_TX0_DOT_PRODUCT_DEPTH_REPLACE	0x0000000a
1160 #define NV20_3D_TEX_SHADER_OP_TX0_DEPENDANT_AR_TEXTURE_2D	0x0000000f
1161 #define NV20_3D_TEX_SHADER_OP_TX0_DEPENDANT_GB_TEXTURE_2D	0x00000010
1162 #define NV20_3D_TEX_SHADER_OP_TX0_DOT_PRODUCT			0x00000011
1163 #define NV20_3D_TEX_SHADER_OP_TX1__MASK				0x000003e0
1164 #define NV20_3D_TEX_SHADER_OP_TX1__SHIFT			5
1165 #define NV20_3D_TEX_SHADER_OP_TX1_NONE				0x00000000
1166 #define NV20_3D_TEX_SHADER_OP_TX1_TEXTURE_2D			0x00000020
1167 #define NV20_3D_TEX_SHADER_OP_TX1_PASS_THROUGH			0x00000080
1168 #define NV20_3D_TEX_SHADER_OP_TX1_CULL_FRAGMENT			0x000000a0
1169 #define NV20_3D_TEX_SHADER_OP_TX1_OFFSET_TEXTURE_2D		0x000000c0
1170 #define NV20_3D_TEX_SHADER_OP_TX1_DOT_PRODUCT_TEXTURE_2D	0x00000120
1171 #define NV20_3D_TEX_SHADER_OP_TX1_DOT_PRODUCT_DEPTH_REPLACE	0x00000140
1172 #define NV20_3D_TEX_SHADER_OP_TX1_DEPENDANT_AR_TEXTURE_2D	0x000001e0
1173 #define NV20_3D_TEX_SHADER_OP_TX1_DEPENDANT_GB_TEXTURE_2D	0x00000200
1174 #define NV20_3D_TEX_SHADER_OP_TX1_DOT_PRODUCT			0x00000220
1175 #define NV20_3D_TEX_SHADER_OP_TX2__MASK				0x00007c00
1176 #define NV20_3D_TEX_SHADER_OP_TX2__SHIFT			10
1177 #define NV20_3D_TEX_SHADER_OP_TX2_NONE				0x00000000
1178 #define NV20_3D_TEX_SHADER_OP_TX2_TEXTURE_2D			0x00000400
1179 #define NV20_3D_TEX_SHADER_OP_TX2_PASS_THROUGH			0x00001000
1180 #define NV20_3D_TEX_SHADER_OP_TX2_CULL_FRAGMENT			0x00001400
1181 #define NV20_3D_TEX_SHADER_OP_TX2_OFFSET_TEXTURE_2D		0x00001800
1182 #define NV20_3D_TEX_SHADER_OP_TX2_DOT_PRODUCT_TEXTURE_2D	0x00002400
1183 #define NV20_3D_TEX_SHADER_OP_TX2_DOT_PRODUCT_DEPTH_REPLACE	0x00002800
1184 #define NV20_3D_TEX_SHADER_OP_TX2_DEPENDANT_AR_TEXTURE_2D	0x00003c00
1185 #define NV20_3D_TEX_SHADER_OP_TX2_DEPENDANT_GB_TEXTURE_2D	0x00004000
1186 #define NV20_3D_TEX_SHADER_OP_TX2_DOT_PRODUCT			0x00004400
1187 #define NV20_3D_TEX_SHADER_OP_TX3__MASK				0x000f8000
1188 #define NV20_3D_TEX_SHADER_OP_TX3__SHIFT			15
1189 #define NV20_3D_TEX_SHADER_OP_TX3_NONE				0x00000000
1190 #define NV20_3D_TEX_SHADER_OP_TX3_TEXTURE_2D			0x00008000
1191 #define NV20_3D_TEX_SHADER_OP_TX3_PASS_THROUGH			0x00020000
1192 #define NV20_3D_TEX_SHADER_OP_TX3_CULL_FRAGMENT			0x00028000
1193 #define NV20_3D_TEX_SHADER_OP_TX3_OFFSET_TEXTURE_2D		0x00030000
1194 #define NV20_3D_TEX_SHADER_OP_TX3_DOT_PRODUCT_TEXTURE_2D	0x00048000
1195 #define NV20_3D_TEX_SHADER_OP_TX3_DOT_PRODUCT_DEPTH_REPLACE	0x00050000
1196 #define NV20_3D_TEX_SHADER_OP_TX3_DEPENDANT_AR_TEXTURE_2D	0x00078000
1197 #define NV20_3D_TEX_SHADER_OP_TX3_DEPENDANT_GB_TEXTURE_2D	0x00080000
1198 #define NV20_3D_TEX_SHADER_OP_TX3_DOT_PRODUCT			0x00088000
1199 
1200 #define NV20_3D_TEX_SHADER_DOTMAPPING				0x00001e74
1201 #define NV20_3D_TEX_SHADER_DOTMAPPING_TX0__MASK			0x0000000f
1202 #define NV20_3D_TEX_SHADER_DOTMAPPING_TX0__SHIFT		0
1203 #define NV20_3D_TEX_SHADER_DOTMAPPING_TX1__MASK			0x000000f0
1204 #define NV20_3D_TEX_SHADER_DOTMAPPING_TX1__SHIFT		4
1205 #define NV20_3D_TEX_SHADER_DOTMAPPING_TX2__MASK			0x00000f00
1206 #define NV20_3D_TEX_SHADER_DOTMAPPING_TX2__SHIFT		8
1207 #define NV20_3D_TEX_SHADER_DOTMAPPING_TX3__MASK			0x0000f000
1208 #define NV20_3D_TEX_SHADER_DOTMAPPING_TX3__SHIFT		12
1209 
1210 #define NV20_3D_TEX_SHADER_PREVIOUS				0x00001e78
1211 #define NV20_3D_TEX_SHADER_PREVIOUS_TX0__MASK			0x00000f00
1212 #define NV20_3D_TEX_SHADER_PREVIOUS_TX0__SHIFT			8
1213 #define NV20_3D_TEX_SHADER_PREVIOUS_TX1__MASK			0x0000f000
1214 #define NV20_3D_TEX_SHADER_PREVIOUS_TX1__SHIFT			12
1215 #define NV20_3D_TEX_SHADER_PREVIOUS_TX2__MASK			0x00030000
1216 #define NV20_3D_TEX_SHADER_PREVIOUS_TX2__SHIFT			16
1217 #define NV20_3D_TEX_SHADER_PREVIOUS_TX3__MASK			0x00300000
1218 #define NV20_3D_TEX_SHADER_PREVIOUS_TX3__SHIFT			20
1219 
1220 #define NV20_3D_TEX(i0)					       (0x00000000 + 0x40*(i0))
1221 #define NV20_3D_TEX__ESIZE					0x00000040
1222 #define NV20_3D_TEX__LEN					0x00000004
1223 
1224 #define NV20_3D_TEX_OFFSET(i0)				       (0x00001b00 + 0x40*(i0))
1225 
1226 #define NV20_3D_TEX_FORMAT(i0)				       (0x00001b04 + 0x40*(i0))
1227 #define NV20_3D_TEX_FORMAT_DMA0					0x00000001
1228 #define NV20_3D_TEX_FORMAT_DMA1					0x00000002
1229 #define NV20_3D_TEX_FORMAT_CUBIC				0x00000004
1230 #define NV20_3D_TEX_FORMAT_NO_BORDER				0x00000008
1231 #define NV20_3D_TEX_FORMAT_DIMS__MASK				0x000000f0
1232 #define NV20_3D_TEX_FORMAT_DIMS__SHIFT				4
1233 #define NV20_3D_TEX_FORMAT_DIMS_1D				0x00000010
1234 #define NV20_3D_TEX_FORMAT_DIMS_2D				0x00000020
1235 #define NV20_3D_TEX_FORMAT_DIMS_3D				0x00000030
1236 #define NV20_3D_TEX_FORMAT_FORMAT__MASK				0x0000ff00
1237 #define NV20_3D_TEX_FORMAT_FORMAT__SHIFT			8
1238 #define NV20_3D_TEX_FORMAT_FORMAT_L8				0x00000000
1239 #define NV20_3D_TEX_FORMAT_FORMAT_I8				0x00000100
1240 #define NV20_3D_TEX_FORMAT_FORMAT_A1R5G5B5			0x00000200
1241 #define NV20_3D_TEX_FORMAT_FORMAT_A4R4G4B4			0x00000400
1242 #define NV20_3D_TEX_FORMAT_FORMAT_R5G6B5			0x00000500
1243 #define NV20_3D_TEX_FORMAT_FORMAT_A8R8G8B8			0x00000600
1244 #define NV20_3D_TEX_FORMAT_FORMAT_X8R8G8B8			0x00000700
1245 #define NV20_3D_TEX_FORMAT_FORMAT_INDEX8			0x00000b00
1246 #define NV20_3D_TEX_FORMAT_FORMAT_DXT1				0x00000c00
1247 #define NV20_3D_TEX_FORMAT_FORMAT_DXT3				0x00000e00
1248 #define NV20_3D_TEX_FORMAT_FORMAT_DXT5				0x00000f00
1249 #define NV20_3D_TEX_FORMAT_FORMAT_A1R5G5B5_RECT			0x00001000
1250 #define NV20_3D_TEX_FORMAT_FORMAT_R5G6B5_RECT			0x00001100
1251 #define NV20_3D_TEX_FORMAT_FORMAT_A8R8G8B8_RECT			0x00001200
1252 #define NV20_3D_TEX_FORMAT_FORMAT_L8_RECT			0x00001300
1253 #define NV20_3D_TEX_FORMAT_FORMAT_DSDT8_RECT			0x00001700
1254 #define NV20_3D_TEX_FORMAT_FORMAT_A8L8				0x00001a00
1255 #define NV20_3D_TEX_FORMAT_FORMAT_I8_RECT			0x00001b00
1256 #define NV20_3D_TEX_FORMAT_FORMAT_A4R4G4B4_RECT			0x00001d00
1257 #define NV20_3D_TEX_FORMAT_FORMAT_R8G8B8_RECT			0x00001e00
1258 #define NV20_3D_TEX_FORMAT_FORMAT_A8L8_RECT			0x00002000
1259 #define NV20_3D_TEX_FORMAT_FORMAT_Z24				0x00002a00
1260 #define NV20_3D_TEX_FORMAT_FORMAT_Z24_RECT			0x00002b00
1261 #define NV20_3D_TEX_FORMAT_FORMAT_Z16				0x00002c00
1262 #define NV20_3D_TEX_FORMAT_FORMAT_Z16_RECT			0x00002d00
1263 #define NV20_3D_TEX_FORMAT_FORMAT_DSDT8				0x00002800
1264 #define NV20_3D_TEX_FORMAT_FORMAT_HILO16			0x00003300
1265 #define NV20_3D_TEX_FORMAT_FORMAT_HILO16_RECT			0x00003600
1266 #define NV20_3D_TEX_FORMAT_FORMAT_HILO8				0x00004400
1267 #define NV20_3D_TEX_FORMAT_FORMAT_SIGNED_HILO8			0x00004500
1268 #define NV20_3D_TEX_FORMAT_FORMAT_HILO8_RECT			0x00004600
1269 #define NV20_3D_TEX_FORMAT_FORMAT_SIGNED_HILO8_RECT		0x00004700
1270 #define NV20_3D_TEX_FORMAT_MIPMAP				0x00080000
1271 #define NV20_3D_TEX_FORMAT_BASE_SIZE_U__MASK			0x00f00000
1272 #define NV20_3D_TEX_FORMAT_BASE_SIZE_U__SHIFT			20
1273 #define NV20_3D_TEX_FORMAT_BASE_SIZE_V__MASK			0x0f000000
1274 #define NV20_3D_TEX_FORMAT_BASE_SIZE_V__SHIFT			24
1275 #define NV20_3D_TEX_FORMAT_BASE_SIZE_W__MASK			0xf0000000
1276 #define NV20_3D_TEX_FORMAT_BASE_SIZE_W__SHIFT			28
1277 
1278 #define NV20_3D_TEX_WRAP(i0)				       (0x00001b08 + 0x40*(i0))
1279 #define NV20_3D_TEX_WRAP_S__MASK				0x000000ff
1280 #define NV20_3D_TEX_WRAP_S__SHIFT				0
1281 #define NV20_3D_TEX_WRAP_S_REPEAT				0x00000001
1282 #define NV20_3D_TEX_WRAP_S_MIRRORED_REPEAT			0x00000002
1283 #define NV20_3D_TEX_WRAP_S_CLAMP_TO_EDGE			0x00000003
1284 #define NV20_3D_TEX_WRAP_S_CLAMP_TO_BORDER			0x00000004
1285 #define NV20_3D_TEX_WRAP_S_CLAMP				0x00000005
1286 #define NV20_3D_TEX_WRAP_T__MASK				0x00000f00
1287 #define NV20_3D_TEX_WRAP_T__SHIFT				8
1288 #define NV20_3D_TEX_WRAP_T_REPEAT				0x00000100
1289 #define NV20_3D_TEX_WRAP_T_MIRRORED_REPEAT			0x00000200
1290 #define NV20_3D_TEX_WRAP_T_CLAMP_TO_EDGE			0x00000300
1291 #define NV20_3D_TEX_WRAP_T_CLAMP_TO_BORDER			0x00000400
1292 #define NV20_3D_TEX_WRAP_T_CLAMP				0x00000500
1293 #define NV20_3D_TEX_WRAP_R__MASK				0x000f0000
1294 #define NV20_3D_TEX_WRAP_R__SHIFT				16
1295 #define NV20_3D_TEX_WRAP_R_REPEAT				0x00010000
1296 #define NV20_3D_TEX_WRAP_R_MIRRORED_REPEAT			0x00020000
1297 #define NV20_3D_TEX_WRAP_R_CLAMP_TO_EDGE			0x00030000
1298 #define NV20_3D_TEX_WRAP_R_CLAMP_TO_BORDER			0x00040000
1299 #define NV20_3D_TEX_WRAP_R_CLAMP				0x00050000
1300 
1301 #define NV20_3D_TEX_ENABLE(i0)				       (0x00001b0c + 0x40*(i0))
1302 #define NV20_3D_TEX_ENABLE_ANISO__MASK				0x00000030
1303 #define NV20_3D_TEX_ENABLE_ANISO__SHIFT				4
1304 #define NV20_3D_TEX_ENABLE_ANISO_NONE				0x00000000
1305 #define NV20_3D_TEX_ENABLE_ANISO_2X				0x00000010
1306 #define NV20_3D_TEX_ENABLE_ANISO_4X				0x00000020
1307 #define NV20_3D_TEX_ENABLE_ANISO_8X				0x00000030
1308 #define NV20_3D_TEX_ENABLE_MIPMAP_MAX_LOD__MASK			0x0003c000
1309 #define NV20_3D_TEX_ENABLE_MIPMAP_MAX_LOD__SHIFT		14
1310 #define NV20_3D_TEX_ENABLE_MIPMAP_MIN_LOD__MASK			0x3c000000
1311 #define NV20_3D_TEX_ENABLE_MIPMAP_MIN_LOD__SHIFT		26
1312 #define NV20_3D_TEX_ENABLE_ENABLE				0x40000000
1313 
1314 #define NV20_3D_TEX_NPOT_PITCH(i0)			       (0x00001b10 + 0x40*(i0))
1315 #define NV20_3D_TEX_NPOT_PITCH_PITCH__MASK			0xffff0000
1316 #define NV20_3D_TEX_NPOT_PITCH_PITCH__SHIFT			16
1317 
1318 #define NV20_3D_TEX_FILTER(i0)				       (0x00001b14 + 0x40*(i0))
1319 #define NV20_3D_TEX_FILTER_LOD_BIAS__MASK			0x00000f00
1320 #define NV20_3D_TEX_FILTER_LOD_BIAS__SHIFT			8
1321 #define NV20_3D_TEX_FILTER_MINIFY__MASK				0x000f0000
1322 #define NV20_3D_TEX_FILTER_MINIFY__SHIFT			16
1323 #define NV20_3D_TEX_FILTER_MINIFY_NEAREST			0x00010000
1324 #define NV20_3D_TEX_FILTER_MINIFY_LINEAR			0x00020000
1325 #define NV20_3D_TEX_FILTER_MINIFY_NEAREST_MIPMAP_NEAREST	0x00030000
1326 #define NV20_3D_TEX_FILTER_MINIFY_LINEAR_MIPMAP_NEAREST		0x00040000
1327 #define NV20_3D_TEX_FILTER_MINIFY_NEAREST_MIPMAP_LINEAR		0x00050000
1328 #define NV20_3D_TEX_FILTER_MINIFY_LINEAR_MIPMAP_LINEAR		0x00060000
1329 #define NV20_3D_TEX_FILTER_MAGNIFY__MASK			0x0f000000
1330 #define NV20_3D_TEX_FILTER_MAGNIFY__SHIFT			24
1331 #define NV20_3D_TEX_FILTER_MAGNIFY_NEAREST			0x01000000
1332 #define NV20_3D_TEX_FILTER_MAGNIFY_LINEAR			0x02000000
1333 
1334 #define NV20_3D_TEX_NPOT_SIZE(i0)			       (0x00001b1c + 0x40*(i0))
1335 #define NV20_3D_TEX_NPOT_SIZE_H__MASK				0x0000ffff
1336 #define NV20_3D_TEX_NPOT_SIZE_H__SHIFT				0
1337 #define NV20_3D_TEX_NPOT_SIZE_W__MASK				0xffff0000
1338 #define NV20_3D_TEX_NPOT_SIZE_W__SHIFT				16
1339 
1340 #define NV20_3D_TEX_PALETTE_OFFSET(i0)			       (0x00001b20 + 0x40*(i0))
1341 
1342 #define NV20_3D_TEX_BORDER_COLOR(i0)			       (0x00001b24 + 0x40*(i0))
1343 #define NV20_3D_TEX_BORDER_COLOR_B__MASK			0x000000ff
1344 #define NV20_3D_TEX_BORDER_COLOR_B__SHIFT			0
1345 #define NV20_3D_TEX_BORDER_COLOR_G__MASK			0x0000ff00
1346 #define NV20_3D_TEX_BORDER_COLOR_G__SHIFT			8
1347 #define NV20_3D_TEX_BORDER_COLOR_R__MASK			0x00ff0000
1348 #define NV20_3D_TEX_BORDER_COLOR_R__SHIFT			16
1349 #define NV20_3D_TEX_BORDER_COLOR_A__MASK			0xff000000
1350 #define NV20_3D_TEX_BORDER_COLOR_A__SHIFT			24
1351 
1352 
1353 
1354 #define NV20_3D_RC_IN_ALPHA(i0)				       (0x00000260 + 0x4*(i0))
1355 #define NV20_3D_RC_IN_ALPHA_D_INPUT__MASK			0x0000000f
1356 #define NV20_3D_RC_IN_ALPHA_D_INPUT__SHIFT			0
1357 #define NV20_3D_RC_IN_ALPHA_D_INPUT_ZERO			0x00000000
1358 #define NV20_3D_RC_IN_ALPHA_D_INPUT_CONSTANT_COLOR0		0x00000001
1359 #define NV20_3D_RC_IN_ALPHA_D_INPUT_CONSTANT_COLOR1		0x00000002
1360 #define NV20_3D_RC_IN_ALPHA_D_INPUT_FOG				0x00000003
1361 #define NV20_3D_RC_IN_ALPHA_D_INPUT_PRIMARY_COLOR		0x00000004
1362 #define NV20_3D_RC_IN_ALPHA_D_INPUT_SECONDARY_COLOR		0x00000005
1363 #define NV20_3D_RC_IN_ALPHA_D_INPUT_TEXTURE0			0x00000008
1364 #define NV20_3D_RC_IN_ALPHA_D_INPUT_TEXTURE1			0x00000009
1365 #define NV20_3D_RC_IN_ALPHA_D_INPUT_TEXTURE2			0x0000000a
1366 #define NV20_3D_RC_IN_ALPHA_D_INPUT_TEXTURE3			0x0000000b
1367 #define NV20_3D_RC_IN_ALPHA_D_INPUT_SPARE0			0x0000000c
1368 #define NV20_3D_RC_IN_ALPHA_D_INPUT_SPARE1			0x0000000d
1369 #define NV20_3D_RC_IN_ALPHA_D_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x0000000e
1370 #define NV20_3D_RC_IN_ALPHA_D_INPUT_E_TIMES_F			0x0000000f
1371 #define NV20_3D_RC_IN_ALPHA_D_COMPONENT_USAGE__MASK		0x00000010
1372 #define NV20_3D_RC_IN_ALPHA_D_COMPONENT_USAGE__SHIFT		4
1373 #define NV20_3D_RC_IN_ALPHA_D_COMPONENT_USAGE_BLUE		0x00000000
1374 #define NV20_3D_RC_IN_ALPHA_D_COMPONENT_USAGE_ALPHA		0x00000010
1375 #define NV20_3D_RC_IN_ALPHA_D_MAPPING__MASK			0x000000e0
1376 #define NV20_3D_RC_IN_ALPHA_D_MAPPING__SHIFT			5
1377 #define NV20_3D_RC_IN_ALPHA_D_MAPPING_UNSIGNED_IDENTITY		0x00000000
1378 #define NV20_3D_RC_IN_ALPHA_D_MAPPING_UNSIGNED_INVERT		0x00000020
1379 #define NV20_3D_RC_IN_ALPHA_D_MAPPING_EXPAND_NORMAL		0x00000040
1380 #define NV20_3D_RC_IN_ALPHA_D_MAPPING_EXPAND_NEGATE		0x00000060
1381 #define NV20_3D_RC_IN_ALPHA_D_MAPPING_HALF_BIAS_NORMAL		0x00000080
1382 #define NV20_3D_RC_IN_ALPHA_D_MAPPING_HALF_BIAS_NEGATE		0x000000a0
1383 #define NV20_3D_RC_IN_ALPHA_D_MAPPING_SIGNED_IDENTITY		0x000000c0
1384 #define NV20_3D_RC_IN_ALPHA_D_MAPPING_SIGNED_NEGATE		0x000000e0
1385 #define NV20_3D_RC_IN_ALPHA_C_INPUT__MASK			0x00000f00
1386 #define NV20_3D_RC_IN_ALPHA_C_INPUT__SHIFT			8
1387 #define NV20_3D_RC_IN_ALPHA_C_INPUT_ZERO			0x00000000
1388 #define NV20_3D_RC_IN_ALPHA_C_INPUT_CONSTANT_COLOR0		0x00000100
1389 #define NV20_3D_RC_IN_ALPHA_C_INPUT_CONSTANT_COLOR1		0x00000200
1390 #define NV20_3D_RC_IN_ALPHA_C_INPUT_FOG				0x00000300
1391 #define NV20_3D_RC_IN_ALPHA_C_INPUT_PRIMARY_COLOR		0x00000400
1392 #define NV20_3D_RC_IN_ALPHA_C_INPUT_SECONDARY_COLOR		0x00000500
1393 #define NV20_3D_RC_IN_ALPHA_C_INPUT_TEXTURE0			0x00000800
1394 #define NV20_3D_RC_IN_ALPHA_C_INPUT_TEXTURE1			0x00000900
1395 #define NV20_3D_RC_IN_ALPHA_C_INPUT_TEXTURE2			0x00000a00
1396 #define NV20_3D_RC_IN_ALPHA_C_INPUT_TEXTURE3			0x00000b00
1397 #define NV20_3D_RC_IN_ALPHA_C_INPUT_SPARE0			0x00000c00
1398 #define NV20_3D_RC_IN_ALPHA_C_INPUT_SPARE1			0x00000d00
1399 #define NV20_3D_RC_IN_ALPHA_C_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x00000e00
1400 #define NV20_3D_RC_IN_ALPHA_C_INPUT_E_TIMES_F			0x00000f00
1401 #define NV20_3D_RC_IN_ALPHA_C_COMPONENT_USAGE__MASK		0x00001000
1402 #define NV20_3D_RC_IN_ALPHA_C_COMPONENT_USAGE__SHIFT		12
1403 #define NV20_3D_RC_IN_ALPHA_C_COMPONENT_USAGE_BLUE		0x00000000
1404 #define NV20_3D_RC_IN_ALPHA_C_COMPONENT_USAGE_ALPHA		0x00001000
1405 #define NV20_3D_RC_IN_ALPHA_C_MAPPING__MASK			0x0000e000
1406 #define NV20_3D_RC_IN_ALPHA_C_MAPPING__SHIFT			13
1407 #define NV20_3D_RC_IN_ALPHA_C_MAPPING_UNSIGNED_IDENTITY		0x00000000
1408 #define NV20_3D_RC_IN_ALPHA_C_MAPPING_UNSIGNED_INVERT		0x00002000
1409 #define NV20_3D_RC_IN_ALPHA_C_MAPPING_EXPAND_NORMAL		0x00004000
1410 #define NV20_3D_RC_IN_ALPHA_C_MAPPING_EXPAND_NEGATE		0x00006000
1411 #define NV20_3D_RC_IN_ALPHA_C_MAPPING_HALF_BIAS_NORMAL		0x00008000
1412 #define NV20_3D_RC_IN_ALPHA_C_MAPPING_HALF_BIAS_NEGATE		0x0000a000
1413 #define NV20_3D_RC_IN_ALPHA_C_MAPPING_SIGNED_IDENTITY		0x0000c000
1414 #define NV20_3D_RC_IN_ALPHA_C_MAPPING_SIGNED_NEGATE		0x0000e000
1415 #define NV20_3D_RC_IN_ALPHA_B_INPUT__MASK			0x000f0000
1416 #define NV20_3D_RC_IN_ALPHA_B_INPUT__SHIFT			16
1417 #define NV20_3D_RC_IN_ALPHA_B_INPUT_ZERO			0x00000000
1418 #define NV20_3D_RC_IN_ALPHA_B_INPUT_CONSTANT_COLOR0		0x00010000
1419 #define NV20_3D_RC_IN_ALPHA_B_INPUT_CONSTANT_COLOR1		0x00020000
1420 #define NV20_3D_RC_IN_ALPHA_B_INPUT_FOG				0x00030000
1421 #define NV20_3D_RC_IN_ALPHA_B_INPUT_PRIMARY_COLOR		0x00040000
1422 #define NV20_3D_RC_IN_ALPHA_B_INPUT_SECONDARY_COLOR		0x00050000
1423 #define NV20_3D_RC_IN_ALPHA_B_INPUT_TEXTURE0			0x00080000
1424 #define NV20_3D_RC_IN_ALPHA_B_INPUT_TEXTURE1			0x00090000
1425 #define NV20_3D_RC_IN_ALPHA_B_INPUT_TEXTURE2			0x000a0000
1426 #define NV20_3D_RC_IN_ALPHA_B_INPUT_TEXTURE3			0x000b0000
1427 #define NV20_3D_RC_IN_ALPHA_B_INPUT_SPARE0			0x000c0000
1428 #define NV20_3D_RC_IN_ALPHA_B_INPUT_SPARE1			0x000d0000
1429 #define NV20_3D_RC_IN_ALPHA_B_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x000e0000
1430 #define NV20_3D_RC_IN_ALPHA_B_INPUT_E_TIMES_F			0x000f0000
1431 #define NV20_3D_RC_IN_ALPHA_B_COMPONENT_USAGE__MASK		0x00100000
1432 #define NV20_3D_RC_IN_ALPHA_B_COMPONENT_USAGE__SHIFT		20
1433 #define NV20_3D_RC_IN_ALPHA_B_COMPONENT_USAGE_BLUE		0x00000000
1434 #define NV20_3D_RC_IN_ALPHA_B_COMPONENT_USAGE_ALPHA		0x00100000
1435 #define NV20_3D_RC_IN_ALPHA_B_MAPPING__MASK			0x00e00000
1436 #define NV20_3D_RC_IN_ALPHA_B_MAPPING__SHIFT			21
1437 #define NV20_3D_RC_IN_ALPHA_B_MAPPING_UNSIGNED_IDENTITY		0x00000000
1438 #define NV20_3D_RC_IN_ALPHA_B_MAPPING_UNSIGNED_INVERT		0x00200000
1439 #define NV20_3D_RC_IN_ALPHA_B_MAPPING_EXPAND_NORMAL		0x00400000
1440 #define NV20_3D_RC_IN_ALPHA_B_MAPPING_EXPAND_NEGATE		0x00600000
1441 #define NV20_3D_RC_IN_ALPHA_B_MAPPING_HALF_BIAS_NORMAL		0x00800000
1442 #define NV20_3D_RC_IN_ALPHA_B_MAPPING_HALF_BIAS_NEGATE		0x00a00000
1443 #define NV20_3D_RC_IN_ALPHA_B_MAPPING_SIGNED_IDENTITY		0x00c00000
1444 #define NV20_3D_RC_IN_ALPHA_B_MAPPING_SIGNED_NEGATE		0x00e00000
1445 #define NV20_3D_RC_IN_ALPHA_A_INPUT__MASK			0x0f000000
1446 #define NV20_3D_RC_IN_ALPHA_A_INPUT__SHIFT			24
1447 #define NV20_3D_RC_IN_ALPHA_A_INPUT_ZERO			0x00000000
1448 #define NV20_3D_RC_IN_ALPHA_A_INPUT_CONSTANT_COLOR0		0x01000000
1449 #define NV20_3D_RC_IN_ALPHA_A_INPUT_CONSTANT_COLOR1		0x02000000
1450 #define NV20_3D_RC_IN_ALPHA_A_INPUT_FOG				0x03000000
1451 #define NV20_3D_RC_IN_ALPHA_A_INPUT_PRIMARY_COLOR		0x04000000
1452 #define NV20_3D_RC_IN_ALPHA_A_INPUT_SECONDARY_COLOR		0x05000000
1453 #define NV20_3D_RC_IN_ALPHA_A_INPUT_TEXTURE0			0x08000000
1454 #define NV20_3D_RC_IN_ALPHA_A_INPUT_TEXTURE1			0x09000000
1455 #define NV20_3D_RC_IN_ALPHA_A_INPUT_TEXTURE2			0x0a000000
1456 #define NV20_3D_RC_IN_ALPHA_A_INPUT_TEXTURE3			0x0b000000
1457 #define NV20_3D_RC_IN_ALPHA_A_INPUT_SPARE0			0x0c000000
1458 #define NV20_3D_RC_IN_ALPHA_A_INPUT_SPARE1			0x0d000000
1459 #define NV20_3D_RC_IN_ALPHA_A_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x0e000000
1460 #define NV20_3D_RC_IN_ALPHA_A_INPUT_E_TIMES_F			0x0f000000
1461 #define NV20_3D_RC_IN_ALPHA_A_COMPONENT_USAGE__MASK		0x10000000
1462 #define NV20_3D_RC_IN_ALPHA_A_COMPONENT_USAGE__SHIFT		28
1463 #define NV20_3D_RC_IN_ALPHA_A_COMPONENT_USAGE_BLUE		0x00000000
1464 #define NV20_3D_RC_IN_ALPHA_A_COMPONENT_USAGE_ALPHA		0x10000000
1465 #define NV20_3D_RC_IN_ALPHA_A_MAPPING__MASK			0xe0000000
1466 #define NV20_3D_RC_IN_ALPHA_A_MAPPING__SHIFT			29
1467 #define NV20_3D_RC_IN_ALPHA_A_MAPPING_UNSIGNED_IDENTITY		0x00000000
1468 #define NV20_3D_RC_IN_ALPHA_A_MAPPING_UNSIGNED_INVERT		0x20000000
1469 #define NV20_3D_RC_IN_ALPHA_A_MAPPING_EXPAND_NORMAL		0x40000000
1470 #define NV20_3D_RC_IN_ALPHA_A_MAPPING_EXPAND_NEGATE		0x60000000
1471 #define NV20_3D_RC_IN_ALPHA_A_MAPPING_HALF_BIAS_NORMAL		0x80000000
1472 #define NV20_3D_RC_IN_ALPHA_A_MAPPING_HALF_BIAS_NEGATE		0xa0000000
1473 #define NV20_3D_RC_IN_ALPHA_A_MAPPING_SIGNED_IDENTITY		0xc0000000
1474 #define NV20_3D_RC_IN_ALPHA_A_MAPPING_SIGNED_NEGATE		0xe0000000
1475 
1476 #define NV20_3D_RC_IN_RGB(i0)				       (0x00000ac0 + 0x4*(i0))
1477 #define NV20_3D_RC_IN_RGB_D_INPUT__MASK				0x0000000f
1478 #define NV20_3D_RC_IN_RGB_D_INPUT__SHIFT			0
1479 #define NV20_3D_RC_IN_RGB_D_INPUT_ZERO				0x00000000
1480 #define NV20_3D_RC_IN_RGB_D_INPUT_CONSTANT_COLOR0		0x00000001
1481 #define NV20_3D_RC_IN_RGB_D_INPUT_CONSTANT_COLOR1		0x00000002
1482 #define NV20_3D_RC_IN_RGB_D_INPUT_FOG				0x00000003
1483 #define NV20_3D_RC_IN_RGB_D_INPUT_PRIMARY_COLOR			0x00000004
1484 #define NV20_3D_RC_IN_RGB_D_INPUT_SECONDARY_COLOR		0x00000005
1485 #define NV20_3D_RC_IN_RGB_D_INPUT_TEXTURE0			0x00000008
1486 #define NV20_3D_RC_IN_RGB_D_INPUT_TEXTURE1			0x00000009
1487 #define NV20_3D_RC_IN_RGB_D_INPUT_TEXTURE2			0x0000000a
1488 #define NV20_3D_RC_IN_RGB_D_INPUT_TEXTURE3			0x0000000b
1489 #define NV20_3D_RC_IN_RGB_D_INPUT_SPARE0			0x0000000c
1490 #define NV20_3D_RC_IN_RGB_D_INPUT_SPARE1			0x0000000d
1491 #define NV20_3D_RC_IN_RGB_D_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x0000000e
1492 #define NV20_3D_RC_IN_RGB_D_INPUT_E_TIMES_F			0x0000000f
1493 #define NV20_3D_RC_IN_RGB_D_COMPONENT_USAGE__MASK		0x00000010
1494 #define NV20_3D_RC_IN_RGB_D_COMPONENT_USAGE__SHIFT		4
1495 #define NV20_3D_RC_IN_RGB_D_COMPONENT_USAGE_RGB			0x00000000
1496 #define NV20_3D_RC_IN_RGB_D_COMPONENT_USAGE_ALPHA		0x00000010
1497 #define NV20_3D_RC_IN_RGB_D_MAPPING__MASK			0x000000e0
1498 #define NV20_3D_RC_IN_RGB_D_MAPPING__SHIFT			5
1499 #define NV20_3D_RC_IN_RGB_D_MAPPING_UNSIGNED_IDENTITY		0x00000000
1500 #define NV20_3D_RC_IN_RGB_D_MAPPING_UNSIGNED_INVERT		0x00000020
1501 #define NV20_3D_RC_IN_RGB_D_MAPPING_EXPAND_NORMAL		0x00000040
1502 #define NV20_3D_RC_IN_RGB_D_MAPPING_EXPAND_NEGATE		0x00000060
1503 #define NV20_3D_RC_IN_RGB_D_MAPPING_HALF_BIAS_NORMAL		0x00000080
1504 #define NV20_3D_RC_IN_RGB_D_MAPPING_HALF_BIAS_NEGATE		0x000000a0
1505 #define NV20_3D_RC_IN_RGB_D_MAPPING_SIGNED_IDENTITY		0x000000c0
1506 #define NV20_3D_RC_IN_RGB_D_MAPPING_SIGNED_NEGATE		0x000000e0
1507 #define NV20_3D_RC_IN_RGB_C_INPUT__MASK				0x00000f00
1508 #define NV20_3D_RC_IN_RGB_C_INPUT__SHIFT			8
1509 #define NV20_3D_RC_IN_RGB_C_INPUT_ZERO				0x00000000
1510 #define NV20_3D_RC_IN_RGB_C_INPUT_CONSTANT_COLOR0		0x00000100
1511 #define NV20_3D_RC_IN_RGB_C_INPUT_CONSTANT_COLOR1		0x00000200
1512 #define NV20_3D_RC_IN_RGB_C_INPUT_FOG				0x00000300
1513 #define NV20_3D_RC_IN_RGB_C_INPUT_PRIMARY_COLOR			0x00000400
1514 #define NV20_3D_RC_IN_RGB_C_INPUT_SECONDARY_COLOR		0x00000500
1515 #define NV20_3D_RC_IN_RGB_C_INPUT_TEXTURE0			0x00000800
1516 #define NV20_3D_RC_IN_RGB_C_INPUT_TEXTURE1			0x00000900
1517 #define NV20_3D_RC_IN_RGB_C_INPUT_TEXTURE2			0x00000a00
1518 #define NV20_3D_RC_IN_RGB_C_INPUT_TEXTURE3			0x00000b00
1519 #define NV20_3D_RC_IN_RGB_C_INPUT_SPARE0			0x00000c00
1520 #define NV20_3D_RC_IN_RGB_C_INPUT_SPARE1			0x00000d00
1521 #define NV20_3D_RC_IN_RGB_C_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x00000e00
1522 #define NV20_3D_RC_IN_RGB_C_INPUT_E_TIMES_F			0x00000f00
1523 #define NV20_3D_RC_IN_RGB_C_COMPONENT_USAGE__MASK		0x00001000
1524 #define NV20_3D_RC_IN_RGB_C_COMPONENT_USAGE__SHIFT		12
1525 #define NV20_3D_RC_IN_RGB_C_COMPONENT_USAGE_RGB			0x00000000
1526 #define NV20_3D_RC_IN_RGB_C_COMPONENT_USAGE_ALPHA		0x00001000
1527 #define NV20_3D_RC_IN_RGB_C_MAPPING__MASK			0x0000e000
1528 #define NV20_3D_RC_IN_RGB_C_MAPPING__SHIFT			13
1529 #define NV20_3D_RC_IN_RGB_C_MAPPING_UNSIGNED_IDENTITY		0x00000000
1530 #define NV20_3D_RC_IN_RGB_C_MAPPING_UNSIGNED_INVERT		0x00002000
1531 #define NV20_3D_RC_IN_RGB_C_MAPPING_EXPAND_NORMAL		0x00004000
1532 #define NV20_3D_RC_IN_RGB_C_MAPPING_EXPAND_NEGATE		0x00006000
1533 #define NV20_3D_RC_IN_RGB_C_MAPPING_HALF_BIAS_NORMAL		0x00008000
1534 #define NV20_3D_RC_IN_RGB_C_MAPPING_HALF_BIAS_NEGATE		0x0000a000
1535 #define NV20_3D_RC_IN_RGB_C_MAPPING_SIGNED_IDENTITY		0x0000c000
1536 #define NV20_3D_RC_IN_RGB_C_MAPPING_SIGNED_NEGATE		0x0000e000
1537 #define NV20_3D_RC_IN_RGB_B_INPUT__MASK				0x000f0000
1538 #define NV20_3D_RC_IN_RGB_B_INPUT__SHIFT			16
1539 #define NV20_3D_RC_IN_RGB_B_INPUT_ZERO				0x00000000
1540 #define NV20_3D_RC_IN_RGB_B_INPUT_CONSTANT_COLOR0		0x00010000
1541 #define NV20_3D_RC_IN_RGB_B_INPUT_CONSTANT_COLOR1		0x00020000
1542 #define NV20_3D_RC_IN_RGB_B_INPUT_FOG				0x00030000
1543 #define NV20_3D_RC_IN_RGB_B_INPUT_PRIMARY_COLOR			0x00040000
1544 #define NV20_3D_RC_IN_RGB_B_INPUT_SECONDARY_COLOR		0x00050000
1545 #define NV20_3D_RC_IN_RGB_B_INPUT_TEXTURE0			0x00080000
1546 #define NV20_3D_RC_IN_RGB_B_INPUT_TEXTURE1			0x00090000
1547 #define NV20_3D_RC_IN_RGB_B_INPUT_TEXTURE2			0x000a0000
1548 #define NV20_3D_RC_IN_RGB_B_INPUT_TEXTURE3			0x000b0000
1549 #define NV20_3D_RC_IN_RGB_B_INPUT_SPARE0			0x000c0000
1550 #define NV20_3D_RC_IN_RGB_B_INPUT_SPARE1			0x000d0000
1551 #define NV20_3D_RC_IN_RGB_B_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x000e0000
1552 #define NV20_3D_RC_IN_RGB_B_INPUT_E_TIMES_F			0x000f0000
1553 #define NV20_3D_RC_IN_RGB_B_COMPONENT_USAGE__MASK		0x00100000
1554 #define NV20_3D_RC_IN_RGB_B_COMPONENT_USAGE__SHIFT		20
1555 #define NV20_3D_RC_IN_RGB_B_COMPONENT_USAGE_RGB			0x00000000
1556 #define NV20_3D_RC_IN_RGB_B_COMPONENT_USAGE_ALPHA		0x00100000
1557 #define NV20_3D_RC_IN_RGB_B_MAPPING__MASK			0x00e00000
1558 #define NV20_3D_RC_IN_RGB_B_MAPPING__SHIFT			21
1559 #define NV20_3D_RC_IN_RGB_B_MAPPING_UNSIGNED_IDENTITY		0x00000000
1560 #define NV20_3D_RC_IN_RGB_B_MAPPING_UNSIGNED_INVERT		0x00200000
1561 #define NV20_3D_RC_IN_RGB_B_MAPPING_EXPAND_NORMAL		0x00400000
1562 #define NV20_3D_RC_IN_RGB_B_MAPPING_EXPAND_NEGATE		0x00600000
1563 #define NV20_3D_RC_IN_RGB_B_MAPPING_HALF_BIAS_NORMAL		0x00800000
1564 #define NV20_3D_RC_IN_RGB_B_MAPPING_HALF_BIAS_NEGATE		0x00a00000
1565 #define NV20_3D_RC_IN_RGB_B_MAPPING_SIGNED_IDENTITY		0x00c00000
1566 #define NV20_3D_RC_IN_RGB_B_MAPPING_SIGNED_NEGATE		0x00e00000
1567 #define NV20_3D_RC_IN_RGB_A_INPUT__MASK				0x0f000000
1568 #define NV20_3D_RC_IN_RGB_A_INPUT__SHIFT			24
1569 #define NV20_3D_RC_IN_RGB_A_INPUT_ZERO				0x00000000
1570 #define NV20_3D_RC_IN_RGB_A_INPUT_CONSTANT_COLOR0		0x01000000
1571 #define NV20_3D_RC_IN_RGB_A_INPUT_CONSTANT_COLOR1		0x02000000
1572 #define NV20_3D_RC_IN_RGB_A_INPUT_FOG				0x03000000
1573 #define NV20_3D_RC_IN_RGB_A_INPUT_PRIMARY_COLOR			0x04000000
1574 #define NV20_3D_RC_IN_RGB_A_INPUT_SECONDARY_COLOR		0x05000000
1575 #define NV20_3D_RC_IN_RGB_A_INPUT_TEXTURE0			0x08000000
1576 #define NV20_3D_RC_IN_RGB_A_INPUT_TEXTURE1			0x09000000
1577 #define NV20_3D_RC_IN_RGB_A_INPUT_TEXTURE2			0x0a000000
1578 #define NV20_3D_RC_IN_RGB_A_INPUT_TEXTURE3			0x0b000000
1579 #define NV20_3D_RC_IN_RGB_A_INPUT_SPARE0			0x0c000000
1580 #define NV20_3D_RC_IN_RGB_A_INPUT_SPARE1			0x0d000000
1581 #define NV20_3D_RC_IN_RGB_A_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x0e000000
1582 #define NV20_3D_RC_IN_RGB_A_INPUT_E_TIMES_F			0x0f000000
1583 #define NV20_3D_RC_IN_RGB_A_COMPONENT_USAGE__MASK		0x10000000
1584 #define NV20_3D_RC_IN_RGB_A_COMPONENT_USAGE__SHIFT		28
1585 #define NV20_3D_RC_IN_RGB_A_COMPONENT_USAGE_RGB			0x00000000
1586 #define NV20_3D_RC_IN_RGB_A_COMPONENT_USAGE_ALPHA		0x10000000
1587 #define NV20_3D_RC_IN_RGB_A_MAPPING__MASK			0xe0000000
1588 #define NV20_3D_RC_IN_RGB_A_MAPPING__SHIFT			29
1589 #define NV20_3D_RC_IN_RGB_A_MAPPING_UNSIGNED_IDENTITY		0x00000000
1590 #define NV20_3D_RC_IN_RGB_A_MAPPING_UNSIGNED_INVERT		0x20000000
1591 #define NV20_3D_RC_IN_RGB_A_MAPPING_EXPAND_NORMAL		0x40000000
1592 #define NV20_3D_RC_IN_RGB_A_MAPPING_EXPAND_NEGATE		0x60000000
1593 #define NV20_3D_RC_IN_RGB_A_MAPPING_HALF_BIAS_NORMAL		0x80000000
1594 #define NV20_3D_RC_IN_RGB_A_MAPPING_HALF_BIAS_NEGATE		0xa0000000
1595 #define NV20_3D_RC_IN_RGB_A_MAPPING_SIGNED_IDENTITY		0xc0000000
1596 #define NV20_3D_RC_IN_RGB_A_MAPPING_SIGNED_NEGATE		0xe0000000
1597 
1598 #define NV20_3D_RC_CONSTANT_COLOR0(i0)			       (0x00000a60 + 0x4*(i0))
1599 #define NV20_3D_RC_CONSTANT_COLOR0_B__MASK			0x000000ff
1600 #define NV20_3D_RC_CONSTANT_COLOR0_B__SHIFT			0
1601 #define NV20_3D_RC_CONSTANT_COLOR0_G__MASK			0x0000ff00
1602 #define NV20_3D_RC_CONSTANT_COLOR0_G__SHIFT			8
1603 #define NV20_3D_RC_CONSTANT_COLOR0_R__MASK			0x00ff0000
1604 #define NV20_3D_RC_CONSTANT_COLOR0_R__SHIFT			16
1605 #define NV20_3D_RC_CONSTANT_COLOR0_A__MASK			0xff000000
1606 #define NV20_3D_RC_CONSTANT_COLOR0_A__SHIFT			24
1607 
1608 #define NV20_3D_RC_CONSTANT_COLOR1(i0)			       (0x00000a80 + 0x4*(i0))
1609 #define NV20_3D_RC_CONSTANT_COLOR1_B__MASK			0x000000ff
1610 #define NV20_3D_RC_CONSTANT_COLOR1_B__SHIFT			0
1611 #define NV20_3D_RC_CONSTANT_COLOR1_G__MASK			0x0000ff00
1612 #define NV20_3D_RC_CONSTANT_COLOR1_G__SHIFT			8
1613 #define NV20_3D_RC_CONSTANT_COLOR1_R__MASK			0x00ff0000
1614 #define NV20_3D_RC_CONSTANT_COLOR1_R__SHIFT			16
1615 #define NV20_3D_RC_CONSTANT_COLOR1_A__MASK			0xff000000
1616 #define NV20_3D_RC_CONSTANT_COLOR1_A__SHIFT			24
1617 
1618 #define NV20_3D_RC_OUT_ALPHA(i0)			       (0x00000aa0 + 0x4*(i0))
1619 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT__MASK			0x0000000f
1620 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT__SHIFT			0
1621 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_ZERO			0x00000000
1622 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_CONSTANT_COLOR0		0x00000001
1623 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_CONSTANT_COLOR1		0x00000002
1624 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_FOG			0x00000003
1625 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_PRIMARY_COLOR		0x00000004
1626 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_SECONDARY_COLOR		0x00000005
1627 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE0			0x00000008
1628 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE1			0x00000009
1629 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE2			0x0000000a
1630 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_TEXTURE3			0x0000000b
1631 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_SPARE0			0x0000000c
1632 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_SPARE1			0x0000000d
1633 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR	0x0000000e
1634 #define NV20_3D_RC_OUT_ALPHA_CD_OUTPUT_E_TIMES_F		0x0000000f
1635 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT__MASK			0x000000f0
1636 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT__SHIFT			4
1637 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_ZERO			0x00000000
1638 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_CONSTANT_COLOR0		0x00000010
1639 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_CONSTANT_COLOR1		0x00000020
1640 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_FOG			0x00000030
1641 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_PRIMARY_COLOR		0x00000040
1642 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_SECONDARY_COLOR		0x00000050
1643 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE0			0x00000080
1644 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE1			0x00000090
1645 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE2			0x000000a0
1646 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_TEXTURE3			0x000000b0
1647 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_SPARE0			0x000000c0
1648 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_SPARE1			0x000000d0
1649 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR	0x000000e0
1650 #define NV20_3D_RC_OUT_ALPHA_AB_OUTPUT_E_TIMES_F		0x000000f0
1651 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT__MASK			0x00000f00
1652 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT__SHIFT			8
1653 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_ZERO			0x00000000
1654 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_CONSTANT_COLOR0		0x00000100
1655 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_CONSTANT_COLOR1		0x00000200
1656 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_FOG			0x00000300
1657 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_PRIMARY_COLOR		0x00000400
1658 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_SECONDARY_COLOR		0x00000500
1659 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE0		0x00000800
1660 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE1		0x00000900
1661 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE2		0x00000a00
1662 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_TEXTURE3		0x00000b00
1663 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_SPARE0			0x00000c00
1664 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_SPARE1			0x00000d00
1665 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR	0x00000e00
1666 #define NV20_3D_RC_OUT_ALPHA_SUM_OUTPUT_E_TIMES_F		0x00000f00
1667 #define NV20_3D_RC_OUT_ALPHA_CD_DOT_PRODUCT			0x00001000
1668 #define NV20_3D_RC_OUT_ALPHA_AB_DOT_PRODUCT			0x00002000
1669 #define NV20_3D_RC_OUT_ALPHA_MUX_SUM				0x00004000
1670 #define NV20_3D_RC_OUT_ALPHA_BIAS__MASK				0x00008000
1671 #define NV20_3D_RC_OUT_ALPHA_BIAS__SHIFT			15
1672 #define NV20_3D_RC_OUT_ALPHA_BIAS_NONE				0x00000000
1673 #define NV20_3D_RC_OUT_ALPHA_BIAS_BIAS_BY_NEGATIVE_ONE_HALF	0x00008000
1674 #define NV20_3D_RC_OUT_ALPHA_SCALE__MASK			0x00030000
1675 #define NV20_3D_RC_OUT_ALPHA_SCALE__SHIFT			16
1676 #define NV20_3D_RC_OUT_ALPHA_SCALE_NONE				0x00000000
1677 #define NV20_3D_RC_OUT_ALPHA_SCALE_SCALE_BY_TWO			0x00010000
1678 #define NV20_3D_RC_OUT_ALPHA_SCALE_SCALE_BY_FOUR		0x00020000
1679 #define NV20_3D_RC_OUT_ALPHA_SCALE_SCALE_BY_ONE_HALF		0x00030000
1680 
1681 #define NV20_3D_RC_OUT_RGB(i0)				       (0x00001e40 + 0x4*(i0))
1682 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT__MASK			0x0000000f
1683 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT__SHIFT			0
1684 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_ZERO			0x00000000
1685 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_CONSTANT_COLOR0		0x00000001
1686 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_CONSTANT_COLOR1		0x00000002
1687 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_FOG			0x00000003
1688 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_PRIMARY_COLOR		0x00000004
1689 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_SECONDARY_COLOR		0x00000005
1690 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_TEXTURE0			0x00000008
1691 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_TEXTURE1			0x00000009
1692 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_TEXTURE2			0x0000000a
1693 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_TEXTURE3			0x0000000b
1694 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_SPARE0			0x0000000c
1695 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_SPARE1			0x0000000d
1696 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR	0x0000000e
1697 #define NV20_3D_RC_OUT_RGB_CD_OUTPUT_E_TIMES_F			0x0000000f
1698 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT__MASK			0x000000f0
1699 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT__SHIFT			4
1700 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_ZERO			0x00000000
1701 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_CONSTANT_COLOR0		0x00000010
1702 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_CONSTANT_COLOR1		0x00000020
1703 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_FOG			0x00000030
1704 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_PRIMARY_COLOR		0x00000040
1705 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_SECONDARY_COLOR		0x00000050
1706 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_TEXTURE0			0x00000080
1707 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_TEXTURE1			0x00000090
1708 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_TEXTURE2			0x000000a0
1709 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_TEXTURE3			0x000000b0
1710 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_SPARE0			0x000000c0
1711 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_SPARE1			0x000000d0
1712 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR	0x000000e0
1713 #define NV20_3D_RC_OUT_RGB_AB_OUTPUT_E_TIMES_F			0x000000f0
1714 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT__MASK			0x00000f00
1715 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT__SHIFT			8
1716 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_ZERO			0x00000000
1717 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_CONSTANT_COLOR0		0x00000100
1718 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_CONSTANT_COLOR1		0x00000200
1719 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_FOG			0x00000300
1720 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_PRIMARY_COLOR		0x00000400
1721 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_SECONDARY_COLOR		0x00000500
1722 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_TEXTURE0			0x00000800
1723 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_TEXTURE1			0x00000900
1724 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_TEXTURE2			0x00000a00
1725 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_TEXTURE3			0x00000b00
1726 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_SPARE0			0x00000c00
1727 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_SPARE1			0x00000d00
1728 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_SPARE0_PLUS_SECONDARY_COLOR	0x00000e00
1729 #define NV20_3D_RC_OUT_RGB_SUM_OUTPUT_E_TIMES_F			0x00000f00
1730 #define NV20_3D_RC_OUT_RGB_CD_DOT_PRODUCT			0x00001000
1731 #define NV20_3D_RC_OUT_RGB_AB_DOT_PRODUCT			0x00002000
1732 #define NV20_3D_RC_OUT_RGB_MUX_SUM				0x00004000
1733 #define NV20_3D_RC_OUT_RGB_BIAS__MASK				0x00008000
1734 #define NV20_3D_RC_OUT_RGB_BIAS__SHIFT				15
1735 #define NV20_3D_RC_OUT_RGB_BIAS_NONE				0x00000000
1736 #define NV20_3D_RC_OUT_RGB_BIAS_BIAS_BY_NEGATIVE_ONE_HALF	0x00008000
1737 #define NV20_3D_RC_OUT_RGB_SCALE__MASK				0x00030000
1738 #define NV20_3D_RC_OUT_RGB_SCALE__SHIFT				16
1739 #define NV20_3D_RC_OUT_RGB_SCALE_NONE				0x00000000
1740 #define NV20_3D_RC_OUT_RGB_SCALE_SCALE_BY_TWO			0x00010000
1741 #define NV20_3D_RC_OUT_RGB_SCALE_SCALE_BY_FOUR			0x00020000
1742 #define NV20_3D_RC_OUT_RGB_SCALE_SCALE_BY_ONE_HALF		0x00030000
1743 
1744 #define NV20_3D_RC_FINAL0					0x00000288
1745 #define NV20_3D_RC_FINAL0_D_INPUT__MASK				0x0000000f
1746 #define NV20_3D_RC_FINAL0_D_INPUT__SHIFT			0
1747 #define NV20_3D_RC_FINAL0_D_INPUT_ZERO				0x00000000
1748 #define NV20_3D_RC_FINAL0_D_INPUT_CONSTANT_COLOR0		0x00000001
1749 #define NV20_3D_RC_FINAL0_D_INPUT_CONSTANT_COLOR1		0x00000002
1750 #define NV20_3D_RC_FINAL0_D_INPUT_FOG				0x00000003
1751 #define NV20_3D_RC_FINAL0_D_INPUT_PRIMARY_COLOR			0x00000004
1752 #define NV20_3D_RC_FINAL0_D_INPUT_SECONDARY_COLOR		0x00000005
1753 #define NV20_3D_RC_FINAL0_D_INPUT_TEXTURE0			0x00000008
1754 #define NV20_3D_RC_FINAL0_D_INPUT_TEXTURE1			0x00000009
1755 #define NV20_3D_RC_FINAL0_D_INPUT_TEXTURE2			0x0000000a
1756 #define NV20_3D_RC_FINAL0_D_INPUT_TEXTURE3			0x0000000b
1757 #define NV20_3D_RC_FINAL0_D_INPUT_SPARE0			0x0000000c
1758 #define NV20_3D_RC_FINAL0_D_INPUT_SPARE1			0x0000000d
1759 #define NV20_3D_RC_FINAL0_D_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x0000000e
1760 #define NV20_3D_RC_FINAL0_D_INPUT_E_TIMES_F			0x0000000f
1761 #define NV20_3D_RC_FINAL0_D_COMPONENT_USAGE__MASK		0x00000010
1762 #define NV20_3D_RC_FINAL0_D_COMPONENT_USAGE__SHIFT		4
1763 #define NV20_3D_RC_FINAL0_D_COMPONENT_USAGE_RGB			0x00000000
1764 #define NV20_3D_RC_FINAL0_D_COMPONENT_USAGE_ALPHA		0x00000010
1765 #define NV20_3D_RC_FINAL0_D_MAPPING__MASK			0x000000e0
1766 #define NV20_3D_RC_FINAL0_D_MAPPING__SHIFT			5
1767 #define NV20_3D_RC_FINAL0_D_MAPPING_UNSIGNED_IDENTITY		0x00000000
1768 #define NV20_3D_RC_FINAL0_D_MAPPING_UNSIGNED_INVERT		0x00000020
1769 #define NV20_3D_RC_FINAL0_D_MAPPING_EXPAND_NORMAL		0x00000040
1770 #define NV20_3D_RC_FINAL0_D_MAPPING_EXPAND_NEGATE		0x00000060
1771 #define NV20_3D_RC_FINAL0_D_MAPPING_HALF_BIAS_NORMAL		0x00000080
1772 #define NV20_3D_RC_FINAL0_D_MAPPING_HALF_BIAS_NEGATE		0x000000a0
1773 #define NV20_3D_RC_FINAL0_D_MAPPING_SIGNED_IDENTITY		0x000000c0
1774 #define NV20_3D_RC_FINAL0_D_MAPPING_SIGNED_NEGATE		0x000000e0
1775 #define NV20_3D_RC_FINAL0_C_INPUT__MASK				0x00000f00
1776 #define NV20_3D_RC_FINAL0_C_INPUT__SHIFT			8
1777 #define NV20_3D_RC_FINAL0_C_INPUT_ZERO				0x00000000
1778 #define NV20_3D_RC_FINAL0_C_INPUT_CONSTANT_COLOR0		0x00000100
1779 #define NV20_3D_RC_FINAL0_C_INPUT_CONSTANT_COLOR1		0x00000200
1780 #define NV20_3D_RC_FINAL0_C_INPUT_FOG				0x00000300
1781 #define NV20_3D_RC_FINAL0_C_INPUT_PRIMARY_COLOR			0x00000400
1782 #define NV20_3D_RC_FINAL0_C_INPUT_SECONDARY_COLOR		0x00000500
1783 #define NV20_3D_RC_FINAL0_C_INPUT_TEXTURE0			0x00000800
1784 #define NV20_3D_RC_FINAL0_C_INPUT_TEXTURE1			0x00000900
1785 #define NV20_3D_RC_FINAL0_C_INPUT_TEXTURE2			0x00000a00
1786 #define NV20_3D_RC_FINAL0_C_INPUT_TEXTURE3			0x00000b00
1787 #define NV20_3D_RC_FINAL0_C_INPUT_SPARE0			0x00000c00
1788 #define NV20_3D_RC_FINAL0_C_INPUT_SPARE1			0x00000d00
1789 #define NV20_3D_RC_FINAL0_C_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x00000e00
1790 #define NV20_3D_RC_FINAL0_C_INPUT_E_TIMES_F			0x00000f00
1791 #define NV20_3D_RC_FINAL0_C_COMPONENT_USAGE__MASK		0x00001000
1792 #define NV20_3D_RC_FINAL0_C_COMPONENT_USAGE__SHIFT		12
1793 #define NV20_3D_RC_FINAL0_C_COMPONENT_USAGE_RGB			0x00000000
1794 #define NV20_3D_RC_FINAL0_C_COMPONENT_USAGE_ALPHA		0x00001000
1795 #define NV20_3D_RC_FINAL0_C_MAPPING__MASK			0x0000e000
1796 #define NV20_3D_RC_FINAL0_C_MAPPING__SHIFT			13
1797 #define NV20_3D_RC_FINAL0_C_MAPPING_UNSIGNED_IDENTITY		0x00000000
1798 #define NV20_3D_RC_FINAL0_C_MAPPING_UNSIGNED_INVERT		0x00002000
1799 #define NV20_3D_RC_FINAL0_C_MAPPING_EXPAND_NORMAL		0x00004000
1800 #define NV20_3D_RC_FINAL0_C_MAPPING_EXPAND_NEGATE		0x00006000
1801 #define NV20_3D_RC_FINAL0_C_MAPPING_HALF_BIAS_NORMAL		0x00008000
1802 #define NV20_3D_RC_FINAL0_C_MAPPING_HALF_BIAS_NEGATE		0x0000a000
1803 #define NV20_3D_RC_FINAL0_C_MAPPING_SIGNED_IDENTITY		0x0000c000
1804 #define NV20_3D_RC_FINAL0_C_MAPPING_SIGNED_NEGATE		0x0000e000
1805 #define NV20_3D_RC_FINAL0_B_INPUT__MASK				0x000f0000
1806 #define NV20_3D_RC_FINAL0_B_INPUT__SHIFT			16
1807 #define NV20_3D_RC_FINAL0_B_INPUT_ZERO				0x00000000
1808 #define NV20_3D_RC_FINAL0_B_INPUT_CONSTANT_COLOR0		0x00010000
1809 #define NV20_3D_RC_FINAL0_B_INPUT_CONSTANT_COLOR1		0x00020000
1810 #define NV20_3D_RC_FINAL0_B_INPUT_FOG				0x00030000
1811 #define NV20_3D_RC_FINAL0_B_INPUT_PRIMARY_COLOR			0x00040000
1812 #define NV20_3D_RC_FINAL0_B_INPUT_SECONDARY_COLOR		0x00050000
1813 #define NV20_3D_RC_FINAL0_B_INPUT_TEXTURE0			0x00080000
1814 #define NV20_3D_RC_FINAL0_B_INPUT_TEXTURE1			0x00090000
1815 #define NV20_3D_RC_FINAL0_B_INPUT_TEXTURE2			0x000a0000
1816 #define NV20_3D_RC_FINAL0_B_INPUT_TEXTURE3			0x000b0000
1817 #define NV20_3D_RC_FINAL0_B_INPUT_SPARE0			0x000c0000
1818 #define NV20_3D_RC_FINAL0_B_INPUT_SPARE1			0x000d0000
1819 #define NV20_3D_RC_FINAL0_B_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x000e0000
1820 #define NV20_3D_RC_FINAL0_B_INPUT_E_TIMES_F			0x000f0000
1821 #define NV20_3D_RC_FINAL0_B_COMPONENT_USAGE__MASK		0x00100000
1822 #define NV20_3D_RC_FINAL0_B_COMPONENT_USAGE__SHIFT		20
1823 #define NV20_3D_RC_FINAL0_B_COMPONENT_USAGE_RGB			0x00000000
1824 #define NV20_3D_RC_FINAL0_B_COMPONENT_USAGE_ALPHA		0x00100000
1825 #define NV20_3D_RC_FINAL0_B_MAPPING__MASK			0x00e00000
1826 #define NV20_3D_RC_FINAL0_B_MAPPING__SHIFT			21
1827 #define NV20_3D_RC_FINAL0_B_MAPPING_UNSIGNED_IDENTITY		0x00000000
1828 #define NV20_3D_RC_FINAL0_B_MAPPING_UNSIGNED_INVERT		0x00200000
1829 #define NV20_3D_RC_FINAL0_B_MAPPING_EXPAND_NORMAL		0x00400000
1830 #define NV20_3D_RC_FINAL0_B_MAPPING_EXPAND_NEGATE		0x00600000
1831 #define NV20_3D_RC_FINAL0_B_MAPPING_HALF_BIAS_NORMAL		0x00800000
1832 #define NV20_3D_RC_FINAL0_B_MAPPING_HALF_BIAS_NEGATE		0x00a00000
1833 #define NV20_3D_RC_FINAL0_B_MAPPING_SIGNED_IDENTITY		0x00c00000
1834 #define NV20_3D_RC_FINAL0_B_MAPPING_SIGNED_NEGATE		0x00e00000
1835 #define NV20_3D_RC_FINAL0_A_INPUT__MASK				0x0f000000
1836 #define NV20_3D_RC_FINAL0_A_INPUT__SHIFT			24
1837 #define NV20_3D_RC_FINAL0_A_INPUT_ZERO				0x00000000
1838 #define NV20_3D_RC_FINAL0_A_INPUT_CONSTANT_COLOR0		0x01000000
1839 #define NV20_3D_RC_FINAL0_A_INPUT_CONSTANT_COLOR1		0x02000000
1840 #define NV20_3D_RC_FINAL0_A_INPUT_FOG				0x03000000
1841 #define NV20_3D_RC_FINAL0_A_INPUT_PRIMARY_COLOR			0x04000000
1842 #define NV20_3D_RC_FINAL0_A_INPUT_SECONDARY_COLOR		0x05000000
1843 #define NV20_3D_RC_FINAL0_A_INPUT_TEXTURE0			0x08000000
1844 #define NV20_3D_RC_FINAL0_A_INPUT_TEXTURE1			0x09000000
1845 #define NV20_3D_RC_FINAL0_A_INPUT_TEXTURE2			0x0a000000
1846 #define NV20_3D_RC_FINAL0_A_INPUT_TEXTURE3			0x0b000000
1847 #define NV20_3D_RC_FINAL0_A_INPUT_SPARE0			0x0c000000
1848 #define NV20_3D_RC_FINAL0_A_INPUT_SPARE1			0x0d000000
1849 #define NV20_3D_RC_FINAL0_A_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x0e000000
1850 #define NV20_3D_RC_FINAL0_A_INPUT_E_TIMES_F			0x0f000000
1851 #define NV20_3D_RC_FINAL0_A_COMPONENT_USAGE__MASK		0x10000000
1852 #define NV20_3D_RC_FINAL0_A_COMPONENT_USAGE__SHIFT		28
1853 #define NV20_3D_RC_FINAL0_A_COMPONENT_USAGE_RGB			0x00000000
1854 #define NV20_3D_RC_FINAL0_A_COMPONENT_USAGE_ALPHA		0x10000000
1855 #define NV20_3D_RC_FINAL0_A_MAPPING__MASK			0xe0000000
1856 #define NV20_3D_RC_FINAL0_A_MAPPING__SHIFT			29
1857 #define NV20_3D_RC_FINAL0_A_MAPPING_UNSIGNED_IDENTITY		0x00000000
1858 #define NV20_3D_RC_FINAL0_A_MAPPING_UNSIGNED_INVERT		0x20000000
1859 #define NV20_3D_RC_FINAL0_A_MAPPING_EXPAND_NORMAL		0x40000000
1860 #define NV20_3D_RC_FINAL0_A_MAPPING_EXPAND_NEGATE		0x60000000
1861 #define NV20_3D_RC_FINAL0_A_MAPPING_HALF_BIAS_NORMAL		0x80000000
1862 #define NV20_3D_RC_FINAL0_A_MAPPING_HALF_BIAS_NEGATE		0xa0000000
1863 #define NV20_3D_RC_FINAL0_A_MAPPING_SIGNED_IDENTITY		0xc0000000
1864 #define NV20_3D_RC_FINAL0_A_MAPPING_SIGNED_NEGATE		0xe0000000
1865 
1866 #define NV20_3D_RC_FINAL1					0x0000028c
1867 #define NV20_3D_RC_FINAL1_COLOR_SUM_CLAMP			0x00000080
1868 #define NV20_3D_RC_FINAL1_G_INPUT__MASK				0x00000f00
1869 #define NV20_3D_RC_FINAL1_G_INPUT__SHIFT			8
1870 #define NV20_3D_RC_FINAL1_G_INPUT_ZERO				0x00000000
1871 #define NV20_3D_RC_FINAL1_G_INPUT_CONSTANT_COLOR0		0x00000100
1872 #define NV20_3D_RC_FINAL1_G_INPUT_CONSTANT_COLOR1		0x00000200
1873 #define NV20_3D_RC_FINAL1_G_INPUT_FOG				0x00000300
1874 #define NV20_3D_RC_FINAL1_G_INPUT_PRIMARY_COLOR			0x00000400
1875 #define NV20_3D_RC_FINAL1_G_INPUT_SECONDARY_COLOR		0x00000500
1876 #define NV20_3D_RC_FINAL1_G_INPUT_TEXTURE0			0x00000800
1877 #define NV20_3D_RC_FINAL1_G_INPUT_TEXTURE1			0x00000900
1878 #define NV20_3D_RC_FINAL1_G_INPUT_TEXTURE2			0x00000a00
1879 #define NV20_3D_RC_FINAL1_G_INPUT_TEXTURE3			0x00000b00
1880 #define NV20_3D_RC_FINAL1_G_INPUT_SPARE0			0x00000c00
1881 #define NV20_3D_RC_FINAL1_G_INPUT_SPARE1			0x00000d00
1882 #define NV20_3D_RC_FINAL1_G_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x00000e00
1883 #define NV20_3D_RC_FINAL1_G_INPUT_E_TIMES_F			0x00000f00
1884 #define NV20_3D_RC_FINAL1_G_COMPONENT_USAGE__MASK		0x00001000
1885 #define NV20_3D_RC_FINAL1_G_COMPONENT_USAGE__SHIFT		12
1886 #define NV20_3D_RC_FINAL1_G_COMPONENT_USAGE_RGB			0x00000000
1887 #define NV20_3D_RC_FINAL1_G_COMPONENT_USAGE_ALPHA		0x00001000
1888 #define NV20_3D_RC_FINAL1_G_MAPPING__MASK			0x0000e000
1889 #define NV20_3D_RC_FINAL1_G_MAPPING__SHIFT			13
1890 #define NV20_3D_RC_FINAL1_G_MAPPING_UNSIGNED_IDENTITY		0x00000000
1891 #define NV20_3D_RC_FINAL1_G_MAPPING_UNSIGNED_INVERT		0x00002000
1892 #define NV20_3D_RC_FINAL1_G_MAPPING_EXPAND_NORMAL		0x00004000
1893 #define NV20_3D_RC_FINAL1_G_MAPPING_EXPAND_NEGATE		0x00006000
1894 #define NV20_3D_RC_FINAL1_G_MAPPING_HALF_BIAS_NORMAL		0x00008000
1895 #define NV20_3D_RC_FINAL1_G_MAPPING_HALF_BIAS_NEGATE		0x0000a000
1896 #define NV20_3D_RC_FINAL1_G_MAPPING_SIGNED_IDENTITY		0x0000c000
1897 #define NV20_3D_RC_FINAL1_G_MAPPING_SIGNED_NEGATE		0x0000e000
1898 #define NV20_3D_RC_FINAL1_F_INPUT__MASK				0x000f0000
1899 #define NV20_3D_RC_FINAL1_F_INPUT__SHIFT			16
1900 #define NV20_3D_RC_FINAL1_F_INPUT_ZERO				0x00000000
1901 #define NV20_3D_RC_FINAL1_F_INPUT_CONSTANT_COLOR0		0x00010000
1902 #define NV20_3D_RC_FINAL1_F_INPUT_CONSTANT_COLOR1		0x00020000
1903 #define NV20_3D_RC_FINAL1_F_INPUT_FOG				0x00030000
1904 #define NV20_3D_RC_FINAL1_F_INPUT_PRIMARY_COLOR			0x00040000
1905 #define NV20_3D_RC_FINAL1_F_INPUT_SECONDARY_COLOR		0x00050000
1906 #define NV20_3D_RC_FINAL1_F_INPUT_TEXTURE0			0x00080000
1907 #define NV20_3D_RC_FINAL1_F_INPUT_TEXTURE1			0x00090000
1908 #define NV20_3D_RC_FINAL1_F_INPUT_TEXTURE2			0x000a0000
1909 #define NV20_3D_RC_FINAL1_F_INPUT_TEXTURE3			0x000b0000
1910 #define NV20_3D_RC_FINAL1_F_INPUT_SPARE0			0x000c0000
1911 #define NV20_3D_RC_FINAL1_F_INPUT_SPARE1			0x000d0000
1912 #define NV20_3D_RC_FINAL1_F_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x000e0000
1913 #define NV20_3D_RC_FINAL1_F_INPUT_E_TIMES_F			0x000f0000
1914 #define NV20_3D_RC_FINAL1_F_COMPONENT_USAGE__MASK		0x00100000
1915 #define NV20_3D_RC_FINAL1_F_COMPONENT_USAGE__SHIFT		20
1916 #define NV20_3D_RC_FINAL1_F_COMPONENT_USAGE_RGB			0x00000000
1917 #define NV20_3D_RC_FINAL1_F_COMPONENT_USAGE_ALPHA		0x00100000
1918 #define NV20_3D_RC_FINAL1_F_MAPPING__MASK			0x00e00000
1919 #define NV20_3D_RC_FINAL1_F_MAPPING__SHIFT			21
1920 #define NV20_3D_RC_FINAL1_F_MAPPING_UNSIGNED_IDENTITY		0x00000000
1921 #define NV20_3D_RC_FINAL1_F_MAPPING_UNSIGNED_INVERT		0x00200000
1922 #define NV20_3D_RC_FINAL1_F_MAPPING_EXPAND_NORMAL		0x00400000
1923 #define NV20_3D_RC_FINAL1_F_MAPPING_EXPAND_NEGATE		0x00600000
1924 #define NV20_3D_RC_FINAL1_F_MAPPING_HALF_BIAS_NORMAL		0x00800000
1925 #define NV20_3D_RC_FINAL1_F_MAPPING_HALF_BIAS_NEGATE		0x00a00000
1926 #define NV20_3D_RC_FINAL1_F_MAPPING_SIGNED_IDENTITY		0x00c00000
1927 #define NV20_3D_RC_FINAL1_F_MAPPING_SIGNED_NEGATE		0x00e00000
1928 #define NV20_3D_RC_FINAL1_E_INPUT__MASK				0x0f000000
1929 #define NV20_3D_RC_FINAL1_E_INPUT__SHIFT			24
1930 #define NV20_3D_RC_FINAL1_E_INPUT_ZERO				0x00000000
1931 #define NV20_3D_RC_FINAL1_E_INPUT_CONSTANT_COLOR0		0x01000000
1932 #define NV20_3D_RC_FINAL1_E_INPUT_CONSTANT_COLOR1		0x02000000
1933 #define NV20_3D_RC_FINAL1_E_INPUT_FOG				0x03000000
1934 #define NV20_3D_RC_FINAL1_E_INPUT_PRIMARY_COLOR			0x04000000
1935 #define NV20_3D_RC_FINAL1_E_INPUT_SECONDARY_COLOR		0x05000000
1936 #define NV20_3D_RC_FINAL1_E_INPUT_TEXTURE0			0x08000000
1937 #define NV20_3D_RC_FINAL1_E_INPUT_TEXTURE1			0x09000000
1938 #define NV20_3D_RC_FINAL1_E_INPUT_TEXTURE2			0x0a000000
1939 #define NV20_3D_RC_FINAL1_E_INPUT_TEXTURE3			0x0b000000
1940 #define NV20_3D_RC_FINAL1_E_INPUT_SPARE0			0x0c000000
1941 #define NV20_3D_RC_FINAL1_E_INPUT_SPARE1			0x0d000000
1942 #define NV20_3D_RC_FINAL1_E_INPUT_SPARE0_PLUS_SECONDARY_COLOR	0x0e000000
1943 #define NV20_3D_RC_FINAL1_E_INPUT_E_TIMES_F			0x0f000000
1944 #define NV20_3D_RC_FINAL1_E_COMPONENT_USAGE__MASK		0x10000000
1945 #define NV20_3D_RC_FINAL1_E_COMPONENT_USAGE__SHIFT		28
1946 #define NV20_3D_RC_FINAL1_E_COMPONENT_USAGE_RGB			0x00000000
1947 #define NV20_3D_RC_FINAL1_E_COMPONENT_USAGE_ALPHA		0x10000000
1948 #define NV20_3D_RC_FINAL1_E_MAPPING__MASK			0xe0000000
1949 #define NV20_3D_RC_FINAL1_E_MAPPING__SHIFT			29
1950 #define NV20_3D_RC_FINAL1_E_MAPPING_UNSIGNED_IDENTITY		0x00000000
1951 #define NV20_3D_RC_FINAL1_E_MAPPING_UNSIGNED_INVERT		0x20000000
1952 #define NV20_3D_RC_FINAL1_E_MAPPING_EXPAND_NORMAL		0x40000000
1953 #define NV20_3D_RC_FINAL1_E_MAPPING_EXPAND_NEGATE		0x60000000
1954 #define NV20_3D_RC_FINAL1_E_MAPPING_HALF_BIAS_NORMAL		0x80000000
1955 #define NV20_3D_RC_FINAL1_E_MAPPING_HALF_BIAS_NEGATE		0xa0000000
1956 #define NV20_3D_RC_FINAL1_E_MAPPING_SIGNED_IDENTITY		0xc0000000
1957 #define NV20_3D_RC_FINAL1_E_MAPPING_SIGNED_NEGATE		0xe0000000
1958 
1959 #define NV20_3D_RC_COLOR0					0x00001e20
1960 #define NV20_3D_RC_COLOR0_B__MASK				0x000000ff
1961 #define NV20_3D_RC_COLOR0_B__SHIFT				0
1962 #define NV20_3D_RC_COLOR0_G__MASK				0x0000ff00
1963 #define NV20_3D_RC_COLOR0_G__SHIFT				8
1964 #define NV20_3D_RC_COLOR0_R__MASK				0x00ff0000
1965 #define NV20_3D_RC_COLOR0_R__SHIFT				16
1966 #define NV20_3D_RC_COLOR0_A__MASK				0xff000000
1967 #define NV20_3D_RC_COLOR0_A__SHIFT				24
1968 
1969 #define NV20_3D_RC_COLOR1					0x00001e24
1970 #define NV20_3D_RC_COLOR1_B__MASK				0x000000ff
1971 #define NV20_3D_RC_COLOR1_B__SHIFT				0
1972 #define NV20_3D_RC_COLOR1_G__MASK				0x0000ff00
1973 #define NV20_3D_RC_COLOR1_G__SHIFT				8
1974 #define NV20_3D_RC_COLOR1_R__MASK				0x00ff0000
1975 #define NV20_3D_RC_COLOR1_R__SHIFT				16
1976 #define NV20_3D_RC_COLOR1_A__MASK				0xff000000
1977 #define NV20_3D_RC_COLOR1_A__SHIFT				24
1978 
1979 #define NV20_3D_RC_ENABLE					0x00001e60
1980 #define NV20_3D_RC_ENABLE_NUM_COMBINERS__MASK			0x0000000f
1981 #define NV20_3D_RC_ENABLE_NUM_COMBINERS__SHIFT			0
1982 
1983 
1984 #define NV20_3D_POINT_SIZE					0x0000043c
1985 
1986 #define NV20_3D_POINT_PARAMETER(i0)			       (0x00000a30 + 0x4*(i0))
1987 #define NV20_3D_POINT_PARAMETER__ESIZE				0x00000004
1988 #define NV20_3D_POINT_PARAMETER__LEN				0x00000008
1989 
1990 #define NV20_3D_POLYGON_STIPPLE_ENABLE				0x0000147c
1991 
1992 #define NV20_3D_POLYGON_STIPPLE_PATTERN(i0)		       (0x00001480 + 0x4*(i0))
1993 #define NV20_3D_POLYGON_STIPPLE_PATTERN__ESIZE			0x00000004
1994 #define NV20_3D_POLYGON_STIPPLE_PATTERN__LEN			0x00000020
1995 
1996 #define NV20_3D_COLOR_LOGIC_OP_ENABLE				0x000017bc
1997 
1998 #define NV20_3D_COLOR_LOGIC_OP_OP				0x000017c0
1999 #define NV20_3D_COLOR_LOGIC_OP_OP_CLEAR				0x00001500
2000 #define NV20_3D_COLOR_LOGIC_OP_OP_AND				0x00001501
2001 #define NV20_3D_COLOR_LOGIC_OP_OP_AND_REVERSE			0x00001502
2002 #define NV20_3D_COLOR_LOGIC_OP_OP_COPY				0x00001503
2003 #define NV20_3D_COLOR_LOGIC_OP_OP_AND_INVERTED			0x00001504
2004 #define NV20_3D_COLOR_LOGIC_OP_OP_NOOP				0x00001505
2005 #define NV20_3D_COLOR_LOGIC_OP_OP_XOR				0x00001506
2006 #define NV20_3D_COLOR_LOGIC_OP_OP_OR				0x00001507
2007 #define NV20_3D_COLOR_LOGIC_OP_OP_NOR				0x00001508
2008 #define NV20_3D_COLOR_LOGIC_OP_OP_EQUIV				0x00001509
2009 #define NV20_3D_COLOR_LOGIC_OP_OP_INVERT			0x0000150a
2010 #define NV20_3D_COLOR_LOGIC_OP_OP_OR_REVERSE			0x0000150b
2011 #define NV20_3D_COLOR_LOGIC_OP_OP_COPY_INVERTED			0x0000150c
2012 #define NV20_3D_COLOR_LOGIC_OP_OP_OR_INVERTED			0x0000150d
2013 #define NV20_3D_COLOR_LOGIC_OP_OP_NAND				0x0000150e
2014 #define NV20_3D_COLOR_LOGIC_OP_OP_SET				0x0000150f
2015 
2016 #define NV20_3D_DEPTH_CLAMP					0x00001d78
2017 
2018 #define NV20_3D_MULTISAMPLE_CONTROL				0x00001d7c
2019 
2020 
2021 #define NV20_3D_CLEAR_DEPTH_VALUE				0x00001d8c
2022 
2023 #define NV20_3D_CLEAR_VALUE					0x00001d90
2024 
2025 #define NV20_3D_CLEAR_BUFFERS					0x00001d94
2026 #define NV20_3D_CLEAR_BUFFERS_COLOR_A				0x00000080
2027 #define NV20_3D_CLEAR_BUFFERS_COLOR_B				0x00000040
2028 #define NV20_3D_CLEAR_BUFFERS_COLOR_G				0x00000020
2029 #define NV20_3D_CLEAR_BUFFERS_COLOR_R				0x00000010
2030 #define NV20_3D_CLEAR_BUFFERS_STENCIL				0x00000002
2031 #define NV20_3D_CLEAR_BUFFERS_DEPTH				0x00000001
2032 
2033 
2034 #define NV25_3D_DMA_HIERZ					0x000001b0
2035 
2036 #define NV25_3D_HIERZ_PITCH					0x0000022c
2037 
2038 #define NV25_3D_HIERZ_OFFSET					0x00000230
2039 
2040 #define NV20_3D_UNK09F8						0x000009f8
2041 
2042 #define NV20_3D_UNK09FC						0x000009fc
2043 
2044 #define NV20_3D_UNK17CC						0x000017cc
2045 
2046 #define NV20_3D_UNK17E0						0x000017e0
2047 
2048 #define NV20_3D_UNK17E4						0x000017e4
2049 
2050 #define NV20_3D_UNK17E8						0x000017e8
2051 
2052 #define NV20_3D_UNK17EC						0x000017ec
2053 
2054 #define NV20_3D_UNK17F0						0x000017f0
2055 
2056 #define NV20_3D_UNK17F4						0x000017f4
2057 
2058 #define NV20_3D_UNK1D80						0x00001d80
2059 
2060 #define NV20_3D_UNK1D84						0x00001d84
2061 
2062 #define NV20_3D_UNK1E68						0x00001e68
2063 
2064 #define NV20_3D_UNK1E98						0x00001e98
2065 
2066 
2067 #define NV25_3D_UNK01AC						0x000001ac
2068 
2069 #define NV25_3D_UNK0A1C						0x00000a1c
2070 
2071 #define NV25_3D_UNK1D88						0x00001d88
2072 
2073 #define NV25_3D_UNK1DA4						0x00001da4
2074 
2075 
2076 #endif /* NV20_3D_XML */
2077