18 #ifndef BVHNODEFORCETORQUE_H
19 #define BVHNODEFORCETORQUE_H
23 #include <yarp/sig/Vector.h>
24 #include <yarp/os/BufferedPort.h>
59 glColor4f(0.4,0.4,1.0,1.0);
61 glTranslated(0.0,0.0,15.0);
62 gluDisk(
cyl,0.0,27.5,16,16);
63 gluCylinder(
cyl,27.5,27.5,18.0,16,16);
64 glTranslated(0.0,0.0,18.0);
65 gluDisk(
cyl,0.0,27.5,16,16);
66 glTranslated(0.0,0.0,-9.0);
68 glDisable(GL_DEPTH_TEST);
70 if (
mPort.getInputCount()>0)
72 yarp::sig::Vector *ft=
mPort.read(
false);
74 if (ft)
for (
int i=0; i<6; ++i)
dForceTorque[i]=(*ft)[i];
84 glColor4f(1.0,0.0,0.0,1.0);
85 glRotated(90.0,0.0,1.0,0.0);
90 glColor4f(0.0,1.0,0.0,1.0);
92 glRotated(-90.0,1.0,0.0,0.0);
97 glColor4f(0.0,0.0,1.0,1.0);
105 glDisable(GL_LINE_SMOOTH);
108 glColor4f(1.0,0.0,0.0,1.0);
110 glRotated(90.0,0.0,1.0,0.0);
115 glColor4f(0.0,1.0,0.0,1.0);
117 glRotated(-90.0,1.0,0.0,0.0);
118 glRotated(180.0,0.0,0.0,10.0);
123 glColor4f(0.0,0.0,1.0,1.0);
125 glRotated(180.0,0.0,0.0,10.0);
131 glEnable(GL_LINE_SMOOTH);
133 glEnable(GL_DEPTH_TEST);
139 yarp::os::BufferedPort<yarp::sig::Vector>
mPort;
void drawArc(double dOmega)
void drawArrow(double dMag)
virtual ~BVHNodeForceTorque()
yarp::os::BufferedPort< yarp::sig::Vector > mPort
BVHNodeForceTorque(const QString &name, const QString &portName, int enc, double a, double d, double alpha, double theta0, iCubMesh *mesh=0)
const QString & name() const