This example is using this Recorder.gpuElapsedNanoseconds
This API is only available from Unity 2020.1+
Tested both playmode & player:
- Works in DX11 / DX12 / Vulkan
- Does not work in OpenGLCore
HDRP is also using this API. The numbers can be found in Debug Window:
- Enter playmode
- Window > RenderPipeline > Render Pipeline Debug
- Display Stats tab
- Expand GPU timings
- Build Development build player
- Run player
- Ctrl+Backspace, debug menu will appear
- PgUp + PgDn to change tab
- Arrows and press enter