24class WEMTrianglePatch;
65 virtual inline void setNode(
unsigned int ,
WEMNode* ) { invalidateBoundingBox(); }
80 virtual inline void setEdge(
unsigned int ,
WEMEdge* ) { invalidateBoundingBox(); }
This class represents an axis aligned bounding box for a WEMPatch.
Defines the mesh component: edge.
Defines the mesh component: face.
WEMBoundingBox _boundingBox
Bounding Box.
virtual Vector3 getCentroid() const =0
Returns the geometric centroid of a face.
virtual const WEMEdge * getEdgeNotContaining(WEMNode *n) const =0
Returns the edge not containing given node.
virtual WEMNode * getOther(WEMNode *n1, WEMNode *n2)=0
Returns the node incident to this face that is not given as a parameter.
bool _isBoundingBoxValid
Is the bounding box valid?
virtual const WEMEdge * getEdgeAt(unsigned int) const
Returns the edge at the given index in face.
WEMFace(WEMFace &&f) noexcept
virtual void computeNormal()=0
Computes the normal.
virtual WEMEdge * getOther(WEMEdge *e1, WEMEdge *e2)=0
Returns the edge incident to this face that is not given as a parameter.
virtual int isConcave() const =0
Checks whether this face is concave.
virtual int getIndex(WEMNode *node) const =0
Returns the index of the given node.
void invalidateBoundingBox()
virtual bool contains(WEMNode *node) const =0
Returns whether this face contains the given node.
virtual double getQuality() const =0
Calculates the quality of the face.
void reset()
Resets the object to default constructed state.
virtual double getArea() const =0
Calculates the area of face.
virtual void replace(WEMNode *orig, WEMNode *replace)=0
Replaces the given orig node by the given replace node.
bool isBoundingBoxValid() const
virtual const WEMEdge * getOther(WEMEdge *e1, WEMEdge *e2) const =0
Returns the edge incident to this face that is not given as a parameter.
Vector3 getNormal() const
Returns the normal.
virtual void setNode(unsigned int, WEMNode *)
Sets the given node to the given index in face.
virtual void replace(WEMEdge *orig, WEMEdge *replace)=0
Replaces the given orig node by the given replace edge.
virtual unsigned int getNumNodes() const =0
Returns the number of nodes.
~WEMFace() override
Standard destructor.
virtual void getCentroid(Vector3 ¢roid) const =0
virtual WEMBoundingBox getBoundingBox()
Calculates the bounding box of face.
void setNormal(const Vector3 &normal)
Sets the normal.
void clone(WEMFace *face)
Clones given face.
virtual WEMEdge * getEdgeNotContaining(WEMNode *n)=0
Returns the edge not containing given node.
virtual WEMNode * getNodeAt(unsigned int index)=0
Returns the node at the given index in face.
virtual const WEMNode * getOther(WEMNode *n1, WEMNode *n2) const =0
Returns the node incident to this face that is not given as a parameter.
virtual double getPerimeter() const =0
Calculates the perimeter of face.
virtual WEMEdge * getEdgeAt(unsigned int)
Returns the edge at the given index in face.
virtual int getIndex(WEMEdge *edge) const =0
Returns the index of the given edge.
virtual void setEdge(unsigned int, WEMEdge *)
Sets the given edge to the given index in face.
WEMFace()
Standard constructor.
virtual Vector3 getNodePositionAt(unsigned int index) const =0
Returns a position of a node at a given index.
virtual void mirror()=0
Mirrors the face.
WEMFace(const WEMFace &f)
Standard copy constructor.
WEMFace & operator=(WEMFace &&f) noexcept
virtual bool contains(WEMEdge *edge) const =0
Returns whether this face contains the given edge.
virtual void removeEdges()=0
Removes all edge pointers of this face.
virtual const WEMNode * getNodeAt(unsigned int index) const =0
Returns the node at the given index in face.
Defines the mesh component: node.
This is the base class for the WEM elements nodes, edges, and faces.
Target mlrange_cast(Source arg)
Generic version of checked ML casts.