#include <mesh_attribute_utilities.h>
Template class used to attach data to polygon vertices. The polygon could be either a triangle or a quadrangle.
Public Types | |
| using | ValueType = T |
Public Member Functions | |
| PolyData () | |
| PolyData (ENUM_DONT_INITIALIZE) | |
| PolyData (const T &av, const T &bv, const T &cv, const T &dv) | |
| PolyData (const PolyData &src) | |
| MAXON_OPERATOR_COPY_ASSIGNMENT (PolyData) | |
| T & | operator[] (Int index) |
| const T & | operator[] (Int index) const |
| Bool | IsTriangle () const |
| Int | FindCornerIndex (const T &value) const |
| Int | FindEdge (const T &value1, const T &value2) const |
| void | GetEdgeValues (Int edge, T &av, T &bv) const |
| Int | GetMemorySize () const |
| MAXON_OPERATOR_EQUALITY_HASHCODE (PolyData, a, b, c, d) | |
| String | ToString (const FormatStatement *formatStatement=nullptr) const |
Public Attributes | |
| T | a |
| T | b |
| T | c |
| T | d |
| using ValueType = T |
| PolyData | ( | ) |
|
explicit |
| PolyData | ( | const T & | av, |
| const T & | bv, | ||
| const T & | cv, | ||
| const T & | dv | ||
| ) |
| MAXON_OPERATOR_COPY_ASSIGNMENT | ( | PolyData< T > | ) |
| T& operator[] | ( | Int | index | ) |
| const T& operator[] | ( | Int | index | ) | const |
| Bool IsTriangle | ( | ) | const |
Checks if the polygon is a triangle.
| Int FindCornerIndex | ( | const T & | value | ) | const |
| Int FindEdge | ( | const T & | value1, |
| const T & | value2 | ||
| ) | const |
Finds the polygon edge that contains vertex values value1 and value2 and returns the edge index within (0 - 3).
| [in] | value1 | The index of the first edge vertex. |
| [in] | value2 | The index of the second edge vertex. |
| void GetEdgeValues | ( | Int | edge, |
| T & | av, | ||
| T & | bv | ||
| ) | const |
Gets the vertex values for a polygon edge index within (0 - 3).
| [in] | edge | The polygon edge index. |
| [out] | av | Assigned the value of the first edge vertex. |
| [out] | bv | Assigned the value of the second edge vertex. |
| Int GetMemorySize | ( | ) | const |
Returns the size of the data.
| String ToString | ( | const FormatStatement * | formatStatement = nullptr | ) | const |
Returns a string which represents the data.
| [in] | formatStatement | Optional format statement. |
| T a |
Value of the first polygon vertex.
| T b |
Value of the second polygon vertex.
| T c |
Value of the third polygon vertex.
| T d |
Value of the fourth polygon vertex.