SPATMOD::IMAGE::BASE Class Reference

Base class for image. More...

#include <spatmod/imagebase.h>

Inheritance diagram for SPATMOD::IMAGE::BASE:

Inheritance graph
base refererrect $classSPATMOD_1_1IMAGE_1_1STAGE.html 213,86 395,105rect $classSPATMOD_1_1IMAGE_1_1TARGET.html 440,86 629,105rect $classSPATMOD_1_1IMAGE_1_1FILTER.html 7,156 185,174rect $classSPATMOD_1_1IMAGE_1_1SOURCE.html 209,156 399,174rect $classSPATMOD_1_1IMAGE_1_1TARGET__FILE.html 423,156 647,174rect $classSPATMOD_1_1IMAGE_1_1TARGET__RVC.html 671,156 897,174
[legend]
List of all members.

Public Types

enum  CAPABILITY { CAPABILITY_Pull, CAPABILITY_Push }
enum  ZOOMABILITY { ZOOMABILITY_Only1X, ZOOMABILITY_List, ZOOMABILITY_Range }

Public Member Functions

 BASE ()
INT32 ComputeTileColumn (double x, double zoom=1) const
INT32 ComputeTileRow (double y, double zoom=1) const
const GEOREFERENCEGetGeoreference () const
INT32 GetNumColumnsOfTiles (double zoom=1) const
double GetNumColumnsPerTile (TILEPOSITION tileposition, double zoom=1) const
INT32 GetNumRowsOfTiles (double zoom=1) const
double GetNumRowsPerTile (TILEPOSITION tileposition, double zoom=1) const
UINT16 GetNumSamples () const
const PIXELTABLEGetPixelLookupTable () const
const PIXELGetPixelProperties () const
RANGETYPE GetPixelRangeType () const
PIXEL::TYPE GetPixelType () const
const PIXELGetPixelValueMax () const
const PIXELGetPixelValueMin () const
double GetTotalColumns (double zoom) const
UINT32 GetTotalColumns () const
double GetTotalRows (double zoom) const
UINT32 GetTotalRows () const
ZOOMABILITY GetZoomAbility (SIMPLE_ARRAY< double > &ZoomsAllowed) const
bool QueryCapability (CAPABILITY capability) const
float QueryStepOrder (STEPORDER steporder, double zoom=1) const
bool QueryZoom (double zoom) const
virtual ~BASE ()

Protected Member Functions

void SetAllDimensions (const BASE &image)
void SetAllProperties (const BASE &image)
void SetGeoreference (const GEOREFERENCE *pGeoreference)
void SetPixelLookupTable (const PIXELTABLE *pPixelTable)
void SetPixelProperties (const BASE &image)
void SetPixelProperties (const PIXEL &PixelProperties)
ERRVALUE SetPixelRange (const PIXEL &PixelValueMin, const PIXEL &PixelValueMax, RANGETYPE RangeType)
void SetPixelRangeDefault ()
ERRVALUE SetTileDimensions (double ColumnsPerTile, double RowsPerTile, double ColumnsPerTileFirst=0, double RowsPerTileFirst=0, double ColumnsPerTileLast=0, double RowsPerTileLast=0)
ERRVALUE SetTotalDimensions (UINT32 TotalColumns, UINT32 TotalRows)
virtual const GEOREFERENCEv_GetGeoreference () const
virtual INT32 v_GetNumColumnsOfTiles (double zoom) const
virtual double v_GetNumColumnsPerTile (TILEPOSITION tileposition, double zoom) const
virtual INT32 v_GetNumRowsOfTiles (double zoom) const
virtual double v_GetNumRowsPerTile (TILEPOSITION tileposition, double zoom) const
virtual const PIXELTABLEv_GetPixelLookupTable () const
virtual double v_GetTotalColumns (double zoom) const
virtual double v_GetTotalRows (double zoom) const
virtual bool v_QueryCapability (CAPABILITY capability) const
virtual float v_QueryStepOrder (STEPORDER steporder, double zoom) const

Protected Attributes

PIXELTABLEm_pPixelLookupTable

Private Member Functions

virtual ZOOMABILITY v_GetZoomAbility (SIMPLE_ARRAY< double > &ZoomsAllowed) const

Detailed Description

Base class for image.

Contains image properties, provides no methods for reading/writing actual image data.

Definition at line 65 of file imagebase.h.


Member Enumeration Documentation

enum SPATMOD::IMAGE::BASE::CAPABILITY

Enumeration of basic image capabilities.

Enumerator:
CAPABILITY_Pull  Can "pull" from image.
CAPABILITY_Push  Can "push" to image.

Definition at line 69 of file imagebase.h.

enum SPATMOD::IMAGE::BASE::ZOOMABILITY

Enumeration of supported zoom abilities.

Enumerator:
ZOOMABILITY_Only1X  Can only access with zoom = 1.
ZOOMABILITY_List  Supports specific set of zoom values.
ZOOMABILITY_Range  Supports any zoom in range.

Definition at line 75 of file imagebase.h.


Constructor & Destructor Documentation

SPATMOD::IMAGE::BASE::BASE (  ) 

Constructor.

virtual SPATMOD::IMAGE::BASE::~BASE (  )  [virtual]

Destructor.


Member Function Documentation

INT32 SPATMOD::IMAGE::BASE::ComputeTileColumn ( double  x,
double  zoom = 1 
) const

Compute tile column for specified image coordinate.

Parameters:
x  Image coordinate at specified zoom value
zoom  Zoom/magnification factor

INT32 SPATMOD::IMAGE::BASE::ComputeTileRow ( double  y,
double  zoom = 1 
) const

Compute tile row for specified image coordinate.

Parameters:
y  Image coordinate at specified zoom value
zoom  Zoom/magnification factor

const GEOREFERENCE* SPATMOD::IMAGE::BASE::GetGeoreference (  )  const [inline]

Get georeference information.

Returns:
Pointer to georeference or NULL if none.

Definition at line 101 of file imagebase.h.

INT32 SPATMOD::IMAGE::BASE::GetNumColumnsOfTiles ( double  zoom = 1  )  const [inline]

Get number of columns of tiles "across" the image.

Returns:
Number of columns of tiles or error < 0 if specified zoom value not supported.
Parameters:
zoom  Zoom/magnification factor

Definition at line 106 of file imagebase.h.

double SPATMOD::IMAGE::BASE::GetNumColumnsPerTile ( TILEPOSITION  tileposition,
double  zoom = 1 
) const [inline]

Get number of columns per tile.

Note that first and last tiles may have different sizes than each other or interior tiles. If GetNumColumnsOfTiles is less than 3 then will return 0 for TILEPOSITION_Interior. If GetNumColumnsOfTiles is less than 2 then the "last" tile will have same dimension as "first" tile.

Returns:
Number of columns per tile or error < 0 if specified zoom value not supported.
Parameters:
tileposition  Tile position
zoom  Zoom/magnification factor

Definition at line 115 of file imagebase.h.

INT32 SPATMOD::IMAGE::BASE::GetNumRowsOfTiles ( double  zoom = 1  )  const [inline]

Get number of rows of tiles "down" the image.

Returns:
Number of rows of tiles or error < 0 if specified zoom value not supported.
Parameters:
zoom  Zoom/magnification factor

Definition at line 122 of file imagebase.h.

double SPATMOD::IMAGE::BASE::GetNumRowsPerTile ( TILEPOSITION  tileposition,
double  zoom = 1 
) const [inline]

Get number of rows per tile.

Note that first and last tiles may have different sizes than each other or interior tiles. If GetNumRowsOfTiles is less than 3 then will return 0 for TILEPOSITION_Interior. If GetNumRowsOfTiles is less than 2 then the "last" tile will have same dimension as "first" tile.

Returns:
Number of rows per tile or error < 0 if specified zoom value not supported.
Parameters:
tileposition  Tile position
zoom  Zoom/magnification factor

Definition at line 131 of file imagebase.h.

UINT16 SPATMOD::IMAGE::BASE::GetNumSamples (  )  const [inline]

Get number of samples per pixel.

Same as GetPixelProperties().GetNumSamples().

Definition at line 138 of file imagebase.h.

const PIXELTABLE* SPATMOD::IMAGE::BASE::GetPixelLookupTable (  )  const [inline]

Get pixel lookup table (for images with PIXEL::TYPE_Indexed).

Returns:
Pointer to lookup table or NULL if none.

Definition at line 143 of file imagebase.h.

const PIXEL& SPATMOD::IMAGE::BASE::GetPixelProperties (  )  const [inline]

Get image pixel properties.

Definition at line 147 of file imagebase.h.

RANGETYPE SPATMOD::IMAGE::BASE::GetPixelRangeType (  )  const [inline]

Get type of pixel range available.

Definition at line 151 of file imagebase.h.

PIXEL::TYPE SPATMOD::IMAGE::BASE::GetPixelType (  )  const [inline]

Get pixel type.

Same as GetPixelProperties().GetPixelType().

Definition at line 156 of file imagebase.h.

const PIXEL& SPATMOD::IMAGE::BASE::GetPixelValueMax (  )  const [inline]

Get maximum pixel value.

Use GetPixelRangeType() to determine if specific to image.

Definition at line 161 of file imagebase.h.

const PIXEL& SPATMOD::IMAGE::BASE::GetPixelValueMin (  )  const [inline]

Get minimum pixel value.

Use GetPixelRangeType() to determine if specific to image.

Definition at line 166 of file imagebase.h.

double SPATMOD::IMAGE::BASE::GetTotalColumns ( double  zoom  )  const [inline]

Get total number of columns in image at specified zoom/magnification.

Returns:
Total image columns or error < 0 if specified zoom value not supported.
Parameters:
zoom  Zoom/magnification factor

Definition at line 176 of file imagebase.h.

UINT32 SPATMOD::IMAGE::BASE::GetTotalColumns (  )  const [inline]

Get total number of columns in image.

Returns:
Total image columns.

Definition at line 171 of file imagebase.h.

double SPATMOD::IMAGE::BASE::GetTotalRows ( double  zoom  )  const [inline]

Get total number of rows in image at specified zoom/magnification.

Returns:
Total image rows or error < 0 if specified zoom value not supported.
Parameters:
zoom  Zoom/magnification factor

Definition at line 187 of file imagebase.h.

UINT32 SPATMOD::IMAGE::BASE::GetTotalRows (  )  const [inline]

Get total number of rows in image.

Returns:
Total image rows.

Definition at line 182 of file imagebase.h.

ZOOMABILITY SPATMOD::IMAGE::BASE::GetZoomAbility ( SIMPLE_ARRAY< double > &  ZoomsAllowed  )  const [inline]

Get zoom ability information.

The returned array will contain one or more values, the meaning of which depends on the ZOOMABILITY value returned. If ZOOMABILITY_Only1X, the returned array should be ignored and may be empty. If ZOOMABILITY_List, the returned array should contain a list of all supported zoom values (including 1.0). If ZOOMABILITY_Range, the returned array will contain exactly 2 values with the first being the minimum supported zoom and the last being the maximum. Returned values in the array should always be positive.

Parameters:
ZoomsAllowed  Zoom values allowed, interpretation depends on return value

Definition at line 198 of file imagebase.h.

bool SPATMOD::IMAGE::BASE::QueryCapability ( CAPABILITY  capability  )  const [inline]

Query image for specified capability.

Definition at line 203 of file imagebase.h.

float SPATMOD::IMAGE::BASE::QueryStepOrder ( STEPORDER  steporder,
double  zoom = 1 
) const

Query support/efficiency for specified stepping order.

Returns:
Efficiency between 0 and 1, 0 indicates not supported, 1 indicates most efficient.
Parameters:
steporder  Stepping order to query
zoom  Zoom/magnification factor

bool SPATMOD::IMAGE::BASE::QueryZoom ( double  zoom  )  const

Query image for support of specified zoom value.

void SPATMOD::IMAGE::BASE::SetAllDimensions ( const BASE image  )  [protected]

Set all base dimensions from another image.

Set total and tile dimensions, and georeference.

Parameters:
image  Image to set dimensions from

void SPATMOD::IMAGE::BASE::SetAllProperties ( const BASE image  )  [protected]

Set all base properties (except pixel lookup table) from another image.

Set total and tile dimensions, pixel properties, pixel range if defined, and georeference.

Parameters:
image  Image to set properties from

void SPATMOD::IMAGE::BASE::SetGeoreference ( const GEOREFERENCE pGeoreference  )  [protected]

Set georeference.

A copy of the specified georeference is retained.

Parameters:
pGeoreference  Pointer to georeference, NULL to remove previously set values

void SPATMOD::IMAGE::BASE::SetPixelLookupTable ( const PIXELTABLE pPixelTable  )  [protected]

Set pixel lookup table (for images with PIXEL::TYPE_Indexed).

A copy of the specified table is retained.

Parameters:
pPixelTable  Pointer to lookup table, NULL to remove previously set table

void SPATMOD::IMAGE::BASE::SetPixelProperties ( const BASE image  )  [protected]

Set pixel properties, including range, from source image.

Parameters:
image  Image to set properties from

void SPATMOD::IMAGE::BASE::SetPixelProperties ( const PIXEL PixelProperties  )  [protected]

Set pixel properties for image.

Will also reset pixel range to default.

ERRVALUE SPATMOD::IMAGE::BASE::SetPixelRange ( const PIXEL PixelValueMin,
const PIXEL PixelValueMax,
RANGETYPE  RangeType 
) [protected]

Set specific pixel range and type.

void SPATMOD::IMAGE::BASE::SetPixelRangeDefault (  )  [protected]

Set pixel range to default for pixel type.

Also set pixel range type to RANGETYPE_Default.

ERRVALUE SPATMOD::IMAGE::BASE::SetTileDimensions ( double  ColumnsPerTile,
double  RowsPerTile,
double  ColumnsPerTileFirst = 0,
double  RowsPerTileFirst = 0,
double  ColumnsPerTileLast = 0,
double  RowsPerTileLast = 0 
) [protected]

Set tile dimensions.

ERRVALUE SPATMOD::IMAGE::BASE::SetTotalDimensions ( UINT32  TotalColumns,
UINT32  TotalRows 
) [protected]

Set image dimensions.

Will reset tile dimensions to match image dimensions (resulting in "untiled" image).

virtual const GEOREFERENCE* SPATMOD::IMAGE::BASE::v_GetGeoreference (  )  const [protected, virtual]

Get georeference information.

Default implementation returns pointer if set, NULL otherwise.

Reimplemented in SPATMOD::IMAGE::FILTER.

virtual INT32 SPATMOD::IMAGE::BASE::v_GetNumColumnsOfTiles ( double  zoom  )  const [protected, virtual]

Get number of columns of tiles "across" the image.

Default implementation returns value for unzoomed image.

Parameters:
zoom  Zoom/magnification factor

virtual double SPATMOD::IMAGE::BASE::v_GetNumColumnsPerTile ( TILEPOSITION  tileposition,
double  zoom 
) const [protected, virtual]

Get number of columns per tile.

Note that first and last tiles may have different sizes than each other or interior tiles. If GetNumColumnsOfTiles is less than 3 then will return 0 for TILEPOSITION_Interior. If GetNumColumnsOfTiles is less than 2 then the "last" tile will have same dimension as "first" tile. Default implementation returns error if zoom unsupported otherwise scales result for unzoomed image by specified zoom value.

Parameters:
tileposition  Tile position
zoom  Zoom/magnification factor

virtual INT32 SPATMOD::IMAGE::BASE::v_GetNumRowsOfTiles ( double  zoom  )  const [protected, virtual]

Get number of rows of tiles "down" the image.

Default implementation returns value for unzoomed image.

Parameters:
zoom  Zoom/magnification factor

virtual double SPATMOD::IMAGE::BASE::v_GetNumRowsPerTile ( TILEPOSITION  tileposition,
double  zoom 
) const [protected, virtual]

Get number of rows per tile.

Note that first and last tiles may have different sizes than each other or interior tiles. If GetNumRowsOfTiles is less than 3 then will return 0 for TILEPOSITION_Interior. If GetNumRowsOfTiles is less than 2 then the "last" tile will have same dimension as "first" tile. Default implementation returns error if zoom unsupported otherwise scales result for unzoomed image by specified zoom value.

Parameters:
tileposition  Tile position
zoom  Zoom/magnification factor

virtual const PIXELTABLE* SPATMOD::IMAGE::BASE::v_GetPixelLookupTable (  )  const [protected, virtual]

Get pixel lookup table.

Default implementation returns pointer if set and image has PIXEL::TYPE_Indexed, NULL otherwise.

Reimplemented in SPATMOD::IMAGE::TARGET.

virtual double SPATMOD::IMAGE::BASE::v_GetTotalColumns ( double  zoom  )  const [protected, virtual]

Get total number of columns in image.

Default implementation returns error if zoom unsupported otherwise scales result for unzoomed image by specified zoom value.

Parameters:
zoom  Zoom/magnification factor

virtual double SPATMOD::IMAGE::BASE::v_GetTotalRows ( double  zoom  )  const [protected, virtual]

Get total number of rows in image.

Default implementation returns error if zoom unsupported otherwise scales result for unzoomed image by specified zoom value.

Parameters:
zoom  Zoom/magnification factor

virtual ZOOMABILITY SPATMOD::IMAGE::BASE::v_GetZoomAbility ( SIMPLE_ARRAY< double > &  ZoomsAllowed  )  const [private, virtual]

Query image for support of specified zoom value.

Default implementation returns true if zoom==1 and false otherwise.

Parameters:
ZoomsAllowed  Zoom values allowed, interpretation depends on return value

virtual bool SPATMOD::IMAGE::BASE::v_QueryCapability ( CAPABILITY  capability  )  const [protected, virtual]

Query image for specified capability.

Reimplemented in SPATMOD::IMAGE::STAGE, and SPATMOD::IMAGE::TARGET.

virtual float SPATMOD::IMAGE::BASE::v_QueryStepOrder ( STEPORDER  steporder,
double  zoom 
) const [protected, virtual]

Query support/efficiency for specified stepping order.

Returns:
Efficiency between 0 and 1, 0 indicates not supported, 1 indicates most efficient. Default implementation returns 1 for STEPORDER_TileSequential, 1 for STEPORDER_FullSequential if only one column of tiles and 0 for all other cases.
Parameters:
steporder  Stepping order to query
zoom  Zoom/magnification factor

Reimplemented in SPATMOD::IMAGE::FILTER.


Member Data Documentation

PIXELTABLE* SPATMOD::IMAGE::BASE::m_pPixelLookupTable [protected]

Pointer to pixel lookup table.

Definition at line 221 of file imagebase.h.


The documentation for this class was generated from the following file:
Generated on Thu Apr 26 04:49:20 2007 for TNTsdk by  doxygen 1.5.2