Viewshed 6.1.0
A C++ library for calculation of viewshed, inverse viewshed and visibility indices for both of those analyses.
Loading...
Searching...
No Matches
viewshed::LoSNode Class Reference

Representation of single cell that creates a point on LoS. More...

#include <losnode.h>

Inheritance diagram for viewshed::LoSNode:
Collaboration diagram for viewshed::LoSNode:

Public Member Functions

 LoSNode ()
 Construct a new empty LoSNode object.
 LoSNode (int row, int col)
 Construct a new LoSNode object at specific row and column.
 LoSNode (const int &pointRow, const int &pointCol, const CellEvent *e, const double &cellSize)
 Construct a new LoSNode object build from Point position, CellEvent and cell size.
bool operator== (const LoSNode &other) const
bool operator!= (const LoSNode &other) const
bool operator< (const LoSNode other) const
double valueAtAngle (const double &angle, ValueType valueType=ValueType::Elevation) const
 Extract value of ValueType at specified angle.
double value (CellEventPositionType position, ValueType valueType=ValueType::Elevation) const
 Extract value of ValueType at specific cell event position.
double centreAngle () const
 Shortcut call to obtain horizontal angle at center of raster cell that this LoSNode represents.
double centreElevation () const
 Shortcut call to obtain elevation angle at center of raster cell that this LoSNode represents.
double centreDistance () const
 Shortcut call to obtain distance angle at center of raster cell that this LoSNode represents.
double elevationAtAngle (const double &angle) const
double distanceAtAngle (const double &angle) const

Public Attributes

double mAngle [3]
double mElevs [3]
double mDistances [3]
bool mInverseLoSBehindTarget = false
Public Attributes inherited from viewshed::RasterPosition
int mRow = -1
int mCol = -1

Detailed Description

Representation of single cell that creates a point on LoS.

Constructor & Destructor Documentation

◆ LoSNode() [1/2]

LoSNode::LoSNode ( int row,
int col )

Construct a new LoSNode object at specific row and column.

Parameters
row
col

◆ LoSNode() [2/2]

LoSNode::LoSNode ( const int & pointRow,
const int & pointCol,
const CellEvent * e,
const double & cellSize )

Construct a new LoSNode object build from Point position, CellEvent and cell size.

Parameters
pointRowImportant point row of viewshed (either view point for viewshed or target point for inverseviewshed).
pointColImportant point column of viewshed (either view point for viewshed or target point for inverseviewshed).
eCell event with all the necessary information.
cellSizeCell size of raster from which the information was derived.

Member Function Documentation

◆ centreAngle()

double LoSNode::centreAngle ( ) const

Shortcut call to obtain horizontal angle at center of raster cell that this LoSNode represents.

Returns
double

◆ centreDistance()

double LoSNode::centreDistance ( ) const

Shortcut call to obtain distance angle at center of raster cell that this LoSNode represents.

Returns
double

◆ centreElevation()

double LoSNode::centreElevation ( ) const

Shortcut call to obtain elevation angle at center of raster cell that this LoSNode represents.

Returns
double

◆ value()

double LoSNode::value ( CellEventPositionType position,
ValueType valueType = ValueType::Elevation ) const

Extract value of ValueType at specific cell event position.

Parameters
position
valueType
Returns
double

◆ valueAtAngle()

double LoSNode::valueAtAngle ( const double & angle,
ValueType valueType = ValueType::Elevation ) const

Extract value of ValueType at specified angle.

Parameters
angle
valueType
Returns
double

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