+ * \brief Initialize my parameter values by linear size of mesh element.
+ * \retval bool - true if parameter values have been successfully defined
+ */
+ virtual bool SetParametersByElementSize(double elemLenght, const SMESH_Mesh* theMesh=0)=0;
*/
//================================================================================
bool NETGENPlugin_Hypothesis::SetParametersByMesh(const SMESH_Mesh* theMesh,
- const TopoDS_Shape& theShape)
+ const TopoDS_Shape& theShape)
{
return false;
}
+//================================================================================
+/*!
+ * \brief Initialize my parameter values by linear size of mesh element.
+ * \retval bool - true if parameter values have been successfully defined
+ */
+//================================================================================
+
+bool NETGENPlugin_Hypothesis::SetParametersByElementSize(double elemLenght,
+ const SMESH_Mesh* /*theMesh*/)
+{
+ return bool( _maxSize = elemLenght );
+}
+
//=============================================================================
/*!
*
*/
virtual bool SetParametersByMesh(const SMESH_Mesh* theMesh, const TopoDS_Shape& theShape);
+ /*!
+ * \brief Initialize my parameter values by linear size of mesh element.
+ * \retval bool - true if parameter values have been successfully defined
+ */
+ virtual bool SetParametersByElementSize( double elemLenght, const SMESH_Mesh* theMesh=0);
+
private:
double _maxSize;
double _growthRate;
}
return nbEdges;
}
+
+//================================================================================
+/*!
+ * \brief Initialize my parameter values by linear size of mesh element.
+ * \retval bool - true if parameter values have been successfully defined
+ */
+//================================================================================
+
+bool NETGENPlugin_SimpleHypothesis_2D::SetParametersByElementSize(double elemLenght,
+ const SMESH_Mesh* /*theMesh*/)
+{
+ return bool( _segmentLength = elemLenght );
+}
+
*/
virtual bool SetParametersByMesh(const SMESH_Mesh* theMesh, const TopoDS_Shape& theShape);
+ /*!
+ * \brief Initialize my parameter values by linear size of mesh element.
+ * \retval bool - true if parameter values have been successfully defined
+ */
+ virtual bool SetParametersByElementSize( double elemLenght, const SMESH_Mesh* theMesh=0);
+
private:
int _nbSegments;
double _segmentLength, _area;