00001 /* +---------------------------------------------------------------------------+ 00002 | The Mobile Robot Programming Toolkit (MRPT) C++ library | 00003 | | 00004 | http://mrpt.sourceforge.net/ | 00005 | | 00006 | Copyright (C) 2005-2008 University of Malaga | 00007 | | 00008 | This software was written by the Machine Perception and Intelligent | 00009 | Robotics Lab, University of Malaga (Spain). | 00010 | Contact: Jose-Luis Blanco <jlblanco@ctima.uma.es> | 00011 | | 00012 | This file is part of the MRPT project. | 00013 | | 00014 | MRPT is free software: you can redistribute it and/or modify | 00015 | it under the terms of the GNU General Public License as published by | 00016 | the Free Software Foundation, either version 3 of the License, or | 00017 | (at your option) any later version. | 00018 | | 00019 | MRPT is distributed in the hope that it will be useful, | 00020 | but WITHOUT ANY WARRANTY; without even the implied warranty of | 00021 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 00022 | GNU General Public License for more details. | 00023 | | 00024 | You should have received a copy of the GNU General Public License | 00025 | along with MRPT. If not, see <http://www.gnu.org/licenses/>. | 00026 | | 00027 +---------------------------------------------------------------------------+ */ 00028 00029 #ifndef opengl_CCamera_H 00030 #define opengl_CCamera_H 00031 00032 #include <mrpt/opengl/CRenderizable.h> 00033 00034 namespace mrpt 00035 { 00036 namespace opengl 00037 { 00038 class COpenGLViewport; 00039 class CCamera; 00040 00041 // This must be added to any CSerializable derived class: 00042 DEFINE_SERIALIZABLE_PRE_CUSTOM_BASE( CCamera, CRenderizable ) 00043 00044 00045 /*struct CCameraPtr : public CRenderizablePtr 00046 { 00047 template <class R> CCameraPtr(R *p) : CRenderizablePtr(p) { } 00048 CCamera* operator ->(void) { return reinterpret_cast<CCamera*>( CRenderizablePtr::operator ->() ); } // reinterpret_cast is because class forward declaration only 00049 }; */ 00050 00051 00055 class MRPTDLLIMPEXP CCamera : public CRenderizable 00056 { 00057 friend class COpenGLViewport; 00058 00059 DEFINE_SERIALIZABLE( CCamera ) 00060 public: 00061 float m_pointingX,m_pointingY,m_pointingZ, 00062 m_distanceZoom, 00063 m_azimuthDeg,m_elevationDeg; 00064 00067 bool m_projectiveModel; 00068 00071 float m_projectiveFOVdeg; 00072 00074 static CCameraPtr Create() 00075 { 00076 return CCameraPtr( new CCamera ); 00077 } 00078 00081 void render() { } 00082 00083 private: 00086 CCamera(); 00087 00089 virtual ~CCamera() { } 00090 00091 }; 00092 00093 } // end namespace opengl 00094 00095 } // End of namespace 00096 00097 00098 #endif
Page generated by Doxygen 1.5.8 for MRPT 0.6.5 SVN:exported at Mon Jan 12 13:00:16 UTC 2009 |