#include "SMDS_MeshNode.hxx"
#include "SMDS_MeshElement.hxx"
#include "SMDS_ElemIterator.hxx"
+#include "SMDS_VolumeTool.hxx"
#include "SMESHDS_Mesh.hxx"
return SMESH::FT_BadOrientedVolume;
}
+/*
+ Class : BareBorderVolume_i
+ Description : Verify whether a mesh volume is incorrectly oriented from
+ the point of view of MED convention
+*/
+BareBorderVolume_i::BareBorderVolume_i()
+{
+ Controls::PredicatePtr control( new Controls::BareBorderVolume() );
+ myFunctorPtr = myPredicatePtr = control;
+};
+
+FunctorType BareBorderVolume_i::GetFunctorType()
+{
+ return SMESH::FT_BareBorderVolume;
+}
+
+/*
+ Class : BareBorderFace_i
+ Description : Verify whether a mesh volume is incorrectly oriented from
+ the point of view of MED convention
+*/
+BareBorderFace_i::BareBorderFace_i()
+{
+ Controls::PredicatePtr control( new Controls::BareBorderFace() );
+ myFunctorPtr = myPredicatePtr = control;
+};
+
+FunctorType BareBorderFace_i::GetFunctorType()
+{
+ return SMESH::FT_BareBorderFace;
+}
+
/*
Class : BelongToGeom_i
Description : Predicate for selection on geometrical support
return anObj._retn();
}
+BareBorderVolume_ptr FilterManager_i::CreateBareBorderVolume()
+{
+ SMESH::BareBorderVolume_i* aServant = new SMESH::BareBorderVolume_i();
+ SMESH::BareBorderVolume_var anObj = aServant->_this();
+ TPythonDump()<<aServant<<" = "<<this<<".CreateBareBorderVolume()";
+ return anObj._retn();
+}
+
+BareBorderFace_ptr FilterManager_i::CreateBareBorderFace()
+{
+ SMESH::BareBorderFace_i* aServant = new SMESH::BareBorderFace_i();
+ SMESH::BareBorderFace_var anObj = aServant->_this();
+ TPythonDump()<<aServant<<" = "<<this<<".CreateBareBorderFace()";
+ return anObj._retn();
+}
+
LessThan_ptr FilterManager_i::CreateLessThan()
{
SMESH::LessThan_i* aServant = new SMESH::LessThan_i();
theCriteria[ i ].Type = FT_BadOrientedVolume;
theCriteria[ i ].TypeOfElement = aPred->GetElementType();
+ return true;
+ }
+ case FT_BareBorderVolume:
+ {
+ BareBorderVolume_i* aPred = dynamic_cast<BareBorderVolume_i*>( thePred );
+
+ CORBA::ULong i = theCriteria->length();
+ theCriteria->length( i + 1 );
+
+ theCriteria[ i ] = createCriterion();
+
+ theCriteria[ i ].Type = FT_BareBorderVolume;
+ theCriteria[ i ].TypeOfElement = aPred->GetElementType();
+
+ return true;
+ }
+ case FT_BareBorderFace:
+ {
+ BareBorderFace_i* aPred = dynamic_cast<BareBorderFace_i*>( thePred );
+
+ CORBA::ULong i = theCriteria->length();
+ theCriteria->length( i + 1 );
+
+ theCriteria[ i ] = createCriterion();
+
+ theCriteria[ i ].Type = FT_BareBorderFace;
+ theCriteria[ i ].TypeOfElement = aPred->GetElementType();
+
return true;
}
case FT_LessThan:
aPredicate = aFilterMgr->CreateBadOrientedVolume();
}
break;
+ case SMESH::FT_BareBorderVolume:
+ {
+ aPredicate = aFilterMgr->CreateBareBorderVolume();
+ }
+ break;
+ case SMESH::FT_BareBorderFace:
+ {
+ aPredicate = aFilterMgr->CreateBareBorderFace();
+ }
+ break;
case SMESH::FT_LinearOrQuadratic:
{
SMESH::LinearOrQuadratic_ptr tmpPred = aFilterMgr->CreateLinearOrQuadratic();
case FT_BelongToCylinder: return "Belong to Cylinder";
case FT_BelongToGenSurface: return "Belong to Generic Surface";
case FT_LyingOnGeom : return "Lying on Geom";
- case FT_BadOrientedVolume: return "Bad Oriented Volume";
+ case FT_BadOrientedVolume:return "Bad Oriented Volume";
+ case FT_BareBorderVolume: return "Volumes with bare border";
+ case FT_BareBorderFace : return "Faces with bare border";
case FT_RangeOfIds : return "Range of IDs";
case FT_FreeBorders : return "Free borders";
case FT_FreeEdges : return "Free edges";
// else if ( theStr.equals( "Length2D" ) ) return FT_Length2D;
else if ( theStr.equals( "Range of IDs" ) ) return FT_RangeOfIds;
else if ( theStr.equals( "Bad Oriented Volume" ) ) return FT_BadOrientedVolume;
+ else if ( theStr.equals( "Volumes with bare border" ) ) return FT_BareBorderVolume;
+ else if ( theStr.equals( "Faces with bare border" ) ) return FT_BareBorderFace;
else if ( theStr.equals( "Less than" ) ) return FT_LessThan;
else if ( theStr.equals( "More than" ) ) return FT_MoreThan;
else if ( theStr.equals( "Equal to" ) ) return FT_EqualTo;
namespace SMESH
{
+ // ================================================================================
namespace Controls
{
Controls::ElementsOnShapePtr myElementsOnShapePtr; // only if myIsSubshape == false
};
typedef boost::shared_ptr<LyingOnGeom> LyingOnGeomPtr;
- }
-
+
+ } // namespace Controls
+
+ // ================================================================================
/*
FUNCTORS
*/
FunctorType GetFunctorType();
};
+ /*
+ Class : BareBorderVolume_i
+ Description : Verify whether a mesh volume is incorrectly oriented from
+ the point of view of MED convention
+ */
+ class SMESH_I_EXPORT BareBorderVolume_i: public virtual POA_SMESH::BareBorderVolume,
+ public virtual Predicate_i
+ {
+ public:
+ BareBorderVolume_i();
+ FunctorType GetFunctorType();
+ };
+
+ /*
+ Class : BareBorderFace_i
+ Description : Verify whether a mesh volume is incorrectly oriented from
+ the point of view of MED convention
+ */
+ class SMESH_I_EXPORT BareBorderFace_i: public virtual POA_SMESH::BareBorderFace,
+ public virtual Predicate_i
+ {
+ public:
+ BareBorderFace_i();
+ FunctorType GetFunctorType();
+ };
+
/*
Class : BelongToGeom_i
Description : Predicate for selection on geometrical support
RangeOfIds_ptr CreateRangeOfIds();
BadOrientedVolume_ptr CreateBadOrientedVolume();
+ BareBorderFace_ptr CreateBareBorderFace();
+ BareBorderVolume_ptr CreateBareBorderVolume();
LinearOrQuadratic_ptr CreateLinearOrQuadratic();
GroupColor_ptr CreateGroupColor();