Main Page | Modules | Class Hierarchy | Alphabetical List | Class List | File List | Class Members | File Members | Related Pages
csview.h
00001 /* 00002 CrystalSpace 3D renderer view 00003 Copyright (C) 1998-2001 by Jorrit Tyberghein 00004 00005 This library is free software; you can redistribute it and/or 00006 modify it under the terms of the GNU Library General Public 00007 License as published by the Free Software Foundation; either 00008 version 2 of the License, or (at your option) any later version. 00009 00010 This library is distributed in the hope that it will be useful, 00011 but WITHOUT ANY WARRANTY; without even the implied warranty of 00012 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00013 Library General Public License for more details. 00014 00015 You should have received a copy of the GNU Library General Public 00016 License along with this library; if not, write to the Free 00017 Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 00018 */ 00019 00020 #ifndef __CS_CSVIEW_H__ 00021 #define __CS_CSVIEW_H__ 00022 00023 #include "csextern.h" 00024 #include "igeom/clip2d.h" 00025 #include "ivaria/view.h" 00026 00027 class csPoly2D; 00028 class csBox2; 00029 00034 class CS_CSTOOL_EXPORT csView : public iView 00035 { 00036 private: 00038 csRef<iEngine> Engine; 00040 csRef<iGraphics3D> G3D; 00042 int OldWidth, OldHeight; 00043 00045 csRef<iCamera> Camera; 00046 00048 csBox2* RectView; 00050 csPoly2D* PolyView; 00052 csRef<iClipper2D> Clipper; 00053 00055 void UpdateView (); 00056 00058 bool AutoResize; 00059 00060 public: 00062 csView (iEngine *iEngine, iGraphics3D* ig3d); 00064 virtual ~csView (); 00065 00067 virtual iEngine* GetEngine (); 00069 virtual void SetEngine (iEngine* e); 00070 00072 virtual iCamera* GetCamera (); 00074 virtual void SetCamera (iCamera* c); 00075 00077 virtual iGraphics3D* GetContext (); 00079 virtual void SetContext (iGraphics3D *ig3d); 00080 00082 virtual void SetRectangle (int x, int y, int w, int h); 00084 virtual void ClearView (); 00086 virtual void AddViewVertex (int x, int y); 00088 virtual void RestrictClipperToScreen (); 00089 00091 virtual void SetAutoResize (bool state) { AutoResize = state; } 00092 00094 virtual void UpdateClipper(); 00096 virtual iClipper2D* GetClipper (); 00098 virtual void Draw (); 00099 00100 SCF_DECLARE_IBASE; 00101 }; 00102 00103 #endif // __CS_CSVIEW_H__
Generated for Crystal Space by doxygen 1.3.9.1