Base Input Module. More...
#include <deBaseInputModule.h>
Public Member Functions | |
Constructors and Destructors | |
| deBaseInputModule (deLoadableModule *loadableModule) | |
| Creates a new module. | |
| virtual | ~deBaseInputModule () |
| Cleans up the module. | |
Module Management | |
| virtual bool | Init ()=0 |
| Called to init the module. | |
| virtual void | CleanUp ()=0 |
| Called to cleanup the module. | |
Device Management | |
| virtual int | GetDeviceCount ()=0 |
| Retrieves the count of devices present on the host system. | |
| virtual deBaseInputDevice * | OpenDevice (int index)=0 |
| Retrieves informations about the device at the given index. | |
Events | |
| virtual void | ProcessEvents ()=0 |
| Check message or event queues. | |
| virtual bool | GetEvent (deInputEvent *event)=0 |
| Retrieves the next event put aside by the preceeding ProcessEvents call. | |
| virtual void | ClearEvents ()=0 |
| Clears the event queue removing all queued events. | |
Base Input Module.
Input modules provide the engine with input from devices on the host computer.
| deBaseInputModule::deBaseInputModule | ( | deLoadableModule * | loadableModule ) |
Creates a new module.
| virtual deBaseInputModule::~deBaseInputModule | ( | ) | [virtual] |
Cleans up the module.
| virtual void deBaseInputModule::CleanUp | ( | ) | [pure virtual] |
Called to cleanup the module.
| virtual void deBaseInputModule::ClearEvents | ( | ) | [pure virtual] |
Clears the event queue removing all queued events.
This is called after a detected engine error to avoid strange behaviour once the engine is brought back up running. Can also be called at other places if a long time duration causes most events to be unusable.
| virtual int deBaseInputModule::GetDeviceCount | ( | ) | [pure virtual] |
Retrieves the count of devices present on the host system.
| virtual bool deBaseInputModule::GetEvent | ( | deInputEvent * | event ) | [pure virtual] |
Retrieves the next event put aside by the preceeding ProcessEvents call.
| event | Buffer to write event to |
| virtual bool deBaseInputModule::Init | ( | ) | [pure virtual] |
Called to init the module.
Returns true on success. To access the os object of the engine use the GetOS function.
| virtual deBaseInputDevice* deBaseInputModule::OpenDevice | ( | int | index ) | [pure virtual] |
Retrieves informations about the device at the given index.
| virtual void deBaseInputModule::ProcessEvents | ( | ) | [pure virtual] |
Check message or event queues.
This function is called before any other frame related tasks are carried out. You are expected to check message and event queues to deliver system notification ( like quitting the game ) to the game engine.
1.7.2