MSUProj-Dev  0.6-20
Public Types | Public Member Functions | List of all members
msumr::MSUProj Class Reference

The class for reprojecting geo data of the sensing equipment MSU-MR of the ERS satellite Meteor-M. More...

#include <msuproj.h>

Public Types

enum  VERSION_TYPE { VERSION_STRING, VERSION_DATE, VERSION_ARCH }
 The enumiration for getVersion() method. More...
 

Public Member Functions

 MSUProj ()
 A constructor.
 
 ~MSUProj ()
 A destructor.
 
const char * getVersion (VERSION_TYPE type=VERSION_STRING) const
 A method of getting version of MSUProj. More...
 
void setDst (std::string file)
 Amethod of setting a destination file name. More...
 
void setDstFormat (std::string format)
 A method of setting a destination file format. More...
 
const RETURN_CODE setSrc (std::string file)
 A method of setting a source raster file. More...
 
const RETURN_CODE readGCP (std::string file)
 A method of setting a GCP file. More...
 
void setPerimSize (const unsigned int &perim)
 A method of setting a maximum size of the pixel values interpolation block side. More...
 
const std::string getUTM () const
 A method of getting an UTM zone string. More...
 
const RETURN_CODE warp (const bool &useUTM=false, const bool &zerosAsND=false)
 A method of projecting of a MSU-MR frame. More...
 
unsigned int getSrcXSize () const
 A source image X size getter method. More...
 
unsigned int getSrcYSize () const
 A source image Y size getter method. More...
 
unsigned int getGCPXSize () const
 A GCP grid X size getter method. More...
 
unsigned int getGCPYSize () const
 A GCP grid Y size getter method. More...
 
unsigned int getGCPXStep () const
 A GCP grid X step getter method. More...
 
unsigned int getGCPYStep () const
 A GCP grid Y step getter method. More...
 
bool ifAddLogo () const
 Check if add logotype option is enabled. More...
 
void setAddLogo (bool enabled)
 Set add logotype option state. More...
 

Detailed Description

The class for reprojecting geo data of the sensing equipment MSU-MR of the ERS satellite Meteor-M.

Uses GDAL (http://www.gdal.org/) to operate with rasters and SGP4 C++ library (https://www.danrw.com/public/sgp4/) to calculate geogrids.

Member Enumeration Documentation

The enumiration for getVersion() method.

Enumerator
VERSION_STRING 

Return a version string.

VERSION_DATE 

Return a version date.

VERSION_ARCH 

Return a version architecture.

Member Function Documentation

unsigned int msumr::MSUProj::getGCPXSize ( ) const

A GCP grid X size getter method.

Returns
A number of points in a line of a GCP grid
unsigned int msumr::MSUProj::getGCPXStep ( ) const

A GCP grid X step getter method.

Returns
A X step size of a GCP grid
unsigned int msumr::MSUProj::getGCPYSize ( ) const

A GCP grid Y size getter method.

Returns
A number of lines of a GCP grid
unsigned int msumr::MSUProj::getGCPYStep ( ) const

A GCP grid Y step getter method.

Returns
A Y step size of a GCP grid
unsigned int msumr::MSUProj::getSrcXSize ( ) const

A source image X size getter method.

Returns
A number of pixels in a line of a source image
unsigned int msumr::MSUProj::getSrcYSize ( ) const

A source image Y size getter method.

Returns
A number of lines of a source image
const std::string msumr::MSUProj::getUTM ( ) const

A method of getting an UTM zone string.

Returns
A UTM zone string in format <hemisphere><zone number>. For example 'N38'.
const char * msumr::MSUProj::getVersion ( VERSION_TYPE  type = VERSION_STRING) const

A method of getting version of MSUProj.

Parameters
type- a type of a returning value:
  • 0 - Get version number
  • 1 - Get build date
  • 2 - Get build architecture
Returns
Version value
bool msumr::MSUProj::ifAddLogo ( ) const

Check if add logotype option is enabled.

Returns
Option state
const msumr::RETURN_CODE msumr::MSUProj::readGCP ( std::string  file)

A method of setting a GCP file.

Parameters
fileA GCP file name
Returns
Exit code MSUMR::RETURN_CODE:
  • success - Successful reading of a GCP file
  • errGCP - Error of reading of a GCP file
void msumr::MSUProj::setAddLogo ( bool  enabled)

Set add logotype option state.

Parameters
enabledOption state
void msumr::MSUProj::setDst ( std::string  file)

Amethod of setting a destination file name.

Parameters
fileA destination file name
void msumr::MSUProj::setDstFormat ( std::string  format)

A method of setting a destination file format.

Parameters
formatA destination file format

Select one of GDAL raster formats (http://www.gdal.org/formats_list.html) that supports creation. Default is 'GeoTiff'.

void msumr::MSUProj::setPerimSize ( const unsigned int &  perim)

A method of setting a maximum size of the pixel values interpolation block side.

When warping we try to calculate the average pixel value from a block of near pixels. By default the maximal block size is 9x9.

Set a less size to increase the warping speed. Too small values will cause graininess and black areas. Too big will blur image.

Parameters
perimA block side size in pixels
const msumr::RETURN_CODE msumr::MSUProj::setSrc ( std::string  file)

A method of setting a source raster file.

Parameters
fileA source file name
Returns
Exit code MSUMR::RETURN_CODE:
  • success - Successful reading of a source file
  • errSRC - Error of reading of a source file
const msumr::RETURN_CODE msumr::MSUProj::warp ( const bool &  useUTM = false,
const bool &  zerosAsND = false 
)

A method of projecting of a MSU-MR frame.

Returns
Exit code MSUMR::RETURN_CODE:
  • success - Successful projection
  • errDST - Error of creation of a destination raster
  • errSRC - A source image is not set
  • errGCP - A source GCP grid is not set

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