Fix for broken face normals in FEdgeSharp and FEdgeSmooth, resulting from

splitting of FEdges at 2D intersections (i.e., at TVertices).
This commit is contained in:
Tamito Kajiyama 2012-04-07 00:37:01 +00:00
parent 21484ba52c
commit 04a9f393d8

@ -1310,11 +1310,14 @@ public:
newEdge = new FEdgeSmooth(ioNewVertex, B);
FEdgeSmooth * se = dynamic_cast<FEdgeSmooth*>(newEdge);
FEdgeSmooth * fes = dynamic_cast<FEdgeSmooth*>(ioEdge);
se->setNormal(fes->normal());
se->setFrsMaterialIndex(fes->frs_materialIndex());
}else{
newEdge = new FEdgeSharp(ioNewVertex, B);
FEdgeSharp * se = dynamic_cast<FEdgeSharp*>(newEdge);
FEdgeSharp * fes = dynamic_cast<FEdgeSharp*>(ioEdge);
se->setNormalA(fes->normalA());
se->setNormalB(fes->normalB());
se->setaFrsMaterialIndex(fes->aFrsMaterialIndex());
se->setbFrsMaterialIndex(fes->bFrsMaterialIndex());
}