VR-Forces Developer's Guide
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Properties Friends Macros Groups Pages
List of all members | Public Member Functions | Protected Member Functions | Static Protected Member Functions | Protected Attributes | Private Member Functions
makVrv::DtGridLinesDrawer Class Referenceabstract

Base class with common data / methods for drawing grid lines on projected and geocentric databases \ingroup vrvOsg.

Inheritance diagram for makVrv::DtGridLinesDrawer:
Inheritance graph
[legend]

Public Member Functions

 DtGridLinesDrawer (DtDe &de)
 
virtual ~DtGridLinesDrawer ()
 
virtual void setChannel (DtOsgChannel *channel)
 
virtual void setChannelDimensions (int startChannelX, int startChannelY, int endChannelX, int endChannelY)
 
virtual void setupOverlay ()
 
virtual void setupFont ()
 
virtual double lookupClosestLatLonSpacing (double minimumSpacingRadians)
 
virtual double lookupClosestCartesianSpacing (double minimumSpacing)
 
virtual double lookupClosestGarsSpacing (double minimumSpacing) const
 
void setPixelRatio (float pixelRatio)
 
- Public Member Functions inherited from makVrv::DtGridLinesParameters
 DtGridLinesParameters ()
 
virtual ~DtGridLinesParameters ()
 
 DtGridLinesParameters (const DtGridLinesParameters &orig)
 
DtGridLinesParametersoperator= (const DtGridLinesParameters &orig)
 
virtual void setGridType (makArchives::DtDisplayUnitsSettingsRecord::CoordSys gridType)
 
virtual void setUnitType (makArchives::DtDisplayUnitsSettingsRecord::DistanceUnits unitType)
 
virtual void setUnitType (makArchives::DtDisplayUnitsSettingsRecord::OrientationUnits unitType)
 
virtual void setMinimalGridlineLabelsEnabled (bool enabled)
 
virtual void setAutoSpacing (bool autoSpacing)
 
virtual void setMinSpacing (int pixels)
 
virtual void setFixedSpacingAmount (double amount)
 
virtual void setXOffset (double offset)
 
virtual void setYOffset (double offset)
 
virtual void setDecimalPlaces (unsigned decimalPlaces)
 
virtual void setMaxGridLines (int maxGridLines)
 
virtual void setEastWestGridLineColor (float r, float g, float b, float a)
 
virtual void setEastWestLabelColor (float r, float g, float b, float a)
 
virtual void setNorthSouthGridLineColor (float r, float g, float b, float a)
 
virtual void setNorthSouthLabelColor (float r, float g, float b, float a)
 
virtual void setLabelFont (const std::string &fontName)
 
virtual void setLabelPointSize (int pointSize)
 
virtual void setLabelXOffset (int pixels)
 
virtual void setLabelYOffset (int pixels)
 
virtual void setLabelTextWidth (int width)
 
virtual void setLabelTextHeight (int height)
 
virtual void setGridLineWidth (float width)
 
virtual void setLatLonLabelsCenteringCutoff (int altitude)
 
virtual void setGarsPolarLatitudeCutoff (double latitude)
 

Protected Member Functions

virtual void reloadTextFonts ()=0
 

Static Protected Member Functions

static bool clip (double xMin, double xMax, double yMin, double yMax, double x0src, double y0src, double x1src, double y1src, double &x0clip, double &y0clip, double &x1clip, double &y1clip)
 

Protected Attributes

DtDemyDe
 
DtOsgChannelmyChannel
 
osg::Matrix myWorldToWindowMatrix
 
int myStartChannelX
 
int myStartChannelY
 
int myEndChannelX
 
int myEndChannelY
 
DtOverlayRenderermyOverlayRenderer
 
DtFontInterfacemyFont
 
float myPixelRatio
 
std::vector< doublemyLatLonAllowableSpacings
 
std::vector< doublemyCartesianAllowableSpacings
 
std::vector< doublemyGarsAllowableSpacings
 
- Protected Attributes inherited from makVrv::DtGridLinesParameters
makArchives::DtDisplayUnitsSettingsRecord::CoordSys myGridType
 
bool myUnitTypeIsAngular
 
makArchives::DtDisplayUnitsSettingsRecord::DistanceUnits myUnitType
 
makArchives::DtDisplayUnitsSettingsRecord::OrientationUnits myAngularUnitType
 
bool myMinimalGridlineLabelsEnabled
 
bool myAutoSpacing
 
int myMinSpacing
 
double mySpacing
 
double myXOffset
 
double myYOffset
 
unsigned myDecimalPlaces
 
int myMaxGridLines
 
float myEastWestGridLineColor [4]
 
float myEastWestLabelColor [4]
 
float myNorthSouthGridLineColor [4]
 
float myNorthSouthLabelColor [4]
 
std::string myLabelFont
 
int myLabelPointSize
 
int myLabelXOffset
 
int myLabelYOffset
 
int myLabelTextWidth
 
int myLabelTextHeight
 
float myGridLineWidth
 
int myLatLonLabelsCenteringCutoff
 
double myGarsPolarLatitudeCutoff
 

Private Member Functions

 DtGridLinesDrawer (const DtGridLinesDrawer &orig)
 
DtGridLinesDraweroperator= (const DtGridLinesDrawer &rhs)
 

Constructor & Destructor Documentation

makVrv::DtGridLinesDrawer::DtGridLinesDrawer ( DtDe de)

Default CTOR.

virtual makVrv::DtGridLinesDrawer::~DtGridLinesDrawer ( )
virtual

Virtual DTOR.

makVrv::DtGridLinesDrawer::DtGridLinesDrawer ( const DtGridLinesDrawer orig)
private

Copy CTOR ( Not implemented )

Member Function Documentation

virtual void makVrv::DtGridLinesDrawer::setChannel ( DtOsgChannel channel)
virtual

Set the channel to draw the grid lines on.

virtual void makVrv::DtGridLinesDrawer::setChannelDimensions ( int  startChannelX,
int  startChannelY,
int  endChannelX,
int  endChannelY 
)
virtual

Set the channel dimensions.

Reimplemented in makVrv::DtGeocentricGridLinesDrawer.

virtual void makVrv::DtGridLinesDrawer::setupOverlay ( )
virtual

Get the overlay to use for our channel.

virtual void makVrv::DtGridLinesDrawer::setupFont ( )
virtual

Get the font to use fron the font manager.

virtual double makVrv::DtGridLinesDrawer::lookupClosestLatLonSpacing ( double  minimumSpacingRadians)
virtual

Find the best allowable lat,lon spacing given the minimum requirement.

virtual double makVrv::DtGridLinesDrawer::lookupClosestCartesianSpacing ( double  minimumSpacing)
virtual

Find the best allowable cartesian spacing given the minimum requirement.

virtual double makVrv::DtGridLinesDrawer::lookupClosestGarsSpacing ( double  minimumSpacing) const
virtual

Find the best allowable GARS spacing given the minimum requirement. Note that this can return -1.0 which is a 'don't draw' indicator.

void makVrv::DtGridLinesDrawer::setPixelRatio ( float  pixelRatio)

Sets the pixel density ratio to scale grid lines on high dpi screens.

virtual void makVrv::DtGridLinesDrawer::reloadTextFonts ( )
protectedpure virtual

Reloads text label fonts on runtime font size change.

Implemented in makVrv::DtGeocentricGridLinesDrawer, and makVrv::DtProjectedGridLinesDrawer.

static bool makVrv::DtGridLinesDrawer::clip ( double  xMin,
double  xMax,
double  yMin,
double  yMax,
double  x0src,
double  y0src,
double  x1src,
double  y1src,
double x0clip,
double y0clip,
double x1clip,
double y1clip 
)
staticprotected

2D clipping routine. Implements Liang / Barsky Clipping

DtGridLinesDrawer& makVrv::DtGridLinesDrawer::operator= ( const DtGridLinesDrawer rhs)
private

Assignment operator ( Not implemented )

Member Data Documentation

DtDe& makVrv::DtGridLinesDrawer::myDe
protected
DtOsgChannel* makVrv::DtGridLinesDrawer::myChannel
protected
osg::Matrix makVrv::DtGridLinesDrawer::myWorldToWindowMatrix
protected
int makVrv::DtGridLinesDrawer::myStartChannelX
protected
int makVrv::DtGridLinesDrawer::myStartChannelY
protected
int makVrv::DtGridLinesDrawer::myEndChannelX
protected
int makVrv::DtGridLinesDrawer::myEndChannelY
protected
DtOverlayRenderer* makVrv::DtGridLinesDrawer::myOverlayRenderer
protected
DtFontInterface* makVrv::DtGridLinesDrawer::myFont
protected
float makVrv::DtGridLinesDrawer::myPixelRatio
protected
std::vector<double> makVrv::DtGridLinesDrawer::myLatLonAllowableSpacings
protected
std::vector<double> makVrv::DtGridLinesDrawer::myCartesianAllowableSpacings
protected
std::vector<double> makVrv::DtGridLinesDrawer::myGarsAllowableSpacings
protected

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

Document ID: Generated on Wed Mar 27 22:49:11 EDT 2024 from SVN revision 264633
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)