Public Member Functions | List of all members
AccumulatorGeo Class Reference
Inheritance diagram for AccumulatorGeo:
Inheritance graph
[legend]
Collaboration diagram for AccumulatorGeo:
Collaboration graph
[legend]

Public Member Functions

virtual void setGeometry (unsigned int width, unsigned int height)
 
virtual void allocate ()
 This should be called after setGeometry, unless the projection is used as a frame.
 
void reset ()
 
void addUnprojected (double lon, double lat, double value, double weight)
 
virtual std::ostream & toStream (std::ostream &ostr) const
 
- Public Member Functions inherited from Accumulator
 Accumulator ()
 
 Accumulator (const Accumulator &acc)
 
void setMethod (const std::string &method)
 Set method to some of the predefined methods.
 
void setMethod (const std::string &name, const std::string &params)
 Set method to some of the predefined methods.
 
void setMethod (const AccumulationMethod &method)
 Copies the method and its parameters. More...
 
bool isMethodSet () const
 
const AccumulationMethodgetMethod () const
 
AccumulationMethodgetMethod ()
 
void add (const size_t i, double value, double weight)
 Adds decoded data that applies natural scaling.
 
void add (const size_t i, double value, double weight, unsigned int count)
 Adds decoded data that applies natural scaling.
 
void addData (const Image &src, const AccumulationConverter &converter, double weight=1.0, int iOffset=0, int jOffset=0)
 Add (accumulate) data with given prior weight. More...
 
void addData (const Image &src, const Image &srcQuality, const AccumulationConverter &converter, double weight=1.0, int iOffset=0, int jOffset=0)
 Add (accumulate) data weighted with input quality. More...
 
void addData (const Image &src, const Image &srcQuality, const Image &srcCount, const AccumulationConverter &converter)
 Add (accumulate) data weighted with input quality and count; each data(i,j) contributes count(i,j) times. More...
 
void extractField (char field, const AccumulationConverter &converter, Image &dst, const drain::Rectangle< int > &crop) const
 Extracts the accumulated quantity or secondary quantities like weight and standard deviation. More...
 
- Public Member Functions inherited from GeoFrame
 GeoFrame (unsigned int width=0, unsigned int height=0)
 Default constructor.
 
void reset ()
 
bool projectionIsSet () const
 Returns true, if the geographical extent has been set.
 
bool geometryIsSet () const
 Return true, if array area is greater than zero.
 
bool bboxIsSet () const
 Returns true, if the bounding box (geographical extent) has been set. More...
 
bool isDefined () const
 Returns true, if the projection, array area and geographical extent bounding box has been set. More...
 
int getFrameWidth () const
 Return the nominal width, not the width of the memory array which does not have to be allocated.
 
int getFrameHeight () const
 Return the nominal height, not the height of the memory array which does not have to be allocated.
 
void setBoundingBox (double lonLL, double latLL, double lonUR, double latUR)
 Sets bounding box in degrees OR in metres in the target coordinate system. More...
 
void setBoundingBox (const drain::Rectangle< double > &bbox)
 Sets bounding box in degrees in the target coordinate system.
 
void setBoundingBoxD (double lonLL, double latLL, double lonUR, double latUR)
 Sets bounding box in degrees in the target coordinate system.
 
void setBoundingBoxD (const drain::Rectangle< double > &bboxD)
 Sets bounding box in degrees in the target coordinate system.
 
void setBoundingBoxR (double lonLL, double latLL, double lonUR, double latUR)
 Sets bounding box in radians in the target coordinate system.
 
void setBoundingBoxR (const drain::Rectangle< double > &bboxR)
 Sets bounding box in radians in the target coordinate system.
 
void setBoundingBoxM (double xLL, double yLL, double xUR, double yUR)
 Sets bounding box in meters in the target coordinate system. More...
 
void setBoundingBoxM (const drain::UniTuple< double, 4 > &bboxM)
 Sets bounding box in meters in the target coordinate system.
 
const drain::Rectangle< double > & getBoundingBoxDeg () const
 Returns the geographical scope in Degrees.
 
const drain::Rectangle< double > & getBoundingBoxNat () const
 Returns the geographical scope in Meters.
 
const drain::Rectangle< double > & getBoundingBoxRad () const
 Returns the geographical scope in Radians.
 
void getCenterPixel (drain::Rectangle< double > &pixelD) const
 
double getXScale () const
 Return horizontal resolution of a pixel in meters (if metric) or degrees (if unprojected, "latlon").
 
double getYScale () const
 Return vertical resolution of a pixel in meters (if metric) or degrees (if unprojected, "latlon").
 
void cropWithM (drain::Rectangle< double > &bboxM)
 Crops the initial bounding box with a given bounding box.
 
void cropWithM (double xLL, double yLL, double xUR, double yUR)
 Crops the initial bounding box with a given bounding box. More...
 
virtual void deg2pix (double lon, double lat, int &i, int &j) const
 Projects geographic coordinates to image coordinates.
 
void deg2pix (const drain::Point2D< double > &loc, drain::Point2D< int > &pix) const
 Project geographic coordinates to image coordinates.
 
virtual void deg2m (double lon, double lat, double &x, double &y) const
 Convert metric coordinates to degrees.
 
void deg2m (const drain::Point2D< double > &pDeg, drain::Point2D< double > &pMet) const
 
virtual void pix2deg (int i, int j, double &lon, double &lat) const
 Calculates the geographic coordinates of the center of a pixel at (i,j).
 
virtual void pix2rad (int i, int j, double &lon, double &lat) const
 Calculates the geographic coordinates [rad] of the center of a pixel at (i,j).
 
void pix2deg (const drain::Point2D< int > &pix, drain::Point2D< double > &loc) const
 Calculates the geographic coordinates of the center of a pixel at (i,j).
 
virtual void pix2LLdeg (int i, int j, double &lon, double &lat) const
 Calculates the geographic coordinates of the lower left corner of a pixel at (i,j).
 
virtual void m2deg (double x, double y, double &lon, double &lat) const
 Convert metric coordinates to degrees.
 
virtual void m2deg (const drain::Point2D< double > &pMetric, drain::Point2D< double > &pDeg) const
 Convert metric coordinates to degrees.
 
virtual void m2pix (double x, double y, int &i, int &j) const
 Scales geographic map coordinates to image coordinates. More...
 
virtual void m2pix (const drain::Point2D< double > &pMetric, drain::Point2D< int > &pImage) const
 
virtual void pix2m (int i, int j, double &x, double &y) const
 Scales image coordinates (i,j) to geographic map coordinates (x,y) in the pixel centres. More...
 
virtual void pix2m (const drain::Point2D< int > &pImage, drain::Point2D< double > &pMetric) const
 
virtual void pix2LLm (int i, int j, double &x, double &y) const
 Scales image coordinates (i,j) to geographic map coordinates (x,y) of the lower left corner pixel. More...
 
void setProjection (const std::string &projDef)
 Sets the projection of the image as a Proj string.
 
void setProjectionEPSG (int epsg)
 Sets the projection of the image as a EPSG code.
 
void updateProjection ()
 Updates bboxex, if needed.
 
const std::string & getProjection () const
 Returns the projection of the composite image as a proj4 std::string.
 
const std::string & getCoordinateSystem () const
 Returns the source projection (should be radian array, lon & lat).
 
const drain::Rectangle< double > & getDataBBoxNat () const
 Return the actual geographical boundingBox suggested by implied by input data.
 
const drain::Rectangle< double > & getDataOverlapBBoxNat () const
 Return the common overlapping geographical area (intersection) implied by input data.
 
void updateDataExtentDeg (const drain::Rectangle< double > &inputBBoxDeg)
 Extend to include this input. More...
 
void updateDataExtentNat (const drain::Rectangle< double > &inputBBoxNat)
 
bool isLongLat () const
 

Additional Inherited Members

- Public Attributes inherited from Accumulator
AccumulationArray accArray
 Todo: export.
 
- Public Attributes inherited from GeoFrame
drain::Proj6 projGeo2Native
 Radial to metric.
 
- Protected Member Functions inherited from Accumulator
void initDst (const AccumulationConverter &coder, Image &dst, drain::Rectangle< int > &cropArea) const
 
- Protected Member Functions inherited from GeoFrame
void updateBoundingBoxR ()
 Proj 6 NEW: Given BBox in geo coords [deg], adjust geo coords [rad]. More...
 
void updateBoundingBoxD ()
 Given BBox in geo coords [rad], adjust geo coords [deg]. More...
 
void updateBoundingBoxM ()
 Given BBox in geo coords [rad], adjust metric bounding box. Do not update xScale or yScale.
 
void updateScaling ()
 Geometric scaling. More...
 
- Protected Attributes inherited from Accumulator
AccumulationMethod undefinedMethod
 A Some predefined methods, that can be set with setMethod(const std::string & key).
 
AccumulationMethodmethodPtr
 
- Protected Attributes inherited from GeoFrame
int frameWidth
 
int frameHeight
 
drain::Rectangle< double > bBoxR
 Geographical scope in Radians.
 
drain::Rectangle< double > bBoxD
 Geographical scope in Degrees.
 
drain::Rectangle< double > bBoxNative
 Geographical scope in meters, or degrees in case of long/lat.
 
drain::Rectangle< double > dataBBoxNat
 For deriving extent (~union) of input data.
 
drain::Rectangle< double > dataOverlapBBoxNat
 For deriving common extent (~intersection) of input data.
 
double xScale = 0.0
 Utility for deriving extent (degrees) required by input data. More...
 
double yScale = 0.0
 

The documentation for this class was generated from the following files: