From 83229db45859c7a2a75b153c098f79400225fd98 Mon Sep 17 00:00:00 2001 From: sabrina-shanman Date: Thu, 24 Oct 2019 14:59:09 -0700 Subject: [PATCH] Fix GLTFSerializer not reading tangents --- libraries/fbx/src/GLTFSerializer.cpp | 3 --- 1 file changed, 3 deletions(-) diff --git a/libraries/fbx/src/GLTFSerializer.cpp b/libraries/fbx/src/GLTFSerializer.cpp index 456bad9346..16d2962ecc 100755 --- a/libraries/fbx/src/GLTFSerializer.cpp +++ b/libraries/fbx/src/GLTFSerializer.cpp @@ -1315,8 +1315,6 @@ bool GLTFSerializer::buildGeometry(HFMModel& hfmModel, const hifi::VariantHash& float tanW = tangentStride == 4 ? tangents[n + 3] : 1; mesh.tangents.push_back(glm::vec3(tanW * tangents[n], tangents[n + 1], tanW * tangents[n + 2])); } - } else if (primitiveAttributes.contains("TANGENT")) { - mesh.tangents.resize(mesh.tangents.size() + partVerticesCount); } if (texcoords.size() == partVerticesCount * TEX_COORD_STRIDE) { @@ -1874,7 +1872,6 @@ bool GLTFSerializer::addArrayFromAttribute(GLTFVertexAttribute::Value vertexAttr qWarning(modelformat) << "Invalid accessor type on glTF TANGENT data for model " << _url; return false; } - break; if (!addArrayFromAccessor(accessor, outarray)) { qWarning(modelformat) << "There was a problem reading glTF TANGENT data for model " << _url;