1SoSensor(3IV)()                                                SoSensor(3IV)()
2
3
4

NAME

6       SoSensor — abstract base class for Inventor sensors
7

INHERITS FROM

9       SoSensor
10

SYNOPSIS

12       #include <Inventor/sensors/SoSensor.h>
13
14     typedef void        SoSensorCB(void *data, SoSensor *sensor)
15
16          Methods from class SoSensor:
17
18     void                setFunction(SoSensorCB *callbackFunction)
19     SoSensorCB *        getFunction() const
20     void                setData(void *callbackData)
21     void *              getData() const
22
23

DESCRIPTION

25       Sensors detect changes either to time or to Inventor objects in a scene
26       graph, and call a user-defined callback function. Sensors are scheduled
27       when  the  thing  they are attached to changes, and sometime after they
28       are scheduled they are triggered, calling the user's callback function.
29

METHODS

31     void                setFunction(SoSensorCB *callbackFunction)
32          Sets the callback function that is called when the sensor  is  trig‐
33          gered. The function must take two arguments — user-supplied callback
34          data (of type void *) and a pointer to the sensor that is triggering
35          the function (of type SoSensor *).
36
37     SoSensorCB *        getFunction() const
38          Returns the callback function that will be called when the sensor is
39          triggered.
40
41     void                setData(void *callbackData)
42          Sets the callback data passed to the callback function.
43
44     void *              getData() const
45          Returns the user-supplied pointer that will be passed to  the  call‐
46          back function.
47
48

SEE ALSO

50       SoAlarmSensor, SoDataSensor, SoFieldSensor, SoIdleSensor, SoNodeSensor,
51       SoPathSensor, SoSensorManager
52
53
54
55
56                                                               SoSensor(3IV)()
Impressum