[TechDraw] Use templates instead of duplicate code: toGp

This commit is contained in:
Benjamin Bræstrup Sayoc
2024-10-08 00:35:25 +02:00
parent e8d466ea98
commit 9f8f6b1f56
13 changed files with 63 additions and 76 deletions

View File

@@ -796,7 +796,7 @@ std::pair<Base::Vector3d, Base::Vector3d> DrawComplexSection::sectionArrowDirs()
}
gp_Vec gProfileVector = makeProfileVector(profileWire);
gp_Vec gSectionNormal = gp_Vec(DU::togp_Dir(SectionNormal.getValue()));
gp_Vec gSectionNormal = gp_Vec(DU::to<gp_Dir>(SectionNormal.getValue()));
gp_Vec gExtrudeVector = (gSectionNormal.Crossed(gProfileVector)).Normalized();
Base::Vector3d vClosestBasis = DrawUtil::closestBasis(gp_Dir(gExtrudeVector), getSectionCS());
gp_Dir gExtrudeDir = gp_Dir(vClosestBasis.x, vClosestBasis.y, vClosestBasis.z);