History

fix snapshots and preview

SamGondelman committed 7 years ago

Commit e7d12dc1 parent c730e5114 files · +101 −85Browse files

Showing the changes to interface/src/graphics/GraphicsEngine.cpp (1 of 14 files). Show all

Unified · Split

interface/src/graphics/GraphicsEngine.cpp+3−1
@@ -245,6 +245,7 @@ void GraphicsEngine::render_performFrame() { · 244 unmodified lines
245245 }
246246
247247 std::queue<Application::SnapshotOperator> snapshotOperators;
248+ std::queue<Application::SecondarySnapshotOperator> secondarySnapshotOperators;
248249 if (!_programsCompiled.load()) {
249250 gpu::doInBatch("splashFrame", _gpuContext, [&](gpu::Batch& batch) {
250251 batch.setFramebuffer(finalFramebuffer);
@@ -273,12 +274,12 @@ void GraphicsEngine::render_performFrame() { · 22 unmodified lines
273274 renderArgs._hudOperator = displayPlugin->getHUDOperator();
274275 renderArgs._hudTexture = qApp->getApplicationOverlay().getOverlayTexture();
275276 renderArgs._takingSnapshot = qApp->takeSnapshotOperators(snapshotOperators);
277+ qApp->takeSecondarySnapshotOperators(secondarySnapshotOperators);
276278 renderArgs._blitFramebuffer = finalFramebuffer;
277279 render_runRenderFrame(&renderArgs);
278280 }
279281 }
280282
281− qDebug() << "boop" << renderArgs._takingSnapshot << snapshotOperators.size();
282283 auto frame = getGPUContext()->endFrame();
283284 frame->frameIndex = _renderFrameCount;
284285 frame->framebuffer = finalFramebuffer;
@@ -289,6 +290,7 @@ void GraphicsEngine::render_performFrame() { · 4 unmodified lines
289290 }
290291 };
291292 frame->snapshotOperators = snapshotOperators;
293+ frame->secondarySnapshotOperators = secondarySnapshotOperators;
292294 // deliver final scene rendering commands to the display plugin
293295 {
294296 PROFILE_RANGE(render, "/pluginOutput");