1bd877ea2SRudolf Cornelissen /* 2bd877ea2SRudolf Cornelissen definitions for used nVidia acceleration engine commands. 3bd877ea2SRudolf Cornelissen 4224b9020SRudolf Cornelissen Written by Rudolf Cornelissen 12/2004-12/2005 5bd877ea2SRudolf Cornelissen */ 6bd877ea2SRudolf Cornelissen 7bd877ea2SRudolf Cornelissen #ifndef NV_ACC_H 8bd877ea2SRudolf Cornelissen #define NV_ACC_H 9bd877ea2SRudolf Cornelissen 10bd877ea2SRudolf Cornelissen typedef struct { 11f0cb8f72SRudolf Cornelissen uint32 reserved00[0x0004]; 12e549fa89SRudolf Cornelissen uint16 FifoFree; /* little endian (FIFO internal register) */ 13e549fa89SRudolf Cornelissen uint16 Nop; /* little endian (FIFO internal register) */ 14b1e0087bSRudolf Cornelissen uint32 reserved01[0x000b]; 15b1e0087bSRudolf Cornelissen uint32 DMAPut; /* b2-28 is DMA Put offset (FIFO internal register) */ 16b1e0087bSRudolf Cornelissen uint32 DMAGet; /* b2-28 is DMA Get offset (FIFO internal register) */ 17b1e0087bSRudolf Cornelissen uint32 reserved02[0x00ae]; 189daf2efeSRudolf Cornelissen uint32 SetRop5; /* b0-7 is ROP5 */ 19bd877ea2SRudolf Cornelissen } cmd_nv_rop5_solid; 20bd877ea2SRudolf Cornelissen 21bd877ea2SRudolf Cornelissen typedef struct { 229daf2efeSRudolf Cornelissen uint32 reserved00[0x0004]; 239daf2efeSRudolf Cornelissen uint16 FifoFree; /* little endian (FIFO internal register) */ 249daf2efeSRudolf Cornelissen uint16 Nop; /* little endian (FIFO internal register) */ 25b1e0087bSRudolf Cornelissen uint32 reserved01[0x000b]; 26b1e0087bSRudolf Cornelissen uint32 DMAPut; /* b2-28 is DMA Put offset (FIFO internal register) */ 27b1e0087bSRudolf Cornelissen uint32 DMAGet; /* b2-28 is DMA Get offset (FIFO internal register) */ 28b1e0087bSRudolf Cornelissen uint32 reserved02[0x00ae]; 299daf2efeSRudolf Cornelissen uint32 TopLeft; /* b0-15 is left, b16-31 is top */ 309daf2efeSRudolf Cornelissen uint32 HeightWidth; /* b0-15 is width, b16-31 is height */ 31bd877ea2SRudolf Cornelissen } cmd_nv_image_black_rectangle; 32bd877ea2SRudolf Cornelissen 33bd877ea2SRudolf Cornelissen typedef struct { 349daf2efeSRudolf Cornelissen uint32 reserved00[0x0004]; 359daf2efeSRudolf Cornelissen uint16 FifoFree; /* little endian (FIFO internal register) */ 369daf2efeSRudolf Cornelissen uint16 Nop; /* little endian (FIFO internal register) */ 37b1e0087bSRudolf Cornelissen uint32 reserved01[0x000b]; 38b1e0087bSRudolf Cornelissen uint32 DMAPut; /* b2-28 is DMA Put offset (FIFO internal register) */ 39b1e0087bSRudolf Cornelissen uint32 DMAGet; /* b2-28 is DMA Get offset (FIFO internal register) */ 408118b759SRudolf Cornelissen uint32 reserved02[0x00ae]; 418118b759SRudolf Cornelissen uint32 SetColorFormat; /* colorspace */ 42b1e0087bSRudolf Cornelissen uint32 reserved03[0x0001]; 438118b759SRudolf Cornelissen uint32 SetShape; /* b0-1: %00 = 8X_8Y; %01 = 64X_1Y; %10 = 1X_64Y */ 448118b759SRudolf Cornelissen uint32 reserved04[0x0001]; 459daf2efeSRudolf Cornelissen uint32 SetColor0; /* b0-31 is color */ 469daf2efeSRudolf Cornelissen uint32 SetColor1; /* b0-31 is color */ 479daf2efeSRudolf Cornelissen uint32 SetPattern[0x0002]; /* b0-31 is bitmap */ 48bd877ea2SRudolf Cornelissen } cmd_nv_image_pattern; 49bd877ea2SRudolf Cornelissen 50bd877ea2SRudolf Cornelissen typedef struct { 519daf2efeSRudolf Cornelissen uint32 reserved00[0x0004]; 529daf2efeSRudolf Cornelissen uint16 FifoFree; /* little endian (FIFO internal register) */ 539daf2efeSRudolf Cornelissen uint16 Nop; /* little endian (FIFO internal register) */ 54b1e0087bSRudolf Cornelissen uint32 reserved01[0x000b]; 55b1e0087bSRudolf Cornelissen uint32 DMAPut; /* b2-28 is DMA Put offset (FIFO internal register) */ 56b1e0087bSRudolf Cornelissen uint32 DMAGet; /* b2-28 is DMA Get offset (FIFO internal register) */ 57b1e0087bSRudolf Cornelissen uint32 reserved02[0x00ae]; 589daf2efeSRudolf Cornelissen uint32 SourceOrg; /* b0-15 is X, b16-31 is Y */ 599daf2efeSRudolf Cornelissen uint32 DestOrg; /* b0-15 is X, b16-31 is Y */ 609daf2efeSRudolf Cornelissen uint32 HeightWidth; /* b0-15 is width, b16-31 is height */ 61bd877ea2SRudolf Cornelissen } cmd_nv_image_blit; 62bd877ea2SRudolf Cornelissen 63940dbde6SRudolf Cornelissen //fixme: using nv4_gdi_rectangle_text for DMA acc. Differs slightly from this one! 64bffb1c3eSRudolf Cornelissen //WARNING: nv4_gdi_rectangle_text can only do 32 unclipped rects at once! 65bd877ea2SRudolf Cornelissen typedef struct { 6607e14ea9SRudolf Cornelissen uint32 reserved00[0x0004]; 6707e14ea9SRudolf Cornelissen uint16 FifoFree; /* little endian (FIFO internal register) */ 6807e14ea9SRudolf Cornelissen uint16 Nop; /* little endian (FIFO internal register) */ 69b1e0087bSRudolf Cornelissen uint32 reserved01[0x000b]; 70b1e0087bSRudolf Cornelissen uint32 DMAPut; /* b2-28 is DMA Put offset (FIFO internal register) */ 71b1e0087bSRudolf Cornelissen uint32 DMAGet; /* b2-28 is DMA Get offset (FIFO internal register) */ 72a8c11977SRudolf Cornelissen uint32 reserved02[0x00ae]; 73a8c11977SRudolf Cornelissen uint32 SetColorFormat; /* colorspace */ 74a8c11977SRudolf Cornelissen uint32 reserved03[0x003e]; 7507e14ea9SRudolf Cornelissen uint32 Color1A; /* b0-31 is color */ 765c2199fcSRudolf Cornelissen struct { 7707e14ea9SRudolf Cornelissen uint32 LeftTop; /* b0-15 is top, b16-31 is left */ 7807e14ea9SRudolf Cornelissen uint32 WidthHeight; /* b0-15 is height, b16-31 is width */ 7907e14ea9SRudolf Cornelissen } UnclippedRectangle[0x40]; /* command can handle upto 64 unclipped rects */ 800e0eb256SRudolf Cornelissen /* fixme: XFree also defines the registers below: 810e0eb256SRudolf Cornelissen * (used for the 2D 'ScanlineCPUToScreenColorExpandFill' and 'ColorExpandScanline' 820e0eb256SRudolf Cornelissen * functions.) 830e0eb256SRudolf Cornelissen * We don't use this currently. */ 8407e14ea9SRudolf Cornelissen /* 8507e14ea9SRudolf Cornelissen U032 reserved04[(0x080)-3]; 8607e14ea9SRudolf Cornelissen struct 8707e14ea9SRudolf Cornelissen { 8807e14ea9SRudolf Cornelissen U032 TopLeft; 8907e14ea9SRudolf Cornelissen U032 BottomRight; 9007e14ea9SRudolf Cornelissen } ClipB; 9107e14ea9SRudolf Cornelissen U032 Color1B; 9207e14ea9SRudolf Cornelissen struct 9307e14ea9SRudolf Cornelissen { 9407e14ea9SRudolf Cornelissen U032 TopLeft; 9507e14ea9SRudolf Cornelissen U032 BottomRight; 9607e14ea9SRudolf Cornelissen } ClippedRectangle[64]; 9707e14ea9SRudolf Cornelissen U032 reserved05[(0x080)-5]; 9807e14ea9SRudolf Cornelissen struct 9907e14ea9SRudolf Cornelissen { 10007e14ea9SRudolf Cornelissen U032 TopLeft; 10107e14ea9SRudolf Cornelissen U032 BottomRight; 10207e14ea9SRudolf Cornelissen } ClipC; 10307e14ea9SRudolf Cornelissen U032 Color1C; 10407e14ea9SRudolf Cornelissen U032 WidthHeightC; 10507e14ea9SRudolf Cornelissen U032 PointC; 10607e14ea9SRudolf Cornelissen U032 MonochromeData1C; 10707e14ea9SRudolf Cornelissen U032 reserved06[(0x080)+121]; 10807e14ea9SRudolf Cornelissen struct 10907e14ea9SRudolf Cornelissen { 11007e14ea9SRudolf Cornelissen U032 TopLeft; 11107e14ea9SRudolf Cornelissen U032 BottomRight; 11207e14ea9SRudolf Cornelissen } ClipD; 11307e14ea9SRudolf Cornelissen U032 Color1D; 11407e14ea9SRudolf Cornelissen U032 WidthHeightInD; 11507e14ea9SRudolf Cornelissen U032 WidthHeightOutD; 11607e14ea9SRudolf Cornelissen U032 PointD; 11707e14ea9SRudolf Cornelissen U032 MonochromeData1D; 11807e14ea9SRudolf Cornelissen U032 reserved07[(0x080)+120]; 11907e14ea9SRudolf Cornelissen struct 12007e14ea9SRudolf Cornelissen { 12107e14ea9SRudolf Cornelissen U032 TopLeft; 12207e14ea9SRudolf Cornelissen U032 BottomRight; 12307e14ea9SRudolf Cornelissen } ClipE; 12407e14ea9SRudolf Cornelissen U032 Color0E; 12507e14ea9SRudolf Cornelissen U032 Color1E; 12607e14ea9SRudolf Cornelissen U032 WidthHeightInE; 12707e14ea9SRudolf Cornelissen U032 WidthHeightOutE; 12807e14ea9SRudolf Cornelissen U032 PointE; 12907e14ea9SRudolf Cornelissen U032 MonochromeData01E; 13007e14ea9SRudolf Cornelissen */ 131bd877ea2SRudolf Cornelissen } cmd_nv3_gdi_rectangle_text; 132bd877ea2SRudolf Cornelissen 1330e0eb256SRudolf Cornelissen /* This command could (at least) potentially speed-up our fill_span command... :-) */ 1340e0eb256SRudolf Cornelissen //fixme: test this 2D command! 1350e0eb256SRudolf Cornelissen typedef struct { 1360e0eb256SRudolf Cornelissen uint32 reserved00[0x0004]; 1370e0eb256SRudolf Cornelissen uint16 FifoFree; /* little endian (FIFO internal register) */ 1380e0eb256SRudolf Cornelissen uint16 Nop; /* little endian (FIFO internal register) */ 139b1e0087bSRudolf Cornelissen uint32 reserved01[0x000b]; 140b1e0087bSRudolf Cornelissen uint32 DMAPut; /* b2-28 is DMA Put offset (FIFO internal register) */ 141b1e0087bSRudolf Cornelissen uint32 DMAGet; /* b2-28 is DMA Get offset (FIFO internal register) */ 142b1e0087bSRudolf Cornelissen uint32 reserved02[0x00af]; 1430e0eb256SRudolf Cornelissen uint32 Color; /* b0-31 is color */ 144b1e0087bSRudolf Cornelissen uint32 reserved03[0x003e]; 1450e0eb256SRudolf Cornelissen struct { 1460e0eb256SRudolf Cornelissen uint32 Point0; /* b0-15 is X, b16-31 is Y: starting coordinate */ 1470e0eb256SRudolf Cornelissen uint32 Point1; /* b0-15 is X, b16-31 is Y: ending coordinate */ 1480e0eb256SRudolf Cornelissen } Line[0x10]; /* command can handle upto 16 lines */ 1490e0eb256SRudolf Cornelissen struct { 1500e0eb256SRudolf Cornelissen uint32 Point0X; /* b0-31 is X: starting coordinate */ 1510e0eb256SRudolf Cornelissen uint32 Point0Y; /* b0-31 is Y: starting coordinate */ 1520e0eb256SRudolf Cornelissen uint32 Point1X; /* b0-31 is X: ending coordinate */ 1530e0eb256SRudolf Cornelissen uint32 Point1Y; /* b0-31 is Y: ending coordinate */ 1540e0eb256SRudolf Cornelissen } Line32[0x08]; /* cmd can handle upto 8 lines with 32-bit coordinates */ 1550e0eb256SRudolf Cornelissen struct { 1560e0eb256SRudolf Cornelissen uint32 Point; /* b0-15 is X, b16-31 is Y */ 1575f8c3a7fSRudolf Cornelissen } Polyline[0x20]; /* cmd can handle upto 32 points polylines */ 1580e0eb256SRudolf Cornelissen struct { 1590e0eb256SRudolf Cornelissen uint32 PointX; /* b0-31 is X */ 1600e0eb256SRudolf Cornelissen uint32 PointY; /* b0-31 is Y */ 1615f8c3a7fSRudolf Cornelissen } Polyline32[0x10]; /* cmd can handle upto 16 point polylines with 32-bit coord's */ 1620e0eb256SRudolf Cornelissen struct { 1630e0eb256SRudolf Cornelissen uint32 Color; /* b0-31 is color */ 1640e0eb256SRudolf Cornelissen uint32 Point; /* b0-15 is X, b16-31 is Y */ 1655f8c3a7fSRudolf Cornelissen } ColorPolyline[0x10]; /* cmd can handle upto 16 point polylines with individually 1665f8c3a7fSRudolf Cornelissen * colored sections */ 1670e0eb256SRudolf Cornelissen } cmd_nv1_render_solid_lin; 1680e0eb256SRudolf Cornelissen 1690e0eb256SRudolf Cornelissen /* Someone defined this in XFree once (as 'RivaRectangle') but never used it: 1700e0eb256SRudolf Cornelissen * a handle should also be defined in the engine's init code, which was never done AFAIK. 1710e0eb256SRudolf Cornelissen * The command could be very interesting for us, as it could potentially speed-up our 1720e0eb256SRudolf Cornelissen * rectangle_fills :-) */ 1730e0eb256SRudolf Cornelissen //fixme: test this 2D command! 1740e0eb256SRudolf Cornelissen typedef struct { 1750e0eb256SRudolf Cornelissen uint32 reserved00[0x0004]; 1760e0eb256SRudolf Cornelissen uint16 FifoFree; /* little endian (FIFO internal register) */ 1770e0eb256SRudolf Cornelissen uint16 Nop; /* little endian (FIFO internal register) */ 178b1e0087bSRudolf Cornelissen uint32 reserved01[0x000b]; 179b1e0087bSRudolf Cornelissen uint32 DMAPut; /* b2-28 is DMA Put offset (FIFO internal register) */ 180b1e0087bSRudolf Cornelissen uint32 DMAGet; /* b2-28 is DMA Get offset (FIFO internal register) */ 181b1e0087bSRudolf Cornelissen uint32 reserved02[0x00af]; 1820e0eb256SRudolf Cornelissen uint32 Color; /* b0-31 is color */ 183b1e0087bSRudolf Cornelissen uint32 reserved03[0x003e]; 1840e0eb256SRudolf Cornelissen struct { 1850e0eb256SRudolf Cornelissen uint32 TopLeft; /* b0-15 is left, b16-31 is top */ 1860e0eb256SRudolf Cornelissen uint32 HeightWidth; /* b0-15 is width, b16-31 is height */ 1870e0eb256SRudolf Cornelissen } Rectangle[0x10]; /* command can handle upto 16 rectangles */ 1880e0eb256SRudolf Cornelissen } cmd_nv_render_solid_rectangle;/* nv1_render_solid_rectangle is identical */ 1890e0eb256SRudolf Cornelissen 1903c8313fdSRudolf Cornelissen //fixme: (setup in progress for DMA) complete or remove (this cmd is not used currently) 1910e0eb256SRudolf Cornelissen typedef struct { 1920e0eb256SRudolf Cornelissen } cmd_nv1_image_from_cpu; /* 'pixmap': used in XFree 4.2.0, but not beyond. 1930e0eb256SRudolf Cornelissen * (Used for the 2D 'ImageWriteScanline' and 1940e0eb256SRudolf Cornelissen * 'ScanlineImageWriteRect' functions.) 1950e0eb256SRudolf Cornelissen * Is this command actually usefull? */ 1960e0eb256SRudolf Cornelissen 1974bf2b3ccSRudolf Cornelissen typedef struct { 1984bf2b3ccSRudolf Cornelissen uint32 reserved00[0x0004]; 1994bf2b3ccSRudolf Cornelissen uint16 FifoFree; /* little endian (FIFO internal register) */ 2004bf2b3ccSRudolf Cornelissen uint16 Nop; /* little endian (FIFO internal register) */ 2014bf2b3ccSRudolf Cornelissen uint32 reserved01[0x000b]; 2024bf2b3ccSRudolf Cornelissen uint32 DMAPut; /* b2-28 is DMA Put offset (FIFO internal register) */ 2034bf2b3ccSRudolf Cornelissen uint32 DMAGet; /* b2-28 is DMA Get offset (FIFO internal register) */ 2044bf2b3ccSRudolf Cornelissen uint32 reserved02[0x00ae]; 2054bf2b3ccSRudolf Cornelissen uint32 Format; /* buffer colorspace */ 2064bf2b3ccSRudolf Cornelissen uint32 Pitch; /* b0-15 is source pitch, b16-31 is dest pitch */ 2074bf2b3ccSRudolf Cornelissen uint32 OffsetSource; /* b0-31 is source bufferadress offset */ 2084bf2b3ccSRudolf Cornelissen uint32 OffsetDest; /* b0-31 is dest bufferadress offset */ 2094bf2b3ccSRudolf Cornelissen } cmd_nv4_surface; /* nv10_context_surfaces_2d is identical as far as used */ 2100e0eb256SRudolf Cornelissen 2110e0eb256SRudolf Cornelissen /************************ 2120e0eb256SRudolf Cornelissen * 3D specific commands * 2130e0eb256SRudolf Cornelissen ************************/ 2140e0eb256SRudolf Cornelissen 215bd877ea2SRudolf Cornelissen typedef struct { 2165c2199fcSRudolf Cornelissen uint32 reserved00[0x0004]; 2175c2199fcSRudolf Cornelissen uint16 FifoFree; /* little endian (FIFO internal register) */ 2185c2199fcSRudolf Cornelissen uint16 Nop; /* little endian (FIFO internal register) */ 219b1e0087bSRudolf Cornelissen uint32 reserved01[0x000b]; 220b1e0087bSRudolf Cornelissen uint32 DMAPut; /* b2-28 is DMA Put offset (FIFO internal register) */ 221b1e0087bSRudolf Cornelissen uint32 DMAGet; /* b2-28 is DMA Get offset (FIFO internal register) */ 222b1e0087bSRudolf Cornelissen uint32 reserved02[0x00ae]; 2235c2199fcSRudolf Cornelissen uint32 Colorkey; /* texture colorkey */ 2245c2199fcSRudolf Cornelissen uint32 Offset; /* texture offset */ 2255c2199fcSRudolf Cornelissen uint32 Format; /* texture colorspace, size, and a lot more */ 2265c2199fcSRudolf Cornelissen uint32 Filter; /* texture filtering modes (used for scaling) */ 2275c2199fcSRudolf Cornelissen uint32 Blend; /* triangle blend: shade, perspective, specular.. */ 2285c2199fcSRudolf Cornelissen uint32 Control; /* triangle control: Z-enable, culling, dither.. */ 2295c2199fcSRudolf Cornelissen uint32 FogColor; /* fog colorvalue */ 230b1e0087bSRudolf Cornelissen uint32 reserved03[0x0039]; 2315c2199fcSRudolf Cornelissen struct { 2320e0eb256SRudolf Cornelissen float ScreenX; /* X */ 2330e0eb256SRudolf Cornelissen float ScreenY; /* Y */ 2340e0eb256SRudolf Cornelissen float ScreenZ; /* depth */ 2350e0eb256SRudolf Cornelissen float RWH; /* eyeM */ 2365c2199fcSRudolf Cornelissen uint32 Color; /* b24-31 Alpha, b16-23 Red, b8-15 Green, b0-7 Blue */ 2375c2199fcSRudolf Cornelissen uint32 Specular; /* b24-31 Fog, b16-23 Red, b8-15 Green, b0-7 Blue */ 2380e0eb256SRudolf Cornelissen float TU; /* texture S */ 2390e0eb256SRudolf Cornelissen float TV; /* texture T */ 2405c2199fcSRudolf Cornelissen } TLVertex[0x10]; /* command can handle upto 16 textured, lit(?) vertexes */ 2415c2199fcSRudolf Cornelissen uint32 TLVDrawPrim[0x40]; /* b20-31 is I5, b16-19 is I4, b12-15 is I3, 2425c2199fcSRudolf Cornelissen * b8-11 is I2, 4-7 is I1, b0-3 is I0: 2435c2199fcSRudolf Cornelissen * Ix is a TLVertex[Ix]. 244b88dbb0cSRudolf Cornelissen * So: define your (single) texture, define your 245b88dbb0cSRudolf Cornelissen * vertexes, and then program TLVDrawPrim with the 246b88dbb0cSRudolf Cornelissen * order to draw them. 247b88dbb0cSRudolf Cornelissen * You can draw primitives consisting of sets of upto 248b88dbb0cSRudolf Cornelissen * 6 out of 16 defined vertexes this way; and you can 249b88dbb0cSRudolf Cornelissen * draw 64 sets maximum. */ 250b88dbb0cSRudolf Cornelissen } cmd_nv4_dx5_texture_triangle; /* nv10_dx5_texture_triangle is identical */ 251b88dbb0cSRudolf Cornelissen 252b88dbb0cSRudolf Cornelissen typedef struct { 253b88dbb0cSRudolf Cornelissen uint32 reserved00[0x0004]; 254b88dbb0cSRudolf Cornelissen uint16 FifoFree; /* little endian (FIFO internal register) */ 255b88dbb0cSRudolf Cornelissen uint16 Nop; /* little endian (FIFO internal register) */ 256b1e0087bSRudolf Cornelissen uint32 reserved01[0x000b]; 257b1e0087bSRudolf Cornelissen uint32 DMAPut; /* b2-28 is DMA Put offset (FIFO internal register) */ 258b1e0087bSRudolf Cornelissen uint32 DMAGet; /* b2-28 is DMA Get offset (FIFO internal register) */ 259b1e0087bSRudolf Cornelissen uint32 reserved02[0x00b0]; /* fixme? there's more here that's not used apparantly */ 260b88dbb0cSRudolf Cornelissen uint32 Pitch; /* b16-31 is Z-buffer, b0-15 is colorbuffer pitch */ 261b88dbb0cSRudolf Cornelissen uint32 SetOffsetColor; /* b0-31 is colorbuffer (renderbuffer) offset */ 262b88dbb0cSRudolf Cornelissen uint32 SetOffsetZeta; /* b0-31 is Z-buffer (zeta buffer) offset */ 263b88dbb0cSRudolf Cornelissen } cmd_nv4_context_surfaces_argb_zs; /* nv10_context_surfaces_argb_zs is identical */ 264bd877ea2SRudolf Cornelissen 2653c8313fdSRudolf Cornelissen //fixme: fill this out... 2660e0eb256SRudolf Cornelissen typedef struct { 2670e0eb256SRudolf Cornelissen } cmd_nv4_dx6_multi_texture_triangle;/* nv10_dx6_multi_texture_triangle is identical? */ 2680e0eb256SRudolf Cornelissen 26949057561SRudolf Cornelissen 27049057561SRudolf Cornelissen /************ DMA command defines ***********/ 27149057561SRudolf Cornelissen 272a9d9522bSRudolf Cornelissen /* FIFO channels */ 2736c001eb7SRudolf Cornelissen #define NV_GENERAL_FIFO_CH0 0x0000 2746c001eb7SRudolf Cornelissen #define NV_GENERAL_FIFO_CH1 0x2000 2756c001eb7SRudolf Cornelissen #define NV_GENERAL_FIFO_CH2 0x4000 2766c001eb7SRudolf Cornelissen #define NV_GENERAL_FIFO_CH3 0x6000 2776c001eb7SRudolf Cornelissen #define NV_GENERAL_FIFO_CH4 0x8000 2786c001eb7SRudolf Cornelissen #define NV_GENERAL_FIFO_CH5 0xa000 2796c001eb7SRudolf Cornelissen #define NV_GENERAL_FIFO_CH6 0xc000 2806c001eb7SRudolf Cornelissen #define NV_GENERAL_FIFO_CH7 0xe000 281a9d9522bSRudolf Cornelissen 282a9d9522bSRudolf Cornelissen /* sub-command offsets within FIFO channels */ 28349057561SRudolf Cornelissen #define NV_GENERAL_DMAPUT 0x0040 28449057561SRudolf Cornelissen #define NV_GENERAL_DMAGET 0x0044 28549057561SRudolf Cornelissen #define NV_ROP5_SOLID_SETROP5 0x0300 28698a4e5c7SRudolf Cornelissen #define NV_IMAGE_BLACK_RECTANGLE_TOPLEFT 0x0300 2878118b759SRudolf Cornelissen #define NV_IMAGE_PATTERN_SETCOLORFORMAT 0x0300 28849057561SRudolf Cornelissen #define NV_IMAGE_PATTERN_SETSHAPE 0x0308 28998a4e5c7SRudolf Cornelissen #define NV_IMAGE_PATTERN_SETCOLOR0 0x0310 29098a4e5c7SRudolf Cornelissen #define NV_IMAGE_BLIT_SOURCEORG 0x0300 291940dbde6SRudolf Cornelissen //fixme note: non-DMA acc is still using NV3_GDI_RECTANGLE_TEXT... 2929c47d9cbSRudolf Cornelissen //which is just as fast as NV4_GDI_RECTANGLE_TEXT, but has a hardware fault for DMA! 293940dbde6SRudolf Cornelissen #define NV4_GDI_RECTANGLE_TEXT_SETCOLORFORMAT 0x0300 294940dbde6SRudolf Cornelissen #define NV4_GDI_RECTANGLE_TEXT_COLOR1A 0x03fc 295940dbde6SRudolf Cornelissen #define NV4_GDI_RECTANGLE_TEXT_UCR0_LEFTTOP 0x0400 2964bf2b3ccSRudolf Cornelissen #define NV4_SURFACE_FORMAT 0x0300 297224b9020SRudolf Cornelissen #define NV_SCALED_IMAGE_FROM_MEMORY_SETCOLORFORMAT 0x0300 2983c8313fdSRudolf Cornelissen #define NV_SCALED_IMAGE_FROM_MEMORY_SOURCEORG 0x0308 29942a631e9SRudolf Cornelissen #define NV_SCALED_IMAGE_FROM_MEMORY_SOURCESIZE 0x0400 300224b9020SRudolf Cornelissen 301224b9020SRudolf Cornelissen 302*1deda8e7SRudolf Cornelissen /************************ 303*1deda8e7SRudolf Cornelissen * 3D specific commands * 304*1deda8e7SRudolf Cornelissen ************************/ 305224b9020SRudolf Cornelissen 30650fdc6cbSRudolf Cornelissen #define NV4_DX5_TEXTURE_TRIANGLE_COLORKEY 0x0300 307d4189794SRudolf Cornelissen #define NV4_DX5_TEXTURE_TRIANGLE_TLVERTEX(i) 0x0400 + (i << 5) 308d4189794SRudolf Cornelissen #define NV4_DX5_TEXTURE_TRIANGLE_TLVDRAWPRIM(i) 0x0600 + (i << 2) 309d4189794SRudolf Cornelissen #define NV4_CONTEXT_SURFACES_ARGB_ZS_PITCH 0x0308 31049057561SRudolf Cornelissen 311bd877ea2SRudolf Cornelissen #endif 312