00001
00002
00003
00004
00005
00006
00007
00008
00009 #ifndef PLANETMAP_H
00010 #define PLANETMAP_H
00011
00012 class cPlanetmap;
00013
00014 #include "cObject.h"
00015
00019 class cPlanetmap : public cObject {
00020 public:
00022 static int sInstances;
00024 static std::vector<long> sTextures;
00025 public:
00027 struct sPatch {
00028
00029 unsigned long touches;
00030
00031 unsigned long key;
00032
00033 float heightcolor[1024*1024*4];
00034 };
00036 std::map<unsigned long,sPatch*> patches;
00037 public:
00038 cPlanetmap();
00040 virtual float constrainParticle(float* worldpos, float radius, float* localpos, cObject* enactor);
00042 inline float getHeight(float x, float z, float* color3f);
00044 inline float getCachedHeight(float x, float z, float* color3f);
00046 virtual void drawSolid();
00048 virtual void drawEffect();
00049 };
00050
00051 #endif
00052