Controller Data Structure
You use a controller data structure to specify information when creating a new controller object. A controller data structure is defined by theTQ3ControllerData
data type.
typedef struct TQ3ControllerData { char *signature; unsigned long valueCount; unsigned long channelCount; TQ3ChannelGetMethod channelGetMethod; TQ3ChannelSetMethod channelSetMethod; } TQ3ControllerData;
Field Description
signature
- The controller's signature. A signature is a null-terminated C string that uniquely identifies the manufacturer and model of a controller device. You are responsible for defining your controller's signature.
valueCount
- The number of values supported by the controller.
channelCount
- The number of channels supported by the controller. If the value in this field is greater than 0, you may define optional routines that get and set those channels.
channelGetMethod
- A pointer to a controller's channel-getting method. See page 18-47 for information on this method. This field is valid only if the value in the
channelCount
field is greater than 0. You may, however, passNULL
in this field if the controller cannot report the current channels.channelSetMethod
- A pointer to a controller's channel-setting method. See page 18-48 for information on this method. This field is valid only if the value in the
channelCount
field is greater than 0. You may, however, passNULL
in this field if the controller cannot set the channels.
Main | Top of Section | What's New | Apple Computer, Inc. | Find It | Feedback | Help