H3D::HLThread Class Reference

HLThread is a singleton class providing an interface to the scheduler and thread running when using OpenHaptics and HD API. More...

#include <Threads.h>

Inheritance diagram for H3D::HLThread:

Inheritance graph
List of all members.

Public Member Functions

bool isActive ()
 If the hd scheduler has been started true is returned.
void setActive (bool _active)
 Set the flag indicating if the hd scheduler has been started or not.
virtual void synchronousCallback (CallbackFunc func, void *data)
 Add a callback function to be executed in this thread.
virtual void asynchronousCallback (CallbackFunc func, void *data)
 Add a callback function to be executed in this thread.

Static Public Member Functions

static HLThreadgetInstance ()
 Get the singleton instance of HLThread.

Static Protected Member Functions

static PeriodicThread::CallbackCode setThreadId (void *_data)

Protected Attributes

bool is_active

Static Protected Attributes

static HLThreadsingleton = new HLThread

Detailed Description

HLThread is a singleton class providing an interface to the scheduler and thread running when using OpenHaptics and HD API.

It is used by the HLHapticsDevice and uses its own thread handling. Since only one instance of the HD API scheduler exists it is a singleton class.


Member Function Documentation

void HLThread::asynchronousCallback CallbackFunc  func,
void *  data
[virtual]
 

Add a callback function to be executed in this thread.

The calling thread will continue executing after adding the callback and will not wait for the callback function to execute.

void HLThread::synchronousCallback CallbackFunc  func,
void *  data
[virtual]
 

Add a callback function to be executed in this thread.

The calling thread will wait until the callback function has returned before continuing.


Generated on Thu Aug 24 12:40:10 2006 for H3D API by  doxygen 1.4.5