Open CASCADE Technology Reference Manual 8.0.0
Loading...
Searching...
No Matches
Public Member Functions
Poly_CoherentTriangle Class Reference

#include <Poly_CoherentTriangle.hxx>

Public Member Functions

 Poly_CoherentTriangle ()
 
 Poly_CoherentTriangle (const int iNode0, const int iNode1, const int iNode2)
 
int Node (const int ind) const
 
bool IsEmpty () const noexcept
 
bool SetConnection (const int iConn, Poly_CoherentTriangle &theTr)
 
bool SetConnection (Poly_CoherentTriangle &theTri)
 
void RemoveConnection (const int iConn)
 
bool RemoveConnection (Poly_CoherentTriangle &theTri)
 
int NConnections () const
 
int GetConnectedNode (const int iConn) const
 
const Poly_CoherentTriangleGetConnectedTri (const int iConn) const
 
const Poly_CoherentLinkGetLink (const int iLink) const
 
int FindConnection (const Poly_CoherentTriangle &) const
 

Detailed Description

Data class used in Poly_CoherentTriangultion. Implements a triangle with references to its neighbours.

Constructor & Destructor Documentation

◆ Poly_CoherentTriangle() [1/2]

Poly_CoherentTriangle::Poly_CoherentTriangle ( )

Empty constructor.

◆ Poly_CoherentTriangle() [2/2]

Poly_CoherentTriangle::Poly_CoherentTriangle ( const int iNode0,
const int iNode1,
const int iNode2 )

Constructor.

Member Function Documentation

◆ FindConnection()

int Poly_CoherentTriangle::FindConnection ( const Poly_CoherentTriangle & ) const

Returns the index of the connection with the given triangle, or -1 if not found.

◆ GetConnectedNode()

int Poly_CoherentTriangle::GetConnectedNode ( const int iConn) const
inline

Query the connected node on the given side. Returns -1 if there is no connection on the specified side.

◆ GetConnectedTri()

const Poly_CoherentTriangle * Poly_CoherentTriangle::GetConnectedTri ( const int iConn) const
inline

Query the connected triangle on the given side. Returns NULL if there is no connection on the specified side.

◆ GetLink()

const Poly_CoherentLink * Poly_CoherentTriangle::GetLink ( const int iLink) const
inline

Query the Link associate with the given side of the Triangle. May return NULL if there are no links in the triangulation.

◆ IsEmpty()

bool Poly_CoherentTriangle::IsEmpty ( ) const
inlinenoexcept

Query if this is a valid triangle.

◆ NConnections()

int Poly_CoherentTriangle::NConnections ( ) const
inline

Query the number of connected triangles.

◆ Node()

int Poly_CoherentTriangle::Node ( const int ind) const
inline

Query the node index in the position given by the parameter 'ind'

◆ RemoveConnection() [1/2]

void Poly_CoherentTriangle::RemoveConnection ( const int iConn)

Remove the connection with the given index.

Parameters
iConnCan be 0, 1 or 2 - index of the node that is opposite to the connection (shared link).

◆ RemoveConnection() [2/2]

bool Poly_CoherentTriangle::RemoveConnection ( Poly_CoherentTriangle & theTri)

Remove the connection with the given Triangle.

Returns
True if successfuol or False if the connection has not been found.

◆ SetConnection() [1/2]

bool Poly_CoherentTriangle::SetConnection ( const int iConn,
Poly_CoherentTriangle & theTr )

Create connection with another triangle theTri. This method creates both connections: in this triangle and in theTri. You do not need to call the same method on triangle theTr.

Parameters
iConnCan be 0, 1 or 2 - index of the node that is opposite to the connection (shared link).
theTrTriangle that is connected on the given link.
Returns
True if successful, False if the connection is rejected due to improper topology.

◆ SetConnection() [2/2]

bool Poly_CoherentTriangle::SetConnection ( Poly_CoherentTriangle & theTri)

Create connection with another triangle theTri. This method creates both connections: in this triangle and in theTri. This method is slower than the previous one, because it makes analysis what sides of both triangles are connected.

Parameters
theTriTriangle that is connected.
Returns
True if successful, False if the connection is rejected due to improper topology.

The documentation for this class was generated from the following file: