summaryrefslogtreecommitdiff
path: root/indra/llprimitive
diff options
context:
space:
mode:
authorruslantproductengine <ruslantproductengine@lindenlab.com>2015-03-26 18:05:47 +0200
committerruslantproductengine <ruslantproductengine@lindenlab.com>2015-03-26 18:05:47 +0200
commit802302a31c06f2ca98875d73ff424ae3d9df195f (patch)
treefabb6a166a2d52dfed852108c948d7969150c36b /indra/llprimitive
parent321a054a7a7ec5e2538cc82d4cf850078ea5640c (diff)
MAINT-3818 FIXED Certain dae files that used to display skin weights successfully now crash when ticking skin weights in model preview on ALL viewers
Diffstat (limited to 'indra/llprimitive')
-rwxr-xr-xindra/llprimitive/llmodel.cpp16
1 files changed, 16 insertions, 0 deletions
diff --git a/indra/llprimitive/llmodel.cpp b/indra/llprimitive/llmodel.cpp
index e0294cfd6a..e18004a49e 100755
--- a/indra/llprimitive/llmodel.cpp
+++ b/indra/llprimitive/llmodel.cpp
@@ -316,6 +316,14 @@ LLModel::EModelStatus load_face_from_dom_triangles(std::vector<LLVolumeFace>& fa
if (indices.size()%3 == 0 && verts.size() >= 65532)
{
+ std::string material;
+
+ if (tri->getMaterial())
+ {
+ material = std::string(tri->getMaterial());
+ }
+
+ materials.push_back(material);
face_list.push_back(face);
face_list.rbegin()->fillFromLegacyData(verts, indices);
LLVolumeFace& new_face = *face_list.rbegin();
@@ -587,6 +595,14 @@ LLModel::EModelStatus load_face_from_dom_polylist(std::vector<LLVolumeFace>& fac
if (indices.size()%3 == 0 && indices.size() >= 65532)
{
+ std::string material;
+
+ if (poly->getMaterial())
+ {
+ material = std::string(poly->getMaterial());
+ }
+
+ materials.push_back(material);
face_list.push_back(face);
face_list.rbegin()->fillFromLegacyData(verts, indices);
LLVolumeFace& new_face = *face_list.rbegin();