Macros

This section describes the following macros used in DirectInput:

·DIDFT_GETINSTANCE

·DIDFT_GETTYPE

·DIEFT_GETTYPE

·DISEQUENCE_COMPARE

·GET_DIDEVICE_SUBTYPE

·GET_DIDEVICE_TYPE

·DIMAKEUSAGEDWORD

Dinput.h also defines macros for C calls to all the methods of the IDirectInput and IDirectInputDevice interfaces. These macros eliminate the need for pointers to method tables. For example, here is a C call to the IDirectInputDevice::Release method:

lpdid->lpVtbl->Release(lpdid));

The equivalent macro call looks like this:

IDirectInputDevice_Release(lpdid);

All these macros take the same parameters as the method calls themselves.