From fa7e7930464ac20a79001dd2bf27ee08b54cadb0 Mon Sep 17 00:00:00 2001 From: eap Date: Thu, 17 May 2007 07:03:11 +0000 Subject: [PATCH] bug PAL15961 ("Extrusion 3D" algo does not work ) speed optimization for the bug case --- src/StdMeshers/StdMeshers_Prism_3D.cxx | 7 ++++--- src/StdMeshers/StdMeshers_Prism_3D.hxx | 2 +- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/StdMeshers/StdMeshers_Prism_3D.cxx b/src/StdMeshers/StdMeshers_Prism_3D.cxx index 01339e702..d7da4e587 100644 --- a/src/StdMeshers/StdMeshers_Prism_3D.cxx +++ b/src/StdMeshers/StdMeshers_Prism_3D.cxx @@ -520,9 +520,10 @@ bool StdMeshers_Prism_3D::assocOrProjBottom2Top() continue; // wall columns are contained in myBlock // compute bottom node params TNode bN( botNode ); - if ( !myBlock.ComputeParameters( bN.GetCoords(), bN.ChangeParams(), ID_BOT_FACE )) - return error(dfltErr(),TCom("Can't compute normalized parameters ") - << "for node " << botNode->GetID() << " on the face #"<< botSM->GetId() ); + if ( zSize > 2 ) + if ( !myBlock.ComputeParameters( bN.GetCoords(), bN.ChangeParams(), ID_BOT_FACE )) + return error(dfltErr(),TCom("Can't compute normalized parameters ") + << "for node " << botNode->GetID() << " on the face #"<< botSM->GetId() ); // create node column TNode2ColumnMap::iterator bN_col = myBotToColumnMap.insert( make_pair ( bN, TNodeColumn() )).first; diff --git a/src/StdMeshers/StdMeshers_Prism_3D.hxx b/src/StdMeshers/StdMeshers_Prism_3D.hxx index 55a249570..20e92a2cb 100644 --- a/src/StdMeshers/StdMeshers_Prism_3D.hxx +++ b/src/StdMeshers/StdMeshers_Prism_3D.hxx @@ -81,7 +81,7 @@ struct TNode SMDS_TypeOfPosition GetPositionType() const { return myNode ? myNode->GetPosition()->GetTypeOfPosition() : SMDS_TOP_UNSPEC; } - TNode(const SMDS_MeshNode* node = 0): myNode(node) {} + TNode(const SMDS_MeshNode* node = 0): myNode(node), myParams(0,0,0) {} bool operator < (const TNode& other) const { return myNode < other.myNode; } }; -- 2.39.2