summaryrefslogtreecommitdiff
path: root/indra
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2011-09-30 00:05:42 -0500
committerDave Parks <davep@lindenlab.com>2011-09-30 00:05:42 -0500
commit3f96ec1bc9098986f1ed811120ab3793a29ae235 (patch)
tree37110643e6c5ffdf2e920382252fb2ff1276dd5b /indra
parentccf751e78ee551648e4ae29f2e7c0e7288cd7168 (diff)
SH-2244 Fix for performance warning on AMD cards
Diffstat (limited to 'indra')
-rw-r--r--indra/newview/llspatialpartition.cpp4
-rw-r--r--indra/newview/pipeline.cpp4
2 files changed, 4 insertions, 4 deletions
diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp
index 61d061520f..8e22a9be2c 100644
--- a/indra/newview/llspatialpartition.cpp
+++ b/indra/newview/llspatialpartition.cpp
@@ -214,7 +214,7 @@ typedef enum
//contact Runitai Linden for a copy of the SL object used to write this table
//basically, you give the table a bitmask of the look-at vector to a node and it
//gives you a triangle fan index array
-static U8 sOcclusionIndices[] =
+static U16 sOcclusionIndices[] =
{
//000
b111, b110, b010, b011, b001, b101, b100, b110,
@@ -251,7 +251,7 @@ U8* get_box_fan_indices_ptr(LLCamera* camera, const LLVector4a& center)
S32 cypher = center.greaterThan(origin).getGatheredBits() & 0x7;
- return sOcclusionIndices+cypher*8;
+ return (U8*) (sOcclusionIndices+cypher*8);
}
diff --git a/indra/newview/pipeline.cpp b/indra/newview/pipeline.cpp
index db9675650a..3fa281368c 100644
--- a/indra/newview/pipeline.cpp
+++ b/indra/newview/pipeline.cpp
@@ -7532,7 +7532,7 @@ void LLPipeline::renderDeferredLighting()
gGL.syncMatrices();
mDeferredVB->setBuffer(LLVertexBuffer::MAP_VERTEX);
glDrawRangeElements(GL_TRIANGLE_FAN, 0, 7, 8,
- GL_UNSIGNED_BYTE, get_box_fan_indices_ptr(camera, center));
+ GL_UNSIGNED_SHORT, get_box_fan_indices_ptr(camera, center));
stop_glerror();
}
}
@@ -7605,7 +7605,7 @@ void LLPipeline::renderDeferredLighting()
gGL.syncMatrices();
mDeferredVB->setBuffer(LLVertexBuffer::MAP_VERTEX);
glDrawRangeElements(GL_TRIANGLE_FAN, 0, 7, 8,
- GL_UNSIGNED_BYTE, get_box_fan_indices_ptr(camera, center));
+ GL_UNSIGNED_SHORT, get_box_fan_indices_ptr(camera, center));
}
gDeferredSpotLightProgram.disableTexture(LLViewerShaderMgr::DEFERRED_PROJECTION);
unbindDeferredShader(gDeferredSpotLightProgram);