From 2b5452d19d67fbb8ae32c2d1ffb373539b84f2c0 Mon Sep 17 00:00:00 2001 From: wandererfan Date: Tue, 30 Aug 2022 16:37:35 -0400 Subject: [PATCH] [TD]fix perspective projection - the logic for the perspective option with the precise HLR algo was inadvertently removed in the multithread modifications. --- src/Mod/TechDraw/App/GeometryObject.cpp | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/src/Mod/TechDraw/App/GeometryObject.cpp b/src/Mod/TechDraw/App/GeometryObject.cpp index 7d2c247a06..23e3dcc5c8 100644 --- a/src/Mod/TechDraw/App/GeometryObject.cpp +++ b/src/Mod/TechDraw/App/GeometryObject.cpp @@ -163,17 +163,21 @@ void GeometryObject::projectShape(const TopoDS_Shape& inShape, { clear(); - Handle(HLRBRep_Algo) brep_hlr; try { brep_hlr = new HLRBRep_Algo(); // brep_hlr->Debug(true); brep_hlr->Add(inShape); - HLRAlgo_Projector projector( viewAxis ); - brep_hlr->Projector(projector); + if (m_isPersp) { + double fLength = std::max(Precision::Confusion(), m_focus); + HLRAlgo_Projector projector( viewAxis, fLength ); + brep_hlr->Projector(projector); + } else { + HLRAlgo_Projector projector( viewAxis ); + brep_hlr->Projector(projector); + } brep_hlr->Update(); brep_hlr->Hide(); - } catch (const Standard_Failure& e) { Base::Console().Error("GO::projectShape - OCC error - %s - while projecting shape\n",