untabify
This commit is contained in:
parent
10fc3eb3e0
commit
fc79403acc
@ -260,10 +260,10 @@ bool NETGENPluginGUI_HypothesisCreator::readParamsFromHypo( NetgenHypothesisData
|
||||
if ( myIs2D )
|
||||
{
|
||||
NETGENPlugin::NETGENPlugin_Hypothesis_2D_var h_2d =
|
||||
NETGENPlugin::NETGENPlugin_Hypothesis_2D::_narrow( initParamsHypothesis() );
|
||||
NETGENPlugin::NETGENPlugin_Hypothesis_2D::_narrow( initParamsHypothesis() );
|
||||
|
||||
if ( !h_2d->_is_nil() )
|
||||
h_data.myAllowQuadrangles = h_2d->GetQuadAllowed();
|
||||
h_data.myAllowQuadrangles = h_2d->GetQuadAllowed();
|
||||
}
|
||||
|
||||
return true;
|
||||
@ -289,9 +289,9 @@ bool NETGENPluginGUI_HypothesisCreator::storeParamsToHypo( const NetgenHypothesi
|
||||
|
||||
if( fineness==UserDefined )
|
||||
{
|
||||
h->SetGrowthRate( h_data.myGrowthRate );
|
||||
h->SetNbSegPerEdge( h_data.myNbSegPerEdge );
|
||||
h->SetNbSegPerRadius( h_data.myNbSegPerRadius );
|
||||
h->SetGrowthRate( h_data.myGrowthRate );
|
||||
h->SetNbSegPerEdge( h_data.myNbSegPerEdge );
|
||||
h->SetNbSegPerRadius( h_data.myNbSegPerRadius );
|
||||
|
||||
aVariablesList.append(h_data.myGrowthRateVar);
|
||||
aVariablesList.append(h_data.myNbSegPerEdgeVar);
|
||||
@ -300,11 +300,11 @@ bool NETGENPluginGUI_HypothesisCreator::storeParamsToHypo( const NetgenHypothesi
|
||||
|
||||
if ( myIs2D )
|
||||
{
|
||||
NETGENPlugin::NETGENPlugin_Hypothesis_2D_var h_2d =
|
||||
NETGENPlugin::NETGENPlugin_Hypothesis_2D::_narrow( h );
|
||||
|
||||
if ( !h_2d->_is_nil() )
|
||||
h_2d->SetQuadAllowed( h_data.myAllowQuadrangles );
|
||||
NETGENPlugin::NETGENPlugin_Hypothesis_2D_var h_2d =
|
||||
NETGENPlugin::NETGENPlugin_Hypothesis_2D::_narrow( h );
|
||||
|
||||
if ( !h_2d->_is_nil() )
|
||||
h_2d->SetQuadAllowed( h_data.myAllowQuadrangles );
|
||||
}
|
||||
|
||||
h->SetParameters(aVariablesList.join(":").toLatin1().constData());
|
||||
@ -360,34 +360,34 @@ void NETGENPluginGUI_HypothesisCreator::onFinenessChanged()
|
||||
double aGrowthRate, aNbSegPerEdge, aNbSegPerRadius;
|
||||
|
||||
switch ( myFineness->currentIndex() )
|
||||
{
|
||||
case VeryCoarse:
|
||||
aGrowthRate = 0.7;
|
||||
aNbSegPerEdge = 0.3;
|
||||
aNbSegPerRadius = 1;
|
||||
break;
|
||||
case Coarse:
|
||||
aGrowthRate = 0.5;
|
||||
aNbSegPerEdge = 0.5;
|
||||
aNbSegPerRadius = 1.5;
|
||||
break;
|
||||
case Fine:
|
||||
aGrowthRate = 0.2;
|
||||
aNbSegPerEdge = 2;
|
||||
aNbSegPerRadius = 3;
|
||||
break;
|
||||
case VeryFine:
|
||||
aGrowthRate = 0.1;
|
||||
aNbSegPerEdge = 3;
|
||||
aNbSegPerRadius = 5;
|
||||
break;
|
||||
case Moderate:
|
||||
default:
|
||||
aGrowthRate = 0.3;
|
||||
aNbSegPerEdge = 1;
|
||||
aNbSegPerRadius = 2;
|
||||
break;
|
||||
}
|
||||
{
|
||||
case VeryCoarse:
|
||||
aGrowthRate = 0.7;
|
||||
aNbSegPerEdge = 0.3;
|
||||
aNbSegPerRadius = 1;
|
||||
break;
|
||||
case Coarse:
|
||||
aGrowthRate = 0.5;
|
||||
aNbSegPerEdge = 0.5;
|
||||
aNbSegPerRadius = 1.5;
|
||||
break;
|
||||
case Fine:
|
||||
aGrowthRate = 0.2;
|
||||
aNbSegPerEdge = 2;
|
||||
aNbSegPerRadius = 3;
|
||||
break;
|
||||
case VeryFine:
|
||||
aGrowthRate = 0.1;
|
||||
aNbSegPerEdge = 3;
|
||||
aNbSegPerRadius = 5;
|
||||
break;
|
||||
case Moderate:
|
||||
default:
|
||||
aGrowthRate = 0.3;
|
||||
aNbSegPerEdge = 1;
|
||||
aNbSegPerRadius = 2;
|
||||
break;
|
||||
}
|
||||
|
||||
myGrowthRate->setValue( aGrowthRate );
|
||||
myNbSegPerEdge->setValue( aNbSegPerEdge );
|
||||
|
@ -50,7 +50,7 @@ public:
|
||||
SMESH_Hypothesis::Hypothesis_Status& aStatus);
|
||||
|
||||
virtual bool Compute(SMESH_Mesh& aMesh,
|
||||
const TopoDS_Shape& aShape);
|
||||
const TopoDS_Shape& aShape);
|
||||
|
||||
virtual bool Evaluate(SMESH_Mesh& aMesh, const TopoDS_Shape& aShape,
|
||||
MapShapeNbElems& aResMap);
|
||||
|
@ -141,8 +141,8 @@ bool NETGENPlugin_NETGEN_2D3D::Compute(SMESH_Mesh& aMesh,
|
||||
//=============================================================================
|
||||
|
||||
bool NETGENPlugin_NETGEN_2D3D::Evaluate(SMESH_Mesh& aMesh,
|
||||
const TopoDS_Shape& aShape,
|
||||
MapShapeNbElems& aResMap)
|
||||
const TopoDS_Shape& aShape,
|
||||
MapShapeNbElems& aResMap)
|
||||
{
|
||||
NETGENPlugin_Mesher mesher(&aMesh, aShape, true);
|
||||
mesher.SetParameters(dynamic_cast<const NETGENPlugin_Hypothesis*>(_hypothesis));
|
||||
|
@ -50,11 +50,11 @@ public:
|
||||
SMESH_Hypothesis::Hypothesis_Status& aStatus);
|
||||
|
||||
virtual bool Compute(SMESH_Mesh& aMesh,
|
||||
const TopoDS_Shape& aShape);
|
||||
const TopoDS_Shape& aShape);
|
||||
|
||||
virtual bool Evaluate(SMESH_Mesh& aMesh,
|
||||
const TopoDS_Shape& aShape,
|
||||
MapShapeNbElems& aResMap);
|
||||
const TopoDS_Shape& aShape,
|
||||
MapShapeNbElems& aResMap);
|
||||
|
||||
protected:
|
||||
const SMESHDS_Hypothesis* _hypothesis;
|
||||
|
@ -38,8 +38,8 @@
|
||||
//=============================================================================
|
||||
|
||||
NETGENPlugin_NETGEN_2D_ONLY_i::NETGENPlugin_NETGEN_2D_ONLY_i( PortableServer::POA_ptr thePOA,
|
||||
int theStudyId,
|
||||
::SMESH_Gen* theGenImpl )
|
||||
int theStudyId,
|
||||
::SMESH_Gen* theGenImpl )
|
||||
: SALOME::GenericObj_i( thePOA ),
|
||||
SMESH_Hypothesis_i( thePOA ),
|
||||
SMESH_Algo_i( thePOA ),
|
||||
|
@ -75,7 +75,7 @@ using namespace std;
|
||||
//=============================================================================
|
||||
|
||||
NETGENPlugin_NETGEN_3D::NETGENPlugin_NETGEN_3D(int hypId, int studyId,
|
||||
SMESH_Gen* gen)
|
||||
SMESH_Gen* gen)
|
||||
: SMESH_3D_Algo(hypId, studyId, gen)
|
||||
{
|
||||
MESSAGE("NETGENPlugin_NETGEN_3D::NETGENPlugin_NETGEN_3D");
|
||||
@ -616,8 +616,8 @@ bool NETGENPlugin_NETGEN_3D::Compute(SMESH_Mesh& aMesh,
|
||||
{
|
||||
Ng_GetPoint( Netgen_mesh, nodeIndex, Netgen_point );
|
||||
SMDS_MeshNode * node = aHelper->AddNode(Netgen_point[0],
|
||||
Netgen_point[1],
|
||||
Netgen_point[2]);
|
||||
Netgen_point[1],
|
||||
Netgen_point[2]);
|
||||
nodeVec.at(nodeIndex) = node;
|
||||
}
|
||||
|
||||
@ -626,9 +626,9 @@ bool NETGENPlugin_NETGEN_3D::Compute(SMESH_Mesh& aMesh,
|
||||
{
|
||||
Ng_GetVolumeElement(Netgen_mesh, elemIndex, Netgen_tetrahedron);
|
||||
aHelper->AddVolume (nodeVec.at( Netgen_tetrahedron[0] ),
|
||||
nodeVec.at( Netgen_tetrahedron[1] ),
|
||||
nodeVec.at( Netgen_tetrahedron[2] ),
|
||||
nodeVec.at( Netgen_tetrahedron[3] ));
|
||||
nodeVec.at( Netgen_tetrahedron[1] ),
|
||||
nodeVec.at( Netgen_tetrahedron[2] ),
|
||||
nodeVec.at( Netgen_tetrahedron[3] ));
|
||||
}
|
||||
}
|
||||
|
||||
@ -648,8 +648,8 @@ bool NETGENPlugin_NETGEN_3D::Compute(SMESH_Mesh& aMesh,
|
||||
//=============================================================================
|
||||
|
||||
bool NETGENPlugin_NETGEN_3D::Evaluate(SMESH_Mesh& aMesh,
|
||||
const TopoDS_Shape& aShape,
|
||||
MapShapeNbElems& aResMap)
|
||||
const TopoDS_Shape& aShape,
|
||||
MapShapeNbElems& aResMap)
|
||||
{
|
||||
int nbtri = 0, nbqua = 0;
|
||||
double fullArea = 0.0;
|
||||
@ -686,7 +686,7 @@ bool NETGENPlugin_NETGEN_3D::Evaluate(SMESH_Mesh& aMesh,
|
||||
if( anIt==aResMap.end() ) {
|
||||
SMESH_ComputeErrorPtr& smError = aSubMesh->GetComputeError();
|
||||
smError.reset( new SMESH_ComputeError(COMPERR_ALGO_FAILED,
|
||||
"Submesh can not be evaluated",this));
|
||||
"Submesh can not be evaluated",this));
|
||||
return false;
|
||||
}
|
||||
std::vector<int> aVec = (*anIt).second;
|
||||
|
@ -49,14 +49,14 @@ public:
|
||||
SMESH_Hypothesis::Hypothesis_Status& aStatus);
|
||||
|
||||
virtual bool Compute(SMESH_Mesh& aMesh,
|
||||
const TopoDS_Shape& aShape);
|
||||
const TopoDS_Shape& aShape);
|
||||
|
||||
virtual bool Compute(SMESH_Mesh& aMesh,
|
||||
SMESH_MesherHelper* aHelper);
|
||||
|
||||
virtual bool Evaluate(SMESH_Mesh& aMesh,
|
||||
const TopoDS_Shape& aShape,
|
||||
MapShapeNbElems& aResMap);
|
||||
const TopoDS_Shape& aShape,
|
||||
MapShapeNbElems& aResMap);
|
||||
|
||||
protected:
|
||||
double _maxElementVolume;
|
||||
|
@ -43,8 +43,8 @@ using namespace std;
|
||||
//=============================================================================
|
||||
|
||||
NETGENPlugin_NETGEN_3D_i::NETGENPlugin_NETGEN_3D_i( PortableServer::POA_ptr thePOA,
|
||||
int theStudyId,
|
||||
::SMESH_Gen* theGenImpl )
|
||||
int theStudyId,
|
||||
::SMESH_Gen* theGenImpl )
|
||||
: SALOME::GenericObj_i( thePOA ),
|
||||
SMESH_Hypothesis_i( thePOA ),
|
||||
SMESH_Algo_i( thePOA ),
|
||||
@ -52,8 +52,8 @@ NETGENPlugin_NETGEN_3D_i::NETGENPlugin_NETGEN_3D_i( PortableServer::POA_ptr theP
|
||||
{
|
||||
MESSAGE( "NETGENPlugin_NETGEN_3D_i::NETGENPlugin_NETGEN_3D_i" );
|
||||
myBaseImpl = new ::NETGENPlugin_NETGEN_3D( theGenImpl->GetANewId(),
|
||||
theStudyId,
|
||||
theGenImpl );
|
||||
theStudyId,
|
||||
theGenImpl );
|
||||
}
|
||||
|
||||
//=============================================================================
|
||||
|
Loading…
Reference in New Issue
Block a user