|
Public Member Functions |
| BlinkSequence () |
| BlinkSequence (const BlinkSequence &bs, const osg::CopyOp ©op=osg::CopyOp::SHALLOW_COPY) |
| META_Object (osgSim, BlinkSequence) |
void | addPulse (double length, const osg::Vec4 &color) |
| add a pulse of specified color and duration to the BlinkSequence.
|
int | getNumPulses () const |
| return the number of pulses.
|
void | getPulse (unsigned int i, double &length, osg::Vec4 &color) const |
| return the pulse data at position i.
|
void | setPulse (unsigned int i, double length, const osg::Vec4 &color) |
| set pulse of specified color and duration to the BlinkSequence.
|
double | getPulsePeriod () const |
| get the total pulse period of the blink sequence, which is equal to the sum of all the pulse periods.
|
void | setSequenceGroup (SequenceGroup *sg) |
| set the sequence group which can be used to synchronize related blink sequences.
|
SequenceGroup * | getSequenceGroup () |
| get the non const sequence group.
|
const SequenceGroup * | getSequenceGroup () const |
| get the const sequence group.
|
void | setPhaseShift (double ps) |
| set the phase shift of the blink sequence, this would be used to shift a sequence within a sequence group.
|
double | getPhaseShift () const |
| get the pahse shift.
|
double | localTime (double time) const |
| compute the local time clamped to this BlinkSequences period, and accounting for the phase shift and sequence group.
|
osg::Vec4 | color (double time, double length) const |
| compute the color for the time interval sepecifed.
|
Protected Types |
typedef std::pair< double,
osg::Vec4 > | IntervalColor |
typedef std::vector< IntervalColor > | PulseData |
Protected Attributes |
double | _pulsePeriod |
double | _phaseShift |
PulseData | _pulseData |
osg::ref_ptr< SequenceGroup > | _sequenceGroup |