Added Frustum::Contains(AxisAlignedBox)

Fixed Frustum::Contains, Intersect and Plane::Distance not being const


Former-commit-id: e219a10fac78f50743f19ebe523345bcac0b0fb7
This commit is contained in:
Lynix
2013-02-20 16:41:29 +01:00
parent 6bfe9c8890
commit 28ea9fc9a0
4 changed files with 55 additions and 14 deletions

View File

@@ -8,6 +8,7 @@
#define NAZARA_FRUSTUM_HPP
#include <Nazara/Core/String.hpp>
#include <Nazara/Math/AxisAlignedBox.hpp>
#include <Nazara/Math/Enums.hpp>
#include <Nazara/Math/Matrix4.hpp>
#include <Nazara/Math/Plane.hpp>
@@ -25,10 +26,11 @@ class NzFrustum
NzFrustum& Build(T angle, T ratio, T zNear, T zFar, const NzVector3<T>& eye, const NzVector3<T>& target, const NzVector3<T>& up = NzVector3<T>::Up());
bool Contains(const NzCube<T>& cube);
bool Contains(const NzSphere<T>& sphere);
bool Contains(const NzVector3<T>& point);
bool Contains(const NzVector3<T>* points, unsigned int pointCount);
bool Contains(const NzAxisAlignedBox<T>& box) const;
bool Contains(const NzCube<T>& cube) const;
bool Contains(const NzSphere<T>& sphere) const;
bool Contains(const NzVector3<T>& point) const;
bool Contains(const NzVector3<T>* points, unsigned int pointCount) const;
NzFrustum& Extract(const NzMatrix4<T>& clipMatrix);
NzFrustum& Extract(const NzMatrix4<T>& view, const NzMatrix4<T>& projection);
@@ -36,9 +38,10 @@ class NzFrustum
const NzVector3<T>& GetCorner(nzCorner corner) const;
const NzPlane<T>& GetPlane(nzFrustumPlane plane) const;
nzIntersectionSide Intersect(const NzAxisAlignedBox<T>& box) const;
nzIntersectionSide Intersect(const NzCube<T>& cube) const;
nzIntersectionSide Intersect(const NzSphere<T>& sphere) const;
nzIntersectionSide Intersect(const NzVector3<T>* points, unsigned int pointCount);
nzIntersectionSide Intersect(const NzVector3<T>* points, unsigned int pointCount) const;
NzFrustum& Set(const NzFrustum& frustum);
template<typename U> NzFrustum& Set(const NzFrustum<U>& frustum);