]> SALOME platform Git repositories - modules/smesh.git/commitdiff
Salome HOME
0019923: EDF 765 SMESH : default values of hypothesis
authoreap <eap@opencascade.com>
Fri, 16 Jan 2009 14:56:05 +0000 (14:56 +0000)
committereap <eap@opencascade.com>
Fri, 16 Jan 2009 14:56:05 +0000 (14:56 +0000)
  store number of segments per box diagonal in SMESH_Gen not in SMESH_Mesh

src/SMESH/SMESH_Mesh.hxx
src/StdMeshers/StdMeshers_Regular_1D.cxx

index 38012a223bcf865ece6c14eae36efcb3d88b2f7d..d93f60ab5284b908f83bfe0946efc05a75b0da80 100644 (file)
@@ -130,10 +130,6 @@ public:
                     std::list <const SMESHDS_Hypothesis * >& aHypList,
                     const bool                               andAncestors) const;
 
-  void SetNbElementsPerDiagonal(int nb) { _nbElemPerDiagonal = nb ;}
-
-  int GetNbElementsPerDiagonal() { return _nbElemPerDiagonal; }
-
   const std::list<SMESHDS_Command*> & GetLog() throw(SALOME_Exception);
   
   void ClearLog() throw(SALOME_Exception);
@@ -274,7 +270,6 @@ protected:
   bool                       _isAutoColor;
 
   double                     _shapeDiagonal; //!< diagonal size of bounding box of shape to mesh
-  int                        _nbElemPerDiagonal; //!< nb elements per diagonal
   
   TopTools_IndexedDataMapOfShapeListOfShape _mapAncestors;
 
index da059a272d49b68aa84014ae958ab2b9e705c3b3..72ac0c73998727dbdb79041f4c79f5f5f67d6d75 100644 (file)
@@ -162,7 +162,7 @@ bool StdMeshers_Regular_1D::CheckHypothesis
     ASSERT(hyp);
     _value[ BEG_LENGTH_IND ] = hyp->GetLength();
     if ( hyp->GetUsePreestimatedLength() ) {
-      if ( int nbSeg = aMesh.GetNbElementsPerDiagonal() )
+      if ( int nbSeg = aMesh.GetGen()->GetBoundaryBoxSegmentation() )
         _value[ BEG_LENGTH_IND ] = aMesh.GetShapeDiagonalSize() / nbSeg;
     }
     ASSERT( _value[ BEG_LENGTH_IND ] > 0 );