00001 // ///////////////////////////////////////////////////////////////////////////// 00002 // 00003 // Name: OctTreeComponent.h 00004 // Author: Michael Bartsch (ZCCdark203) 00005 // 00006 // Desc : Declaration of the OctTreeComponent class. 00007 // 00008 // License: Copyright (C) 2009 Michael Bartsch and Contributors 00009 // 00010 // This program is free software: you can redistribute it 00011 // and/or modify it under the terms of the zlib/libpng License. 00012 // See main.cpp for conditions of distribution and use. 00013 // 00014 // ///////////////////////////////////////////////////////////////////////////// 00015 00016 #ifndef __OCTTREECOMPONENT_H__ 00017 #define __OCTTREECOMPONENT_H__ 00018 00019 // Include files 00020 #include "../../dependencies.h" 00021 #include "SceneComponent.h" 00022 00023 00024 // OctTreeComponent class 00026 class OctTreeComponent : public SceneComponent 00027 { 00028 public: 00029 00030 // Initialisation and deinitialisation 00037 OctTreeComponent(Entity *parent, const std::string &fileName, s32 minPolysPerNode = 256); 00045 OctTreeComponent(Entity *parent, IMesh *mesh, s32 minPolysPerNode = 256); 00053 OctTreeComponent(Entity *parent, IAnimatedMesh *mesh, s32 minPolysPerNode = 512); 00055 ~OctTreeComponent(); 00056 00057 // AngelScript binding 00060 static OctTreeComponent* refFactory(Entity *parent, const std::string &fileName, 00061 s32 minPolysPerNode); 00062 }; 00063 00064 00065 // OctTreeComponent Angelscript binding. 00067 extern void bindOctTreeComponent(asIScriptEngine *engine); 00068 00069 #endif