convert line ends
[canaan.git] / prj / cam / src / actreact / stimul8r.h
blob260b32dcec923089e9e2853b839ad204f5fe93a1
1 /*
2 @Copyright Looking Glass Studios, Inc.
3 1996,1997,1998,1999,2000 Unpublished Work.
4 */
6 // $Header: r:/t2repos/thief2/src/actreact/stimul8r.h,v 1.5 2000/01/29 12:44:50 adurant Exp $
7 #pragma once
9 #ifndef __STIMUL8R_H
10 #define __STIMUL8R_H
12 #include <comtools.h>
13 #include <stimtype.h>
14 #include <senstype.h>
15 #include <reactype.h>
17 ////////////////////////////////////////////////////////////
18 // OBJECT STIMULATION API
20 // This interface is presented by the Act/React Object System layer for use by the
21 // Act/React Propagation system. It is the path by which stimulus sensors
22 // are notified of stimulus events that hit them.
25 typedef void* tStimFilterData;
26 typedef eReactionResult (* tStimFilterFunc)(sStimEvent* event, tStimFilterData data);
27 typedef ulong tStimFilterID;
29 F_DECLARE_INTERFACE(IStimulator);
31 #undef INTERFACE
32 #define INTERFACE IStimulator
33 DECLARE_INTERFACE_(IStimulator,IUnknown)
35 DECLARE_UNKNOWN_PURE();
38 // Send a stimulus event to a sensor
40 STDMETHOD(StimulateSensor)(THIS_ StimSensorID sensor, const sStimEvent* event) PURE;
43 // Describe the sensitive intensity range of an object
44 // returns S_FALSE if the object is not sensitive to that stimulus
46 STDMETHOD(GetSensitivity)(THIS_ StimSensorID id, sStimSensitivity* sensitivity) PURE;
49 // Look up the position of a sensor
51 STDMETHOD_(const sStimPosition*, GetSensorPosition)(THIS_ StimSensorID id) PURE;
54 // Update Frame
56 STDMETHOD(UpdateFrame)(THIS_ tStimTimeStamp time, tStimDuration dt) PURE;
59 // Add a "filter" callback for stimulus events. The filter is called before
60 // the event is applied to the sensor. The filter may mutate the event.
62 STDMETHOD_(tStimFilterID,AddFilter)(THIS_ tStimFilterFunc func, tStimFilterData data) PURE;
63 STDMETHOD(RemoveFilter)(THIS_ tStimFilterID id) PURE;
67 #undef INTERFACE
69 EXTERN void StimulatorCreate(void);
71 #endif // __STIMUL8R_H