3 #include "CullingResult.h"
7 #include <glm/vec3.hpp>
25 : _center(center), _radius(radius) {}
30 constexpr
const glm::dvec3&
getCenter() const noexcept {
37 constexpr
double getRadius() const noexcept {
return this->_radius; }
72 bool contains(
const glm::dvec3& position)
const noexcept;
A bounding sphere with a center and a radius.
CullingResult intersectPlane(const Plane &plane) const noexcept
Determines on which side of a plane this boundings sphere is located.
bool contains(const glm::dvec3 &position) const noexcept
Computes whether the given position is contained within the bounding sphere.
constexpr const glm::dvec3 & getCenter() const noexcept
Gets the center of the bounding sphere.
constexpr BoundingSphere(const glm::dvec3 ¢er, double radius) noexcept
Construct a new instance.
double computeDistanceSquaredToPosition(const glm::dvec3 &position) const noexcept
Computes the distance squared from a position to the closest point on this bounding sphere....
constexpr double getRadius() const noexcept
Gets the radius of the bounding sphere.
BoundingSphere transform(const glm::dmat4 &transformation) const noexcept
Transforms this bounding sphere to another coordinate system using a 4x4 matrix.
A plane in Hessian Normal Format.
Basic geometry classes for Cesium.
CullingResult
The result of culling an object.