{-# language CPP #-}
module Vulkan.Extensions.VK_NV_device_generated_commands ( cmdExecuteGeneratedCommandsNV
, cmdPreprocessGeneratedCommandsNV
, cmdBindPipelineShaderGroupNV
, getGeneratedCommandsMemoryRequirementsNV
, createIndirectCommandsLayoutNV
, withIndirectCommandsLayoutNV
, destroyIndirectCommandsLayoutNV
, PhysicalDeviceDeviceGeneratedCommandsFeaturesNV(..)
, PhysicalDeviceDeviceGeneratedCommandsPropertiesNV(..)
, GraphicsShaderGroupCreateInfoNV(..)
, GraphicsPipelineShaderGroupsCreateInfoNV(..)
, BindShaderGroupIndirectCommandNV(..)
, BindIndexBufferIndirectCommandNV(..)
, BindVertexBufferIndirectCommandNV(..)
, SetStateFlagsIndirectCommandNV(..)
, IndirectCommandsStreamNV(..)
, IndirectCommandsLayoutTokenNV(..)
, IndirectCommandsLayoutCreateInfoNV(..)
, GeneratedCommandsInfoNV(..)
, GeneratedCommandsMemoryRequirementsInfoNV(..)
, IndirectCommandsLayoutUsageFlagBitsNV( INDIRECT_COMMANDS_LAYOUT_USAGE_EXPLICIT_PREPROCESS_BIT_NV
, INDIRECT_COMMANDS_LAYOUT_USAGE_INDEXED_SEQUENCES_BIT_NV
, INDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NV
, ..
)
, IndirectCommandsLayoutUsageFlagsNV
, IndirectStateFlagBitsNV( INDIRECT_STATE_FLAG_FRONTFACE_BIT_NV
, ..
)
, IndirectStateFlagsNV
, IndirectCommandsTokenTypeNV( INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV
, INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV
, INDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV
, INDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV
, INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV
, INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV
, INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV
, INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV
, ..
)
, NV_DEVICE_GENERATED_COMMANDS_SPEC_VERSION
, pattern NV_DEVICE_GENERATED_COMMANDS_SPEC_VERSION
, NV_DEVICE_GENERATED_COMMANDS_EXTENSION_NAME
, pattern NV_DEVICE_GENERATED_COMMANDS_EXTENSION_NAME
, IndirectCommandsLayoutNV(..)
) where
import Control.Exception.Base (bracket)
import Control.Monad (unless)
import Control.Monad.IO.Class (liftIO)
import Foreign.Marshal.Alloc (allocaBytesAligned)
import Foreign.Marshal.Alloc (callocBytes)
import Foreign.Marshal.Alloc (free)
import Foreign.Marshal.Utils (maybePeek)
import GHC.Base (when)
import GHC.IO (throwIO)
import GHC.Ptr (castPtr)
import GHC.Ptr (nullFunPtr)
import Foreign.Ptr (nullPtr)
import Foreign.Ptr (plusPtr)
import GHC.Read (choose)
import GHC.Read (expectP)
import GHC.Read (parens)
import GHC.Show (showParen)
import GHC.Show (showString)
import GHC.Show (showsPrec)
import Numeric (showHex)
import Text.ParserCombinators.ReadPrec ((+++))
import Text.ParserCombinators.ReadPrec (prec)
import Text.ParserCombinators.ReadPrec (step)
import Control.Monad.Trans.Class (lift)
import Control.Monad.Trans.Cont (evalContT)
import Data.Vector (generateM)
import qualified Data.Vector (imapM_)
import qualified Data.Vector (length)
import Control.Monad.IO.Class (MonadIO)
import Data.Bits (Bits)
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.IO.Exception (IOErrorType(..))
import GHC.IO.Exception (IOException(..))
import Data.Int (Int32)
import Foreign.Ptr (FunPtr)
import Foreign.Ptr (Ptr)
import GHC.Read (Read(readPrec))
import Data.Word (Word32)
import Text.Read.Lex (Lexeme(Ident))
import Data.Kind (Type)
import Control.Monad.Trans.Cont (ContT(..))
import Data.Vector (Vector)
import Vulkan.CStruct.Utils (advancePtrBytes)
import Vulkan.Core10.BaseType (bool32ToBool)
import Vulkan.Core10.BaseType (boolToBool32)
import Vulkan.CStruct.Extends (forgetExtensions)
import Vulkan.CStruct.Extends (peekSomeCStruct)
import Vulkan.CStruct.Extends (pokeSomeCStruct)
import Vulkan.CStruct.Extends (withSomeCStruct)
import Vulkan.NamedType ((:::))
import Vulkan.Core10.AllocationCallbacks (AllocationCallbacks)
import Vulkan.Core10.BaseType (Bool32)
import Vulkan.Core10.BaseType (Bool32(..))
import Vulkan.Core10.Handles (Buffer)
import Vulkan.Core10.Handles (CommandBuffer)
import Vulkan.Core10.Handles (CommandBuffer(..))
import Vulkan.Core10.Handles (CommandBuffer_T)
import Vulkan.Core10.Handles (Device)
import Vulkan.Core10.Handles (Device(..))
import Vulkan.Core10.BaseType (DeviceAddress)
import Vulkan.Dynamic (DeviceCmds(pVkCmdBindPipelineShaderGroupNV))
import Vulkan.Dynamic (DeviceCmds(pVkCmdExecuteGeneratedCommandsNV))
import Vulkan.Dynamic (DeviceCmds(pVkCmdPreprocessGeneratedCommandsNV))
import Vulkan.Dynamic (DeviceCmds(pVkCreateIndirectCommandsLayoutNV))
import Vulkan.Dynamic (DeviceCmds(pVkDestroyIndirectCommandsLayoutNV))
import Vulkan.Dynamic (DeviceCmds(pVkGetGeneratedCommandsMemoryRequirementsNV))
import Vulkan.Core10.BaseType (DeviceSize)
import Vulkan.Core10.Handles (Device_T)
import Vulkan.CStruct.Extends (Extendss)
import Vulkan.Core10.BaseType (Flags)
import Vulkan.CStruct (FromCStruct)
import Vulkan.CStruct (FromCStruct(..))
import Vulkan.Core10.Enums.IndexType (IndexType)
import Vulkan.Extensions.Handles (IndirectCommandsLayoutNV)
import Vulkan.Extensions.Handles (IndirectCommandsLayoutNV(..))
import Vulkan.Core11.Promoted_From_VK_KHR_get_memory_requirements2 (MemoryRequirements2)
import Vulkan.CStruct.Extends (PeekChain)
import Vulkan.Core10.Handles (Pipeline)
import Vulkan.Core10.Handles (Pipeline(..))
import Vulkan.Core10.Enums.PipelineBindPoint (PipelineBindPoint)
import Vulkan.Core10.Enums.PipelineBindPoint (PipelineBindPoint(..))
import Vulkan.Core10.Handles (PipelineLayout)
import Vulkan.Core10.Pipeline (PipelineShaderStageCreateInfo)
import Vulkan.Core10.Pipeline (PipelineTessellationStateCreateInfo)
import Vulkan.Core10.Pipeline (PipelineVertexInputStateCreateInfo)
import Vulkan.CStruct.Extends (PokeChain)
import Vulkan.Core10.Enums.Result (Result)
import Vulkan.Core10.Enums.Result (Result(..))
import Vulkan.Core10.Enums.ShaderStageFlagBits (ShaderStageFlags)
import Vulkan.CStruct.Extends (SomeStruct)
import Vulkan.Core10.Enums.StructureType (StructureType)
import Vulkan.CStruct (ToCStruct)
import Vulkan.CStruct (ToCStruct(..))
import Vulkan.Exception (VulkanException(..))
import Vulkan.Zero (Zero)
import Vulkan.Zero (Zero(..))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_GENERATED_COMMANDS_INFO_NV))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_GENERATED_COMMANDS_MEMORY_REQUIREMENTS_INFO_NV))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_GRAPHICS_PIPELINE_SHADER_GROUPS_CREATE_INFO_NV))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_GRAPHICS_SHADER_GROUP_CREATE_INFO_NV))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_INDIRECT_COMMANDS_LAYOUT_CREATE_INFO_NV))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_INDIRECT_COMMANDS_LAYOUT_TOKEN_NV))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_FEATURES_NV))
import Vulkan.Core10.Enums.StructureType (StructureType(STRUCTURE_TYPE_PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_PROPERTIES_NV))
import Vulkan.Core10.Enums.Result (Result(SUCCESS))
import Vulkan.Extensions.Handles (IndirectCommandsLayoutNV(..))
foreign import ccall
#if !defined(SAFE_FOREIGN_CALLS)
unsafe
#endif
"dynamic" mkVkCmdExecuteGeneratedCommandsNV
:: FunPtr (Ptr CommandBuffer_T -> Bool32 -> Ptr GeneratedCommandsInfoNV -> IO ()) -> Ptr CommandBuffer_T -> Bool32 -> Ptr GeneratedCommandsInfoNV -> IO ()
cmdExecuteGeneratedCommandsNV :: forall io . MonadIO io => CommandBuffer -> ("isPreprocessed" ::: Bool) -> GeneratedCommandsInfoNV -> io ()
cmdExecuteGeneratedCommandsNV :: CommandBuffer
-> ("isPreprocessed" ::: Bool) -> GeneratedCommandsInfoNV -> io ()
cmdExecuteGeneratedCommandsNV commandBuffer :: CommandBuffer
commandBuffer isPreprocessed :: "isPreprocessed" ::: Bool
isPreprocessed generatedCommandsInfo :: GeneratedCommandsInfoNV
generatedCommandsInfo = IO () -> io ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> io ())
-> (ContT () IO () -> IO ()) -> ContT () IO () -> io ()
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ContT () IO () -> IO ()
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT () IO () -> io ()) -> ContT () IO () -> io ()
forall a b. (a -> b) -> a -> b
$ do
let vkCmdExecuteGeneratedCommandsNVPtr :: FunPtr
(Ptr CommandBuffer_T
-> ("isPreprocessed" ::: Bool32)
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
vkCmdExecuteGeneratedCommandsNVPtr = DeviceCmds
-> FunPtr
(Ptr CommandBuffer_T
-> ("isPreprocessed" ::: Bool32)
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
pVkCmdExecuteGeneratedCommandsNV (CommandBuffer -> DeviceCmds
deviceCmds (CommandBuffer
commandBuffer :: CommandBuffer))
IO () -> ContT () IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT () IO ()) -> IO () -> ContT () IO ()
forall a b. (a -> b) -> a -> b
$ ("isPreprocessed" ::: Bool) -> IO () -> IO ()
forall (f :: * -> *).
Applicative f =>
("isPreprocessed" ::: Bool) -> f () -> f ()
unless (FunPtr
(Ptr CommandBuffer_T
-> ("isPreprocessed" ::: Bool32)
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
vkCmdExecuteGeneratedCommandsNVPtr FunPtr
(Ptr CommandBuffer_T
-> ("isPreprocessed" ::: Bool32)
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> FunPtr
(Ptr CommandBuffer_T
-> ("isPreprocessed" ::: Bool32)
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> "isPreprocessed" ::: Bool
forall a. Eq a => a -> a -> "isPreprocessed" ::: Bool
/= FunPtr
(Ptr CommandBuffer_T
-> ("isPreprocessed" ::: Bool32)
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
forall a. FunPtr a
nullFunPtr) (IO () -> IO ()) -> IO () -> IO ()
forall a b. (a -> b) -> a -> b
$
IOException -> IO ()
forall e a. Exception e => e -> IO a
throwIO (IOException -> IO ()) -> IOException -> IO ()
forall a b. (a -> b) -> a -> b
$ Maybe Handle
-> IOErrorType
-> String
-> String
-> Maybe CInt
-> Maybe String
-> IOException
IOError Maybe Handle
forall a. Maybe a
Nothing IOErrorType
InvalidArgument "" "The function pointer for vkCmdExecuteGeneratedCommandsNV is null" Maybe CInt
forall a. Maybe a
Nothing Maybe String
forall a. Maybe a
Nothing
let vkCmdExecuteGeneratedCommandsNV' :: Ptr CommandBuffer_T
-> ("isPreprocessed" ::: Bool32)
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ()
vkCmdExecuteGeneratedCommandsNV' = FunPtr
(Ptr CommandBuffer_T
-> ("isPreprocessed" ::: Bool32)
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> Ptr CommandBuffer_T
-> ("isPreprocessed" ::: Bool32)
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ()
mkVkCmdExecuteGeneratedCommandsNV FunPtr
(Ptr CommandBuffer_T
-> ("isPreprocessed" ::: Bool32)
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
vkCmdExecuteGeneratedCommandsNVPtr
"pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
pGeneratedCommandsInfo <- ((("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> IO ())
-> ContT
() IO ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> IO ())
-> ContT
() IO ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV))
-> ((("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> IO ())
-> ContT
() IO ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
forall a b. (a -> b) -> a -> b
$ GeneratedCommandsInfoNV
-> (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> IO ()
forall a b. ToCStruct a => a -> (Ptr a -> IO b) -> IO b
withCStruct (GeneratedCommandsInfoNV
generatedCommandsInfo)
IO () -> ContT () IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT () IO ()) -> IO () -> ContT () IO ()
forall a b. (a -> b) -> a -> b
$ Ptr CommandBuffer_T
-> ("isPreprocessed" ::: Bool32)
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ()
vkCmdExecuteGeneratedCommandsNV' (CommandBuffer -> Ptr CommandBuffer_T
commandBufferHandle (CommandBuffer
commandBuffer)) (("isPreprocessed" ::: Bool) -> "isPreprocessed" ::: Bool32
boolToBool32 ("isPreprocessed" ::: Bool
isPreprocessed)) "pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
pGeneratedCommandsInfo
() -> ContT () IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure (() -> ContT () IO ()) -> () -> ContT () IO ()
forall a b. (a -> b) -> a -> b
$ ()
foreign import ccall
#if !defined(SAFE_FOREIGN_CALLS)
unsafe
#endif
"dynamic" mkVkCmdPreprocessGeneratedCommandsNV
:: FunPtr (Ptr CommandBuffer_T -> Ptr GeneratedCommandsInfoNV -> IO ()) -> Ptr CommandBuffer_T -> Ptr GeneratedCommandsInfoNV -> IO ()
cmdPreprocessGeneratedCommandsNV :: forall io . MonadIO io => CommandBuffer -> GeneratedCommandsInfoNV -> io ()
cmdPreprocessGeneratedCommandsNV :: CommandBuffer -> GeneratedCommandsInfoNV -> io ()
cmdPreprocessGeneratedCommandsNV commandBuffer :: CommandBuffer
commandBuffer generatedCommandsInfo :: GeneratedCommandsInfoNV
generatedCommandsInfo = IO () -> io ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> io ())
-> (ContT () IO () -> IO ()) -> ContT () IO () -> io ()
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ContT () IO () -> IO ()
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT () IO () -> io ()) -> ContT () IO () -> io ()
forall a b. (a -> b) -> a -> b
$ do
let vkCmdPreprocessGeneratedCommandsNVPtr :: FunPtr
(Ptr CommandBuffer_T
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
vkCmdPreprocessGeneratedCommandsNVPtr = DeviceCmds
-> FunPtr
(Ptr CommandBuffer_T
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
pVkCmdPreprocessGeneratedCommandsNV (CommandBuffer -> DeviceCmds
deviceCmds (CommandBuffer
commandBuffer :: CommandBuffer))
IO () -> ContT () IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT () IO ()) -> IO () -> ContT () IO ()
forall a b. (a -> b) -> a -> b
$ ("isPreprocessed" ::: Bool) -> IO () -> IO ()
forall (f :: * -> *).
Applicative f =>
("isPreprocessed" ::: Bool) -> f () -> f ()
unless (FunPtr
(Ptr CommandBuffer_T
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
vkCmdPreprocessGeneratedCommandsNVPtr FunPtr
(Ptr CommandBuffer_T
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> FunPtr
(Ptr CommandBuffer_T
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> "isPreprocessed" ::: Bool
forall a. Eq a => a -> a -> "isPreprocessed" ::: Bool
/= FunPtr
(Ptr CommandBuffer_T
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
forall a. FunPtr a
nullFunPtr) (IO () -> IO ()) -> IO () -> IO ()
forall a b. (a -> b) -> a -> b
$
IOException -> IO ()
forall e a. Exception e => e -> IO a
throwIO (IOException -> IO ()) -> IOException -> IO ()
forall a b. (a -> b) -> a -> b
$ Maybe Handle
-> IOErrorType
-> String
-> String
-> Maybe CInt
-> Maybe String
-> IOException
IOError Maybe Handle
forall a. Maybe a
Nothing IOErrorType
InvalidArgument "" "The function pointer for vkCmdPreprocessGeneratedCommandsNV is null" Maybe CInt
forall a. Maybe a
Nothing Maybe String
forall a. Maybe a
Nothing
let vkCmdPreprocessGeneratedCommandsNV' :: Ptr CommandBuffer_T
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ()
vkCmdPreprocessGeneratedCommandsNV' = FunPtr
(Ptr CommandBuffer_T
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> Ptr CommandBuffer_T
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ()
mkVkCmdPreprocessGeneratedCommandsNV FunPtr
(Ptr CommandBuffer_T
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
vkCmdPreprocessGeneratedCommandsNVPtr
"pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
pGeneratedCommandsInfo <- ((("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> IO ())
-> ContT
() IO ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> IO ())
-> ContT
() IO ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV))
-> ((("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> IO ())
-> ContT
() IO ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
forall a b. (a -> b) -> a -> b
$ GeneratedCommandsInfoNV
-> (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ())
-> IO ()
forall a b. ToCStruct a => a -> (Ptr a -> IO b) -> IO b
withCStruct (GeneratedCommandsInfoNV
generatedCommandsInfo)
IO () -> ContT () IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT () IO ()) -> IO () -> ContT () IO ()
forall a b. (a -> b) -> a -> b
$ Ptr CommandBuffer_T
-> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO ()
vkCmdPreprocessGeneratedCommandsNV' (CommandBuffer -> Ptr CommandBuffer_T
commandBufferHandle (CommandBuffer
commandBuffer)) "pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
pGeneratedCommandsInfo
() -> ContT () IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure (() -> ContT () IO ()) -> () -> ContT () IO ()
forall a b. (a -> b) -> a -> b
$ ()
foreign import ccall
#if !defined(SAFE_FOREIGN_CALLS)
unsafe
#endif
"dynamic" mkVkCmdBindPipelineShaderGroupNV
:: FunPtr (Ptr CommandBuffer_T -> PipelineBindPoint -> Pipeline -> Word32 -> IO ()) -> Ptr CommandBuffer_T -> PipelineBindPoint -> Pipeline -> Word32 -> IO ()
cmdBindPipelineShaderGroupNV :: forall io . MonadIO io => CommandBuffer -> PipelineBindPoint -> Pipeline -> ("groupIndex" ::: Word32) -> io ()
cmdBindPipelineShaderGroupNV :: CommandBuffer
-> PipelineBindPoint
-> Pipeline
-> ("groupIndex" ::: Word32)
-> io ()
cmdBindPipelineShaderGroupNV commandBuffer :: CommandBuffer
commandBuffer pipelineBindPoint :: PipelineBindPoint
pipelineBindPoint pipeline :: Pipeline
pipeline groupIndex :: "groupIndex" ::: Word32
groupIndex = IO () -> io ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> io ()) -> IO () -> io ()
forall a b. (a -> b) -> a -> b
$ do
let vkCmdBindPipelineShaderGroupNVPtr :: FunPtr
(Ptr CommandBuffer_T
-> PipelineBindPoint
-> Pipeline
-> ("groupIndex" ::: Word32)
-> IO ())
vkCmdBindPipelineShaderGroupNVPtr = DeviceCmds
-> FunPtr
(Ptr CommandBuffer_T
-> PipelineBindPoint
-> Pipeline
-> ("groupIndex" ::: Word32)
-> IO ())
pVkCmdBindPipelineShaderGroupNV (CommandBuffer -> DeviceCmds
deviceCmds (CommandBuffer
commandBuffer :: CommandBuffer))
("isPreprocessed" ::: Bool) -> IO () -> IO ()
forall (f :: * -> *).
Applicative f =>
("isPreprocessed" ::: Bool) -> f () -> f ()
unless (FunPtr
(Ptr CommandBuffer_T
-> PipelineBindPoint
-> Pipeline
-> ("groupIndex" ::: Word32)
-> IO ())
vkCmdBindPipelineShaderGroupNVPtr FunPtr
(Ptr CommandBuffer_T
-> PipelineBindPoint
-> Pipeline
-> ("groupIndex" ::: Word32)
-> IO ())
-> FunPtr
(Ptr CommandBuffer_T
-> PipelineBindPoint
-> Pipeline
-> ("groupIndex" ::: Word32)
-> IO ())
-> "isPreprocessed" ::: Bool
forall a. Eq a => a -> a -> "isPreprocessed" ::: Bool
/= FunPtr
(Ptr CommandBuffer_T
-> PipelineBindPoint
-> Pipeline
-> ("groupIndex" ::: Word32)
-> IO ())
forall a. FunPtr a
nullFunPtr) (IO () -> IO ()) -> IO () -> IO ()
forall a b. (a -> b) -> a -> b
$
IOException -> IO ()
forall e a. Exception e => e -> IO a
throwIO (IOException -> IO ()) -> IOException -> IO ()
forall a b. (a -> b) -> a -> b
$ Maybe Handle
-> IOErrorType
-> String
-> String
-> Maybe CInt
-> Maybe String
-> IOException
IOError Maybe Handle
forall a. Maybe a
Nothing IOErrorType
InvalidArgument "" "The function pointer for vkCmdBindPipelineShaderGroupNV is null" Maybe CInt
forall a. Maybe a
Nothing Maybe String
forall a. Maybe a
Nothing
let vkCmdBindPipelineShaderGroupNV' :: Ptr CommandBuffer_T
-> PipelineBindPoint
-> Pipeline
-> ("groupIndex" ::: Word32)
-> IO ()
vkCmdBindPipelineShaderGroupNV' = FunPtr
(Ptr CommandBuffer_T
-> PipelineBindPoint
-> Pipeline
-> ("groupIndex" ::: Word32)
-> IO ())
-> Ptr CommandBuffer_T
-> PipelineBindPoint
-> Pipeline
-> ("groupIndex" ::: Word32)
-> IO ()
mkVkCmdBindPipelineShaderGroupNV FunPtr
(Ptr CommandBuffer_T
-> PipelineBindPoint
-> Pipeline
-> ("groupIndex" ::: Word32)
-> IO ())
vkCmdBindPipelineShaderGroupNVPtr
Ptr CommandBuffer_T
-> PipelineBindPoint
-> Pipeline
-> ("groupIndex" ::: Word32)
-> IO ()
vkCmdBindPipelineShaderGroupNV' (CommandBuffer -> Ptr CommandBuffer_T
commandBufferHandle (CommandBuffer
commandBuffer)) (PipelineBindPoint
pipelineBindPoint) (Pipeline
pipeline) ("groupIndex" ::: Word32
groupIndex)
() -> IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure (() -> IO ()) -> () -> IO ()
forall a b. (a -> b) -> a -> b
$ ()
foreign import ccall
#if !defined(SAFE_FOREIGN_CALLS)
unsafe
#endif
"dynamic" mkVkGetGeneratedCommandsMemoryRequirementsNV
:: FunPtr (Ptr Device_T -> Ptr GeneratedCommandsMemoryRequirementsInfoNV -> Ptr (MemoryRequirements2 a) -> IO ()) -> Ptr Device_T -> Ptr GeneratedCommandsMemoryRequirementsInfoNV -> Ptr (MemoryRequirements2 a) -> IO ()
getGeneratedCommandsMemoryRequirementsNV :: forall a io . (Extendss MemoryRequirements2 a, PokeChain a, PeekChain a, MonadIO io) => Device -> GeneratedCommandsMemoryRequirementsInfoNV -> io (MemoryRequirements2 a)
getGeneratedCommandsMemoryRequirementsNV :: Device
-> GeneratedCommandsMemoryRequirementsInfoNV
-> io (MemoryRequirements2 a)
getGeneratedCommandsMemoryRequirementsNV device :: Device
device info :: GeneratedCommandsMemoryRequirementsInfoNV
info = IO (MemoryRequirements2 a) -> io (MemoryRequirements2 a)
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO (MemoryRequirements2 a) -> io (MemoryRequirements2 a))
-> (ContT (MemoryRequirements2 a) IO (MemoryRequirements2 a)
-> IO (MemoryRequirements2 a))
-> ContT (MemoryRequirements2 a) IO (MemoryRequirements2 a)
-> io (MemoryRequirements2 a)
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ContT (MemoryRequirements2 a) IO (MemoryRequirements2 a)
-> IO (MemoryRequirements2 a)
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT (MemoryRequirements2 a) IO (MemoryRequirements2 a)
-> io (MemoryRequirements2 a))
-> ContT (MemoryRequirements2 a) IO (MemoryRequirements2 a)
-> io (MemoryRequirements2 a)
forall a b. (a -> b) -> a -> b
$ do
let vkGetGeneratedCommandsMemoryRequirementsNVPtr :: FunPtr
(Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO ())
vkGetGeneratedCommandsMemoryRequirementsNVPtr = DeviceCmds
-> forall (a :: [*]).
FunPtr
(Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO ())
pVkGetGeneratedCommandsMemoryRequirementsNV (Device -> DeviceCmds
deviceCmds (Device
device :: Device))
IO () -> ContT (MemoryRequirements2 a) IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT (MemoryRequirements2 a) IO ())
-> IO () -> ContT (MemoryRequirements2 a) IO ()
forall a b. (a -> b) -> a -> b
$ ("isPreprocessed" ::: Bool) -> IO () -> IO ()
forall (f :: * -> *).
Applicative f =>
("isPreprocessed" ::: Bool) -> f () -> f ()
unless (FunPtr
(Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO ())
vkGetGeneratedCommandsMemoryRequirementsNVPtr FunPtr
(Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO ())
-> FunPtr
(Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO ())
-> "isPreprocessed" ::: Bool
forall a. Eq a => a -> a -> "isPreprocessed" ::: Bool
/= FunPtr
(Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO ())
forall a. FunPtr a
nullFunPtr) (IO () -> IO ()) -> IO () -> IO ()
forall a b. (a -> b) -> a -> b
$
IOException -> IO ()
forall e a. Exception e => e -> IO a
throwIO (IOException -> IO ()) -> IOException -> IO ()
forall a b. (a -> b) -> a -> b
$ Maybe Handle
-> IOErrorType
-> String
-> String
-> Maybe CInt
-> Maybe String
-> IOException
IOError Maybe Handle
forall a. Maybe a
Nothing IOErrorType
InvalidArgument "" "The function pointer for vkGetGeneratedCommandsMemoryRequirementsNV is null" Maybe CInt
forall a. Maybe a
Nothing Maybe String
forall a. Maybe a
Nothing
let vkGetGeneratedCommandsMemoryRequirementsNV' :: Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO ()
vkGetGeneratedCommandsMemoryRequirementsNV' = FunPtr
(Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO ())
-> Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO ()
forall (a :: [*]).
FunPtr
(Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Ptr (MemoryRequirements2 a)
-> IO ())
-> Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Ptr (MemoryRequirements2 a)
-> IO ()
mkVkGetGeneratedCommandsMemoryRequirementsNV FunPtr
(Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO ())
vkGetGeneratedCommandsMemoryRequirementsNVPtr
"pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
pInfo <- ((("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> IO (MemoryRequirements2 a))
-> IO (MemoryRequirements2 a))
-> ContT
(MemoryRequirements2 a)
IO
("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> IO (MemoryRequirements2 a))
-> IO (MemoryRequirements2 a))
-> ContT
(MemoryRequirements2 a)
IO
("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV))
-> ((("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> IO (MemoryRequirements2 a))
-> IO (MemoryRequirements2 a))
-> ContT
(MemoryRequirements2 a)
IO
("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
forall a b. (a -> b) -> a -> b
$ GeneratedCommandsMemoryRequirementsInfoNV
-> (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> IO (MemoryRequirements2 a))
-> IO (MemoryRequirements2 a)
forall a b. ToCStruct a => a -> (Ptr a -> IO b) -> IO b
withCStruct (GeneratedCommandsMemoryRequirementsInfoNV
info)
"pMemoryRequirements" ::: Ptr (MemoryRequirements2 a)
pPMemoryRequirements <- ((("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO (MemoryRequirements2 a))
-> IO (MemoryRequirements2 a))
-> ContT
(MemoryRequirements2 a)
IO
("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (forall b.
ToCStruct (MemoryRequirements2 a) =>
(("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a)) -> IO b)
-> IO b
forall a b. ToCStruct a => (Ptr a -> IO b) -> IO b
withZeroCStruct @(MemoryRequirements2 _))
IO () -> ContT (MemoryRequirements2 a) IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT (MemoryRequirements2 a) IO ())
-> IO () -> ContT (MemoryRequirements2 a) IO ()
forall a b. (a -> b) -> a -> b
$ Ptr Device_T
-> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO ()
vkGetGeneratedCommandsMemoryRequirementsNV' (Device -> Ptr Device_T
deviceHandle (Device
device)) "pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
pInfo ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a)
pPMemoryRequirements)
MemoryRequirements2 a
pMemoryRequirements <- IO (MemoryRequirements2 a)
-> ContT (MemoryRequirements2 a) IO (MemoryRequirements2 a)
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO (MemoryRequirements2 a)
-> ContT (MemoryRequirements2 a) IO (MemoryRequirements2 a))
-> IO (MemoryRequirements2 a)
-> ContT (MemoryRequirements2 a) IO (MemoryRequirements2 a)
forall a b. (a -> b) -> a -> b
$ ("pMemoryRequirements" ::: Ptr (MemoryRequirements2 a))
-> IO (MemoryRequirements2 a)
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct @(MemoryRequirements2 _) "pMemoryRequirements" ::: Ptr (MemoryRequirements2 a)
pPMemoryRequirements
MemoryRequirements2 a
-> ContT (MemoryRequirements2 a) IO (MemoryRequirements2 a)
forall (f :: * -> *) a. Applicative f => a -> f a
pure (MemoryRequirements2 a
-> ContT (MemoryRequirements2 a) IO (MemoryRequirements2 a))
-> MemoryRequirements2 a
-> ContT (MemoryRequirements2 a) IO (MemoryRequirements2 a)
forall a b. (a -> b) -> a -> b
$ (MemoryRequirements2 a
pMemoryRequirements)
foreign import ccall
#if !defined(SAFE_FOREIGN_CALLS)
unsafe
#endif
"dynamic" mkVkCreateIndirectCommandsLayoutNV
:: FunPtr (Ptr Device_T -> Ptr IndirectCommandsLayoutCreateInfoNV -> Ptr AllocationCallbacks -> Ptr IndirectCommandsLayoutNV -> IO Result) -> Ptr Device_T -> Ptr IndirectCommandsLayoutCreateInfoNV -> Ptr AllocationCallbacks -> Ptr IndirectCommandsLayoutNV -> IO Result
createIndirectCommandsLayoutNV :: forall io . MonadIO io => Device -> IndirectCommandsLayoutCreateInfoNV -> ("allocator" ::: Maybe AllocationCallbacks) -> io (IndirectCommandsLayoutNV)
createIndirectCommandsLayoutNV :: Device
-> IndirectCommandsLayoutCreateInfoNV
-> ("allocator" ::: Maybe AllocationCallbacks)
-> io IndirectCommandsLayoutNV
createIndirectCommandsLayoutNV device :: Device
device createInfo :: IndirectCommandsLayoutCreateInfoNV
createInfo allocator :: "allocator" ::: Maybe AllocationCallbacks
allocator = IO IndirectCommandsLayoutNV -> io IndirectCommandsLayoutNV
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO IndirectCommandsLayoutNV -> io IndirectCommandsLayoutNV)
-> (ContT IndirectCommandsLayoutNV IO IndirectCommandsLayoutNV
-> IO IndirectCommandsLayoutNV)
-> ContT IndirectCommandsLayoutNV IO IndirectCommandsLayoutNV
-> io IndirectCommandsLayoutNV
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ContT IndirectCommandsLayoutNV IO IndirectCommandsLayoutNV
-> IO IndirectCommandsLayoutNV
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT IndirectCommandsLayoutNV IO IndirectCommandsLayoutNV
-> io IndirectCommandsLayoutNV)
-> ContT IndirectCommandsLayoutNV IO IndirectCommandsLayoutNV
-> io IndirectCommandsLayoutNV
forall a b. (a -> b) -> a -> b
$ do
let vkCreateIndirectCommandsLayoutNVPtr :: FunPtr
(Ptr Device_T
-> ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO Result)
vkCreateIndirectCommandsLayoutNVPtr = DeviceCmds
-> FunPtr
(Ptr Device_T
-> ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO Result)
pVkCreateIndirectCommandsLayoutNV (Device -> DeviceCmds
deviceCmds (Device
device :: Device))
IO () -> ContT IndirectCommandsLayoutNV IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT IndirectCommandsLayoutNV IO ())
-> IO () -> ContT IndirectCommandsLayoutNV IO ()
forall a b. (a -> b) -> a -> b
$ ("isPreprocessed" ::: Bool) -> IO () -> IO ()
forall (f :: * -> *).
Applicative f =>
("isPreprocessed" ::: Bool) -> f () -> f ()
unless (FunPtr
(Ptr Device_T
-> ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO Result)
vkCreateIndirectCommandsLayoutNVPtr FunPtr
(Ptr Device_T
-> ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO Result)
-> FunPtr
(Ptr Device_T
-> ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO Result)
-> "isPreprocessed" ::: Bool
forall a. Eq a => a -> a -> "isPreprocessed" ::: Bool
/= FunPtr
(Ptr Device_T
-> ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO Result)
forall a. FunPtr a
nullFunPtr) (IO () -> IO ()) -> IO () -> IO ()
forall a b. (a -> b) -> a -> b
$
IOException -> IO ()
forall e a. Exception e => e -> IO a
throwIO (IOException -> IO ()) -> IOException -> IO ()
forall a b. (a -> b) -> a -> b
$ Maybe Handle
-> IOErrorType
-> String
-> String
-> Maybe CInt
-> Maybe String
-> IOException
IOError Maybe Handle
forall a. Maybe a
Nothing IOErrorType
InvalidArgument "" "The function pointer for vkCreateIndirectCommandsLayoutNV is null" Maybe CInt
forall a. Maybe a
Nothing Maybe String
forall a. Maybe a
Nothing
let vkCreateIndirectCommandsLayoutNV' :: Ptr Device_T
-> ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO Result
vkCreateIndirectCommandsLayoutNV' = FunPtr
(Ptr Device_T
-> ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO Result)
-> Ptr Device_T
-> ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO Result
mkVkCreateIndirectCommandsLayoutNV FunPtr
(Ptr Device_T
-> ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO Result)
vkCreateIndirectCommandsLayoutNVPtr
"pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
pCreateInfo <- ((("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> ContT
IndirectCommandsLayoutNV
IO
("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> ContT
IndirectCommandsLayoutNV
IO
("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV))
-> ((("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> ContT
IndirectCommandsLayoutNV
IO
("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
forall a b. (a -> b) -> a -> b
$ IndirectCommandsLayoutCreateInfoNV
-> (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV
forall a b. ToCStruct a => a -> (Ptr a -> IO b) -> IO b
withCStruct (IndirectCommandsLayoutCreateInfoNV
createInfo)
"pAllocator" ::: Ptr AllocationCallbacks
pAllocator <- case ("allocator" ::: Maybe AllocationCallbacks
allocator) of
Nothing -> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ContT
IndirectCommandsLayoutNV
IO
("pAllocator" ::: Ptr AllocationCallbacks)
forall (f :: * -> *) a. Applicative f => a -> f a
pure "pAllocator" ::: Ptr AllocationCallbacks
forall a. Ptr a
nullPtr
Just j :: AllocationCallbacks
j -> ((("pAllocator" ::: Ptr AllocationCallbacks)
-> IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> ContT
IndirectCommandsLayoutNV
IO
("pAllocator" ::: Ptr AllocationCallbacks)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((("pAllocator" ::: Ptr AllocationCallbacks)
-> IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> ContT
IndirectCommandsLayoutNV
IO
("pAllocator" ::: Ptr AllocationCallbacks))
-> ((("pAllocator" ::: Ptr AllocationCallbacks)
-> IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> ContT
IndirectCommandsLayoutNV
IO
("pAllocator" ::: Ptr AllocationCallbacks)
forall a b. (a -> b) -> a -> b
$ AllocationCallbacks
-> (("pAllocator" ::: Ptr AllocationCallbacks)
-> IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV
forall a b. ToCStruct a => a -> (Ptr a -> IO b) -> IO b
withCStruct (AllocationCallbacks
j)
"pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV
pPIndirectCommandsLayout <- ((("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> ContT
IndirectCommandsLayoutNV
IO
("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> ContT
IndirectCommandsLayoutNV
IO
("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV))
-> ((("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> ContT
IndirectCommandsLayoutNV
IO
("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
forall a b. (a -> b) -> a -> b
$ IO ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> (("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO ())
-> (("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV
forall a b c. IO a -> (a -> IO b) -> (a -> IO c) -> IO c
bracket (Int
-> IO ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
forall a. Int -> IO (Ptr a)
callocBytes @IndirectCommandsLayoutNV 8) ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO ()
forall a. Ptr a -> IO ()
free
Result
r <- IO Result -> ContT IndirectCommandsLayoutNV IO Result
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO Result -> ContT IndirectCommandsLayoutNV IO Result)
-> IO Result -> ContT IndirectCommandsLayoutNV IO Result
forall a b. (a -> b) -> a -> b
$ Ptr Device_T
-> ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO Result
vkCreateIndirectCommandsLayoutNV' (Device -> Ptr Device_T
deviceHandle (Device
device)) "pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
pCreateInfo "pAllocator" ::: Ptr AllocationCallbacks
pAllocator ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV
pPIndirectCommandsLayout)
IO () -> ContT IndirectCommandsLayoutNV IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT IndirectCommandsLayoutNV IO ())
-> IO () -> ContT IndirectCommandsLayoutNV IO ()
forall a b. (a -> b) -> a -> b
$ ("isPreprocessed" ::: Bool) -> IO () -> IO ()
forall (f :: * -> *).
Applicative f =>
("isPreprocessed" ::: Bool) -> f () -> f ()
when (Result
r Result -> Result -> "isPreprocessed" ::: Bool
forall a. Ord a => a -> a -> "isPreprocessed" ::: Bool
< Result
SUCCESS) (VulkanException -> IO ()
forall e a. Exception e => e -> IO a
throwIO (Result -> VulkanException
VulkanException Result
r))
IndirectCommandsLayoutNV
pIndirectCommandsLayout <- IO IndirectCommandsLayoutNV
-> ContT IndirectCommandsLayoutNV IO IndirectCommandsLayoutNV
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO IndirectCommandsLayoutNV
-> ContT IndirectCommandsLayoutNV IO IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV
-> ContT IndirectCommandsLayoutNV IO IndirectCommandsLayoutNV
forall a b. (a -> b) -> a -> b
$ ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV
forall a. Storable a => Ptr a -> IO a
peek @IndirectCommandsLayoutNV "pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV
pPIndirectCommandsLayout
IndirectCommandsLayoutNV
-> ContT IndirectCommandsLayoutNV IO IndirectCommandsLayoutNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (IndirectCommandsLayoutNV
-> ContT IndirectCommandsLayoutNV IO IndirectCommandsLayoutNV)
-> IndirectCommandsLayoutNV
-> ContT IndirectCommandsLayoutNV IO IndirectCommandsLayoutNV
forall a b. (a -> b) -> a -> b
$ (IndirectCommandsLayoutNV
pIndirectCommandsLayout)
withIndirectCommandsLayoutNV :: forall io r . MonadIO io => Device -> IndirectCommandsLayoutCreateInfoNV -> Maybe AllocationCallbacks -> (io (IndirectCommandsLayoutNV) -> ((IndirectCommandsLayoutNV) -> io ()) -> r) -> r
withIndirectCommandsLayoutNV :: Device
-> IndirectCommandsLayoutCreateInfoNV
-> ("allocator" ::: Maybe AllocationCallbacks)
-> (io IndirectCommandsLayoutNV
-> (IndirectCommandsLayoutNV -> io ()) -> r)
-> r
withIndirectCommandsLayoutNV device :: Device
device pCreateInfo :: IndirectCommandsLayoutCreateInfoNV
pCreateInfo pAllocator :: "allocator" ::: Maybe AllocationCallbacks
pAllocator b :: io IndirectCommandsLayoutNV
-> (IndirectCommandsLayoutNV -> io ()) -> r
b =
io IndirectCommandsLayoutNV
-> (IndirectCommandsLayoutNV -> io ()) -> r
b (Device
-> IndirectCommandsLayoutCreateInfoNV
-> ("allocator" ::: Maybe AllocationCallbacks)
-> io IndirectCommandsLayoutNV
forall (io :: * -> *).
MonadIO io =>
Device
-> IndirectCommandsLayoutCreateInfoNV
-> ("allocator" ::: Maybe AllocationCallbacks)
-> io IndirectCommandsLayoutNV
createIndirectCommandsLayoutNV Device
device IndirectCommandsLayoutCreateInfoNV
pCreateInfo "allocator" ::: Maybe AllocationCallbacks
pAllocator)
(\(IndirectCommandsLayoutNV
o0) -> Device
-> IndirectCommandsLayoutNV
-> ("allocator" ::: Maybe AllocationCallbacks)
-> io ()
forall (io :: * -> *).
MonadIO io =>
Device
-> IndirectCommandsLayoutNV
-> ("allocator" ::: Maybe AllocationCallbacks)
-> io ()
destroyIndirectCommandsLayoutNV Device
device IndirectCommandsLayoutNV
o0 "allocator" ::: Maybe AllocationCallbacks
pAllocator)
foreign import ccall
#if !defined(SAFE_FOREIGN_CALLS)
unsafe
#endif
"dynamic" mkVkDestroyIndirectCommandsLayoutNV
:: FunPtr (Ptr Device_T -> IndirectCommandsLayoutNV -> Ptr AllocationCallbacks -> IO ()) -> Ptr Device_T -> IndirectCommandsLayoutNV -> Ptr AllocationCallbacks -> IO ()
destroyIndirectCommandsLayoutNV :: forall io . MonadIO io => Device -> IndirectCommandsLayoutNV -> ("allocator" ::: Maybe AllocationCallbacks) -> io ()
destroyIndirectCommandsLayoutNV :: Device
-> IndirectCommandsLayoutNV
-> ("allocator" ::: Maybe AllocationCallbacks)
-> io ()
destroyIndirectCommandsLayoutNV device :: Device
device indirectCommandsLayout :: IndirectCommandsLayoutNV
indirectCommandsLayout allocator :: "allocator" ::: Maybe AllocationCallbacks
allocator = IO () -> io ()
forall (m :: * -> *) a. MonadIO m => IO a -> m a
liftIO (IO () -> io ())
-> (ContT () IO () -> IO ()) -> ContT () IO () -> io ()
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ContT () IO () -> IO ()
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT () IO () -> io ()) -> ContT () IO () -> io ()
forall a b. (a -> b) -> a -> b
$ do
let vkDestroyIndirectCommandsLayoutNVPtr :: FunPtr
(Ptr Device_T
-> IndirectCommandsLayoutNV
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> IO ())
vkDestroyIndirectCommandsLayoutNVPtr = DeviceCmds
-> FunPtr
(Ptr Device_T
-> IndirectCommandsLayoutNV
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> IO ())
pVkDestroyIndirectCommandsLayoutNV (Device -> DeviceCmds
deviceCmds (Device
device :: Device))
IO () -> ContT () IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT () IO ()) -> IO () -> ContT () IO ()
forall a b. (a -> b) -> a -> b
$ ("isPreprocessed" ::: Bool) -> IO () -> IO ()
forall (f :: * -> *).
Applicative f =>
("isPreprocessed" ::: Bool) -> f () -> f ()
unless (FunPtr
(Ptr Device_T
-> IndirectCommandsLayoutNV
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> IO ())
vkDestroyIndirectCommandsLayoutNVPtr FunPtr
(Ptr Device_T
-> IndirectCommandsLayoutNV
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> IO ())
-> FunPtr
(Ptr Device_T
-> IndirectCommandsLayoutNV
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> IO ())
-> "isPreprocessed" ::: Bool
forall a. Eq a => a -> a -> "isPreprocessed" ::: Bool
/= FunPtr
(Ptr Device_T
-> IndirectCommandsLayoutNV
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> IO ())
forall a. FunPtr a
nullFunPtr) (IO () -> IO ()) -> IO () -> IO ()
forall a b. (a -> b) -> a -> b
$
IOException -> IO ()
forall e a. Exception e => e -> IO a
throwIO (IOException -> IO ()) -> IOException -> IO ()
forall a b. (a -> b) -> a -> b
$ Maybe Handle
-> IOErrorType
-> String
-> String
-> Maybe CInt
-> Maybe String
-> IOException
IOError Maybe Handle
forall a. Maybe a
Nothing IOErrorType
InvalidArgument "" "The function pointer for vkDestroyIndirectCommandsLayoutNV is null" Maybe CInt
forall a. Maybe a
Nothing Maybe String
forall a. Maybe a
Nothing
let vkDestroyIndirectCommandsLayoutNV' :: Ptr Device_T
-> IndirectCommandsLayoutNV
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> IO ()
vkDestroyIndirectCommandsLayoutNV' = FunPtr
(Ptr Device_T
-> IndirectCommandsLayoutNV
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> IO ())
-> Ptr Device_T
-> IndirectCommandsLayoutNV
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> IO ()
mkVkDestroyIndirectCommandsLayoutNV FunPtr
(Ptr Device_T
-> IndirectCommandsLayoutNV
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> IO ())
vkDestroyIndirectCommandsLayoutNVPtr
"pAllocator" ::: Ptr AllocationCallbacks
pAllocator <- case ("allocator" ::: Maybe AllocationCallbacks
allocator) of
Nothing -> ("pAllocator" ::: Ptr AllocationCallbacks)
-> ContT () IO ("pAllocator" ::: Ptr AllocationCallbacks)
forall (f :: * -> *) a. Applicative f => a -> f a
pure "pAllocator" ::: Ptr AllocationCallbacks
forall a. Ptr a
nullPtr
Just j :: AllocationCallbacks
j -> ((("pAllocator" ::: Ptr AllocationCallbacks) -> IO ()) -> IO ())
-> ContT () IO ("pAllocator" ::: Ptr AllocationCallbacks)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((("pAllocator" ::: Ptr AllocationCallbacks) -> IO ()) -> IO ())
-> ContT () IO ("pAllocator" ::: Ptr AllocationCallbacks))
-> ((("pAllocator" ::: Ptr AllocationCallbacks) -> IO ()) -> IO ())
-> ContT () IO ("pAllocator" ::: Ptr AllocationCallbacks)
forall a b. (a -> b) -> a -> b
$ AllocationCallbacks
-> (("pAllocator" ::: Ptr AllocationCallbacks) -> IO ()) -> IO ()
forall a b. ToCStruct a => a -> (Ptr a -> IO b) -> IO b
withCStruct (AllocationCallbacks
j)
IO () -> ContT () IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT () IO ()) -> IO () -> ContT () IO ()
forall a b. (a -> b) -> a -> b
$ Ptr Device_T
-> IndirectCommandsLayoutNV
-> ("pAllocator" ::: Ptr AllocationCallbacks)
-> IO ()
vkDestroyIndirectCommandsLayoutNV' (Device -> Ptr Device_T
deviceHandle (Device
device)) (IndirectCommandsLayoutNV
indirectCommandsLayout) "pAllocator" ::: Ptr AllocationCallbacks
pAllocator
() -> ContT () IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure (() -> ContT () IO ()) -> () -> ContT () IO ()
forall a b. (a -> b) -> a -> b
$ ()
data PhysicalDeviceDeviceGeneratedCommandsFeaturesNV = PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
{
PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> "isPreprocessed" ::: Bool
deviceGeneratedCommands :: Bool }
deriving (Typeable)
deriving instance Show PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
instance ToCStruct PhysicalDeviceDeviceGeneratedCommandsFeaturesNV where
withCStruct :: PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> (Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV -> IO b)
-> IO b
withCStruct x :: PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
x f :: Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV -> IO b
f = Int
-> Int
-> (Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV -> IO b)
-> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 24 8 ((Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV -> IO b)
-> IO b)
-> (Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV -> IO b)
-> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p -> Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> PhysicalDeviceDeviceGeneratedCommandsFeaturesNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
x (Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV -> IO b
f Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p)
pokeCStruct :: Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> PhysicalDeviceDeviceGeneratedCommandsFeaturesNV -> IO b -> IO b
pokeCStruct p :: Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p PhysicalDeviceDeviceGeneratedCommandsFeaturesNV{..} f :: IO b
f = do
Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_FEATURES_NV)
Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
Ptr ("isPreprocessed" ::: Bool32)
-> ("isPreprocessed" ::: Bool32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> Int -> Ptr ("isPreprocessed" ::: Bool32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Bool32)) (("isPreprocessed" ::: Bool) -> "isPreprocessed" ::: Bool32
boolToBool32 ("isPreprocessed" ::: Bool
deviceGeneratedCommands))
IO b
f
cStructSize :: Int
cStructSize = 24
cStructAlignment :: Int
cStructAlignment = 8
pokeZeroCStruct :: Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV -> IO b -> IO b
pokeZeroCStruct p :: Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p f :: IO b
f = do
Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_FEATURES_NV)
Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
Ptr ("isPreprocessed" ::: Bool32)
-> ("isPreprocessed" ::: Bool32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> Int -> Ptr ("isPreprocessed" ::: Bool32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Bool32)) (("isPreprocessed" ::: Bool) -> "isPreprocessed" ::: Bool32
boolToBool32 ("isPreprocessed" ::: Bool
forall a. Zero a => a
zero))
IO b
f
instance FromCStruct PhysicalDeviceDeviceGeneratedCommandsFeaturesNV where
peekCStruct :: Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> IO PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
peekCStruct p :: Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p = do
"isPreprocessed" ::: Bool32
deviceGeneratedCommands <- Ptr ("isPreprocessed" ::: Bool32)
-> IO ("isPreprocessed" ::: Bool32)
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> Int -> Ptr ("isPreprocessed" ::: Bool32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Bool32))
PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> IO PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> IO PhysicalDeviceDeviceGeneratedCommandsFeaturesNV)
-> PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> IO PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
forall a b. (a -> b) -> a -> b
$ ("isPreprocessed" ::: Bool)
-> PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
(("isPreprocessed" ::: Bool32) -> "isPreprocessed" ::: Bool
bool32ToBool "isPreprocessed" ::: Bool32
deviceGeneratedCommands)
instance Storable PhysicalDeviceDeviceGeneratedCommandsFeaturesNV where
sizeOf :: PhysicalDeviceDeviceGeneratedCommandsFeaturesNV -> Int
sizeOf ~PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
_ = 24
alignment :: PhysicalDeviceDeviceGeneratedCommandsFeaturesNV -> Int
alignment ~PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
_ = 8
peek :: Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> IO PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
peek = Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> IO PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct
poke :: Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> PhysicalDeviceDeviceGeneratedCommandsFeaturesNV -> IO ()
poke ptr :: Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
ptr poked :: PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
poked = Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
-> IO ()
-> IO ()
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
ptr PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
poked (() -> IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure ())
instance Zero PhysicalDeviceDeviceGeneratedCommandsFeaturesNV where
zero :: PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
zero = ("isPreprocessed" ::: Bool)
-> PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
PhysicalDeviceDeviceGeneratedCommandsFeaturesNV
"isPreprocessed" ::: Bool
forall a. Zero a => a
zero
data PhysicalDeviceDeviceGeneratedCommandsPropertiesNV = PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
{
PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> "groupIndex" ::: Word32
maxGraphicsShaderGroupCount :: Word32
,
PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> "groupIndex" ::: Word32
maxIndirectSequenceCount :: Word32
,
PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> "groupIndex" ::: Word32
maxIndirectCommandsTokenCount :: Word32
,
PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> "groupIndex" ::: Word32
maxIndirectCommandsStreamCount :: Word32
,
PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> "groupIndex" ::: Word32
maxIndirectCommandsTokenOffset :: Word32
,
PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> "groupIndex" ::: Word32
maxIndirectCommandsStreamStride :: Word32
,
PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> "groupIndex" ::: Word32
minSequencesCountBufferOffsetAlignment :: Word32
,
PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> "groupIndex" ::: Word32
minSequencesIndexBufferOffsetAlignment :: Word32
,
PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> "groupIndex" ::: Word32
minIndirectCommandsBufferOffsetAlignment :: Word32
}
deriving (Typeable)
deriving instance Show PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
instance ToCStruct PhysicalDeviceDeviceGeneratedCommandsPropertiesNV where
withCStruct :: PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> (Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV -> IO b)
-> IO b
withCStruct x :: PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
x f :: Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV -> IO b
f = Int
-> Int
-> (Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV -> IO b)
-> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 56 8 ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV -> IO b)
-> IO b)
-> (Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV -> IO b)
-> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p -> Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> IO b
-> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
x (Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV -> IO b
f Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p)
pokeCStruct :: Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> IO b
-> IO b
pokeCStruct p :: Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p PhysicalDeviceDeviceGeneratedCommandsPropertiesNV{..} f :: IO b
f = do
Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_PROPERTIES_NV)
Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32)) ("groupIndex" ::: Word32
maxGraphicsShaderGroupCount)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Word32)) ("groupIndex" ::: Word32
maxIndirectSequenceCount)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Word32)) ("groupIndex" ::: Word32
maxIndirectCommandsTokenCount)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 28 :: Ptr Word32)) ("groupIndex" ::: Word32
maxIndirectCommandsStreamCount)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Word32)) ("groupIndex" ::: Word32
maxIndirectCommandsTokenOffset)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 36 :: Ptr Word32)) ("groupIndex" ::: Word32
maxIndirectCommandsStreamStride)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Word32)) ("groupIndex" ::: Word32
minSequencesCountBufferOffsetAlignment)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 44 :: Ptr Word32)) ("groupIndex" ::: Word32
minSequencesIndexBufferOffsetAlignment)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr Word32)) ("groupIndex" ::: Word32
minIndirectCommandsBufferOffsetAlignment)
IO b
f
cStructSize :: Int
cStructSize = 56
cStructAlignment :: Int
cStructAlignment = 8
pokeZeroCStruct :: Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> IO b -> IO b
pokeZeroCStruct p :: Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p f :: IO b
f = do
Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_PHYSICAL_DEVICE_DEVICE_GENERATED_COMMANDS_PROPERTIES_NV)
Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 28 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 36 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 44 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
IO b
f
instance FromCStruct PhysicalDeviceDeviceGeneratedCommandsPropertiesNV where
peekCStruct :: Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> IO PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
peekCStruct p :: Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p = do
"groupIndex" ::: Word32
maxGraphicsShaderGroupCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32))
"groupIndex" ::: Word32
maxIndirectSequenceCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Word32))
"groupIndex" ::: Word32
maxIndirectCommandsTokenCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Word32))
"groupIndex" ::: Word32
maxIndirectCommandsStreamCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 28 :: Ptr Word32))
"groupIndex" ::: Word32
maxIndirectCommandsTokenOffset <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Word32))
"groupIndex" ::: Word32
maxIndirectCommandsStreamStride <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 36 :: Ptr Word32))
"groupIndex" ::: Word32
minSequencesCountBufferOffsetAlignment <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Word32))
"groupIndex" ::: Word32
minSequencesIndexBufferOffsetAlignment <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 44 :: Ptr Word32))
"groupIndex" ::: Word32
minIndirectCommandsBufferOffsetAlignment <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
p Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr Word32))
PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> IO PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> IO PhysicalDeviceDeviceGeneratedCommandsPropertiesNV)
-> PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> IO PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
forall a b. (a -> b) -> a -> b
$ ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
"groupIndex" ::: Word32
maxGraphicsShaderGroupCount "groupIndex" ::: Word32
maxIndirectSequenceCount "groupIndex" ::: Word32
maxIndirectCommandsTokenCount "groupIndex" ::: Word32
maxIndirectCommandsStreamCount "groupIndex" ::: Word32
maxIndirectCommandsTokenOffset "groupIndex" ::: Word32
maxIndirectCommandsStreamStride "groupIndex" ::: Word32
minSequencesCountBufferOffsetAlignment "groupIndex" ::: Word32
minSequencesIndexBufferOffsetAlignment "groupIndex" ::: Word32
minIndirectCommandsBufferOffsetAlignment
instance Storable PhysicalDeviceDeviceGeneratedCommandsPropertiesNV where
sizeOf :: PhysicalDeviceDeviceGeneratedCommandsPropertiesNV -> Int
sizeOf ~PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
_ = 56
alignment :: PhysicalDeviceDeviceGeneratedCommandsPropertiesNV -> Int
alignment ~PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
_ = 8
peek :: Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> IO PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
peek = Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> IO PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct
poke :: Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> PhysicalDeviceDeviceGeneratedCommandsPropertiesNV -> IO ()
poke ptr :: Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
ptr poked :: PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
poked = Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
-> IO ()
-> IO ()
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
ptr PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
poked (() -> IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure ())
instance Zero PhysicalDeviceDeviceGeneratedCommandsPropertiesNV where
zero :: PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
zero = ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
PhysicalDeviceDeviceGeneratedCommandsPropertiesNV
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
data GraphicsShaderGroupCreateInfoNV = GraphicsShaderGroupCreateInfoNV
{
GraphicsShaderGroupCreateInfoNV
-> Vector (SomeStruct PipelineShaderStageCreateInfo)
stages :: Vector (SomeStruct PipelineShaderStageCreateInfo)
,
GraphicsShaderGroupCreateInfoNV
-> Maybe (SomeStruct PipelineVertexInputStateCreateInfo)
vertexInputState :: Maybe (SomeStruct PipelineVertexInputStateCreateInfo)
,
GraphicsShaderGroupCreateInfoNV
-> Maybe (SomeStruct PipelineTessellationStateCreateInfo)
tessellationState :: Maybe (SomeStruct PipelineTessellationStateCreateInfo)
}
deriving (Typeable)
deriving instance Show GraphicsShaderGroupCreateInfoNV
instance ToCStruct GraphicsShaderGroupCreateInfoNV where
withCStruct :: GraphicsShaderGroupCreateInfoNV
-> (Ptr GraphicsShaderGroupCreateInfoNV -> IO b) -> IO b
withCStruct x :: GraphicsShaderGroupCreateInfoNV
x f :: Ptr GraphicsShaderGroupCreateInfoNV -> IO b
f = Int -> Int -> (Ptr GraphicsShaderGroupCreateInfoNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 48 8 ((Ptr GraphicsShaderGroupCreateInfoNV -> IO b) -> IO b)
-> (Ptr GraphicsShaderGroupCreateInfoNV -> IO b) -> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr GraphicsShaderGroupCreateInfoNV
p -> Ptr GraphicsShaderGroupCreateInfoNV
-> GraphicsShaderGroupCreateInfoNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr GraphicsShaderGroupCreateInfoNV
p GraphicsShaderGroupCreateInfoNV
x (Ptr GraphicsShaderGroupCreateInfoNV -> IO b
f Ptr GraphicsShaderGroupCreateInfoNV
p)
pokeCStruct :: Ptr GraphicsShaderGroupCreateInfoNV
-> GraphicsShaderGroupCreateInfoNV -> IO b -> IO b
pokeCStruct p :: Ptr GraphicsShaderGroupCreateInfoNV
p GraphicsShaderGroupCreateInfoNV{..} f :: IO b
f = ContT b IO b -> IO b
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT b IO b -> IO b) -> ContT b IO b -> IO b
forall a b. (a -> b) -> a -> b
$ do
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV -> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_GRAPHICS_SHADER_GROUP_CREATE_INFO_NV)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32)) ((Int -> "groupIndex" ::: Word32
forall a b. (Integral a, Num b) => a -> b
fromIntegral (Vector (SomeStruct PipelineShaderStageCreateInfo) -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector (SomeStruct PipelineShaderStageCreateInfo) -> Int)
-> Vector (SomeStruct PipelineShaderStageCreateInfo) -> Int
forall a b. (a -> b) -> a -> b
$ (Vector (SomeStruct PipelineShaderStageCreateInfo)
stages)) :: Word32))
Ptr (PipelineShaderStageCreateInfo Any)
pPStages' <- ((Ptr (PipelineShaderStageCreateInfo Any) -> IO b) -> IO b)
-> ContT b IO (Ptr (PipelineShaderStageCreateInfo Any))
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr (PipelineShaderStageCreateInfo Any) -> IO b) -> IO b)
-> ContT b IO (Ptr (PipelineShaderStageCreateInfo Any)))
-> ((Ptr (PipelineShaderStageCreateInfo Any) -> IO b) -> IO b)
-> ContT b IO (Ptr (PipelineShaderStageCreateInfo Any))
forall a b. (a -> b) -> a -> b
$ Int
-> Int -> (Ptr (PipelineShaderStageCreateInfo Any) -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @(PipelineShaderStageCreateInfo _) ((Vector (SomeStruct PipelineShaderStageCreateInfo) -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector (SomeStruct PipelineShaderStageCreateInfo)
stages)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 48) 8
(Int -> SomeStruct PipelineShaderStageCreateInfo -> ContT b IO ())
-> Vector (SomeStruct PipelineShaderStageCreateInfo)
-> ContT b IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: SomeStruct PipelineShaderStageCreateInfo
e -> ((() -> IO b) -> IO b) -> ContT b IO ()
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((() -> IO b) -> IO b) -> ContT b IO ())
-> ((() -> IO b) -> IO b) -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (SomeStruct PipelineShaderStageCreateInfo)
-> SomeStruct PipelineShaderStageCreateInfo -> IO b -> IO b
forall (a :: [*] -> *) b.
(forall (es :: [*]).
(Extendss a es, PokeChain es) =>
ToCStruct (a es)) =>
Ptr (SomeStruct a) -> SomeStruct a -> IO b -> IO b
pokeSomeCStruct (Ptr (PipelineShaderStageCreateInfo Any)
-> Ptr (SomeStruct PipelineShaderStageCreateInfo)
forall (a :: [*] -> *) (es :: [*]).
Ptr (a es) -> Ptr (SomeStruct a)
forgetExtensions (Ptr (PipelineShaderStageCreateInfo Any)
pPStages' Ptr (PipelineShaderStageCreateInfo Any)
-> Int -> Ptr (PipelineShaderStageCreateInfo _)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (48 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr (PipelineShaderStageCreateInfo _))) (SomeStruct PipelineShaderStageCreateInfo
e) (IO b -> IO b) -> ((() -> IO b) -> IO b) -> (() -> IO b) -> IO b
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ((() -> IO b) -> () -> IO b
forall a b. (a -> b) -> a -> b
$ ())) (Vector (SomeStruct PipelineShaderStageCreateInfo)
stages)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr (PipelineShaderStageCreateInfo Any))
-> Ptr (PipelineShaderStageCreateInfo Any) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV
-> Int -> Ptr (Ptr (PipelineShaderStageCreateInfo _))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr (Ptr (PipelineShaderStageCreateInfo _)))) (Ptr (PipelineShaderStageCreateInfo Any)
pPStages')
Ptr (PipelineVertexInputStateCreateInfo '[])
pVertexInputState'' <- case (Maybe (SomeStruct PipelineVertexInputStateCreateInfo)
vertexInputState) of
Nothing -> Ptr (PipelineVertexInputStateCreateInfo '[])
-> ContT b IO (Ptr (PipelineVertexInputStateCreateInfo '[]))
forall (f :: * -> *) a. Applicative f => a -> f a
pure Ptr (PipelineVertexInputStateCreateInfo '[])
forall a. Ptr a
nullPtr
Just j :: SomeStruct PipelineVertexInputStateCreateInfo
j -> ((Ptr (PipelineVertexInputStateCreateInfo '[]) -> IO b) -> IO b)
-> ContT b IO (Ptr (PipelineVertexInputStateCreateInfo '[]))
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT @_ @_ @(Ptr (PipelineVertexInputStateCreateInfo '[])) (((Ptr (PipelineVertexInputStateCreateInfo '[]) -> IO b) -> IO b)
-> ContT b IO (Ptr (PipelineVertexInputStateCreateInfo '[])))
-> ((Ptr (PipelineVertexInputStateCreateInfo '[]) -> IO b) -> IO b)
-> ContT b IO (Ptr (PipelineVertexInputStateCreateInfo '[]))
forall a b. (a -> b) -> a -> b
$ \cont :: Ptr (PipelineVertexInputStateCreateInfo '[]) -> IO b
cont -> SomeStruct PipelineVertexInputStateCreateInfo
-> (forall (es :: [*]).
(Extendss PipelineVertexInputStateCreateInfo es, PokeChain es) =>
Ptr (PipelineVertexInputStateCreateInfo es) -> IO b)
-> IO b
forall (a :: [*] -> *) b.
(forall (es :: [*]).
(Extendss a es, PokeChain es) =>
ToCStruct (a es)) =>
SomeStruct a
-> (forall (es :: [*]).
(Extendss a es, PokeChain es) =>
Ptr (a es) -> IO b)
-> IO b
withSomeCStruct @PipelineVertexInputStateCreateInfo (SomeStruct PipelineVertexInputStateCreateInfo
j) (Ptr (PipelineVertexInputStateCreateInfo '[]) -> IO b
cont (Ptr (PipelineVertexInputStateCreateInfo '[]) -> IO b)
-> (Ptr (PipelineVertexInputStateCreateInfo es)
-> Ptr (PipelineVertexInputStateCreateInfo '[]))
-> Ptr (PipelineVertexInputStateCreateInfo es)
-> IO b
forall b c a. (b -> c) -> (a -> b) -> a -> c
. Ptr (PipelineVertexInputStateCreateInfo es)
-> Ptr (PipelineVertexInputStateCreateInfo '[])
forall a b. Ptr a -> Ptr b
castPtr)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr (PipelineVertexInputStateCreateInfo '[]))
-> Ptr (PipelineVertexInputStateCreateInfo '[]) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV
-> Int -> Ptr (Ptr (PipelineVertexInputStateCreateInfo _))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr (Ptr (PipelineVertexInputStateCreateInfo _)))) Ptr (PipelineVertexInputStateCreateInfo '[])
pVertexInputState''
Ptr (PipelineTessellationStateCreateInfo '[])
pTessellationState'' <- case (Maybe (SomeStruct PipelineTessellationStateCreateInfo)
tessellationState) of
Nothing -> Ptr (PipelineTessellationStateCreateInfo '[])
-> ContT b IO (Ptr (PipelineTessellationStateCreateInfo '[]))
forall (f :: * -> *) a. Applicative f => a -> f a
pure Ptr (PipelineTessellationStateCreateInfo '[])
forall a. Ptr a
nullPtr
Just j :: SomeStruct PipelineTessellationStateCreateInfo
j -> ((Ptr (PipelineTessellationStateCreateInfo '[]) -> IO b) -> IO b)
-> ContT b IO (Ptr (PipelineTessellationStateCreateInfo '[]))
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT @_ @_ @(Ptr (PipelineTessellationStateCreateInfo '[])) (((Ptr (PipelineTessellationStateCreateInfo '[]) -> IO b) -> IO b)
-> ContT b IO (Ptr (PipelineTessellationStateCreateInfo '[])))
-> ((Ptr (PipelineTessellationStateCreateInfo '[]) -> IO b)
-> IO b)
-> ContT b IO (Ptr (PipelineTessellationStateCreateInfo '[]))
forall a b. (a -> b) -> a -> b
$ \cont :: Ptr (PipelineTessellationStateCreateInfo '[]) -> IO b
cont -> SomeStruct PipelineTessellationStateCreateInfo
-> (forall (es :: [*]).
(Extendss PipelineTessellationStateCreateInfo es, PokeChain es) =>
Ptr (PipelineTessellationStateCreateInfo es) -> IO b)
-> IO b
forall (a :: [*] -> *) b.
(forall (es :: [*]).
(Extendss a es, PokeChain es) =>
ToCStruct (a es)) =>
SomeStruct a
-> (forall (es :: [*]).
(Extendss a es, PokeChain es) =>
Ptr (a es) -> IO b)
-> IO b
withSomeCStruct @PipelineTessellationStateCreateInfo (SomeStruct PipelineTessellationStateCreateInfo
j) (Ptr (PipelineTessellationStateCreateInfo '[]) -> IO b
cont (Ptr (PipelineTessellationStateCreateInfo '[]) -> IO b)
-> (Ptr (PipelineTessellationStateCreateInfo es)
-> Ptr (PipelineTessellationStateCreateInfo '[]))
-> Ptr (PipelineTessellationStateCreateInfo es)
-> IO b
forall b c a. (b -> c) -> (a -> b) -> a -> c
. Ptr (PipelineTessellationStateCreateInfo es)
-> Ptr (PipelineTessellationStateCreateInfo '[])
forall a b. Ptr a -> Ptr b
castPtr)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr (PipelineTessellationStateCreateInfo '[]))
-> Ptr (PipelineTessellationStateCreateInfo '[]) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV
-> Int -> Ptr (Ptr (PipelineTessellationStateCreateInfo _))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr (Ptr (PipelineTessellationStateCreateInfo _)))) Ptr (PipelineTessellationStateCreateInfo '[])
pTessellationState''
IO b -> ContT b IO b
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO b -> ContT b IO b) -> IO b -> ContT b IO b
forall a b. (a -> b) -> a -> b
$ IO b
f
cStructSize :: Int
cStructSize = 48
cStructAlignment :: Int
cStructAlignment = 8
pokeZeroCStruct :: Ptr GraphicsShaderGroupCreateInfoNV -> IO b -> IO b
pokeZeroCStruct p :: Ptr GraphicsShaderGroupCreateInfoNV
p f :: IO b
f = ContT b IO b -> IO b
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT b IO b -> IO b) -> ContT b IO b -> IO b
forall a b. (a -> b) -> a -> b
$ do
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV -> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_GRAPHICS_SHADER_GROUP_CREATE_INFO_NV)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
Ptr (PipelineShaderStageCreateInfo Any)
pPStages' <- ((Ptr (PipelineShaderStageCreateInfo Any) -> IO b) -> IO b)
-> ContT b IO (Ptr (PipelineShaderStageCreateInfo Any))
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr (PipelineShaderStageCreateInfo Any) -> IO b) -> IO b)
-> ContT b IO (Ptr (PipelineShaderStageCreateInfo Any)))
-> ((Ptr (PipelineShaderStageCreateInfo Any) -> IO b) -> IO b)
-> ContT b IO (Ptr (PipelineShaderStageCreateInfo Any))
forall a b. (a -> b) -> a -> b
$ Int
-> Int -> (Ptr (PipelineShaderStageCreateInfo Any) -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @(PipelineShaderStageCreateInfo _) ((Vector Any -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector Any
forall a. Monoid a => a
mempty)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 48) 8
(Int -> SomeStruct PipelineShaderStageCreateInfo -> ContT b IO ())
-> Vector (SomeStruct PipelineShaderStageCreateInfo)
-> ContT b IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: SomeStruct PipelineShaderStageCreateInfo
e -> ((() -> IO b) -> IO b) -> ContT b IO ()
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((() -> IO b) -> IO b) -> ContT b IO ())
-> ((() -> IO b) -> IO b) -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (SomeStruct PipelineShaderStageCreateInfo)
-> SomeStruct PipelineShaderStageCreateInfo -> IO b -> IO b
forall (a :: [*] -> *) b.
(forall (es :: [*]).
(Extendss a es, PokeChain es) =>
ToCStruct (a es)) =>
Ptr (SomeStruct a) -> SomeStruct a -> IO b -> IO b
pokeSomeCStruct (Ptr (PipelineShaderStageCreateInfo Any)
-> Ptr (SomeStruct PipelineShaderStageCreateInfo)
forall (a :: [*] -> *) (es :: [*]).
Ptr (a es) -> Ptr (SomeStruct a)
forgetExtensions (Ptr (PipelineShaderStageCreateInfo Any)
pPStages' Ptr (PipelineShaderStageCreateInfo Any)
-> Int -> Ptr (PipelineShaderStageCreateInfo _)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (48 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr (PipelineShaderStageCreateInfo _))) (SomeStruct PipelineShaderStageCreateInfo
e) (IO b -> IO b) -> ((() -> IO b) -> IO b) -> (() -> IO b) -> IO b
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ((() -> IO b) -> () -> IO b
forall a b. (a -> b) -> a -> b
$ ())) (Vector (SomeStruct PipelineShaderStageCreateInfo)
forall a. Monoid a => a
mempty)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr (PipelineShaderStageCreateInfo Any))
-> Ptr (PipelineShaderStageCreateInfo Any) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV
-> Int -> Ptr (Ptr (PipelineShaderStageCreateInfo _))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr (Ptr (PipelineShaderStageCreateInfo _)))) (Ptr (PipelineShaderStageCreateInfo Any)
pPStages')
IO b -> ContT b IO b
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO b -> ContT b IO b) -> IO b -> ContT b IO b
forall a b. (a -> b) -> a -> b
$ IO b
f
instance FromCStruct GraphicsShaderGroupCreateInfoNV where
peekCStruct :: Ptr GraphicsShaderGroupCreateInfoNV
-> IO GraphicsShaderGroupCreateInfoNV
peekCStruct p :: Ptr GraphicsShaderGroupCreateInfoNV
p = do
"groupIndex" ::: Word32
stageCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32))
Ptr (PipelineShaderStageCreateInfo Any)
pStages <- Ptr (Ptr (PipelineShaderStageCreateInfo Any))
-> IO (Ptr (PipelineShaderStageCreateInfo Any))
forall a. Storable a => Ptr a -> IO a
peek @(Ptr (PipelineShaderStageCreateInfo _)) ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV
-> Int -> Ptr (Ptr (PipelineShaderStageCreateInfo a))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr (Ptr (PipelineShaderStageCreateInfo a))))
Vector (SomeStruct PipelineShaderStageCreateInfo)
pStages' <- Int
-> (Int -> IO (SomeStruct PipelineShaderStageCreateInfo))
-> IO (Vector (SomeStruct PipelineShaderStageCreateInfo))
forall (m :: * -> *) a.
Monad m =>
Int -> (Int -> m a) -> m (Vector a)
generateM (("groupIndex" ::: Word32) -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral "groupIndex" ::: Word32
stageCount) (\i :: Int
i -> Ptr (SomeStruct PipelineShaderStageCreateInfo)
-> IO (SomeStruct PipelineShaderStageCreateInfo)
forall (a :: [*] -> *).
(Extensible a,
forall (es :: [*]).
(Extendss a es, PeekChain es) =>
FromCStruct (a es)) =>
Ptr (SomeStruct a) -> IO (SomeStruct a)
peekSomeCStruct (Ptr (PipelineShaderStageCreateInfo Any)
-> Ptr (SomeStruct PipelineShaderStageCreateInfo)
forall (a :: [*] -> *) (es :: [*]).
Ptr (a es) -> Ptr (SomeStruct a)
forgetExtensions ((Ptr (PipelineShaderStageCreateInfo Any)
pStages Ptr (PipelineShaderStageCreateInfo Any)
-> Int -> Ptr (PipelineShaderStageCreateInfo Any)
forall a. Ptr a -> Int -> Ptr a
`advancePtrBytes` (48 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr (PipelineShaderStageCreateInfo _)))))
Ptr (PipelineVertexInputStateCreateInfo Any)
pVertexInputState <- Ptr (Ptr (PipelineVertexInputStateCreateInfo Any))
-> IO (Ptr (PipelineVertexInputStateCreateInfo Any))
forall a. Storable a => Ptr a -> IO a
peek @(Ptr (PipelineVertexInputStateCreateInfo _)) ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV
-> Int -> Ptr (Ptr (PipelineVertexInputStateCreateInfo a))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr (Ptr (PipelineVertexInputStateCreateInfo a))))
Maybe (SomeStruct PipelineVertexInputStateCreateInfo)
pVertexInputState' <- (Ptr (PipelineVertexInputStateCreateInfo Any)
-> IO (SomeStruct PipelineVertexInputStateCreateInfo))
-> Ptr (PipelineVertexInputStateCreateInfo Any)
-> IO (Maybe (SomeStruct PipelineVertexInputStateCreateInfo))
forall a b. (Ptr a -> IO b) -> Ptr a -> IO (Maybe b)
maybePeek (\j :: Ptr (PipelineVertexInputStateCreateInfo Any)
j -> Ptr (SomeStruct PipelineVertexInputStateCreateInfo)
-> IO (SomeStruct PipelineVertexInputStateCreateInfo)
forall (a :: [*] -> *).
(Extensible a,
forall (es :: [*]).
(Extendss a es, PeekChain es) =>
FromCStruct (a es)) =>
Ptr (SomeStruct a) -> IO (SomeStruct a)
peekSomeCStruct (Ptr (PipelineVertexInputStateCreateInfo Any)
-> Ptr (SomeStruct PipelineVertexInputStateCreateInfo)
forall (a :: [*] -> *) (es :: [*]).
Ptr (a es) -> Ptr (SomeStruct a)
forgetExtensions (Ptr (PipelineVertexInputStateCreateInfo Any)
j))) Ptr (PipelineVertexInputStateCreateInfo Any)
pVertexInputState
Ptr (PipelineTessellationStateCreateInfo Any)
pTessellationState <- Ptr (Ptr (PipelineTessellationStateCreateInfo Any))
-> IO (Ptr (PipelineTessellationStateCreateInfo Any))
forall a. Storable a => Ptr a -> IO a
peek @(Ptr (PipelineTessellationStateCreateInfo _)) ((Ptr GraphicsShaderGroupCreateInfoNV
p Ptr GraphicsShaderGroupCreateInfoNV
-> Int -> Ptr (Ptr (PipelineTessellationStateCreateInfo a))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr (Ptr (PipelineTessellationStateCreateInfo a))))
Maybe (SomeStruct PipelineTessellationStateCreateInfo)
pTessellationState' <- (Ptr (PipelineTessellationStateCreateInfo Any)
-> IO (SomeStruct PipelineTessellationStateCreateInfo))
-> Ptr (PipelineTessellationStateCreateInfo Any)
-> IO (Maybe (SomeStruct PipelineTessellationStateCreateInfo))
forall a b. (Ptr a -> IO b) -> Ptr a -> IO (Maybe b)
maybePeek (\j :: Ptr (PipelineTessellationStateCreateInfo Any)
j -> Ptr (SomeStruct PipelineTessellationStateCreateInfo)
-> IO (SomeStruct PipelineTessellationStateCreateInfo)
forall (a :: [*] -> *).
(Extensible a,
forall (es :: [*]).
(Extendss a es, PeekChain es) =>
FromCStruct (a es)) =>
Ptr (SomeStruct a) -> IO (SomeStruct a)
peekSomeCStruct (Ptr (PipelineTessellationStateCreateInfo Any)
-> Ptr (SomeStruct PipelineTessellationStateCreateInfo)
forall (a :: [*] -> *) (es :: [*]).
Ptr (a es) -> Ptr (SomeStruct a)
forgetExtensions (Ptr (PipelineTessellationStateCreateInfo Any)
j))) Ptr (PipelineTessellationStateCreateInfo Any)
pTessellationState
GraphicsShaderGroupCreateInfoNV
-> IO GraphicsShaderGroupCreateInfoNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (GraphicsShaderGroupCreateInfoNV
-> IO GraphicsShaderGroupCreateInfoNV)
-> GraphicsShaderGroupCreateInfoNV
-> IO GraphicsShaderGroupCreateInfoNV
forall a b. (a -> b) -> a -> b
$ Vector (SomeStruct PipelineShaderStageCreateInfo)
-> Maybe (SomeStruct PipelineVertexInputStateCreateInfo)
-> Maybe (SomeStruct PipelineTessellationStateCreateInfo)
-> GraphicsShaderGroupCreateInfoNV
GraphicsShaderGroupCreateInfoNV
Vector (SomeStruct PipelineShaderStageCreateInfo)
pStages' Maybe (SomeStruct PipelineVertexInputStateCreateInfo)
pVertexInputState' Maybe (SomeStruct PipelineTessellationStateCreateInfo)
pTessellationState'
instance Zero GraphicsShaderGroupCreateInfoNV where
zero :: GraphicsShaderGroupCreateInfoNV
zero = Vector (SomeStruct PipelineShaderStageCreateInfo)
-> Maybe (SomeStruct PipelineVertexInputStateCreateInfo)
-> Maybe (SomeStruct PipelineTessellationStateCreateInfo)
-> GraphicsShaderGroupCreateInfoNV
GraphicsShaderGroupCreateInfoNV
Vector (SomeStruct PipelineShaderStageCreateInfo)
forall a. Monoid a => a
mempty
Maybe (SomeStruct PipelineVertexInputStateCreateInfo)
forall a. Maybe a
Nothing
Maybe (SomeStruct PipelineTessellationStateCreateInfo)
forall a. Maybe a
Nothing
data GraphicsPipelineShaderGroupsCreateInfoNV = GraphicsPipelineShaderGroupsCreateInfoNV
{
GraphicsPipelineShaderGroupsCreateInfoNV
-> Vector GraphicsShaderGroupCreateInfoNV
groups :: Vector GraphicsShaderGroupCreateInfoNV
,
GraphicsPipelineShaderGroupsCreateInfoNV -> Vector Pipeline
pipelines :: Vector Pipeline
}
deriving (Typeable)
deriving instance Show GraphicsPipelineShaderGroupsCreateInfoNV
instance ToCStruct GraphicsPipelineShaderGroupsCreateInfoNV where
withCStruct :: GraphicsPipelineShaderGroupsCreateInfoNV
-> (Ptr GraphicsPipelineShaderGroupsCreateInfoNV -> IO b) -> IO b
withCStruct x :: GraphicsPipelineShaderGroupsCreateInfoNV
x f :: Ptr GraphicsPipelineShaderGroupsCreateInfoNV -> IO b
f = Int
-> Int
-> (Ptr GraphicsPipelineShaderGroupsCreateInfoNV -> IO b)
-> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 48 8 ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV -> IO b) -> IO b)
-> (Ptr GraphicsPipelineShaderGroupsCreateInfoNV -> IO b) -> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p -> Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> GraphicsPipelineShaderGroupsCreateInfoNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p GraphicsPipelineShaderGroupsCreateInfoNV
x (Ptr GraphicsPipelineShaderGroupsCreateInfoNV -> IO b
f Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p)
pokeCStruct :: Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> GraphicsPipelineShaderGroupsCreateInfoNV -> IO b -> IO b
pokeCStruct p :: Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p GraphicsPipelineShaderGroupsCreateInfoNV{..} f :: IO b
f = ContT b IO b -> IO b
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT b IO b -> IO b) -> ContT b IO b -> IO b
forall a b. (a -> b) -> a -> b
$ do
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_GRAPHICS_PIPELINE_SHADER_GROUPS_CREATE_INFO_NV)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32)) ((Int -> "groupIndex" ::: Word32
forall a b. (Integral a, Num b) => a -> b
fromIntegral (Vector GraphicsShaderGroupCreateInfoNV -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector GraphicsShaderGroupCreateInfoNV -> Int)
-> Vector GraphicsShaderGroupCreateInfoNV -> Int
forall a b. (a -> b) -> a -> b
$ (Vector GraphicsShaderGroupCreateInfoNV
groups)) :: Word32))
Ptr GraphicsShaderGroupCreateInfoNV
pPGroups' <- ((Ptr GraphicsShaderGroupCreateInfoNV -> IO b) -> IO b)
-> ContT b IO (Ptr GraphicsShaderGroupCreateInfoNV)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr GraphicsShaderGroupCreateInfoNV -> IO b) -> IO b)
-> ContT b IO (Ptr GraphicsShaderGroupCreateInfoNV))
-> ((Ptr GraphicsShaderGroupCreateInfoNV -> IO b) -> IO b)
-> ContT b IO (Ptr GraphicsShaderGroupCreateInfoNV)
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr GraphicsShaderGroupCreateInfoNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @GraphicsShaderGroupCreateInfoNV ((Vector GraphicsShaderGroupCreateInfoNV -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector GraphicsShaderGroupCreateInfoNV
groups)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 48) 8
(Int -> GraphicsShaderGroupCreateInfoNV -> ContT b IO ())
-> Vector GraphicsShaderGroupCreateInfoNV -> ContT b IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: GraphicsShaderGroupCreateInfoNV
e -> ((() -> IO b) -> IO b) -> ContT b IO ()
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((() -> IO b) -> IO b) -> ContT b IO ())
-> ((() -> IO b) -> IO b) -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr GraphicsShaderGroupCreateInfoNV
-> GraphicsShaderGroupCreateInfoNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct (Ptr GraphicsShaderGroupCreateInfoNV
pPGroups' Ptr GraphicsShaderGroupCreateInfoNV
-> Int -> Ptr GraphicsShaderGroupCreateInfoNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (48 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr GraphicsShaderGroupCreateInfoNV) (GraphicsShaderGroupCreateInfoNV
e) (IO b -> IO b) -> ((() -> IO b) -> IO b) -> (() -> IO b) -> IO b
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ((() -> IO b) -> () -> IO b
forall a b. (a -> b) -> a -> b
$ ())) (Vector GraphicsShaderGroupCreateInfoNV
groups)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr GraphicsShaderGroupCreateInfoNV)
-> Ptr GraphicsShaderGroupCreateInfoNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> Int -> Ptr (Ptr GraphicsShaderGroupCreateInfoNV)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr (Ptr GraphicsShaderGroupCreateInfoNV))) (Ptr GraphicsShaderGroupCreateInfoNV
pPGroups')
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Word32)) ((Int -> "groupIndex" ::: Word32
forall a b. (Integral a, Num b) => a -> b
fromIntegral (Vector Pipeline -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector Pipeline -> Int) -> Vector Pipeline -> Int
forall a b. (a -> b) -> a -> b
$ (Vector Pipeline
pipelines)) :: Word32))
Ptr Pipeline
pPPipelines' <- ((Ptr Pipeline -> IO b) -> IO b) -> ContT b IO (Ptr Pipeline)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr Pipeline -> IO b) -> IO b) -> ContT b IO (Ptr Pipeline))
-> ((Ptr Pipeline -> IO b) -> IO b) -> ContT b IO (Ptr Pipeline)
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr Pipeline -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @Pipeline ((Vector Pipeline -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector Pipeline
pipelines)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 8) 8
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ (Int -> Pipeline -> IO ()) -> Vector Pipeline -> IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: Pipeline
e -> Ptr Pipeline -> Pipeline -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Pipeline
pPPipelines' Ptr Pipeline -> Int -> Ptr Pipeline
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (8 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr Pipeline) (Pipeline
e)) (Vector Pipeline
pipelines)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr Pipeline) -> Ptr Pipeline -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> Int -> Ptr (Ptr Pipeline)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr (Ptr Pipeline))) (Ptr Pipeline
pPPipelines')
IO b -> ContT b IO b
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO b -> ContT b IO b) -> IO b -> ContT b IO b
forall a b. (a -> b) -> a -> b
$ IO b
f
cStructSize :: Int
cStructSize = 48
cStructAlignment :: Int
cStructAlignment = 8
pokeZeroCStruct :: Ptr GraphicsPipelineShaderGroupsCreateInfoNV -> IO b -> IO b
pokeZeroCStruct p :: Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p f :: IO b
f = ContT b IO b -> IO b
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT b IO b -> IO b) -> ContT b IO b -> IO b
forall a b. (a -> b) -> a -> b
$ do
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_GRAPHICS_PIPELINE_SHADER_GROUPS_CREATE_INFO_NV)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
Ptr GraphicsShaderGroupCreateInfoNV
pPGroups' <- ((Ptr GraphicsShaderGroupCreateInfoNV -> IO b) -> IO b)
-> ContT b IO (Ptr GraphicsShaderGroupCreateInfoNV)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr GraphicsShaderGroupCreateInfoNV -> IO b) -> IO b)
-> ContT b IO (Ptr GraphicsShaderGroupCreateInfoNV))
-> ((Ptr GraphicsShaderGroupCreateInfoNV -> IO b) -> IO b)
-> ContT b IO (Ptr GraphicsShaderGroupCreateInfoNV)
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr GraphicsShaderGroupCreateInfoNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @GraphicsShaderGroupCreateInfoNV ((Vector Any -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector Any
forall a. Monoid a => a
mempty)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 48) 8
(Int -> GraphicsShaderGroupCreateInfoNV -> ContT b IO ())
-> Vector GraphicsShaderGroupCreateInfoNV -> ContT b IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: GraphicsShaderGroupCreateInfoNV
e -> ((() -> IO b) -> IO b) -> ContT b IO ()
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((() -> IO b) -> IO b) -> ContT b IO ())
-> ((() -> IO b) -> IO b) -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr GraphicsShaderGroupCreateInfoNV
-> GraphicsShaderGroupCreateInfoNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct (Ptr GraphicsShaderGroupCreateInfoNV
pPGroups' Ptr GraphicsShaderGroupCreateInfoNV
-> Int -> Ptr GraphicsShaderGroupCreateInfoNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (48 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr GraphicsShaderGroupCreateInfoNV) (GraphicsShaderGroupCreateInfoNV
e) (IO b -> IO b) -> ((() -> IO b) -> IO b) -> (() -> IO b) -> IO b
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ((() -> IO b) -> () -> IO b
forall a b. (a -> b) -> a -> b
$ ())) (Vector GraphicsShaderGroupCreateInfoNV
forall a. Monoid a => a
mempty)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr GraphicsShaderGroupCreateInfoNV)
-> Ptr GraphicsShaderGroupCreateInfoNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> Int -> Ptr (Ptr GraphicsShaderGroupCreateInfoNV)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr (Ptr GraphicsShaderGroupCreateInfoNV))) (Ptr GraphicsShaderGroupCreateInfoNV
pPGroups')
Ptr Pipeline
pPPipelines' <- ((Ptr Pipeline -> IO b) -> IO b) -> ContT b IO (Ptr Pipeline)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr Pipeline -> IO b) -> IO b) -> ContT b IO (Ptr Pipeline))
-> ((Ptr Pipeline -> IO b) -> IO b) -> ContT b IO (Ptr Pipeline)
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr Pipeline -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @Pipeline ((Vector Any -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector Any
forall a. Monoid a => a
mempty)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 8) 8
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ (Int -> Pipeline -> IO ()) -> Vector Pipeline -> IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: Pipeline
e -> Ptr Pipeline -> Pipeline -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr Pipeline
pPPipelines' Ptr Pipeline -> Int -> Ptr Pipeline
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (8 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr Pipeline) (Pipeline
e)) (Vector Pipeline
forall a. Monoid a => a
mempty)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr Pipeline) -> Ptr Pipeline -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> Int -> Ptr (Ptr Pipeline)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr (Ptr Pipeline))) (Ptr Pipeline
pPPipelines')
IO b -> ContT b IO b
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO b -> ContT b IO b) -> IO b -> ContT b IO b
forall a b. (a -> b) -> a -> b
$ IO b
f
instance FromCStruct GraphicsPipelineShaderGroupsCreateInfoNV where
peekCStruct :: Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> IO GraphicsPipelineShaderGroupsCreateInfoNV
peekCStruct p :: Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p = do
"groupIndex" ::: Word32
groupCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr Word32))
Ptr GraphicsShaderGroupCreateInfoNV
pGroups <- Ptr (Ptr GraphicsShaderGroupCreateInfoNV)
-> IO (Ptr GraphicsShaderGroupCreateInfoNV)
forall a. Storable a => Ptr a -> IO a
peek @(Ptr GraphicsShaderGroupCreateInfoNV) ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> Int -> Ptr (Ptr GraphicsShaderGroupCreateInfoNV)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr (Ptr GraphicsShaderGroupCreateInfoNV)))
Vector GraphicsShaderGroupCreateInfoNV
pGroups' <- Int
-> (Int -> IO GraphicsShaderGroupCreateInfoNV)
-> IO (Vector GraphicsShaderGroupCreateInfoNV)
forall (m :: * -> *) a.
Monad m =>
Int -> (Int -> m a) -> m (Vector a)
generateM (("groupIndex" ::: Word32) -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral "groupIndex" ::: Word32
groupCount) (\i :: Int
i -> Ptr GraphicsShaderGroupCreateInfoNV
-> IO GraphicsShaderGroupCreateInfoNV
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct @GraphicsShaderGroupCreateInfoNV ((Ptr GraphicsShaderGroupCreateInfoNV
pGroups Ptr GraphicsShaderGroupCreateInfoNV
-> Int -> Ptr GraphicsShaderGroupCreateInfoNV
forall a. Ptr a -> Int -> Ptr a
`advancePtrBytes` (48 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr GraphicsShaderGroupCreateInfoNV)))
"groupIndex" ::: Word32
pipelineCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Word32))
Ptr Pipeline
pPipelines <- Ptr (Ptr Pipeline) -> IO (Ptr Pipeline)
forall a. Storable a => Ptr a -> IO a
peek @(Ptr Pipeline) ((Ptr GraphicsPipelineShaderGroupsCreateInfoNV
p Ptr GraphicsPipelineShaderGroupsCreateInfoNV
-> Int -> Ptr (Ptr Pipeline)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr (Ptr Pipeline)))
Vector Pipeline
pPipelines' <- Int -> (Int -> IO Pipeline) -> IO (Vector Pipeline)
forall (m :: * -> *) a.
Monad m =>
Int -> (Int -> m a) -> m (Vector a)
generateM (("groupIndex" ::: Word32) -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral "groupIndex" ::: Word32
pipelineCount) (\i :: Int
i -> Ptr Pipeline -> IO Pipeline
forall a. Storable a => Ptr a -> IO a
peek @Pipeline ((Ptr Pipeline
pPipelines Ptr Pipeline -> Int -> Ptr Pipeline
forall a. Ptr a -> Int -> Ptr a
`advancePtrBytes` (8 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr Pipeline)))
GraphicsPipelineShaderGroupsCreateInfoNV
-> IO GraphicsPipelineShaderGroupsCreateInfoNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (GraphicsPipelineShaderGroupsCreateInfoNV
-> IO GraphicsPipelineShaderGroupsCreateInfoNV)
-> GraphicsPipelineShaderGroupsCreateInfoNV
-> IO GraphicsPipelineShaderGroupsCreateInfoNV
forall a b. (a -> b) -> a -> b
$ Vector GraphicsShaderGroupCreateInfoNV
-> Vector Pipeline -> GraphicsPipelineShaderGroupsCreateInfoNV
GraphicsPipelineShaderGroupsCreateInfoNV
Vector GraphicsShaderGroupCreateInfoNV
pGroups' Vector Pipeline
pPipelines'
instance Zero GraphicsPipelineShaderGroupsCreateInfoNV where
zero :: GraphicsPipelineShaderGroupsCreateInfoNV
zero = Vector GraphicsShaderGroupCreateInfoNV
-> Vector Pipeline -> GraphicsPipelineShaderGroupsCreateInfoNV
GraphicsPipelineShaderGroupsCreateInfoNV
Vector GraphicsShaderGroupCreateInfoNV
forall a. Monoid a => a
mempty
Vector Pipeline
forall a. Monoid a => a
mempty
data BindShaderGroupIndirectCommandNV = BindShaderGroupIndirectCommandNV
{
BindShaderGroupIndirectCommandNV -> "groupIndex" ::: Word32
groupIndex :: Word32 }
deriving (Typeable)
deriving instance Show BindShaderGroupIndirectCommandNV
instance ToCStruct BindShaderGroupIndirectCommandNV where
withCStruct :: BindShaderGroupIndirectCommandNV
-> (Ptr BindShaderGroupIndirectCommandNV -> IO b) -> IO b
withCStruct x :: BindShaderGroupIndirectCommandNV
x f :: Ptr BindShaderGroupIndirectCommandNV -> IO b
f = Int
-> Int -> (Ptr BindShaderGroupIndirectCommandNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 4 4 ((Ptr BindShaderGroupIndirectCommandNV -> IO b) -> IO b)
-> (Ptr BindShaderGroupIndirectCommandNV -> IO b) -> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr BindShaderGroupIndirectCommandNV
p -> Ptr BindShaderGroupIndirectCommandNV
-> BindShaderGroupIndirectCommandNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr BindShaderGroupIndirectCommandNV
p BindShaderGroupIndirectCommandNV
x (Ptr BindShaderGroupIndirectCommandNV -> IO b
f Ptr BindShaderGroupIndirectCommandNV
p)
pokeCStruct :: Ptr BindShaderGroupIndirectCommandNV
-> BindShaderGroupIndirectCommandNV -> IO b -> IO b
pokeCStruct p :: Ptr BindShaderGroupIndirectCommandNV
p BindShaderGroupIndirectCommandNV{..} f :: IO b
f = do
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindShaderGroupIndirectCommandNV
p Ptr BindShaderGroupIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr Word32)) ("groupIndex" ::: Word32
groupIndex)
IO b
f
cStructSize :: Int
cStructSize = 4
cStructAlignment :: Int
cStructAlignment = 4
pokeZeroCStruct :: Ptr BindShaderGroupIndirectCommandNV -> IO b -> IO b
pokeZeroCStruct p :: Ptr BindShaderGroupIndirectCommandNV
p f :: IO b
f = do
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindShaderGroupIndirectCommandNV
p Ptr BindShaderGroupIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
IO b
f
instance FromCStruct BindShaderGroupIndirectCommandNV where
peekCStruct :: Ptr BindShaderGroupIndirectCommandNV
-> IO BindShaderGroupIndirectCommandNV
peekCStruct p :: Ptr BindShaderGroupIndirectCommandNV
p = do
"groupIndex" ::: Word32
groupIndex <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr BindShaderGroupIndirectCommandNV
p Ptr BindShaderGroupIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr Word32))
BindShaderGroupIndirectCommandNV
-> IO BindShaderGroupIndirectCommandNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (BindShaderGroupIndirectCommandNV
-> IO BindShaderGroupIndirectCommandNV)
-> BindShaderGroupIndirectCommandNV
-> IO BindShaderGroupIndirectCommandNV
forall a b. (a -> b) -> a -> b
$ ("groupIndex" ::: Word32) -> BindShaderGroupIndirectCommandNV
BindShaderGroupIndirectCommandNV
"groupIndex" ::: Word32
groupIndex
instance Storable BindShaderGroupIndirectCommandNV where
sizeOf :: BindShaderGroupIndirectCommandNV -> Int
sizeOf ~BindShaderGroupIndirectCommandNV
_ = 4
alignment :: BindShaderGroupIndirectCommandNV -> Int
alignment ~BindShaderGroupIndirectCommandNV
_ = 4
peek :: Ptr BindShaderGroupIndirectCommandNV
-> IO BindShaderGroupIndirectCommandNV
peek = Ptr BindShaderGroupIndirectCommandNV
-> IO BindShaderGroupIndirectCommandNV
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct
poke :: Ptr BindShaderGroupIndirectCommandNV
-> BindShaderGroupIndirectCommandNV -> IO ()
poke ptr :: Ptr BindShaderGroupIndirectCommandNV
ptr poked :: BindShaderGroupIndirectCommandNV
poked = Ptr BindShaderGroupIndirectCommandNV
-> BindShaderGroupIndirectCommandNV -> IO () -> IO ()
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr BindShaderGroupIndirectCommandNV
ptr BindShaderGroupIndirectCommandNV
poked (() -> IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure ())
instance Zero BindShaderGroupIndirectCommandNV where
zero :: BindShaderGroupIndirectCommandNV
zero = ("groupIndex" ::: Word32) -> BindShaderGroupIndirectCommandNV
BindShaderGroupIndirectCommandNV
"groupIndex" ::: Word32
forall a. Zero a => a
zero
data BindIndexBufferIndirectCommandNV = BindIndexBufferIndirectCommandNV
{
BindIndexBufferIndirectCommandNV -> DeviceAddress
bufferAddress :: DeviceAddress
,
BindIndexBufferIndirectCommandNV -> "groupIndex" ::: Word32
size :: Word32
,
BindIndexBufferIndirectCommandNV -> IndexType
indexType :: IndexType
}
deriving (Typeable)
deriving instance Show BindIndexBufferIndirectCommandNV
instance ToCStruct BindIndexBufferIndirectCommandNV where
withCStruct :: BindIndexBufferIndirectCommandNV
-> (Ptr BindIndexBufferIndirectCommandNV -> IO b) -> IO b
withCStruct x :: BindIndexBufferIndirectCommandNV
x f :: Ptr BindIndexBufferIndirectCommandNV -> IO b
f = Int
-> Int -> (Ptr BindIndexBufferIndirectCommandNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 16 8 ((Ptr BindIndexBufferIndirectCommandNV -> IO b) -> IO b)
-> (Ptr BindIndexBufferIndirectCommandNV -> IO b) -> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr BindIndexBufferIndirectCommandNV
p -> Ptr BindIndexBufferIndirectCommandNV
-> BindIndexBufferIndirectCommandNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr BindIndexBufferIndirectCommandNV
p BindIndexBufferIndirectCommandNV
x (Ptr BindIndexBufferIndirectCommandNV -> IO b
f Ptr BindIndexBufferIndirectCommandNV
p)
pokeCStruct :: Ptr BindIndexBufferIndirectCommandNV
-> BindIndexBufferIndirectCommandNV -> IO b -> IO b
pokeCStruct p :: Ptr BindIndexBufferIndirectCommandNV
p BindIndexBufferIndirectCommandNV{..} f :: IO b
f = do
Ptr DeviceAddress -> DeviceAddress -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindIndexBufferIndirectCommandNV
p Ptr BindIndexBufferIndirectCommandNV -> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr DeviceAddress)) (DeviceAddress
bufferAddress)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindIndexBufferIndirectCommandNV
p Ptr BindIndexBufferIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr Word32)) ("groupIndex" ::: Word32
size)
Ptr IndexType -> IndexType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindIndexBufferIndirectCommandNV
p Ptr BindIndexBufferIndirectCommandNV -> Int -> Ptr IndexType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 12 :: Ptr IndexType)) (IndexType
indexType)
IO b
f
cStructSize :: Int
cStructSize = 16
cStructAlignment :: Int
cStructAlignment = 8
pokeZeroCStruct :: Ptr BindIndexBufferIndirectCommandNV -> IO b -> IO b
pokeZeroCStruct p :: Ptr BindIndexBufferIndirectCommandNV
p f :: IO b
f = do
Ptr DeviceAddress -> DeviceAddress -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindIndexBufferIndirectCommandNV
p Ptr BindIndexBufferIndirectCommandNV -> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr DeviceAddress)) (DeviceAddress
forall a. Zero a => a
zero)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindIndexBufferIndirectCommandNV
p Ptr BindIndexBufferIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
Ptr IndexType -> IndexType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindIndexBufferIndirectCommandNV
p Ptr BindIndexBufferIndirectCommandNV -> Int -> Ptr IndexType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 12 :: Ptr IndexType)) (IndexType
forall a. Zero a => a
zero)
IO b
f
instance FromCStruct BindIndexBufferIndirectCommandNV where
peekCStruct :: Ptr BindIndexBufferIndirectCommandNV
-> IO BindIndexBufferIndirectCommandNV
peekCStruct p :: Ptr BindIndexBufferIndirectCommandNV
p = do
DeviceAddress
bufferAddress <- Ptr DeviceAddress -> IO DeviceAddress
forall a. Storable a => Ptr a -> IO a
peek @DeviceAddress ((Ptr BindIndexBufferIndirectCommandNV
p Ptr BindIndexBufferIndirectCommandNV -> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr DeviceAddress))
"groupIndex" ::: Word32
size <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr BindIndexBufferIndirectCommandNV
p Ptr BindIndexBufferIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr Word32))
IndexType
indexType <- Ptr IndexType -> IO IndexType
forall a. Storable a => Ptr a -> IO a
peek @IndexType ((Ptr BindIndexBufferIndirectCommandNV
p Ptr BindIndexBufferIndirectCommandNV -> Int -> Ptr IndexType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 12 :: Ptr IndexType))
BindIndexBufferIndirectCommandNV
-> IO BindIndexBufferIndirectCommandNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (BindIndexBufferIndirectCommandNV
-> IO BindIndexBufferIndirectCommandNV)
-> BindIndexBufferIndirectCommandNV
-> IO BindIndexBufferIndirectCommandNV
forall a b. (a -> b) -> a -> b
$ DeviceAddress
-> ("groupIndex" ::: Word32)
-> IndexType
-> BindIndexBufferIndirectCommandNV
BindIndexBufferIndirectCommandNV
DeviceAddress
bufferAddress "groupIndex" ::: Word32
size IndexType
indexType
instance Storable BindIndexBufferIndirectCommandNV where
sizeOf :: BindIndexBufferIndirectCommandNV -> Int
sizeOf ~BindIndexBufferIndirectCommandNV
_ = 16
alignment :: BindIndexBufferIndirectCommandNV -> Int
alignment ~BindIndexBufferIndirectCommandNV
_ = 8
peek :: Ptr BindIndexBufferIndirectCommandNV
-> IO BindIndexBufferIndirectCommandNV
peek = Ptr BindIndexBufferIndirectCommandNV
-> IO BindIndexBufferIndirectCommandNV
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct
poke :: Ptr BindIndexBufferIndirectCommandNV
-> BindIndexBufferIndirectCommandNV -> IO ()
poke ptr :: Ptr BindIndexBufferIndirectCommandNV
ptr poked :: BindIndexBufferIndirectCommandNV
poked = Ptr BindIndexBufferIndirectCommandNV
-> BindIndexBufferIndirectCommandNV -> IO () -> IO ()
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr BindIndexBufferIndirectCommandNV
ptr BindIndexBufferIndirectCommandNV
poked (() -> IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure ())
instance Zero BindIndexBufferIndirectCommandNV where
zero :: BindIndexBufferIndirectCommandNV
zero = DeviceAddress
-> ("groupIndex" ::: Word32)
-> IndexType
-> BindIndexBufferIndirectCommandNV
BindIndexBufferIndirectCommandNV
DeviceAddress
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
IndexType
forall a. Zero a => a
zero
data BindVertexBufferIndirectCommandNV = BindVertexBufferIndirectCommandNV
{
BindVertexBufferIndirectCommandNV -> DeviceAddress
bufferAddress :: DeviceAddress
,
BindVertexBufferIndirectCommandNV -> "groupIndex" ::: Word32
size :: Word32
,
BindVertexBufferIndirectCommandNV -> "groupIndex" ::: Word32
stride :: Word32
}
deriving (Typeable)
deriving instance Show BindVertexBufferIndirectCommandNV
instance ToCStruct BindVertexBufferIndirectCommandNV where
withCStruct :: BindVertexBufferIndirectCommandNV
-> (Ptr BindVertexBufferIndirectCommandNV -> IO b) -> IO b
withCStruct x :: BindVertexBufferIndirectCommandNV
x f :: Ptr BindVertexBufferIndirectCommandNV -> IO b
f = Int
-> Int -> (Ptr BindVertexBufferIndirectCommandNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 16 8 ((Ptr BindVertexBufferIndirectCommandNV -> IO b) -> IO b)
-> (Ptr BindVertexBufferIndirectCommandNV -> IO b) -> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr BindVertexBufferIndirectCommandNV
p -> Ptr BindVertexBufferIndirectCommandNV
-> BindVertexBufferIndirectCommandNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr BindVertexBufferIndirectCommandNV
p BindVertexBufferIndirectCommandNV
x (Ptr BindVertexBufferIndirectCommandNV -> IO b
f Ptr BindVertexBufferIndirectCommandNV
p)
pokeCStruct :: Ptr BindVertexBufferIndirectCommandNV
-> BindVertexBufferIndirectCommandNV -> IO b -> IO b
pokeCStruct p :: Ptr BindVertexBufferIndirectCommandNV
p BindVertexBufferIndirectCommandNV{..} f :: IO b
f = do
Ptr DeviceAddress -> DeviceAddress -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindVertexBufferIndirectCommandNV
p Ptr BindVertexBufferIndirectCommandNV -> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr DeviceAddress)) (DeviceAddress
bufferAddress)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindVertexBufferIndirectCommandNV
p Ptr BindVertexBufferIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr Word32)) ("groupIndex" ::: Word32
size)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindVertexBufferIndirectCommandNV
p Ptr BindVertexBufferIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 12 :: Ptr Word32)) ("groupIndex" ::: Word32
stride)
IO b
f
cStructSize :: Int
cStructSize = 16
cStructAlignment :: Int
cStructAlignment = 8
pokeZeroCStruct :: Ptr BindVertexBufferIndirectCommandNV -> IO b -> IO b
pokeZeroCStruct p :: Ptr BindVertexBufferIndirectCommandNV
p f :: IO b
f = do
Ptr DeviceAddress -> DeviceAddress -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindVertexBufferIndirectCommandNV
p Ptr BindVertexBufferIndirectCommandNV -> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr DeviceAddress)) (DeviceAddress
forall a. Zero a => a
zero)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindVertexBufferIndirectCommandNV
p Ptr BindVertexBufferIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr BindVertexBufferIndirectCommandNV
p Ptr BindVertexBufferIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 12 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
IO b
f
instance FromCStruct BindVertexBufferIndirectCommandNV where
peekCStruct :: Ptr BindVertexBufferIndirectCommandNV
-> IO BindVertexBufferIndirectCommandNV
peekCStruct p :: Ptr BindVertexBufferIndirectCommandNV
p = do
DeviceAddress
bufferAddress <- Ptr DeviceAddress -> IO DeviceAddress
forall a. Storable a => Ptr a -> IO a
peek @DeviceAddress ((Ptr BindVertexBufferIndirectCommandNV
p Ptr BindVertexBufferIndirectCommandNV -> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr DeviceAddress))
"groupIndex" ::: Word32
size <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr BindVertexBufferIndirectCommandNV
p Ptr BindVertexBufferIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr Word32))
"groupIndex" ::: Word32
stride <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr BindVertexBufferIndirectCommandNV
p Ptr BindVertexBufferIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 12 :: Ptr Word32))
BindVertexBufferIndirectCommandNV
-> IO BindVertexBufferIndirectCommandNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (BindVertexBufferIndirectCommandNV
-> IO BindVertexBufferIndirectCommandNV)
-> BindVertexBufferIndirectCommandNV
-> IO BindVertexBufferIndirectCommandNV
forall a b. (a -> b) -> a -> b
$ DeviceAddress
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> BindVertexBufferIndirectCommandNV
BindVertexBufferIndirectCommandNV
DeviceAddress
bufferAddress "groupIndex" ::: Word32
size "groupIndex" ::: Word32
stride
instance Storable BindVertexBufferIndirectCommandNV where
sizeOf :: BindVertexBufferIndirectCommandNV -> Int
sizeOf ~BindVertexBufferIndirectCommandNV
_ = 16
alignment :: BindVertexBufferIndirectCommandNV -> Int
alignment ~BindVertexBufferIndirectCommandNV
_ = 8
peek :: Ptr BindVertexBufferIndirectCommandNV
-> IO BindVertexBufferIndirectCommandNV
peek = Ptr BindVertexBufferIndirectCommandNV
-> IO BindVertexBufferIndirectCommandNV
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct
poke :: Ptr BindVertexBufferIndirectCommandNV
-> BindVertexBufferIndirectCommandNV -> IO ()
poke ptr :: Ptr BindVertexBufferIndirectCommandNV
ptr poked :: BindVertexBufferIndirectCommandNV
poked = Ptr BindVertexBufferIndirectCommandNV
-> BindVertexBufferIndirectCommandNV -> IO () -> IO ()
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr BindVertexBufferIndirectCommandNV
ptr BindVertexBufferIndirectCommandNV
poked (() -> IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure ())
instance Zero BindVertexBufferIndirectCommandNV where
zero :: BindVertexBufferIndirectCommandNV
zero = DeviceAddress
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> BindVertexBufferIndirectCommandNV
BindVertexBufferIndirectCommandNV
DeviceAddress
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
data SetStateFlagsIndirectCommandNV = SetStateFlagsIndirectCommandNV
{
SetStateFlagsIndirectCommandNV -> "groupIndex" ::: Word32
data' :: Word32 }
deriving (Typeable)
deriving instance Show SetStateFlagsIndirectCommandNV
instance ToCStruct SetStateFlagsIndirectCommandNV where
withCStruct :: SetStateFlagsIndirectCommandNV
-> (Ptr SetStateFlagsIndirectCommandNV -> IO b) -> IO b
withCStruct x :: SetStateFlagsIndirectCommandNV
x f :: Ptr SetStateFlagsIndirectCommandNV -> IO b
f = Int -> Int -> (Ptr SetStateFlagsIndirectCommandNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 4 4 ((Ptr SetStateFlagsIndirectCommandNV -> IO b) -> IO b)
-> (Ptr SetStateFlagsIndirectCommandNV -> IO b) -> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr SetStateFlagsIndirectCommandNV
p -> Ptr SetStateFlagsIndirectCommandNV
-> SetStateFlagsIndirectCommandNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr SetStateFlagsIndirectCommandNV
p SetStateFlagsIndirectCommandNV
x (Ptr SetStateFlagsIndirectCommandNV -> IO b
f Ptr SetStateFlagsIndirectCommandNV
p)
pokeCStruct :: Ptr SetStateFlagsIndirectCommandNV
-> SetStateFlagsIndirectCommandNV -> IO b -> IO b
pokeCStruct p :: Ptr SetStateFlagsIndirectCommandNV
p SetStateFlagsIndirectCommandNV{..} f :: IO b
f = do
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr SetStateFlagsIndirectCommandNV
p Ptr SetStateFlagsIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr Word32)) ("groupIndex" ::: Word32
data')
IO b
f
cStructSize :: Int
cStructSize = 4
cStructAlignment :: Int
cStructAlignment = 4
pokeZeroCStruct :: Ptr SetStateFlagsIndirectCommandNV -> IO b -> IO b
pokeZeroCStruct p :: Ptr SetStateFlagsIndirectCommandNV
p f :: IO b
f = do
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr SetStateFlagsIndirectCommandNV
p Ptr SetStateFlagsIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
IO b
f
instance FromCStruct SetStateFlagsIndirectCommandNV where
peekCStruct :: Ptr SetStateFlagsIndirectCommandNV
-> IO SetStateFlagsIndirectCommandNV
peekCStruct p :: Ptr SetStateFlagsIndirectCommandNV
p = do
"groupIndex" ::: Word32
data' <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr SetStateFlagsIndirectCommandNV
p Ptr SetStateFlagsIndirectCommandNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr Word32))
SetStateFlagsIndirectCommandNV -> IO SetStateFlagsIndirectCommandNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (SetStateFlagsIndirectCommandNV
-> IO SetStateFlagsIndirectCommandNV)
-> SetStateFlagsIndirectCommandNV
-> IO SetStateFlagsIndirectCommandNV
forall a b. (a -> b) -> a -> b
$ ("groupIndex" ::: Word32) -> SetStateFlagsIndirectCommandNV
SetStateFlagsIndirectCommandNV
"groupIndex" ::: Word32
data'
instance Storable SetStateFlagsIndirectCommandNV where
sizeOf :: SetStateFlagsIndirectCommandNV -> Int
sizeOf ~SetStateFlagsIndirectCommandNV
_ = 4
alignment :: SetStateFlagsIndirectCommandNV -> Int
alignment ~SetStateFlagsIndirectCommandNV
_ = 4
peek :: Ptr SetStateFlagsIndirectCommandNV
-> IO SetStateFlagsIndirectCommandNV
peek = Ptr SetStateFlagsIndirectCommandNV
-> IO SetStateFlagsIndirectCommandNV
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct
poke :: Ptr SetStateFlagsIndirectCommandNV
-> SetStateFlagsIndirectCommandNV -> IO ()
poke ptr :: Ptr SetStateFlagsIndirectCommandNV
ptr poked :: SetStateFlagsIndirectCommandNV
poked = Ptr SetStateFlagsIndirectCommandNV
-> SetStateFlagsIndirectCommandNV -> IO () -> IO ()
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr SetStateFlagsIndirectCommandNV
ptr SetStateFlagsIndirectCommandNV
poked (() -> IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure ())
instance Zero SetStateFlagsIndirectCommandNV where
zero :: SetStateFlagsIndirectCommandNV
zero = ("groupIndex" ::: Word32) -> SetStateFlagsIndirectCommandNV
SetStateFlagsIndirectCommandNV
"groupIndex" ::: Word32
forall a. Zero a => a
zero
data IndirectCommandsStreamNV = IndirectCommandsStreamNV
{
IndirectCommandsStreamNV -> Buffer
buffer :: Buffer
,
IndirectCommandsStreamNV -> DeviceAddress
offset :: DeviceSize
}
deriving (Typeable)
deriving instance Show IndirectCommandsStreamNV
instance ToCStruct IndirectCommandsStreamNV where
withCStruct :: IndirectCommandsStreamNV
-> (Ptr IndirectCommandsStreamNV -> IO b) -> IO b
withCStruct x :: IndirectCommandsStreamNV
x f :: Ptr IndirectCommandsStreamNV -> IO b
f = Int -> Int -> (Ptr IndirectCommandsStreamNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 16 8 ((Ptr IndirectCommandsStreamNV -> IO b) -> IO b)
-> (Ptr IndirectCommandsStreamNV -> IO b) -> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr IndirectCommandsStreamNV
p -> Ptr IndirectCommandsStreamNV
-> IndirectCommandsStreamNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr IndirectCommandsStreamNV
p IndirectCommandsStreamNV
x (Ptr IndirectCommandsStreamNV -> IO b
f Ptr IndirectCommandsStreamNV
p)
pokeCStruct :: Ptr IndirectCommandsStreamNV
-> IndirectCommandsStreamNV -> IO b -> IO b
pokeCStruct p :: Ptr IndirectCommandsStreamNV
p IndirectCommandsStreamNV{..} f :: IO b
f = do
Ptr Buffer -> Buffer -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsStreamNV
p Ptr IndirectCommandsStreamNV -> Int -> Ptr Buffer
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr Buffer)) (Buffer
buffer)
Ptr DeviceAddress -> DeviceAddress -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsStreamNV
p Ptr IndirectCommandsStreamNV -> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr DeviceSize)) (DeviceAddress
offset)
IO b
f
cStructSize :: Int
cStructSize = 16
cStructAlignment :: Int
cStructAlignment = 8
pokeZeroCStruct :: Ptr IndirectCommandsStreamNV -> IO b -> IO b
pokeZeroCStruct p :: Ptr IndirectCommandsStreamNV
p f :: IO b
f = do
Ptr Buffer -> Buffer -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsStreamNV
p Ptr IndirectCommandsStreamNV -> Int -> Ptr Buffer
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr Buffer)) (Buffer
forall a. Zero a => a
zero)
Ptr DeviceAddress -> DeviceAddress -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsStreamNV
p Ptr IndirectCommandsStreamNV -> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr DeviceSize)) (DeviceAddress
forall a. Zero a => a
zero)
IO b
f
instance FromCStruct IndirectCommandsStreamNV where
peekCStruct :: Ptr IndirectCommandsStreamNV -> IO IndirectCommandsStreamNV
peekCStruct p :: Ptr IndirectCommandsStreamNV
p = do
Buffer
buffer <- Ptr Buffer -> IO Buffer
forall a. Storable a => Ptr a -> IO a
peek @Buffer ((Ptr IndirectCommandsStreamNV
p Ptr IndirectCommandsStreamNV -> Int -> Ptr Buffer
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr Buffer))
DeviceAddress
offset <- Ptr DeviceAddress -> IO DeviceAddress
forall a. Storable a => Ptr a -> IO a
peek @DeviceSize ((Ptr IndirectCommandsStreamNV
p Ptr IndirectCommandsStreamNV -> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr DeviceSize))
IndirectCommandsStreamNV -> IO IndirectCommandsStreamNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (IndirectCommandsStreamNV -> IO IndirectCommandsStreamNV)
-> IndirectCommandsStreamNV -> IO IndirectCommandsStreamNV
forall a b. (a -> b) -> a -> b
$ Buffer -> DeviceAddress -> IndirectCommandsStreamNV
IndirectCommandsStreamNV
Buffer
buffer DeviceAddress
offset
instance Storable IndirectCommandsStreamNV where
sizeOf :: IndirectCommandsStreamNV -> Int
sizeOf ~IndirectCommandsStreamNV
_ = 16
alignment :: IndirectCommandsStreamNV -> Int
alignment ~IndirectCommandsStreamNV
_ = 8
peek :: Ptr IndirectCommandsStreamNV -> IO IndirectCommandsStreamNV
peek = Ptr IndirectCommandsStreamNV -> IO IndirectCommandsStreamNV
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct
poke :: Ptr IndirectCommandsStreamNV -> IndirectCommandsStreamNV -> IO ()
poke ptr :: Ptr IndirectCommandsStreamNV
ptr poked :: IndirectCommandsStreamNV
poked = Ptr IndirectCommandsStreamNV
-> IndirectCommandsStreamNV -> IO () -> IO ()
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr IndirectCommandsStreamNV
ptr IndirectCommandsStreamNV
poked (() -> IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure ())
instance Zero IndirectCommandsStreamNV where
zero :: IndirectCommandsStreamNV
zero = Buffer -> DeviceAddress -> IndirectCommandsStreamNV
IndirectCommandsStreamNV
Buffer
forall a. Zero a => a
zero
DeviceAddress
forall a. Zero a => a
zero
data IndirectCommandsLayoutTokenNV = IndirectCommandsLayoutTokenNV
{
IndirectCommandsLayoutTokenNV -> IndirectCommandsTokenTypeNV
tokenType :: IndirectCommandsTokenTypeNV
,
IndirectCommandsLayoutTokenNV -> "groupIndex" ::: Word32
stream :: Word32
,
IndirectCommandsLayoutTokenNV -> "groupIndex" ::: Word32
offset :: Word32
,
IndirectCommandsLayoutTokenNV -> "groupIndex" ::: Word32
vertexBindingUnit :: Word32
,
IndirectCommandsLayoutTokenNV -> "isPreprocessed" ::: Bool
vertexDynamicStride :: Bool
,
IndirectCommandsLayoutTokenNV -> PipelineLayout
pushconstantPipelineLayout :: PipelineLayout
,
IndirectCommandsLayoutTokenNV -> ShaderStageFlags
pushconstantShaderStageFlags :: ShaderStageFlags
,
IndirectCommandsLayoutTokenNV -> "groupIndex" ::: Word32
pushconstantOffset :: Word32
,
IndirectCommandsLayoutTokenNV -> "groupIndex" ::: Word32
pushconstantSize :: Word32
,
IndirectCommandsLayoutTokenNV -> IndirectStateFlagsNV
indirectStateFlags :: IndirectStateFlagsNV
,
IndirectCommandsLayoutTokenNV -> Vector IndexType
indexTypes :: Vector IndexType
,
IndirectCommandsLayoutTokenNV -> Vector ("groupIndex" ::: Word32)
indexTypeValues :: Vector Word32
}
deriving (Typeable)
deriving instance Show IndirectCommandsLayoutTokenNV
instance ToCStruct IndirectCommandsLayoutTokenNV where
withCStruct :: IndirectCommandsLayoutTokenNV
-> (Ptr IndirectCommandsLayoutTokenNV -> IO b) -> IO b
withCStruct x :: IndirectCommandsLayoutTokenNV
x f :: Ptr IndirectCommandsLayoutTokenNV -> IO b
f = Int -> Int -> (Ptr IndirectCommandsLayoutTokenNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 88 8 ((Ptr IndirectCommandsLayoutTokenNV -> IO b) -> IO b)
-> (Ptr IndirectCommandsLayoutTokenNV -> IO b) -> IO b
forall a b. (a -> b) -> a -> b
$ \p :: Ptr IndirectCommandsLayoutTokenNV
p -> Ptr IndirectCommandsLayoutTokenNV
-> IndirectCommandsLayoutTokenNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct Ptr IndirectCommandsLayoutTokenNV
p IndirectCommandsLayoutTokenNV
x (Ptr IndirectCommandsLayoutTokenNV -> IO b
f Ptr IndirectCommandsLayoutTokenNV
p)
pokeCStruct :: Ptr IndirectCommandsLayoutTokenNV
-> IndirectCommandsLayoutTokenNV -> IO b -> IO b
pokeCStruct p :: Ptr IndirectCommandsLayoutTokenNV
p IndirectCommandsLayoutTokenNV{..} f :: IO b
f = ContT b IO b -> IO b
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT b IO b -> IO b) -> ContT b IO b -> IO b
forall a b. (a -> b) -> a -> b
$ do
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV -> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_INDIRECT_COMMANDS_LAYOUT_TOKEN_NV)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr IndirectCommandsTokenTypeNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr IndirectCommandsTokenTypeNV)) (IndirectCommandsTokenTypeNV
tokenType)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Word32)) ("groupIndex" ::: Word32
stream)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Word32)) ("groupIndex" ::: Word32
offset)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 28 :: Ptr Word32)) ("groupIndex" ::: Word32
vertexBindingUnit)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("isPreprocessed" ::: Bool32)
-> ("isPreprocessed" ::: Bool32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("isPreprocessed" ::: Bool32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Bool32)) (("isPreprocessed" ::: Bool) -> "isPreprocessed" ::: Bool32
boolToBool32 ("isPreprocessed" ::: Bool
vertexDynamicStride))
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr PipelineLayout -> PipelineLayout -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV -> Int -> Ptr PipelineLayout
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr PipelineLayout)) (PipelineLayout
pushconstantPipelineLayout)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ShaderStageFlags -> ShaderStageFlags -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV -> Int -> Ptr ShaderStageFlags
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr ShaderStageFlags)) (ShaderStageFlags
pushconstantShaderStageFlags)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 52 :: Ptr Word32)) ("groupIndex" ::: Word32
pushconstantOffset)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 56 :: Ptr Word32)) ("groupIndex" ::: Word32
pushconstantSize)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr IndirectStateFlagsNV -> IndirectStateFlagsNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr IndirectStateFlagsNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 60 :: Ptr IndirectStateFlagsNV)) (IndirectStateFlagsNV
indirectStateFlags)
let pIndexTypesLength :: Int
pIndexTypesLength = Vector IndexType -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector IndexType -> Int) -> Vector IndexType -> Int
forall a b. (a -> b) -> a -> b
$ (Vector IndexType
indexTypes)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ ("isPreprocessed" ::: Bool) -> IO () -> IO ()
forall (f :: * -> *).
Applicative f =>
("isPreprocessed" ::: Bool) -> f () -> f ()
unless ((Vector ("groupIndex" ::: Word32) -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector ("groupIndex" ::: Word32) -> Int)
-> Vector ("groupIndex" ::: Word32) -> Int
forall a b. (a -> b) -> a -> b
$ (Vector ("groupIndex" ::: Word32)
indexTypeValues)) Int -> Int -> "isPreprocessed" ::: Bool
forall a. Eq a => a -> a -> "isPreprocessed" ::: Bool
== Int
pIndexTypesLength) (IO () -> IO ()) -> IO () -> IO ()
forall a b. (a -> b) -> a -> b
$
IOException -> IO ()
forall e a. Exception e => e -> IO a
throwIO (IOException -> IO ()) -> IOException -> IO ()
forall a b. (a -> b) -> a -> b
$ Maybe Handle
-> IOErrorType
-> String
-> String
-> Maybe CInt
-> Maybe String
-> IOException
IOError Maybe Handle
forall a. Maybe a
Nothing IOErrorType
InvalidArgument "" "pIndexTypeValues and pIndexTypes must have the same length" Maybe CInt
forall a. Maybe a
Nothing Maybe String
forall a. Maybe a
Nothing
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 64 :: Ptr Word32)) ((Int -> "groupIndex" ::: Word32
forall a b. (Integral a, Num b) => a -> b
fromIntegral Int
pIndexTypesLength :: Word32))
Ptr IndexType
pPIndexTypes' <- ((Ptr IndexType -> IO b) -> IO b) -> ContT b IO (Ptr IndexType)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr IndexType -> IO b) -> IO b) -> ContT b IO (Ptr IndexType))
-> ((Ptr IndexType -> IO b) -> IO b) -> ContT b IO (Ptr IndexType)
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr IndexType -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @IndexType ((Vector IndexType -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector IndexType
indexTypes)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 4) 4
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ (Int -> IndexType -> IO ()) -> Vector IndexType -> IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: IndexType
e -> Ptr IndexType -> IndexType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr IndexType
pPIndexTypes' Ptr IndexType -> Int -> Ptr IndexType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (4 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr IndexType) (IndexType
e)) (Vector IndexType
indexTypes)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr IndexType) -> Ptr IndexType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV -> Int -> Ptr (Ptr IndexType)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 72 :: Ptr (Ptr IndexType))) (Ptr IndexType
pPIndexTypes')
Ptr ("groupIndex" ::: Word32)
pPIndexTypeValues' <- ((Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b)
-> ContT b IO (Ptr ("groupIndex" ::: Word32))
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b)
-> ContT b IO (Ptr ("groupIndex" ::: Word32)))
-> ((Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b)
-> ContT b IO (Ptr ("groupIndex" ::: Word32))
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @Word32 ((Vector ("groupIndex" ::: Word32) -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector ("groupIndex" ::: Word32)
indexTypeValues)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 4) 4
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ (Int -> ("groupIndex" ::: Word32) -> IO ())
-> Vector ("groupIndex" ::: Word32) -> IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: "groupIndex" ::: Word32
e -> Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr ("groupIndex" ::: Word32)
pPIndexTypeValues' Ptr ("groupIndex" ::: Word32)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (4 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr Word32) ("groupIndex" ::: Word32
e)) (Vector ("groupIndex" ::: Word32)
indexTypeValues)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ("groupIndex" ::: Word32))
-> Ptr ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr (Ptr ("groupIndex" ::: Word32))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 80 :: Ptr (Ptr Word32))) (Ptr ("groupIndex" ::: Word32)
pPIndexTypeValues')
IO b -> ContT b IO b
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO b -> ContT b IO b) -> IO b -> ContT b IO b
forall a b. (a -> b) -> a -> b
$ IO b
f
cStructSize :: Int
cStructSize = 88
cStructAlignment :: Int
cStructAlignment = 8
pokeZeroCStruct :: Ptr IndirectCommandsLayoutTokenNV -> IO b -> IO b
pokeZeroCStruct p :: Ptr IndirectCommandsLayoutTokenNV
p f :: IO b
f = ContT b IO b -> IO b
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT b IO b -> IO b) -> ContT b IO b -> IO b
forall a b. (a -> b) -> a -> b
$ do
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV -> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_INDIRECT_COMMANDS_LAYOUT_TOKEN_NV)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV -> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr IndirectCommandsTokenTypeNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr IndirectCommandsTokenTypeNV)) (IndirectCommandsTokenTypeNV
forall a. Zero a => a
zero)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 28 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("isPreprocessed" ::: Bool32)
-> ("isPreprocessed" ::: Bool32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("isPreprocessed" ::: Bool32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Bool32)) (("isPreprocessed" ::: Bool) -> "isPreprocessed" ::: Bool32
boolToBool32 ("isPreprocessed" ::: Bool
forall a. Zero a => a
zero))
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 52 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 56 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
Ptr IndexType
pPIndexTypes' <- ((Ptr IndexType -> IO b) -> IO b) -> ContT b IO (Ptr IndexType)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr IndexType -> IO b) -> IO b) -> ContT b IO (Ptr IndexType))
-> ((Ptr IndexType -> IO b) -> IO b) -> ContT b IO (Ptr IndexType)
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr IndexType -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @IndexType ((Vector Any -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector Any
forall a. Monoid a => a
mempty)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 4) 4
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ (Int -> IndexType -> IO ()) -> Vector IndexType -> IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: IndexType
e -> Ptr IndexType -> IndexType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr IndexType
pPIndexTypes' Ptr IndexType -> Int -> Ptr IndexType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (4 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr IndexType) (IndexType
e)) (Vector IndexType
forall a. Monoid a => a
mempty)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr IndexType) -> Ptr IndexType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV -> Int -> Ptr (Ptr IndexType)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 72 :: Ptr (Ptr IndexType))) (Ptr IndexType
pPIndexTypes')
Ptr ("groupIndex" ::: Word32)
pPIndexTypeValues' <- ((Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b)
-> ContT b IO (Ptr ("groupIndex" ::: Word32))
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b)
-> ContT b IO (Ptr ("groupIndex" ::: Word32)))
-> ((Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b)
-> ContT b IO (Ptr ("groupIndex" ::: Word32))
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @Word32 ((Vector Any -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector Any
forall a. Monoid a => a
mempty)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 4) 4
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ (Int -> ("groupIndex" ::: Word32) -> IO ())
-> Vector ("groupIndex" ::: Word32) -> IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: "groupIndex" ::: Word32
e -> Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr ("groupIndex" ::: Word32)
pPIndexTypeValues' Ptr ("groupIndex" ::: Word32)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (4 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr Word32) ("groupIndex" ::: Word32
e)) (Vector ("groupIndex" ::: Word32)
forall a. Monoid a => a
mempty)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ("groupIndex" ::: Word32))
-> Ptr ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr (Ptr ("groupIndex" ::: Word32))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 80 :: Ptr (Ptr Word32))) (Ptr ("groupIndex" ::: Word32)
pPIndexTypeValues')
IO b -> ContT b IO b
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO b -> ContT b IO b) -> IO b -> ContT b IO b
forall a b. (a -> b) -> a -> b
$ IO b
f
instance FromCStruct IndirectCommandsLayoutTokenNV where
peekCStruct :: Ptr IndirectCommandsLayoutTokenNV
-> IO IndirectCommandsLayoutTokenNV
peekCStruct p :: Ptr IndirectCommandsLayoutTokenNV
p = do
IndirectCommandsTokenTypeNV
tokenType <- Ptr IndirectCommandsTokenTypeNV -> IO IndirectCommandsTokenTypeNV
forall a. Storable a => Ptr a -> IO a
peek @IndirectCommandsTokenTypeNV ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr IndirectCommandsTokenTypeNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr IndirectCommandsTokenTypeNV))
"groupIndex" ::: Word32
stream <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr Word32))
"groupIndex" ::: Word32
offset <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Word32))
"groupIndex" ::: Word32
vertexBindingUnit <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 28 :: Ptr Word32))
"isPreprocessed" ::: Bool32
vertexDynamicStride <- Ptr ("isPreprocessed" ::: Bool32)
-> IO ("isPreprocessed" ::: Bool32)
forall a. Storable a => Ptr a -> IO a
peek @Bool32 ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("isPreprocessed" ::: Bool32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr Bool32))
PipelineLayout
pushconstantPipelineLayout <- Ptr PipelineLayout -> IO PipelineLayout
forall a. Storable a => Ptr a -> IO a
peek @PipelineLayout ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV -> Int -> Ptr PipelineLayout
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr PipelineLayout))
ShaderStageFlags
pushconstantShaderStageFlags <- Ptr ShaderStageFlags -> IO ShaderStageFlags
forall a. Storable a => Ptr a -> IO a
peek @ShaderStageFlags ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV -> Int -> Ptr ShaderStageFlags
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr ShaderStageFlags))
"groupIndex" ::: Word32
pushconstantOffset <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 52 :: Ptr Word32))
"groupIndex" ::: Word32
pushconstantSize <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 56 :: Ptr Word32))
IndirectStateFlagsNV
indirectStateFlags <- Ptr IndirectStateFlagsNV -> IO IndirectStateFlagsNV
forall a. Storable a => Ptr a -> IO a
peek @IndirectStateFlagsNV ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr IndirectStateFlagsNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 60 :: Ptr IndirectStateFlagsNV))
"groupIndex" ::: Word32
indexTypeCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 64 :: Ptr Word32))
Ptr IndexType
pIndexTypes <- Ptr (Ptr IndexType) -> IO (Ptr IndexType)
forall a. Storable a => Ptr a -> IO a
peek @(Ptr IndexType) ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV -> Int -> Ptr (Ptr IndexType)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 72 :: Ptr (Ptr IndexType)))
Vector IndexType
pIndexTypes' <- Int -> (Int -> IO IndexType) -> IO (Vector IndexType)
forall (m :: * -> *) a.
Monad m =>
Int -> (Int -> m a) -> m (Vector a)
generateM (("groupIndex" ::: Word32) -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral "groupIndex" ::: Word32
indexTypeCount) (\i :: Int
i -> Ptr IndexType -> IO IndexType
forall a. Storable a => Ptr a -> IO a
peek @IndexType ((Ptr IndexType
pIndexTypes Ptr IndexType -> Int -> Ptr IndexType
forall a. Ptr a -> Int -> Ptr a
`advancePtrBytes` (4 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr IndexType)))
Ptr ("groupIndex" ::: Word32)
pIndexTypeValues <- Ptr (Ptr ("groupIndex" ::: Word32))
-> IO (Ptr ("groupIndex" ::: Word32))
forall a. Storable a => Ptr a -> IO a
peek @(Ptr Word32) ((Ptr IndirectCommandsLayoutTokenNV
p Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr (Ptr ("groupIndex" ::: Word32))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 80 :: Ptr (Ptr Word32)))
Vector ("groupIndex" ::: Word32)
pIndexTypeValues' <- Int
-> (Int -> IO ("groupIndex" ::: Word32))
-> IO (Vector ("groupIndex" ::: Word32))
forall (m :: * -> *) a.
Monad m =>
Int -> (Int -> m a) -> m (Vector a)
generateM (("groupIndex" ::: Word32) -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral "groupIndex" ::: Word32
indexTypeCount) (\i :: Int
i -> Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr ("groupIndex" ::: Word32)
pIndexTypeValues Ptr ("groupIndex" ::: Word32)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a. Ptr a -> Int -> Ptr a
`advancePtrBytes` (4 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr Word32)))
IndirectCommandsLayoutTokenNV -> IO IndirectCommandsLayoutTokenNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (IndirectCommandsLayoutTokenNV -> IO IndirectCommandsLayoutTokenNV)
-> IndirectCommandsLayoutTokenNV
-> IO IndirectCommandsLayoutTokenNV
forall a b. (a -> b) -> a -> b
$ IndirectCommandsTokenTypeNV
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("isPreprocessed" ::: Bool)
-> PipelineLayout
-> ShaderStageFlags
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> IndirectStateFlagsNV
-> Vector IndexType
-> Vector ("groupIndex" ::: Word32)
-> IndirectCommandsLayoutTokenNV
IndirectCommandsLayoutTokenNV
IndirectCommandsTokenTypeNV
tokenType "groupIndex" ::: Word32
stream "groupIndex" ::: Word32
offset "groupIndex" ::: Word32
vertexBindingUnit (("isPreprocessed" ::: Bool32) -> "isPreprocessed" ::: Bool
bool32ToBool "isPreprocessed" ::: Bool32
vertexDynamicStride) PipelineLayout
pushconstantPipelineLayout ShaderStageFlags
pushconstantShaderStageFlags "groupIndex" ::: Word32
pushconstantOffset "groupIndex" ::: Word32
pushconstantSize IndirectStateFlagsNV
indirectStateFlags Vector IndexType
pIndexTypes' Vector ("groupIndex" ::: Word32)
pIndexTypeValues'
instance Zero IndirectCommandsLayoutTokenNV where
zero :: IndirectCommandsLayoutTokenNV
zero = IndirectCommandsTokenTypeNV
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> ("isPreprocessed" ::: Bool)
-> PipelineLayout
-> ShaderStageFlags
-> ("groupIndex" ::: Word32)
-> ("groupIndex" ::: Word32)
-> IndirectStateFlagsNV
-> Vector IndexType
-> Vector ("groupIndex" ::: Word32)
-> IndirectCommandsLayoutTokenNV
IndirectCommandsLayoutTokenNV
IndirectCommandsTokenTypeNV
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"isPreprocessed" ::: Bool
forall a. Zero a => a
zero
PipelineLayout
forall a. Zero a => a
zero
ShaderStageFlags
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
IndirectStateFlagsNV
forall a. Zero a => a
zero
Vector IndexType
forall a. Monoid a => a
mempty
Vector ("groupIndex" ::: Word32)
forall a. Monoid a => a
mempty
data IndirectCommandsLayoutCreateInfoNV = IndirectCommandsLayoutCreateInfoNV
{
IndirectCommandsLayoutCreateInfoNV
-> IndirectCommandsLayoutUsageFlagsNV
flags :: IndirectCommandsLayoutUsageFlagsNV
,
IndirectCommandsLayoutCreateInfoNV -> PipelineBindPoint
pipelineBindPoint :: PipelineBindPoint
,
IndirectCommandsLayoutCreateInfoNV
-> Vector IndirectCommandsLayoutTokenNV
tokens :: Vector IndirectCommandsLayoutTokenNV
,
IndirectCommandsLayoutCreateInfoNV
-> Vector ("groupIndex" ::: Word32)
streamStrides :: Vector Word32
}
deriving (Typeable)
deriving instance Show IndirectCommandsLayoutCreateInfoNV
instance ToCStruct IndirectCommandsLayoutCreateInfoNV where
withCStruct :: IndirectCommandsLayoutCreateInfoNV
-> (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> IO b)
-> IO b
withCStruct x :: IndirectCommandsLayoutCreateInfoNV
x f :: ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV) -> IO b
f = Int
-> Int
-> (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> IO b)
-> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 56 8 ((("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> IO b)
-> IO b)
-> (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> IO b)
-> IO b
forall a b. (a -> b) -> a -> b
$ \p :: "pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p -> ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> IndirectCommandsLayoutCreateInfoNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct "pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p IndirectCommandsLayoutCreateInfoNV
x (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV) -> IO b
f "pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p)
pokeCStruct :: ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> IndirectCommandsLayoutCreateInfoNV -> IO b -> IO b
pokeCStruct p :: "pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p IndirectCommandsLayoutCreateInfoNV{..} f :: IO b
f = ContT b IO b -> IO b
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT b IO b -> IO b) -> ContT b IO b -> IO b
forall a b. (a -> b) -> a -> b
$ do
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_INDIRECT_COMMANDS_LAYOUT_CREATE_INFO_NV)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr IndirectCommandsLayoutUsageFlagsNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr IndirectCommandsLayoutUsageFlagsNV)) (IndirectCommandsLayoutUsageFlagsNV
flags)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr PipelineBindPoint -> PipelineBindPoint -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr PipelineBindPoint
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr PipelineBindPoint)) (PipelineBindPoint
pipelineBindPoint)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Word32)) ((Int -> "groupIndex" ::: Word32
forall a b. (Integral a, Num b) => a -> b
fromIntegral (Vector IndirectCommandsLayoutTokenNV -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector IndirectCommandsLayoutTokenNV -> Int)
-> Vector IndirectCommandsLayoutTokenNV -> Int
forall a b. (a -> b) -> a -> b
$ (Vector IndirectCommandsLayoutTokenNV
tokens)) :: Word32))
Ptr IndirectCommandsLayoutTokenNV
pPTokens' <- ((Ptr IndirectCommandsLayoutTokenNV -> IO b) -> IO b)
-> ContT b IO (Ptr IndirectCommandsLayoutTokenNV)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr IndirectCommandsLayoutTokenNV -> IO b) -> IO b)
-> ContT b IO (Ptr IndirectCommandsLayoutTokenNV))
-> ((Ptr IndirectCommandsLayoutTokenNV -> IO b) -> IO b)
-> ContT b IO (Ptr IndirectCommandsLayoutTokenNV)
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr IndirectCommandsLayoutTokenNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @IndirectCommandsLayoutTokenNV ((Vector IndirectCommandsLayoutTokenNV -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector IndirectCommandsLayoutTokenNV
tokens)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 88) 8
(Int -> IndirectCommandsLayoutTokenNV -> ContT b IO ())
-> Vector IndirectCommandsLayoutTokenNV -> ContT b IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: IndirectCommandsLayoutTokenNV
e -> ((() -> IO b) -> IO b) -> ContT b IO ()
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((() -> IO b) -> IO b) -> ContT b IO ())
-> ((() -> IO b) -> IO b) -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr IndirectCommandsLayoutTokenNV
-> IndirectCommandsLayoutTokenNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct (Ptr IndirectCommandsLayoutTokenNV
pPTokens' Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr IndirectCommandsLayoutTokenNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (88 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr IndirectCommandsLayoutTokenNV) (IndirectCommandsLayoutTokenNV
e) (IO b -> IO b) -> ((() -> IO b) -> IO b) -> (() -> IO b) -> IO b
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ((() -> IO b) -> () -> IO b
forall a b. (a -> b) -> a -> b
$ ())) (Vector IndirectCommandsLayoutTokenNV
tokens)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr IndirectCommandsLayoutTokenNV)
-> Ptr IndirectCommandsLayoutTokenNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr (Ptr IndirectCommandsLayoutTokenNV)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr (Ptr IndirectCommandsLayoutTokenNV))) (Ptr IndirectCommandsLayoutTokenNV
pPTokens')
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Word32)) ((Int -> "groupIndex" ::: Word32
forall a b. (Integral a, Num b) => a -> b
fromIntegral (Vector ("groupIndex" ::: Word32) -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector ("groupIndex" ::: Word32) -> Int)
-> Vector ("groupIndex" ::: Word32) -> Int
forall a b. (a -> b) -> a -> b
$ (Vector ("groupIndex" ::: Word32)
streamStrides)) :: Word32))
Ptr ("groupIndex" ::: Word32)
pPStreamStrides' <- ((Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b)
-> ContT b IO (Ptr ("groupIndex" ::: Word32))
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b)
-> ContT b IO (Ptr ("groupIndex" ::: Word32)))
-> ((Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b)
-> ContT b IO (Ptr ("groupIndex" ::: Word32))
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @Word32 ((Vector ("groupIndex" ::: Word32) -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector ("groupIndex" ::: Word32)
streamStrides)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 4) 4
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ (Int -> ("groupIndex" ::: Word32) -> IO ())
-> Vector ("groupIndex" ::: Word32) -> IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: "groupIndex" ::: Word32
e -> Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr ("groupIndex" ::: Word32)
pPStreamStrides' Ptr ("groupIndex" ::: Word32)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (4 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr Word32) ("groupIndex" ::: Word32
e)) (Vector ("groupIndex" ::: Word32)
streamStrides)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ("groupIndex" ::: Word32))
-> Ptr ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr (Ptr ("groupIndex" ::: Word32))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr (Ptr Word32))) (Ptr ("groupIndex" ::: Word32)
pPStreamStrides')
IO b -> ContT b IO b
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO b -> ContT b IO b) -> IO b -> ContT b IO b
forall a b. (a -> b) -> a -> b
$ IO b
f
cStructSize :: Int
cStructSize = 56
cStructAlignment :: Int
cStructAlignment = 8
pokeZeroCStruct :: ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> IO b -> IO b
pokeZeroCStruct p :: "pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p f :: IO b
f = ContT b IO b -> IO b
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT b IO b -> IO b) -> ContT b IO b -> IO b
forall a b. (a -> b) -> a -> b
$ do
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_INDIRECT_COMMANDS_LAYOUT_CREATE_INFO_NV)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr IndirectCommandsLayoutUsageFlagsNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr IndirectCommandsLayoutUsageFlagsNV)) (IndirectCommandsLayoutUsageFlagsNV
forall a. Zero a => a
zero)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr PipelineBindPoint -> PipelineBindPoint -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr PipelineBindPoint
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr PipelineBindPoint)) (PipelineBindPoint
forall a. Zero a => a
zero)
Ptr IndirectCommandsLayoutTokenNV
pPTokens' <- ((Ptr IndirectCommandsLayoutTokenNV -> IO b) -> IO b)
-> ContT b IO (Ptr IndirectCommandsLayoutTokenNV)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr IndirectCommandsLayoutTokenNV -> IO b) -> IO b)
-> ContT b IO (Ptr IndirectCommandsLayoutTokenNV))
-> ((Ptr IndirectCommandsLayoutTokenNV -> IO b) -> IO b)
-> ContT b IO (Ptr IndirectCommandsLayoutTokenNV)
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr IndirectCommandsLayoutTokenNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @IndirectCommandsLayoutTokenNV ((Vector Any -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector Any
forall a. Monoid a => a
mempty)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 88) 8
(Int -> IndirectCommandsLayoutTokenNV -> ContT b IO ())
-> Vector IndirectCommandsLayoutTokenNV -> ContT b IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: IndirectCommandsLayoutTokenNV
e -> ((() -> IO b) -> IO b) -> ContT b IO ()
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((() -> IO b) -> IO b) -> ContT b IO ())
-> ((() -> IO b) -> IO b) -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr IndirectCommandsLayoutTokenNV
-> IndirectCommandsLayoutTokenNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct (Ptr IndirectCommandsLayoutTokenNV
pPTokens' Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr IndirectCommandsLayoutTokenNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (88 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr IndirectCommandsLayoutTokenNV) (IndirectCommandsLayoutTokenNV
e) (IO b -> IO b) -> ((() -> IO b) -> IO b) -> (() -> IO b) -> IO b
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ((() -> IO b) -> () -> IO b
forall a b. (a -> b) -> a -> b
$ ())) (Vector IndirectCommandsLayoutTokenNV
forall a. Monoid a => a
mempty)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr IndirectCommandsLayoutTokenNV)
-> Ptr IndirectCommandsLayoutTokenNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr (Ptr IndirectCommandsLayoutTokenNV)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr (Ptr IndirectCommandsLayoutTokenNV))) (Ptr IndirectCommandsLayoutTokenNV
pPTokens')
Ptr ("groupIndex" ::: Word32)
pPStreamStrides' <- ((Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b)
-> ContT b IO (Ptr ("groupIndex" ::: Word32))
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b)
-> ContT b IO (Ptr ("groupIndex" ::: Word32)))
-> ((Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b)
-> ContT b IO (Ptr ("groupIndex" ::: Word32))
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr ("groupIndex" ::: Word32) -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @Word32 ((Vector Any -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector Any
forall a. Monoid a => a
mempty)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 4) 4
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ (Int -> ("groupIndex" ::: Word32) -> IO ())
-> Vector ("groupIndex" ::: Word32) -> IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: "groupIndex" ::: Word32
e -> Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (Ptr ("groupIndex" ::: Word32)
pPStreamStrides' Ptr ("groupIndex" ::: Word32)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (4 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr Word32) ("groupIndex" ::: Word32
e)) (Vector ("groupIndex" ::: Word32)
forall a. Monoid a => a
mempty)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ("groupIndex" ::: Word32))
-> Ptr ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr (Ptr ("groupIndex" ::: Word32))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr (Ptr Word32))) (Ptr ("groupIndex" ::: Word32)
pPStreamStrides')
IO b -> ContT b IO b
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO b -> ContT b IO b) -> IO b -> ContT b IO b
forall a b. (a -> b) -> a -> b
$ IO b
f
instance FromCStruct IndirectCommandsLayoutCreateInfoNV where
peekCStruct :: ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> IO IndirectCommandsLayoutCreateInfoNV
peekCStruct p :: "pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p = do
IndirectCommandsLayoutUsageFlagsNV
flags <- Ptr IndirectCommandsLayoutUsageFlagsNV
-> IO IndirectCommandsLayoutUsageFlagsNV
forall a. Storable a => Ptr a -> IO a
peek @IndirectCommandsLayoutUsageFlagsNV (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr IndirectCommandsLayoutUsageFlagsNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr IndirectCommandsLayoutUsageFlagsNV))
PipelineBindPoint
pipelineBindPoint <- Ptr PipelineBindPoint -> IO PipelineBindPoint
forall a. Storable a => Ptr a -> IO a
peek @PipelineBindPoint (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr PipelineBindPoint
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 20 :: Ptr PipelineBindPoint))
"groupIndex" ::: Word32
tokenCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Word32))
Ptr IndirectCommandsLayoutTokenNV
pTokens <- Ptr (Ptr IndirectCommandsLayoutTokenNV)
-> IO (Ptr IndirectCommandsLayoutTokenNV)
forall a. Storable a => Ptr a -> IO a
peek @(Ptr IndirectCommandsLayoutTokenNV) (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr (Ptr IndirectCommandsLayoutTokenNV)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr (Ptr IndirectCommandsLayoutTokenNV)))
Vector IndirectCommandsLayoutTokenNV
pTokens' <- Int
-> (Int -> IO IndirectCommandsLayoutTokenNV)
-> IO (Vector IndirectCommandsLayoutTokenNV)
forall (m :: * -> *) a.
Monad m =>
Int -> (Int -> m a) -> m (Vector a)
generateM (("groupIndex" ::: Word32) -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral "groupIndex" ::: Word32
tokenCount) (\i :: Int
i -> Ptr IndirectCommandsLayoutTokenNV
-> IO IndirectCommandsLayoutTokenNV
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct @IndirectCommandsLayoutTokenNV ((Ptr IndirectCommandsLayoutTokenNV
pTokens Ptr IndirectCommandsLayoutTokenNV
-> Int -> Ptr IndirectCommandsLayoutTokenNV
forall a. Ptr a -> Int -> Ptr a
`advancePtrBytes` (88 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr IndirectCommandsLayoutTokenNV)))
"groupIndex" ::: Word32
streamCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Word32))
Ptr ("groupIndex" ::: Word32)
pStreamStrides <- Ptr (Ptr ("groupIndex" ::: Word32))
-> IO (Ptr ("groupIndex" ::: Word32))
forall a. Storable a => Ptr a -> IO a
peek @(Ptr Word32) (("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV
p ("pCreateInfo" ::: Ptr IndirectCommandsLayoutCreateInfoNV)
-> Int -> Ptr (Ptr ("groupIndex" ::: Word32))
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr (Ptr Word32)))
Vector ("groupIndex" ::: Word32)
pStreamStrides' <- Int
-> (Int -> IO ("groupIndex" ::: Word32))
-> IO (Vector ("groupIndex" ::: Word32))
forall (m :: * -> *) a.
Monad m =>
Int -> (Int -> m a) -> m (Vector a)
generateM (("groupIndex" ::: Word32) -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral "groupIndex" ::: Word32
streamCount) (\i :: Int
i -> Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 ((Ptr ("groupIndex" ::: Word32)
pStreamStrides Ptr ("groupIndex" ::: Word32)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a. Ptr a -> Int -> Ptr a
`advancePtrBytes` (4 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr Word32)))
IndirectCommandsLayoutCreateInfoNV
-> IO IndirectCommandsLayoutCreateInfoNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (IndirectCommandsLayoutCreateInfoNV
-> IO IndirectCommandsLayoutCreateInfoNV)
-> IndirectCommandsLayoutCreateInfoNV
-> IO IndirectCommandsLayoutCreateInfoNV
forall a b. (a -> b) -> a -> b
$ IndirectCommandsLayoutUsageFlagsNV
-> PipelineBindPoint
-> Vector IndirectCommandsLayoutTokenNV
-> Vector ("groupIndex" ::: Word32)
-> IndirectCommandsLayoutCreateInfoNV
IndirectCommandsLayoutCreateInfoNV
IndirectCommandsLayoutUsageFlagsNV
flags PipelineBindPoint
pipelineBindPoint Vector IndirectCommandsLayoutTokenNV
pTokens' Vector ("groupIndex" ::: Word32)
pStreamStrides'
instance Zero IndirectCommandsLayoutCreateInfoNV where
zero :: IndirectCommandsLayoutCreateInfoNV
zero = IndirectCommandsLayoutUsageFlagsNV
-> PipelineBindPoint
-> Vector IndirectCommandsLayoutTokenNV
-> Vector ("groupIndex" ::: Word32)
-> IndirectCommandsLayoutCreateInfoNV
IndirectCommandsLayoutCreateInfoNV
IndirectCommandsLayoutUsageFlagsNV
forall a. Zero a => a
zero
PipelineBindPoint
forall a. Zero a => a
zero
Vector IndirectCommandsLayoutTokenNV
forall a. Monoid a => a
mempty
Vector ("groupIndex" ::: Word32)
forall a. Monoid a => a
mempty
data GeneratedCommandsInfoNV = GeneratedCommandsInfoNV
{
GeneratedCommandsInfoNV -> PipelineBindPoint
pipelineBindPoint :: PipelineBindPoint
,
GeneratedCommandsInfoNV -> Pipeline
pipeline :: Pipeline
,
GeneratedCommandsInfoNV -> IndirectCommandsLayoutNV
indirectCommandsLayout :: IndirectCommandsLayoutNV
,
GeneratedCommandsInfoNV -> Vector IndirectCommandsStreamNV
streams :: Vector IndirectCommandsStreamNV
,
GeneratedCommandsInfoNV -> "groupIndex" ::: Word32
sequencesCount :: Word32
,
GeneratedCommandsInfoNV -> Buffer
preprocessBuffer :: Buffer
,
GeneratedCommandsInfoNV -> DeviceAddress
preprocessOffset :: DeviceSize
,
GeneratedCommandsInfoNV -> DeviceAddress
preprocessSize :: DeviceSize
,
GeneratedCommandsInfoNV -> Buffer
sequencesCountBuffer :: Buffer
,
GeneratedCommandsInfoNV -> DeviceAddress
sequencesCountOffset :: DeviceSize
,
GeneratedCommandsInfoNV -> Buffer
sequencesIndexBuffer :: Buffer
,
GeneratedCommandsInfoNV -> DeviceAddress
sequencesIndexOffset :: DeviceSize
}
deriving (Typeable)
deriving instance Show GeneratedCommandsInfoNV
instance ToCStruct GeneratedCommandsInfoNV where
withCStruct :: GeneratedCommandsInfoNV
-> (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO b)
-> IO b
withCStruct x :: GeneratedCommandsInfoNV
x f :: ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV) -> IO b
f = Int
-> Int
-> (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO b)
-> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 120 8 ((("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO b)
-> IO b)
-> (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO b)
-> IO b
forall a b. (a -> b) -> a -> b
$ \p :: "pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p -> ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> GeneratedCommandsInfoNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct "pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p GeneratedCommandsInfoNV
x (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV) -> IO b
f "pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p)
pokeCStruct :: ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> GeneratedCommandsInfoNV -> IO b -> IO b
pokeCStruct p :: "pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p GeneratedCommandsInfoNV{..} f :: IO b
f = ContT b IO b -> IO b
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT b IO b -> IO b) -> ContT b IO b -> IO b
forall a b. (a -> b) -> a -> b
$ do
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_GENERATED_COMMANDS_INFO_NV)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr PipelineBindPoint -> PipelineBindPoint -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr PipelineBindPoint
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr PipelineBindPoint)) (PipelineBindPoint
pipelineBindPoint)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr Pipeline -> Pipeline -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr Pipeline
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Pipeline)) (Pipeline
pipeline)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IndirectCommandsLayoutNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int
-> "pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr IndirectCommandsLayoutNV)) (IndirectCommandsLayoutNV
indirectCommandsLayout)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Word32)) ((Int -> "groupIndex" ::: Word32
forall a b. (Integral a, Num b) => a -> b
fromIntegral (Vector IndirectCommandsStreamNV -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector IndirectCommandsStreamNV -> Int)
-> Vector IndirectCommandsStreamNV -> Int
forall a b. (a -> b) -> a -> b
$ (Vector IndirectCommandsStreamNV
streams)) :: Word32))
Ptr IndirectCommandsStreamNV
pPStreams' <- ((Ptr IndirectCommandsStreamNV -> IO b) -> IO b)
-> ContT b IO (Ptr IndirectCommandsStreamNV)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr IndirectCommandsStreamNV -> IO b) -> IO b)
-> ContT b IO (Ptr IndirectCommandsStreamNV))
-> ((Ptr IndirectCommandsStreamNV -> IO b) -> IO b)
-> ContT b IO (Ptr IndirectCommandsStreamNV)
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr IndirectCommandsStreamNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @IndirectCommandsStreamNV ((Vector IndirectCommandsStreamNV -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector IndirectCommandsStreamNV
streams)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 16) 8
(Int -> IndirectCommandsStreamNV -> ContT b IO ())
-> Vector IndirectCommandsStreamNV -> ContT b IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: IndirectCommandsStreamNV
e -> ((() -> IO b) -> IO b) -> ContT b IO ()
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((() -> IO b) -> IO b) -> ContT b IO ())
-> ((() -> IO b) -> IO b) -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr IndirectCommandsStreamNV
-> IndirectCommandsStreamNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct (Ptr IndirectCommandsStreamNV
pPStreams' Ptr IndirectCommandsStreamNV -> Int -> Ptr IndirectCommandsStreamNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (16 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr IndirectCommandsStreamNV) (IndirectCommandsStreamNV
e) (IO b -> IO b) -> ((() -> IO b) -> IO b) -> (() -> IO b) -> IO b
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ((() -> IO b) -> () -> IO b
forall a b. (a -> b) -> a -> b
$ ())) (Vector IndirectCommandsStreamNV
streams)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr IndirectCommandsStreamNV)
-> Ptr IndirectCommandsStreamNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr (Ptr IndirectCommandsStreamNV)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr (Ptr IndirectCommandsStreamNV))) (Ptr IndirectCommandsStreamNV
pPStreams')
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 56 :: Ptr Word32)) ("groupIndex" ::: Word32
sequencesCount)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr Buffer -> Buffer -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr Buffer
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 64 :: Ptr Buffer)) (Buffer
preprocessBuffer)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr DeviceAddress -> DeviceAddress -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 72 :: Ptr DeviceSize)) (DeviceAddress
preprocessOffset)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr DeviceAddress -> DeviceAddress -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 80 :: Ptr DeviceSize)) (DeviceAddress
preprocessSize)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr Buffer -> Buffer -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr Buffer
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 88 :: Ptr Buffer)) (Buffer
sequencesCountBuffer)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr DeviceAddress -> DeviceAddress -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 96 :: Ptr DeviceSize)) (DeviceAddress
sequencesCountOffset)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr Buffer -> Buffer -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr Buffer
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 104 :: Ptr Buffer)) (Buffer
sequencesIndexBuffer)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr DeviceAddress -> DeviceAddress -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 112 :: Ptr DeviceSize)) (DeviceAddress
sequencesIndexOffset)
IO b -> ContT b IO b
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO b -> ContT b IO b) -> IO b -> ContT b IO b
forall a b. (a -> b) -> a -> b
$ IO b
f
cStructSize :: Int
cStructSize = 120
cStructAlignment :: Int
cStructAlignment = 8
pokeZeroCStruct :: ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO b -> IO b
pokeZeroCStruct p :: "pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p f :: IO b
f = ContT b IO b -> IO b
forall (m :: * -> *) r. Monad m => ContT r m r -> m r
evalContT (ContT b IO b -> IO b) -> ContT b IO b -> IO b
forall a b. (a -> b) -> a -> b
$ do
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_GENERATED_COMMANDS_INFO_NV)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr PipelineBindPoint -> PipelineBindPoint -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr PipelineBindPoint
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr PipelineBindPoint)) (PipelineBindPoint
forall a. Zero a => a
zero)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr Pipeline -> Pipeline -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr Pipeline
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Pipeline)) (Pipeline
forall a. Zero a => a
zero)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IndirectCommandsLayoutNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int
-> "pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr IndirectCommandsLayoutNV)) (IndirectCommandsLayoutNV
forall a. Zero a => a
zero)
Ptr IndirectCommandsStreamNV
pPStreams' <- ((Ptr IndirectCommandsStreamNV -> IO b) -> IO b)
-> ContT b IO (Ptr IndirectCommandsStreamNV)
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((Ptr IndirectCommandsStreamNV -> IO b) -> IO b)
-> ContT b IO (Ptr IndirectCommandsStreamNV))
-> ((Ptr IndirectCommandsStreamNV -> IO b) -> IO b)
-> ContT b IO (Ptr IndirectCommandsStreamNV)
forall a b. (a -> b) -> a -> b
$ Int -> Int -> (Ptr IndirectCommandsStreamNV -> IO b) -> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned @IndirectCommandsStreamNV ((Vector Any -> Int
forall a. Vector a -> Int
Data.Vector.length (Vector Any
forall a. Monoid a => a
mempty)) Int -> Int -> Int
forall a. Num a => a -> a -> a
* 16) 8
(Int -> IndirectCommandsStreamNV -> ContT b IO ())
-> Vector IndirectCommandsStreamNV -> ContT b IO ()
forall (m :: * -> *) a b.
Monad m =>
(Int -> a -> m b) -> Vector a -> m ()
Data.Vector.imapM_ (\i :: Int
i e :: IndirectCommandsStreamNV
e -> ((() -> IO b) -> IO b) -> ContT b IO ()
forall k (r :: k) (m :: k -> *) a.
((a -> m r) -> m r) -> ContT r m a
ContT (((() -> IO b) -> IO b) -> ContT b IO ())
-> ((() -> IO b) -> IO b) -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr IndirectCommandsStreamNV
-> IndirectCommandsStreamNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct (Ptr IndirectCommandsStreamNV
pPStreams' Ptr IndirectCommandsStreamNV -> Int -> Ptr IndirectCommandsStreamNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` (16 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr IndirectCommandsStreamNV) (IndirectCommandsStreamNV
e) (IO b -> IO b) -> ((() -> IO b) -> IO b) -> (() -> IO b) -> IO b
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ((() -> IO b) -> () -> IO b
forall a b. (a -> b) -> a -> b
$ ())) (Vector IndirectCommandsStreamNV
forall a. Monoid a => a
mempty)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr (Ptr IndirectCommandsStreamNV)
-> Ptr IndirectCommandsStreamNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr (Ptr IndirectCommandsStreamNV)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr (Ptr IndirectCommandsStreamNV))) (Ptr IndirectCommandsStreamNV
pPStreams')
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 56 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr Buffer -> Buffer -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr Buffer
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 64 :: Ptr Buffer)) (Buffer
forall a. Zero a => a
zero)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr DeviceAddress -> DeviceAddress -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 72 :: Ptr DeviceSize)) (DeviceAddress
forall a. Zero a => a
zero)
IO () -> ContT b IO ()
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO () -> ContT b IO ()) -> IO () -> ContT b IO ()
forall a b. (a -> b) -> a -> b
$ Ptr DeviceAddress -> DeviceAddress -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 80 :: Ptr DeviceSize)) (DeviceAddress
forall a. Zero a => a
zero)
IO b -> ContT b IO b
forall (t :: (* -> *) -> * -> *) (m :: * -> *) a.
(MonadTrans t, Monad m) =>
m a -> t m a
lift (IO b -> ContT b IO b) -> IO b -> ContT b IO b
forall a b. (a -> b) -> a -> b
$ IO b
f
instance FromCStruct GeneratedCommandsInfoNV where
peekCStruct :: ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> IO GeneratedCommandsInfoNV
peekCStruct p :: "pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p = do
PipelineBindPoint
pipelineBindPoint <- Ptr PipelineBindPoint -> IO PipelineBindPoint
forall a. Storable a => Ptr a -> IO a
peek @PipelineBindPoint (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr PipelineBindPoint
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr PipelineBindPoint))
Pipeline
pipeline <- Ptr Pipeline -> IO Pipeline
forall a. Storable a => Ptr a -> IO a
peek @Pipeline (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr Pipeline
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Pipeline))
IndirectCommandsLayoutNV
indirectCommandsLayout <- ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV
forall a. Storable a => Ptr a -> IO a
peek @IndirectCommandsLayoutNV (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int
-> "pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr IndirectCommandsLayoutNV))
"groupIndex" ::: Word32
streamCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Word32))
Ptr IndirectCommandsStreamNV
pStreams <- Ptr (Ptr IndirectCommandsStreamNV)
-> IO (Ptr IndirectCommandsStreamNV)
forall a. Storable a => Ptr a -> IO a
peek @(Ptr IndirectCommandsStreamNV) (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr (Ptr IndirectCommandsStreamNV)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 48 :: Ptr (Ptr IndirectCommandsStreamNV)))
Vector IndirectCommandsStreamNV
pStreams' <- Int
-> (Int -> IO IndirectCommandsStreamNV)
-> IO (Vector IndirectCommandsStreamNV)
forall (m :: * -> *) a.
Monad m =>
Int -> (Int -> m a) -> m (Vector a)
generateM (("groupIndex" ::: Word32) -> Int
forall a b. (Integral a, Num b) => a -> b
fromIntegral "groupIndex" ::: Word32
streamCount) (\i :: Int
i -> Ptr IndirectCommandsStreamNV -> IO IndirectCommandsStreamNV
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct @IndirectCommandsStreamNV ((Ptr IndirectCommandsStreamNV
pStreams Ptr IndirectCommandsStreamNV -> Int -> Ptr IndirectCommandsStreamNV
forall a. Ptr a -> Int -> Ptr a
`advancePtrBytes` (16 Int -> Int -> Int
forall a. Num a => a -> a -> a
* (Int
i)) :: Ptr IndirectCommandsStreamNV)))
"groupIndex" ::: Word32
sequencesCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 56 :: Ptr Word32))
Buffer
preprocessBuffer <- Ptr Buffer -> IO Buffer
forall a. Storable a => Ptr a -> IO a
peek @Buffer (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr Buffer
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 64 :: Ptr Buffer))
DeviceAddress
preprocessOffset <- Ptr DeviceAddress -> IO DeviceAddress
forall a. Storable a => Ptr a -> IO a
peek @DeviceSize (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 72 :: Ptr DeviceSize))
DeviceAddress
preprocessSize <- Ptr DeviceAddress -> IO DeviceAddress
forall a. Storable a => Ptr a -> IO a
peek @DeviceSize (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 80 :: Ptr DeviceSize))
Buffer
sequencesCountBuffer <- Ptr Buffer -> IO Buffer
forall a. Storable a => Ptr a -> IO a
peek @Buffer (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr Buffer
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 88 :: Ptr Buffer))
DeviceAddress
sequencesCountOffset <- Ptr DeviceAddress -> IO DeviceAddress
forall a. Storable a => Ptr a -> IO a
peek @DeviceSize (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 96 :: Ptr DeviceSize))
Buffer
sequencesIndexBuffer <- Ptr Buffer -> IO Buffer
forall a. Storable a => Ptr a -> IO a
peek @Buffer (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr Buffer
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 104 :: Ptr Buffer))
DeviceAddress
sequencesIndexOffset <- Ptr DeviceAddress -> IO DeviceAddress
forall a. Storable a => Ptr a -> IO a
peek @DeviceSize (("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV
p ("pGeneratedCommandsInfo" ::: Ptr GeneratedCommandsInfoNV)
-> Int -> Ptr DeviceAddress
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 112 :: Ptr DeviceSize))
GeneratedCommandsInfoNV -> IO GeneratedCommandsInfoNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (GeneratedCommandsInfoNV -> IO GeneratedCommandsInfoNV)
-> GeneratedCommandsInfoNV -> IO GeneratedCommandsInfoNV
forall a b. (a -> b) -> a -> b
$ PipelineBindPoint
-> Pipeline
-> IndirectCommandsLayoutNV
-> Vector IndirectCommandsStreamNV
-> ("groupIndex" ::: Word32)
-> Buffer
-> DeviceAddress
-> DeviceAddress
-> Buffer
-> DeviceAddress
-> Buffer
-> DeviceAddress
-> GeneratedCommandsInfoNV
GeneratedCommandsInfoNV
PipelineBindPoint
pipelineBindPoint Pipeline
pipeline IndirectCommandsLayoutNV
indirectCommandsLayout Vector IndirectCommandsStreamNV
pStreams' "groupIndex" ::: Word32
sequencesCount Buffer
preprocessBuffer DeviceAddress
preprocessOffset DeviceAddress
preprocessSize Buffer
sequencesCountBuffer DeviceAddress
sequencesCountOffset Buffer
sequencesIndexBuffer DeviceAddress
sequencesIndexOffset
instance Zero GeneratedCommandsInfoNV where
zero :: GeneratedCommandsInfoNV
zero = PipelineBindPoint
-> Pipeline
-> IndirectCommandsLayoutNV
-> Vector IndirectCommandsStreamNV
-> ("groupIndex" ::: Word32)
-> Buffer
-> DeviceAddress
-> DeviceAddress
-> Buffer
-> DeviceAddress
-> Buffer
-> DeviceAddress
-> GeneratedCommandsInfoNV
GeneratedCommandsInfoNV
PipelineBindPoint
forall a. Zero a => a
zero
Pipeline
forall a. Zero a => a
zero
IndirectCommandsLayoutNV
forall a. Zero a => a
zero
Vector IndirectCommandsStreamNV
forall a. Monoid a => a
mempty
"groupIndex" ::: Word32
forall a. Zero a => a
zero
Buffer
forall a. Zero a => a
zero
DeviceAddress
forall a. Zero a => a
zero
DeviceAddress
forall a. Zero a => a
zero
Buffer
forall a. Zero a => a
zero
DeviceAddress
forall a. Zero a => a
zero
Buffer
forall a. Zero a => a
zero
DeviceAddress
forall a. Zero a => a
zero
data GeneratedCommandsMemoryRequirementsInfoNV = GeneratedCommandsMemoryRequirementsInfoNV
{
GeneratedCommandsMemoryRequirementsInfoNV -> PipelineBindPoint
pipelineBindPoint :: PipelineBindPoint
,
GeneratedCommandsMemoryRequirementsInfoNV -> Pipeline
pipeline :: Pipeline
,
GeneratedCommandsMemoryRequirementsInfoNV
-> IndirectCommandsLayoutNV
indirectCommandsLayout :: IndirectCommandsLayoutNV
,
GeneratedCommandsMemoryRequirementsInfoNV
-> "groupIndex" ::: Word32
maxSequencesCount :: Word32
}
deriving (Typeable)
deriving instance Show GeneratedCommandsMemoryRequirementsInfoNV
instance ToCStruct GeneratedCommandsMemoryRequirementsInfoNV where
withCStruct :: GeneratedCommandsMemoryRequirementsInfoNV
-> (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> IO b)
-> IO b
withCStruct x :: GeneratedCommandsMemoryRequirementsInfoNV
x f :: ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV) -> IO b
f = Int
-> Int
-> (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> IO b)
-> IO b
forall a b. Int -> Int -> (Ptr a -> IO b) -> IO b
allocaBytesAligned 48 8 ((("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> IO b)
-> IO b)
-> (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> IO b)
-> IO b
forall a b. (a -> b) -> a -> b
$ \p :: "pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p -> ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> GeneratedCommandsMemoryRequirementsInfoNV -> IO b -> IO b
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct "pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p GeneratedCommandsMemoryRequirementsInfoNV
x (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV) -> IO b
f "pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p)
pokeCStruct :: ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> GeneratedCommandsMemoryRequirementsInfoNV -> IO b -> IO b
pokeCStruct p :: "pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p GeneratedCommandsMemoryRequirementsInfoNV{..} f :: IO b
f = do
Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_GENERATED_COMMANDS_MEMORY_REQUIREMENTS_INFO_NV)
Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
Ptr PipelineBindPoint -> PipelineBindPoint -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr PipelineBindPoint
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr PipelineBindPoint)) (PipelineBindPoint
pipelineBindPoint)
Ptr Pipeline -> Pipeline -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr Pipeline
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Pipeline)) (Pipeline
pipeline)
("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IndirectCommandsLayoutNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int
-> "pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr IndirectCommandsLayoutNV)) (IndirectCommandsLayoutNV
indirectCommandsLayout)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Word32)) ("groupIndex" ::: Word32
maxSequencesCount)
IO b
f
cStructSize :: Int
cStructSize = 48
cStructAlignment :: Int
cStructAlignment = 8
pokeZeroCStruct :: ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> IO b -> IO b
pokeZeroCStruct p :: "pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p f :: IO b
f = do
Ptr StructureType -> StructureType -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr StructureType
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 0 :: Ptr StructureType)) (StructureType
STRUCTURE_TYPE_GENERATED_COMMANDS_MEMORY_REQUIREMENTS_INFO_NV)
Ptr (Ptr ()) -> Ptr () -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr (Ptr ())
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 8 :: Ptr (Ptr ()))) (Ptr ()
forall a. Ptr a
nullPtr)
Ptr PipelineBindPoint -> PipelineBindPoint -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr PipelineBindPoint
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr PipelineBindPoint)) (PipelineBindPoint
forall a. Zero a => a
zero)
Ptr Pipeline -> Pipeline -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr Pipeline
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Pipeline)) (Pipeline
forall a. Zero a => a
zero)
("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IndirectCommandsLayoutNV -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int
-> "pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr IndirectCommandsLayoutNV)) (IndirectCommandsLayoutNV
forall a. Zero a => a
zero)
Ptr ("groupIndex" ::: Word32) -> ("groupIndex" ::: Word32) -> IO ()
forall a. Storable a => Ptr a -> a -> IO ()
poke (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Word32)) ("groupIndex" ::: Word32
forall a. Zero a => a
zero)
IO b
f
instance FromCStruct GeneratedCommandsMemoryRequirementsInfoNV where
peekCStruct :: ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> IO GeneratedCommandsMemoryRequirementsInfoNV
peekCStruct p :: "pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p = do
PipelineBindPoint
pipelineBindPoint <- Ptr PipelineBindPoint -> IO PipelineBindPoint
forall a. Storable a => Ptr a -> IO a
peek @PipelineBindPoint (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr PipelineBindPoint
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 16 :: Ptr PipelineBindPoint))
Pipeline
pipeline <- Ptr Pipeline -> IO Pipeline
forall a. Storable a => Ptr a -> IO a
peek @Pipeline (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr Pipeline
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 24 :: Ptr Pipeline))
IndirectCommandsLayoutNV
indirectCommandsLayout <- ("pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV)
-> IO IndirectCommandsLayoutNV
forall a. Storable a => Ptr a -> IO a
peek @IndirectCommandsLayoutNV (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int
-> "pIndirectCommandsLayout" ::: Ptr IndirectCommandsLayoutNV
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 32 :: Ptr IndirectCommandsLayoutNV))
"groupIndex" ::: Word32
maxSequencesCount <- Ptr ("groupIndex" ::: Word32) -> IO ("groupIndex" ::: Word32)
forall a. Storable a => Ptr a -> IO a
peek @Word32 (("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
p ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> Int -> Ptr ("groupIndex" ::: Word32)
forall a b. Ptr a -> Int -> Ptr b
`plusPtr` 40 :: Ptr Word32))
GeneratedCommandsMemoryRequirementsInfoNV
-> IO GeneratedCommandsMemoryRequirementsInfoNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (GeneratedCommandsMemoryRequirementsInfoNV
-> IO GeneratedCommandsMemoryRequirementsInfoNV)
-> GeneratedCommandsMemoryRequirementsInfoNV
-> IO GeneratedCommandsMemoryRequirementsInfoNV
forall a b. (a -> b) -> a -> b
$ PipelineBindPoint
-> Pipeline
-> IndirectCommandsLayoutNV
-> ("groupIndex" ::: Word32)
-> GeneratedCommandsMemoryRequirementsInfoNV
GeneratedCommandsMemoryRequirementsInfoNV
PipelineBindPoint
pipelineBindPoint Pipeline
pipeline IndirectCommandsLayoutNV
indirectCommandsLayout "groupIndex" ::: Word32
maxSequencesCount
instance Storable GeneratedCommandsMemoryRequirementsInfoNV where
sizeOf :: GeneratedCommandsMemoryRequirementsInfoNV -> Int
sizeOf ~GeneratedCommandsMemoryRequirementsInfoNV
_ = 48
alignment :: GeneratedCommandsMemoryRequirementsInfoNV -> Int
alignment ~GeneratedCommandsMemoryRequirementsInfoNV
_ = 8
peek :: ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> IO GeneratedCommandsMemoryRequirementsInfoNV
peek = ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> IO GeneratedCommandsMemoryRequirementsInfoNV
forall a. FromCStruct a => Ptr a -> IO a
peekCStruct
poke :: ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> GeneratedCommandsMemoryRequirementsInfoNV -> IO ()
poke ptr :: "pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
ptr poked :: GeneratedCommandsMemoryRequirementsInfoNV
poked = ("pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV)
-> GeneratedCommandsMemoryRequirementsInfoNV -> IO () -> IO ()
forall a b. ToCStruct a => Ptr a -> a -> IO b -> IO b
pokeCStruct "pInfo" ::: Ptr GeneratedCommandsMemoryRequirementsInfoNV
ptr GeneratedCommandsMemoryRequirementsInfoNV
poked (() -> IO ()
forall (f :: * -> *) a. Applicative f => a -> f a
pure ())
instance Zero GeneratedCommandsMemoryRequirementsInfoNV where
zero :: GeneratedCommandsMemoryRequirementsInfoNV
zero = PipelineBindPoint
-> Pipeline
-> IndirectCommandsLayoutNV
-> ("groupIndex" ::: Word32)
-> GeneratedCommandsMemoryRequirementsInfoNV
GeneratedCommandsMemoryRequirementsInfoNV
PipelineBindPoint
forall a. Zero a => a
zero
Pipeline
forall a. Zero a => a
zero
IndirectCommandsLayoutNV
forall a. Zero a => a
zero
"groupIndex" ::: Word32
forall a. Zero a => a
zero
newtype IndirectCommandsLayoutUsageFlagBitsNV = IndirectCommandsLayoutUsageFlagBitsNV Flags
deriving newtype (IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
(IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool)
-> (IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool)
-> Eq IndirectCommandsLayoutUsageFlagsNV
forall a.
(a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> "isPreprocessed" ::: Bool) -> Eq a
/= :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
$c/= :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
== :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
$c== :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
Eq, Eq IndirectCommandsLayoutUsageFlagsNV
Eq IndirectCommandsLayoutUsageFlagsNV =>
(IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> Ordering)
-> (IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool)
-> (IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool)
-> (IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool)
-> (IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool)
-> (IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV)
-> Ord IndirectCommandsLayoutUsageFlagsNV
IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> Ordering
IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
forall a.
Eq a =>
(a -> a -> Ordering)
-> (a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
min :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
$cmin :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
max :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
$cmax :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
>= :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
$c>= :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
> :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
$c> :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
<= :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
$c<= :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
< :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
$c< :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
compare :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> Ordering
$ccompare :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> Ordering
$cp1Ord :: Eq IndirectCommandsLayoutUsageFlagsNV
Ord, Ptr b -> Int -> IO IndirectCommandsLayoutUsageFlagsNV
Ptr b -> Int -> IndirectCommandsLayoutUsageFlagsNV -> IO ()
Ptr IndirectCommandsLayoutUsageFlagsNV
-> IO IndirectCommandsLayoutUsageFlagsNV
Ptr IndirectCommandsLayoutUsageFlagsNV
-> Int -> IO IndirectCommandsLayoutUsageFlagsNV
Ptr IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV -> IO ()
Ptr IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> IO ()
IndirectCommandsLayoutUsageFlagsNV -> Int
(IndirectCommandsLayoutUsageFlagsNV -> Int)
-> (IndirectCommandsLayoutUsageFlagsNV -> Int)
-> (Ptr IndirectCommandsLayoutUsageFlagsNV
-> Int -> IO IndirectCommandsLayoutUsageFlagsNV)
-> (Ptr IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV -> IO ())
-> (forall b.
Ptr b -> Int -> IO IndirectCommandsLayoutUsageFlagsNV)
-> (forall b.
Ptr b -> Int -> IndirectCommandsLayoutUsageFlagsNV -> IO ())
-> (Ptr IndirectCommandsLayoutUsageFlagsNV
-> IO IndirectCommandsLayoutUsageFlagsNV)
-> (Ptr IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> IO ())
-> Storable IndirectCommandsLayoutUsageFlagsNV
forall b. Ptr b -> Int -> IO IndirectCommandsLayoutUsageFlagsNV
forall b.
Ptr b -> Int -> IndirectCommandsLayoutUsageFlagsNV -> 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 IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> IO ()
$cpoke :: Ptr IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV -> IO ()
peek :: Ptr IndirectCommandsLayoutUsageFlagsNV
-> IO IndirectCommandsLayoutUsageFlagsNV
$cpeek :: Ptr IndirectCommandsLayoutUsageFlagsNV
-> IO IndirectCommandsLayoutUsageFlagsNV
pokeByteOff :: Ptr b -> Int -> IndirectCommandsLayoutUsageFlagsNV -> IO ()
$cpokeByteOff :: forall b.
Ptr b -> Int -> IndirectCommandsLayoutUsageFlagsNV -> IO ()
peekByteOff :: Ptr b -> Int -> IO IndirectCommandsLayoutUsageFlagsNV
$cpeekByteOff :: forall b. Ptr b -> Int -> IO IndirectCommandsLayoutUsageFlagsNV
pokeElemOff :: Ptr IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV -> IO ()
$cpokeElemOff :: Ptr IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV -> IO ()
peekElemOff :: Ptr IndirectCommandsLayoutUsageFlagsNV
-> Int -> IO IndirectCommandsLayoutUsageFlagsNV
$cpeekElemOff :: Ptr IndirectCommandsLayoutUsageFlagsNV
-> Int -> IO IndirectCommandsLayoutUsageFlagsNV
alignment :: IndirectCommandsLayoutUsageFlagsNV -> Int
$calignment :: IndirectCommandsLayoutUsageFlagsNV -> Int
sizeOf :: IndirectCommandsLayoutUsageFlagsNV -> Int
$csizeOf :: IndirectCommandsLayoutUsageFlagsNV -> Int
Storable, IndirectCommandsLayoutUsageFlagsNV
IndirectCommandsLayoutUsageFlagsNV
-> Zero IndirectCommandsLayoutUsageFlagsNV
forall a. a -> Zero a
zero :: IndirectCommandsLayoutUsageFlagsNV
$czero :: IndirectCommandsLayoutUsageFlagsNV
Zero, Eq IndirectCommandsLayoutUsageFlagsNV
IndirectCommandsLayoutUsageFlagsNV
Eq IndirectCommandsLayoutUsageFlagsNV =>
(IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV)
-> IndirectCommandsLayoutUsageFlagsNV
-> (Int -> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> Int -> "isPreprocessed" ::: Bool)
-> (IndirectCommandsLayoutUsageFlagsNV -> Maybe Int)
-> (IndirectCommandsLayoutUsageFlagsNV -> Int)
-> (IndirectCommandsLayoutUsageFlagsNV
-> "isPreprocessed" ::: Bool)
-> (IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV)
-> (IndirectCommandsLayoutUsageFlagsNV -> Int)
-> Bits IndirectCommandsLayoutUsageFlagsNV
Int -> IndirectCommandsLayoutUsageFlagsNV
IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
IndirectCommandsLayoutUsageFlagsNV -> Int
IndirectCommandsLayoutUsageFlagsNV -> Maybe Int
IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
IndirectCommandsLayoutUsageFlagsNV
-> Int -> "isPreprocessed" ::: Bool
IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
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 -> "isPreprocessed" ::: Bool)
-> (a -> Maybe Int)
-> (a -> Int)
-> (a -> "isPreprocessed" ::: Bool)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int)
-> Bits a
popCount :: IndirectCommandsLayoutUsageFlagsNV -> Int
$cpopCount :: IndirectCommandsLayoutUsageFlagsNV -> Int
rotateR :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
$crotateR :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
rotateL :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
$crotateL :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
unsafeShiftR :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
$cunsafeShiftR :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
shiftR :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
$cshiftR :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
unsafeShiftL :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
$cunsafeShiftL :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
shiftL :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
$cshiftL :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
isSigned :: IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
$cisSigned :: IndirectCommandsLayoutUsageFlagsNV -> "isPreprocessed" ::: Bool
bitSize :: IndirectCommandsLayoutUsageFlagsNV -> Int
$cbitSize :: IndirectCommandsLayoutUsageFlagsNV -> Int
bitSizeMaybe :: IndirectCommandsLayoutUsageFlagsNV -> Maybe Int
$cbitSizeMaybe :: IndirectCommandsLayoutUsageFlagsNV -> Maybe Int
testBit :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> "isPreprocessed" ::: Bool
$ctestBit :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> "isPreprocessed" ::: Bool
complementBit :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
$ccomplementBit :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
clearBit :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
$cclearBit :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
setBit :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
$csetBit :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
bit :: Int -> IndirectCommandsLayoutUsageFlagsNV
$cbit :: Int -> IndirectCommandsLayoutUsageFlagsNV
zeroBits :: IndirectCommandsLayoutUsageFlagsNV
$czeroBits :: IndirectCommandsLayoutUsageFlagsNV
rotate :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
$crotate :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
shift :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
$cshift :: IndirectCommandsLayoutUsageFlagsNV
-> Int -> IndirectCommandsLayoutUsageFlagsNV
complement :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
$ccomplement :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
xor :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
$cxor :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
.|. :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
$c.|. :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
.&. :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
$c.&. :: IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
-> IndirectCommandsLayoutUsageFlagsNV
$cp1Bits :: Eq IndirectCommandsLayoutUsageFlagsNV
Bits)
pattern $bINDIRECT_COMMANDS_LAYOUT_USAGE_EXPLICIT_PREPROCESS_BIT_NV :: IndirectCommandsLayoutUsageFlagsNV
$mINDIRECT_COMMANDS_LAYOUT_USAGE_EXPLICIT_PREPROCESS_BIT_NV :: forall r.
IndirectCommandsLayoutUsageFlagsNV
-> (Void# -> r) -> (Void# -> r) -> r
INDIRECT_COMMANDS_LAYOUT_USAGE_EXPLICIT_PREPROCESS_BIT_NV = IndirectCommandsLayoutUsageFlagBitsNV 0x00000001
pattern $bINDIRECT_COMMANDS_LAYOUT_USAGE_INDEXED_SEQUENCES_BIT_NV :: IndirectCommandsLayoutUsageFlagsNV
$mINDIRECT_COMMANDS_LAYOUT_USAGE_INDEXED_SEQUENCES_BIT_NV :: forall r.
IndirectCommandsLayoutUsageFlagsNV
-> (Void# -> r) -> (Void# -> r) -> r
INDIRECT_COMMANDS_LAYOUT_USAGE_INDEXED_SEQUENCES_BIT_NV = IndirectCommandsLayoutUsageFlagBitsNV 0x00000002
pattern $bINDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NV :: IndirectCommandsLayoutUsageFlagsNV
$mINDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NV :: forall r.
IndirectCommandsLayoutUsageFlagsNV
-> (Void# -> r) -> (Void# -> r) -> r
INDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NV = IndirectCommandsLayoutUsageFlagBitsNV 0x00000004
type IndirectCommandsLayoutUsageFlagsNV = IndirectCommandsLayoutUsageFlagBitsNV
instance Show IndirectCommandsLayoutUsageFlagBitsNV where
showsPrec :: Int -> IndirectCommandsLayoutUsageFlagsNV -> ShowS
showsPrec p :: Int
p = \case
INDIRECT_COMMANDS_LAYOUT_USAGE_EXPLICIT_PREPROCESS_BIT_NV -> String -> ShowS
showString "INDIRECT_COMMANDS_LAYOUT_USAGE_EXPLICIT_PREPROCESS_BIT_NV"
INDIRECT_COMMANDS_LAYOUT_USAGE_INDEXED_SEQUENCES_BIT_NV -> String -> ShowS
showString "INDIRECT_COMMANDS_LAYOUT_USAGE_INDEXED_SEQUENCES_BIT_NV"
INDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NV -> String -> ShowS
showString "INDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NV"
IndirectCommandsLayoutUsageFlagBitsNV x :: "groupIndex" ::: Word32
x -> ("isPreprocessed" ::: Bool) -> ShowS -> ShowS
showParen (Int
p Int -> Int -> "isPreprocessed" ::: Bool
forall a. Ord a => a -> a -> "isPreprocessed" ::: Bool
>= 11) (String -> ShowS
showString "IndirectCommandsLayoutUsageFlagBitsNV 0x" ShowS -> ShowS -> ShowS
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ("groupIndex" ::: Word32) -> ShowS
forall a. (Integral a, Show a) => a -> ShowS
showHex "groupIndex" ::: Word32
x)
instance Read IndirectCommandsLayoutUsageFlagBitsNV where
readPrec :: ReadPrec IndirectCommandsLayoutUsageFlagsNV
readPrec = ReadPrec IndirectCommandsLayoutUsageFlagsNV
-> ReadPrec IndirectCommandsLayoutUsageFlagsNV
forall a. ReadPrec a -> ReadPrec a
parens ([(String, ReadPrec IndirectCommandsLayoutUsageFlagsNV)]
-> ReadPrec IndirectCommandsLayoutUsageFlagsNV
forall a. [(String, ReadPrec a)] -> ReadPrec a
choose [("INDIRECT_COMMANDS_LAYOUT_USAGE_EXPLICIT_PREPROCESS_BIT_NV", IndirectCommandsLayoutUsageFlagsNV
-> ReadPrec IndirectCommandsLayoutUsageFlagsNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure IndirectCommandsLayoutUsageFlagsNV
INDIRECT_COMMANDS_LAYOUT_USAGE_EXPLICIT_PREPROCESS_BIT_NV)
, ("INDIRECT_COMMANDS_LAYOUT_USAGE_INDEXED_SEQUENCES_BIT_NV", IndirectCommandsLayoutUsageFlagsNV
-> ReadPrec IndirectCommandsLayoutUsageFlagsNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure IndirectCommandsLayoutUsageFlagsNV
INDIRECT_COMMANDS_LAYOUT_USAGE_INDEXED_SEQUENCES_BIT_NV)
, ("INDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NV", IndirectCommandsLayoutUsageFlagsNV
-> ReadPrec IndirectCommandsLayoutUsageFlagsNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure IndirectCommandsLayoutUsageFlagsNV
INDIRECT_COMMANDS_LAYOUT_USAGE_UNORDERED_SEQUENCES_BIT_NV)]
ReadPrec IndirectCommandsLayoutUsageFlagsNV
-> ReadPrec IndirectCommandsLayoutUsageFlagsNV
-> ReadPrec IndirectCommandsLayoutUsageFlagsNV
forall a. ReadPrec a -> ReadPrec a -> ReadPrec a
+++
Int
-> ReadPrec IndirectCommandsLayoutUsageFlagsNV
-> ReadPrec IndirectCommandsLayoutUsageFlagsNV
forall a. Int -> ReadPrec a -> ReadPrec a
prec 10 (do
Lexeme -> ReadPrec ()
expectP (String -> Lexeme
Ident "IndirectCommandsLayoutUsageFlagBitsNV")
"groupIndex" ::: Word32
v <- ReadPrec ("groupIndex" ::: Word32)
-> ReadPrec ("groupIndex" ::: Word32)
forall a. ReadPrec a -> ReadPrec a
step ReadPrec ("groupIndex" ::: Word32)
forall a. Read a => ReadPrec a
readPrec
IndirectCommandsLayoutUsageFlagsNV
-> ReadPrec IndirectCommandsLayoutUsageFlagsNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (("groupIndex" ::: Word32) -> IndirectCommandsLayoutUsageFlagsNV
IndirectCommandsLayoutUsageFlagBitsNV "groupIndex" ::: Word32
v)))
newtype IndirectStateFlagBitsNV = IndirectStateFlagBitsNV Flags
deriving newtype (IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
(IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool)
-> (IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool)
-> Eq IndirectStateFlagsNV
forall a.
(a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> "isPreprocessed" ::: Bool) -> Eq a
/= :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
$c/= :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
== :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
$c== :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
Eq, Eq IndirectStateFlagsNV
Eq IndirectStateFlagsNV =>
(IndirectStateFlagsNV -> IndirectStateFlagsNV -> Ordering)
-> (IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool)
-> (IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool)
-> (IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool)
-> (IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool)
-> (IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV)
-> Ord IndirectStateFlagsNV
IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
IndirectStateFlagsNV -> IndirectStateFlagsNV -> Ordering
IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV
forall a.
Eq a =>
(a -> a -> Ordering)
-> (a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
min :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV
$cmin :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV
max :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV
$cmax :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV
>= :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
$c>= :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
> :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
$c> :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
<= :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
$c<= :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
< :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
$c< :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
compare :: IndirectStateFlagsNV -> IndirectStateFlagsNV -> Ordering
$ccompare :: IndirectStateFlagsNV -> IndirectStateFlagsNV -> Ordering
$cp1Ord :: Eq IndirectStateFlagsNV
Ord, Ptr b -> Int -> IO IndirectStateFlagsNV
Ptr b -> Int -> IndirectStateFlagsNV -> IO ()
Ptr IndirectStateFlagsNV -> IO IndirectStateFlagsNV
Ptr IndirectStateFlagsNV -> Int -> IO IndirectStateFlagsNV
Ptr IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV -> IO ()
Ptr IndirectStateFlagsNV -> IndirectStateFlagsNV -> IO ()
IndirectStateFlagsNV -> Int
(IndirectStateFlagsNV -> Int)
-> (IndirectStateFlagsNV -> Int)
-> (Ptr IndirectStateFlagsNV -> Int -> IO IndirectStateFlagsNV)
-> (Ptr IndirectStateFlagsNV
-> Int -> IndirectStateFlagsNV -> IO ())
-> (forall b. Ptr b -> Int -> IO IndirectStateFlagsNV)
-> (forall b. Ptr b -> Int -> IndirectStateFlagsNV -> IO ())
-> (Ptr IndirectStateFlagsNV -> IO IndirectStateFlagsNV)
-> (Ptr IndirectStateFlagsNV -> IndirectStateFlagsNV -> IO ())
-> Storable IndirectStateFlagsNV
forall b. Ptr b -> Int -> IO IndirectStateFlagsNV
forall b. Ptr b -> Int -> IndirectStateFlagsNV -> 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 IndirectStateFlagsNV -> IndirectStateFlagsNV -> IO ()
$cpoke :: Ptr IndirectStateFlagsNV -> IndirectStateFlagsNV -> IO ()
peek :: Ptr IndirectStateFlagsNV -> IO IndirectStateFlagsNV
$cpeek :: Ptr IndirectStateFlagsNV -> IO IndirectStateFlagsNV
pokeByteOff :: Ptr b -> Int -> IndirectStateFlagsNV -> IO ()
$cpokeByteOff :: forall b. Ptr b -> Int -> IndirectStateFlagsNV -> IO ()
peekByteOff :: Ptr b -> Int -> IO IndirectStateFlagsNV
$cpeekByteOff :: forall b. Ptr b -> Int -> IO IndirectStateFlagsNV
pokeElemOff :: Ptr IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV -> IO ()
$cpokeElemOff :: Ptr IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV -> IO ()
peekElemOff :: Ptr IndirectStateFlagsNV -> Int -> IO IndirectStateFlagsNV
$cpeekElemOff :: Ptr IndirectStateFlagsNV -> Int -> IO IndirectStateFlagsNV
alignment :: IndirectStateFlagsNV -> Int
$calignment :: IndirectStateFlagsNV -> Int
sizeOf :: IndirectStateFlagsNV -> Int
$csizeOf :: IndirectStateFlagsNV -> Int
Storable, IndirectStateFlagsNV
IndirectStateFlagsNV -> Zero IndirectStateFlagsNV
forall a. a -> Zero a
zero :: IndirectStateFlagsNV
$czero :: IndirectStateFlagsNV
Zero, Eq IndirectStateFlagsNV
IndirectStateFlagsNV
Eq IndirectStateFlagsNV =>
(IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV)
-> IndirectStateFlagsNV
-> (Int -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> Int -> "isPreprocessed" ::: Bool)
-> (IndirectStateFlagsNV -> Maybe Int)
-> (IndirectStateFlagsNV -> Int)
-> (IndirectStateFlagsNV -> "isPreprocessed" ::: Bool)
-> (IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV)
-> (IndirectStateFlagsNV -> Int)
-> Bits IndirectStateFlagsNV
Int -> IndirectStateFlagsNV
IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
IndirectStateFlagsNV -> Int
IndirectStateFlagsNV -> Maybe Int
IndirectStateFlagsNV -> IndirectStateFlagsNV
IndirectStateFlagsNV -> Int -> "isPreprocessed" ::: Bool
IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV
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 -> "isPreprocessed" ::: Bool)
-> (a -> Maybe Int)
-> (a -> Int)
-> (a -> "isPreprocessed" ::: Bool)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int -> a)
-> (a -> Int)
-> Bits a
popCount :: IndirectStateFlagsNV -> Int
$cpopCount :: IndirectStateFlagsNV -> Int
rotateR :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
$crotateR :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
rotateL :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
$crotateL :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
unsafeShiftR :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
$cunsafeShiftR :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
shiftR :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
$cshiftR :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
unsafeShiftL :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
$cunsafeShiftL :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
shiftL :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
$cshiftL :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
isSigned :: IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
$cisSigned :: IndirectStateFlagsNV -> "isPreprocessed" ::: Bool
bitSize :: IndirectStateFlagsNV -> Int
$cbitSize :: IndirectStateFlagsNV -> Int
bitSizeMaybe :: IndirectStateFlagsNV -> Maybe Int
$cbitSizeMaybe :: IndirectStateFlagsNV -> Maybe Int
testBit :: IndirectStateFlagsNV -> Int -> "isPreprocessed" ::: Bool
$ctestBit :: IndirectStateFlagsNV -> Int -> "isPreprocessed" ::: Bool
complementBit :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
$ccomplementBit :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
clearBit :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
$cclearBit :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
setBit :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
$csetBit :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
bit :: Int -> IndirectStateFlagsNV
$cbit :: Int -> IndirectStateFlagsNV
zeroBits :: IndirectStateFlagsNV
$czeroBits :: IndirectStateFlagsNV
rotate :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
$crotate :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
shift :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
$cshift :: IndirectStateFlagsNV -> Int -> IndirectStateFlagsNV
complement :: IndirectStateFlagsNV -> IndirectStateFlagsNV
$ccomplement :: IndirectStateFlagsNV -> IndirectStateFlagsNV
xor :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV
$cxor :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV
.|. :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV
$c.|. :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV
.&. :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV
$c.&. :: IndirectStateFlagsNV
-> IndirectStateFlagsNV -> IndirectStateFlagsNV
$cp1Bits :: Eq IndirectStateFlagsNV
Bits)
pattern $bINDIRECT_STATE_FLAG_FRONTFACE_BIT_NV :: IndirectStateFlagsNV
$mINDIRECT_STATE_FLAG_FRONTFACE_BIT_NV :: forall r. IndirectStateFlagsNV -> (Void# -> r) -> (Void# -> r) -> r
INDIRECT_STATE_FLAG_FRONTFACE_BIT_NV = IndirectStateFlagBitsNV 0x00000001
type IndirectStateFlagsNV = IndirectStateFlagBitsNV
instance Show IndirectStateFlagBitsNV where
showsPrec :: Int -> IndirectStateFlagsNV -> ShowS
showsPrec p :: Int
p = \case
INDIRECT_STATE_FLAG_FRONTFACE_BIT_NV -> String -> ShowS
showString "INDIRECT_STATE_FLAG_FRONTFACE_BIT_NV"
IndirectStateFlagBitsNV x :: "groupIndex" ::: Word32
x -> ("isPreprocessed" ::: Bool) -> ShowS -> ShowS
showParen (Int
p Int -> Int -> "isPreprocessed" ::: Bool
forall a. Ord a => a -> a -> "isPreprocessed" ::: Bool
>= 11) (String -> ShowS
showString "IndirectStateFlagBitsNV 0x" ShowS -> ShowS -> ShowS
forall b c a. (b -> c) -> (a -> b) -> a -> c
. ("groupIndex" ::: Word32) -> ShowS
forall a. (Integral a, Show a) => a -> ShowS
showHex "groupIndex" ::: Word32
x)
instance Read IndirectStateFlagBitsNV where
readPrec :: ReadPrec IndirectStateFlagsNV
readPrec = ReadPrec IndirectStateFlagsNV -> ReadPrec IndirectStateFlagsNV
forall a. ReadPrec a -> ReadPrec a
parens ([(String, ReadPrec IndirectStateFlagsNV)]
-> ReadPrec IndirectStateFlagsNV
forall a. [(String, ReadPrec a)] -> ReadPrec a
choose [("INDIRECT_STATE_FLAG_FRONTFACE_BIT_NV", IndirectStateFlagsNV -> ReadPrec IndirectStateFlagsNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure IndirectStateFlagsNV
INDIRECT_STATE_FLAG_FRONTFACE_BIT_NV)]
ReadPrec IndirectStateFlagsNV
-> ReadPrec IndirectStateFlagsNV -> ReadPrec IndirectStateFlagsNV
forall a. ReadPrec a -> ReadPrec a -> ReadPrec a
+++
Int
-> ReadPrec IndirectStateFlagsNV -> ReadPrec IndirectStateFlagsNV
forall a. Int -> ReadPrec a -> ReadPrec a
prec 10 (do
Lexeme -> ReadPrec ()
expectP (String -> Lexeme
Ident "IndirectStateFlagBitsNV")
"groupIndex" ::: Word32
v <- ReadPrec ("groupIndex" ::: Word32)
-> ReadPrec ("groupIndex" ::: Word32)
forall a. ReadPrec a -> ReadPrec a
step ReadPrec ("groupIndex" ::: Word32)
forall a. Read a => ReadPrec a
readPrec
IndirectStateFlagsNV -> ReadPrec IndirectStateFlagsNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (("groupIndex" ::: Word32) -> IndirectStateFlagsNV
IndirectStateFlagBitsNV "groupIndex" ::: Word32
v)))
newtype IndirectCommandsTokenTypeNV = IndirectCommandsTokenTypeNV Int32
deriving newtype (IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
(IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool)
-> (IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool)
-> Eq IndirectCommandsTokenTypeNV
forall a.
(a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> "isPreprocessed" ::: Bool) -> Eq a
/= :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
$c/= :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
== :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
$c== :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
Eq, Eq IndirectCommandsTokenTypeNV
Eq IndirectCommandsTokenTypeNV =>
(IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> Ordering)
-> (IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool)
-> (IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool)
-> (IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool)
-> (IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool)
-> (IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IndirectCommandsTokenTypeNV)
-> (IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IndirectCommandsTokenTypeNV)
-> Ord IndirectCommandsTokenTypeNV
IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> Ordering
IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IndirectCommandsTokenTypeNV
forall a.
Eq a =>
(a -> a -> Ordering)
-> (a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> "isPreprocessed" ::: Bool)
-> (a -> a -> a)
-> (a -> a -> a)
-> Ord a
min :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IndirectCommandsTokenTypeNV
$cmin :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IndirectCommandsTokenTypeNV
max :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IndirectCommandsTokenTypeNV
$cmax :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IndirectCommandsTokenTypeNV
>= :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
$c>= :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
> :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
$c> :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
<= :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
$c<= :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
< :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
$c< :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> "isPreprocessed" ::: Bool
compare :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> Ordering
$ccompare :: IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> Ordering
$cp1Ord :: Eq IndirectCommandsTokenTypeNV
Ord, Ptr b -> Int -> IO IndirectCommandsTokenTypeNV
Ptr b -> Int -> IndirectCommandsTokenTypeNV -> IO ()
Ptr IndirectCommandsTokenTypeNV -> IO IndirectCommandsTokenTypeNV
Ptr IndirectCommandsTokenTypeNV
-> Int -> IO IndirectCommandsTokenTypeNV
Ptr IndirectCommandsTokenTypeNV
-> Int -> IndirectCommandsTokenTypeNV -> IO ()
Ptr IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IO ()
IndirectCommandsTokenTypeNV -> Int
(IndirectCommandsTokenTypeNV -> Int)
-> (IndirectCommandsTokenTypeNV -> Int)
-> (Ptr IndirectCommandsTokenTypeNV
-> Int -> IO IndirectCommandsTokenTypeNV)
-> (Ptr IndirectCommandsTokenTypeNV
-> Int -> IndirectCommandsTokenTypeNV -> IO ())
-> (forall b. Ptr b -> Int -> IO IndirectCommandsTokenTypeNV)
-> (forall b. Ptr b -> Int -> IndirectCommandsTokenTypeNV -> IO ())
-> (Ptr IndirectCommandsTokenTypeNV
-> IO IndirectCommandsTokenTypeNV)
-> (Ptr IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IO ())
-> Storable IndirectCommandsTokenTypeNV
forall b. Ptr b -> Int -> IO IndirectCommandsTokenTypeNV
forall b. Ptr b -> Int -> IndirectCommandsTokenTypeNV -> 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 IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IO ()
$cpoke :: Ptr IndirectCommandsTokenTypeNV
-> IndirectCommandsTokenTypeNV -> IO ()
peek :: Ptr IndirectCommandsTokenTypeNV -> IO IndirectCommandsTokenTypeNV
$cpeek :: Ptr IndirectCommandsTokenTypeNV -> IO IndirectCommandsTokenTypeNV
pokeByteOff :: Ptr b -> Int -> IndirectCommandsTokenTypeNV -> IO ()
$cpokeByteOff :: forall b. Ptr b -> Int -> IndirectCommandsTokenTypeNV -> IO ()
peekByteOff :: Ptr b -> Int -> IO IndirectCommandsTokenTypeNV
$cpeekByteOff :: forall b. Ptr b -> Int -> IO IndirectCommandsTokenTypeNV
pokeElemOff :: Ptr IndirectCommandsTokenTypeNV
-> Int -> IndirectCommandsTokenTypeNV -> IO ()
$cpokeElemOff :: Ptr IndirectCommandsTokenTypeNV
-> Int -> IndirectCommandsTokenTypeNV -> IO ()
peekElemOff :: Ptr IndirectCommandsTokenTypeNV
-> Int -> IO IndirectCommandsTokenTypeNV
$cpeekElemOff :: Ptr IndirectCommandsTokenTypeNV
-> Int -> IO IndirectCommandsTokenTypeNV
alignment :: IndirectCommandsTokenTypeNV -> Int
$calignment :: IndirectCommandsTokenTypeNV -> Int
sizeOf :: IndirectCommandsTokenTypeNV -> Int
$csizeOf :: IndirectCommandsTokenTypeNV -> Int
Storable, IndirectCommandsTokenTypeNV
IndirectCommandsTokenTypeNV -> Zero IndirectCommandsTokenTypeNV
forall a. a -> Zero a
zero :: IndirectCommandsTokenTypeNV
$czero :: IndirectCommandsTokenTypeNV
Zero)
pattern $bINDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV :: IndirectCommandsTokenTypeNV
$mINDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV :: forall r.
IndirectCommandsTokenTypeNV -> (Void# -> r) -> (Void# -> r) -> r
INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV = IndirectCommandsTokenTypeNV 0
pattern $bINDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV :: IndirectCommandsTokenTypeNV
$mINDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV :: forall r.
IndirectCommandsTokenTypeNV -> (Void# -> r) -> (Void# -> r) -> r
INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV = IndirectCommandsTokenTypeNV 1
pattern $bINDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV :: IndirectCommandsTokenTypeNV
$mINDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV :: forall r.
IndirectCommandsTokenTypeNV -> (Void# -> r) -> (Void# -> r) -> r
INDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV = IndirectCommandsTokenTypeNV 2
pattern $bINDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV :: IndirectCommandsTokenTypeNV
$mINDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV :: forall r.
IndirectCommandsTokenTypeNV -> (Void# -> r) -> (Void# -> r) -> r
INDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV = IndirectCommandsTokenTypeNV 3
pattern $bINDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV :: IndirectCommandsTokenTypeNV
$mINDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV :: forall r.
IndirectCommandsTokenTypeNV -> (Void# -> r) -> (Void# -> r) -> r
INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV = IndirectCommandsTokenTypeNV 4
pattern $bINDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV :: IndirectCommandsTokenTypeNV
$mINDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV :: forall r.
IndirectCommandsTokenTypeNV -> (Void# -> r) -> (Void# -> r) -> r
INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV = IndirectCommandsTokenTypeNV 5
pattern $bINDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV :: IndirectCommandsTokenTypeNV
$mINDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV :: forall r.
IndirectCommandsTokenTypeNV -> (Void# -> r) -> (Void# -> r) -> r
INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV = IndirectCommandsTokenTypeNV 6
pattern $bINDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV :: IndirectCommandsTokenTypeNV
$mINDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV :: forall r.
IndirectCommandsTokenTypeNV -> (Void# -> r) -> (Void# -> r) -> r
INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV = IndirectCommandsTokenTypeNV 7
{-# complete INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV,
INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV,
INDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV,
INDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV,
INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV,
INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV,
INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV,
INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV :: IndirectCommandsTokenTypeNV #-}
instance Show IndirectCommandsTokenTypeNV where
showsPrec :: Int -> IndirectCommandsTokenTypeNV -> ShowS
showsPrec p :: Int
p = \case
INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV -> String -> ShowS
showString "INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV"
INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV -> String -> ShowS
showString "INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV"
INDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV -> String -> ShowS
showString "INDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV"
INDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV -> String -> ShowS
showString "INDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV"
INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV -> String -> ShowS
showString "INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV"
INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV -> String -> ShowS
showString "INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV"
INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV -> String -> ShowS
showString "INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV"
INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV -> String -> ShowS
showString "INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV"
IndirectCommandsTokenTypeNV x :: Int32
x -> ("isPreprocessed" ::: Bool) -> ShowS -> ShowS
showParen (Int
p Int -> Int -> "isPreprocessed" ::: Bool
forall a. Ord a => a -> a -> "isPreprocessed" ::: Bool
>= 11) (String -> ShowS
showString "IndirectCommandsTokenTypeNV " ShowS -> ShowS -> ShowS
forall b c a. (b -> c) -> (a -> b) -> a -> c
. Int -> Int32 -> ShowS
forall a. Show a => Int -> a -> ShowS
showsPrec 11 Int32
x)
instance Read IndirectCommandsTokenTypeNV where
readPrec :: ReadPrec IndirectCommandsTokenTypeNV
readPrec = ReadPrec IndirectCommandsTokenTypeNV
-> ReadPrec IndirectCommandsTokenTypeNV
forall a. ReadPrec a -> ReadPrec a
parens ([(String, ReadPrec IndirectCommandsTokenTypeNV)]
-> ReadPrec IndirectCommandsTokenTypeNV
forall a. [(String, ReadPrec a)] -> ReadPrec a
choose [("INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV", IndirectCommandsTokenTypeNV -> ReadPrec IndirectCommandsTokenTypeNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure IndirectCommandsTokenTypeNV
INDIRECT_COMMANDS_TOKEN_TYPE_SHADER_GROUP_NV)
, ("INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV", IndirectCommandsTokenTypeNV -> ReadPrec IndirectCommandsTokenTypeNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure IndirectCommandsTokenTypeNV
INDIRECT_COMMANDS_TOKEN_TYPE_STATE_FLAGS_NV)
, ("INDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV", IndirectCommandsTokenTypeNV -> ReadPrec IndirectCommandsTokenTypeNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure IndirectCommandsTokenTypeNV
INDIRECT_COMMANDS_TOKEN_TYPE_INDEX_BUFFER_NV)
, ("INDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV", IndirectCommandsTokenTypeNV -> ReadPrec IndirectCommandsTokenTypeNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure IndirectCommandsTokenTypeNV
INDIRECT_COMMANDS_TOKEN_TYPE_VERTEX_BUFFER_NV)
, ("INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV", IndirectCommandsTokenTypeNV -> ReadPrec IndirectCommandsTokenTypeNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure IndirectCommandsTokenTypeNV
INDIRECT_COMMANDS_TOKEN_TYPE_PUSH_CONSTANT_NV)
, ("INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV", IndirectCommandsTokenTypeNV -> ReadPrec IndirectCommandsTokenTypeNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure IndirectCommandsTokenTypeNV
INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_INDEXED_NV)
, ("INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV", IndirectCommandsTokenTypeNV -> ReadPrec IndirectCommandsTokenTypeNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure IndirectCommandsTokenTypeNV
INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_NV)
, ("INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV", IndirectCommandsTokenTypeNV -> ReadPrec IndirectCommandsTokenTypeNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure IndirectCommandsTokenTypeNV
INDIRECT_COMMANDS_TOKEN_TYPE_DRAW_TASKS_NV)]
ReadPrec IndirectCommandsTokenTypeNV
-> ReadPrec IndirectCommandsTokenTypeNV
-> ReadPrec IndirectCommandsTokenTypeNV
forall a. ReadPrec a -> ReadPrec a -> ReadPrec a
+++
Int
-> ReadPrec IndirectCommandsTokenTypeNV
-> ReadPrec IndirectCommandsTokenTypeNV
forall a. Int -> ReadPrec a -> ReadPrec a
prec 10 (do
Lexeme -> ReadPrec ()
expectP (String -> Lexeme
Ident "IndirectCommandsTokenTypeNV")
Int32
v <- ReadPrec Int32 -> ReadPrec Int32
forall a. ReadPrec a -> ReadPrec a
step ReadPrec Int32
forall a. Read a => ReadPrec a
readPrec
IndirectCommandsTokenTypeNV -> ReadPrec IndirectCommandsTokenTypeNV
forall (f :: * -> *) a. Applicative f => a -> f a
pure (Int32 -> IndirectCommandsTokenTypeNV
IndirectCommandsTokenTypeNV Int32
v)))
type NV_DEVICE_GENERATED_COMMANDS_SPEC_VERSION = 3
pattern NV_DEVICE_GENERATED_COMMANDS_SPEC_VERSION :: forall a . Integral a => a
pattern $bNV_DEVICE_GENERATED_COMMANDS_SPEC_VERSION :: a
$mNV_DEVICE_GENERATED_COMMANDS_SPEC_VERSION :: forall r a. Integral a => a -> (Void# -> r) -> (Void# -> r) -> r
NV_DEVICE_GENERATED_COMMANDS_SPEC_VERSION = 3
type NV_DEVICE_GENERATED_COMMANDS_EXTENSION_NAME = "VK_NV_device_generated_commands"
pattern NV_DEVICE_GENERATED_COMMANDS_EXTENSION_NAME :: forall a . (Eq a, IsString a) => a
pattern $bNV_DEVICE_GENERATED_COMMANDS_EXTENSION_NAME :: a
$mNV_DEVICE_GENERATED_COMMANDS_EXTENSION_NAME :: forall r a.
(Eq a, IsString a) =>
a -> (Void# -> r) -> (Void# -> r) -> r
NV_DEVICE_GENERATED_COMMANDS_EXTENSION_NAME = "VK_NV_device_generated_commands"