161 double a_radiusContact);
176 void setShow(
bool a_showProxy =
true,
177 bool a_showGoal =
false,
Implements a finger-proxy force rendering algorithm.
Implements a force algorithm for modeling haptic effects.
Implements an audio device for listening to audio sources.
Implements a base class for all objects.
Implementation of a 3D shape sphere object.
This class implements a finger-proxy force rendering algorithm.
Definition CAlgorithmFingerProxy.h:87
int getNumCollisionEvents()
This method return the number of collision events (0, 1, 2 or 3):
Definition CAlgorithmFingerProxy.h:151
cCollisionEvent * m_collisionEvents[3]
Table of collision events (0-3). Call getNumCollisionEvents() to see how many are actually valid.
Definition CAlgorithmFingerProxy.h:161
This class implements a force algorithms for handling all haptic effects associated with objects.
Definition CAlgorithmPotentialField.h:80
cInteractionRecorder m_interactionRecorder
Interaction recorder.
Definition CAlgorithmPotentialField.h:114
This class implements an audio device context.
Definition CAudioDevice.h:82
This class implements an audio source.
Definition CAudioSource.h:79
This class implements a base class for all 2D or 3D objects in CHAI3D.
Definition CGenericObject.h:113
This class implements a haptic point on a tool.
Definition CHapticPoint.h:98
cShapeSphere * m_sphereProxy
Sphere object used for rendering the proxy position.
Definition CHapticPoint.h:249
cAudioSource * m_audioSourceFriction[3]
Optional audio source for rendering sound friction.
Definition CHapticPoint.h:310
cAlgorithmFingerProxy * m_algorithmFingerProxy
Finger-proxy algorithm used for modeling contacts with cMesh objects.
Definition CHapticPoint.h:236
void setRadiusContact(double a_radiusContact)
This method sets the radius size of the physical proxy.
Definition CHapticPoint.cpp:309
bool isInContact(cGenericObject *a_object)
This method checks if the tool is touching a particular object.
Definition CHapticPoint.cpp:584
cInteractionEvent * getInteractionEvent(const int a_index)
Definition CHapticPoint.h:207
virtual ~cHapticPoint()
Destructor of cHapticPoint.
Definition CHapticPoint.cpp:116
void updateSpherePositions()
This method updates the position of the spheres (proxy and goal) in local tool coordinates.
Definition CHapticPoint.cpp:697
void setShow(bool a_showProxy=true, bool a_showGoal=false, cColorf a_colorLine=cColorf(0.5, 0.5, 0.5))
This method sets the display options of the goal and proxy spheres.
Definition CHapticPoint.cpp:347
double m_radiusContact
Radius used to model the physical radius of the proxy.
Definition CHapticPoint.h:294
void initialize()
This method resets the haptic point to the current position of the haptic device.
Definition CHapticPoint.cpp:220
void render(cRenderOptions &a_options)
This method renders the haptic point graphically using OpenGL.
Definition CHapticPoint.cpp:640
cVector3d getLocalPosProxy()
This method returns the current proxy position of the haptic point in local tool coordinates.
Definition CHapticPoint.cpp:199
double m_radiusDisplay
Radius used for rendering the proxy and goal spheres.
Definition CHapticPoint.h:291
cAudioSource * m_audioSourceImpact[3]
Optional audio source for rendering sound impacts with environment.
Definition CHapticPoint.h:307
int getNumCollisionEvents()
Definition CHapticPoint.h:191
cVector3d getGlobalPosGoal()
This method returns the current desired goal position of the haptic point in world coordinates.
Definition CHapticPoint.cpp:148
int getNumInteractionEvents()
Definition CHapticPoint.h:204
cVector3d getLocalPosGoal()
This method returns the current desired goal position of the haptic point in local tool coordinates.
Definition CHapticPoint.cpp:176
cVector3d m_lastComputedGlobalForce
Last computed interaction force [N] in world global coordinates.
Definition CHapticPoint.h:288
void setRadiusDisplay(double a_radiusDisplay)
This method sets the radius size of the sphere used to display the proxy and goal position.
Definition CHapticPoint.cpp:326
virtual std::string getClassName()
This method returns the name of the object class.
Definition CHapticPoint.h:119
cAlgorithmPotentialField * m_algorithmPotentialField
Potential field algorithm used for modeling interaction forces with objects that have haptic effects ...
Definition CHapticPoint.h:239
cColorf m_colorLine
Color of the display line that connects both spheres (proxy and goal).
Definition CHapticPoint.h:255
bool m_useAudioSources
If true then audio sources are enabled.
Definition CHapticPoint.h:313
double getRadiusContact()
This method returns the radius size of the physical proxy.
Definition CHapticPoint.h:167
cGenericTool * m_parentTool
Parent tool.
Definition CHapticPoint.h:285
cGenericObject * m_audioProxyContacts[3]
Pointers to mesh objects for which the proxy was last in contact with.
Definition CHapticPoint.h:316
cShapeSphere * m_sphereGoal
Sphere object used for rendering the goal position.
Definition CHapticPoint.h:252
cCollisionEvent * getCollisionEvent(const int a_index)
Definition CHapticPoint.h:194
cVector3d getGlobalPosProxy()
This method returns the the current proxy position of the haptic point in world coordinates.
Definition CHapticPoint.cpp:162
cVector3d getLastComputedForce()
This method returns the last computed force in global world coordinates.
Definition CHapticPoint.h:223
double getRadiusDisplay()
This method returns the display radius size of the proxy and goal spheres.
Definition CHapticPoint.h:173
void setRadius(double a_radius)
This method sets the radius size of the haptic point.
Definition CHapticPoint.cpp:260
bool createAudioSource(cAudioDevice *a_audioDevice)
This method Create an audio source for this haptic point.
Definition CHapticPoint.cpp:365
cVector3d computeInteractionForces(cVector3d &a_globalPos, cMatrix3d &a_globalRot, cVector3d &a_globalLinVel, cVector3d &a_globalAngVel)
This method computes all interaction forces between the haptic point and the virtual environment.
Definition CHapticPoint.cpp:407
cGenericTool * getParentTool()
This method returns a pointer to the parent tool.
Definition CHapticPoint.h:135
cGenericObject * m_meshProxyContacts[3]
Pointer to mesh objects for which the proxy is in contact with.
Definition CHapticPoint.h:297
std::vector< cInteractionEvent > m_interactions
List of interaction events stored in recorder.
Definition CInteractionBasics.h:168
This class implements a 3D shape sphere.
Definition CShapeSphere.h:87
Definition CAudioBuffer.cpp:57
This structure stores the data related to a collision event.
Definition CCollisionBasics.h:92
This class defines a color using a GLfloat representation for each component.
Definition CColor.h:139
This structure stores information associated with the interaction of a haptic tool with a shape primi...
Definition CInteractionBasics.h:88
This class implements a 3D matrix.
Definition CMatrix3d.h:98
This structures provide a containers for storing rendering options that are passed through the sceneg...
Definition CRenderOptions.h:83
This class implements a 3D vector.
Definition CVector3d.h:89