openModeller  Version 1.4.0
TerralibRaster.hh
Go to the documentation of this file.
00001 
00031 #ifndef _TE_RASTERHH_
00032 #define _TE_RASTERHH_
00033 
00034 #include <openmodeller/env_io/Raster.hh>
00035 
00036 class TeRaster;
00037 class TeDatabase;
00038 class TeLayer;
00039 class TeRasterParams;
00040 class TeStringParser;
00041 
00042 #include <string>
00043 using std::string;
00044 
00045 class MapFormat;
00046 
00048 
00051 class dllexp TerralibRaster: public Raster
00052 {
00053 public:
00055 
00058   static Raster* CreateRasterCallback();
00059   
00061 
00064   TerralibRaster(): db_(0), raster_(0), layer_(0), params_(0), te_str_parser_(0) {};
00065 
00067 
00073   void createRaster( const std::string& str, int categ = 0 );
00074 
00076 
00082   void createRaster( const std::string& str, const MapFormat& format );
00083 
00087   ~TerralibRaster();
00088 
00090 
00093   int get( Coord x, Coord y, Scalar *val );
00094 
00096 
00100   int put( Coord x, Coord y, Scalar val );
00101   
00103 
00107   int put( Coord x, Coord y );
00108 
00114   int getMinMax( Scalar *min, Scalar *max );
00115 
00119   int deleteRaster();
00120   
00121 private:
00125 
00126   TeDatabase *db_;
00127   TeRaster *raster_;
00128   TeRasterParams* params_; 
00129   TeLayer *layer_;
00130 
00132   TeStringParser *te_str_parser_;
00133 
00135   void openTeRaster();
00136 
00138   void createTeRaster();
00139 };
00140 
00141 #endif