{-# language CPP #-}
module Vulkan.Extensions.VK_EXT_inline_uniform_block  ( PhysicalDeviceInlineUniformBlockFeaturesEXT(..)
                                                      , PhysicalDeviceInlineUniformBlockPropertiesEXT(..)
                                                      , WriteDescriptorSetInlineUniformBlockEXT(..)
                                                      , DescriptorPoolInlineUniformBlockCreateInfoEXT(..)
                                                      , EXT_INLINE_UNIFORM_BLOCK_SPEC_VERSION
                                                      , pattern EXT_INLINE_UNIFORM_BLOCK_SPEC_VERSION
                                                      , EXT_INLINE_UNIFORM_BLOCK_EXTENSION_NAME
                                                      , pattern EXT_INLINE_UNIFORM_BLOCK_EXTENSION_NAME
                                                      ) where

import Foreign.Marshal.Alloc (allocaBytesAligned)
import Foreign.Ptr (nullPtr)
import Foreign.Ptr (plusPtr)
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 Foreign.Ptr (Ptr)
import Data.Word (Word32)
import Data.Kind (Type)
import Vulkan.Core10.FundamentalTypes (bool32ToBool)
import Vulkan.Core10.FundamentalTypes (boolToBool32)
import Vulkan.Core10.FundamentalTypes (Bool32)
import Vulkan.CStruct (FromCStruct)
import Vulkan.CStruct (FromCStruct(..))
import Vulkan.Core10.Enums.StructureType (StructureType)
import Vulkan.CStruct (ToCStruct)
import Vulkan.CStruct (ToCStruct(..))
import Vulkan.Zero (Zero(..))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_DESCRIPTOR_POOL_INLINE_UNIFORM_BLOCK_CREATE_INFO_EXT))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_PHYSICAL_DEVICE_INLINE_UNIFORM_BLOCK_FEATURES_EXT))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_PHYSICAL_DEVICE_INLINE_UNIFORM_BLOCK_PROPERTIES_EXT))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_WRITE_DESCRIPTOR_SET_INLINE_UNIFORM_BLOCK_EXT))
-- | VkPhysicalDeviceInlineUniformBlockFeaturesEXT - Structure describing
-- inline uniform block features that can be supported by an implementation
--
-- = Members
--
-- The members of the 'PhysicalDeviceInlineUniformBlockFeaturesEXT'
-- structure describe the following features:
--
-- = Description
--
-- If the 'PhysicalDeviceInlineUniformBlockFeaturesEXT' structure is
-- included in the @pNext@ chain of
-- 'Vulkan.Core11.Promoted_From_VK_KHR_get_physical_device_properties2.PhysicalDeviceFeatures2',
-- it is filled with values indicating whether each feature is supported.
-- 'PhysicalDeviceInlineUniformBlockFeaturesEXT' /can/ also be included in
-- the @pNext@ chain of 'Vulkan.Core10.Device.DeviceCreateInfo' to enable
-- features.
--
-- == Valid Usage (Implicit)
--
-- = See Also
--
-- 'Vulkan.Core10.FundamentalTypes.Bool32',
-- 'Vulkan.Core10.Enums.StructureType.StructureType'
data PhysicalDeviceInlineUniformBlockFeaturesEXT = PhysicalDeviceInlineUniformBlockFeaturesEXT
  { -- | @inlineUniformBlock@ indicates whether the implementation supports
    -- inline uniform block descriptors. If this feature is not enabled,
    -- 'Vulkan.Core10.Enums.DescriptorType.DESCRIPTOR_TYPE_INLINE_UNIFORM_BLOCK_EXT'
    -- /must/ not be used.
    PhysicalDeviceInlineUniformBlockFeaturesEXT -> Bool
inlineUniformBlock :: Bool
  , -- | @descriptorBindingInlineUniformBlockUpdateAfterBind@ indicates whether
    -- the implementation supports updating inline uniform block descriptors
    -- after a set is bound. If this feature is not enabled,
    -- 'Vulkan.Core12.Enums.DescriptorBindingFlagBits.DESCRIPTOR_BINDING_UPDATE_AFTER_BIND_BIT'
    -- /must/ not be used with
    -- 'Vulkan.Core10.Enums.DescriptorType.DESCRIPTOR_TYPE_INLINE_UNIFORM_BLOCK_EXT'.
    PhysicalDeviceInlineUniformBlockFeaturesEXT -> Bool
descriptorBindingInlineUniformBlockUpdateAfterBind :: Bool
  }
  deriving (Typeable, PhysicalDeviceInlineUniformBlockFeaturesEXT
-> PhysicalDeviceInlineUniformBlockFeaturesEXT -> Bool
(PhysicalDeviceInlineUniformBlockFeaturesEXT
 -> PhysicalDeviceInlineUniformBlockFeaturesEXT -> Bool)
-> (PhysicalDeviceInlineUniformBlockFeaturesEXT
    -> PhysicalDeviceInlineUniformBlockFeaturesEXT -> Bool)
-> Eq PhysicalDeviceInlineUniformBlockFeaturesEXT
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PhysicalDeviceInlineUniformBlockFeaturesEXT
-> PhysicalDeviceInlineUniformBlockFeaturesEXT -> Bool
$c/= :: PhysicalDeviceInlineUniformBlockFeaturesEXT
-> PhysicalDeviceInlineUniformBlockFeaturesEXT -> Bool
== :: PhysicalDeviceInlineUniformBlockFeaturesEXT
-> PhysicalDeviceInlineUniformBlockFeaturesEXT -> Bool
$c== :: PhysicalDeviceInlineUniformBlockFeaturesEXT
-> PhysicalDeviceInlineUniformBlockFeaturesEXT -> Bool
Eq)
#if defined(GENERIC_INSTANCES)
deriving instance Generic (PhysicalDeviceInlineUniformBlockFeaturesEXT)
#endif
deriving instance Show PhysicalDeviceInlineUniformBlockFeaturesEXT

instance ToCStruct PhysicalDeviceInlineUniformBlockFeaturesEXT where
  withCStruct :: PhysicalDeviceInlineUniformBlockFeaturesEXT
-> (Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT -> IO b)
-> IO b
withCStruct x :: PhysicalDeviceInlineUniformBlockFeaturesEXT
x f :: Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT -> IO b
f = Int
-> Int
-> (Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT -> IO b)
-> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 24 8 ((Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT -> IO b) -> IO b)
-> (Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT -> IO b)
-> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p -> Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> PhysicalDeviceInlineUniformBlockFeaturesEXT -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p PhysicalDeviceInlineUniformBlockFeaturesEXT
x (Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT -> IO b
f Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p)
  pokeCStruct :: Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> PhysicalDeviceInlineUniformBlockFeaturesEXT -> IO b -> IO b
pokeCStruct p :: Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p PhysicalDeviceInlineUniformBlockFeaturesEXT{..} f :: IO b
f = do
    Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_PHYSICAL_DEVICE_INLINE_UNIFORM_BLOCK_FEATURES_EXT)
    Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
inlineUniformBlock))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
descriptorBindingInlineUniformBlockUpdateAfterBind))
    IO b
f
  cStructSize :: Int
cStructSize = 24
  cStructAlignment :: Int
cStructAlignment = 8
  pokeZeroCStruct :: Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT -> IO b -> IO b
pokeZeroCStruct p :: Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p f :: IO b
f = do
    Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_PHYSICAL_DEVICE_INLINE_UNIFORM_BLOCK_FEATURES_EXT)
    Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    Ptr Bool32 -> Bool32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Bool32)) (Bool -> Bool32
boolToBool32 (Bool
forall a. Zero a => a
zero))
    IO b
f

instance FromCStruct PhysicalDeviceInlineUniformBlockFeaturesEXT where
  peekCStruct :: Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> IO PhysicalDeviceInlineUniformBlockFeaturesEXT
peekCStruct p :: Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p = do
    Bool32
inlineUniformBlock <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Bool32))
    Bool32
descriptorBindingInlineUniformBlockUpdateAfterBind <- Ptr Bool32 -> IO Bool32
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
p Ptr PhysicalDeviceInlineUniformBlockFeaturesEXT
-> Int -> Ptr Bool32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Bool32))
    PhysicalDeviceInlineUniformBlockFeaturesEXT
-> IO PhysicalDeviceInlineUniformBlockFeaturesEXT
forall (f :: * -> *) a. Applicative f => a -> f a
pure (PhysicalDeviceInlineUniformBlockFeaturesEXT
 -> IO PhysicalDeviceInlineUniformBlockFeaturesEXT)
-> PhysicalDeviceInlineUniformBlockFeaturesEXT
-> IO PhysicalDeviceInlineUniformBlockFeaturesEXT
forall a b. (a -> b) -> a -> b
$ Bool -> Bool -> PhysicalDeviceInlineUniformBlockFeaturesEXT
PhysicalDeviceInlineUniformBlockFeaturesEXT
             (Bool32 -> Bool
bool32ToBool Bool32
inlineUniformBlock) (Bool32 -> Bool
bool32ToBool Bool32
descriptorBindingInlineUniformBlockUpdateAfterBind)

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

instance Zero PhysicalDeviceInlineUniformBlockFeaturesEXT where
  zero :: PhysicalDeviceInlineUniformBlockFeaturesEXT
zero = Bool -> Bool -> PhysicalDeviceInlineUniformBlockFeaturesEXT
PhysicalDeviceInlineUniformBlockFeaturesEXT
           Bool
forall a. Zero a => a
zero
           Bool
forall a. Zero a => a
zero


-- | VkPhysicalDeviceInlineUniformBlockPropertiesEXT - Structure describing
-- inline uniform block properties that can be supported by an
-- implementation
--
-- = Members
--
-- The members of the 'PhysicalDeviceInlineUniformBlockPropertiesEXT'
-- structure describe the following implementation-dependent limits:
--
-- = Description
--
-- If the 'PhysicalDeviceInlineUniformBlockPropertiesEXT' structure is
-- included in the @pNext@ chain of
-- 'Vulkan.Core11.Promoted_From_VK_KHR_get_physical_device_properties2.PhysicalDeviceProperties2',
-- it is filled with the implementation-dependent limits.
--
-- == Valid Usage (Implicit)
--
-- = See Also
--
-- 'Vulkan.Core10.Enums.StructureType.StructureType'
data PhysicalDeviceInlineUniformBlockPropertiesEXT = PhysicalDeviceInlineUniformBlockPropertiesEXT
  { -- | @maxInlineUniformBlockSize@ is the maximum size in bytes of an
    -- <https://www.khronos.org/registry/vulkan/specs/1.2-extensions/html/vkspec.html#descriptorsets-inlineuniformblock inline uniform block>
    -- binding.
    PhysicalDeviceInlineUniformBlockPropertiesEXT -> Word32
maxInlineUniformBlockSize :: Word32
  , -- No documentation found for Nested "VkPhysicalDeviceInlineUniformBlockPropertiesEXT" "maxPerStageDescriptorInlineUniformBlocks"
    PhysicalDeviceInlineUniformBlockPropertiesEXT -> Word32
maxPerStageDescriptorInlineUniformBlocks :: Word32
  , -- | @maxPerStageDescriptorUpdateAfterBindInlineUniformBlocks@ is similar to
    -- @maxPerStageDescriptorInlineUniformBlocks@ but counts descriptor
    -- bindings from descriptor sets created with or without the
    -- 'Vulkan.Core10.Enums.DescriptorSetLayoutCreateFlagBits.DESCRIPTOR_SET_LAYOUT_CREATE_UPDATE_AFTER_BIND_POOL_BIT'
    -- bit set.
    PhysicalDeviceInlineUniformBlockPropertiesEXT -> Word32
maxPerStageDescriptorUpdateAfterBindInlineUniformBlocks :: Word32
  , -- | @maxDescriptorSetInlineUniformBlocks@ is the maximum number of inline
    -- uniform block bindings that /can/ be included in descriptor bindings in
    -- a pipeline layout across all pipeline shader stages and descriptor set
    -- numbers. Descriptor bindings with a descriptor type of
    -- 'Vulkan.Core10.Enums.DescriptorType.DESCRIPTOR_TYPE_INLINE_UNIFORM_BLOCK_EXT'
    -- count against this limit. Only descriptor bindings in descriptor set
    -- layouts created without the
    -- 'Vulkan.Core10.Enums.DescriptorSetLayoutCreateFlagBits.DESCRIPTOR_SET_LAYOUT_CREATE_UPDATE_AFTER_BIND_POOL_BIT'
    -- bit set count against this limit.
    PhysicalDeviceInlineUniformBlockPropertiesEXT -> Word32
maxDescriptorSetInlineUniformBlocks :: Word32
  , -- | @maxDescriptorSetUpdateAfterBindInlineUniformBlocks@ is similar to
    -- @maxDescriptorSetInlineUniformBlocks@ but counts descriptor bindings
    -- from descriptor sets created with or without the
    -- 'Vulkan.Core10.Enums.DescriptorSetLayoutCreateFlagBits.DESCRIPTOR_SET_LAYOUT_CREATE_UPDATE_AFTER_BIND_POOL_BIT'
    -- bit set.
    PhysicalDeviceInlineUniformBlockPropertiesEXT -> Word32
maxDescriptorSetUpdateAfterBindInlineUniformBlocks :: Word32
  }
  deriving (Typeable, PhysicalDeviceInlineUniformBlockPropertiesEXT
-> PhysicalDeviceInlineUniformBlockPropertiesEXT -> Bool
(PhysicalDeviceInlineUniformBlockPropertiesEXT
 -> PhysicalDeviceInlineUniformBlockPropertiesEXT -> Bool)
-> (PhysicalDeviceInlineUniformBlockPropertiesEXT
    -> PhysicalDeviceInlineUniformBlockPropertiesEXT -> Bool)
-> Eq PhysicalDeviceInlineUniformBlockPropertiesEXT
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: PhysicalDeviceInlineUniformBlockPropertiesEXT
-> PhysicalDeviceInlineUniformBlockPropertiesEXT -> Bool
$c/= :: PhysicalDeviceInlineUniformBlockPropertiesEXT
-> PhysicalDeviceInlineUniformBlockPropertiesEXT -> Bool
== :: PhysicalDeviceInlineUniformBlockPropertiesEXT
-> PhysicalDeviceInlineUniformBlockPropertiesEXT -> Bool
$c== :: PhysicalDeviceInlineUniformBlockPropertiesEXT
-> PhysicalDeviceInlineUniformBlockPropertiesEXT -> Bool
Eq)
#if defined(GENERIC_INSTANCES)
deriving instance Generic (PhysicalDeviceInlineUniformBlockPropertiesEXT)
#endif
deriving instance Show PhysicalDeviceInlineUniformBlockPropertiesEXT

instance ToCStruct PhysicalDeviceInlineUniformBlockPropertiesEXT where
  withCStruct :: PhysicalDeviceInlineUniformBlockPropertiesEXT
-> (Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT -> IO b)
-> IO b
withCStruct x :: PhysicalDeviceInlineUniformBlockPropertiesEXT
x f :: Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT -> IO b
f = Int
-> Int
-> (Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT -> IO b)
-> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 40 8 ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT -> IO b)
 -> IO b)
-> (Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT -> IO b)
-> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p -> Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> PhysicalDeviceInlineUniformBlockPropertiesEXT -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p PhysicalDeviceInlineUniformBlockPropertiesEXT
x (Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT -> IO b
f Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p)
  pokeCStruct :: Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> PhysicalDeviceInlineUniformBlockPropertiesEXT -> IO b -> IO b
pokeCStruct p :: Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p PhysicalDeviceInlineUniformBlockPropertiesEXT{..} f :: IO b
f = do
    Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_PHYSICAL_DEVICE_INLINE_UNIFORM_BLOCK_PROPERTIES_EXT)
    Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32)) (Word32
maxInlineUniformBlockSize)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Word32)) (Word32
maxPerStageDescriptorInlineUniformBlocks)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Word32)) (Word32
maxPerStageDescriptorUpdateAfterBindInlineUniformBlocks)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 28 :: Ptr Word32)) (Word32
maxDescriptorSetInlineUniformBlocks)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Word32)) (Word32
maxDescriptorSetUpdateAfterBindInlineUniformBlocks)
    IO b
f
  cStructSize :: Int
cStructSize = 40
  cStructAlignment :: Int
cStructAlignment = 8
  pokeZeroCStruct :: Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT -> IO b -> IO b
pokeZeroCStruct p :: Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p f :: IO b
f = do
    Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_PHYSICAL_DEVICE_INLINE_UNIFORM_BLOCK_PROPERTIES_EXT)
    Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32)) (Word32
forall a. Zero a => a
zero)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Word32)) (Word32
forall a. Zero a => a
zero)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Word32)) (Word32
forall a. Zero a => a
zero)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 28 :: Ptr Word32)) (Word32
forall a. Zero a => a
zero)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Word32)) (Word32
forall a. Zero a => a
zero)
    IO b
f

instance FromCStruct PhysicalDeviceInlineUniformBlockPropertiesEXT where
  peekCStruct :: Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> IO PhysicalDeviceInlineUniformBlockPropertiesEXT
peekCStruct p :: Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p = do
    Word32
maxInlineUniformBlockSize <- Ptr Word32 -> IO Word32
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32))
    Word32
maxPerStageDescriptorInlineUniformBlocks <- Ptr Word32 -> IO Word32
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Word32))
    Word32
maxPerStageDescriptorUpdateAfterBindInlineUniformBlocks <- Ptr Word32 -> IO Word32
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Word32))
    Word32
maxDescriptorSetInlineUniformBlocks <- Ptr Word32 -> IO Word32
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 28 :: Ptr Word32))
    Word32
maxDescriptorSetUpdateAfterBindInlineUniformBlocks <- Ptr Word32 -> IO Word32
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
p Ptr PhysicalDeviceInlineUniformBlockPropertiesEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Word32))
    PhysicalDeviceInlineUniformBlockPropertiesEXT
-> IO PhysicalDeviceInlineUniformBlockPropertiesEXT
forall (f :: * -> *) a. Applicative f => a -> f a
pure (PhysicalDeviceInlineUniformBlockPropertiesEXT
 -> IO PhysicalDeviceInlineUniformBlockPropertiesEXT)
-> PhysicalDeviceInlineUniformBlockPropertiesEXT
-> IO PhysicalDeviceInlineUniformBlockPropertiesEXT
forall a b. (a -> b) -> a -> b
$ Word32
-> Word32
-> Word32
-> Word32
-> Word32
-> PhysicalDeviceInlineUniformBlockPropertiesEXT
PhysicalDeviceInlineUniformBlockPropertiesEXT
             Word32
maxInlineUniformBlockSize Word32
maxPerStageDescriptorInlineUniformBlocks Word32
maxPerStageDescriptorUpdateAfterBindInlineUniformBlocks Word32
maxDescriptorSetInlineUniformBlocks Word32
maxDescriptorSetUpdateAfterBindInlineUniformBlocks

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

instance Zero PhysicalDeviceInlineUniformBlockPropertiesEXT where
  zero :: PhysicalDeviceInlineUniformBlockPropertiesEXT
zero = Word32
-> Word32
-> Word32
-> Word32
-> Word32
-> PhysicalDeviceInlineUniformBlockPropertiesEXT
PhysicalDeviceInlineUniformBlockPropertiesEXT
           Word32
forall a. Zero a => a
zero
           Word32
forall a. Zero a => a
zero
           Word32
forall a. Zero a => a
zero
           Word32
forall a. Zero a => a
zero
           Word32
forall a. Zero a => a
zero


-- | VkWriteDescriptorSetInlineUniformBlockEXT - Structure specifying inline
-- uniform block data
--
-- == Valid Usage (Implicit)
--
-- = See Also
--
-- 'Vulkan.Core10.Enums.StructureType.StructureType'
data WriteDescriptorSetInlineUniformBlockEXT = WriteDescriptorSetInlineUniformBlockEXT
  { -- | @dataSize@ is the number of bytes of inline uniform block data pointed
    -- to by @pData@.
    --
    -- @dataSize@ /must/ be an integer multiple of @4@
    --
    -- @dataSize@ /must/ be greater than @0@
    WriteDescriptorSetInlineUniformBlockEXT -> Word32
dataSize :: Word32
  , -- | @pData@ is a pointer to @dataSize@ number of bytes of data to write to
    -- the inline uniform block.
    --
    -- @pData@ /must/ be a valid pointer to an array of @dataSize@ bytes
    WriteDescriptorSetInlineUniformBlockEXT -> Ptr ()
data' :: Ptr ()
  }
  deriving (Typeable)
#if defined(GENERIC_INSTANCES)
deriving instance Generic (WriteDescriptorSetInlineUniformBlockEXT)
#endif
deriving instance Show WriteDescriptorSetInlineUniformBlockEXT

instance ToCStruct WriteDescriptorSetInlineUniformBlockEXT where
  withCStruct :: WriteDescriptorSetInlineUniformBlockEXT
-> (Ptr WriteDescriptorSetInlineUniformBlockEXT -> IO b) -> IO b
withCStruct x :: WriteDescriptorSetInlineUniformBlockEXT
x f :: Ptr WriteDescriptorSetInlineUniformBlockEXT -> IO b
f = Int
-> Int
-> (Ptr WriteDescriptorSetInlineUniformBlockEXT -> IO b)
-> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 32 8 ((Ptr WriteDescriptorSetInlineUniformBlockEXT -> IO b) -> IO b)
-> (Ptr WriteDescriptorSetInlineUniformBlockEXT -> IO b) -> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr WriteDescriptorSetInlineUniformBlockEXT
p -> Ptr WriteDescriptorSetInlineUniformBlockEXT
-> WriteDescriptorSetInlineUniformBlockEXT -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr WriteDescriptorSetInlineUniformBlockEXT
p WriteDescriptorSetInlineUniformBlockEXT
x (Ptr WriteDescriptorSetInlineUniformBlockEXT -> IO b
f Ptr WriteDescriptorSetInlineUniformBlockEXT
p)
  pokeCStruct :: Ptr WriteDescriptorSetInlineUniformBlockEXT
-> WriteDescriptorSetInlineUniformBlockEXT -> IO b -> IO b
pokeCStruct p :: Ptr WriteDescriptorSetInlineUniformBlockEXT
p WriteDescriptorSetInlineUniformBlockEXT{..} f :: IO b
f = do
    Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr WriteDescriptorSetInlineUniformBlockEXT
p Ptr WriteDescriptorSetInlineUniformBlockEXT
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_WRITE_DESCRIPTOR_SET_INLINE_UNIFORM_BLOCK_EXT)
    Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr WriteDescriptorSetInlineUniformBlockEXT
p Ptr WriteDescriptorSetInlineUniformBlockEXT -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr WriteDescriptorSetInlineUniformBlockEXT
p Ptr WriteDescriptorSetInlineUniformBlockEXT -> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32)) (Word32
dataSize)
    Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr WriteDescriptorSetInlineUniformBlockEXT
p Ptr WriteDescriptorSetInlineUniformBlockEXT -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr (Ptr ()))) (Ptr ()
data')
    IO b
f
  cStructSize :: Int
cStructSize = 32
  cStructAlignment :: Int
cStructAlignment = 8
  pokeZeroCStruct :: Ptr WriteDescriptorSetInlineUniformBlockEXT -> IO b -> IO b
pokeZeroCStruct p :: Ptr WriteDescriptorSetInlineUniformBlockEXT
p f :: IO b
f = do
    Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr WriteDescriptorSetInlineUniformBlockEXT
p Ptr WriteDescriptorSetInlineUniformBlockEXT
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_WRITE_DESCRIPTOR_SET_INLINE_UNIFORM_BLOCK_EXT)
    Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr WriteDescriptorSetInlineUniformBlockEXT
p Ptr WriteDescriptorSetInlineUniformBlockEXT -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr WriteDescriptorSetInlineUniformBlockEXT
p Ptr WriteDescriptorSetInlineUniformBlockEXT -> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32)) (Word32
forall a. Zero a => a
zero)
    Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr WriteDescriptorSetInlineUniformBlockEXT
p Ptr WriteDescriptorSetInlineUniformBlockEXT -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr (Ptr ()))) (Ptr ()
forall a. Zero a => a
zero)
    IO b
f

instance FromCStruct WriteDescriptorSetInlineUniformBlockEXT where
  peekCStruct :: Ptr WriteDescriptorSetInlineUniformBlockEXT
-> IO WriteDescriptorSetInlineUniformBlockEXT
peekCStruct p :: Ptr WriteDescriptorSetInlineUniformBlockEXT
p = do
    Word32
dataSize <- Ptr Word32 -> IO Word32
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr WriteDescriptorSetInlineUniformBlockEXT
p Ptr WriteDescriptorSetInlineUniformBlockEXT -> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32))
    Ptr ()
pData <- Ptr (Ptr ()) -> IO (Ptr ())
forall a. Storable a => Ptr a -> IO a
peek @(Ptr ()) ((Ptr WriteDescriptorSetInlineUniformBlockEXT
p Ptr WriteDescriptorSetInlineUniformBlockEXT -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr (Ptr ())))
    WriteDescriptorSetInlineUniformBlockEXT
-> IO WriteDescriptorSetInlineUniformBlockEXT
forall (f :: * -> *) a. Applicative f => a -> f a
pure (WriteDescriptorSetInlineUniformBlockEXT
 -> IO WriteDescriptorSetInlineUniformBlockEXT)
-> WriteDescriptorSetInlineUniformBlockEXT
-> IO WriteDescriptorSetInlineUniformBlockEXT
forall a b. (a -> b) -> a -> b
$ Word32 -> Ptr () -> WriteDescriptorSetInlineUniformBlockEXT
WriteDescriptorSetInlineUniformBlockEXT
             Word32
dataSize Ptr ()
pData

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

instance Zero WriteDescriptorSetInlineUniformBlockEXT where
  zero :: WriteDescriptorSetInlineUniformBlockEXT
zero = Word32 -> Ptr () -> WriteDescriptorSetInlineUniformBlockEXT
WriteDescriptorSetInlineUniformBlockEXT
           Word32
forall a. Zero a => a
zero
           Ptr ()
forall a. Zero a => a
zero


-- | VkDescriptorPoolInlineUniformBlockCreateInfoEXT - Structure specifying
-- the maximum number of inline uniform block bindings of a newly created
-- descriptor pool
--
-- == Valid Usage (Implicit)
--
-- = See Also
--
-- 'Vulkan.Core10.Enums.StructureType.StructureType'
data DescriptorPoolInlineUniformBlockCreateInfoEXT = DescriptorPoolInlineUniformBlockCreateInfoEXT
  { -- | @maxInlineUniformBlockBindings@ is the number of inline uniform block
    -- bindings to allocate.
    DescriptorPoolInlineUniformBlockCreateInfoEXT -> Word32
maxInlineUniformBlockBindings :: Word32 }
  deriving (Typeable, DescriptorPoolInlineUniformBlockCreateInfoEXT
-> DescriptorPoolInlineUniformBlockCreateInfoEXT -> Bool
(DescriptorPoolInlineUniformBlockCreateInfoEXT
 -> DescriptorPoolInlineUniformBlockCreateInfoEXT -> Bool)
-> (DescriptorPoolInlineUniformBlockCreateInfoEXT
    -> DescriptorPoolInlineUniformBlockCreateInfoEXT -> Bool)
-> Eq DescriptorPoolInlineUniformBlockCreateInfoEXT
forall a. (a -> a -> Bool) -> (a -> a -> Bool) -> Eq a
/= :: DescriptorPoolInlineUniformBlockCreateInfoEXT
-> DescriptorPoolInlineUniformBlockCreateInfoEXT -> Bool
$c/= :: DescriptorPoolInlineUniformBlockCreateInfoEXT
-> DescriptorPoolInlineUniformBlockCreateInfoEXT -> Bool
== :: DescriptorPoolInlineUniformBlockCreateInfoEXT
-> DescriptorPoolInlineUniformBlockCreateInfoEXT -> Bool
$c== :: DescriptorPoolInlineUniformBlockCreateInfoEXT
-> DescriptorPoolInlineUniformBlockCreateInfoEXT -> Bool
Eq)
#if defined(GENERIC_INSTANCES)
deriving instance Generic (DescriptorPoolInlineUniformBlockCreateInfoEXT)
#endif
deriving instance Show DescriptorPoolInlineUniformBlockCreateInfoEXT

instance ToCStruct DescriptorPoolInlineUniformBlockCreateInfoEXT where
  withCStruct :: DescriptorPoolInlineUniformBlockCreateInfoEXT
-> (Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT -> IO b)
-> IO b
withCStruct x :: DescriptorPoolInlineUniformBlockCreateInfoEXT
x f :: Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT -> IO b
f = Int
-> Int
-> (Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT -> IO b)
-> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 24 8 ((Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT -> IO b)
 -> IO b)
-> (Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT -> IO b)
-> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p -> Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
-> DescriptorPoolInlineUniformBlockCreateInfoEXT -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p DescriptorPoolInlineUniformBlockCreateInfoEXT
x (Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT -> IO b
f Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p)
  pokeCStruct :: Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
-> DescriptorPoolInlineUniformBlockCreateInfoEXT -> IO b -> IO b
pokeCStruct p :: Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p DescriptorPoolInlineUniformBlockCreateInfoEXT{..} f :: IO b
f = do
    Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_DESCRIPTOR_POOL_INLINE_UNIFORM_BLOCK_CREATE_INFO_EXT)
    Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32)) (Word32
maxInlineUniformBlockBindings)
    IO b
f
  cStructSize :: Int
cStructSize = 24
  cStructAlignment :: Int
cStructAlignment = 8
  pokeZeroCStruct :: Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT -> IO b -> IO b
pokeZeroCStruct p :: Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p f :: IO b
f = do
    Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_DESCRIPTOR_POOL_INLINE_UNIFORM_BLOCK_CREATE_INFO_EXT)
    Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
    Ptr Word32 -> Word32 -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32)) (Word32
forall a. Zero a => a
zero)
    IO b
f

instance FromCStruct DescriptorPoolInlineUniformBlockCreateInfoEXT where
  peekCStruct :: Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
-> IO DescriptorPoolInlineUniformBlockCreateInfoEXT
peekCStruct p :: Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p = do
    Word32
maxInlineUniformBlockBindings <- Ptr Word32 -> IO Word32
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
p Ptr DescriptorPoolInlineUniformBlockCreateInfoEXT
-> Int -> Ptr Word32
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32))
    DescriptorPoolInlineUniformBlockCreateInfoEXT
-> IO DescriptorPoolInlineUniformBlockCreateInfoEXT
forall (f :: * -> *) a. Applicative f => a -> f a
pure (DescriptorPoolInlineUniformBlockCreateInfoEXT
 -> IO DescriptorPoolInlineUniformBlockCreateInfoEXT)
-> DescriptorPoolInlineUniformBlockCreateInfoEXT
-> IO DescriptorPoolInlineUniformBlockCreateInfoEXT
forall a b. (a -> b) -> a -> b
$ Word32 -> DescriptorPoolInlineUniformBlockCreateInfoEXT
DescriptorPoolInlineUniformBlockCreateInfoEXT
             Word32
maxInlineUniformBlockBindings

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

instance Zero DescriptorPoolInlineUniformBlockCreateInfoEXT where
  zero :: DescriptorPoolInlineUniformBlockCreateInfoEXT
zero = Word32 -> DescriptorPoolInlineUniformBlockCreateInfoEXT
DescriptorPoolInlineUniformBlockCreateInfoEXT
           Word32
forall a. Zero a => a
zero


type EXT_INLINE_UNIFORM_BLOCK_SPEC_VERSION = 1

-- No documentation found for TopLevel "VK_EXT_INLINE_UNIFORM_BLOCK_SPEC_VERSION"
pattern EXT_INLINE_UNIFORM_BLOCK_SPEC_VERSION :: forall a . Integral a => a
pattern $bEXT_INLINE_UNIFORM_BLOCK_SPEC_VERSION :: a
$mEXT_INLINE_UNIFORM_BLOCK_SPEC_VERSION :: forall r a. Integral a => a -> (Void# -> r) -> (Void# -> r) -> r
EXT_INLINE_UNIFORM_BLOCK_SPEC_VERSION = 1


type EXT_INLINE_UNIFORM_BLOCK_EXTENSION_NAME = "VK_EXT_inline_uniform_block"

-- No documentation found for TopLevel "VK_EXT_INLINE_UNIFORM_BLOCK_EXTENSION_NAME"
pattern EXT_INLINE_UNIFORM_BLOCK_EXTENSION_NAME :: forall a . (Eq a, IsString a) => a
pattern $bEXT_INLINE_UNIFORM_BLOCK_EXTENSION_NAME :: a
$mEXT_INLINE_UNIFORM_BLOCK_EXTENSION_NAME :: forall r a.
(Eq a, IsString a) =>
a -> (Void# -> r) -> (Void# -> r) -> r
EXT_INLINE_UNIFORM_BLOCK_EXTENSION_NAME = "VK_EXT_inline_uniform_block"