GPU/Commands: Difference between revisions
No edit summary |
|||
Line 1: | Line 1: | ||
This page describes the structure of the buffer for [[GX_Commands|GX command]] 1 with the registers at [[GPU|0x1EF018E0]]. This buffer is used for GPU commands including OpenGL commands, each 8-byte entry in the buffer is a command. Cmd+0 is the command parameter, and cmd+4 is the | This page describes the structure of the buffer for [[GX_Commands|GX command]] 1 with the registers at [[GPU|0x1EF018E0]]. This buffer is used for GPU commands including OpenGL commands, each 8-byte entry in the buffer is a command. Cmd+0 is the command parameter, and cmd+4 is the command header. | ||
=== Command Header === | |||
{| class="wikitable" border="1" | |||
! Bit | |||
! Description | |||
|- | |||
| 19-0 | |||
| Command ID | |||
|- | |||
| 31-20 | |||
| Total words following the command, if any. | |||
|} | |||
The first word in the parameter data structure is the command parameter value, the rest of the data structure is from the data following the command. The word after the last data structure word is usually padding. | |||
=== Commands === | === Commands === | ||
Line 33: | Line 46: | ||
| 0xXXXF02C1 | | 0xXXXF02C1 | ||
| float X coordinate for the first vertex | | float X coordinate for the first vertex | ||
| | | The vertex entries is the data following the command. | ||
|} | |} | ||
Line 42: | Line 55: | ||
|- | |- | ||
| 0 | | 0 | ||
| float X coordinate | | float X coordinate | ||
|- | |- | ||
| 1 | | 1 | ||
Line 49: | Line 62: | ||
| 2 | | 2 | ||
| float Z coordinate | | float Z coordinate | ||
|} | |} |