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

vrvGraphics-based implementation of a 2D compass

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

Classes

struct  TickMark
 

Public Member Functions

 DtOsgChannelCompassInstance (DtDe &de)
 
virtual ~DtOsgChannelCompassInstance ()
 
 DtOsgChannelCompassInstance ()=delete
 
 DtOsgChannelCompassInstance (const DtOsgChannelCompassInstance &other)=delete
 
DtOsgChannelCompassInstanceoperator= (const DtOsgChannelCompassInstance &other)=delete
 
virtual void setVisible (bool isVisible)
 
virtual bool visible ()
 
virtual void setChannelName (const std::string &deName, const std::string &winName, const std::string &channelName)
 
virtual void setModelDefinition (const std::string &modelDefinition)
 
virtual void updateCompass (bool force)
 
void updateLetter (bool &dirtyFlag, const std::string &filename, int tickIndex, DtQuadProxyInterface *letterQuad, DtOsgTextureWrapper *letterTexture, bool &force)
 
virtual void setNorthLetterFilename (const std::string &filename)
 
virtual void setSouthLetterFilename (const std::string &filename)
 
virtual void setEastLetterFilename (const std::string &filename)
 
virtual void setWestLetterFilename (const std::string &filename)
 
virtual void setStarFilename (const std::string &filename)
 
virtual void setDarkTickColor (float r, float g, float b, float a)
 
virtual void setLightTickColor (float r, float g, float b, float a)
 
virtual void setPixelRatio (float pixelRatio)
 
- Public Member Functions inherited from makVrv::DtChannelCompassInstance
 DtChannelCompassInstance (DtDe &de)
 
virtual ~DtChannelCompassInstance ()
 
 DtChannelCompassInstance (const DtChannelCompassInstance &other)=delete
 
DtChannelCompassInstanceoperator= (const DtChannelCompassInstance &other)=delete
 
virtual void setCompassHeading (double heading)
 
virtual void setLocation (DtChannelCompass::Locations location)
 
DtChannelCompass::Locations location () const
 
virtual void setMargins (unsigned int xMargin, unsigned int yMargin)
 
virtual void setCompassRadius (unsigned int radius)
 
virtual void setNorthLetterSize (unsigned int width, unsigned int height)
 
void setSouthLetterSize (unsigned int width, unsigned int height)
 
virtual void setEastLetterSize (unsigned int width, unsigned int height)
 
virtual void setWestLetterSize (unsigned int width, unsigned int height)
 
virtual void setStarSize (unsigned int width, unsigned int height)
 
virtual void showSmallTickMarks (bool show)
 
- Public Member Functions inherited from makVrv::DtSetVisibilityInterface
virtual ~DtSetVisibilityInterface ()
 

Protected Types

typedef std::vector< float > VertexList
 

Protected Member Functions

virtual void slot_channelCreated (DtChannelManager *, DtChannel *)
 
virtual void slot_channelToBeDestroyed (DtChannelManager *, DtChannel *)
 
virtual void slot_channelConfigurationModified (const std::string &deName, const std::string &winName, const std::string &oldChannelName, const DtChannelConfiguration &config)
 
virtual void slot_windowConfigurationModified (const std::string &deName, const std::string &winName, const DtWindowConfiguration &config)
 
virtual void slot_coordinateSystemChanged ()
 
void createCompass ()
 
void destroyCompass ()
 
virtual void createTextures (DtDe &de)
 
virtual void destroyTextures ()
 
osg::Vec2 calcCenterPosition ()
 
void slot_update ()
 
DtLineSegmentcreateDarkSide (DtOverlayRendererInterface &overlay)
 
DtLineSegmentcreateLightSide (DtOverlayRendererInterface &overlay)
 

Static Protected Member Functions

static void rotate (const DtOsgChannelCompassInstance::VertexList &in, double rad, DtOsgChannelCompassInstance::VertexList &out)
 
static void translate (const DtOsgChannelCompassInstance::VertexList &in, const osg::Vec2 &translation, DtOsgChannelCompassInstance::VertexList &out)
 
static void scale (const DtOsgChannelCompassInstance::VertexList &in, double s, DtOsgChannelCompassInstance::VertexList &out)
 

Protected Attributes

DtSignalConnectionManager myConnections
 
DtSignalConnectionManager myPixelRatioConnection
 
DtOsgChannelmyChannel
 
std::unique_ptr
< DtOsgTextureWrapper
myNorthTexture
 
std::unique_ptr
< DtOsgTextureWrapper
mySouthTexture
 
std::unique_ptr
< DtOsgTextureWrapper
myEastTexture
 
std::unique_ptr
< DtOsgTextureWrapper
myWestTexture
 
std::unique_ptr
< DtOsgTextureWrapper
myStarTexture
 
DtQuadProxyInterfacemyNorthLetter
 
DtQuadProxyInterfacemySouthLetter
 
DtQuadProxyInterfacemyEastLetter
 
DtQuadProxyInterfacemyWestLetter
 
DtQuadProxyInterfacemyStarQuad
 
osg::Vec2 myCenterPosition
 
bool myNorthLetterDirty
 
bool mySouthLetterDirty
 
bool myEastLetterDirty
 
bool myWestLetterDirty
 
bool myStarDirty
 
TickMark myLargeTickMarks [7]
 
TickMark mySmallTickMarks [16]
 
float myPixelRatio
 
TickMark myTrueNorthMark
 
TickMark myMagneticNorthMark
 
TickMark myDaggerMark
 
DtCoordinateSystemmyCoordinateSystem = nullptr
 
- Protected Attributes inherited from makVrv::DtChannelCompassInstance
std::string myModelDefinitionName
 
std::string myDisplayEngineName
 
std::string myWindowName
 
std::string myChannelName
 
DtChannelCompass::Locations myLocation
 
unsigned int myMargins [2]
 
std::string myNorthLetterFilename
 
std::string mySouthLetterFilename
 
std::string myEastLetterFilename
 
std::string myWestLetterFilename
 
std::string myStarFilename
 
unsigned int myCompassRadius
 
double myCompassHeading
 
double myCompassDeclination
 
unsigned int myNorthLetterSize [2]
 
unsigned int mySouthLetterSize [2]
 
unsigned int myEastLetterSize [2]
 
unsigned int myWestLetterSize [2]
 
unsigned int myStarSize [2]
 
float myDarkTickColor [4]
 
float myLightTickColor [4]
 
bool myShowSmallTickMarks
 
DtDemyDe
 

Member Typedef Documentation

typedef std::vector<float> makVrv::DtOsgChannelCompassInstance::VertexList
protected

Constructor & Destructor Documentation

makVrv::DtOsgChannelCompassInstance::DtOsgChannelCompassInstance ( DtDe de)

CTOR.

virtual makVrv::DtOsgChannelCompassInstance::~DtOsgChannelCompassInstance ( )
virtual

DTOR.

makVrv::DtOsgChannelCompassInstance::DtOsgChannelCompassInstance ( )
delete

Default Constructor not implemented.

makVrv::DtOsgChannelCompassInstance::DtOsgChannelCompassInstance ( const DtOsgChannelCompassInstance other)
delete

Copy Constructor not implemented - Copy not allowed.

Member Function Documentation

DtOsgChannelCompassInstance& makVrv::DtOsgChannelCompassInstance::operator= ( const DtOsgChannelCompassInstance other)
delete

Assignment Operator not implemented - Assignment not allowed.

virtual void makVrv::DtOsgChannelCompassInstance::setVisible ( bool  isVisible)
virtual

Set the compass to visible or invisible.

Implements makVrv::DtSetVisibilityInterface.

virtual bool makVrv::DtOsgChannelCompassInstance::visible ( )
virtual

Return visibility status.

virtual void makVrv::DtOsgChannelCompassInstance::setChannelName ( const std::string &  deName,
const std::string &  winName,
const std::string &  channelName 
)
virtual

Set the name of the channel that this compass should be drawn on.

Reimplemented from makVrv::DtChannelCompassInstance.

virtual void makVrv::DtOsgChannelCompassInstance::setModelDefinition ( const std::string &  modelDefinition)
virtual

Set the model definition; note that this (potentially) includes all the other parameters enumeration below.

Reimplemented from makVrv::DtChannelCompassInstance.

virtual void makVrv::DtOsgChannelCompassInstance::updateCompass ( bool  force)
virtual

Called anytime any of the compass frame parameters change; calls redraw compass needle.

Implements makVrv::DtChannelCompassInstance.

void makVrv::DtOsgChannelCompassInstance::updateLetter ( bool dirtyFlag,
const std::string &  filename,
int  tickIndex,
DtQuadProxyInterface letterQuad,
DtOsgTextureWrapper letterTexture,
bool force 
)
virtual void makVrv::DtOsgChannelCompassInstance::setNorthLetterFilename ( const std::string &  filename)
virtual

Override base class method to set the dirty flag.

Reimplemented from makVrv::DtChannelCompassInstance.

virtual void makVrv::DtOsgChannelCompassInstance::setSouthLetterFilename ( const std::string &  filename)
virtual

Override base class method to set the dirty flag.

Reimplemented from makVrv::DtChannelCompassInstance.

virtual void makVrv::DtOsgChannelCompassInstance::setEastLetterFilename ( const std::string &  filename)
virtual

Override base class method to set the dirty flag.

Reimplemented from makVrv::DtChannelCompassInstance.

virtual void makVrv::DtOsgChannelCompassInstance::setWestLetterFilename ( const std::string &  filename)
virtual

Override base class method to set the dirty flag.

Reimplemented from makVrv::DtChannelCompassInstance.

virtual void makVrv::DtOsgChannelCompassInstance::setStarFilename ( const std::string &  filename)
virtual

Override base class method to set the dirty flag.

Reimplemented from makVrv::DtChannelCompassInstance.

virtual void makVrv::DtOsgChannelCompassInstance::setDarkTickColor ( float  r,
float  g,
float  b,
float  a 
)
virtual

Override base class method to change dark color on all tick marks.

Reimplemented from makVrv::DtChannelCompassInstance.

virtual void makVrv::DtOsgChannelCompassInstance::setLightTickColor ( float  r,
float  g,
float  b,
float  a 
)
virtual

Override base class method to change dark color on all tick marks.

Reimplemented from makVrv::DtChannelCompassInstance.

virtual void makVrv::DtOsgChannelCompassInstance::setPixelRatio ( float  pixelRatio)
virtual

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

virtual void makVrv::DtOsgChannelCompassInstance::slot_channelCreated ( DtChannelManager ,
DtChannel  
)
protectedvirtual
virtual void makVrv::DtOsgChannelCompassInstance::slot_channelToBeDestroyed ( DtChannelManager ,
DtChannel  
)
protectedvirtual
virtual void makVrv::DtOsgChannelCompassInstance::slot_channelConfigurationModified ( const std::string &  deName,
const std::string &  winName,
const std::string &  oldChannelName,
const DtChannelConfiguration config 
)
protectedvirtual
virtual void makVrv::DtOsgChannelCompassInstance::slot_windowConfigurationModified ( const std::string &  deName,
const std::string &  winName,
const DtWindowConfiguration config 
)
protectedvirtual
virtual void makVrv::DtOsgChannelCompassInstance::slot_coordinateSystemChanged ( )
protectedvirtual

slot for when the coordinate system changes

void makVrv::DtOsgChannelCompassInstance::createCompass ( )
protected
void makVrv::DtOsgChannelCompassInstance::destroyCompass ( )
protected
virtual void makVrv::DtOsgChannelCompassInstance::createTextures ( DtDe de)
protectedvirtual
virtual void makVrv::DtOsgChannelCompassInstance::destroyTextures ( )
protectedvirtual
osg::Vec2 makVrv::DtOsgChannelCompassInstance::calcCenterPosition ( )
protected
void makVrv::DtOsgChannelCompassInstance::slot_update ( )
protected
DtLineSegment* makVrv::DtOsgChannelCompassInstance::createDarkSide ( DtOverlayRendererInterface overlay)
protected
DtLineSegment* makVrv::DtOsgChannelCompassInstance::createLightSide ( DtOverlayRendererInterface overlay)
protected
static void makVrv::DtOsgChannelCompassInstance::rotate ( const DtOsgChannelCompassInstance::VertexList in,
double  rad,
DtOsgChannelCompassInstance::VertexList out 
)
staticprotected

Utility function to rotate a list of vertices.

static void makVrv::DtOsgChannelCompassInstance::translate ( const DtOsgChannelCompassInstance::VertexList in,
const osg::Vec2 &  translation,
DtOsgChannelCompassInstance::VertexList out 
)
staticprotected

Utility function to translate a list of vertices.

static void makVrv::DtOsgChannelCompassInstance::scale ( const DtOsgChannelCompassInstance::VertexList in,
double  s,
DtOsgChannelCompassInstance::VertexList out 
)
staticprotected

Member Data Documentation

DtSignalConnectionManager makVrv::DtOsgChannelCompassInstance::myConnections
protected
DtSignalConnectionManager makVrv::DtOsgChannelCompassInstance::myPixelRatioConnection
protected
DtOsgChannel* makVrv::DtOsgChannelCompassInstance::myChannel
protected
std::unique_ptr<DtOsgTextureWrapper> makVrv::DtOsgChannelCompassInstance::myNorthTexture
protected
std::unique_ptr<DtOsgTextureWrapper> makVrv::DtOsgChannelCompassInstance::mySouthTexture
protected
std::unique_ptr<DtOsgTextureWrapper> makVrv::DtOsgChannelCompassInstance::myEastTexture
protected
std::unique_ptr<DtOsgTextureWrapper> makVrv::DtOsgChannelCompassInstance::myWestTexture
protected
std::unique_ptr<DtOsgTextureWrapper> makVrv::DtOsgChannelCompassInstance::myStarTexture
protected
DtQuadProxyInterface* makVrv::DtOsgChannelCompassInstance::myNorthLetter
protected
DtQuadProxyInterface* makVrv::DtOsgChannelCompassInstance::mySouthLetter
protected
DtQuadProxyInterface* makVrv::DtOsgChannelCompassInstance::myEastLetter
protected
DtQuadProxyInterface* makVrv::DtOsgChannelCompassInstance::myWestLetter
protected
DtQuadProxyInterface* makVrv::DtOsgChannelCompassInstance::myStarQuad
protected
osg::Vec2 makVrv::DtOsgChannelCompassInstance::myCenterPosition
protected
bool makVrv::DtOsgChannelCompassInstance::myNorthLetterDirty
protected
bool makVrv::DtOsgChannelCompassInstance::mySouthLetterDirty
protected
bool makVrv::DtOsgChannelCompassInstance::myEastLetterDirty
protected
bool makVrv::DtOsgChannelCompassInstance::myWestLetterDirty
protected
bool makVrv::DtOsgChannelCompassInstance::myStarDirty
protected
TickMark makVrv::DtOsgChannelCompassInstance::myLargeTickMarks[7]
protected
TickMark makVrv::DtOsgChannelCompassInstance::mySmallTickMarks[16]
protected
float makVrv::DtOsgChannelCompassInstance::myPixelRatio
protected
TickMark makVrv::DtOsgChannelCompassInstance::myTrueNorthMark
protected
TickMark makVrv::DtOsgChannelCompassInstance::myMagneticNorthMark
protected
TickMark makVrv::DtOsgChannelCompassInstance::myDaggerMark
protected
DtCoordinateSystem* makVrv::DtOsgChannelCompassInstance::myCoordinateSystem = nullptr
protected

local clone of the system wide coordinate system. for thread safety.


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

Document ID: Generated on Thu Oct 23 22:29:17 EDT 2025 from SVN revision 280951
Copyright © 2005-2024 MAK Technologies. All Rights Reserved (www.mak.com)