Fix build
parent
ec47c20919
commit
0320be1c15
|
@ -133,11 +133,10 @@ MeshLoader::MeshLoader(void *meshlite, int meshId, int triangulatedMeshId, QColo
|
||||||
triangulatedFace.color.setBlueF(useColorB);
|
triangulatedFace.color.setBlueF(useColorB);
|
||||||
QVector3D positions[3];
|
QVector3D positions[3];
|
||||||
if (smoothNormal) {
|
if (smoothNormal) {
|
||||||
inputTrianglesForSmoothAngle.push_back({
|
inputTrianglesForSmoothAngle.push_back(std::make_tuple((size_t)triangleIndices[firstIndex + 0],
|
||||||
(size_t)triangleIndices[firstIndex + 0],
|
|
||||||
(size_t)triangleIndices[firstIndex + 1],
|
(size_t)triangleIndices[firstIndex + 1],
|
||||||
(size_t)triangleIndices[firstIndex + 2]
|
(size_t)triangleIndices[firstIndex + 2]
|
||||||
});
|
));
|
||||||
inputNormalsForSmoothAngle.push_back(QVector3D(triangleNormals[firstIndex + 0],
|
inputNormalsForSmoothAngle.push_back(QVector3D(triangleNormals[firstIndex + 0],
|
||||||
triangleNormals[firstIndex + 1],
|
triangleNormals[firstIndex + 1],
|
||||||
triangleNormals[firstIndex + 2]));
|
triangleNormals[firstIndex + 2]));
|
||||||
|
|
|
@ -429,7 +429,7 @@ void MeshResultContext::interpolateTriangleVertexNormals(std::vector<QVector3D>
|
||||||
for (const auto &vertex: vertices)
|
for (const auto &vertex: vertices)
|
||||||
inputVerticies.push_back(vertex.position);
|
inputVerticies.push_back(vertex.position);
|
||||||
for (const auto &triangle: triangles) {
|
for (const auto &triangle: triangles) {
|
||||||
inputTriangles.push_back({triangle.indicies[0], triangle.indicies[1], triangle.indicies[2]});
|
inputTriangles.push_back(std::make_tuple((size_t)triangle.indicies[0], (size_t)triangle.indicies[1], (size_t)triangle.indicies[2]));
|
||||||
inputNormals.push_back(triangle.normal);
|
inputNormals.push_back(triangle.normal);
|
||||||
}
|
}
|
||||||
angleSmooth(inputVerticies, inputTriangles, inputNormals, thresholdAngleDegrees, resultNormals);
|
angleSmooth(inputVerticies, inputTriangles, inputNormals, thresholdAngleDegrees, resultNormals);
|
||||||
|
|
Loading…
Reference in New Issue