summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorDave Parks <davep@lindenlab.com>2011-02-02 19:03:03 -0600
committerDave Parks <davep@lindenlab.com>2011-02-02 19:03:03 -0600
commit5bd5d918caa63338a678e2c94db9195f77867e8a (patch)
tree4293c41109adb4b77ec6d0c4d5aec741bd7d092f
parent33f82d788502a036953b676bfcb709d968b2a569 (diff)
parentbb113f75efefffc1f976267be6d722289929e596 (diff)
merge
-rw-r--r--indra/newview/lldrawable.cpp8
-rw-r--r--indra/newview/llface.cpp3
-rw-r--r--indra/newview/llspatialpartition.cpp8
3 files changed, 9 insertions, 10 deletions
diff --git a/indra/newview/lldrawable.cpp b/indra/newview/lldrawable.cpp
index 73c4cf94ef..cbee800acb 100644
--- a/indra/newview/lldrawable.cpp
+++ b/indra/newview/lldrawable.cpp
@@ -709,11 +709,7 @@ void LLDrawable::updateDistance(LLCamera& camera, bool force_update)
if (volume)
{
pos.set(getPositionGroup().getF32ptr());
- if (isStatic())
- {
- pos += volume->getRegion()->getOriginAgent();
- }
-
+
if (isState(LLDrawable::HAS_ALPHA))
{
for (S32 i = 0; i < getNumFaces(); i++)
@@ -733,7 +729,7 @@ void LLDrawable::updateDistance(LLCamera& camera, bool force_update)
facep->mDistance = v * camera.getAtAxis();
}
}
- }
+ }
}
else
{
diff --git a/indra/newview/llface.cpp b/indra/newview/llface.cpp
index 1576ef0769..863e335f4a 100644
--- a/indra/newview/llface.cpp
+++ b/indra/newview/llface.cpp
@@ -761,8 +761,7 @@ BOOL LLFace::genVolumeBBoxes(const LLVolume &volume, S32 f,
mCenterLocal.set(t.getF32ptr());
t.setSub(newMax,newMin);
- t.mul(0.5f);
- mBoundingSphereRadius = t.getLength3().getF32();
+ mBoundingSphereRadius = t.getLength3().getF32()*0.5f;
updateCenterAgent();
}
diff --git a/indra/newview/llspatialpartition.cpp b/indra/newview/llspatialpartition.cpp
index af6064ad20..a4c9b66e38 100644
--- a/indra/newview/llspatialpartition.cpp
+++ b/indra/newview/llspatialpartition.cpp
@@ -2948,10 +2948,10 @@ void renderMeshBaseHull(LLVOVolume* volume, U32 data_mask, LLColor4& color, LLCo
{
buff->setBuffer(data_mask);
- glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
+ /* glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
glColor4fv(line_color.mV);
buff->drawArrays(LLRender::TRIANGLES, 0, buff->getNumVerts());
- glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
+ glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);*/
{
glColor4fv(color.mV);
@@ -2979,9 +2979,13 @@ void render_hull(LLVertexBuffer* buff, U32 data_mask, const LLColor4& color, con
glColor4fv(color.mV);
buff->drawArrays(LLRender::TRIANGLES, 0, buff->getNumVerts());
+ LLGLEnable offset(GL_POLYGON_OFFSET_LINE);
glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
+ glPolygonOffset(3.f, 3.f);
+ glLineWidth(3.f);
glColor4fv(line_color.mV);
buff->drawArrays(LLRender::TRIANGLES, 0, buff->getNumVerts());
+ glLineWidth(1.f);
glPolygonMode(GL_FRONT_AND_BACK, GL_FILL);
}