{-# language CPP #-}
-- | = Name
--
-- VK_EXT_directfb_surface - instance extension
--
-- == VK_EXT_directfb_surface
--
-- [__Name String__]
--     @VK_EXT_directfb_surface@
--
-- [__Extension Type__]
--     Instance extension
--
-- [__Registered Extension Number__]
--     347
--
-- [__Revision__]
--     1
--
-- [__Ratification Status__]
--     Not ratified
--
-- [__Extension and Version Dependencies__]
--     <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#VK_KHR_surface VK_KHR_surface>
--
-- [__Contact__]
--
--     -   Nicolas Caramelli
--         <https://github.com/KhronosGroup/Vulkan-Docs/issues/new?body=[VK_EXT_directfb_surface] @caramelli%0A*Here describe the issue or question you have about the VK_EXT_directfb_surface extension* >
--
-- == Other Extension Metadata
--
-- [__Last Modified Date__]
--     2020-06-16
--
-- [__IP Status__]
--     No known IP claims.
--
-- [__Contributors__]
--
--     -   Nicolas Caramelli
--
-- == Description
--
-- The @VK_EXT_directfb_surface@ extension is an instance extension. It
-- provides a mechanism to create a 'Vulkan.Extensions.Handles.SurfaceKHR'
-- object (defined by the @VK_KHR_surface@ extension) that refers to a
-- DirectFB 'IDirectFBSurface', as well as a query to determine support for
-- rendering via DirectFB.
--
-- == New Commands
--
-- -   'createDirectFBSurfaceEXT'
--
-- -   'getPhysicalDeviceDirectFBPresentationSupportEXT'
--
-- == New Structures
--
-- -   'DirectFBSurfaceCreateInfoEXT'
--
-- == New Bitmasks
--
-- -   'DirectFBSurfaceCreateFlagsEXT'
--
-- == New Enum Constants
--
-- -   'EXT_DIRECTFB_SURFACE_EXTENSION_NAME'
--
-- -   'EXT_DIRECTFB_SURFACE_SPEC_VERSION'
--
-- -   Extending 'Vulkan.Core10.Enums.StructureType.StructureType':
--
--     -   'Vulkan.Core10.Enums.StructureType.STRUCTURE_TYPE_DIRECTFB_SURFACE_CREATE_INFO_EXT'
--
-- == Version History
--
-- -   Revision 1, 2020-06-16 (Nicolas Caramelli)
--
--     -   Initial version
--
-- == See Also
--
-- 'DirectFBSurfaceCreateFlagsEXT', 'DirectFBSurfaceCreateInfoEXT',
-- 'createDirectFBSurfaceEXT',
-- 'getPhysicalDeviceDirectFBPresentationSupportEXT'
--
-- == Document Notes
--
-- For more information, see the
-- <https://registry.khronos.org/vulkan/specs/1.3-extensions/html/vkspec.html#VK_EXT_directfb_surface Vulkan Specification>
--
-- This page is a generated document. Fixes and changes should be made to
-- the generator scripts, not directly.
module Vulkan.Extensions.VK_EXT_directfb_surface  ( createDirectFBSurfaceEXT
                                                  , getPhysicalDeviceDirectFBPresentationSupportEXT
                                                  , DirectFBSurfaceCreateInfoEXT(..)
                                                  , DirectFBSurfaceCreateFlagsEXT(..)
                                                  , EXT_DIRECTFB_SURFACE_SPEC_VERSION
                                                  , pattern EXT_DIRECTFB_SURFACE_SPEC_VERSION
                                                  , EXT_DIRECTFB_SURFACE_EXTENSION_NAME
                                                  , pattern EXT_DIRECTFB_SURFACE_EXTENSION_NAME
                                                  , IDirectFB
                                                  , IDirectFBSurface
                                                  , SurfaceKHR(..)
                                                  ) where

import Data.Bits (Bits)
import Data.Bits (FiniteBits)
import Vulkan.Internal.Utils (enumReadPrec)
import Vulkan.Internal.Utils (enumShowsPrec)
import Vulkan.Internal.Utils (traceAroundEvent)
import Control.Exception.Base (bracket)
import Control.Monad (unless)
import Control.Monad.IO.Class (liftIO)
import Foreign.Marshal.Alloc (allocaBytes)
import Foreign.Marshal.Alloc (callocBytes)
import Foreign.Marshal.Alloc (free)
import GHC.Base (when)
import GHC.IO (throwIO)
import GHC.Ptr (nullFunPtr)
import Foreign.Ptr (nullPtr)
import Foreign.Ptr (plusPtr)
import GHC.Show (showString)
import Numeric (showHex)
import Control.Monad.Trans.Class (lift)
import Control.Monad.Trans.Cont (evalContT)
import Vulkan.CStruct (FromCStruct)
import Vulkan.CStruct (FromCStruct(..))
import Vulkan.CStruct (ToCStruct)
import Vulkan.CStruct (ToCStruct(..))
import Vulkan.Zero (Zero)
import Vulkan.Zero (Zero(..))
import Control.Monad.IO.Class (MonadIO)
import Data.String (IsString)
import Data.Typeable (Typeable)
import Foreign.Storable (Storable)
import Foreign.Storable (Storable(peek))
import Foreign.Storable (Storable(poke))
import qualified Foreign.Storable (Storable(..))
import GHC.Generics (Generic)
import GHC.IO.Exception (IOErrorType(..))
import GHC.IO.Exception (IOException(..))
import Foreign.Ptr (FunPtr)
import Foreign.Ptr (Ptr)
import GHC.Read (Read(readPrec))
import GHC.Show (Show(showsPrec))
import Data.Word (Word32)
import Data.Kind (Type)
import Control.Monad.Trans.Cont (ContT(..))
import Vulkan.Core10.FundamentalTypes (bool32ToBool)
import Vulkan.NamedType ((:::))
import Vulkan.Core10.AllocationCallbacks (AllocationCallbacks)
import Vulkan.Core10.FundamentalTypes (Bool32)
import Vulkan.Core10.FundamentalTypes (Bool32(..))
import Vulkan.Core10.FundamentalTypes (Flags)
import Vulkan.Core10.Handles (Instance)
import Vulkan.Core10.Handles (Instance(..))
import Vulkan.Core10.Handles (Instance(Instance))
import Vulkan.Dynamic (InstanceCmds(pVkCreateDirectFBSurfaceEXT))
import Vulkan.Dynamic (InstanceCmds(pVkGetPhysicalDeviceDirectFBPresentationSupportEXT))
import Vulkan.Core10.Handles (Instance_T)
import Vulkan.Core10.Handles (PhysicalDevice)
import Vulkan.Core10.Handles (PhysicalDevice(..))
import Vulkan.Core10.Handles (PhysicalDevice(PhysicalDevice))
import Vulkan.Core10.Handles (PhysicalDevice_T)
import Vulkan.Core10.Enums.Result (Result)
import Vulkan.Core10.Enums.Result (Result(..))
import Vulkan.Core10.Enums.StructureType (StructureType)
import Vulkan.Extensions.Handles (SurfaceKHR)
import Vulkan.Extensions.Handles (SurfaceKHR(..))
import Vulkan.Exception (VulkanException(..))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_DIRECTFB_SURFACE_CREATE_INFO_EXT))
import Vulkan.Core10.Enums.Result (Result(SUCCESS))
import Vulkan.Extensions.Handles (SurfaceKHR(..))
foreign import ccall
#if !defined(SAFE_FOREIGN_CALLS)
  unsafe
#endif
  "dynamic" mkVkCreateDirectFBSurfaceEXT
  :: FunPtr (Ptr Instance_T -> Ptr DirectFBSurfaceCreateInfoEXT -> Ptr AllocationCallbacks -> Ptr SurfaceKHR -> IO Result) -> Ptr Instance_T -> Ptr DirectFBSurfaceCreateInfoEXT -> Ptr AllocationCallbacks -> Ptr SurfaceKHR -> IO Result

-- | vkCreateDirectFBSurfaceEXT - Create a
-- 'Vulkan.Extensions.Handles.SurfaceKHR' object for a DirectFB surface
--
-- == Valid Usage (Implicit)
--
-- -   #VUID-vkCreateDirectFBSurfaceEXT-instance-parameter# @instance@
--     /must/ be a valid 'Vulkan.Core10.Handles.Instance' handle
--
-- -   #VUID-vkCreateDirectFBSurfaceEXT-pCreateInfo-parameter#
--     @pCreateInfo@ /must/ be a valid pointer to a valid
--     'DirectFBSurfaceCreateInfoEXT' structure
--
-- -   #VUID-vkCreateDirectFBSurfaceEXT-pAllocator-parameter# If
--     @pAllocator@ is not @NULL@, @pAllocator@ /must/ be a valid pointer
--     to a valid 'Vulkan.Core10.AllocationCallbacks.AllocationCallbacks'
--     structure
--
-- -   #VUID-vkCreateDirectFBSurfaceEXT-pSurface-parameter# @pSurface@
--     /must/ be a valid pointer to a
--     'Vulkan.Extensions.Handles.SurfaceKHR' handle
--
-- == Return Codes
--
-- [<https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#fundamentals-successcodes Success>]
--
--     -   'Vulkan.Core10.Enums.Result.SUCCESS'
--
-- [<https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#fundamentals-errorcodes Failure>]
--
--     -   'Vulkan.Core10.Enums.Result.ERROR_OUT_OF_HOST_MEMORY'
--
--     -   'Vulkan.Core10.Enums.Result.ERROR_OUT_OF_DEVICE_MEMORY'
--
-- = See Also
--
-- <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#VK_EXT_directfb_surface VK_EXT_directfb_surface>,
-- 'Vulkan.Core10.AllocationCallbacks.AllocationCallbacks',
-- 'DirectFBSurfaceCreateInfoEXT', 'Vulkan.Core10.Handles.Instance',
-- 'Vulkan.Extensions.Handles.SurfaceKHR'
createDirectFBSurfaceEXT :: forall io
                          . (MonadIO io)
                         => -- | @instance@ is the instance to associate the surface with.
                            Instance
                         -> -- | @pCreateInfo@ is a pointer to a 'DirectFBSurfaceCreateInfoEXT' structure
                            -- containing parameters affecting the creation of the surface object.
                            DirectFBSurfaceCreateInfoEXT
                         -> -- | @pAllocator@ is the allocator used for host memory allocated for the
                            -- surface object when there is no more specific allocator available (see
                            -- <https://registry.khronos.org/vulkan/specs/1.3-extensions/html/vkspec.html#memory-allocation Memory Allocation>).
                            ("allocator" ::: Maybe AllocationCallbacks)
                         -> io (SurfaceKHR)
createDirectFBSurfaceEXT :: forall (io :: * -> *).
MonadIO io =>
Instance
-> DirectFBSurfaceCreateInfoEXT
-> ("allocator" ::: Maybe AllocationCallbacks)
-> io SurfaceKHR
createDirectFBSurfaceEXT Instance
instance'
                           DirectFBSurfaceCreateInfoEXT
createInfo
                           "allocator" ::: Maybe AllocationCallbacks
allocator = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall b c a. (b -> c) -> (a -> b) -> a -> c
. forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT forall a b. (a -> b) -> a -> b
$ do
  let vkCreateDirectFBSurfaceEXTPtr :: FunPtr
  (Ptr Instance_T
   -> ("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
   -> ("pAllocator" ::: Ptr AllocationCallbacks)
   -> ("pSurface" ::: Ptr SurfaceKHR)
   -> IO Result)
vkCreateDirectFBSurfaceEXTPtr = InstanceCmds
-> FunPtr
     (Ptr Instance_T
      -> ("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
      -> ("pAllocator" ::: Ptr AllocationCallbacks)
      -> ("pSurface" ::: Ptr SurfaceKHR)
      -> IO Result)
pVkCreateDirectFBSurfaceEXT (case Instance
instance' of Instance{InstanceCmds
$sel:instanceCmds:Instance :: Instance -> InstanceCmds
instanceCmds :: InstanceCmds
instanceCmds} -> InstanceCmds
instanceCmds)
  forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift forall a b. (a -> b) -> a -> b
$ forall (f :: * -> *). Applicative f => Bool -> f () -> f ()
unless (FunPtr
  (Ptr Instance_T
   -> ("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
   -> ("pAllocator" ::: Ptr AllocationCallbacks)
   -> ("pSurface" ::: Ptr SurfaceKHR)
   -> IO Result)
vkCreateDirectFBSurfaceEXTPtr forall a. Eq a => a -> a -> Bool
/= forall a. FunPtr a
nullFunPtr) forall a b. (a -> b) -> a -> b
$
    forall e a. Exception e => e -> IO a
throwIO forall a b. (a -> b) -> a -> b
$ Maybe Handle
-> IOErrorType
-> String
-> String
-> Maybe CInt
-> Maybe String
-> IOException
IOError forall a. Maybe a
Nothing IOErrorType
InvalidArgument String
"" String
"The function pointer for vkCreateDirectFBSurfaceEXT is null" forall a. Maybe a
Nothing forall a. Maybe a
Nothing
  let vkCreateDirectFBSurfaceEXT' :: Ptr Instance_T
-> ("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pSurface" ::: Ptr SurfaceKHR)
-> IO Result
vkCreateDirectFBSurfaceEXT' = FunPtr
  (Ptr Instance_T
   -> ("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
   -> ("pAllocator" ::: Ptr AllocationCallbacks)
   -> ("pSurface" ::: Ptr SurfaceKHR)
   -> IO Result)
-> Ptr Instance_T
-> ("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pSurface" ::: Ptr SurfaceKHR)
-> IO Result
mkVkCreateDirectFBSurfaceEXT FunPtr
  (Ptr Instance_T
   -> ("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
   -> ("pAllocator" ::: Ptr AllocationCallbacks)
   -> ("pSurface" ::: Ptr SurfaceKHR)
   -> IO Result)
vkCreateDirectFBSurfaceEXTPtr
  "pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
pCreateInfo <- forall {k} (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT forall a b. (a -> b) -> a -> b
$ forall a b. ToCStruct a => a -> (Ptr a -> IO b) -> IO b
withCStruct (DirectFBSurfaceCreateInfoEXT
createInfo)
  "pAllocator" ::: Ptr AllocationCallbacks
pAllocator <- case ("allocator" ::: Maybe AllocationCallbacks
allocator) of
    "allocator" ::: Maybe AllocationCallbacks
Nothing -> forall (f :: * -> *) a. Applicative f => a -> f a
pure forall a. Ptr a
nullPtr
    Just AllocationCallbacks
j -> forall {k} (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT forall a b. (a -> b) -> a -> b
$ forall a b. ToCStruct a => a -> (Ptr a -> IO b) -> IO b
withCStruct (AllocationCallbacks
j)
  "pSurface" ::: Ptr SurfaceKHR
pPSurface <- forall {k} (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT forall a b. (a -> b) -> a -> b
$ forall a b c. IO a -> (a -> IO b) -> (a -> IO c) -> IO c
bracket (forall a. Int -> IO (Ptr a)
callocBytes @SurfaceKHR Int
8) forall a. Ptr a -> IO ()
free
  Result
r <- forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift forall a b. (a -> b) -> a -> b
$ forall a. String -> IO a -> IO a
traceAroundEvent String
"vkCreateDirectFBSurfaceEXT" (Ptr Instance_T
-> ("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pSurface" ::: Ptr SurfaceKHR)
-> IO Result
vkCreateDirectFBSurfaceEXT'
                                                               (Instance -> Ptr Instance_T
instanceHandle (Instance
instance'))
                                                               "pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
pCreateInfo
                                                               "pAllocator" ::: Ptr AllocationCallbacks
pAllocator
                                                               ("pSurface" ::: Ptr SurfaceKHR
pPSurface))
  forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift forall a b. (a -> b) -> a -> b
$ forall (f :: * -> *). Applicative f => Bool -> f () -> f ()
when (Result
r forall a. Ord a => a -> a -> Bool
< Result
SUCCESS) (forall e a. Exception e => e -> IO a
throwIO (Result -> VulkanException
VulkanException Result
r))
  SurfaceKHR
pSurface <- forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift forall a b. (a -> b) -> a -> b
$ forall a. Storable a => Ptr a -> IO a
peek @SurfaceKHR "pSurface" ::: Ptr SurfaceKHR
pPSurface
  forall (f :: * -> *) a. Applicative f => a -> f a
pure forall a b. (a -> b) -> a -> b
$ (SurfaceKHR
pSurface)


foreign import ccall
#if !defined(SAFE_FOREIGN_CALLS)
  unsafe
#endif
  "dynamic" mkVkGetPhysicalDeviceDirectFBPresentationSupportEXT
  :: FunPtr (Ptr PhysicalDevice_T -> Word32 -> Ptr IDirectFB -> IO Bool32) -> Ptr PhysicalDevice_T -> Word32 -> Ptr IDirectFB -> IO Bool32

-- | vkGetPhysicalDeviceDirectFBPresentationSupportEXT - Query physical
-- device for presentation with DirectFB
--
-- = Description
--
-- This platform-specific function /can/ be called prior to creating a
-- surface.
--
-- == Valid Usage (Implicit)
--
-- = See Also
--
-- <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#VK_EXT_directfb_surface VK_EXT_directfb_surface>,
-- 'Vulkan.Core10.Handles.PhysicalDevice'
getPhysicalDeviceDirectFBPresentationSupportEXT :: forall io
                                                 . (MonadIO io)
                                                => -- | @physicalDevice@ is the physical device.
                                                   --
                                                   -- #VUID-vkGetPhysicalDeviceDirectFBPresentationSupportEXT-physicalDevice-parameter#
                                                   -- @physicalDevice@ /must/ be a valid
                                                   -- 'Vulkan.Core10.Handles.PhysicalDevice' handle
                                                   PhysicalDevice
                                                -> -- | @queueFamilyIndex@ is the queue family index.
                                                   --
                                                   -- #VUID-vkGetPhysicalDeviceDirectFBPresentationSupportEXT-queueFamilyIndex-04119#
                                                   -- @queueFamilyIndex@ /must/ be less than @pQueueFamilyPropertyCount@
                                                   -- returned by
                                                   -- 'Vulkan.Core10.DeviceInitialization.getPhysicalDeviceQueueFamilyProperties'
                                                   -- for the given @physicalDevice@
                                                   ("queueFamilyIndex" ::: Word32)
                                                -> -- | @dfb@ is a pointer to the 'IDirectFB' main interface of DirectFB.
                                                   --
                                                   -- #VUID-vkGetPhysicalDeviceDirectFBPresentationSupportEXT-dfb-parameter#
                                                   -- @dfb@ /must/ be a valid pointer to an 'IDirectFB' value
                                                   ("dfb" ::: Ptr IDirectFB)
                                                -> io (Bool)
getPhysicalDeviceDirectFBPresentationSupportEXT :: forall (io :: * -> *).
MonadIO io =>
PhysicalDevice
-> ("queueFamilyIndex" ::: Word32)
-> ("dfb" ::: Ptr IDirectFB)
-> io Bool
getPhysicalDeviceDirectFBPresentationSupportEXT PhysicalDevice
physicalDevice
                                                  "queueFamilyIndex" ::: Word32
queueFamilyIndex
                                                  "dfb" ::: Ptr IDirectFB
dfb = forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO forall a b. (a -> b) -> a -> b
$ do
  let vkGetPhysicalDeviceDirectFBPresentationSupportEXTPtr :: FunPtr
  (Ptr PhysicalDevice_T
   -> ("queueFamilyIndex" ::: Word32)
   -> ("dfb" ::: Ptr IDirectFB)
   -> IO Bool32)
vkGetPhysicalDeviceDirectFBPresentationSupportEXTPtr = InstanceCmds
-> FunPtr
     (Ptr PhysicalDevice_T
      -> ("queueFamilyIndex" ::: Word32)
      -> ("dfb" ::: Ptr IDirectFB)
      -> IO Bool32)
pVkGetPhysicalDeviceDirectFBPresentationSupportEXT (case PhysicalDevice
physicalDevice of PhysicalDevice{InstanceCmds
$sel:instanceCmds:PhysicalDevice :: PhysicalDevice -> InstanceCmds
instanceCmds :: InstanceCmds
instanceCmds} -> InstanceCmds
instanceCmds)
  forall (f :: * -> *). Applicative f => Bool -> f () -> f ()
unless (FunPtr
  (Ptr PhysicalDevice_T
   -> ("queueFamilyIndex" ::: Word32)
   -> ("dfb" ::: Ptr IDirectFB)
   -> IO Bool32)
vkGetPhysicalDeviceDirectFBPresentationSupportEXTPtr forall a. Eq a => a -> a -> Bool
/= forall a. FunPtr a
nullFunPtr) forall a b. (a -> b) -> a -> b
$
    forall e a. Exception e => e -> IO a
throwIO forall a b. (a -> b) -> a -> b
$ Maybe Handle
-> IOErrorType
-> String
-> String
-> Maybe CInt
-> Maybe String
-> IOException
IOError forall a. Maybe a
Nothing IOErrorType
InvalidArgument String
"" String
"The function pointer for vkGetPhysicalDeviceDirectFBPresentationSupportEXT is null" forall a. Maybe a
Nothing forall a. Maybe a
Nothing
  let vkGetPhysicalDeviceDirectFBPresentationSupportEXT' :: Ptr PhysicalDevice_T
-> ("queueFamilyIndex" ::: Word32)
-> ("dfb" ::: Ptr IDirectFB)
-> IO Bool32
vkGetPhysicalDeviceDirectFBPresentationSupportEXT' = FunPtr
  (Ptr PhysicalDevice_T
   -> ("queueFamilyIndex" ::: Word32)
   -> ("dfb" ::: Ptr IDirectFB)
   -> IO Bool32)
-> Ptr PhysicalDevice_T
-> ("queueFamilyIndex" ::: Word32)
-> ("dfb" ::: Ptr IDirectFB)
-> IO Bool32
mkVkGetPhysicalDeviceDirectFBPresentationSupportEXT FunPtr
  (Ptr PhysicalDevice_T
   -> ("queueFamilyIndex" ::: Word32)
   -> ("dfb" ::: Ptr IDirectFB)
   -> IO Bool32)
vkGetPhysicalDeviceDirectFBPresentationSupportEXTPtr
  Bool32
r <- forall a. String -> IO a -> IO a
traceAroundEvent String
"vkGetPhysicalDeviceDirectFBPresentationSupportEXT" (Ptr PhysicalDevice_T
-> ("queueFamilyIndex" ::: Word32)
-> ("dfb" ::: Ptr IDirectFB)
-> IO Bool32
vkGetPhysicalDeviceDirectFBPresentationSupportEXT'
                                                                               (PhysicalDevice -> Ptr PhysicalDevice_T
physicalDeviceHandle (PhysicalDevice
physicalDevice))
                                                                               ("queueFamilyIndex" ::: Word32
queueFamilyIndex)
                                                                               ("dfb" ::: Ptr IDirectFB
dfb))
  forall (f :: * -> *) a. Applicative f => a -> f a
pure forall a b. (a -> b) -> a -> b
$ ((Bool32 -> Bool
bool32ToBool Bool32
r))


-- | VkDirectFBSurfaceCreateInfoEXT - Structure specifying parameters of a
-- newly created DirectFB surface object
--
-- == Valid Usage (Implicit)
--
-- = See Also
--
-- <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#VK_EXT_directfb_surface VK_EXT_directfb_surface>,
-- 'DirectFBSurfaceCreateFlagsEXT',
-- 'Vulkan.Core10.Enums.StructureType.StructureType',
-- 'createDirectFBSurfaceEXT'
data DirectFBSurfaceCreateInfoEXT = DirectFBSurfaceCreateInfoEXT
  { -- | @flags@ is reserved for future use.
    --
    -- #VUID-VkDirectFBSurfaceCreateInfoEXT-flags-zerobitmask# @flags@ /must/
    -- be @0@
    DirectFBSurfaceCreateInfoEXT -> DirectFBSurfaceCreateFlagsEXT
flags :: DirectFBSurfaceCreateFlagsEXT
  , -- | @dfb@ is a pointer to the 'IDirectFB' main interface of DirectFB.
    --
    -- #VUID-VkDirectFBSurfaceCreateInfoEXT-dfb-04117# @dfb@ /must/ point to a
    -- valid DirectFB 'IDirectFB'
    DirectFBSurfaceCreateInfoEXT -> "dfb" ::: Ptr IDirectFB
dfb :: Ptr IDirectFB
  , -- | @surface@ is a pointer to a 'IDirectFBSurface' surface interface.
    --
    -- #VUID-VkDirectFBSurfaceCreateInfoEXT-surface-04118# @surface@ /must/
    -- point to a valid DirectFB 'IDirectFBSurface'
    DirectFBSurfaceCreateInfoEXT -> Ptr IDirectFBSurface
surface :: Ptr IDirectFBSurface
  }
  deriving (Typeable, DirectFBSurfaceCreateInfoEXT
-> DirectFBSurfaceCreateInfoEXT -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DirectFBSurfaceCreateInfoEXT
-> DirectFBSurfaceCreateInfoEXT -> Bool
$c/= :: DirectFBSurfaceCreateInfoEXT
-> DirectFBSurfaceCreateInfoEXT -> Bool
== :: DirectFBSurfaceCreateInfoEXT
-> DirectFBSurfaceCreateInfoEXT -> Bool
$c== :: DirectFBSurfaceCreateInfoEXT
-> DirectFBSurfaceCreateInfoEXT -> Bool
Eq)
#if defined(GENERIC_INSTANCES)
deriving instance Generic (DirectFBSurfaceCreateInfoEXT)
#endif
deriving instance Show DirectFBSurfaceCreateInfoEXT

instance ToCStruct DirectFBSurfaceCreateInfoEXT where
  withCStruct :: forall b.
DirectFBSurfaceCreateInfoEXT
-> (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT) -> IO b)
-> IO b
withCStruct DirectFBSurfaceCreateInfoEXT
x ("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT) -> IO b
f = forall a b. Int -> (Ptr a -> IO b) -> IO b
allocaBytes Int
40 forall a b. (a -> b) -> a -> b
$ \"pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p -> forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct "pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p DirectFBSurfaceCreateInfoEXT
x (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT) -> IO b
f "pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p)
  pokeCStruct :: forall b.
("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
-> DirectFBSurfaceCreateInfoEXT -> IO b -> IO b
pokeCStruct "pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p DirectFBSurfaceCreateInfoEXT{"dfb" ::: Ptr IDirectFB
Ptr IDirectFBSurface
DirectFBSurfaceCreateFlagsEXT
surface :: Ptr IDirectFBSurface
dfb :: "dfb" ::: Ptr IDirectFB
flags :: DirectFBSurfaceCreateFlagsEXT
$sel:surface:DirectFBSurfaceCreateInfoEXT :: DirectFBSurfaceCreateInfoEXT -> Ptr IDirectFBSurface
$sel:dfb:DirectFBSurfaceCreateInfoEXT :: DirectFBSurfaceCreateInfoEXT -> "dfb" ::: Ptr IDirectFB
$sel:flags:DirectFBSurfaceCreateInfoEXT :: DirectFBSurfaceCreateInfoEXT -> DirectFBSurfaceCreateFlagsEXT
..} IO b
f = do
    forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_DIRECTFB_SURFACE_CREATE_INFO_EXT)
    forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
8 :: Ptr (Ptr ()))) (forall a. Ptr a
nullPtr)
    forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
16 :: Ptr DirectFBSurfaceCreateFlagsEXT)) (DirectFBSurfaceCreateFlagsEXT
flags)
    forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
24 :: Ptr (Ptr IDirectFB))) ("dfb" ::: Ptr IDirectFB
dfb)
    forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
32 :: Ptr (Ptr IDirectFBSurface))) (Ptr IDirectFBSurface
surface)
    IO b
f
  cStructSize :: Int
cStructSize = Int
40
  cStructAlignment :: Int
cStructAlignment = Int
8
  pokeZeroCStruct :: forall b.
("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
-> IO b -> IO b
pokeZeroCStruct "pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p IO b
f = do
    forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_DIRECTFB_SURFACE_CREATE_INFO_EXT)
    forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
8 :: Ptr (Ptr ()))) (forall a. Ptr a
nullPtr)
    forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
24 :: Ptr (Ptr IDirectFB))) (forall a. Zero a => a
zero)
    forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
32 :: Ptr (Ptr IDirectFBSurface))) (forall a. Zero a => a
zero)
    IO b
f

instance FromCStruct DirectFBSurfaceCreateInfoEXT where
  peekCStruct :: ("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
-> IO DirectFBSurfaceCreateInfoEXT
peekCStruct "pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p = do
    DirectFBSurfaceCreateFlagsEXT
flags <- forall a. Storable a => Ptr a -> IO a
peek @DirectFBSurfaceCreateFlagsEXT (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
16 :: Ptr DirectFBSurfaceCreateFlagsEXT))
    "dfb" ::: Ptr IDirectFB
dfb <- forall a. Storable a => Ptr a -> IO a
peek @(Ptr IDirectFB) (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
24 :: Ptr (Ptr IDirectFB)))
    Ptr IDirectFBSurface
surface <- forall a. Storable a => Ptr a -> IO a
peek @(Ptr IDirectFBSurface) (("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
p forall a b. Ptr a -> Int -> Ptr b
`plusPtr` Int
32 :: Ptr (Ptr IDirectFBSurface)))
    forall (f :: * -> *) a. Applicative f => a -> f a
pure forall a b. (a -> b) -> a -> b
$ DirectFBSurfaceCreateFlagsEXT
-> ("dfb" ::: Ptr IDirectFB)
-> Ptr IDirectFBSurface
-> DirectFBSurfaceCreateInfoEXT
DirectFBSurfaceCreateInfoEXT
             DirectFBSurfaceCreateFlagsEXT
flags "dfb" ::: Ptr IDirectFB
dfb Ptr IDirectFBSurface
surface

instance Storable DirectFBSurfaceCreateInfoEXT where
  sizeOf :: DirectFBSurfaceCreateInfoEXT -> Int
sizeOf ~DirectFBSurfaceCreateInfoEXT
_ = Int
40
  alignment :: DirectFBSurfaceCreateInfoEXT -> Int
alignment ~DirectFBSurfaceCreateInfoEXT
_ = Int
8
  peek :: ("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
-> IO DirectFBSurfaceCreateInfoEXT
peek = forall a. FromCStruct a => Ptr a -> IO a
peekCStruct
  poke :: ("pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT)
-> DirectFBSurfaceCreateInfoEXT -> IO ()
poke "pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
ptr DirectFBSurfaceCreateInfoEXT
poked = forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct "pCreateInfo" ::: Ptr DirectFBSurfaceCreateInfoEXT
ptr DirectFBSurfaceCreateInfoEXT
poked (forall (f :: * -> *) a. Applicative f => a -> f a
pure ())

instance Zero DirectFBSurfaceCreateInfoEXT where
  zero :: DirectFBSurfaceCreateInfoEXT
zero = DirectFBSurfaceCreateFlagsEXT
-> ("dfb" ::: Ptr IDirectFB)
-> Ptr IDirectFBSurface
-> DirectFBSurfaceCreateInfoEXT
DirectFBSurfaceCreateInfoEXT
           forall a. Zero a => a
zero
           forall a. Zero a => a
zero
           forall a. Zero a => a
zero


-- | VkDirectFBSurfaceCreateFlagsEXT - Reserved for future use
--
-- = Description
--
-- 'DirectFBSurfaceCreateFlagsEXT' is a bitmask type for setting a mask,
-- but is currently reserved for future use.
--
-- = See Also
--
-- <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#VK_EXT_directfb_surface VK_EXT_directfb_surface>,
-- 'DirectFBSurfaceCreateInfoEXT'
newtype DirectFBSurfaceCreateFlagsEXT = DirectFBSurfaceCreateFlagsEXT Flags
  deriving newtype (DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
$c/= :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
== :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
$c== :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
Eq, Eq DirectFBSurfaceCreateFlagsEXT
DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Ordering
DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
forall a.
Eq a
-> (a -> a -> Ordering)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
min :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
$cmin :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
max :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
$cmax :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
>= :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
$c>= :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
> :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
$c> :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
<= :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
$c<= :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
< :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
$c< :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Bool
compare :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Ordering
$ccompare :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> Ordering
Ord, Ptr DirectFBSurfaceCreateFlagsEXT
-> IO DirectFBSurfaceCreateFlagsEXT
Ptr DirectFBSurfaceCreateFlagsEXT
-> Int -> IO DirectFBSurfaceCreateFlagsEXT
Ptr DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT -> IO ()
Ptr DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> IO ()
DirectFBSurfaceCreateFlagsEXT -> Int
forall b. Ptr b -> Int -> IO DirectFBSurfaceCreateFlagsEXT
forall b. Ptr b -> Int -> DirectFBSurfaceCreateFlagsEXT -> IO ()
forall a.
(a -> Int)
-> (a -> Int)
-> (Ptr a -> Int -> IO a)
-> (Ptr a -> Int -> a -> IO ())
-> (forall b. Ptr b -> Int -> IO a)
-> (forall b. Ptr b -> Int -> a -> IO ())
-> (Ptr a -> IO a)
-> (Ptr a -> a -> IO ())
-> Storable a
poke :: Ptr DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> IO ()
$cpoke :: Ptr DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> IO ()
peek :: Ptr DirectFBSurfaceCreateFlagsEXT
-> IO DirectFBSurfaceCreateFlagsEXT
$cpeek :: Ptr DirectFBSurfaceCreateFlagsEXT
-> IO DirectFBSurfaceCreateFlagsEXT
pokeByteOff :: forall b. Ptr b -> Int -> DirectFBSurfaceCreateFlagsEXT -> IO ()
$cpokeByteOff :: forall b. Ptr b -> Int -> DirectFBSurfaceCreateFlagsEXT -> IO ()
peekByteOff :: forall b. Ptr b -> Int -> IO DirectFBSurfaceCreateFlagsEXT
$cpeekByteOff :: forall b. Ptr b -> Int -> IO DirectFBSurfaceCreateFlagsEXT
pokeElemOff :: Ptr DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT -> IO ()
$cpokeElemOff :: Ptr DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT -> IO ()
peekElemOff :: Ptr DirectFBSurfaceCreateFlagsEXT
-> Int -> IO DirectFBSurfaceCreateFlagsEXT
$cpeekElemOff :: Ptr DirectFBSurfaceCreateFlagsEXT
-> Int -> IO DirectFBSurfaceCreateFlagsEXT
alignment :: DirectFBSurfaceCreateFlagsEXT -> Int
$calignment :: DirectFBSurfaceCreateFlagsEXT -> Int
sizeOf :: DirectFBSurfaceCreateFlagsEXT -> Int
$csizeOf :: DirectFBSurfaceCreateFlagsEXT -> Int
Storable, DirectFBSurfaceCreateFlagsEXT
forall a. a -> Zero a
zero :: DirectFBSurfaceCreateFlagsEXT
$czero :: DirectFBSurfaceCreateFlagsEXT
Zero, Eq DirectFBSurfaceCreateFlagsEXT
DirectFBSurfaceCreateFlagsEXT
Int -> DirectFBSurfaceCreateFlagsEXT
DirectFBSurfaceCreateFlagsEXT -> Bool
DirectFBSurfaceCreateFlagsEXT -> Int
DirectFBSurfaceCreateFlagsEXT -> Maybe Int
DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
DirectFBSurfaceCreateFlagsEXT -> Int -> Bool
DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
forall a.
Eq a
-> (a -> a -> a)
-> (a -> a -> a)
-> (a -> a -> a)
-> (a -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> a
-> (Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> Bool)
-> (a -> Maybe Int)
-> (a -> Int)
-> (a -> Bool)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int)
-> Bits a
popCount :: DirectFBSurfaceCreateFlagsEXT -> Int
$cpopCount :: DirectFBSurfaceCreateFlagsEXT -> Int
rotateR :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
$crotateR :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
rotateL :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
$crotateL :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
unsafeShiftR :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
$cunsafeShiftR :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
shiftR :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
$cshiftR :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
unsafeShiftL :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
$cunsafeShiftL :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
shiftL :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
$cshiftL :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
isSigned :: DirectFBSurfaceCreateFlagsEXT -> Bool
$cisSigned :: DirectFBSurfaceCreateFlagsEXT -> Bool
bitSize :: DirectFBSurfaceCreateFlagsEXT -> Int
$cbitSize :: DirectFBSurfaceCreateFlagsEXT -> Int
bitSizeMaybe :: DirectFBSurfaceCreateFlagsEXT -> Maybe Int
$cbitSizeMaybe :: DirectFBSurfaceCreateFlagsEXT -> Maybe Int
testBit :: DirectFBSurfaceCreateFlagsEXT -> Int -> Bool
$ctestBit :: DirectFBSurfaceCreateFlagsEXT -> Int -> Bool
complementBit :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
$ccomplementBit :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
clearBit :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
$cclearBit :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
setBit :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
$csetBit :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
bit :: Int -> DirectFBSurfaceCreateFlagsEXT
$cbit :: Int -> DirectFBSurfaceCreateFlagsEXT
zeroBits :: DirectFBSurfaceCreateFlagsEXT
$czeroBits :: DirectFBSurfaceCreateFlagsEXT
rotate :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
$crotate :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
shift :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
$cshift :: DirectFBSurfaceCreateFlagsEXT
-> Int -> DirectFBSurfaceCreateFlagsEXT
complement :: DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
$ccomplement :: DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
xor :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
$cxor :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
.|. :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
$c.|. :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
.&. :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
$c.&. :: DirectFBSurfaceCreateFlagsEXT
-> DirectFBSurfaceCreateFlagsEXT -> DirectFBSurfaceCreateFlagsEXT
Bits, Bits DirectFBSurfaceCreateFlagsEXT
DirectFBSurfaceCreateFlagsEXT -> Int
forall b.
Bits b -> (b -> Int) -> (b -> Int) -> (b -> Int) -> FiniteBits b
countTrailingZeros :: DirectFBSurfaceCreateFlagsEXT -> Int
$ccountTrailingZeros :: DirectFBSurfaceCreateFlagsEXT -> Int
countLeadingZeros :: DirectFBSurfaceCreateFlagsEXT -> Int
$ccountLeadingZeros :: DirectFBSurfaceCreateFlagsEXT -> Int
finiteBitSize :: DirectFBSurfaceCreateFlagsEXT -> Int
$cfiniteBitSize :: DirectFBSurfaceCreateFlagsEXT -> Int
FiniteBits)

conNameDirectFBSurfaceCreateFlagsEXT :: String
conNameDirectFBSurfaceCreateFlagsEXT :: String
conNameDirectFBSurfaceCreateFlagsEXT = String
"DirectFBSurfaceCreateFlagsEXT"

enumPrefixDirectFBSurfaceCreateFlagsEXT :: String
enumPrefixDirectFBSurfaceCreateFlagsEXT :: String
enumPrefixDirectFBSurfaceCreateFlagsEXT = String
""

showTableDirectFBSurfaceCreateFlagsEXT :: [(DirectFBSurfaceCreateFlagsEXT, String)]
showTableDirectFBSurfaceCreateFlagsEXT :: [(DirectFBSurfaceCreateFlagsEXT, String)]
showTableDirectFBSurfaceCreateFlagsEXT = []

instance Show DirectFBSurfaceCreateFlagsEXT where
  showsPrec :: Int -> DirectFBSurfaceCreateFlagsEXT -> ShowS
showsPrec =
    forall a i.
Eq a =>
String
-> [(a, String)]
-> String
-> (a -> i)
-> (i -> ShowS)
-> Int
-> a
-> ShowS
enumShowsPrec
      String
enumPrefixDirectFBSurfaceCreateFlagsEXT
      [(DirectFBSurfaceCreateFlagsEXT, String)]
showTableDirectFBSurfaceCreateFlagsEXT
      String
conNameDirectFBSurfaceCreateFlagsEXT
      (\(DirectFBSurfaceCreateFlagsEXT "queueFamilyIndex" ::: Word32
x) -> "queueFamilyIndex" ::: Word32
x)
      (\"queueFamilyIndex" ::: Word32
x -> String -> ShowS
showString String
"0x" forall b c a. (b -> c) -> (a -> b) -> a -> c
. forall a. (Integral a, Show a) => a -> ShowS
showHex "queueFamilyIndex" ::: Word32
x)

instance Read DirectFBSurfaceCreateFlagsEXT where
  readPrec :: ReadPrec DirectFBSurfaceCreateFlagsEXT
readPrec =
    forall i a.
Read i =>
String -> [(a, String)] -> String -> (i -> a) -> ReadPrec a
enumReadPrec
      String
enumPrefixDirectFBSurfaceCreateFlagsEXT
      [(DirectFBSurfaceCreateFlagsEXT, String)]
showTableDirectFBSurfaceCreateFlagsEXT
      String
conNameDirectFBSurfaceCreateFlagsEXT
      ("queueFamilyIndex" ::: Word32) -> DirectFBSurfaceCreateFlagsEXT
DirectFBSurfaceCreateFlagsEXT

type EXT_DIRECTFB_SURFACE_SPEC_VERSION = 1

-- No documentation found for TopLevel "VK_EXT_DIRECTFB_SURFACE_SPEC_VERSION"
pattern EXT_DIRECTFB_SURFACE_SPEC_VERSION :: forall a . Integral a => a
pattern $bEXT_DIRECTFB_SURFACE_SPEC_VERSION :: forall a. Integral a => a
$mEXT_DIRECTFB_SURFACE_SPEC_VERSION :: forall {r} {a}.
Integral a =>
a -> ((# #) -> r) -> ((# #) -> r) -> r
EXT_DIRECTFB_SURFACE_SPEC_VERSION = 1


type EXT_DIRECTFB_SURFACE_EXTENSION_NAME = "VK_EXT_directfb_surface"

-- No documentation found for TopLevel "VK_EXT_DIRECTFB_SURFACE_EXTENSION_NAME"
pattern EXT_DIRECTFB_SURFACE_EXTENSION_NAME :: forall a . (Eq a, IsString a) => a
pattern $bEXT_DIRECTFB_SURFACE_EXTENSION_NAME :: forall a. (Eq a, IsString a) => a
$mEXT_DIRECTFB_SURFACE_EXTENSION_NAME :: forall {r} {a}.
(Eq a, IsString a) =>
a -> ((# #) -> r) -> ((# #) -> r) -> r
EXT_DIRECTFB_SURFACE_EXTENSION_NAME = "VK_EXT_directfb_surface"


data IDirectFB


data IDirectFBSurface