summaryrefslogtreecommitdiff
path: root/indra/newview/llfloatermodelpreview.cpp
diff options
context:
space:
mode:
authorAndrey Kleshchev <andreykproductengine@lindenlab.com>2020-04-21 17:33:14 +0300
committerAndrey Kleshchev <andreykproductengine@lindenlab.com>2020-04-21 17:33:14 +0300
commit311921cad63175b276fefae4de3dbed8bce98802 (patch)
tree3d322aa758d60a93de2f43f50b06f9983954887c /indra/newview/llfloatermodelpreview.cpp
parent1f8f3d13d0baf7668696d98064a6d65af52d036b (diff)
SL-13064 Artifacts on the preview with physics
Diffstat (limited to 'indra/newview/llfloatermodelpreview.cpp')
-rw-r--r--indra/newview/llfloatermodelpreview.cpp7
1 files changed, 3 insertions, 4 deletions
diff --git a/indra/newview/llfloatermodelpreview.cpp b/indra/newview/llfloatermodelpreview.cpp
index 54ab245089..264ba99170 100644
--- a/indra/newview/llfloatermodelpreview.cpp
+++ b/indra/newview/llfloatermodelpreview.cpp
@@ -4597,7 +4597,8 @@ BOOL LLModelPreview::render()
}
}
}
- }
+ gGL.popMatrix();
+ }
// only do this if mDegenerate was set in the preceding mesh checks [Check this if the ordering ever breaks]
if (pass > 0 && mHasDegenerate)
@@ -4642,8 +4643,7 @@ BOOL LLModelPreview::render()
genBuffers(LLModel::LOD_PHYSICS, false);
}
- auto num_degenerate = 0;
- auto num_models = mVertexBuffer[LLModel::LOD_PHYSICS][model].size();
+ U32 num_models = mVertexBuffer[LLModel::LOD_PHYSICS][model].size();
for (U32 v = 0; v < num_models; ++v)
{
LLVertexBuffer* buffer = mVertexBuffer[LLModel::LOD_PHYSICS][model][v];
@@ -4667,7 +4667,6 @@ BOOL LLModelPreview::render()
if (ll_is_degenerate(v1, v2, v3))
{
- num_degenerate++;
glPolygonMode(GL_FRONT_AND_BACK, GL_LINE);
gGL.diffuseColor3fv(deg_edge_col().mV);
buffer->drawRange(LLRender::TRIANGLES, 0, 2, 3, indices_offset);