Internal model configuration concept. More...
#include <playrho/d2/detail/ShapeModel.hpp>
Public Types | |
| using | data_type = T |
| Type alias for the type of the data held. | |
Public Member Functions | |
| template<typename U , std::enable_if_t<!std::is_same_v< U, ShapeModel >, int > = 0> | |
| ShapeModel (U &&arg) noexcept(std::is_nothrow_constructible_v< T, U >) | |
| Initializing constructor. | |
| std::unique_ptr< ShapeConcept > | Clone_ () const override |
| Clones this concept and returns a pointer to a mutable copy. More... | |
| DistanceProxy | GetChild_ (ChildCounter index) const override |
| Gets the "child" specified by the given index. | |
| ChildCounter | GetChildCount_ () const noexcept override |
| Gets the "child" count. | |
| const void * | GetData_ () const noexcept override |
| Gets the data for the underlying configuration. | |
| NonNegative< AreaDensity > | GetDensity_ () const noexcept override |
| Gets the density. | |
| Filter | GetFilter_ () const noexcept override |
| Gets the filter. More... | |
| NonNegativeFF< Real > | GetFriction_ () const noexcept override |
| Gets the friction. | |
| MassData | GetMassData_ () const override |
| Gets the mass data. | |
| Real | GetRestitution_ () const noexcept override |
| Gets the restitution. | |
| TypeID | GetType_ () const noexcept override |
| Gets the use type information. More... | |
| NonNegative< Length > | GetVertexRadius_ (ChildCounter idx) const override |
| Gets the vertex radius. More... | |
| bool | IsEqual_ (const ShapeConcept &other) const noexcept override |
| Equality checking function. | |
| bool | IsSensor_ () const noexcept override |
| Gets whether or not this shape is a sensor. More... | |
| void | Rotate_ (const UnitVec &value) override |
| Rotates all of the shape's vertices by the given amount. | |
| void | Scale_ (const Vec2 &value) override |
| Scales all of the shape's vertices by the given amount. | |
| void | SetDensity_ (NonNegative< AreaDensity > value) noexcept override |
| Sets the density. | |
| void | SetFilter_ (Filter value) override |
| Sets the filter. More... | |
| void | SetFriction_ (NonNegative< Real > value) override |
| Sets the friction. | |
| void | SetRestitution_ (Real value) override |
| Sets the restitution. | |
| void | SetSensor_ (bool value) override |
| Sets whether or not this shape is a sensor. More... | |
| void | SetVertexRadius_ (ChildCounter idx, NonNegative< Length > value) override |
| Sets the vertex radius. More... | |
| void | Translate_ (const Length2 &value) override |
| Translates all of the shape's vertices by the given amount. | |
Public Attributes | |
| data_type | data |
| Data. | |
Internal model configuration concept.
|
inlineoverridevirtual |
Clones this concept and returns a pointer to a mutable copy.
std::bad_alloc or any exception that's thrown by the constructor for the model's underlying data type. | std::bad_alloc | if there's a failure allocating storage. |
Implements playrho::d2::detail::ShapeConcept.
|
inlineoverridevirtualnoexcept |
|
inlineoverridevirtualnoexcept |
Gets the use type information.
Implements playrho::d2::detail::ShapeConcept.
Referenced by playrho::d2::detail::ShapeModel< T >::IsEqual_().
|
inlineoverridevirtual |
Gets the vertex radius.
| idx | Child index to get vertex radius for. |
Implements playrho::d2::detail::ShapeConcept.
|
inlineoverridevirtualnoexcept |
Gets whether or not this shape is a sensor.
Implements playrho::d2::detail::ShapeConcept.
|
inlineoverridevirtual |
|
inlineoverridevirtual |
Sets whether or not this shape is a sensor.
Implements playrho::d2::detail::ShapeConcept.
|
inlineoverridevirtual |
Sets the vertex radius.
| idx | Child index to set vertex radius for. |
| value | Value to set the vertex radius to. |
Implements playrho::d2::detail::ShapeConcept.