Represents a polygon.
Index of first point in the polygon.
Type: int
Index of second point in the polygon.
Type: int
Index of third point in the polygon.
Type: int
Index of optional fourth point in the polygon.
Type: int
Parameters: |
|
---|
Returns a string representation of the polygon. Called if str() is wrapped around an instance of CPolygon. (see __str__).
Return type: | str |
---|---|
Returns: | The string representation of the polygon. |
New in version R16.021.
Checks if the polygon is a triangle.
Return type: | bool |
---|---|
Returns: | True if the polygon is a triangle, otherwise False. |
New in version R16.021.
Checks if one of the polygon vertex indices is equal to index and returns the found polygon vertex number (0-3, equals a - d).
Parameters: | index (int) – The vertex index to check. |
---|---|
Return type: | int |
Returns: | The matching polygon vertex number (0-3, equals a - d). NOTOK is returned if there is no match. |
New in version R16.021.
Checks if the vertex indices index1 and index2 form an edge in this polygon. If so the polygon edge number is returned (0-3).
Parameters: |
|
---|---|
Return type: | int |
Returns: | The found polygon edge number (0-3). NOTOK is returned if there is no match. |
New in version R16.021.
Retrieves the point indices for edge.
Parameters: | edge (int) – The edge index (0-3). |
---|---|
Return type: | tuple(int, int) |
Returns: | The index of the first and second edge point. |