2#pragma warning(disable : 4251)
10class EntityMeshTetFace;
11class EntityMeshTetItemDataFaces;
12class EntityMeshTetItemDataTets;
13class EntityMeshTetItemDataTetedges;
19class __declspec(dllexport) EntityMeshTetItem :
public EntityBase
22 EntityMeshTetItem(
ot::UID ID, EntityBase *parent, EntityObserver *obs, ModelState *ms, ClassFactoryHandler*factory,
const std::string &owner);
23 virtual ~EntityMeshTetItem();
25 virtual bool getEntityBox(
double &xmin,
double &xmax,
double &ymin,
double &ymax,
double &zmin,
double &zmax)
override;
27 void setMesh(EntityMeshTet *
m) { mesh =
m; };
29 void setNumberTets(
size_t nT);
30 void setNumberTetEdges(
size_t nE);
31 void setNumberFaces(
size_t nT) { faces.resize(nT); setModified(); };
33 int getFaceId(
size_t nF) {
return faces[nF]; };
34 void setFace(
size_t nF,
int faceId) { faces[nF] = faceId; setModified(); };
36 bool getFaceOrientation(
size_t nF) {
return getFaceId(nF) > 0; };
38 EntityMeshTetFace *getFace(
size_t nF);
40 void updateStatistics(
void);
41 size_t getNumberTriangles(
void) {
return numberOfTriangles; };
42 size_t getNumberTets(
void) {
return numberOfTets; };
43 size_t getNumberTetEdges(
void) {
return numberOfTetEdges; };
44 size_t getNumberFaces(
void) {
return faces.size(); };
46 void setNumberOfTetNodes(
size_t nT,
int nNodes);
47 void setTetNode(
size_t nT,
int nodeIndex,
size_t node);
48 size_t getTetNode(
size_t nT,
int nodeIndex);
50 void setTetEdgeNodes(
size_t nE,
size_t n[2]);
51 void getTetEdgeNodes(
size_t nE,
size_t n[2]);
53 virtual void StoreToDataBase(
void)
override;
55 virtual void addVisualizationNodes(
void)
override;
57 void addVisualizationItem(
bool isHidden);
59 void setColor(
double r,
double g,
double b) { colorRGB[0] = r; colorRGB[1] = g; colorRGB[2] =
b; };
61 virtual std::string getClassName(
void)
override {
return "EntityMeshTetItem"; };
63 long long getMeshDataTetsStorageId(
void) {
return meshDataTetsStorageId; };
64 long long getMeshDataTetedgesStorageId(
void) {
return meshDataTetEdgesStorageId; };
66 virtual entityType getEntityType(
void)
override {
return TOPOLOGY; };
67 virtual void removeChild(EntityBase *child)
override;
71 EntityMeshTetItemDataTets *getMeshDataTets(
void) {
return meshDataTets; }
72 EntityMeshTetItemDataTetedges *getMeshDataTetEdges(
void) {
return meshDataTetEdges; }
74 virtual bool updateFromProperties(
void)
override;
77 void EnsureMeshItemDataTetsLoaded(
void);
78 void EnsureMeshItemDataTetEdgesLoaded(
void);
79 void storeMeshData(
void);
80 void releaseMeshData(
void);
81 virtual int getSchemaVersion(
void)
override {
return 1; };
82 virtual void AddStorageData(bsoncxx::builder::basic::document &storage)
override;
83 virtual void readSpecificDataFromDataBase(bsoncxx::document::view &doc_view, std::map<ot::UID, EntityBase *> &entityMap)
override;
87 EntityMeshTetItemDataTets *meshDataTets;
90 EntityMeshTetItemDataTetedges *meshDataTetEdges;
91 ot::UID meshDataTetEdgesStorageId;
95 std::vector<int> faces;
97 BoundingBox boundingBox;
98 size_t numberOfTriangles;
100 size_t numberOfTetEdges;
Mesh m
Definition SelfIntersectionCheck.cpp:26
double double double b[]
Definition GeometryOperations.h:24
BoundingBox getBoundingBox(std::list< EntityGeometry * > &geometryEntities)
Definition GeometryOperations.cpp:230
unsigned long UID
Unique identifier (32 bit unsigned integer)
Definition CoreTypes.h:27