GREM 3.12.0
Game/Rendering Engine Modules for C++
Loading...
Searching...
No Matches
grem::physics::convex_polytope_shape Concept Reference

Concept that checks if a type is a valid convex polytope shape type. More...

#include <GREM/physics/Shape.hpp>

Concept definition

template<typename T, size_t N>
requires(const T t, const ConvexPolytopeVertexIndex vertexIndex, const ConvexPolytopeFaceIndex faceIndex, const Direction<N> localDirection, const Direction<N> direction) {
{ t.getLocalSupportPointVertexIndex(localDirection, vertexIndex) } -> convertible_to<ConvexPolytopeVertexIndex>;
{ t.getVertexCount() } -> convertible_to<ConvexPolytopeVertexIndex>;
{ t.getFaceCount() } -> convertible_to<ConvexPolytopeFaceIndex>;
{ t.getLocalVertexOffset(vertexIndex) } -> convertible_to<Length<N>>;
{ t.getLocalFaceOffset(faceIndex) } -> convertible_to<Length<N>>;
{ t.getLocalFaceNormal(faceIndex) } -> convertible_to<Direction<N>>;
{ t.getFaceIndexWithMostFittingLocalNormal(localDirection, faceIndex) } -> convertible_to<ConvexPolytopeFaceIndex>;
} && (N != 3 || requires(const T t, const ConvexPolytopeVertexIndex vertexIndex, const ConvexPolytopeFaceIndex faceIndex, const ConvexPolytopeEdgeIndex edgeIndex) {
{ t.getEdgeCount() } -> convertible_to<ConvexPolytopeEdgeIndex>;
{ t.getFirstVertexIndexOfEdge(edgeIndex) } -> convertible_to<ConvexPolytopeVertexIndex>;
{ t.getFaceIndexOfEdge(edgeIndex) } -> convertible_to<ConvexPolytopeFaceIndex>;
{ t.getNextEdgeIndex(edgeIndex) } -> convertible_to<ConvexPolytopeEdgeIndex>;
{ t.getFirstEdgeIndexOfFace(faceIndex) } -> convertible_to<ConvexPolytopeEdgeIndex>;
{ t.getSomeEdgeIndexOfVertex(vertexIndex) } -> convertible_to<ConvexPolytopeEdgeIndex>;
})
Definition concepts.hpp:47
Concept that checks if a type is a valid convex polytope shape type.
Definition Shape.hpp:1288
Concept that checks if a type is a valid convex shape type.
Definition Shape.hpp:1260
@ N
'n'
Definition keyboard.hpp:84
@ T
't'
Definition keyboard.hpp:90
uint8_t ConvexPolytopeEdgeIndex
Index of an edge in a convex polytope.
Definition ConvexPolytope.hpp:29
uint8_t ConvexPolytopeVertexIndex
Index of a vertex in a convex polytope.
Definition ConvexPolytope.hpp:24
uint8_t ConvexPolytopeFaceIndex
Index of a face in a convex polytope.
Definition ConvexPolytope.hpp:34
Normalized unit vector.
Definition quantities.hpp:4105

Detailed Description

Concept that checks if a type is a valid convex polytope shape type.

Template Parameters
Tthe type to check.
Nnumber of dimensions of the world space (must be 2 or 3).