Go to the documentation of this file.
28 #ifndef __PlaneBoundedVolume_H_
29 #define __PlaneBoundedVolume_H_
60 : outside(theOutside) {}
67 if (box.
isNull())
return false;
75 PlaneList::const_iterator i, iend;
77 for (i = planes.begin(); i != iend; ++i)
79 const Plane& plane = *i;
98 PlaneList::const_iterator i, iend;
100 for (i = planes.begin(); i != iend; ++i)
102 const Plane& plane = *i;
std::pair< bool, Real > intersects(const Ray &ray)
Intersection test with a Ray.
Defines a plane in 3D space.
bool intersects(const Sphere &sphere) const
Intersection test with Sphere.
bool isInfinite(void) const
Returns true if the box is infinite.
Real getRadius(void) const
Returns the radius of the sphere.
Side
The "positive side" of the plane is the half space to which the plane normal points.
bool intersects(const AxisAlignedBox &box) const
Intersection test with AABB.
Side getSide(const Vector3 &rkPoint) const
Vector3 getCenter(void) const
Gets the centre of the box.
PlaneBoundedVolume(Plane::Side theOutside)
Constructor, determines which side is deemed to be 'outside'.
Real getDistance(const Vector3 &rkPoint) const
This is a pseudodistance.
bool isNull(void) const
Returns true if the box is null i.e.
const Vector3 & getCenter(void) const
Returns the center point of the sphere.
A 3D box aligned with the x/y/z axes.
A sphere primitive, mostly used for bounds checking.
Represents a convex volume bounded by planes.
static std::pair< bool, Real > intersects(const Ray &ray, const Plane &plane)
Ray / plane intersection, returns boolean result and distance.
vector< Plane >::type PlaneList
Vector3 getHalfSize(void) const
Gets the half-size of the box.
float Real
Software floating point type.
vector< PlaneBoundedVolume >::type PlaneBoundedVolumeList
PlaneList planes
Publicly accessible plane list, you can modify this direct.
Representation of a ray in space, i.e.
Standard 3-dimensional vector.
Copyright © 2012 Torus Knot Software Ltd

This work is licensed under a Creative Commons Attribution-ShareAlike 3.0 Unported License.
Last modified Tue Apr 13 2021 08:53:15