summaryrefslogtreecommitdiffstats
path: root/src/ShadowVolume.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/ShadowVolume.h')
-rw-r--r--src/ShadowVolume.h16
1 files changed, 4 insertions, 12 deletions
diff --git a/src/ShadowVolume.h b/src/ShadowVolume.h
index 445e7ba..a7b276c 100644
--- a/src/ShadowVolume.h
+++ b/src/ShadowVolume.h
@@ -20,8 +20,7 @@
#ifndef ZOOM_SHADOWVOLUME_H_
#define ZOOM_SHADOWVOLUME_H_
-#include <vmmlib/vector.hpp>
-#include <vmmlib/matrix.hpp>
+#include "MathUtil.h"
namespace Zoom {
@@ -32,12 +31,8 @@ class ShadowVolume {
ShadowVolume(const Triangle &t, const vmml::vec3f &lightPos);
virtual ~ShadowVolume() {}
- const vmml::vec3f& getVertex(int i) const {
- return rays[i].p;
- }
-
- const vmml::vec3f& getDirection(int i) const {
- return rays[i].dir;
+ const MathUtil::Ray& getRay(int i) const {
+ return rays[i];
}
bool isVisible() const {
@@ -47,10 +42,7 @@ class ShadowVolume {
private:
bool visible;
- struct Ray {
- vmml::vec3f p;
- vmml::vec3f dir;
- } rays[3];
+ MathUtil::Ray rays[3];
};
}