Main Page   Namespace List   Class Hierarchy   Alphabetical List   Compound List   File List   Namespace Members   Compound Members   File Members   Related Pages  

Object.h

00001 /*
00002   File: Object.h
00003 
00004   Copyright(C) C. Kotterink, Computed Graphics
00005 */
00006 #ifndef OBJECT_H
00007 #define OBJECT_H
00008 
00009 #include<WDFFile.h>
00010 #include<RenderContext.h>
00011 
00012 class Ray;
00013 class World;
00014 class CollisionHull;
00015 
00018 class Object
00019 {
00020 public:
00021     Object() {}
00022     const AABoundingBox &getBound() const {
00023         return bound;
00024     }
00025 
00026     virtual bool update(World &world);
00027     virtual void render(
00028         RenderContext &rc,
00029         RenderContext::Visibility visibility = RenderContext::PartlyVisible
00030     ) = 0;
00031     virtual float collide(
00032         const CollisionHull &hull, Vertex3 &nearestIntersection);
00033     virtual real intersect(const Ray &ray) const;
00034 
00035     void read(WDFFile &f);
00036     virtual void write(WDFFile &f);
00037     virtual void readChunk(WDFFile::Chunk &chunk, WDFFile &f);
00038 
00039 protected:
00040     AABoundingBox bound;
00041 };
00042 #endif

This documentation was generated using doxygen. If you have any comments or additions please mail me.