SL-13406, cleanup and format changes
parent
21cf868f38
commit
fb45ca014c
|
|
@ -911,28 +911,28 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot)
|
|||
|
||||
stop_glerror();
|
||||
|
||||
gGL.setColorMask(true, true);
|
||||
|
||||
if (LLPipeline::sRenderDeferred)
|
||||
{
|
||||
gPipeline.mDeferredScreen.bindTarget();
|
||||
glClearColor(1,0,1,1);
|
||||
gPipeline.mDeferredScreen.clear();
|
||||
}
|
||||
else
|
||||
{
|
||||
gPipeline.mScreen.bindTarget();
|
||||
if (LLPipeline::sUnderWaterRender && !gPipeline.canUseWindLightShaders())
|
||||
{
|
||||
const LLColor4 &col = LLEnvironment::instance().getCurrentWater()->getWaterFogColor();
|
||||
glClearColor(col.mV[0], col.mV[1], col.mV[2], 0.f);
|
||||
}
|
||||
gPipeline.mScreen.clear();
|
||||
}
|
||||
|
||||
gGL.setColorMask(true, false);
|
||||
|
||||
LLAppViewer::instance()->pingMainloopTimeout("Display:RenderGeom");
|
||||
gGL.setColorMask(true, true);
|
||||
|
||||
if (LLPipeline::sRenderDeferred)
|
||||
{
|
||||
gPipeline.mDeferredScreen.bindTarget();
|
||||
glClearColor(1, 0, 1, 1);
|
||||
gPipeline.mDeferredScreen.clear();
|
||||
}
|
||||
else
|
||||
{
|
||||
gPipeline.mScreen.bindTarget();
|
||||
if (LLPipeline::sUnderWaterRender && !gPipeline.canUseWindLightShaders())
|
||||
{
|
||||
const LLColor4 &col = LLEnvironment::instance().getCurrentWater()->getWaterFogColor();
|
||||
glClearColor(col.mV[0], col.mV[1], col.mV[2], 0.f);
|
||||
}
|
||||
gPipeline.mScreen.clear();
|
||||
}
|
||||
|
||||
gGL.setColorMask(true, false);
|
||||
|
||||
LLAppViewer::instance()->pingMainloopTimeout("Display:RenderGeom");
|
||||
|
||||
if (!(LLAppViewer::instance()->logoutRequestSent() && LLAppViewer::instance()->hasSavedFinalSnapshot())
|
||||
&& !gRestoreGL)
|
||||
|
|
@ -994,20 +994,20 @@ void display(BOOL rebuild, F32 zoom_factor, int subfield, BOOL for_snapshot)
|
|||
}
|
||||
}
|
||||
|
||||
LLAppViewer::instance()->pingMainloopTimeout("Display:RenderFlush");
|
||||
|
||||
|
||||
LLAppViewer::instance()->pingMainloopTimeout("Display:RenderFlush");
|
||||
|
||||
LLRenderTarget &rt = (gPipeline.sRenderDeferred ? gPipeline.mDeferredScreen : gPipeline.mScreen);
|
||||
rt.flush();
|
||||
|
||||
if (rt.sUseFBO)
|
||||
{
|
||||
LLRenderTarget::copyContentsToFramebuffer(rt, 0, 0, rt.getWidth(), rt.getHeight(), 0, 0, rt.getWidth(), rt.getHeight(), GL_DEPTH_BUFFER_BIT | GL_STENCIL_BUFFER_BIT, GL_NEAREST);
|
||||
LLRenderTarget::copyContentsToFramebuffer(rt, 0, 0, rt.getWidth(), rt.getHeight(), 0, 0, rt.getWidth(),
|
||||
rt.getHeight(), GL_DEPTH_BUFFER_BIT | GL_STENCIL_BUFFER_BIT,
|
||||
GL_NEAREST);
|
||||
}
|
||||
|
||||
|
||||
if (LLPipeline::sRenderDeferred)
|
||||
{
|
||||
if (LLPipeline::sRenderDeferred)
|
||||
{
|
||||
gPipeline.renderDeferredLighting(&gPipeline.mScreen);
|
||||
}
|
||||
|
||||
|
|
@ -1271,10 +1271,11 @@ void render_ui(F32 zoom_factor, int subfield)
|
|||
gGL.popMatrix();
|
||||
}
|
||||
|
||||
gPipeline.renderPost(gSnapshot, zoom_factor, subfield);
|
||||
|
||||
LL_RECORD_BLOCK_TIME(FTM_RENDER_HUD);
|
||||
render_hud_elements();
|
||||
// Finalize scene
|
||||
gPipeline.renderFinalize();
|
||||
|
||||
LL_RECORD_BLOCK_TIME(FTM_RENDER_HUD);
|
||||
render_hud_elements();
|
||||
render_hud_attachments();
|
||||
|
||||
LLGLSDefault gls_default;
|
||||
|
|
|
|||
File diff suppressed because it is too large
Load Diff
|
|
@ -139,7 +139,7 @@ public:
|
|||
void resetVertexBuffers(LLDrawable* drawable);
|
||||
void generateImpostor(LLVOAvatar* avatar);
|
||||
void bindScreenToTexture();
|
||||
void renderPost(bool for_snapshot, F32 zoom_factor = 1.f, int subfield = 0);
|
||||
void renderFinalize();
|
||||
|
||||
void init();
|
||||
void cleanup();
|
||||
|
|
|
|||
Loading…
Reference in New Issue