MCPcopy Create free account
hub / github.com/baldurk/renderdoc / DisplayRendererPreview

Function DisplayRendererPreview

renderdoccmd/renderdoccmd_android.cpp:372–398  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

370}
371
372void DisplayRendererPreview(IReplayController *renderer, TextureDisplay &displayCfg, uint32_t width,
373 uint32_t height, uint32_t numLoops)
374{
375 ANativeWindow *connectionScreenWindow = android_state->window;
376
377 m_DrawLock.lock();
378
379 IReplayOutput *out = renderer->CreateOutput(CreateAndroidWindowingData(connectionScreenWindow),
380 ReplayOutputType::Texture);
381
382 out->SetTextureDisplay(displayCfg);
383
384 if(numLoops == 0)
385 numLoops = 100;
386
387 for(uint32_t i = 0; i < numLoops; i++)
388 {
389 renderer->SetFrameEvent(10000000, true);
390
391 ANDROID_LOG("Frame %u", i);
392 out->Display();
393
394 usleep(100000);
395 }
396
397 m_DrawLock.unlock();
398}
399
400// Returns the renderdoccmd arguments passed via am start
401// Examples: am start ... -e renderdoccmd "remoteserver"

Callers

nothing calls this directly

Calls 7

CreateOutputMethod · 0.80
SetTextureDisplayMethod · 0.80
DisplayMethod · 0.80
lockMethod · 0.45
SetFrameEventMethod · 0.45
unlockMethod · 0.45

Tested by

no test coverage detected