mirror of
https://github.com/AntonioND/dsma-library.git
synced 2025-06-18 16:45:33 -04:00
Wait for GPU to be idle before measuring
This commit is contained in:
parent
307002d616
commit
79b065d8f6
@ -214,6 +214,9 @@ int main(void)
|
||||
|
||||
draw_and_update_models();
|
||||
|
||||
// Wait for geometry engine operations to end
|
||||
while (GFX_STATUS & BIT(27));
|
||||
|
||||
uint32_t end_time = cpuEndTiming();
|
||||
|
||||
const float us_per_frame = 1000000.0 / 60.0;
|
||||
@ -221,9 +224,6 @@ int main(void)
|
||||
end_time, timerTicks2usec(end_time),
|
||||
100.0 * timerTicks2usec(end_time) / us_per_frame);
|
||||
|
||||
// Wait for geometry engine operations to end
|
||||
while (GFX_STATUS & BIT(27));
|
||||
|
||||
printf("\x1b[23;0HPolys: %4d Vertices: %4d",
|
||||
GFX_POLYGON_RAM_USAGE, GFX_VERTEX_RAM_USAGE);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user