diff options
Diffstat (limited to 'indra/newview/llviewerdisplay.cpp')
-rw-r--r-- | indra/newview/llviewerdisplay.cpp | 35 |
1 files changed, 29 insertions, 6 deletions
diff --git a/indra/newview/llviewerdisplay.cpp b/indra/newview/llviewerdisplay.cpp index d1cb9dabf1..1d5caabebb 100644 --- a/indra/newview/llviewerdisplay.cpp +++ b/indra/newview/llviewerdisplay.cpp @@ -218,6 +218,29 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) LLMemType mt_render(LLMemType::MTYPE_RENDER); LLFastTimer t(FTM_RENDER); + if (gResizeScreenTexture) + { //skip render on frames where screen texture is resizing + gGL.flush(); + if (!for_snapshot) + { + glClear(GL_COLOR_BUFFER_BIT); + gViewerWindow->mWindow->swapBuffers(); + } + + gResizeScreenTexture = FALSE; + gPipeline.resizeScreenTexture(); + + if (!for_snapshot) + { + return; + } + } + + if (LLPipeline::sRenderDeferred) + { //hack to make sky show up in deferred snapshots + for_snapshot = FALSE; + } + if (LLPipeline::sRenderFrameTest) { send_agent_pause(); @@ -531,6 +554,7 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) gViewerWindow->setup3DViewport(); gPipeline.resetFrameStats(); // Reset per-frame statistics. + if (!gDisconnected) { LLMemType mt_du(LLMemType::MTYPE_DISPLAY_UPDATE); @@ -642,11 +666,11 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) LLVertexBuffer::clientCopy(0.016); } - if (gResizeScreenTexture) - { - gResizeScreenTexture = FALSE; - gPipeline.resizeScreenTexture(); - } + //if (gResizeScreenTexture) + //{ + // gResizeScreenTexture = FALSE; + // gPipeline.resizeScreenTexture(); + //} gGL.setColorMask(true, true); glClearColor(0,0,0,0); @@ -707,7 +731,6 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot) // // Doing this here gives hardware occlusion queries extra time to complete LLAppViewer::instance()->pingMainloopTimeout("Display:UpdateImages"); - LLError::LLCallStacks::clear() ; { LLMemType mt_iu(LLMemType::MTYPE_DISPLAY_IMAGE_UPDATE); |