nngxAdd3DCommand Function
NNGX_APICALL void NNGX_APIENTRY nngxAdd3DCommand(
GLvoid * bufferaddr,
GLsizei buffersize,
GLboolean copycmd
);
| Name | Description | |
|---|---|---|
| in | bufferaddr | Pointer to the data region where the 3D commands to add are located. |
| in | buffersize | Size (in bytes) of the 3D commands to add. |
| in | copycmd | Addition method (specifies whether to add a 3D command buffer or a render command request). |
Adds the data (3D commands) in the specified region to the current 3D command buffer.
If copycmd is GL_TRUE, the data in the region specified by bufferaddr is copied to the current 3D command buffer. Set buffersize equal to the number of bytes to copy. Behavior is not guaranteed if a 3D command buffer with split commands is copied.
If copycmd is GL_FALSE, a render command request is first generated with the region specified by bufferaddr as its execution address and then added to the current command requests. Set buffersize equal to the number of bytes in the 3D command buffer to execute. If unsplit 3D commands have accumulated in the current 3D command buffer, this function calls the nngxSplitDrawCmdlist function and then adds the newly generated render command request. Behavior is not guaranteed if the last command in the specified region is not a split command.
This function flushes the cache for the region specified by bufferaddr when copycmd is GL_FALSE. When a cache flush is unnecessary, it can be omitted by using the nngxAdd3DCommandNoCacheFlush function.
This function generates the following errors.
GL_ERROR_804E_DMP | No command list is currently bound. |
|---|---|
GL_ERROR_804F_DMP | Either buffersize is 0 or it is not a multiple of 16 (or not a multiple of 4 if copycmd is GL_TRUE). |
GL_ERROR_8050_DMP | The copycmd argument is GL_TRUE and the size of the current 3D command buffer is insufficient. |
GL_ERROR_8051_DMP | The copycmd argument is GL_FALSE and the size of the current command requests is insufficient. |
GL_ERROR_8052_DMP | The copycmd argument is GL_FALSE and the value specified for bufferaddr is not a multiple of 16. |
nngxAdd3DCommandNoCacheFlush function.GL_ERROR_804F_DMP).
CONFIDENTIAL