WXP C++ Library Version 6.74.6
Loading...
Searching...
No Matches
Public Types | Public Member Functions | Static Public Member Functions | List of all members
WXP::SatFile Class Reference

This class reads satellite imagery from file. More...

#include "../include/SatFile.h"

Public Types

enum  Type {
  UNK , RAW , IMG , IMGZ ,
  GINI , GINIZ , GINIP , NETCDF ,
  UNISYS , AREA , TIFF , LRIT ,
  GIF , PNG
}
 

Public Member Functions

 SatFile ()
 
 SatFile (const char *filename, int raccess, int rtype)
 
 SatFile (const char *filename, int raccess, const char *rtype)
 
 SatFile (Filename &filename, int raccess)
 
 ~SatFile ()
 
int init ()
 
int open (const char *filename, int raccess, int rtype)
 
int open (const char *filename, int raccess, const char *rtype)
 
int open (Filename &filename, int raccess)
 
bool isOpen ()
 
int rewind ()
 
int close ()
 
int getHeader (Image &data)
 
int read (Image &data)
 
int read (const char *filename, int type, Image &image)
 
int read (const char *filename, const char *type, Image &image)
 
int read (Filename &filename, Image &image)
 
int write (Image &data)
 
int write (const char *filename, int type, Image &image)
 
int setMapRemove (int val)
 
int setDomain (const char *str)
 
int setCalibration (const char *str)
 

Static Public Member Functions

static int getType (const char *str)
 
static int checkType (const char *filename)
 

Detailed Description

This class reads satellite imagery from file.

Author
Dan Vietor

Constructor & Destructor Documentation

◆ SatFile() [1/4]

SatFile::SatFile ( )

Constructor. Initializes the class

References init().

◆ SatFile() [2/4]

SatFile::SatFile ( const char *  filename,
int  access,
int  type 
)

Constructor. Opens the satellite file

Parameters
filenameFile to open
accessAccess (FileAttr::READ, FileAttr::WRITE)
typeFile type (IMG, IMGZ, GINI, GINIZ, AREA, UNISYS, TIFF, LRIT)

References init(), and open().

◆ SatFile() [3/4]

SatFile::SatFile ( const char *  filename,
int  access,
const char *  type 
)

Constructor. Opens the satellite file

Parameters
filenameFile to open
accessAccess (FileAttr::READ, FileAttr::WRITE)
typeFile type (img, imgz, gini, giniz, area, unisys, tiff, lrit)

References init(), and open().

◆ SatFile() [4/4]

SatFile::SatFile ( Filename filename,
int  access 
)

Constructor. Opens the satellite file

Parameters
filenameFile to open
accessAccess (FileAttr::READ, FileAttr::WRITE)
typeFile type (img, imgz, gini, giniz, area, unisys, tiff, lrit)

References WXP::Filename::getName(), WXP::Filename::getType(), init(), and open().

◆ ~SatFile()

SatFile::~SatFile ( )

Destructor

References close().

Member Function Documentation

◆ checkType()

int SatFile::checkType ( const char *  filename)
static

Check the type of data in the file

Parameters
filenameFile to check

References WXP::StrLib::equal(), WXP::File::isOpen(), and WXP::File::scanf().

Referenced by open().

◆ close()

int SatFile::close ( )

Closes the file

References WXP::File::close().

Referenced by ~SatFile().

◆ getHeader()

int SatFile::getHeader ( Image image)

◆ init()

int SatFile::init ( )

Initializes the class data

References WXP::Const::MISS.

Referenced by SatFile().

◆ isOpen()

bool SatFile::isOpen ( )

Is file open

Returns
True if open

Referenced by WXP::SatPlot::draw(), and WXP::SatPlot::getDomain().

◆ open() [1/2]

int SatFile::open ( const char *  filename,
int  access,
const char *  rtype 
)

Opens a satellite image file

Parameters
filenameFile to open
accessAccess (File::READ, File::WRITE)
rtypeFile type (unk, img, imgz, gini, giniz, area, unisys)

References open().

◆ open() [2/2]

int SatFile::open ( const char *  filename,
int  access,
int  rtype 
)

◆ read()

int SatFile::read ( Image image)

◆ rewind()

int SatFile::rewind ( )

Rewinds the file

References WXP::File::rewind(), and WXP::File::skipLine().

◆ setCalibration()

int SatFile::setCalibration ( const char *  str)

Sets the calibration factor

Parameters
strThe calibration

Referenced by WXP::SatPlot::draw().

◆ setDomain()

int SatFile::setDomain ( const char *  str)

Sets the domain of the image for navigation

Parameters
strThe domain of the image

Referenced by WXP::SatPlot::draw().

◆ setMapRemove()

int SatFile::setMapRemove ( int  val)

Enables map removal algorithm

Parameters
strTurns on map removal

Referenced by WXP::SatPlot::draw().


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