MCPcopy Create free account
hub / github.com/NVIDIAGameWorks/Falcor / resizeTargetFBO

Method resizeTargetFBO

Source/Falcor/Core/SampleApp.cpp:536–553  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

534}
535
536void SampleApp::resizeTargetFBO(uint32_t width, uint32_t height)
537{
538 // Resize target frame buffer.
539 auto pPrevFBO = mpTargetFBO;
540 mpTargetFBO = Fbo::create2D(mpDevice, width, height, pPrevFBO->getDesc());
541 mpDevice->getRenderContext()->blit(pPrevFBO->getColorTexture(0)->getSRV(), mpTargetFBO->getRenderTargetView(0));
542
543 // Tell the GUI the swap-chain size changed
544 if (mpGui)
545 mpGui->onWindowResize(width, height);
546
547 // Resize the pixel zoom
548 if (mpPixelZoom)
549 mpPixelZoom->onResize(mpTargetFBO.get());
550
551 // Call the user callback
552 onResize(width, height);
553}
554
555void SampleApp::initUI()
556{

Callers

nothing calls this directly

Calls 8

onResizeFunction · 0.85
blitMethod · 0.80
getColorTextureMethod · 0.80
getRenderTargetViewMethod · 0.80
onWindowResizeMethod · 0.80
getSRVMethod · 0.45
onResizeMethod · 0.45
getMethod · 0.45

Tested by

no test coverage detected