#define PRIMITIVE_HXX
#include "Ray.hxx"
+#include "Shader.hxx"
+#include "Box.hxx"
class Primitive
{
public:
+ Primitive(Shader* shader = 0);
+ virtual ~Primitive();
+
virtual bool Intersect(Ray &ray) = 0;
+ virtual bool Occluded(Ray& ray);
+ virtual Vec3f GetNormal(Ray& ray) = 0;
+ virtual Box CalcBounds() = 0;
+ virtual bool InVoxel(const Box& box) = 0;
+ Shader* shader();
+
+protected:
+ Shader* m_shader;
};
#endif