UpdateBuffer

nn::gx::CTR::UpdateBuffer Function

Syntax

void UpdateBuffer(
     const void * pBuffer,
     size_t size
);

Parameters

Name Description
in pBuffer Pointer to the start of the buffer.
in size Buffer size.

Return Values

None.

Description

Applies to the graphics processor the updates that have been made to the contents of the vertex buffer and texture buffer in main memory.

When the GPU directly references texture, vertex, and other buffer data that has been expanded, copied, or overwritten into device memory by the CPU, use this to reflect those CPU-side changes in the GPU.

Specifically speaking, internal processing consists of flushing the cache, but Nintendo does not support using this function as a generic means of flushing the cache.

Only use this function to reflect CPU changes to the vertex and texture buffers in the GPU.

This function blocks in order to call system processes. There is a fixed processing overhead for each process call. To improve performance, call this function as infrequently as possible. In other words, try to collect updates into a large batch before calling it, rather than breaking the updates into small batches.

Revision History

2011/11/29
Added note about the overhead of making calls.
2011/03/23
Revised a part of the description.
2011/01/17
Enhanced the description.
2010/10/25
Initial version.

CONFIDENTIAL