SDL_OpenHaptic

Open a haptic device for use.

The index passed as an argument refers to the N'th haptic device on this system.

When opening a haptic device, its gain will be set to maximum and autocenter will be disabled. To modify these values use SDL_SetHapticGain() and SDL_SetHapticAutocenter().

\param instance_id the haptic device instance ID. \returns the device identifier or NULL on failure; call SDL_GetError() for more information.

\since This function is available since SDL 3.2.0.

\sa SDL_CloseHaptic \sa SDL_GetHaptics \sa SDL_OpenHapticFromJoystick \sa SDL_OpenHapticFromMouse \sa SDL_SetHapticAutocenter \sa SDL_SetHapticGain

extern (C) nothrow @nogc extern
SDL_OpenHaptic

Meta