#include "SMESH_1D_Algo.hxx"
-class StdMeshers_LocalLength;
-class StdMeshers_NumberOfSegments;
+class TopoDS_Edge;
class StdMeshers_Regular_1D:
public SMESH_1D_Algo
virtual bool Compute(SMESH_Mesh& aMesh,
const TopoDS_Shape& aShape);
+ virtual const std::list <const SMESHDS_Hypothesis *> &
+ GetUsedHypothesis(SMESH_Mesh & aMesh, const TopoDS_Shape & aShape);
+
ostream & SaveTo(ostream & save);
istream & LoadFrom(istream & load);
friend ostream & operator << (ostream & save, StdMeshers_Regular_1D & hyp);
friend istream & operator >> (istream & load, StdMeshers_Regular_1D & hyp);
protected:
- double _localLength;
- int _numberOfSegments;
- double _scaleFactor;
- const StdMeshers_LocalLength* _hypLocalLength;
- const StdMeshers_NumberOfSegments* _hypNumberOfSegments;
+
+ virtual bool computeInternalParameters (const TopoDS_Edge& theEdge,
+ std::list< double > & theParameters,
+ const bool theReverse) const;
+
+ enum HypothesisType { LOCAL_LENGTH, NB_SEGMENTS, BEG_END_LENGTH, DEFLECTION, ARITHMETIC_1D, NONE };
+
+ enum ValueIndex {
+ NB_SEGMENTS_IND = 0,
+ SCALE_FACTOR_IND = 1,
+ BEG_LENGTH_IND = 0,
+ END_LENGTH_IND = 1,
+ DEFLECTION_IND = 0
+ };
+
+ HypothesisType _hypType;
+
+ double _value[2];
+
+ // a source of propagated hypothesis, is set by CheckHypothesis()
+ // always called before Compute()
+ TopoDS_Shape _mainEdge;
};
#endif