more info on meshing and recalculation only if needed
This commit is contained in:
@@ -890,3 +890,25 @@ Data::Segment* FemMesh::getSubElement(const char* Type, unsigned long n) const
|
||||
//return new ShapeSegment(getSubShape(temp.c_str()));
|
||||
return 0;
|
||||
}
|
||||
|
||||
struct Fem::FemMesh::FemMeshInfo FemMesh::getInfo(void) const{
|
||||
|
||||
struct FemMeshInfo rtrn;
|
||||
|
||||
SMESHDS_Mesh* data = const_cast<SMESH_Mesh*>(getSMesh())->GetMeshDS();
|
||||
const SMDS_MeshInfo& info = data->GetMeshInfo();
|
||||
rtrn.numFaces = data->NbFaces();
|
||||
rtrn.numNode = info.NbNodes();
|
||||
rtrn.numTria = info.NbTriangles();
|
||||
rtrn.numQuad = info.NbQuadrangles();
|
||||
rtrn.numPoly = info.NbPolygons();
|
||||
rtrn.numVolu = info.NbVolumes();
|
||||
rtrn.numTetr = info.NbTetras();
|
||||
rtrn.numHexa = info.NbHexas();
|
||||
rtrn.numPyrd = info.NbPyramids();
|
||||
rtrn.numPris = info.NbPrisms();
|
||||
rtrn.numHedr = info.NbPolyhedrons();
|
||||
|
||||
return rtrn;
|
||||
|
||||
}
|
||||
@@ -104,6 +104,23 @@ public:
|
||||
void transformGeometry(const Base::Matrix4D &rclMat);
|
||||
//@}
|
||||
|
||||
struct FemMeshInfo {
|
||||
int numFaces;
|
||||
int numNode;
|
||||
int numTria;
|
||||
int numQuad;
|
||||
int numPoly;
|
||||
int numVolu;
|
||||
int numTetr;
|
||||
int numHexa;
|
||||
int numPyrd;
|
||||
int numPris;
|
||||
int numHedr;
|
||||
};
|
||||
|
||||
///
|
||||
struct FemMeshInfo getInfo(void) const;
|
||||
|
||||
/// import from files
|
||||
void read(const char *FileName);
|
||||
void write(const char *FileName) const;
|
||||
|
||||
Reference in New Issue
Block a user