30 #include <osg/Geometry> 80 const osg::Program*
getProgram()
const {
return m_program; }
102 void setUseRedShiftScale(
bool);
143 virtual void update();
197 virtual void removeNotification();
202 virtual void addNotification();
204 void initialize(osg::Group* root);
SplineShaderRef m_splineGeometry
agx::Real getRadius() const
const osg::Uniform * getCircleResolutionUniform() const
agxUtil::SplineRef m_spline
osg::Vec4Array * m_quatsInColorArray
osg::ref_ptr< osg::Uniform > m_cylinderColorUniform
osg::FloatArray * m_radiusArray
Derive from this class to implement a listener for simulation step events.
size_t m_numActiveElements
agx::Real getNumSegmentsPerUnitLength() const
void setSplineModel(agxUtil::Spline *spline)
Assign spline model.
This namespace consists of a set of classes for handling geometric intersection tests including boole...
A class holding 4 dimensional vectors and providing basic arithmetic.
osg::ref_ptr< osg::Group > m_node
agxUtil::Spline * getSplineModel()
virtual void last(const agx::TimeStamp &)
Called after a step is taken in the simulation Implement this method in the derived class to get call...
osg::FloatArray * getRadiusArray()
Class to encapsulate reading shader files and setting up rendering of a Spline.
agx::RealVector m_redShiftScales
Values from 0 to 1 how red the color of the node is (0 default color, 1 red color, redShiftScale.size == spline->getNumPoints())
osg::DrawArrays * m_primitiveSet
The geometry representation used by the collision detection engine.
osg::ref_ptr< SplineShader > SplineShaderRef
osg::Uniform * getCircleResolutionUniform()
osg::Uniform * getCylinderColorUniform()
osg::FloatArray * m_xTexCoordArray
const osg::Program * getProgram() const
agx::ref_ptr< SplineRenderer > SplineRendererRef
const agx::RealVector & getRedShiftScales() const
The agxOSG namespace provides functionality for visualizing AGX simulations with OpenSceneGraph.
osg::ref_ptr< osg::Uniform > m_circleResolutionUniform
Class for rendering a spline model.
agx::RealVector & getRedShiftScales()
osg::Vec3Array * m_vertexArray
void setNumActiveElements(size_t numActiveElements)
osg::Vec4Array * getQuatsInColorArray()
const agxUtil::Spline * getSplineModel() const
osg::Vec3Array * getVertexArray()
void setRadius(agx::Real radius)
Assign new radius of the cylinder segments.
const osg::Uniform * getCylinderColorUniform() const
virtual ~SplineRenderer()
agx::Real m_numSegmentsPerUnitLength
osg::Program * getProgram()
void setNumSegmentsPerUnitLength(agx::Real segmentsPerUnitLength)
Assign how many cylinder segments that should be used per unit length.
AGXCORE_EXPORT Component * root()
osg::Uniform * getCircleNormalUniform()
const osg::Uniform * getCircleNormalUniform() const
osg::ref_ptr< osg::Uniform > m_circleNormalUniform
osg::ref_ptr< osg::Uniform > m_useRedShiftUniform
osg::FloatArray * m_redShiftArray