Specialization of the class for specifying indices of vertices for defining a DIM-dimensional polytope for DIM=2 (i.e., a polygon) More...
#include <ptems/polytope.hpp>
Public Types | |
| typedef std::vector< std::size_t >::const_iterator | iterator |
| Type of iterator over the vertices. More... | |
| typedef std::vector< std::size_t >::const_iterator | const_iterator |
| Type of iterator over the vertices. More... | |
Public Member Functions | |
| template<typename It > | |
| Polytope (It begin, It end) | |
| Constructs a polygon from a list of vertex indices. More... | |
| Polytope (std::vector< std::size_t > &&vertices) | |
| Constructs a polygon from a list of vertex indices. More... | |
| template<typename... INDICES, typename = std::enable_if<(std::is_integral_v<INDICES> && ...)>> | |
| Polytope (std::size_t index1, INDICES... indices) | |
| Constructs a polygon from a list of vertex indices. More... | |
| Polytope (const std::initializer_list< std::size_t > &indices) | |
| Constructs a polygon from a list of vertex indices. More... | |
| template<typename V > | |
| bool | Validate ([[maybe_unused]] const V &vertexList) const |
| Checks if the polytope defines a valid polygon: More... | |
| int | Compare (const Polytope &rhs) const |
| Compares this polygon to the specified polygon with strict ordering. More... | |
| std::set< Polytope< 1 > > | Faces () const |
| Gets list of faces of the polygon (edges) More... | |
| std::size_t | size () const |
| Gets the number of vertices in the polytope. More... | |
| std::size_t | operator[] (std::size_t idx) const |
| Gets the specified vertex of the polytope. More... | |
| const_iterator | begin () const |
| Gets begin iterator over the list of vertices of the polytope. More... | |
| const_iterator | cbegin () const |
| Gets begin iterator over the list of vertices of the polytope. More... | |
| const_iterator | end () const |
| Gets end iterator over the list of vertices of the polytope. More... | |
| const_iterator | cend () const |
| Gets begin iterator over the list of vertices of the polytope. More... | |
Specialization of the class for specifying indices of vertices for defining a DIM-dimensional polytope for DIM=2 (i.e., a polygon)
| typedef std::vector<std::size_t>::const_iterator ptems::Polytope< 2 >::const_iterator |
Type of iterator over the vertices.
| typedef std::vector<std::size_t>::const_iterator ptems::Polytope< 2 >::iterator |
Type of iterator over the vertices.
|
inline |
Constructs a polygon from a list of vertex indices.
| Type | of iterator over list of vertices |
| begin | The iterator to the start of the list of vertex indices |
| end | The iterator to the end of the list of vertex indices |
|
inline |
Constructs a polygon from a list of vertex indices.
| vertices | List of vertex indices defining the polygon |
|
inline |
Constructs a polygon from a list of vertex indices.
| index1 | First vertex index defining the polygon |
| indices | Rest of vertex indices defining the polygon |
|
inline |
Constructs a polygon from a list of vertex indices.
| indices | List of vertex indices defining the polygon |
|
inline |
Gets begin iterator over the list of vertices of the polytope.
|
inline |
Gets begin iterator over the list of vertices of the polytope.
|
inline |
Gets begin iterator over the list of vertices of the polytope.
|
inline |
Compares this polygon to the specified polygon with strict ordering.
| rhs | The right hand polygon to compare to |
|
inline |
Gets end iterator over the list of vertices of the polytope.
|
inline |
Gets list of faces of the polygon (edges)
|
inline |
Gets the specified vertex of the polytope.
| std::out_of_range | If idx is greater than 1 |
| idx | Index of vertex to get |
|
inline |
Gets the number of vertices in the polytope.
|
inline |
Checks if the polytope defines a valid polygon:
This makes no guarantee about simplicity (could self-intersect)
| V | Type of vertex list - must be indexable |
| vertexList | List of vertices to look up the polygon vertices in |