16 #include <osg/MatrixTransform>
37 float segmentSpacing = 1.0,
38 const osg::Vec4& color = osg::Vec4d(0.5, 0.5, 0.5, 1.0),
39 float maxLength = 2000,
40 float timeout = 3600.0);
55 virtual void traverse(osg::NodeVisitor& nv);
58 virtual osg::Node* node();
61 virtual void setColor(
const osg::Vec4& color);
64 virtual const osg::Vec4&
color()
const {
return myColor; }
67 virtual void setDroppedPoints(
const osg::Vec3d& pointA,
const osg::Vec3d& pointB);
72 virtual void setDroppedPointsPositionOffset(
const osg::Vec3d& posOffset);
75 virtual void update(
double dt,
double simTime);
79 virtual void update();
82 virtual void setMaxSegments(
long segments);
85 inline virtual long maxSegments()
const {
return myMaxSegments; }
88 virtual void setSegmentSpacing(
float spacing);
91 virtual void setSegmentTimeout(
float duration);
102 virtual void setStippled(
bool stippled);
108 inline virtual bool isStippled()
const {
return myStippled; }
111 virtual void setLightingEnabled(
bool enable);
114 virtual bool lightingEnabled();
117 virtual void setHeightLinesEnabled(
bool enabled);
120 virtual void setHeightLinesColor(
float r,
float g,
float b,
float a);
123 virtual void setHeightLinesSpacing(
float spacing);
126 virtual void setHeightLinesModelSetId(
DtModelSetId modelSetId);
131 virtual void addParticle(osg::Vec3d
const& left, osg::Vec3d
const& right,
135 virtual float currentSegmentLength() = 0;
138 virtual void setCurrentSegmentLength(
float len );
143 virtual void cleanupOldSegments(
double simTime) = 0;
146 virtual void extendCurrentSegment(osg::Vec3d
const& left,
147 osg::Vec3d
const& right,
double simTime) = 0;
150 virtual osg::Drawable* getDrawable() = 0;
153 virtual osg::Geode* createGeode();
156 virtual void setDrawable();
187 float myHeightLinesColor[4];
long myMaxSegments
Definition: DtOsgRibbon.h:169
int myLastUpdatedFrame
Definition: DtOsgRibbon.h:165
virtual long maxSegments() const
Gets the maximum number of segments allowed in the ribbon.
Definition: DtOsgRibbon.h:85
DtModelSetId myHeightLinesModelSetId
Definition: DtOsgRibbon.h:189
osg::Matrixd myWorldTransformInv
Definition: DtOsgRibbon.h:162
bool myFirstUpdate
Definition: DtOsgRibbon.h:180
float mySegmentTimeout
Definition: DtOsgRibbon.h:173
#define DT_DLL_VRVOSG
Definition: vrvOsg.h:23
bool myStippled
Definition: DtOsgRibbon.h:181
bool myShaderSet
Definition: DtOsgRibbon.h:185
DtDe & myDe
Definition: DtOsgRibbon.h:183
osg::ref_ptr< osg::MatrixTransform > myPositionNode
Definition: DtOsgRibbon.h:160
osg::Vec3d myLocalPointA
Definition: DtOsgRibbon.h:175
virtual bool isStippled() const
Get the stipple setting for this ribbon.
Definition: DtOsgRibbon.h:108
osg::ref_ptr< osg::Geode > myGeode
Definition: DtOsgRibbon.h:161
double myRibbonLengthSquared
Definition: DtOsgRibbon.h:167
bool myLightingEnabled
Definition: DtOsgRibbon.h:184
float mySegmentSpacingSquared
Definition: DtOsgRibbon.h:171
virtual const osg::Vec4 & color() const
Get the ribbon's color.
Definition: DtOsgRibbon.h:64
osg::Vec3d myLocalPointB
Definition: DtOsgRibbon.h:176
bool myHeightLinesEnabled
Definition: DtOsgRibbon.h:186
osg::Vec3d myLocalPosOffset
Definition: DtOsgRibbon.h:177
osg::Vec4 myColor
Definition: DtOsgRibbon.h:179
Base class for OSG ribbon implementations.
Definition: DtOsgRibbon.h:27
osg::Matrixd myLastLocalToWork
Definition: DtOsgRibbon.h:163
float mySegmentSpacing
Definition: DtOsgRibbon.h:172
virtual float segmentSpacing() const
Gets the maximum length of the ribbon segments.
Definition: DtOsgRibbon.h:94
Contains DLL export macros.
The DtDe is the core component of any VR-Vantage application. It owns a DtRenderer, DtDeCommunicator, as well as a DtDisplay and other things.
Definition: DtDe.h:72
int myActiveSegmentCount
Definition: DtOsgRibbon.h:170
float myHeightLinesSpacing
Definition: DtOsgRibbon.h:188
DtModelSetId
Definition: DtModelSetEnums.h:19
double myLastUpdateTime
Definition: DtOsgRibbon.h:166
Contains various enum classes relating to model sets.