AnimatLab  2
Test
OsgPrismaticLimit.h
1 
2 #pragma once
3 
4 namespace OsgAnimatSim
5 {
6  namespace Environment
7  {
8  namespace Joints
9  {
10 
11  class ANIMAT_OSG_PORT OsgPrismaticLimit
12  {
13  protected:
14  ConstraintLimit *m_lpThisLimit;
15 
16  osg::ref_ptr<osg::Geometry> m_osgCylinder;
17  osg::ref_ptr<osg::Geode> m_osgCylinderGeode;
18  osg::ref_ptr<osg::MatrixTransform> m_osgCylinderMT;
19  osg::ref_ptr<osg::Material> m_osgCylinderMat;
20  osg::ref_ptr<osg::StateSet> m_osgCylinderSS;
21 
22  osg::ref_ptr<osg::Geometry> m_osgBox;
23  osg::ref_ptr<osg::MatrixTransform> m_osgBoxMT;
24  osg::ref_ptr<osg::Material> m_osgBoxMat;
25  osg::ref_ptr<osg::StateSet> m_osgBoxSS;
26 
27  public:
29  virtual ~OsgPrismaticLimit();
30 
31  virtual void LimitAlpha(float fltA);
32  virtual void SetLimitPos(float fltRadius);
33 
34  virtual void SetConstraintLimit(ConstraintLimit *lpLimit) {m_lpThisLimit = lpLimit;};
35 
36  osg::Geometry *BoxGeometry();
37  osg::MatrixTransform *BoxMT();
38  osg::Material *BoxMat();
39  osg::StateSet *BoxSS();
40 
41  osg::Geometry *CylinderGeometry();
42  osg::MatrixTransform *CylinderMT();
43  osg::Material *CylinderMat();
44  osg::StateSet *CylinderSS();
45 
46  virtual void SetupLimitGraphics(float fltBoxSize, float fltRadius);
47  virtual void DeleteLimitGraphics();
48  };
49 
50  } // Joints
51  } // Environment
52 } //OsgAnimatSim
Classes for implementing the cm-labs vortex physics engine for AnimatLab.