\page skew_page Skew
\n \b Skew mesh quality criterion reflects the angle between the lines
-that join opposite sides of a quadrangle element or the greatesr angle
-between three medians in triangle elements. This mesh quality
+that join opposite sides of a quadrangle element or the greatest angle
+between a median and a midline in a triangle element. This mesh quality
criterion can be applied to elements composed of 4 and 3 nodes
(quadrangles and triangles).
mesh_extmeth_surf_offset_smooth.png
mesh_extmeth_face_offset.png
mesh_quality.png
+ mesh_show.png
+ mesh_hide.png
)
INSTALL(FILES ${SMESH_RESOURCES_FILES} DESTINATION ${SALOME_SMESH_INSTALL_RES_DATA})
//vtkDebugLeaks::SetExitError(0);
}
+namespace
+{
+ // a structure used to nullify SMESH_Gen field of SMESH_Hypothesis,
+ // which is needed for SMESH_Hypothesis not deleted before ~SMESH_Gen()
+ struct _Hyp : public SMESH_Hypothesis
+ {
+ void NullifyGen()
+ {
+ _gen = 0;
+ }
+ };
+}
+
//=============================================================================
/*!
* Destructor
std::map < int, StudyContextStruct * >::iterator i_sc = _mapStudyContext.begin();
for ( ; i_sc != _mapStudyContext.end(); ++i_sc )
{
- delete i_sc->second->myDocument;
- delete i_sc->second;
- }
+ StudyContextStruct* context = i_sc->second;
+ std::map < int, SMESH_Hypothesis * >::iterator i_hyp = context->mapHypothesis.begin();
+ for ( ; i_hyp != context->mapHypothesis.end(); ++i_hyp )
+ {
+ if ( _Hyp* h = static_cast< _Hyp*>( i_hyp->second ))
+ h->NullifyGen();
+ }
+ delete context->myDocument;
+ delete context;
+ }
}
//=============================================================================
// Author : Paul RASCLE, EDF
// Module : SMESH
//
-#include "SMESH_Hypothesis.hxx"
-#include "SMESHDS_Mesh.hxx"
#include "SMESH_Gen.hxx"
-#include "SMESH_Mesh.hxx"
-#include "SMESH_subMesh.hxx"
-#include "utilities.h"
+#include "SMESHDS_Mesh.hxx"
+#include "SMESH_Hypothesis.hxx"
+#include "SMESH_Mesh.hxx"
using namespace std;
//=============================================================================
/*!
- *
+ *
*/
//=============================================================================
SMESH_Hypothesis::~SMESH_Hypothesis()
{
- StudyContextStruct* myStudyContext = _gen->GetStudyContext(_studyId);
- myStudyContext->mapHypothesis[_hypId] = 0;
+ if ( _gen )
+ {
+ StudyContextStruct* myStudyContext = _gen->GetStudyContext(_studyId);
+ myStudyContext->mapHypothesis[_hypId] = 0;
+ }
}
//=============================================================================
{
int dim = 0;
switch (_type)
- {
- case ALGO_1D: dim = 1; break;
- case ALGO_2D: dim = 2; break;
- case ALGO_3D: dim = 3; break;
- case ALGO_0D: dim = 0; break;
- case PARAM_ALGO:
- dim = ( _param_algo_dim < 0 ) ? -_param_algo_dim : _param_algo_dim; break;
- }
+ {
+ case ALGO_1D: dim = 1; break;
+ case ALGO_2D: dim = 2; break;
+ case ALGO_3D: dim = 3; break;
+ case ALGO_0D: dim = 0; break;
+ case PARAM_ALGO:
+ dim = ( _param_algo_dim < 0 ) ? -_param_algo_dim : _param_algo_dim; break;
+ }
return dim;
}
//=============================================================================
/*!
- *
+ *
*/
//=============================================================================
createSMESHAction( SMESHOp::OpPropertiesArea, "MEASURE_AREA", "ICON_MEASURE_AREA" );
createSMESHAction( SMESHOp::OpPropertiesVolume, "MEASURE_VOLUME", "ICON_MEASURE_VOLUME" );
- createSMESHAction( SMESHOp::OpHide, "HIDE" );
- createSMESHAction( SMESHOp::OpShow, "SHOW" );
+ createSMESHAction( SMESHOp::OpHide, "HIDE", "ICON_HIDE" );
+ createSMESHAction( SMESHOp::OpShow, "SHOW", "ICON_SHOW" );
createSMESHAction( SMESHOp::OpShowOnly, "DISPLAY_ONLY" );
createSMESHAction( SMESHOp::OpSortChild, "SORT_CHILD_ITEMS" );
<source>ICON_MEASURE_BND_BOX</source>
<translation>mesh_bounding_box.png</translation>
</message>
+ <message>
+ <source>ICON_SHOW</source>
+ <translation>mesh_show.png</translation>
+ </message>
+ <message>
+ <source>ICON_HIDE</source>
+ <translation>mesh_hide.png</translation>
+ </message>
</context>
</TS>
double SquareDistance(const SMDS_MeshNode* n) const { return (SMESH_TNodeXYZ( n )-*this).SquareModulus(); }
bool operator==(const SMESH_TNodeXYZ& other) const { return _node == other._node; }
};
+typedef SMESH_TNodeXYZ SMESH_NodeXYZ;
//--------------------------------------------------
/*!