OSSIM - Open Source Software Image Map  Version 1.9.0 (20180803)
ossimNBandToIndexFilter.h
Go to the documentation of this file.
1 //*******************************************************************
2 // Copyright (C) 2005 Garrett Potts
3 //
4 // License: MIT
5 //
6 // See LICENSE.txt file in the top level directory for more details.
7 //
8 // Author: Garrett Potts
9 //
10 //*************************************************************************
11 // $Id: ossimNBandToIndexFilter.h 15766 2009-10-20 12:37:09Z gpotts $
12 #ifndef ossimNBandToIndexFilter_HEADER
13 #define ossimNBandToIndexFilter_HEADER
17 #include <vector>
18 
19 class ossimImageData;
20 
44 {
45 public:
50 
51  virtual ossimRefPtr<ossimImageData> getTile(const ossimIrect& origin,
52  ossim_uint32 resLevel=0);
53 
54  virtual ossim_uint32 getNumberOfOutputBands() const;
55 
56  virtual ossimScalarType getOutputScalarType() const;
57 
58  void setLut(ossimNBandLutDataObject& lut);
59 
60  void setLut(const ossimFilename& file);
61 
62  virtual bool isSourceEnabled()const;
63  virtual void disableSource();
64 
65  virtual double getNullPixelValue(ossim_uint32 band=0)const;
66 
67  virtual double getMinPixelValue(ossim_uint32 band=0)const;
68 
69  virtual double getMaxPixelValue(ossim_uint32 band=0)const;
70 
71  virtual void initialize();
72 
76  virtual bool saveState(ossimKeywordlist& kwl, const char* prefix=0)const;
77 
81  virtual bool loadState(const ossimKeywordlist& kwl, const char* prefix=0);
82 
89  virtual void setProperty(ossimRefPtr<ossimProperty> property);
90 
97  virtual ossimRefPtr<ossimProperty> getProperty(const ossimString& name)const;
98 
104  virtual void getPropertyNames(std::vector<ossimString>& propertyNames)const;
105 
106 protected:
107  virtual ~ossimNBandToIndexFilter();
108  void allocate();
109 
110 
111  virtual ossimRefPtr<ossimImageData> convertInputTile(ossimImageData* inputTile);
112 
113  template <class T> ossimRefPtr<ossimImageData> convertOutputTileTemplate(T inputDummy,
114  ossimImageData* inputTile);
115  template <class T1, class T2> ossimRefPtr<ossimImageData> convertInputTileToOutputTemplate(T1 inputDummy,
116  T2 outputDummy,
117  ossimImageData* inputTile);
118 
123  std::vector<ossimNBandLutDataObject::LUT_ENTRY_TYPE> theMinValues;
124  std::vector<ossimNBandLutDataObject::LUT_ENTRY_TYPE> theMaxValues;
125  std::vector<ossimNBandLutDataObject::LUT_ENTRY_TYPE> theNullValues;
126 TYPE_DATA
127 };
128 
129 #endif
virtual bool isSourceEnabled() const
Definition: ossimSource.cpp:79
ossimRefPtr< ossimNBandLutDataObject > theLut
virtual void setProperty(ossimRefPtr< ossimProperty > property)
Represents serializable keyword/value map.
virtual ossim_uint32 getNumberOfOutputBands() const
Returns the number of bands in a tile returned from this TileSource.
virtual void disableSource()
Definition: ossimSource.cpp:89
virtual double getMinPixelValue(ossim_uint32 band=0) const
Returns the min pixel of the band.
virtual void getPropertyNames(std::vector< ossimString > &propertyNames) const
#define TYPE_DATA
Definition: ossimRtti.h:339
std::vector< ossimNBandLutDataObject::LUT_ENTRY_TYPE > theMinValues
unsigned int ossim_uint32
virtual bool loadState(const ossimKeywordlist &kwl, const char *prefix=0)
Method to the load (recreate) the state of an object from a keyword list.
ossimScalarType
ossimRefPtr< ossimImageData > theTile
std::vector< ossimNBandLutDataObject::LUT_ENTRY_TYPE > theNullValues
virtual ossimScalarType getOutputScalarType() const
This will be used to query the output pixel type of the tile source.
virtual bool saveState(ossimKeywordlist &kwl, const char *prefix=0) const
Method to save the state of an object to a keyword list.
virtual double getMaxPixelValue(ossim_uint32 band=0) const
Returns the max pixel of the band.
#define OSSIM_DLL
virtual ossimRefPtr< ossimProperty > getProperty(const ossimString &name) const
class ossimNBandLutDataObject
std::vector< ossimNBandLutDataObject::LUT_ENTRY_TYPE > theMaxValues
virtual double getNullPixelValue(ossim_uint32 band=0) const
Each band has a null pixel associated with it.
virtual ossimRefPtr< ossimImageData > getTile(const ossimIpt &origin, ossim_uint32 resLevel=0)