summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2013-07-02 15:30:42 -0500
committerDave Parks <davep@lindenlab.com>2013-07-02 15:30:42 -0500
commit716f6b93355500c0aee378c0ce86a7dedcc24a9a (patch)
tree6cf8e8e4f32092aad83b9b731fb7a5075ebea6fa
parentd6d2f74fbbf22ba70166a97e15b6c3b39e42ac4d (diff)
NORSPEC-290 Disable occlusion culling for distortion render target since there are generally zero under water occluders.
-rwxr-xr-xindra/newview/pipeline.cpp8
1 files changed, 5 insertions, 3 deletions
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp
index 14529099b5..97abbc2815 100755
--- a/indra/newview/pipeline.cpp
+++ b/indra/newview/pipeline.cpp
@@ -9208,12 +9208,13 @@ void LLPipeline::generateWaterReflection(LLCamera& camera_in)
water_clip = 1;
}
+ S32 occlusion = LLPipeline::sUseOcclusion;
+ LLPipeline::sUseOcclusion = 0;
+
if (!LLViewerCamera::getInstance()->cameraUnderWater())
{ //generate planar reflection map
//disable occlusion culling for reflection map for now
- S32 occlusion = LLPipeline::sUseOcclusion;
- LLPipeline::sUseOcclusion = 0;
gGL.getTexUnit(0)->unbind(LLTexUnit::TT_TEXTURE);
glClearColor(0,0,0,0);
mWaterRef.bindTarget();
@@ -9317,7 +9318,6 @@ void LLPipeline::generateWaterReflection(LLCamera& camera_in)
gGL.popMatrix();
mWaterRef.flush();
glh_set_current_modelview(current);
- LLPipeline::sUseOcclusion = occlusion;
}
camera.setOrigin(camera_in.getOrigin());
@@ -9373,6 +9373,8 @@ void LLPipeline::generateWaterReflection(LLCamera& camera_in)
LLPipeline::sUnderWaterRender = FALSE;
mWaterDis.flush();
}
+
+ LLPipeline::sUseOcclusion = occlusion;
last_update = LLDrawPoolWater::sNeedsReflectionUpdate && LLDrawPoolWater::sNeedsDistortionUpdate;
LLPipeline::sReflectionRender = FALSE;