CObject.h
00001 00008 #ifndef __COBJECT_H__ 00009 #define __COBJECT_H__ 00010 00011 #include "CNode.h" 00012 #include "CMaterial.h" 00013 00014 class CObject : public CNode 00015 { 00016 protected: 00017 CNode *mNode; 00018 CMaterial *mMaterial; 00019 00020 public: 00021 CObject() { mNode = GetNodeInstance(); } 00022 virtual ~CObject() { } 00023 00024 // set 00025 __forceinline SetNode(CNode* node) { mNode = node; } 00026 __forceinline SetMaterial(CMaterial* material) { mMaterial = material; } 00027 00028 // get 00029 __forceinline CMaterial* GetMaterial() const { return mMaterial; } 00030 __forceinline CNode* GetNode() const { return mNode; } 00031 00032 // [hérité de CNode] 00033 virtual bool IntersectsNode(const CRay& ray, CIntersectInfo *intersectInfo=NULL) = 0; 00034 }; 00035 00036 #endif /* #ifndef __COBJECT_H__ */
Generated on Fri Apr 19 16:19:34 2002 by 1.2.15