00001 /**************************************************************************** 00002 00003 This file is part of the GLC-lib library. 00004 Copyright (C) 2005-2008 Laurent Ribon (laumaya@users.sourceforge.net) 00005 http://glc-lib.sourceforge.net 00006 00007 GLC-lib is free software; you can redistribute it and/or modify 00008 it under the terms of the GNU Lesser General Public License as published by 00009 the Free Software Foundation; either version 3 of the License, or 00010 (at your option) any later version. 00011 00012 GLC-lib is distributed in the hope that it will be useful, 00013 but WITHOUT ANY WARRANTY; without even the implied warranty of 00014 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 00015 GNU Lesser General Public License for more details. 00016 00017 You should have received a copy of the GNU Lesser General Public License 00018 along with GLC-lib; if not, write to the Free Software 00019 Foundation, Inc., 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA 00020 00021 *****************************************************************************/ 00023 00024 #ifndef GLC_SPACEPARTITIONING_H_ 00025 #define GLC_SPACEPARTITIONING_H_ 00026 00027 #include "../glc_config.h" 00028 #include "../glc_boundingbox.h" 00029 #include "../viewport/glc_frustum.h" 00030 00031 class GLC_3DViewCollection; 00032 class GLC_3DViewInstance; 00033 00036 00037 00038 class GLC_LIB_EXPORT GLC_SpacePartitioning 00039 { 00041 00043 00044 public: 00046 GLC_SpacePartitioning(GLC_3DViewCollection*); 00047 00049 GLC_SpacePartitioning(const GLC_SpacePartitioning&); 00050 00052 virtual ~GLC_SpacePartitioning(); 00054 00056 00058 00059 public: 00061 inline GLC_3DViewCollection* collectionHandle() 00062 {return m_pCollection;} 00063 00065 virtual QList<GLC_3DViewInstance*> listOfIntersectedInstances(const GLC_BoundingBox&)= 0; 00066 00067 00069 00070 00072 00073 public: 00074 00076 virtual void updateViewableInstances(const GLC_Frustum&)= 0; 00077 00079 virtual void updateSpacePartitioning()= 0; 00080 00082 virtual void clear()= 0; 00083 00085 00087 // Protected members 00089 protected: 00091 GLC_3DViewCollection* m_pCollection; 00092 00093 }; 00094 00095 #endif /* GLC_SPACEPARTITIONING_H_ */