{-# LANGUAGE ForeignFunctionInterface #-}
{-# LANGUAGE TemplateHaskell #-}
{-# LANGUAGE NoFieldSelectors #-}
{-# LANGUAGE NoImplicitPrelude #-}
{-# OPTIONS_HADDOCK prune #-}
module SDL3.Sys.Bindgen.Vulkan.Unsafe (
SDL3.Sys.Bindgen.Vulkan.Unsafe.sDL_Vulkan_LoadLibrary,
SDL3.Sys.Bindgen.Vulkan.Unsafe.sDL_Vulkan_GetVkGetInstanceProcAddr,
SDL3.Sys.Bindgen.Vulkan.Unsafe.sDL_Vulkan_UnloadLibrary,
SDL3.Sys.Bindgen.Vulkan.Unsafe.sDL_Vulkan_GetInstanceExtensions,
SDL3.Sys.Bindgen.Vulkan.Unsafe.sDL_Vulkan_CreateSurface,
SDL3.Sys.Bindgen.Vulkan.Unsafe.sDL_Vulkan_DestroySurface,
SDL3.Sys.Bindgen.Vulkan.Unsafe.sDL_Vulkan_GetPresentationSupport,
)
where
import Prelude (IO, fmap)
import HsBindgen.Runtime.LibC qualified
import HsBindgen.Runtime.PtrConst qualified as PtrConst
import HsBindgen.Runtime.Support qualified
import HsBindgen.Runtime.Support qualified as BG
import HsBindgen.Runtime.Support.CAPI qualified
import SDL3.Sys.Bindgen.Stdinc qualified
import SDL3.Sys.Bindgen.Video qualified
import SDL3.Sys.Bindgen.Vulkan
$( 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_vulkan.h>"
, "_Bool hs_bindgen_a109086f43a5b6e5 ("
, " char const *arg1"
, ")"
, "{"
, " return (SDL_Vulkan_LoadLibrary)(arg1);"
, "}"
, "SDL_FunctionPointer hs_bindgen_4a040ba0b3ef299e (void)"
, "{"
, " return (SDL_Vulkan_GetVkGetInstanceProcAddr)();"
, "}"
, "void hs_bindgen_37af72574ddcbb1a (void)"
, "{"
, " (SDL_Vulkan_UnloadLibrary)();"
, "}"
, "char const *const *hs_bindgen_2aad81b39a87b1fa ("
, " Uint32 *arg1"
, ")"
, "{"
, " return (SDL_Vulkan_GetInstanceExtensions)(arg1);"
, "}"
, "_Bool hs_bindgen_32bf040c7a36881e ("
, " SDL_Window *arg1,"
, " VkInstance arg2,"
, " struct VkAllocationCallbacks const *arg3,"
, " VkSurfaceKHR *arg4"
, ")"
, "{"
, " return (SDL_Vulkan_CreateSurface)(arg1, arg2, arg3, arg4);"
, "}"
, "void hs_bindgen_c7debc5633e16c49 ("
, " VkInstance arg1,"
, " VkSurfaceKHR arg2,"
, " struct VkAllocationCallbacks const *arg3"
, ")"
, "{"
, " (SDL_Vulkan_DestroySurface)(arg1, arg2, arg3);"
, "}"
, "_Bool hs_bindgen_dfcebfd398bdf0a8 ("
, " VkInstance arg1,"
, " VkPhysicalDevice arg2,"
, " Uint32 arg3"
, ")"
, "{"
, " return (SDL_Vulkan_GetPresentationSupport)(arg1, arg2, arg3);"
, "}"
]
)
)
foreign import ccall unsafe "hs_bindgen_a109086f43a5b6e5"
hs_bindgen_a109086f43a5b6e5_base
:: BG.Ptr BG.Void
-> IO BG.CBool
hs_bindgen_a109086f43a5b6e5
:: PtrConst.PtrConst BG.CChar
-> IO BG.CBool
hs_bindgen_a109086f43a5b6e5 :: PtrConst CChar -> IO CBool
hs_bindgen_a109086f43a5b6e5 =
\PtrConst CChar
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_a109086f43a5b6e5_base (PtrConst CChar -> FFIType (PtrConst CChar)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType PtrConst CChar
x0))
sDL_Vulkan_LoadLibrary
:: PtrConst.PtrConst BG.CChar
-> IO BG.CBool
sDL_Vulkan_LoadLibrary :: PtrConst CChar -> IO CBool
sDL_Vulkan_LoadLibrary = PtrConst CChar -> IO CBool
hs_bindgen_a109086f43a5b6e5
foreign import ccall unsafe "hs_bindgen_4a040ba0b3ef299e"
hs_bindgen_4a040ba0b3ef299e_base
:: IO HsBindgen.Runtime.Support.FunPtrVoid
hs_bindgen_4a040ba0b3ef299e :: IO SDL3.Sys.Bindgen.Stdinc.SDL_FunctionPointer
hs_bindgen_4a040ba0b3ef299e :: IO SDL_FunctionPointer
hs_bindgen_4a040ba0b3ef299e =
(FunPtrVoid -> SDL_FunctionPointer)
-> IO FunPtrVoid -> IO SDL_FunctionPointer
forall a b. (a -> b) -> IO a -> IO b
forall (f :: * -> *) a b. Functor f => (a -> b) -> f a -> f b
fmap FunPtrVoid -> SDL_FunctionPointer
FFIType SDL_FunctionPointer -> SDL_FunctionPointer
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType IO FunPtrVoid
hs_bindgen_4a040ba0b3ef299e_base
sDL_Vulkan_GetVkGetInstanceProcAddr :: IO SDL3.Sys.Bindgen.Stdinc.SDL_FunctionPointer
sDL_Vulkan_GetVkGetInstanceProcAddr :: IO SDL_FunctionPointer
sDL_Vulkan_GetVkGetInstanceProcAddr =
IO SDL_FunctionPointer
hs_bindgen_4a040ba0b3ef299e
foreign import ccall unsafe "hs_bindgen_37af72574ddcbb1a"
hs_bindgen_37af72574ddcbb1a_base
:: IO ()
hs_bindgen_37af72574ddcbb1a :: IO ()
hs_bindgen_37af72574ddcbb1a :: IO ()
hs_bindgen_37af72574ddcbb1a =
IO ()
hs_bindgen_37af72574ddcbb1a_base
sDL_Vulkan_UnloadLibrary :: IO ()
sDL_Vulkan_UnloadLibrary :: IO ()
sDL_Vulkan_UnloadLibrary =
IO ()
hs_bindgen_37af72574ddcbb1a
foreign import ccall unsafe "hs_bindgen_2aad81b39a87b1fa"
hs_bindgen_2aad81b39a87b1fa_base
:: BG.Ptr BG.Void
-> IO (BG.Ptr BG.Void)
hs_bindgen_2aad81b39a87b1fa
:: BG.Ptr SDL3.Sys.Bindgen.Stdinc.Uint32
-> IO (PtrConst.PtrConst (PtrConst.PtrConst BG.CChar))
hs_bindgen_2aad81b39a87b1fa :: Ptr Uint32 -> IO (PtrConst (PtrConst CChar))
hs_bindgen_2aad81b39a87b1fa =
\Ptr Uint32
x0 ->
(Ptr Void -> PtrConst (PtrConst CChar))
-> IO (Ptr Void) -> IO (PtrConst (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 (PtrConst CChar)
FFIType (PtrConst (PtrConst CChar)) -> PtrConst (PtrConst CChar)
forall a. HasFFIType a => FFIType a -> a
BG.fromFFIType (Ptr Void -> IO (Ptr Void)
hs_bindgen_2aad81b39a87b1fa_base (Ptr Uint32 -> FFIType (Ptr Uint32)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr Uint32
x0))
sDL_Vulkan_GetInstanceExtensions
:: BG.Ptr SDL3.Sys.Bindgen.Stdinc.Uint32
-> IO (PtrConst.PtrConst (PtrConst.PtrConst BG.CChar))
sDL_Vulkan_GetInstanceExtensions :: Ptr Uint32 -> IO (PtrConst (PtrConst CChar))
sDL_Vulkan_GetInstanceExtensions =
Ptr Uint32 -> IO (PtrConst (PtrConst CChar))
hs_bindgen_2aad81b39a87b1fa
foreign import ccall unsafe "hs_bindgen_32bf040c7a36881e"
hs_bindgen_32bf040c7a36881e_base
:: BG.Ptr BG.Void
-> BG.Ptr BG.Void
-> BG.Ptr BG.Void
-> BG.Ptr BG.Void
-> IO BG.CBool
hs_bindgen_32bf040c7a36881e
:: BG.Ptr SDL3.Sys.Bindgen.Video.SDL_Window
-> VkInstance
-> PtrConst.PtrConst VkAllocationCallbacks
-> BG.Ptr VkSurfaceKHR
-> IO BG.CBool
hs_bindgen_32bf040c7a36881e :: Ptr SDL_Window
-> VkInstance
-> PtrConst VkAllocationCallbacks
-> Ptr VkSurfaceKHR
-> IO CBool
hs_bindgen_32bf040c7a36881e =
\Ptr SDL_Window
x0 ->
\VkInstance
x1 ->
\PtrConst VkAllocationCallbacks
x2 ->
\Ptr VkSurfaceKHR
x3 ->
(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 -> Ptr Void -> Ptr Void -> IO CBool
hs_bindgen_32bf040c7a36881e_base
(Ptr SDL_Window -> FFIType (Ptr SDL_Window)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr SDL_Window
x0)
(VkInstance -> FFIType VkInstance
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType VkInstance
x1)
(PtrConst VkAllocationCallbacks
-> FFIType (PtrConst VkAllocationCallbacks)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType PtrConst VkAllocationCallbacks
x2)
(Ptr VkSurfaceKHR -> FFIType (Ptr VkSurfaceKHR)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Ptr VkSurfaceKHR
x3)
)
sDL_Vulkan_CreateSurface
:: BG.Ptr SDL3.Sys.Bindgen.Video.SDL_Window
-> VkInstance
-> PtrConst.PtrConst VkAllocationCallbacks
-> BG.Ptr VkSurfaceKHR
-> IO BG.CBool
sDL_Vulkan_CreateSurface :: Ptr SDL_Window
-> VkInstance
-> PtrConst VkAllocationCallbacks
-> Ptr VkSurfaceKHR
-> IO CBool
sDL_Vulkan_CreateSurface =
Ptr SDL_Window
-> VkInstance
-> PtrConst VkAllocationCallbacks
-> Ptr VkSurfaceKHR
-> IO CBool
hs_bindgen_32bf040c7a36881e
foreign import ccall unsafe "hs_bindgen_c7debc5633e16c49"
hs_bindgen_c7debc5633e16c49_base
:: BG.Ptr BG.Void
-> BG.Ptr BG.Void
-> BG.Ptr BG.Void
-> IO ()
hs_bindgen_c7debc5633e16c49
:: VkInstance
-> VkSurfaceKHR
-> PtrConst.PtrConst VkAllocationCallbacks
-> IO ()
hs_bindgen_c7debc5633e16c49 :: VkInstance
-> VkSurfaceKHR -> PtrConst VkAllocationCallbacks -> IO ()
hs_bindgen_c7debc5633e16c49 =
\VkInstance
x0 ->
\VkSurfaceKHR
x1 ->
\PtrConst VkAllocationCallbacks
x2 ->
Ptr Void -> Ptr Void -> Ptr Void -> IO ()
hs_bindgen_c7debc5633e16c49_base (VkInstance -> FFIType VkInstance
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType VkInstance
x0) (VkSurfaceKHR -> FFIType VkSurfaceKHR
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType VkSurfaceKHR
x1) (PtrConst VkAllocationCallbacks
-> FFIType (PtrConst VkAllocationCallbacks)
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType PtrConst VkAllocationCallbacks
x2)
sDL_Vulkan_DestroySurface
:: VkInstance
-> VkSurfaceKHR
-> PtrConst.PtrConst VkAllocationCallbacks
-> IO ()
sDL_Vulkan_DestroySurface :: VkInstance
-> VkSurfaceKHR -> PtrConst VkAllocationCallbacks -> IO ()
sDL_Vulkan_DestroySurface =
VkInstance
-> VkSurfaceKHR -> PtrConst VkAllocationCallbacks -> IO ()
hs_bindgen_c7debc5633e16c49
foreign import ccall unsafe "hs_bindgen_dfcebfd398bdf0a8"
hs_bindgen_dfcebfd398bdf0a8_base
:: BG.Ptr BG.Void
-> BG.Ptr BG.Void
-> HsBindgen.Runtime.LibC.Word32
-> IO BG.CBool
hs_bindgen_dfcebfd398bdf0a8
:: VkInstance
-> VkPhysicalDevice
-> SDL3.Sys.Bindgen.Stdinc.Uint32
-> IO BG.CBool
hs_bindgen_dfcebfd398bdf0a8 :: VkInstance -> VkPhysicalDevice -> Uint32 -> IO CBool
hs_bindgen_dfcebfd398bdf0a8 =
\VkInstance
x0 ->
\VkPhysicalDevice
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 -> Ptr Void -> Word32 -> IO CBool
hs_bindgen_dfcebfd398bdf0a8_base (VkInstance -> FFIType VkInstance
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType VkInstance
x0) (VkPhysicalDevice -> FFIType VkPhysicalDevice
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType VkPhysicalDevice
x1) (Uint32 -> FFIType Uint32
forall a. HasFFIType a => a -> FFIType a
BG.toFFIType Uint32
x2))
sDL_Vulkan_GetPresentationSupport
:: VkInstance
-> VkPhysicalDevice
-> SDL3.Sys.Bindgen.Stdinc.Uint32
-> IO BG.CBool
sDL_Vulkan_GetPresentationSupport :: VkInstance -> VkPhysicalDevice -> Uint32 -> IO CBool
sDL_Vulkan_GetPresentationSupport =
VkInstance -> VkPhysicalDevice -> Uint32 -> IO CBool
hs_bindgen_dfcebfd398bdf0a8