CrystalSpace

Public API Reference

Main Page   Modules   Class Hierarchy   Alphabetical List   Compound List   File List   Compound Members   File Members   Related Pages  

imesh/bcterr.h

00001 /*
00002     Copyright (C) 2002 by Jorrit Tyberghein and Ryan Surkamp
00003 
00004     This library is free software; you can redistribute it and/or
00005     modify it under the terms of the GNU Library General Public
00006     License as published by the Free Software Foundation; either
00007     version 2 of the License, or (at your option) any later version.
00008 
00009     This library is distributed in the hope that it will be useful,
00010     but WITHOUT ANY WARRANTY; without even the implied warranty of
00011     MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00012     Library General Public License for more details.
00013 
00014     You should have received a copy of the GNU Library General Public
00015     License along with this library; if not, write to the Free
00016     Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
00017 */
00018 
00019 #ifndef __CS_IMESH_BCTERR_H__
00020 #define __CS_IMESH_BCTERR_H__
00021 
00022 #include "csutil/scf.h"
00023 
00024 struct iEngine;
00025 struct iImage;
00026 struct iMaterialWrapper;
00027 struct iMaterialList;
00028 struct iLoaderContext;
00029 class csVector3;
00030 class csVector2;
00031 class csColor;
00032 class csTransform;
00033 class csSharedLODMesh;
00034 class csBCTerrBlock;
00035 class csBox3;
00036 
00037 
00038 
00039 SCF_VERSION (iBCTerrState, 0, 0, 3);
00040 
00044 struct iBCTerrState : public iBase
00045 {
00047   virtual void SetSize (int x, int z) = 0;
00049   virtual void SetTopLeftCorner (const csVector3& topleft) = 0;
00051   virtual void SetBlockMaterial (int x_block, int z_block,
00052         iMaterialWrapper* mat) = 0;
00054   virtual void SetHeightMap (iImage* im) = 0;
00056   virtual int HeightTest (csVector3 *point) = 0;
00058   virtual void SetBlockMaterialNum (int num, iMaterialWrapper* mat) = 0;
00060   virtual int CameraHeightTest (csVector3 *point) = 0;
00062   virtual void SetControlPoint (const csVector3 point, const int iter) = 0;
00064   virtual void SetControlPoint (const csVector3 point, const int x,
00065         const int z) = 0;
00067   virtual void SetControlPointHeight (const float height, const int iter) = 0;
00069   virtual void SetControlPointHeight (const float height, const int x,
00070         const int z) = 0;
00072   virtual void SetFlattenHeight (const float up, const float down,
00073         const float left, const float right) = 0;
00078   virtual void DoFlatten (const bool up, const bool down,
00079         const bool left, const bool right) = 0;
00081   virtual void SetSystemInc (const int inc) = 0;
00086   virtual void PreBuild () = 0;
00088   virtual void Build () = 0;
00090   virtual int GetControlLength () = 0;
00093   virtual bool GetControlPoint (int iter, csVector3 &point) = 0;
00094 };
00095 
00096 SCF_VERSION (iBCTerrFactoryState, 0, 0, 3);
00097 
00101 struct iBCTerrFactoryState : public iBase
00102 {
00104   virtual void SetMaxEdgeResolution (int res) = 0;
00105   virtual int GetMaxEdgeResolution () = 0;
00107   virtual void SetBlockSize (float x, float z) = 0;
00108 
00110   virtual void AddLOD (float distance, int increments) = 0;
00112   virtual void SetLODDistance (int lod_level, float distance) = 0;
00114   virtual void SetMultiplier (float m ) = 0;
00116   virtual csSharedLODMesh* GetSharedMesh (int level, csBCTerrBlock *owner) = 0;
00117   virtual void FreeShared (csBCTerrBlock *owner, int level ) = 0;
00119   virtual void AddTime (csTicks time) = 0;
00120   virtual csVector2* GetSize () = 0;
00121   virtual float GetMultiplier () = 0;
00123   virtual csSharedLODMesh* CreateFreeMesh (bool wavy) = 0;
00124   virtual void SetFocusPoint (const csVector3 focus) = 0;
00125   virtual csVector2* GetLODUV (int lod_level) = 0;
00126   virtual float* GetLODDistances () = 0;
00127   virtual void SetDefaultMaterial ( iMaterialWrapper* mat ) = 0;
00128   virtual iMaterialWrapper* GetDefaultMaterial () = 0;
00130   virtual int GetUserLOD () = 0;
00131   virtual void GetSystemDistance (float &start, float &dist) = 0;
00133   virtual void SetSystemDistance (float start, float new_dist) = 0;
00134 };
00135 
00136 #endif // __CS_IMESH_BCTERR_H__
00137 

Generated for Crystal Space by doxygen 1.2.18