{-# LANGUAGE ForeignFunctionInterface #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE NoFieldSelectors #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_HADDOCK prune #-}

module SDL3.Sys.Bindgen.Haptic.Safe (
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_GetHaptics,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_GetHapticNameForID,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_OpenHaptic,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_GetHapticFromID,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_GetHapticID,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_GetHapticName,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_IsMouseHaptic,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_OpenHapticFromMouse,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_IsJoystickHaptic,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_OpenHapticFromJoystick,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_CloseHaptic,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_GetMaxHapticEffects,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_GetMaxHapticEffectsPlaying,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_GetHapticFeatures,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_GetNumHapticAxes,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_HapticEffectSupported,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_CreateHapticEffect,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_UpdateHapticEffect,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_RunHapticEffect,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_StopHapticEffect,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_DestroyHapticEffect,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_GetHapticEffectStatus,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_SetHapticGain,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_SetHapticAutocenter,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_PauseHaptic,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_ResumeHaptic,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_StopHapticEffects,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_HapticRumbleSupported,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_InitHapticRumble,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_PlayHapticRumble,
  SDL3.Sys.Bindgen.Haptic.Safe.sDL_StopHapticRumble,
)
where

import Prelude (IO, fmap)

import HsBindgen.Runtime.LibC qualified
import HsBindgen.Runtime.PtrConst qualified as PtrConst
import HsBindgen.Runtime.Support qualified as BG
import HsBindgen.Runtime.Support.CAPI qualified
import SDL3.Sys.Bindgen.Haptic
import SDL3.Sys.Bindgen.Joystick qualified
import SDL3.Sys.Bindgen.Stdinc qualified

$( HsBindgen.Runtime.Support.CAPI.addCSource
     ( HsBindgen.Runtime.Support.CAPI.unlines
         [ "#define SDL_MAIN_HANDLED"
         , "#define SDL_SLOW_MEMCPY"
         , "#define SDL_SLOW_MEMMOVE"
         , "#define SDL_SLOW_MEMSET"
         , "#include <SDL3/SDL_haptic.h>"
         , "SDL_HapticID *hs_bindgen_0fa1139acd663b7b ("
         , "  signed int *arg1"
         , ")"
         , "{"
         , "  return (SDL_GetHaptics)(arg1);"
         , "}"
         , "char const *hs_bindgen_9314d546163bea9b ("
         , "  SDL_HapticID arg1"
         , ")"
         , "{"
         , "  return (SDL_GetHapticNameForID)(arg1);"
         , "}"
         , "SDL_Haptic *hs_bindgen_dbff4b31baeb7b51 ("
         , "  SDL_HapticID arg1"
         , ")"
         , "{"
         , "  return (SDL_OpenHaptic)(arg1);"
         , "}"
         , "SDL_Haptic *hs_bindgen_1785e32cd90d0d06 ("
         , "  SDL_HapticID arg1"
         , ")"
         , "{"
         , "  return (SDL_GetHapticFromID)(arg1);"
         , "}"
         , "SDL_HapticID hs_bindgen_de8498981e0f6223 ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  return (SDL_GetHapticID)(arg1);"
         , "}"
         , "char const *hs_bindgen_360c0a89e793b7ad ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  return (SDL_GetHapticName)(arg1);"
         , "}"
         , "_Bool hs_bindgen_4c4f92c17cae6f18 (void)"
         , "{"
         , "  return (SDL_IsMouseHaptic)();"
         , "}"
         , "SDL_Haptic *hs_bindgen_8e6b94caa3e52d98 (void)"
         , "{"
         , "  return (SDL_OpenHapticFromMouse)();"
         , "}"
         , "_Bool hs_bindgen_c5f4f376b01c2e4f ("
         , "  SDL_Joystick *arg1"
         , ")"
         , "{"
         , "  return (SDL_IsJoystickHaptic)(arg1);"
         , "}"
         , "SDL_Haptic *hs_bindgen_01eda3f2b59f9aab ("
         , "  SDL_Joystick *arg1"
         , ")"
         , "{"
         , "  return (SDL_OpenHapticFromJoystick)(arg1);"
         , "}"
         , "void hs_bindgen_f6f5492f48ba2e5b ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  (SDL_CloseHaptic)(arg1);"
         , "}"
         , "signed int hs_bindgen_366d199432bdd8e0 ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  return (SDL_GetMaxHapticEffects)(arg1);"
         , "}"
         , "signed int hs_bindgen_5bf116c6af24ad82 ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  return (SDL_GetMaxHapticEffectsPlaying)(arg1);"
         , "}"
         , "Uint32 hs_bindgen_13fda9a87e4ece91 ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  return (SDL_GetHapticFeatures)(arg1);"
         , "}"
         , "signed int hs_bindgen_7ed42e0a43315641 ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  return (SDL_GetNumHapticAxes)(arg1);"
         , "}"
         , "_Bool hs_bindgen_5f13cffbd392579e ("
         , "  SDL_Haptic *arg1,"
         , "  SDL_HapticEffect const *arg2"
         , ")"
         , "{"
         , "  return (SDL_HapticEffectSupported)(arg1, arg2);"
         , "}"
         , "#include <SDL3/SDL_version.h>"
         , "#if !SDL_VERSION_ATLEAST(3, 4, 0)"
         , "typedef int SDL_HapticEffectID;"
         , "#endif"
         , "SDL_HapticEffectID hs_bindgen_15baa0f4a78836ae ("
         , "  SDL_Haptic *arg1,"
         , "  SDL_HapticEffect const *arg2"
         , ")"
         , "{"
         , "  return (SDL_CreateHapticEffect)(arg1, arg2);"
         , "}"
         , "#include <SDL3/SDL_version.h>"
         , "#if !SDL_VERSION_ATLEAST(3, 4, 0)"
         , "typedef int SDL_HapticEffectID;"
         , "#endif"
         , "_Bool hs_bindgen_0492468c6fb17ac5 ("
         , "  SDL_Haptic *arg1,"
         , "  SDL_HapticEffectID arg2,"
         , "  SDL_HapticEffect const *arg3"
         , ")"
         , "{"
         , "  return (SDL_UpdateHapticEffect)(arg1, arg2, arg3);"
         , "}"
         , "#include <SDL3/SDL_version.h>"
         , "#if !SDL_VERSION_ATLEAST(3, 4, 0)"
         , "typedef int SDL_HapticEffectID;"
         , "#endif"
         , "_Bool hs_bindgen_a614a05d61f4001a ("
         , "  SDL_Haptic *arg1,"
         , "  SDL_HapticEffectID arg2,"
         , "  Uint32 arg3"
         , ")"
         , "{"
         , "  return (SDL_RunHapticEffect)(arg1, arg2, arg3);"
         , "}"
         , "#include <SDL3/SDL_version.h>"
         , "#if !SDL_VERSION_ATLEAST(3, 4, 0)"
         , "typedef int SDL_HapticEffectID;"
         , "#endif"
         , "_Bool hs_bindgen_62c7aa3038b74c27 ("
         , "  SDL_Haptic *arg1,"
         , "  SDL_HapticEffectID arg2"
         , ")"
         , "{"
         , "  return (SDL_StopHapticEffect)(arg1, arg2);"
         , "}"
         , "#include <SDL3/SDL_version.h>"
         , "#if !SDL_VERSION_ATLEAST(3, 4, 0)"
         , "typedef int SDL_HapticEffectID;"
         , "#endif"
         , "void hs_bindgen_6ebf1b15d73c024c ("
         , "  SDL_Haptic *arg1,"
         , "  SDL_HapticEffectID arg2"
         , ")"
         , "{"
         , "  (SDL_DestroyHapticEffect)(arg1, arg2);"
         , "}"
         , "#include <SDL3/SDL_version.h>"
         , "#if !SDL_VERSION_ATLEAST(3, 4, 0)"
         , "typedef int SDL_HapticEffectID;"
         , "#endif"
         , "_Bool hs_bindgen_8953e9e35530a132 ("
         , "  SDL_Haptic *arg1,"
         , "  SDL_HapticEffectID arg2"
         , ")"
         , "{"
         , "  return (SDL_GetHapticEffectStatus)(arg1, arg2);"
         , "}"
         , "_Bool hs_bindgen_33d36e11c46c206d ("
         , "  SDL_Haptic *arg1,"
         , "  signed int arg2"
         , ")"
         , "{"
         , "  return (SDL_SetHapticGain)(arg1, arg2);"
         , "}"
         , "_Bool hs_bindgen_713374147201159e ("
         , "  SDL_Haptic *arg1,"
         , "  signed int arg2"
         , ")"
         , "{"
         , "  return (SDL_SetHapticAutocenter)(arg1, arg2);"
         , "}"
         , "_Bool hs_bindgen_d4344f317b2d7325 ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  return (SDL_PauseHaptic)(arg1);"
         , "}"
         , "_Bool hs_bindgen_79c16f8418a90f86 ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  return (SDL_ResumeHaptic)(arg1);"
         , "}"
         , "_Bool hs_bindgen_f452836b38dc6590 ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  return (SDL_StopHapticEffects)(arg1);"
         , "}"
         , "_Bool hs_bindgen_113ac21fbd9de22e ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  return (SDL_HapticRumbleSupported)(arg1);"
         , "}"
         , "_Bool hs_bindgen_ae32c683da240a6e ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  return (SDL_InitHapticRumble)(arg1);"
         , "}"
         , "_Bool hs_bindgen_10fe16fce6a60bfe ("
         , "  SDL_Haptic *arg1,"
         , "  float arg2,"
         , "  Uint32 arg3"
         , ")"
         , "{"
         , "  return (SDL_PlayHapticRumble)(arg1, arg2, arg3);"
         , "}"
         , "_Bool hs_bindgen_2b55fdb7a5a8262a ("
         , "  SDL_Haptic *arg1"
         , ")"
         , "{"
         , "  return (SDL_StopHapticRumble)(arg1);"
         , "}"
         ]
     )
 )

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHaptics@
foreign import ccall safe "hs_bindgen_0fa1139acd663b7b"
  hs_bindgen_0fa1139acd663b7b_base
    :: BG.Ptr BG.Void
    -> IO (BG.Ptr BG.Void)

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHaptics@
hs_bindgen_0fa1139acd663b7b
  :: BG.Ptr BG.CInt
  -> IO (BG.Ptr SDL_HapticID)
hs_bindgen_0fa1139acd663b7b :: Ptr CInt -> IO (Ptr SDL_HapticID)
hs_bindgen_0fa1139acd663b7b =
  \Ptr CInt
x0 ->
    (Ptr Void -> Ptr SDL_HapticID)
-> IO (Ptr Void) -> IO (Ptr SDL_HapticID)
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap Ptr Void -> Ptr SDL_HapticID
FFIType (Ptr SDL_HapticID) -> Ptr SDL_HapticID
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO (Ptr Void)
hs_bindgen_0fa1139acd663b7b_base (Ptr CInt -> FFIType (Ptr CInt)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr CInt
x0))

-- | Get a list of currently connected haptic devices.
--
--     [Returns]: a 0 terminated array of haptic device instance IDs or NULL on failure; call SDL_GetError() for more information. This should be freed with SDL_free() when it is no longer needed.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_OpenHaptic'
--
--     [C declaration]: @SDL_GetHaptics@, defined at @SDL3\/SDL_haptic.h 975:44@
sDL_GetHaptics
  :: BG.Ptr BG.CInt
  -- ^
  --
  --           [@count@]: a pointer filled in with the number of haptic devices returned, may be NULL.
  -> IO (BG.Ptr SDL_HapticID)
sDL_GetHaptics :: Ptr CInt -> IO (Ptr SDL_HapticID)
sDL_GetHaptics = Ptr CInt -> IO (Ptr SDL_HapticID)
hs_bindgen_0fa1139acd663b7b

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHapticNameForID@
foreign import ccall safe "hs_bindgen_9314d546163bea9b"
  hs_bindgen_9314d546163bea9b_base
    :: HsBindgen.Runtime.LibC.Word32
    -> IO (BG.Ptr BG.Void)

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHapticNameForID@
hs_bindgen_9314d546163bea9b
  :: SDL_HapticID
  -> IO (PtrConst.PtrConst BG.CChar)
hs_bindgen_9314d546163bea9b :: SDL_HapticID -> IO (PtrConst CChar)
hs_bindgen_9314d546163bea9b =
  \SDL_HapticID
x0 ->
    (Ptr Void -> PtrConst CChar)
-> IO (Ptr Void) -> IO (PtrConst CChar)
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap Ptr Void -> PtrConst CChar
FFIType (PtrConst CChar) -> PtrConst CChar
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Word32 -> IO (Ptr Void)
hs_bindgen_9314d546163bea9b_base (SDL_HapticID -> FFIType SDL_HapticID
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_HapticID
x0))

-- | Get the implementation dependent name of a haptic device.
--
--     This can be called before any haptic devices are opened.
--
--     [Returns]: the name of the selected haptic device. If no name can be found, this function returns NULL; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_GetHapticName', 'sDL_OpenHaptic'
--
--     [C declaration]: @SDL_GetHapticNameForID@, defined at @SDL3\/SDL_haptic.h 992:42@
sDL_GetHapticNameForID
  :: SDL_HapticID
  -- ^
  --
  --           [@instance_id@]: the haptic device instance ID.
  -> IO (PtrConst.PtrConst BG.CChar)
sDL_GetHapticNameForID :: SDL_HapticID -> IO (PtrConst CChar)
sDL_GetHapticNameForID = SDL_HapticID -> IO (PtrConst CChar)
hs_bindgen_9314d546163bea9b

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_OpenHaptic@
foreign import ccall safe "hs_bindgen_dbff4b31baeb7b51"
  hs_bindgen_dbff4b31baeb7b51_base
    :: HsBindgen.Runtime.LibC.Word32
    -> IO (BG.Ptr BG.Void)

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_OpenHaptic@
hs_bindgen_dbff4b31baeb7b51
  :: SDL_HapticID
  -> IO (BG.Ptr SDL_Haptic)
hs_bindgen_dbff4b31baeb7b51 :: SDL_HapticID -> IO (Ptr SDL_Haptic)
hs_bindgen_dbff4b31baeb7b51 =
  \SDL_HapticID
x0 ->
    (Ptr Void -> Ptr SDL_Haptic)
-> IO (Ptr Void) -> IO (Ptr SDL_Haptic)
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap Ptr Void -> Ptr SDL_Haptic
FFIType (Ptr SDL_Haptic) -> Ptr SDL_Haptic
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Word32 -> IO (Ptr Void)
hs_bindgen_dbff4b31baeb7b51_base (SDL_HapticID -> FFIType SDL_HapticID
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_HapticID
x0))

-- | 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()@.
--
--     [Returns]: the device identifier or NULL on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_CloseHaptic', 'sDL_GetHaptics', 'sDL_OpenHapticFromJoystick', 'sDL_OpenHapticFromMouse', 'sDL_SetHapticAutocenter', 'sDL_SetHapticGain'
--
--     [C declaration]: @SDL_OpenHaptic@, defined at @SDL3\/SDL_haptic.h 1017:42@
sDL_OpenHaptic
  :: SDL_HapticID
  -- ^
  --
  --           [@instance_id@]: the haptic device instance ID.
  -> IO (BG.Ptr SDL_Haptic)
sDL_OpenHaptic :: SDL_HapticID -> IO (Ptr SDL_Haptic)
sDL_OpenHaptic = SDL_HapticID -> IO (Ptr SDL_Haptic)
hs_bindgen_dbff4b31baeb7b51

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHapticFromID@
foreign import ccall safe "hs_bindgen_1785e32cd90d0d06"
  hs_bindgen_1785e32cd90d0d06_base
    :: HsBindgen.Runtime.LibC.Word32
    -> IO (BG.Ptr BG.Void)

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHapticFromID@
hs_bindgen_1785e32cd90d0d06
  :: SDL_HapticID
  -> IO (BG.Ptr SDL_Haptic)
hs_bindgen_1785e32cd90d0d06 :: SDL_HapticID -> IO (Ptr SDL_Haptic)
hs_bindgen_1785e32cd90d0d06 =
  \SDL_HapticID
x0 ->
    (Ptr Void -> Ptr SDL_Haptic)
-> IO (Ptr Void) -> IO (Ptr SDL_Haptic)
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap Ptr Void -> Ptr SDL_Haptic
FFIType (Ptr SDL_Haptic) -> Ptr SDL_Haptic
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Word32 -> IO (Ptr Void)
hs_bindgen_1785e32cd90d0d06_base (SDL_HapticID -> FFIType SDL_HapticID
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_HapticID
x0))

-- | Get the 'SDL_Haptic' associated with an instance ID, if it has been opened.
--
--     [Returns]: an 'SDL_Haptic' on success or NULL on failure or if it hasn\'t been opened yet; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [C declaration]: @SDL_GetHapticFromID@, defined at @SDL3\/SDL_haptic.h 1029:42@
sDL_GetHapticFromID
  :: SDL_HapticID
  -- ^
  --
  --           [@instance_id@]: the instance ID to get the 'SDL_Haptic' for.
  -> IO (BG.Ptr SDL_Haptic)
sDL_GetHapticFromID :: SDL_HapticID -> IO (Ptr SDL_Haptic)
sDL_GetHapticFromID = SDL_HapticID -> IO (Ptr SDL_Haptic)
hs_bindgen_1785e32cd90d0d06

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHapticID@
foreign import ccall safe "hs_bindgen_de8498981e0f6223"
  hs_bindgen_de8498981e0f6223_base
    :: BG.Ptr BG.Void
    -> IO HsBindgen.Runtime.LibC.Word32

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHapticID@
hs_bindgen_de8498981e0f6223
  :: BG.Ptr SDL_Haptic
  -> IO SDL_HapticID
hs_bindgen_de8498981e0f6223 :: Ptr SDL_Haptic -> IO SDL_HapticID
hs_bindgen_de8498981e0f6223 =
  \Ptr SDL_Haptic
x0 ->
    (Word32 -> SDL_HapticID) -> IO Word32 -> IO SDL_HapticID
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap Word32 -> SDL_HapticID
FFIType SDL_HapticID -> SDL_HapticID
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO Word32
hs_bindgen_de8498981e0f6223_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0))

-- | Get the instance ID of an opened haptic device.
--
--     [Returns]: the instance ID of the specified haptic device on success or 0 on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [C declaration]: @SDL_GetHapticID@, defined at @SDL3\/SDL_haptic.h 1040:42@
sDL_GetHapticID
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to query.
  -> IO SDL_HapticID
sDL_GetHapticID :: Ptr SDL_Haptic -> IO SDL_HapticID
sDL_GetHapticID = Ptr SDL_Haptic -> IO SDL_HapticID
hs_bindgen_de8498981e0f6223

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHapticName@
foreign import ccall safe "hs_bindgen_360c0a89e793b7ad"
  hs_bindgen_360c0a89e793b7ad_base
    :: BG.Ptr BG.Void
    -> IO (BG.Ptr BG.Void)

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHapticName@
hs_bindgen_360c0a89e793b7ad
  :: BG.Ptr SDL_Haptic
  -> IO (PtrConst.PtrConst BG.CChar)
hs_bindgen_360c0a89e793b7ad :: Ptr SDL_Haptic -> IO (PtrConst CChar)
hs_bindgen_360c0a89e793b7ad =
  \Ptr SDL_Haptic
x0 ->
    (Ptr Void -> PtrConst CChar)
-> IO (Ptr Void) -> IO (PtrConst CChar)
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap Ptr Void -> PtrConst CChar
FFIType (PtrConst CChar) -> PtrConst CChar
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO (Ptr Void)
hs_bindgen_360c0a89e793b7ad_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0))

-- | Get the implementation dependent name of a haptic device.
--
--     [Returns]: the name of the selected haptic device. If no name can be found, this function returns NULL; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_GetHapticNameForID'
--
--     [C declaration]: @SDL_GetHapticName@, defined at @SDL3\/SDL_haptic.h 1054:42@
sDL_GetHapticName
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' obtained from SDL_OpenJoystick().
  -> IO (PtrConst.PtrConst BG.CChar)
sDL_GetHapticName :: Ptr SDL_Haptic -> IO (PtrConst CChar)
sDL_GetHapticName = Ptr SDL_Haptic -> IO (PtrConst CChar)
hs_bindgen_360c0a89e793b7ad

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_IsMouseHaptic@
foreign import ccall safe "hs_bindgen_4c4f92c17cae6f18"
  hs_bindgen_4c4f92c17cae6f18_base
    :: IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_IsMouseHaptic@
hs_bindgen_4c4f92c17cae6f18 :: IO BG.CBool
hs_bindgen_4c4f92c17cae6f18 :: IO CBool
hs_bindgen_4c4f92c17cae6f18 =
  (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType IO CBool
hs_bindgen_4c4f92c17cae6f18_base

-- | Query whether or not the current mouse has haptic capabilities.
--
--     [Returns]: true if the mouse is haptic or false if it isn\'t.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_OpenHapticFromMouse'
--
--     [C declaration]: @SDL_IsMouseHaptic@, defined at @SDL3\/SDL_haptic.h 1065:34@
sDL_IsMouseHaptic :: IO BG.CBool
sDL_IsMouseHaptic :: IO CBool
sDL_IsMouseHaptic = IO CBool
hs_bindgen_4c4f92c17cae6f18

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_OpenHapticFromMouse@
foreign import ccall safe "hs_bindgen_8e6b94caa3e52d98"
  hs_bindgen_8e6b94caa3e52d98_base
    :: IO (BG.Ptr BG.Void)

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_OpenHapticFromMouse@
hs_bindgen_8e6b94caa3e52d98 :: IO (BG.Ptr SDL_Haptic)
hs_bindgen_8e6b94caa3e52d98 :: IO (Ptr SDL_Haptic)
hs_bindgen_8e6b94caa3e52d98 =
  (Ptr Void -> Ptr SDL_Haptic)
-> IO (Ptr Void) -> IO (Ptr SDL_Haptic)
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap Ptr Void -> Ptr SDL_Haptic
FFIType (Ptr SDL_Haptic) -> Ptr SDL_Haptic
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType IO (Ptr Void)
hs_bindgen_8e6b94caa3e52d98_base

-- | Try to open a haptic device from the current mouse.
--
--     [Returns]: the haptic device identifier or NULL on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_CloseHaptic', 'sDL_IsMouseHaptic'
--
--     [C declaration]: @SDL_OpenHapticFromMouse@, defined at @SDL3\/SDL_haptic.h 1078:42@
sDL_OpenHapticFromMouse :: IO (BG.Ptr SDL_Haptic)
sDL_OpenHapticFromMouse :: IO (Ptr SDL_Haptic)
sDL_OpenHapticFromMouse = IO (Ptr SDL_Haptic)
hs_bindgen_8e6b94caa3e52d98

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_IsJoystickHaptic@
foreign import ccall safe "hs_bindgen_c5f4f376b01c2e4f"
  hs_bindgen_c5f4f376b01c2e4f_base
    :: BG.Ptr BG.Void
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_IsJoystickHaptic@
hs_bindgen_c5f4f376b01c2e4f
  :: BG.Ptr SDL3.Sys.Bindgen.Joystick.SDL_Joystick
  -> IO BG.CBool
hs_bindgen_c5f4f376b01c2e4f :: Ptr SDL_Joystick -> IO CBool
hs_bindgen_c5f4f376b01c2e4f =
  \Ptr SDL_Joystick
x0 ->
    (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO CBool
hs_bindgen_c5f4f376b01c2e4f_base (Ptr SDL_Joystick -> FFIType (Ptr SDL_Joystick)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Joystick
x0))

-- | Query if a joystick has haptic features.
--
--     [Returns]: true if the joystick is haptic or false if it isn\'t.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_OpenHapticFromJoystick'
--
--     [C declaration]: @SDL_IsJoystickHaptic@, defined at @SDL3\/SDL_haptic.h 1090:34@
sDL_IsJoystickHaptic
  :: BG.Ptr SDL3.Sys.Bindgen.Joystick.SDL_Joystick
  -- ^
  --
  --           [@joystick@]: the SDL_Joystick to test for haptic capabilities.
  -> IO BG.CBool
sDL_IsJoystickHaptic :: Ptr SDL_Joystick -> IO CBool
sDL_IsJoystickHaptic = Ptr SDL_Joystick -> IO CBool
hs_bindgen_c5f4f376b01c2e4f

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_OpenHapticFromJoystick@
foreign import ccall safe "hs_bindgen_01eda3f2b59f9aab"
  hs_bindgen_01eda3f2b59f9aab_base
    :: BG.Ptr BG.Void
    -> IO (BG.Ptr BG.Void)

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_OpenHapticFromJoystick@
hs_bindgen_01eda3f2b59f9aab
  :: BG.Ptr SDL3.Sys.Bindgen.Joystick.SDL_Joystick
  -> IO (BG.Ptr SDL_Haptic)
hs_bindgen_01eda3f2b59f9aab :: Ptr SDL_Joystick -> IO (Ptr SDL_Haptic)
hs_bindgen_01eda3f2b59f9aab =
  \Ptr SDL_Joystick
x0 ->
    (Ptr Void -> Ptr SDL_Haptic)
-> IO (Ptr Void) -> IO (Ptr SDL_Haptic)
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap Ptr Void -> Ptr SDL_Haptic
FFIType (Ptr SDL_Haptic) -> Ptr SDL_Haptic
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO (Ptr Void)
hs_bindgen_01eda3f2b59f9aab_base (Ptr SDL_Joystick -> FFIType (Ptr SDL_Joystick)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Joystick
x0))

-- | Open a haptic device for use from a joystick device.
--
--     You must still close the haptic device separately. It will not be closed with the joystick.
--
--     When opened from a joystick you should first close the haptic device before closing the joystick device. If not, on some implementations the haptic device will also get unallocated and you\'ll be unable to use force feedback on that device.
--
--     [Returns]: a valid haptic device identifier on success or NULL on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_CloseHaptic', 'sDL_IsJoystickHaptic'
--
--     [C declaration]: @SDL_OpenHapticFromJoystick@, defined at @SDL3\/SDL_haptic.h 1112:42@
sDL_OpenHapticFromJoystick
  :: BG.Ptr SDL3.Sys.Bindgen.Joystick.SDL_Joystick
  -- ^
  --
  --           [@joystick@]: the SDL_Joystick to create a haptic device from.
  -> IO (BG.Ptr SDL_Haptic)
sDL_OpenHapticFromJoystick :: Ptr SDL_Joystick -> IO (Ptr SDL_Haptic)
sDL_OpenHapticFromJoystick =
  Ptr SDL_Joystick -> IO (Ptr SDL_Haptic)
hs_bindgen_01eda3f2b59f9aab

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_CloseHaptic@
foreign import ccall safe "hs_bindgen_f6f5492f48ba2e5b"
  hs_bindgen_f6f5492f48ba2e5b_base
    :: BG.Ptr BG.Void
    -> IO ()

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_CloseHaptic@
hs_bindgen_f6f5492f48ba2e5b
  :: BG.Ptr SDL_Haptic
  -> IO ()
hs_bindgen_f6f5492f48ba2e5b :: Ptr SDL_Haptic -> IO ()
hs_bindgen_f6f5492f48ba2e5b =
  \Ptr SDL_Haptic
x0 ->
    Ptr Void -> IO ()
hs_bindgen_f6f5492f48ba2e5b_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0)

-- | Close a haptic device previously opened with @SDL_OpenHaptic()@.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_OpenHaptic'
--
--     [C declaration]: @SDL_CloseHaptic@, defined at @SDL3\/SDL_haptic.h 1123:34@
sDL_CloseHaptic
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to close.
  -> IO ()
sDL_CloseHaptic :: Ptr SDL_Haptic -> IO ()
sDL_CloseHaptic = Ptr SDL_Haptic -> IO ()
hs_bindgen_f6f5492f48ba2e5b

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetMaxHapticEffects@
foreign import ccall safe "hs_bindgen_366d199432bdd8e0"
  hs_bindgen_366d199432bdd8e0_base
    :: BG.Ptr BG.Void
    -> IO BG.CInt

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetMaxHapticEffects@
hs_bindgen_366d199432bdd8e0
  :: BG.Ptr SDL_Haptic
  -> IO BG.CInt
hs_bindgen_366d199432bdd8e0 :: Ptr SDL_Haptic -> IO CInt
hs_bindgen_366d199432bdd8e0 =
  \Ptr SDL_Haptic
x0 ->
    (CInt -> CInt) -> IO CInt -> IO CInt
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CInt -> CInt
FFIType CInt -> CInt
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO CInt
hs_bindgen_366d199432bdd8e0_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0))

-- | Get the number of effects a haptic device can store.
--
--     On some platforms this isn\'t fully supported, and therefore is an approximation. Always check to see if your created effect was actually created and do not rely solely on @SDL_GetMaxHapticEffects()@.
--
--     [Returns]: the number of effects the haptic device can store or a negative error code on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_GetMaxHapticEffectsPlaying', 'sDL_GetHapticFeatures'
--
--     [C declaration]: @SDL_GetMaxHapticEffects@, defined at @SDL3\/SDL_haptic.h 1141:33@
sDL_GetMaxHapticEffects
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to query.
  -> IO BG.CInt
sDL_GetMaxHapticEffects :: Ptr SDL_Haptic -> IO CInt
sDL_GetMaxHapticEffects = Ptr SDL_Haptic -> IO CInt
hs_bindgen_366d199432bdd8e0

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetMaxHapticEffectsPlaying@
foreign import ccall safe "hs_bindgen_5bf116c6af24ad82"
  hs_bindgen_5bf116c6af24ad82_base
    :: BG.Ptr BG.Void
    -> IO BG.CInt

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetMaxHapticEffectsPlaying@
hs_bindgen_5bf116c6af24ad82
  :: BG.Ptr SDL_Haptic
  -> IO BG.CInt
hs_bindgen_5bf116c6af24ad82 :: Ptr SDL_Haptic -> IO CInt
hs_bindgen_5bf116c6af24ad82 =
  \Ptr SDL_Haptic
x0 ->
    (CInt -> CInt) -> IO CInt -> IO CInt
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CInt -> CInt
FFIType CInt -> CInt
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO CInt
hs_bindgen_5bf116c6af24ad82_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0))

-- | Get the number of effects a haptic device can play at the same time.
--
--     This is not supported on all platforms, but will always return a value.
--
--     [Returns]: the number of effects the haptic device can play at the same time or -1 on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_GetMaxHapticEffects', 'sDL_GetHapticFeatures'
--
--     [C declaration]: @SDL_GetMaxHapticEffectsPlaying@, defined at @SDL3\/SDL_haptic.h 1157:33@
sDL_GetMaxHapticEffectsPlaying
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to query maximum playing effects.
  -> IO BG.CInt
sDL_GetMaxHapticEffectsPlaying :: Ptr SDL_Haptic -> IO CInt
sDL_GetMaxHapticEffectsPlaying =
  Ptr SDL_Haptic -> IO CInt
hs_bindgen_5bf116c6af24ad82

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHapticFeatures@
foreign import ccall safe "hs_bindgen_13fda9a87e4ece91"
  hs_bindgen_13fda9a87e4ece91_base
    :: BG.Ptr BG.Void
    -> IO HsBindgen.Runtime.LibC.Word32

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHapticFeatures@
hs_bindgen_13fda9a87e4ece91
  :: BG.Ptr SDL_Haptic
  -> IO SDL3.Sys.Bindgen.Stdinc.Uint32
hs_bindgen_13fda9a87e4ece91 :: Ptr SDL_Haptic -> IO Uint32
hs_bindgen_13fda9a87e4ece91 =
  \Ptr SDL_Haptic
x0 ->
    (Word32 -> Uint32) -> IO Word32 -> IO Uint32
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap Word32 -> Uint32
FFIType Uint32 -> Uint32
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO Word32
hs_bindgen_13fda9a87e4ece91_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0))

-- | Get the haptic device\'s supported features in bitwise manner.
--
--     [Returns]: a list of supported haptic features in bitwise manner (OR\'d), or 0 on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_HapticEffectSupported', 'sDL_GetMaxHapticEffects'
--
--     [C declaration]: @SDL_GetHapticFeatures@, defined at @SDL3\/SDL_haptic.h 1171:36@
sDL_GetHapticFeatures
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to query.
  -> IO SDL3.Sys.Bindgen.Stdinc.Uint32
sDL_GetHapticFeatures :: Ptr SDL_Haptic -> IO Uint32
sDL_GetHapticFeatures = Ptr SDL_Haptic -> IO Uint32
hs_bindgen_13fda9a87e4ece91

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetNumHapticAxes@
foreign import ccall safe "hs_bindgen_7ed42e0a43315641"
  hs_bindgen_7ed42e0a43315641_base
    :: BG.Ptr BG.Void
    -> IO BG.CInt

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetNumHapticAxes@
hs_bindgen_7ed42e0a43315641
  :: BG.Ptr SDL_Haptic
  -> IO BG.CInt
hs_bindgen_7ed42e0a43315641 :: Ptr SDL_Haptic -> IO CInt
hs_bindgen_7ed42e0a43315641 =
  \Ptr SDL_Haptic
x0 ->
    (CInt -> CInt) -> IO CInt -> IO CInt
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CInt -> CInt
FFIType CInt -> CInt
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO CInt
hs_bindgen_7ed42e0a43315641_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0))

-- | Get the number of haptic axes the device has.
--
--     The number of haptic axes might be useful if working with the 'SDL_HapticDirection' effect.
--
--     [Returns]: the number of axes on success or -1 on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [C declaration]: @SDL_GetNumHapticAxes@, defined at @SDL3\/SDL_haptic.h 1185:33@
sDL_GetNumHapticAxes
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to query.
  -> IO BG.CInt
sDL_GetNumHapticAxes :: Ptr SDL_Haptic -> IO CInt
sDL_GetNumHapticAxes = Ptr SDL_Haptic -> IO CInt
hs_bindgen_7ed42e0a43315641

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_HapticEffectSupported@
foreign import ccall safe "hs_bindgen_5f13cffbd392579e"
  hs_bindgen_5f13cffbd392579e_base
    :: BG.Ptr BG.Void
    -> BG.Ptr BG.Void
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_HapticEffectSupported@
hs_bindgen_5f13cffbd392579e
  :: BG.Ptr SDL_Haptic
  -> PtrConst.PtrConst SDL_HapticEffect
  -> IO BG.CBool
hs_bindgen_5f13cffbd392579e :: Ptr SDL_Haptic -> PtrConst SDL_HapticEffect -> IO CBool
hs_bindgen_5f13cffbd392579e =
  \Ptr SDL_Haptic
x0 ->
    \PtrConst SDL_HapticEffect
x1 ->
      (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> Ptr Void -> IO CBool
hs_bindgen_5f13cffbd392579e_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0) (PtrConst SDL_HapticEffect -> FFIType (PtrConst SDL_HapticEffect)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType PtrConst SDL_HapticEffect
x1))

-- | Check to see if an effect is supported by a haptic device.
--
--     [Returns]: true if the effect is supported or false if it isn\'t.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_CreateHapticEffect', 'sDL_GetHapticFeatures'
--
--     [C declaration]: @SDL_HapticEffectSupported@, defined at @SDL3\/SDL_haptic.h 1199:34@
sDL_HapticEffectSupported
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to query.
  -> PtrConst.PtrConst SDL_HapticEffect
  -- ^
  --
  --           [@effect@]: the desired effect to query.
  -> IO BG.CBool
sDL_HapticEffectSupported :: Ptr SDL_Haptic -> PtrConst SDL_HapticEffect -> IO CBool
sDL_HapticEffectSupported =
  Ptr SDL_Haptic -> PtrConst SDL_HapticEffect -> IO CBool
hs_bindgen_5f13cffbd392579e

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_CreateHapticEffect@
foreign import ccall safe "hs_bindgen_15baa0f4a78836ae"
  hs_bindgen_15baa0f4a78836ae_base
    :: BG.Ptr BG.Void
    -> BG.Ptr BG.Void
    -> IO BG.CInt

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_CreateHapticEffect@
hs_bindgen_15baa0f4a78836ae
  :: BG.Ptr SDL_Haptic
  -> PtrConst.PtrConst SDL_HapticEffect
  -> IO SDL_HapticEffectID
hs_bindgen_15baa0f4a78836ae :: Ptr SDL_Haptic
-> PtrConst SDL_HapticEffect -> IO SDL_HapticEffectID
hs_bindgen_15baa0f4a78836ae =
  \Ptr SDL_Haptic
x0 ->
    \PtrConst SDL_HapticEffect
x1 ->
      (CInt -> SDL_HapticEffectID) -> IO CInt -> IO SDL_HapticEffectID
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CInt -> SDL_HapticEffectID
FFIType SDL_HapticEffectID -> SDL_HapticEffectID
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> Ptr Void -> IO CInt
hs_bindgen_15baa0f4a78836ae_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0) (PtrConst SDL_HapticEffect -> FFIType (PtrConst SDL_HapticEffect)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType PtrConst SDL_HapticEffect
x1))

-- | Create a new haptic effect on a specified device.
--
--     [Returns]: the ID of the effect on success or -1 on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_DestroyHapticEffect', 'sDL_RunHapticEffect', 'sDL_UpdateHapticEffect'
--
--     [C declaration]: @SDL_CreateHapticEffect@, defined at @SDL3\/SDL_haptic.h 1216:48@
sDL_CreateHapticEffect
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: an 'SDL_Haptic' device to create the effect on.
  -> PtrConst.PtrConst SDL_HapticEffect
  -- ^
  --
  --           [@effect@]: an 'SDL_HapticEffect' structure containing the properties of the effect to create.
  -> IO SDL_HapticEffectID
sDL_CreateHapticEffect :: Ptr SDL_Haptic
-> PtrConst SDL_HapticEffect -> IO SDL_HapticEffectID
sDL_CreateHapticEffect = Ptr SDL_Haptic
-> PtrConst SDL_HapticEffect -> IO SDL_HapticEffectID
hs_bindgen_15baa0f4a78836ae

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_UpdateHapticEffect@
foreign import ccall safe "hs_bindgen_0492468c6fb17ac5"
  hs_bindgen_0492468c6fb17ac5_base
    :: BG.Ptr BG.Void
    -> BG.CInt
    -> BG.Ptr BG.Void
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_UpdateHapticEffect@
hs_bindgen_0492468c6fb17ac5
  :: BG.Ptr SDL_Haptic
  -> SDL_HapticEffectID
  -> PtrConst.PtrConst SDL_HapticEffect
  -> IO BG.CBool
hs_bindgen_0492468c6fb17ac5 :: Ptr SDL_Haptic
-> SDL_HapticEffectID -> PtrConst SDL_HapticEffect -> IO CBool
hs_bindgen_0492468c6fb17ac5 =
  \Ptr SDL_Haptic
x0 ->
    \SDL_HapticEffectID
x1 ->
      \PtrConst SDL_HapticEffect
x2 ->
        (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap
          CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType
          (Ptr Void -> CInt -> Ptr Void -> IO CBool
hs_bindgen_0492468c6fb17ac5_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0) (SDL_HapticEffectID -> FFIType SDL_HapticEffectID
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_HapticEffectID
x1) (PtrConst SDL_HapticEffect -> FFIType (PtrConst SDL_HapticEffect)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType PtrConst SDL_HapticEffect
x2))

-- | Update the properties of an effect.
--
--     Can be used dynamically, although behavior when dynamically changing direction may be strange. Specifically the effect may re-upload itself and start playing from the start. You also cannot change the type either when running @SDL_UpdateHapticEffect()@.
--
--     [Returns]: true on success or false on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_CreateHapticEffect', 'sDL_RunHapticEffect'
--
--     [C declaration]: @SDL_UpdateHapticEffect@, defined at @SDL3\/SDL_haptic.h 1238:34@
sDL_UpdateHapticEffect
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device that has the effect.
  -> SDL_HapticEffectID
  -- ^
  --
  --           [@effect@]: the identifier of the effect to update.
  -> PtrConst.PtrConst SDL_HapticEffect
  -- ^
  --
  --           [@data@]: an 'SDL_HapticEffect' structure containing the new effect properties to use.
  -> IO BG.CBool
sDL_UpdateHapticEffect :: Ptr SDL_Haptic
-> SDL_HapticEffectID -> PtrConst SDL_HapticEffect -> IO CBool
sDL_UpdateHapticEffect = Ptr SDL_Haptic
-> SDL_HapticEffectID -> PtrConst SDL_HapticEffect -> IO CBool
hs_bindgen_0492468c6fb17ac5

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_RunHapticEffect@
foreign import ccall safe "hs_bindgen_a614a05d61f4001a"
  hs_bindgen_a614a05d61f4001a_base
    :: BG.Ptr BG.Void
    -> BG.CInt
    -> HsBindgen.Runtime.LibC.Word32
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_RunHapticEffect@
hs_bindgen_a614a05d61f4001a
  :: BG.Ptr SDL_Haptic
  -> SDL_HapticEffectID
  -> SDL3.Sys.Bindgen.Stdinc.Uint32
  -> IO BG.CBool
hs_bindgen_a614a05d61f4001a :: Ptr SDL_Haptic -> SDL_HapticEffectID -> Uint32 -> IO CBool
hs_bindgen_a614a05d61f4001a =
  \Ptr SDL_Haptic
x0 ->
    \SDL_HapticEffectID
x1 ->
      \Uint32
x2 ->
        (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap
          CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType
          (Ptr Void -> CInt -> Word32 -> IO CBool
hs_bindgen_a614a05d61f4001a_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0) (SDL_HapticEffectID -> FFIType SDL_HapticEffectID
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_HapticEffectID
x1) (Uint32 -> FFIType Uint32
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Uint32
x2))

-- | Run the haptic effect on its associated haptic device.
--
--     To repeat the effect over and over indefinitely, set @iterations@ to @'sDL_HAPTIC_INFINITY'@. (Repeats the envelope - attack and fade.) To make one instance of the effect last indefinitely (so the effect does not fade), set the effect\'s @length@ in its structure\/union to @'sDL_HAPTIC_INFINITY'@ instead.
--
--     [Returns]: true on success or false on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_GetHapticEffectStatus', 'sDL_StopHapticEffect', 'sDL_StopHapticEffects'
--
--     [C declaration]: @SDL_RunHapticEffect@, defined at @SDL3\/SDL_haptic.h 1262:34@
sDL_RunHapticEffect
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to run the effect on.
  -> SDL_HapticEffectID
  -- ^
  --
  --           [@effect@]: the ID of the haptic effect to run.
  -> SDL3.Sys.Bindgen.Stdinc.Uint32
  -- ^
  --
  --           [@iterations@]: the number of iterations to run the effect; use @'sDL_HAPTIC_INFINITY'@ to repeat forever.
  -> IO BG.CBool
sDL_RunHapticEffect :: Ptr SDL_Haptic -> SDL_HapticEffectID -> Uint32 -> IO CBool
sDL_RunHapticEffect = Ptr SDL_Haptic -> SDL_HapticEffectID -> Uint32 -> IO CBool
hs_bindgen_a614a05d61f4001a

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_StopHapticEffect@
foreign import ccall safe "hs_bindgen_62c7aa3038b74c27"
  hs_bindgen_62c7aa3038b74c27_base
    :: BG.Ptr BG.Void
    -> BG.CInt
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_StopHapticEffect@
hs_bindgen_62c7aa3038b74c27
  :: BG.Ptr SDL_Haptic
  -> SDL_HapticEffectID
  -> IO BG.CBool
hs_bindgen_62c7aa3038b74c27 :: Ptr SDL_Haptic -> SDL_HapticEffectID -> IO CBool
hs_bindgen_62c7aa3038b74c27 =
  \Ptr SDL_Haptic
x0 ->
    \SDL_HapticEffectID
x1 ->
      (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> CInt -> IO CBool
hs_bindgen_62c7aa3038b74c27_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0) (SDL_HapticEffectID -> FFIType SDL_HapticEffectID
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_HapticEffectID
x1))

-- | Stop the haptic effect on its associated haptic device.
--
--     [Returns]: true on success or false on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_RunHapticEffect', 'sDL_StopHapticEffects'
--
--     [C declaration]: @SDL_StopHapticEffect@, defined at @SDL3\/SDL_haptic.h 1277:34@
sDL_StopHapticEffect
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to stop the effect on.
  -> SDL_HapticEffectID
  -- ^
  --
  --           [@effect@]: the ID of the haptic effect to stop.
  -> IO BG.CBool
sDL_StopHapticEffect :: Ptr SDL_Haptic -> SDL_HapticEffectID -> IO CBool
sDL_StopHapticEffect = Ptr SDL_Haptic -> SDL_HapticEffectID -> IO CBool
hs_bindgen_62c7aa3038b74c27

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_DestroyHapticEffect@
foreign import ccall safe "hs_bindgen_6ebf1b15d73c024c"
  hs_bindgen_6ebf1b15d73c024c_base
    :: BG.Ptr BG.Void
    -> BG.CInt
    -> IO ()

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_DestroyHapticEffect@
hs_bindgen_6ebf1b15d73c024c
  :: BG.Ptr SDL_Haptic
  -> SDL_HapticEffectID
  -> IO ()
hs_bindgen_6ebf1b15d73c024c :: Ptr SDL_Haptic -> SDL_HapticEffectID -> IO ()
hs_bindgen_6ebf1b15d73c024c =
  \Ptr SDL_Haptic
x0 ->
    \SDL_HapticEffectID
x1 ->
      Ptr Void -> CInt -> IO ()
hs_bindgen_6ebf1b15d73c024c_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0) (SDL_HapticEffectID -> FFIType SDL_HapticEffectID
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_HapticEffectID
x1)

-- | Destroy a haptic effect on the device.
--
--     This will stop the effect if it\'s running. Effects are automatically destroyed when the device is closed.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_CreateHapticEffect'
--
--     [C declaration]: @SDL_DestroyHapticEffect@, defined at @SDL3\/SDL_haptic.h 1292:34@
sDL_DestroyHapticEffect
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to destroy the effect on.
  -> SDL_HapticEffectID
  -- ^
  --
  --           [@effect@]: the ID of the haptic effect to destroy.
  -> IO ()
sDL_DestroyHapticEffect :: Ptr SDL_Haptic -> SDL_HapticEffectID -> IO ()
sDL_DestroyHapticEffect = Ptr SDL_Haptic -> SDL_HapticEffectID -> IO ()
hs_bindgen_6ebf1b15d73c024c

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHapticEffectStatus@
foreign import ccall safe "hs_bindgen_8953e9e35530a132"
  hs_bindgen_8953e9e35530a132_base
    :: BG.Ptr BG.Void
    -> BG.CInt
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_GetHapticEffectStatus@
hs_bindgen_8953e9e35530a132
  :: BG.Ptr SDL_Haptic
  -> SDL_HapticEffectID
  -> IO BG.CBool
hs_bindgen_8953e9e35530a132 :: Ptr SDL_Haptic -> SDL_HapticEffectID -> IO CBool
hs_bindgen_8953e9e35530a132 =
  \Ptr SDL_Haptic
x0 ->
    \SDL_HapticEffectID
x1 ->
      (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> CInt -> IO CBool
hs_bindgen_8953e9e35530a132_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0) (SDL_HapticEffectID -> FFIType SDL_HapticEffectID
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType SDL_HapticEffectID
x1))

-- | Get the status of the current effect on the specified haptic device.
--
--     Device must support the SDL_HAPTIC_STATUS feature.
--
--     [Returns]: true if it is playing, false if it isn\'t playing or haptic status isn\'t supported.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_GetHapticFeatures'
--
--     [C declaration]: @SDL_GetHapticEffectStatus@, defined at @SDL3\/SDL_haptic.h 1308:34@
sDL_GetHapticEffectStatus
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to query for the effect status on.
  -> SDL_HapticEffectID
  -- ^
  --
  --           [@effect@]: the ID of the haptic effect to query its status.
  -> IO BG.CBool
sDL_GetHapticEffectStatus :: Ptr SDL_Haptic -> SDL_HapticEffectID -> IO CBool
sDL_GetHapticEffectStatus =
  Ptr SDL_Haptic -> SDL_HapticEffectID -> IO CBool
hs_bindgen_8953e9e35530a132

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_SetHapticGain@
foreign import ccall safe "hs_bindgen_33d36e11c46c206d"
  hs_bindgen_33d36e11c46c206d_base
    :: BG.Ptr BG.Void
    -> BG.CInt
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_SetHapticGain@
hs_bindgen_33d36e11c46c206d
  :: BG.Ptr SDL_Haptic
  -> BG.CInt
  -> IO BG.CBool
hs_bindgen_33d36e11c46c206d :: Ptr SDL_Haptic -> CInt -> IO CBool
hs_bindgen_33d36e11c46c206d =
  \Ptr SDL_Haptic
x0 ->
    \CInt
x1 ->
      (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> CInt -> IO CBool
hs_bindgen_33d36e11c46c206d_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0) (CInt -> FFIType CInt
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType CInt
x1))

-- | Set the global gain of the specified haptic device.
--
--     Device must support the SDL_HAPTIC_GAIN feature.
--
--     The user may specify the maximum gain by setting the environment variable @SDL_HAPTIC_GAIN_MAX@ which should be between 0 and 100. All calls to @SDL_SetHapticGain()@ will scale linearly using @SDL_HAPTIC_GAIN_MAX@ as the maximum.
--
--     [Returns]: true on success or false on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_GetHapticFeatures'
--
--     [C declaration]: @SDL_SetHapticGain@, defined at @SDL3\/SDL_haptic.h 1330:34@
sDL_SetHapticGain
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to set the gain on.
  -> BG.CInt
  -- ^
  --
  --           [@gain@]: value to set the gain to, should be between 0 and 100 (0 - 100).
  -> IO BG.CBool
sDL_SetHapticGain :: Ptr SDL_Haptic -> CInt -> IO CBool
sDL_SetHapticGain = Ptr SDL_Haptic -> CInt -> IO CBool
hs_bindgen_33d36e11c46c206d

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_SetHapticAutocenter@
foreign import ccall safe "hs_bindgen_713374147201159e"
  hs_bindgen_713374147201159e_base
    :: BG.Ptr BG.Void
    -> BG.CInt
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_SetHapticAutocenter@
hs_bindgen_713374147201159e
  :: BG.Ptr SDL_Haptic
  -> BG.CInt
  -> IO BG.CBool
hs_bindgen_713374147201159e :: Ptr SDL_Haptic -> CInt -> IO CBool
hs_bindgen_713374147201159e =
  \Ptr SDL_Haptic
x0 ->
    \CInt
x1 ->
      (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> CInt -> IO CBool
hs_bindgen_713374147201159e_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0) (CInt -> FFIType CInt
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType CInt
x1))

-- | Set the global autocenter of the device.
--
--     Autocenter should be between 0 and 100. Setting it to 0 will disable autocentering.
--
--     Device must support the SDL_HAPTIC_AUTOCENTER feature.
--
--     [Returns]: true on success or false on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_GetHapticFeatures'
--
--     [C declaration]: @SDL_SetHapticAutocenter@, defined at @SDL3\/SDL_haptic.h 1349:34@
sDL_SetHapticAutocenter
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to set autocentering on.
  -> BG.CInt
  -- ^
  --
  --           [@autocenter@]: value to set autocenter to (0-100).
  -> IO BG.CBool
sDL_SetHapticAutocenter :: Ptr SDL_Haptic -> CInt -> IO CBool
sDL_SetHapticAutocenter = Ptr SDL_Haptic -> CInt -> IO CBool
hs_bindgen_713374147201159e

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_PauseHaptic@
foreign import ccall safe "hs_bindgen_d4344f317b2d7325"
  hs_bindgen_d4344f317b2d7325_base
    :: BG.Ptr BG.Void
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_PauseHaptic@
hs_bindgen_d4344f317b2d7325
  :: BG.Ptr SDL_Haptic
  -> IO BG.CBool
hs_bindgen_d4344f317b2d7325 :: Ptr SDL_Haptic -> IO CBool
hs_bindgen_d4344f317b2d7325 =
  \Ptr SDL_Haptic
x0 ->
    (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO CBool
hs_bindgen_d4344f317b2d7325_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0))

-- | Pause a haptic device.
--
--     Device must support the @'sDL_HAPTIC_PAUSE'@ feature. Call @SDL_ResumeHaptic()@ to resume playback.
--
--     Do not modify the effects nor add new ones while the device is paused. That can cause all sorts of weird errors.
--
--     [Returns]: true on success or false on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_ResumeHaptic'
--
--     [C declaration]: @SDL_PauseHaptic@, defined at @SDL3\/SDL_haptic.h 1368:34@
sDL_PauseHaptic
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to pause.
  -> IO BG.CBool
sDL_PauseHaptic :: Ptr SDL_Haptic -> IO CBool
sDL_PauseHaptic = Ptr SDL_Haptic -> IO CBool
hs_bindgen_d4344f317b2d7325

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_ResumeHaptic@
foreign import ccall safe "hs_bindgen_79c16f8418a90f86"
  hs_bindgen_79c16f8418a90f86_base
    :: BG.Ptr BG.Void
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_ResumeHaptic@
hs_bindgen_79c16f8418a90f86
  :: BG.Ptr SDL_Haptic
  -> IO BG.CBool
hs_bindgen_79c16f8418a90f86 :: Ptr SDL_Haptic -> IO CBool
hs_bindgen_79c16f8418a90f86 =
  \Ptr SDL_Haptic
x0 ->
    (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO CBool
hs_bindgen_79c16f8418a90f86_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0))

-- | Resume a haptic device.
--
--     Call to unpause after @SDL_PauseHaptic()@.
--
--     [Returns]: true on success or false on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_PauseHaptic'
--
--     [C declaration]: @SDL_ResumeHaptic@, defined at @SDL3\/SDL_haptic.h 1383:34@
sDL_ResumeHaptic
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to unpause.
  -> IO BG.CBool
sDL_ResumeHaptic :: Ptr SDL_Haptic -> IO CBool
sDL_ResumeHaptic = Ptr SDL_Haptic -> IO CBool
hs_bindgen_79c16f8418a90f86

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_StopHapticEffects@
foreign import ccall safe "hs_bindgen_f452836b38dc6590"
  hs_bindgen_f452836b38dc6590_base
    :: BG.Ptr BG.Void
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_StopHapticEffects@
hs_bindgen_f452836b38dc6590
  :: BG.Ptr SDL_Haptic
  -> IO BG.CBool
hs_bindgen_f452836b38dc6590 :: Ptr SDL_Haptic -> IO CBool
hs_bindgen_f452836b38dc6590 =
  \Ptr SDL_Haptic
x0 ->
    (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO CBool
hs_bindgen_f452836b38dc6590_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0))

-- | Stop all the currently playing effects on a haptic device.
--
--     [Returns]: true on success or false on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_RunHapticEffect', 'sDL_StopHapticEffect'
--
--     [C declaration]: @SDL_StopHapticEffects@, defined at @SDL3\/SDL_haptic.h 1397:34@
sDL_StopHapticEffects
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the 'SDL_Haptic' device to stop.
  -> IO BG.CBool
sDL_StopHapticEffects :: Ptr SDL_Haptic -> IO CBool
sDL_StopHapticEffects = Ptr SDL_Haptic -> IO CBool
hs_bindgen_f452836b38dc6590

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_HapticRumbleSupported@
foreign import ccall safe "hs_bindgen_113ac21fbd9de22e"
  hs_bindgen_113ac21fbd9de22e_base
    :: BG.Ptr BG.Void
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_HapticRumbleSupported@
hs_bindgen_113ac21fbd9de22e
  :: BG.Ptr SDL_Haptic
  -> IO BG.CBool
hs_bindgen_113ac21fbd9de22e :: Ptr SDL_Haptic -> IO CBool
hs_bindgen_113ac21fbd9de22e =
  \Ptr SDL_Haptic
x0 ->
    (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO CBool
hs_bindgen_113ac21fbd9de22e_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0))

-- | Check whether rumble is supported on a haptic device.
--
--     [Returns]: true if the effect is supported or false if it isn\'t.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_InitHapticRumble'
--
--     [C declaration]: @SDL_HapticRumbleSupported@, defined at @SDL3\/SDL_haptic.h 1409:34@
sDL_HapticRumbleSupported
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: haptic device to check for rumble support.
  -> IO BG.CBool
sDL_HapticRumbleSupported :: Ptr SDL_Haptic -> IO CBool
sDL_HapticRumbleSupported =
  Ptr SDL_Haptic -> IO CBool
hs_bindgen_113ac21fbd9de22e

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_InitHapticRumble@
foreign import ccall safe "hs_bindgen_ae32c683da240a6e"
  hs_bindgen_ae32c683da240a6e_base
    :: BG.Ptr BG.Void
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_InitHapticRumble@
hs_bindgen_ae32c683da240a6e
  :: BG.Ptr SDL_Haptic
  -> IO BG.CBool
hs_bindgen_ae32c683da240a6e :: Ptr SDL_Haptic -> IO CBool
hs_bindgen_ae32c683da240a6e =
  \Ptr SDL_Haptic
x0 ->
    (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO CBool
hs_bindgen_ae32c683da240a6e_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0))

-- | Initialize a haptic device for simple rumble playback.
--
--     [Returns]: true on success or false on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_PlayHapticRumble', 'sDL_StopHapticRumble', 'sDL_HapticRumbleSupported'
--
--     [C declaration]: @SDL_InitHapticRumble@, defined at @SDL3\/SDL_haptic.h 1424:34@
sDL_InitHapticRumble
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the haptic device to initialize for simple rumble playback.
  -> IO BG.CBool
sDL_InitHapticRumble :: Ptr SDL_Haptic -> IO CBool
sDL_InitHapticRumble = Ptr SDL_Haptic -> IO CBool
hs_bindgen_ae32c683da240a6e

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_PlayHapticRumble@
foreign import ccall safe "hs_bindgen_10fe16fce6a60bfe"
  hs_bindgen_10fe16fce6a60bfe_base
    :: BG.Ptr BG.Void
    -> BG.CFloat
    -> HsBindgen.Runtime.LibC.Word32
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_PlayHapticRumble@
hs_bindgen_10fe16fce6a60bfe
  :: BG.Ptr SDL_Haptic
  -> BG.CFloat
  -> SDL3.Sys.Bindgen.Stdinc.Uint32
  -> IO BG.CBool
hs_bindgen_10fe16fce6a60bfe :: Ptr SDL_Haptic -> CFloat -> Uint32 -> IO CBool
hs_bindgen_10fe16fce6a60bfe =
  \Ptr SDL_Haptic
x0 ->
    \CFloat
x1 ->
      \Uint32
x2 ->
        (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap
          CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType
          (Ptr Void -> CFloat -> Word32 -> IO CBool
hs_bindgen_10fe16fce6a60bfe_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0) (CFloat -> FFIType CFloat
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType CFloat
x1) (Uint32 -> FFIType Uint32
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Uint32
x2))

-- | Run a simple rumble effect on a haptic device.
--
--     [Returns]: true on success or false on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_InitHapticRumble', 'sDL_StopHapticRumble'
--
--     [C declaration]: @SDL_PlayHapticRumble@, defined at @SDL3\/SDL_haptic.h 1440:34@
sDL_PlayHapticRumble
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the haptic device to play the rumble effect on.
  -> BG.CFloat
  -- ^
  --
  --           [@strength@]: strength of the rumble to play as a 0-1 float value.
  -> SDL3.Sys.Bindgen.Stdinc.Uint32
  -- ^
  --
  --           [@length@]: length of the rumble to play in milliseconds.
  -> IO BG.CBool
sDL_PlayHapticRumble :: Ptr SDL_Haptic -> CFloat -> Uint32 -> IO CBool
sDL_PlayHapticRumble = Ptr SDL_Haptic -> CFloat -> Uint32 -> IO CBool
hs_bindgen_10fe16fce6a60bfe

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_StopHapticRumble@
foreign import ccall safe "hs_bindgen_2b55fdb7a5a8262a"
  hs_bindgen_2b55fdb7a5a8262a_base
    :: BG.Ptr BG.Void
    -> IO BG.CBool

-- __unique:__ @sdl3bindgensys_SDL3.Sys.Bindgen.Haptic_Safe_SDL_StopHapticRumble@
hs_bindgen_2b55fdb7a5a8262a
  :: BG.Ptr SDL_Haptic
  -> IO BG.CBool
hs_bindgen_2b55fdb7a5a8262a :: Ptr SDL_Haptic -> IO CBool
hs_bindgen_2b55fdb7a5a8262a =
  \Ptr SDL_Haptic
x0 ->
    (CBool -> CBool) -> IO CBool -> IO CBool
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap CBool -> CBool
FFIType CBool -> CBool
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO CBool
hs_bindgen_2b55fdb7a5a8262a_base (Ptr SDL_Haptic -> FFIType (Ptr SDL_Haptic)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Haptic
x0))

-- | Stop the simple rumble on a haptic device.
--
--     [Returns]: true on success or false on failure; call SDL_GetError() for more information.
--
--     @since 3.2.0
--
--     [See also]: 'sDL_PlayHapticRumble'
--
--     [C declaration]: @SDL_StopHapticRumble@, defined at @SDL3\/SDL_haptic.h 1453:34@
sDL_StopHapticRumble
  :: BG.Ptr SDL_Haptic
  -- ^
  --
  --           [@haptic@]: the haptic device to stop the rumble effect on.
  -> IO BG.CBool
sDL_StopHapticRumble :: Ptr SDL_Haptic -> IO CBool
sDL_StopHapticRumble = Ptr SDL_Haptic -> IO CBool
hs_bindgen_2b55fdb7a5a8262a