In this manner, an application designed for your hardware can use the second effect descriptor to access the full capabilities of the effect, whereas an application designed for generic hardware can use the first effect descriptor to access basic capabilities of the effect. Create a special type-specific structure (such as DIPERIODICFORCEWITHDECAY) that contains the extra parameters. List the effect under the DIEFT_HARDWARE category.
If an application creates the effect in the predefined category, the driver should provide suitable defaults for the specified parameters that are not part of the standard type-specific data structure. List the effect under the predefined category. In these cases, the effect should be listed twice as follows:
For information about these structures, see the DirectInput section of the DirectX Software Development Kit (SDK). If a device supports a hardware effect that does not fall into any of the predefined categories (DIEFT_CONSTANTFORCE, DIEFT_RAMPFORCE, DIEFT_PERIODIC, DIEFT_CONDITION, or DIEFT_CUSTOMFORCE), then the DIEFFECTATTRIBUTES structure for the effect should specify DIEFT_HARDWARE as the effect type.Ī device can support a hardware effect that falls into one of the predefined categories (listed in the preceding paragraph) but also receive additional parameters that are not part of the standard type-specific data structures (DICONSTANTFORCE, DIRAMPFORCE, DIPERIODIC, DICONDITION, or DICUSTOMFORCE). A value is added to indicate that the Human Interface Device (HID) provides the driver interface when that is implemented. If the VJoyD value is present, it should be a zero-length binary value, which indicates that the VJoyD minidriver associated with the device to be used should provide extra callbacks for the driver interface.
The name of each subkey is a globally unique identifier (GUID) in the form "" for the COM object that provides the driver interface. Under the Effects subkey is a list of subkeys, one for each effect. Under this key is an Effects subkey that contains two values for each effect. The latter complements the existing OEMName value that holds the name of the device.Ī new OEMForceFeedback key has been defined to hold force feedback specific keys and values. The two generic values are a binary value containing version information and a Manufacturer string value (REGSTR_VAL_MANUFACTURER in regstr.h ) containing a string for the manufacturer's name. In addition to the values defined for existing joystick devices, two new optional generic values and a set of force feedback specific values have been defined. The data stored under this OEM-specific key is initialized when the device is first installed and then used for reference purposes only. New joystick registry entries are found under an OEM-specific key that is installed for each joystick device type under the key with the registry path HKEY_LOCAL_MACHINE\System\CurrentControlSet\Control\MediaProperties\PrivateProperties\Joystick\OEM. This section covers the interface between DirectInput and the device-specific force feedback driver.