gz/math/Plane.hh
Go to the documentation of this file.
PlaneSide
Enum used to indicate a side of the plane, no side, or both sides for entities on the plane.
Definition: gz/math/Plane.hh:43
Definition: gz/math/AdditivelySeparableScalarField3.hh:27
PlaneSide Side(const math::AxisAlignedBox &_box) const
The side of the plane a box is on.
Definition: gz/math/Plane.hh:196
T Distance(const Vector3< T > &_point) const
The distance to the plane from the given point. The distance can be negative, which indicates the poi...
Definition: gz/math/Plane.hh:120
@ BOTH_SIDE
On both sides of the plane.
Definition: gz/math/Plane.hh:57
T Distance(const Vector3< T > &_origin, const Vector3< T > &_dir) const
Get distance to the plane give an origin and direction.
Definition: gz/math/Plane.hh:214
PlaneSide Side(const Vector3< T > &_point) const
The side of the plane a point is on.
Definition: gz/math/Plane.hh:177
@ NEGATIVE_SIDE
Negative side of the plane. This is the side that is opposite the normal.
Definition: gz/math/Plane.hh:47
The Vector3 class represents the generic vector containing 3 elements. Since it's commonly used to ke...
Definition: gz/math/Vector3.hh:41
const Vector3< T > & Normal() const
Get the plane offset.
Definition: gz/math/Plane.hh:245
void Set(const Vector3< T > &_normal, T _offset)
Set the plane.
Definition: gz/math/Plane.hh:96
std::optional< Vector3< T > > Intersection(const Vector3< T > &_point, const Vector3< T > &_gradient, const double &_tolerance=1e-6) const
Get the intersection of an infinite line with the plane, given the line's gradient and a point in par...
Definition: gz/math/Plane.hh:133
Vector3< T > & Normal()
Get the plane offset.
Definition: gz/math/Plane.hh:251
@ POSITIVE_SIDE
Positive side of the plane. This is the side that has the normal vector.
Definition: gz/math/Plane.hh:51
void Set(const Vector3< T > &_normal, const Vector2< T > &_size, T _offset)
Set the plane.
Definition: gz/math/Plane.hh:106
Plane(const Plane &_plane)
Copy constructor.
Definition: gz/math/Plane.hh:86
T Dot(const Vector3< T > &_v) const
Return the dot product of this vector and another vector.
Definition: gz/math/Vector3.hh:205
Mathematical representation of a box that is aligned along an X,Y,Z axis.
Definition: gz/math/AxisAlignedBox.hh:42
Plane(const Vector3< T > &_normal, T _offset=0.0)
Constructor from a normal and a distance.
Definition: gz/math/Plane.hh:69
Plane< T > & operator=(const Plane< T > &_p)
Equal operator.
Definition: gz/math/Plane.hh:265
Plane(const Vector3< T > &_normal, const Vector2< T > &_size, T _offset)
Constructor.
Definition: gz/math/Plane.hh:78
Vector3 Cross(const Vector3< T > &_v) const
Return the cross product of this vector with another vector.
Definition: gz/math/Vector3.hh:195
const Vector2< T > & Size() const
Get the plane size.
Definition: gz/math/Plane.hh:233