MCPcopy Create free account
hub / github.com/FlaxEngine/FlaxEngine / EndEvent

Method EndEvent

Source/Engine/Profiler/ProfilerGPU.cpp:117–133  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

115}
116
117void ProfilerGPU::EndEvent(int32 index)
118{
119 auto context = GPUDevice::Instance->GetMainContext();
120#if GPU_ALLOW_PROFILE_EVENTS
121 if (EventsEnabled)
122 context->EventEnd();
123#endif
124 if (index == -1)
125 return;
126 _depth--;
127
128 auto& buffer = Buffers[CurrentBuffer];
129 auto e = buffer.Get(index);
130 e->QueryActive = false;
131 e->Stats.Mix(RenderStatsData::Counter);
132 context->EndQuery(e->Query);
133}
134
135void ProfilerGPU::BeginFrame()
136{

Callers

nothing calls this directly

Calls 5

MixMethod · 0.80
GetMainContextMethod · 0.45
EventEndMethod · 0.45
GetMethod · 0.45
EndQueryMethod · 0.45

Tested by

no test coverage detected