nngxGetProfilingResult Function
NNGX_APICALL void NNGX_APIENTRY nngxGetProfilingResult(
GLenum item,
GLuint * result
);
| Name | Description | |
|---|---|---|
| in | item |
Profiling functionality |
| in | result |
Profiling Results |
Gets the profiling results.
Returns in result the profiling results of the profiling functionality specified by item . Values that can be specified in item and profiling results that can be obtained in result are shown in the table below.
NN_GX_PROFILING_BUSY | Obtains the profiling results stored in busy counters. Obtains the busy count for each module since profiling started. A 16-bit busy count is obtained for each module. result specifies a buffer for storing four GLuint type values. Data is stored in the following order.
|
|---|---|
NN_GX_PROFILING_VERTEX_SHADER0 |
Obtains profiling results for Shader processor 0. Refer to the difference value between any two points as there is a constant count of this value. result specifies a buffer for five GLuint type values. Each counter is 32 bits. Data is stored in the following order.
|
| NN_GX_PROFILING_VERTEX_SHADER1 | Obtains profiling results for Shader processor 1. For details, see NN_GX_PROFILING_VERTEX_SHADER0, which is similar. |
NN_GX_PROFILING_VERTEX_SHADER2 | Obtains profiling results for Shader processor 2. For details, see NN_GX_PROFILING_VERTEX_SHADER0, which is similar. |
NN_GX_PROFILING_VERTEX_SHADER3 | Obtains profiling results for Shader processor 3. For details, see NN_GX_PROFILING_VERTEX_SHADER0, which is similar. |
NN_GX_PROFILING_VERTEX_CACHE |
Obtains the number of vertices input into the post vertex cache. result specifies a buffer for one GLuint type value. The obtained value is the result of the last rendering by glDrawElements (rendering made by writing 1 into PICA register 0x22F). Because the clock is cleared to 0 first for each rendering task, profiling results can be always be obtained for the most recently run rendering task. Even if the rendering task uses the same vertex data, obtained results may vary slightly depending on conditions, such as the timing at which vertex indices were loaded and how busy the last module of the post vertex cache is.
|
NN_GX_PROFILING_POLYGON |
Obtains the value of the counter storing the I/O polygon count. Refer to the difference value between any two points as there is a constant count of this value. result specifies a buffer for three GLuint type values. Each counter is 32 bits. Data is stored in the following order.
|
NN_GX_PROFILING_FRAGMENT |
Obtains the value of the counter storing the input fragment count. Refer to the difference value between any two points as there is a constant count of this value. result specifies a buffer for one GLuint type value. The counter value obtained is a 32-bit value that stores the number of fragments input to the per fragment operation module.
|
NN_GX_PROFILING_MEMORY_ACCESS | Gets the number of times the hardware modules have accessed memory. All counter values are 32-bit values, and multiplying these by 16 produces the actual number of bytes read and written.
|
Each counter rolls over to zero upon overflow. The busy counter starts counting from 0 when profiling starts. Although the vertex cache input vertex count counter counts from zero for each render, the other counters are reset to zero at hardware reset and then they count continuously. Counters that run continuously can be used to get profiling results for the interval you want to measure by referring to the difference in values between two points in time. The number of data items returned in result (in other words, the size of buffer specified for result) depends on item. The buffer size (measured in terms of the number of GLuint type values to be stored, rather than in bytes) required for result is defined by a macro. This is defined using names of the form NN_GX_PROFILING_RESULT_BUFSIZE_*** for NN_GX_PROFILING_*** items. For example, if NN_GX_PROFILING_BUSY is specified in item, the buffer specified in result must be able to store the number of GLuint type values defined by NN_GX_PROFILING_RESULT_BUFSIZE_BUSY.
Do not call this function while the GPU is executing (executing a command list). Although errors will not occur if called during GPU execution, the GPU may perform illegal operations.
This function generates the following errors.
GL_ERROR_80A4_DMP | An illegal value was specified in item. |
|---|
CONFIDENTIAL