|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||
java.lang.Objectdasher.CDasherComponent
dasher.CDasherModule
dasher.CDasherInput
public abstract class CDasherInput
DasherInput is the base class for all modules which provide some sort of co-ordinate input.
To serve as a co-ordinate source, a device must be able to provide synchronous or quasi-synchronous readout of its current co-ordinates, such that a call to GetCoordinates will return almost instantaneously.
Devices are free to return their co-ordinates relative to the screen, using pixels as their unit of measure, or relative to the Dasher world, using Dasher co-ordinates.
CDasherModule| Field Summary |
|---|
| Fields inherited from class dasher.CDasherComponent |
|---|
m_EventHandler, m_SettingsStore |
| Constructor Summary | |
|---|---|
CDasherInput(CEventHandler EventHandler,
CSettingsStore SettingsStore,
long iID,
int iType,
java.lang.String szName)
Sole constructor. |
|
| Method Summary | |
|---|---|
void |
Activate()
Activates the input device. |
void |
Deactivate()
Deactivates the device; resources should be freed at this point. |
abstract int |
GetCoordinateCount()
Gets the number of co-ordinates this device returns. |
abstract int |
GetCoordinates(int iN,
long[] Coordinates)
Called to request that the device report the current co-ordinates. |
void |
SetMaxCoordinates(int iN,
long[] iDasherMax)
Sets the maximum co-ordinates which the device should return. |
| Methods inherited from class dasher.CDasherModule |
|---|
GetID, GetName, GetType, Ref, Unref |
| Methods inherited from class dasher.CDasherComponent |
|---|
GetBoolParameter, GetLongParameter, GetParameterName, GetParameterType, GetStringParameter, HandleEvent, InsertEvent, SetBoolParameter, SetLongParameter, SetStringParameter, UnregisterComponent |
| Methods inherited from class java.lang.Object |
|---|
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait |
| Constructor Detail |
|---|
public CDasherInput(CEventHandler EventHandler,
CSettingsStore SettingsStore,
long iID,
int iType,
java.lang.String szName)
EventHandler - Event handler with which we wish to register ourselvesSettingsStore - Settings store for parameter getting/settingiID - This device's IDiType - This device's type numberszName - Friendly name for this device, to be used with GetModuleByName| Method Detail |
|---|
public void SetMaxCoordinates(int iN,
long[] iDasherMax)
iN - Number of co-ordinates specifiediDasherMax - Maximum co-ordinates.
public abstract int GetCoordinates(int iN,
long[] Coordinates)
iN - Number of co-ordinates expected.Coordinates - Fill with the current co-ordinates
public abstract int GetCoordinateCount()
At present, only 1- and 2-axis devices are accepted, but this may be easily upgraded in the future.
public void Activate()
public void Deactivate()
|
||||||||||
| PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
| SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD | |||||||||