vulkan-api-1.3.0.0: Low-level low-overhead vulkan api bindings

Safe HaskellNone
LanguageHaskell2010

Graphics.Vulkan.Marshal

Contents

Description

This module is not part of auto-generated code based on vk.xml. Instead, it is hand-written to provide common types and classes.

Synopsis

Documentation

data FlagType Source #

Distinguish single bits and bitmasks in vulkan flags

Constructors

FlagMask 
FlagBit 

type FlagMask = FlagMask Source #

Vulkan flags type that can have multiple bits set.

type FlagBit = FlagBit Source #

Vulkan single bit flag value.

bitToMask :: Coercible (x FlagBit) (x FlagMask) => x FlagBit -> x FlagMask Source #

Convert a single bit (XxxBits) to a bitmask (XxxFlags)

maskToBits :: (Bits (x FlagMask), Coercible (x FlagBit) (x FlagMask)) => x FlagMask -> [x FlagBit] Source #

List all set bits of a bitmask (XxxFlags) in the increasing order.

class (VulkanStruct (StructRep a), IsVkStruct a) => VulkanMarshal a Source #

All Vulkan structures are stored as-is in byte arrays to avoid any overheads for wrapping and unwrapping haskell values. VulkanMarshal provides an interfaces to write and read these structures in an imperative way.

Associated Types

type StructRep a :: StructMeta Source #

Instances
VulkanMarshal VkAcquireNextImageInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.AcquireNextImageInfoKHR

VulkanMarshal VkApplicationInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.ApplicationInfo

VulkanMarshal VkBaseOutStructure Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Base

VulkanMarshal VkBaseInStructure Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Base

VulkanMarshal VkCommandPoolCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Command

VulkanMarshal VkCommandBufferInheritanceInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Command

VulkanMarshal VkCommandBufferBeginInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Command

VulkanMarshal VkCommandBufferAllocateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Command

VulkanMarshal VkComponentMapping Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.ComponentMapping

VulkanMarshal VkCopyDescriptorSet Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.CopyDescriptorSet

VulkanMarshal VkDebugUtilsLabelEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.DebugUtilsLabelEXT

VulkanMarshal VkDebugUtilsObjectNameInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.DebugUtilsObjectNameInfoEXT

VulkanMarshal VkDebugUtilsMessengerCallbackDataEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.DebugUtilsMessengerCallbackDataEXT

VulkanMarshal VkAllocationCallbacks Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.AllocationCallbacks

VulkanMarshal VkDescriptorUpdateTemplateEntry Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDescriptorUpdateTemplateCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDescriptorSetVariableDescriptorCountLayoutSupportEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDescriptorSetVariableDescriptorCountAllocateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDescriptorSetLayoutSupport Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDescriptorSetLayoutCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDescriptorSetLayoutBindingFlagsCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDescriptorSetLayoutBinding Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDescriptorSetAllocateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDescriptorPoolSize Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDescriptorPoolCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDescriptorImageInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDescriptorBufferInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Descriptor

VulkanMarshal VkDispatchIndirectCommand Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.DispatchIndirectCommand

VulkanMarshal VkDrawIndirectCommand Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.DrawInd

VulkanMarshal VkDrawIndexedIndirectCommand Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.DrawInd

VulkanMarshal VkEventCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.EventCreateInfo

VulkanMarshal VkExtensionProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.ExtensionProperties

VulkanMarshal VkExtent3D Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Extent

Associated Types

type StructRep VkExtent3D :: StructMeta Source #

VulkanMarshal VkExtent2D Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Extent

Associated Types

type StructRep VkExtent2D :: StructMeta Source #

VulkanMarshal VkFenceGetFdInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Fence

VulkanMarshal VkFenceCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Fence

VulkanMarshal VkFormatProperties2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.FormatProperties

VulkanMarshal VkFormatProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.FormatProperties

VulkanMarshal VkFramebufferCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.FramebufferCreateInfo

VulkanMarshal VkIndirectCommandsTokenNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.IndirectCommands

VulkanMarshal VkIndirectCommandsLayoutTokenNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.IndirectCommands

VulkanMarshal VkIndirectCommandsLayoutCreateInfoNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.IndirectCommands

VulkanMarshal VkCmdReserveSpaceForCommandsInfoNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Cmd

VulkanMarshal VkCmdProcessCommandsInfoNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Cmd

VulkanMarshal VkInputAttachmentAspectReference Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.InputAttachmentAspectReference

VulkanMarshal VkInstanceCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.InstanceCreateInfo

VulkanMarshal VkDebugUtilsMessengerCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.DebugUtilsMessengerCreateInfoEXT

VulkanMarshal VkDebugUtilsObjectTagInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Debug

VulkanMarshal VkDebugReportCallbackCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Debug

VulkanMarshal VkDebugMarkerObjectTagInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Debug

VulkanMarshal VkDebugMarkerObjectNameInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Debug

VulkanMarshal VkDebugMarkerMarkerInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Debug

VulkanMarshal VkLayerProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.LayerProperties

VulkanMarshal VkMappedMemoryRange Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.MappedMemoryRange

VulkanMarshal VkMemoryType Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Memory

Associated Types

type StructRep VkMemoryType :: StructMeta Source #

VulkanMarshal VkMemoryRequirements2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Memory

VulkanMarshal VkMemoryRequirements Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Memory

VulkanMarshal VkMemoryHostPointerPropertiesEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Memory

VulkanMarshal VkMemoryHeap Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Memory

Associated Types

type StructRep VkMemoryHeap :: StructMeta Source #

VulkanMarshal VkMemoryGetFdInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Memory

VulkanMarshal VkMemoryFdPropertiesKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Memory

VulkanMarshal VkMemoryDedicatedRequirements Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Memory

VulkanMarshal VkMemoryDedicatedAllocateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Memory

VulkanMarshal VkMemoryBarrier Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Memory

Associated Types

type StructRep VkMemoryBarrier :: StructMeta Source #

VulkanMarshal VkMemoryAllocateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Memory

VulkanMarshal VkMemoryAllocateFlagsInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Memory

VulkanMarshal VkImportSemaphoreFdInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Import

VulkanMarshal VkImportMemoryHostPointerInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Import

VulkanMarshal VkImportMemoryFdInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Import

VulkanMarshal VkImportFenceFdInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Import

VulkanMarshal VkMultisamplePropertiesEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.MultisamplePropertiesEXT

VulkanMarshal VkObjectTableVertexBufferEntryNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.ObjectTable

VulkanMarshal VkObjectTablePushConstantEntryNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.ObjectTable

VulkanMarshal VkObjectTablePipelineEntryNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.ObjectTable

VulkanMarshal VkObjectTableIndexBufferEntryNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.ObjectTable

VulkanMarshal VkObjectTableEntryNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.ObjectTable

VulkanMarshal VkObjectTableDescriptorSetEntryNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.ObjectTable

VulkanMarshal VkObjectTableCreateInfoNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.ObjectTable

VulkanMarshal VkOffset3D Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Offset

Associated Types

type StructRep VkOffset3D :: StructMeta Source #

VulkanMarshal VkOffset2D Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Offset

Associated Types

type StructRep VkOffset2D :: StructMeta Source #

VulkanMarshal VkImageViewUsageCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageViewCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageSwapchainCreateInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageSubresourceRange Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageSubresourceLayers Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageSubresource Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageSparseMemoryRequirementsInfo2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageResolve Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

Associated Types

type StructRep VkImageResolve :: StructMeta Source #

VulkanMarshal VkImagePlaneMemoryRequirementsInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageMemoryRequirementsInfo2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageMemoryBarrier Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageFormatProperties2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageFormatProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageFormatListCreateInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

VulkanMarshal VkImageCopy Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

Associated Types

type StructRep VkImageCopy :: StructMeta Source #

VulkanMarshal VkImageBlit Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Image

Associated Types

type StructRep VkImageBlit :: StructMeta Source #

VulkanMarshal VkBufferViewCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Buffer

VulkanMarshal VkBufferMemoryRequirementsInfo2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Buffer

VulkanMarshal VkBufferMemoryBarrier Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Buffer

VulkanMarshal VkBufferImageCopy Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Buffer

VulkanMarshal VkBufferCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Buffer

VulkanMarshal VkBufferCopy Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Buffer

Associated Types

type StructRep VkBufferCopy :: StructMeta Source #

VulkanMarshal VkExternalSemaphoreProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.External

VulkanMarshal VkExternalMemoryProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.External

VulkanMarshal VkExternalMemoryImageCreateInfoNV Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.External

VulkanMarshal VkExternalMemoryImageCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.External

VulkanMarshal VkExternalMemoryBufferCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.External

VulkanMarshal VkExternalImageFormatPropertiesNV Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.External

VulkanMarshal VkExternalImageFormatProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.External

VulkanMarshal VkExternalFenceProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.External

VulkanMarshal VkExternalBufferProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.External

VulkanMarshal VkDedicatedAllocationMemoryAllocateInfoNV Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.DedicatedAllocation

VulkanMarshal VkDedicatedAllocationImageCreateInfoNV Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.DedicatedAllocation

VulkanMarshal VkDedicatedAllocationBufferCreateInfoNV Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.DedicatedAllocation

VulkanMarshal VkPastPresentationTimingGOOGLE Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PastPresentationTimingGOOGLE

VulkanMarshal VkPhysicalDeviceFeatures Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDeviceFeatures

VulkanMarshal VkPushConstantRange Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PushConstantRange

VulkanMarshal VkQueryPoolCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.QueryPoolCreateInfo

VulkanMarshal VkQueueFamilyProperties2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.QueueFamilyProperties

VulkanMarshal VkQueueFamilyProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.QueueFamilyProperties

VulkanMarshal VkRectLayerKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Rect

Associated Types

type StructRep VkRectLayerKHR :: StructMeta Source #

VulkanMarshal VkRect2D Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Rect

Associated Types

type StructRep VkRect2D :: StructMeta Source #

VulkanMarshal VkPresentTimesInfoGOOGLE Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Present

VulkanMarshal VkPresentTimeGOOGLE Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Present

VulkanMarshal VkPresentRegionsKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Present

VulkanMarshal VkPresentRegionKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Present

VulkanMarshal VkPresentInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Present

Associated Types

type StructRep VkPresentInfoKHR :: StructMeta Source #

VulkanMarshal VkDisplaySurfaceCreateInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayPropertiesKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayProperties2KHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayPresentInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayPowerInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayPlanePropertiesKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayPlaneProperties2KHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayPlaneInfo2KHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayPlaneCapabilitiesKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayPlaneCapabilities2KHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayModePropertiesKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayModeProperties2KHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayModeParametersKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayModeCreateInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkDisplayEventInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Display

VulkanMarshal VkClearValue Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Clear

Associated Types

type StructRep VkClearValue :: StructMeta Source #

VulkanMarshal VkClearRect Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Clear

Associated Types

type StructRep VkClearRect :: StructMeta Source #

VulkanMarshal VkClearDepthStencilValue Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Clear

VulkanMarshal VkClearColorValue Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Clear

VulkanMarshal VkClearAttachment Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Clear

VulkanMarshal VkRefreshCycleDurationGOOGLE Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.RefreshCycleDurationGOOGLE

VulkanMarshal VkSampleLocationsInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.SampleLocation

VulkanMarshal VkSampleLocationEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.SampleLocation

VulkanMarshal VkAttachmentSampleLocationsEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Attachment

VulkanMarshal VkAttachmentReference Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Attachment

VulkanMarshal VkAttachmentDescription Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Attachment

VulkanMarshal VkSamplerYcbcrConversionInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sampler

VulkanMarshal VkSamplerYcbcrConversionImageFormatProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sampler

VulkanMarshal VkSamplerYcbcrConversionCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sampler

VulkanMarshal VkSamplerReductionModeCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sampler

VulkanMarshal VkSamplerCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sampler

VulkanMarshal VkSemaphoreGetFdInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Semaphore

VulkanMarshal VkSemaphoreCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Semaphore

VulkanMarshal VkExportSemaphoreCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Export

VulkanMarshal VkExportMemoryAllocateInfoNV Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Export

VulkanMarshal VkExportMemoryAllocateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Export

VulkanMarshal VkExportFenceCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Export

VulkanMarshal VkShaderStatisticsInfoAMD Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Shader

VulkanMarshal VkShaderResourceUsageAMD Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Shader

VulkanMarshal VkShaderModuleValidationCacheCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Shader

VulkanMarshal VkShaderModuleCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Shader

VulkanMarshal VkSparseMemoryBind Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sparse

VulkanMarshal VkSparseImageOpaqueMemoryBindInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sparse

VulkanMarshal VkSparseImageMemoryRequirements2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sparse

VulkanMarshal VkSparseImageMemoryRequirements Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sparse

VulkanMarshal VkSparseImageMemoryBindInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sparse

VulkanMarshal VkSparseImageMemoryBind Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sparse

VulkanMarshal VkSparseImageFormatProperties2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sparse

VulkanMarshal VkSparseImageFormatProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sparse

VulkanMarshal VkSparseBufferMemoryBindInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Sparse

VulkanMarshal VkBindSparseInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Bind

Associated Types

type StructRep VkBindSparseInfo :: StructMeta Source #

VulkanMarshal VkBindImagePlaneMemoryInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Bind

VulkanMarshal VkBindImageMemorySwapchainInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Bind

VulkanMarshal VkBindImageMemoryInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Bind

VulkanMarshal VkBindImageMemoryDeviceGroupInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Bind

VulkanMarshal VkBindBufferMemoryInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Bind

VulkanMarshal VkBindBufferMemoryDeviceGroupInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Bind

VulkanMarshal VkSpecializationMapEntry Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Specialization

VulkanMarshal VkSpecializationInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Specialization

VulkanMarshal VkStencilOpState Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.StencilOpState

Associated Types

type StructRep VkStencilOpState :: StructMeta Source #

VulkanMarshal VkSubmitInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.SubmitInfo

Associated Types

type StructRep VkSubmitInfo :: StructMeta Source #

VulkanMarshal VkProtectedSubmitInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.ProtectedSubmitInfo

VulkanMarshal VkSubpassSampleLocationsEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Subpass

VulkanMarshal VkSubpassDescription Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Subpass

VulkanMarshal VkSubpassDependency Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Subpass

VulkanMarshal VkRenderPassSampleLocationsBeginInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.RenderPass

VulkanMarshal VkRenderPassMultiviewCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.RenderPass

VulkanMarshal VkRenderPassInputAttachmentAspectCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.RenderPass

VulkanMarshal VkRenderPassCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.RenderPass

VulkanMarshal VkRenderPassBeginInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.RenderPass

VulkanMarshal VkSubresourceLayout Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.SubresourceLayout

VulkanMarshal VkSurfaceFormatKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Surface

VulkanMarshal VkSurfaceFormat2KHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Surface

VulkanMarshal VkSurfaceCapabilitiesKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Surface

VulkanMarshal VkSurfaceCapabilities2KHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Surface

VulkanMarshal VkSurfaceCapabilities2EXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Surface

VulkanMarshal VkSharedPresentSurfaceCapabilitiesKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.SharedPresentSurfaceCapabilitiesKHR

VulkanMarshal VkSwapchainCreateInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.SwapchainC

VulkanMarshal VkSwapchainCounterCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.SwapchainC

VulkanMarshal VkDeviceQueueInfo2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceQueueGlobalPriorityCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceQueueCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceGroupSwapchainCreateInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceGroupSubmitInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceGroupRenderPassBeginInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceGroupPresentInfoKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceGroupPresentCapabilitiesKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceGroupDeviceCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceGroupCommandBufferBeginInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceGroupBindSparseInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceGeneratedCommandsLimitsNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceGeneratedCommandsFeaturesNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceEventInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkDeviceCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Device

VulkanMarshal VkPhysicalDeviceVertexAttributeDivisorPropertiesEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceVariablePointerFeatures Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceSurfaceInfo2KHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceSubgroupProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceSparseProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceSparseImageFormatInfo2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceShaderDrawParameterFeatures Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceShaderCorePropertiesAMD Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceSamplerYcbcrConversionFeatures Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceSamplerFilterMinmaxPropertiesEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceSampleLocationsPropertiesEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDevicePushDescriptorPropertiesKHR Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceProtectedMemoryProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceProtectedMemoryFeatures Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceProperties2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDevicePointClippingProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceMultiviewProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceMultiviewPerViewAttributesPropertiesNVX Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceMultiviewFeatures Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceMemoryProperties2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceMemoryProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceMaintenance3Properties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceLimits Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceImageFormatInfo2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceIDProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceGroupProperties Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceFeatures2 Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceExternalSemaphoreInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceExternalMemoryHostPropertiesEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceExternalImageFormatInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceExternalFenceInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceExternalBufferInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceDiscardRectanglePropertiesEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceDescriptorIndexingPropertiesEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceDescriptorIndexingFeaturesEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceConservativeRasterizationPropertiesEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceBlendOperationAdvancedPropertiesEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDeviceBlendOperationAdvancedFeaturesEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkPhysicalDevice16BitStorageFeatures Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.PhysicalDevice

VulkanMarshal VkTextureLODGatherFormatPropertiesAMD Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.TextureLODGatherFormatPropertiesAMD

VulkanMarshal VkValidationFlagsEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Validation

VulkanMarshal VkValidationCacheCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Validation

VulkanMarshal VkVertexInputBindingDivisorDescriptionEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.VertexInput

VulkanMarshal VkVertexInputBindingDescription Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.VertexInput

VulkanMarshal VkVertexInputAttributeDescription Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.VertexInput

VulkanMarshal VkViewportWScalingNV Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Viewport

VulkanMarshal VkViewportSwizzleNV Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Viewport

VulkanMarshal VkViewport Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Viewport

Associated Types

type StructRep VkViewport :: StructMeta Source #

VulkanMarshal VkPipelineViewportWScalingStateCreateInfoNV Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineViewportSwizzleStateCreateInfoNV Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineViewportStateCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineVertexInputStateCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineVertexInputDivisorStateCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineTessellationStateCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineTessellationDomainOriginStateCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineShaderStageCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineSampleLocationsStateCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineRasterizationStateRasterizationOrderAMD Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineRasterizationStateCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineRasterizationConservativeStateCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineMultisampleStateCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineLayoutCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineInputAssemblyStateCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineDynamicStateCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineDiscardRectangleStateCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineDepthStencilStateCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineCoverageToColorStateCreateInfoNV Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineCoverageModulationStateCreateInfoNV Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineColorBlendStateCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineColorBlendAttachmentState Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineColorBlendAdvancedStateCreateInfoEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkPipelineCacheCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkGraphicsPipelineCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.Pipeline

VulkanMarshal VkComputePipelineCreateInfo Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.ComputePipelineCreateInfo

VulkanMarshal VkWriteDescriptorSet Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.WriteDescriptorSet

VulkanMarshal VkXYColorEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.XYColorEXT

Associated Types

type StructRep VkXYColorEXT :: StructMeta Source #

VulkanMarshal VkHdrMetadataEXT Source # 
Instance details

Defined in Graphics.Vulkan.Types.Struct.HdrMetadataEXT

Associated Types

type StructRep VkHdrMetadataEXT :: StructMeta Source #

newVkData :: forall a. VulkanMarshal a => (Ptr a -> IO ()) -> IO a Source #

Allocate a pinned aligned byte array to keep vulkan data structure and fill it using a foreign function.

Note, the function is supposed to use newAlignedPinnedByteArray# and does not guarantee to fill memory with zeroes. Use clearStorable to make sure all bytes are set to zero.

Note, the memory is managed by GHC, thus no need for freeing it manually.

mallocVkData :: forall a. VulkanMarshal a => IO a Source #

Allocate a pinned aligned byte array to keep vulkan data structure.

Note, the function is supposed to use newAlignedPinnedByteArray# and does not guarantee to fill memory with zeroes. Use clearStorable to make sure all bytes are set to zero.

Note, the memory is managed by GHC, thus no need for freeing it manually.

mallocVkDataArray :: forall a. VulkanMarshal a => Int -> IO (Ptr a, [a]) Source #

Allocate a pinned aligned byte array to keep vulkan data structures. Returned `Ptr a` points to the first element in the contiguous array of returned structures. Returned list elements point to the same memory area. This function is unsafe in two ways:

  • Several structures are stored next to each other, with no gaps; it would break its alignment if the size is not multiple of alignment.
  • Returned pointer is not tracked by GHC as a reference to the managed memory. Thus, the array can be GCed if all references to the returned list are lost.

Note, the function is supposed to use newAlignedPinnedByteArray# and does not guarantee to fill memory with zeroes. Use clearStorable to make sure all bytes are set to zero.

Note, the memory is managed by GHC, thus no need for freeing it manually.

unsafePtr :: IsVkStruct a => a -> Ptr a Source #

Get pointer to vulkan structure. Note, the address is only valid as long as a given vulkan structure exists. Structures created with newVkData are stored in pinned byte arrays, so their memory is maintained by Haskell GC.

fromForeignPtr :: forall a. VulkanMarshal a => ForeignPtr a -> IO a Source #

Get vulkan structure referenced by a ForeignPtr trying to avoid copying data.

This function does copy data if called on an unmanaged ForeignPtr (i.e. one created from ordinary Ptr using something like newForeignPtr.).

This function does not copy data if called on a managed ForeignPtr (i.e. one created using mallocForeignPtr, or toForeignPtr, or toPlainForeignPtr).

Note, fromForeignPtr does not copy finalizers of ForeignPtr. Thus, if all references to original ForeignPtr are lost, its attached finalizers may run even if the created structure is alive.

toForeignPtr :: IsVkStruct a => a -> IO (ForeignPtr a) Source #

Create a ForeignPtr referencing the structure without copying data.

toPlainForeignPtr :: IsVkStruct a => a -> IO (ForeignPtr a) Source #

Create a ForeignPtr referencing the structure without copying data. This version of a pointer carries no finalizers.

It is not possible to add a finalizer to a ForeignPtr created with toPlainForeignPtr. Attempts to add a finalizer to a ForeignPtr created this way, or to finalize such a pointer, will throw an exception.

touchVkData :: IsVkStruct a => a -> IO () Source #

Make sure this data is alive at a given point in a sequence of IO actions.

class VulkanPtr ptr where Source #

Unify dispatchable and non-dispatchable vulkan pointer types.

Dispatchable handles are represented as Ptr.

Non-dispatchable handles are represented as VkPtr.

Methods

vkNullPtr :: ptr a Source #

Instances
VulkanPtr Ptr Source # 
Instance details

Defined in Graphics.Vulkan.Marshal

Methods

vkNullPtr :: Ptr a Source #

VulkanPtr VkPtr Source # 
Instance details

Defined in Graphics.Vulkan.Marshal

Methods

vkNullPtr :: VkPtr a Source #

newtype VkPtr a Source #

VK_DEFINE_NON_DISPATCHABLE_HANDLE

Non-dispatchable handles are represented as VkPtr

Represented as Word64

#if !defined(VK_DEFINE_NON_DISPATCHABLE_HANDLE)
#if defined(__LP64__) || defined(_WIN64) || (defined(__x86_64__) && !defined(__ILP32__) ) || defined(_M_X64) || defined(__ia64) || defined (_M_IA64) || defined(__aarch64__) || defined(__powerpc64__)
        #define VK_DEFINE_NON_DISPATCHABLE_HANDLE(object) typedef struct object##_T *object;
#else
        #define VK_DEFINE_NON_DISPATCHABLE_HANDLE(object) typedef uint64_t object;
#endif
#endif

Constructors

VkPtr Word64 
Instances
VulkanPtr VkPtr Source # 
Instance details

Defined in Graphics.Vulkan.Marshal

Methods

vkNullPtr :: VkPtr a Source #

Eq (VkPtr a) Source # 
Instance details

Defined in Graphics.Vulkan.Marshal

Methods

(==) :: VkPtr a -> VkPtr a -> Bool #

(/=) :: VkPtr a -> VkPtr a -> Bool #

Ord (VkPtr a) Source # 
Instance details

Defined in Graphics.Vulkan.Marshal

Methods

compare :: VkPtr a -> VkPtr a -> Ordering #

(<) :: VkPtr a -> VkPtr a -> Bool #

(<=) :: VkPtr a -> VkPtr a -> Bool #

(>) :: VkPtr a -> VkPtr a -> Bool #

(>=) :: VkPtr a -> VkPtr a -> Bool #

max :: VkPtr a -> VkPtr a -> VkPtr a #

min :: VkPtr a -> VkPtr a -> VkPtr a #

Show (VkPtr a) Source # 
Instance details

Defined in Graphics.Vulkan.Marshal

Methods

showsPrec :: Int -> VkPtr a -> ShowS #

show :: VkPtr a -> String #

showList :: [VkPtr a] -> ShowS #

Storable (VkPtr a) Source # 
Instance details

Defined in Graphics.Vulkan.Marshal

Methods

sizeOf :: VkPtr a -> Int #

alignment :: VkPtr a -> Int #

peekElemOff :: Ptr (VkPtr a) -> Int -> IO (VkPtr a) #

pokeElemOff :: Ptr (VkPtr a) -> Int -> VkPtr a -> IO () #

peekByteOff :: Ptr b -> Int -> IO (VkPtr a) #

pokeByteOff :: Ptr b -> Int -> VkPtr a -> IO () #

peek :: Ptr (VkPtr a) -> IO (VkPtr a) #

poke :: Ptr (VkPtr a) -> VkPtr a -> IO () #

pattern VK_ZERO_FLAGS :: Bits a => a Source #

A synonym for zeroBits

pattern VK_NULL_HANDLE :: (Eq (ptr a), VulkanPtr ptr) => ptr a Source #

#define VK_NULL_HANDLE 0

pattern VK_NULL :: (Eq (ptr a), VulkanPtr ptr) => ptr a Source #

Null pointer (either dispatchable or non-dispatchable)

clearStorable :: Storable a => Ptr a -> IO () Source #

Fill all bytes to zero getting data size from Storable instance.

withPtr :: VulkanMarshal a => a -> (Ptr a -> IO b) -> IO b Source #

Run some operation with a pointer to vulkan structure.

Should be used with care: the structure pretends to be immutable, so it is better to only read from the pointed memory area, not to write. If an action needs to write something to the pointer, use newVkData.

Type-indexed access to struct members

type StructFields a = SFields (StructRep a) Source #

Descriptions of all fields of a vulkan struct

type CUnionType a = SIsUnion (StructRep a) Source #

Whether this type is a C union. Otherwise this is a C structure.

type ReturnedOnly a = SIsReturnedOnly (StructRep a) Source #

Notes that this struct or union is going to be filled in by the API, rather than an application filling it out and passing it to the API.

type StructExtends a = SStructExtends (StructRep a) Source #

Comma-separated list of structures whose "pNext" can include this type.

type StructFieldNames (a :: Type) = FieldNames (StructFields a) Source #

type HasField (fname :: Symbol) (a :: Type) = (VulkanMarshal a, VulkanField (FieldRep fname a)) Source #

A Constraint: a vulkan struct must have a field with a given name.

type FieldRep (fname :: Symbol) (a :: Type) = GetFieldMeta (ErrorNoSuchField fname a) fname (StructFields a) Source #

Type-level description of a Vulkan structure field.

type FieldType (fname :: Symbol) (a :: Type) = FType (FieldRep fname a) Source #

Type of a field in a vulkan structure or union.

type FieldOptional (fname :: Symbol) (a :: Type) = FOptional (FieldRep fname a) Source #

Whether this field marked optional in vulkan specification. Usually, this means that VK_NULL can be written in place of this field.

type FieldOffset (fname :: Symbol) (a :: Type) = FByteOffset (FieldRep fname a) Source #

Offset of a field in bytes.

type FieldIsArray (fname :: Symbol) (a :: Type) = IsArrayLen (FLength (FieldRep fname a)) Source #

Whether this field is a fixed-length array stored directly in a struct.

type FieldArrayLength (fname :: Symbol) (a :: Type) = FLength (FieldRep fname a) Source #

Length of an array that is a field of a structure or union

type CanReadField (fname :: Symbol) (a :: Type) = (HasField fname a, IsTrue (ErrorNotReadableField fname a) (FCanRead (FieldRep fname a)), Storable (FieldType fname a)) Source #

type CanWriteField (fname :: Symbol) (a :: Type) = (HasField fname a, IsTrue (ErrorNotWritableField fname a) (FCanWrite (FieldRep fname a)), Storable (FieldType fname a)) Source #

type CanReadFieldArray (fname :: Symbol) (a :: Type) = CanReadField fname a Source #

type CanWriteFieldArray (fname :: Symbol) (a :: Type) = CanWriteField fname a Source #

fieldOptional :: forall (fname :: Symbol) (a :: Type). HasField fname a => Bool Source #

Whether this field marked optional in vulkan specification. Usually, this means that VK_NULL can be written in place of this field.

fieldOffset :: forall (fname :: Symbol) (a :: Type). HasField fname a => Int Source #

Offset of a field in bytes.

fieldArrayLength :: forall (fname :: Symbol) (a :: Type). HasField fname a => Int Source #

Length of an array that is a field of a structure or union.

Returns 1 if this field is not an array.

getField :: forall (fname :: Symbol) (a :: Type). CanReadField fname a => a -> FieldType fname a Source #

readField :: forall (fname :: Symbol) (a :: Type). CanReadField fname a => Ptr a -> IO (FieldType fname a) Source #

writeField :: forall (fname :: Symbol) (a :: Type). CanWriteField fname a => Ptr a -> FieldType fname a -> IO () Source #

getFieldArrayUnsafe :: forall (fname :: Symbol) (a :: Type). CanReadFieldArray fname a => Int -> a -> FieldType fname a Source #

Index an array-type field. No bound checks.

readFieldArrayUnsafe :: forall (fname :: Symbol) (a :: Type). CanReadFieldArray fname a => Int -> Ptr a -> IO (FieldType fname a) Source #

Read from an array-type field. No bound checks.

writeFieldArrayUnsafe :: forall (fname :: Symbol) (a :: Type). CanWriteFieldArray fname a => Int -> Ptr a -> FieldType fname a -> IO () Source #

Write to an array-type field. No bound checks.

getFieldArray :: forall fname idx a. (CanReadFieldArray fname a, IndexInBounds fname idx a, KnownNat idx) => a -> FieldType fname a Source #

readFieldArray :: forall fname idx a. (CanReadFieldArray fname a, IndexInBounds fname idx a, KnownNat idx) => Ptr a -> IO (FieldType fname a) Source #

writeFieldArray :: forall fname idx a. (CanWriteFieldArray fname a, IndexInBounds fname idx a, KnownNat idx) => Ptr a -> FieldType fname a -> IO () Source #

type IndexInBounds (s :: Symbol) (i :: Nat) (a :: Type) = IndexInBounds' s i a (CmpNat i (FieldArrayLength s a)) Source #

Type-level info about Structs

class VulkanFields (SFields m) => VulkanStruct (m :: StructMeta) where Source #

Associated Types

type SName m :: Symbol Source #

type SType m :: Type Source #

type SSize m :: Nat Source #

type SAlign m :: Nat Source #

type SFields m :: [FieldMeta] Source #

type SIsUnion m :: Bool Source #

type SIsReturnedOnly m :: Bool Source #

type SStructExtends m :: [Type] Source #

Instances
(KnownSymbol structName, KnownNat size, KnownNat alignment, VulkanFields fields, KnownBool isUnion, KnownBool isReturnedOnly) => VulkanStruct (StructMeta structName structType size alignment fields isUnion isReturnedOnly structExtends) Source # 
Instance details

Defined in Graphics.Vulkan.Marshal.Internal

Associated Types

type SName (StructMeta structName structType size alignment fields isUnion isReturnedOnly structExtends) :: Symbol Source #

type SType (StructMeta structName structType size alignment fields isUnion isReturnedOnly structExtends) :: Type Source #

type SSize (StructMeta structName structType size alignment fields isUnion isReturnedOnly structExtends) :: Nat Source #

type SAlign (StructMeta structName structType size alignment fields isUnion isReturnedOnly structExtends) :: Nat Source #

type SFields (StructMeta structName structType size alignment fields isUnion isReturnedOnly structExtends) :: [FieldMeta] Source #

type SIsUnion (StructMeta structName structType size alignment fields isUnion isReturnedOnly structExtends) :: Bool Source #

type SIsReturnedOnly (StructMeta structName structType size alignment fields isUnion isReturnedOnly structExtends) :: Bool Source #

type SStructExtends (StructMeta structName structType size alignment fields isUnion isReturnedOnly structExtends) :: [Type] Source #

class (Show (FType m), Storable (FType m)) => VulkanField (m :: FieldMeta) where Source #

Associated Types

type FName m :: Symbol Source #

type FType m :: Type Source #

type FOptional m :: Bool Source #

type FByteOffset m :: Nat Source #

type FLength m :: Nat Source #

type FCanRead m :: Bool Source #

type FCanWrite m :: Bool Source #

Instances
(KnownSymbol fieldName, Show t, Storable t, KnownBool optional, KnownNat byteOffset, KnownNat length, KnownBool canRead, KnownBool canWrite) => VulkanField (FieldMeta fieldName t optional byteOffset length canRead canWrite) Source # 
Instance details

Defined in Graphics.Vulkan.Marshal.Internal

Associated Types

type FName (FieldMeta fieldName t optional byteOffset length canRead canWrite) :: Symbol Source #

type FType (FieldMeta fieldName t optional byteOffset length canRead canWrite) :: Type Source #

type FOptional (FieldMeta fieldName t optional byteOffset length canRead canWrite) :: Bool Source #

type FByteOffset (FieldMeta fieldName t optional byteOffset length canRead canWrite) :: Nat Source #

type FLength (FieldMeta fieldName t optional byteOffset length canRead canWrite) :: Nat Source #

type FCanRead (FieldMeta fieldName t optional byteOffset length canRead canWrite) :: Bool Source #

type FCanWrite (FieldMeta fieldName t optional byteOffset length canRead canWrite) :: Bool Source #

class VulkanFields (ms :: [FieldMeta]) where Source #

Methods

withField :: forall (fname :: Symbol) (r :: Type) (errMsg :: ErrorMessage). KnownSymbol fname => Proxy# fname -> Proxy# errMsg -> (VulkanField (GetFieldMeta errMsg fname ms) => r) -> r Source #

enumerateFields :: forall (a :: Type). (forall (m :: FieldMeta). VulkanField m => Proxy# m -> a -> a) -> a -> a Source #

Instances
VulkanFields ([] :: [FieldMeta]) Source # 
Instance details

Defined in Graphics.Vulkan.Marshal.Internal

Methods

withField :: KnownSymbol fname => Proxy# fname -> Proxy# errMsg -> (VulkanField (GetFieldMeta errMsg fname []) -> r) -> r Source #

enumerateFields :: (forall (m :: FieldMeta). VulkanField m => Proxy# m -> a -> a) -> a -> a Source #

(VulkanField m, VulkanFields ms) => VulkanFields (m ': ms) Source # 
Instance details

Defined in Graphics.Vulkan.Marshal.Internal

Methods

withField :: KnownSymbol fname => Proxy# fname -> Proxy# errMsg -> (VulkanField (GetFieldMeta errMsg fname (m ': ms)) -> r) -> r Source #

enumerateFields :: (forall (m0 :: FieldMeta). VulkanField m0 => Proxy# m0 -> a -> a) -> a -> a Source #

class KnownBool (b :: Bool) where Source #

This class give a term-level boolean associated with a type-level boolean.

The same as KnownNat for integers.

Methods

boolSing :: Bool Source #

Instances
KnownBool False Source # 
Instance details

Defined in Graphics.Vulkan.Marshal.Internal

Methods

boolSing :: Bool Source #

KnownBool True Source # 
Instance details

Defined in Graphics.Vulkan.Marshal.Internal

Methods

boolSing :: Bool Source #

data FieldMeta Source #

FieldMeta fieldName fieldType optional byteOffset length canRead canWrite represents a Vulkan structure field at the type level.

Instances
VulkanFields ([] :: [FieldMeta]) Source # 
Instance details

Defined in Graphics.Vulkan.Marshal.Internal

Methods

withField :: KnownSymbol fname => Proxy# fname -> Proxy# errMsg -> (VulkanField (GetFieldMeta errMsg fname []) -> r) -> r Source #

enumerateFields :: (forall (m :: FieldMeta). VulkanField m => Proxy# m -> a -> a) -> a -> a Source #

(VulkanField m, VulkanFields ms) => VulkanFields (m ': ms) Source # 
Instance details

Defined in Graphics.Vulkan.Marshal.Internal

Methods

withField :: KnownSymbol fname => Proxy# fname -> Proxy# errMsg -> (VulkanField (GetFieldMeta errMsg fname (m ': ms)) -> r) -> r Source #

enumerateFields :: (forall (m0 :: FieldMeta). VulkanField m0 => Proxy# m0 -> a -> a) -> a -> a Source #

data StructMeta Source #

StructMeta structName structType size alignment fields isUnion isReturnedOnly structExtends represents a Vulkan structure at the type level.

Re-exported functions from ForeignPtr

mallocForeignPtr :: Storable a => IO (ForeignPtr a) #

Allocate some memory and return a ForeignPtr to it. The memory will be released automatically when the ForeignPtr is discarded.

mallocForeignPtr is equivalent to

   do { p <- malloc; newForeignPtr finalizerFree p }

although it may be implemented differently internally: you may not assume that the memory returned by mallocForeignPtr has been allocated with malloc.

GHC notes: mallocForeignPtr has a heavily optimised implementation in GHC. It uses pinned memory in the garbage collected heap, so the ForeignPtr does not require a finalizer to free the memory. Use of mallocForeignPtr and associated functions is strongly recommended in preference to newForeignPtr with a finalizer.

withForeignPtr :: ForeignPtr a -> (Ptr a -> IO b) -> IO b #

This is a way to look at the pointer living inside a foreign object. This function takes a function which is applied to that pointer. The resulting IO action is then executed. The foreign object is kept alive at least during the whole action, even if it is not used directly inside. Note that it is not safe to return the pointer from the action and use it after the action completes. All uses of the pointer should be inside the withForeignPtr bracket. The reason for this unsafeness is the same as for unsafeForeignPtrToPtr below: the finalizer may run earlier than expected, because the compiler can only track usage of the ForeignPtr object, not a Ptr object made from it.

This function is normally used for marshalling data to or from the object pointed to by the ForeignPtr, using the operations from the Storable class.

addForeignPtrFinalizer :: FinalizerPtr a -> ForeignPtr a -> IO () #

This function adds a finalizer to the given foreign object. The finalizer will run before all other finalizers for the same object which have already been registered.

Re-exported common types

data Int8 #

8-bit signed integer type

Instances
Bounded Int8

Since: base-2.1

Instance details

Defined in GHC.Int

Enum Int8

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

succ :: Int8 -> Int8 #

pred :: Int8 -> Int8 #

toEnum :: Int -> Int8 #

fromEnum :: Int8 -> Int #

enumFrom :: Int8 -> [Int8] #

enumFromThen :: Int8 -> Int8 -> [Int8] #

enumFromTo :: Int8 -> Int8 -> [Int8] #

enumFromThenTo :: Int8 -> Int8 -> Int8 -> [Int8] #

Eq Int8

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

(==) :: Int8 -> Int8 -> Bool #

(/=) :: Int8 -> Int8 -> Bool #

Integral Int8

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

quot :: Int8 -> Int8 -> Int8 #

rem :: Int8 -> Int8 -> Int8 #

div :: Int8 -> Int8 -> Int8 #

mod :: Int8 -> Int8 -> Int8 #

quotRem :: Int8 -> Int8 -> (Int8, Int8) #

divMod :: Int8 -> Int8 -> (Int8, Int8) #

toInteger :: Int8 -> Integer #

Num Int8

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

(+) :: Int8 -> Int8 -> Int8 #

(-) :: Int8 -> Int8 -> Int8 #

(*) :: Int8 -> Int8 -> Int8 #

negate :: Int8 -> Int8 #

abs :: Int8 -> Int8 #

signum :: Int8 -> Int8 #

fromInteger :: Integer -> Int8 #

Ord Int8

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

compare :: Int8 -> Int8 -> Ordering #

(<) :: Int8 -> Int8 -> Bool #

(<=) :: Int8 -> Int8 -> Bool #

(>) :: Int8 -> Int8 -> Bool #

(>=) :: Int8 -> Int8 -> Bool #

max :: Int8 -> Int8 -> Int8 #

min :: Int8 -> Int8 -> Int8 #

Read Int8

Since: base-2.1

Instance details

Defined in GHC.Int

Real Int8

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

toRational :: Int8 -> Rational #

Show Int8

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

showsPrec :: Int -> Int8 -> ShowS #

show :: Int8 -> String #

showList :: [Int8] -> ShowS #

Ix Int8

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

range :: (Int8, Int8) -> [Int8] #

index :: (Int8, Int8) -> Int8 -> Int #

unsafeIndex :: (Int8, Int8) -> Int8 -> Int

inRange :: (Int8, Int8) -> Int8 -> Bool #

rangeSize :: (Int8, Int8) -> Int #

unsafeRangeSize :: (Int8, Int8) -> Int

Storable Int8

Since: base-2.1

Instance details

Defined in Foreign.Storable

Methods

sizeOf :: Int8 -> Int #

alignment :: Int8 -> Int #

peekElemOff :: Ptr Int8 -> Int -> IO Int8 #

pokeElemOff :: Ptr Int8 -> Int -> Int8 -> IO () #

peekByteOff :: Ptr b -> Int -> IO Int8 #

pokeByteOff :: Ptr b -> Int -> Int8 -> IO () #

peek :: Ptr Int8 -> IO Int8 #

poke :: Ptr Int8 -> Int8 -> IO () #

Bits Int8

Since: base-2.1

Instance details

Defined in GHC.Int

FiniteBits Int8

Since: base-4.6.0.0

Instance details

Defined in GHC.Int

data Int16 #

16-bit signed integer type

Instances
Bounded Int16

Since: base-2.1

Instance details

Defined in GHC.Int

Enum Int16

Since: base-2.1

Instance details

Defined in GHC.Int

Eq Int16

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

(==) :: Int16 -> Int16 -> Bool #

(/=) :: Int16 -> Int16 -> Bool #

Integral Int16

Since: base-2.1

Instance details

Defined in GHC.Int

Num Int16

Since: base-2.1

Instance details

Defined in GHC.Int

Ord Int16

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

compare :: Int16 -> Int16 -> Ordering #

(<) :: Int16 -> Int16 -> Bool #

(<=) :: Int16 -> Int16 -> Bool #

(>) :: Int16 -> Int16 -> Bool #

(>=) :: Int16 -> Int16 -> Bool #

max :: Int16 -> Int16 -> Int16 #

min :: Int16 -> Int16 -> Int16 #

Read Int16

Since: base-2.1

Instance details

Defined in GHC.Int

Real Int16

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

toRational :: Int16 -> Rational #

Show Int16

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

showsPrec :: Int -> Int16 -> ShowS #

show :: Int16 -> String #

showList :: [Int16] -> ShowS #

Ix Int16

Since: base-2.1

Instance details

Defined in GHC.Int

Storable Int16

Since: base-2.1

Instance details

Defined in Foreign.Storable

Methods

sizeOf :: Int16 -> Int #

alignment :: Int16 -> Int #

peekElemOff :: Ptr Int16 -> Int -> IO Int16 #

pokeElemOff :: Ptr Int16 -> Int -> Int16 -> IO () #

peekByteOff :: Ptr b -> Int -> IO Int16 #

pokeByteOff :: Ptr b -> Int -> Int16 -> IO () #

peek :: Ptr Int16 -> IO Int16 #

poke :: Ptr Int16 -> Int16 -> IO () #

Bits Int16

Since: base-2.1

Instance details

Defined in GHC.Int

FiniteBits Int16

Since: base-4.6.0.0

Instance details

Defined in GHC.Int

data Int32 #

32-bit signed integer type

Instances
Bounded Int32

Since: base-2.1

Instance details

Defined in GHC.Int

Enum Int32

Since: base-2.1

Instance details

Defined in GHC.Int

Eq Int32

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

(==) :: Int32 -> Int32 -> Bool #

(/=) :: Int32 -> Int32 -> Bool #

Integral Int32

Since: base-2.1

Instance details

Defined in GHC.Int

Num Int32

Since: base-2.1

Instance details

Defined in GHC.Int

Ord Int32

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

compare :: Int32 -> Int32 -> Ordering #

(<) :: Int32 -> Int32 -> Bool #

(<=) :: Int32 -> Int32 -> Bool #

(>) :: Int32 -> Int32 -> Bool #

(>=) :: Int32 -> Int32 -> Bool #

max :: Int32 -> Int32 -> Int32 #

min :: Int32 -> Int32 -> Int32 #

Read Int32

Since: base-2.1

Instance details

Defined in GHC.Int

Real Int32

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

toRational :: Int32 -> Rational #

Show Int32

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

showsPrec :: Int -> Int32 -> ShowS #

show :: Int32 -> String #

showList :: [Int32] -> ShowS #

Ix Int32

Since: base-2.1

Instance details

Defined in GHC.Int

Storable Int32

Since: base-2.1

Instance details

Defined in Foreign.Storable

Methods

sizeOf :: Int32 -> Int #

alignment :: Int32 -> Int #

peekElemOff :: Ptr Int32 -> Int -> IO Int32 #

pokeElemOff :: Ptr Int32 -> Int -> Int32 -> IO () #

peekByteOff :: Ptr b -> Int -> IO Int32 #

pokeByteOff :: Ptr b -> Int -> Int32 -> IO () #

peek :: Ptr Int32 -> IO Int32 #

poke :: Ptr Int32 -> Int32 -> IO () #

Bits Int32

Since: base-2.1

Instance details

Defined in GHC.Int

FiniteBits Int32

Since: base-4.6.0.0

Instance details

Defined in GHC.Int

data Int64 #

64-bit signed integer type

Instances
Bounded Int64

Since: base-2.1

Instance details

Defined in GHC.Int

Enum Int64

Since: base-2.1

Instance details

Defined in GHC.Int

Eq Int64

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

(==) :: Int64 -> Int64 -> Bool #

(/=) :: Int64 -> Int64 -> Bool #

Integral Int64

Since: base-2.1

Instance details

Defined in GHC.Int

Num Int64

Since: base-2.1

Instance details

Defined in GHC.Int

Ord Int64

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

compare :: Int64 -> Int64 -> Ordering #

(<) :: Int64 -> Int64 -> Bool #

(<=) :: Int64 -> Int64 -> Bool #

(>) :: Int64 -> Int64 -> Bool #

(>=) :: Int64 -> Int64 -> Bool #

max :: Int64 -> Int64 -> Int64 #

min :: Int64 -> Int64 -> Int64 #

Read Int64

Since: base-2.1

Instance details

Defined in GHC.Int

Real Int64

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

toRational :: Int64 -> Rational #

Show Int64

Since: base-2.1

Instance details

Defined in GHC.Int

Methods

showsPrec :: Int -> Int64 -> ShowS #

show :: Int64 -> String #

showList :: [Int64] -> ShowS #

Ix Int64

Since: base-2.1

Instance details

Defined in GHC.Int

Storable Int64

Since: base-2.1

Instance details

Defined in Foreign.Storable

Methods

sizeOf :: Int64 -> Int #

alignment :: Int64 -> Int #

peekElemOff :: Ptr Int64 -> Int -> IO Int64 #

pokeElemOff :: Ptr Int64 -> Int -> Int64 -> IO () #

peekByteOff :: Ptr b -> Int -> IO Int64 #

pokeByteOff :: Ptr b -> Int -> Int64 -> IO () #

peek :: Ptr Int64 -> IO Int64 #

poke :: Ptr Int64 -> Int64 -> IO () #

Bits Int64

Since: base-2.1

Instance details

Defined in GHC.Int

FiniteBits Int64

Since: base-4.6.0.0

Instance details

Defined in GHC.Int

data Word8 #

8-bit unsigned integer type

Instances
Bounded Word8

Since: base-2.1

Instance details

Defined in GHC.Word

Enum Word8

Since: base-2.1

Instance details

Defined in GHC.Word

Eq Word8

Since: base-2.1

Instance details

Defined in GHC.Word

Methods

(==) :: Word8 -> Word8 -> Bool #

(/=) :: Word8 -> Word8 -> Bool #

Integral Word8

Since: base-2.1

Instance details

Defined in GHC.Word

Num Word8

Since: base-2.1

Instance details

Defined in GHC.Word

Ord Word8

Since: base-2.1

Instance details

Defined in GHC.Word

Methods

compare :: Word8 -> Word8 -> Ordering #

(<) :: Word8 -> Word8 -> Bool #

(<=) :: Word8 -> Word8 -> Bool #

(>) :: Word8 -> Word8 -> Bool #

(>=) :: Word8 -> Word8 -> Bool #

max :: Word8 -> Word8 -> Word8 #

min :: Word8 -> Word8 -> Word8 #

Read Word8

Since: base-2.1

Instance details

Defined in GHC.Read

Real Word8

Since: base-2.1

Instance details

Defined in GHC.Word

Methods

toRational :: Word8 -> Rational #

Show Word8

Since: base-2.1

Instance details

Defined in GHC.Word

Methods

showsPrec :: Int -> Word8 -> ShowS #

show :: Word8 -> String #

showList :: [Word8] -> ShowS #

Ix Word8

Since: base-2.1

Instance details

Defined in GHC.Word

Storable Word8

Since: base-2.1

Instance details

Defined in Foreign.Storable

Methods

sizeOf :: Word8 -> Int #

alignment :: Word8 -> Int #

peekElemOff :: Ptr Word8 -> Int -> IO Word8 #

pokeElemOff :: Ptr Word8 -> Int -> Word8 -> IO () #

peekByteOff :: Ptr b -> Int -> IO Word8 #

pokeByteOff :: Ptr b -> Int -> Word8 -> IO () #

peek :: Ptr Word8 -> IO Word8 #

poke :: Ptr Word8 -> Word8 -> IO () #

Bits Word8

Since: base-2.1

Instance details

Defined in GHC.Word

FiniteBits Word8

Since: base-4.6.0.0

Instance details

Defined in GHC.Word

data Word16 #

16-bit unsigned integer type

Instances
Bounded Word16

Since: base-2.1

Instance details

Defined in GHC.Word

Enum Word16

Since: base-2.1

Instance details

Defined in GHC.Word

Eq Word16

Since: base-2.1

Instance details

Defined in GHC.Word

Methods

(==) :: Word16 -> Word16 -> Bool #

(/=) :: Word16 -> Word16 -> Bool #

Integral Word16

Since: base-2.1

Instance details

Defined in GHC.Word

Num Word16

Since: base-2.1

Instance details

Defined in GHC.Word

Ord Word16

Since: base-2.1

Instance details

Defined in GHC.Word

Read Word16

Since: base-2.1

Instance details

Defined in GHC.Read

Real Word16

Since: base-2.1

Instance details

Defined in GHC.Word

Show Word16

Since: base-2.1

Instance details

Defined in GHC.Word

Ix Word16

Since: base-2.1

Instance details

Defined in GHC.Word

Storable Word16

Since: base-2.1

Instance details

Defined in Foreign.Storable

Bits Word16

Since: base-2.1

Instance details

Defined in GHC.Word

FiniteBits Word16

Since: base-4.6.0.0

Instance details

Defined in GHC.Word

data Word32 #

32-bit unsigned integer type

Instances
Bounded Word32

Since: base-2.1

Instance details

Defined in GHC.Word

Enum Word32

Since: base-2.1

Instance details

Defined in GHC.Word

Eq Word32

Since: base-2.1

Instance details

Defined in GHC.Word

Methods

(==) :: Word32 -> Word32 -> Bool #

(/=) :: Word32 -> Word32 -> Bool #

Integral Word32

Since: base-2.1

Instance details

Defined in GHC.Word

Num Word32

Since: base-2.1

Instance details

Defined in GHC.Word

Ord Word32

Since: base-2.1

Instance details

Defined in GHC.Word

Read Word32

Since: base-2.1

Instance details

Defined in GHC.Read

Real Word32

Since: base-2.1

Instance details

Defined in GHC.Word

Show Word32

Since: base-2.1

Instance details

Defined in GHC.Word

Ix Word32

Since: base-2.1

Instance details

Defined in GHC.Word

Storable Word32

Since: base-2.1

Instance details

Defined in Foreign.Storable

Bits Word32

Since: base-2.1

Instance details

Defined in GHC.Word

FiniteBits Word32

Since: base-4.6.0.0

Instance details

Defined in GHC.Word

data Word64 #

64-bit unsigned integer type

Instances
Bounded Word64

Since: base-2.1

Instance details

Defined in GHC.Word

Enum Word64

Since: base-2.1

Instance details

Defined in GHC.Word

Eq Word64

Since: base-2.1

Instance details

Defined in GHC.Word

Methods

(==) :: Word64 -> Word64 -> Bool #

(/=) :: Word64 -> Word64 -> Bool #

Integral Word64

Since: base-2.1

Instance details

Defined in GHC.Word

Num Word64

Since: base-2.1

Instance details

Defined in GHC.Word

Ord Word64

Since: base-2.1

Instance details

Defined in GHC.Word

Read Word64

Since: base-2.1

Instance details

Defined in GHC.Read

Real Word64

Since: base-2.1

Instance details

Defined in GHC.Word

Show Word64

Since: base-2.1

Instance details

Defined in GHC.Word

Ix Word64

Since: base-2.1

Instance details

Defined in GHC.Word

Storable Word64

Since: base-2.1

Instance details

Defined in Foreign.Storable

Bits Word64

Since: base-2.1

Instance details

Defined in GHC.Word

FiniteBits Word64

Since: base-4.6.0.0

Instance details

Defined in GHC.Word

data Ptr a #

A value of type Ptr a represents a pointer to an object, or an array of objects, which may be marshalled to or from Haskell values of type a.

The type a will often be an instance of class Storable which provides the marshalling operations. However this is not essential, and you can provide your own operations to access the pointer. For example you might write small foreign functions to get or set the fields of a C struct.

Instances
VulkanPtr Ptr Source # 
Instance details

Defined in Graphics.Vulkan.Marshal

Methods

vkNullPtr :: Ptr a Source #

Generic1 (URec (Ptr ()) :: k -> Type) 
Instance details

Defined in GHC.Generics

Associated Types

type Rep1 (URec (Ptr ())) :: k -> Type #

Methods

from1 :: URec (Ptr ()) a -> Rep1 (URec (Ptr ())) a #

to1 :: Rep1 (URec (Ptr ())) a -> URec (Ptr ()) a #

Eq (Ptr a)

Since: base-2.1

Instance details

Defined in GHC.Ptr

Methods

(==) :: Ptr a -> Ptr a -> Bool #

(/=) :: Ptr a -> Ptr a -> Bool #

Ord (Ptr a)

Since: base-2.1

Instance details

Defined in GHC.Ptr

Methods

compare :: Ptr a -> Ptr a -> Ordering #

(<) :: Ptr a -> Ptr a -> Bool #

(<=) :: Ptr a -> Ptr a -> Bool #

(>) :: Ptr a -> Ptr a -> Bool #

(>=) :: Ptr a -> Ptr a -> Bool #

max :: Ptr a -> Ptr a -> Ptr a #

min :: Ptr a -> Ptr a -> Ptr a #

Show (Ptr a)

Since: base-2.1

Instance details

Defined in GHC.Ptr

Methods

showsPrec :: Int -> Ptr a -> ShowS #

show :: Ptr a -> String #

showList :: [Ptr a] -> ShowS #

Storable (Ptr a)

Since: base-2.1

Instance details

Defined in Foreign.Storable

Methods

sizeOf :: Ptr a -> Int #

alignment :: Ptr a -> Int #

peekElemOff :: Ptr (Ptr a) -> Int -> IO (Ptr a) #

pokeElemOff :: Ptr (Ptr a) -> Int -> Ptr a -> IO () #

peekByteOff :: Ptr b -> Int -> IO (Ptr a) #

pokeByteOff :: Ptr b -> Int -> Ptr a -> IO () #

peek :: Ptr (Ptr a) -> IO (Ptr a) #

poke :: Ptr (Ptr a) -> Ptr a -> IO () #

Functor (URec (Ptr ()) :: Type -> Type)

Since: base-4.9.0.0

Instance details

Defined in GHC.Generics

Methods

fmap :: (a -> b) -> URec (Ptr ()) a -> URec (Ptr ()) b #

(<$) :: a -> URec (Ptr ()) b -> URec (Ptr ()) a #

Foldable (URec (Ptr ()) :: Type -> Type)

Since: base-4.9.0.0

Instance details

Defined in Data.Foldable

Methods

fold :: Monoid m => URec (Ptr ()) m -> m #

foldMap :: Monoid m => (a -> m) -> URec (Ptr ()) a -> m #

foldr :: (a -> b -> b) -> b -> URec (Ptr ()) a -> b #

foldr' :: (a -> b -> b) -> b -> URec (Ptr ()) a -> b #

foldl :: (b -> a -> b) -> b -> URec (Ptr ()) a -> b #

foldl' :: (b -> a -> b) -> b -> URec (Ptr ()) a -> b #

foldr1 :: (a -> a -> a) -> URec (Ptr ()) a -> a #

foldl1 :: (a -> a -> a) -> URec (Ptr ()) a -> a #

toList :: URec (Ptr ()) a -> [a] #

null :: URec (Ptr ()) a -> Bool #

length :: URec (Ptr ()) a -> Int #

elem :: Eq a => a -> URec (Ptr ()) a -> Bool #

maximum :: Ord a => URec (Ptr ()) a -> a #

minimum :: Ord a => URec (Ptr ()) a -> a #

sum :: Num a => URec (Ptr ()) a -> a #

product :: Num a => URec (Ptr ()) a -> a #

Traversable (URec (Ptr ()) :: Type -> Type)

Since: base-4.9.0.0

Instance details

Defined in Data.Traversable

Methods

traverse :: Applicative f => (a -> f b) -> URec (Ptr ()) a -> f (URec (Ptr ()) b) #

sequenceA :: Applicative f => URec (Ptr ()) (f a) -> f (URec (Ptr ()) a) #

mapM :: Monad m => (a -> m b) -> URec (Ptr ()) a -> m (URec (Ptr ()) b) #

sequence :: Monad m => URec (Ptr ()) (m a) -> m (URec (Ptr ()) a) #

Eq (URec (Ptr ()) p)

Since: base-4.9.0.0

Instance details

Defined in GHC.Generics

Methods

(==) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool #

(/=) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool #

Ord (URec (Ptr ()) p)

Since: base-4.9.0.0

Instance details

Defined in GHC.Generics

Methods

compare :: URec (Ptr ()) p -> URec (Ptr ()) p -> Ordering #

(<) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool #

(<=) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool #

(>) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool #

(>=) :: URec (Ptr ()) p -> URec (Ptr ()) p -> Bool #

max :: URec (Ptr ()) p -> URec (Ptr ()) p -> URec (Ptr ()) p #

min :: URec (Ptr ()) p -> URec (Ptr ()) p -> URec (Ptr ()) p #

Generic (URec (Ptr ()) p) 
Instance details

Defined in GHC.Generics

Associated Types

type Rep (URec (Ptr ()) p) :: Type -> Type #

Methods

from :: URec (Ptr ()) p -> Rep (URec (Ptr ()) p) x #

to :: Rep (URec (Ptr ()) p) x -> URec (Ptr ()) p #

data URec (Ptr ()) (p :: k)

Used for marking occurrences of Addr#

Since: base-4.9.0.0

Instance details

Defined in GHC.Generics

data URec (Ptr ()) (p :: k) = UAddr {}
type Rep1 (URec (Ptr ()) :: k -> Type)

Since: base-4.9.0.0

Instance details

Defined in GHC.Generics

type Rep1 (URec (Ptr ()) :: k -> Type) = D1 (MetaData "URec" "GHC.Generics" "base" False) (C1 (MetaCons "UAddr" PrefixI True) (S1 (MetaSel (Just "uAddr#") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (UAddr :: k -> Type)))
type Rep (URec (Ptr ()) p)

Since: base-4.9.0.0

Instance details

Defined in GHC.Generics

type Rep (URec (Ptr ()) p) = D1 (MetaData "URec" "GHC.Generics" "base" False) (C1 (MetaCons "UAddr" PrefixI True) (S1 (MetaSel (Just "uAddr#") NoSourceUnpackedness NoSourceStrictness DecidedLazy) (UAddr :: Type -> Type)))

data FunPtr a #

A value of type FunPtr a is a pointer to a function callable from foreign code. The type a will normally be a foreign type, a function type with zero or more arguments where

A value of type FunPtr a may be a pointer to a foreign function, either returned by another foreign function or imported with a a static address import like

foreign import ccall "stdlib.h &free"
  p_free :: FunPtr (Ptr a -> IO ())

or a pointer to a Haskell function created using a wrapper stub declared to produce a FunPtr of the correct type. For example:

type Compare = Int -> Int -> Bool
foreign import ccall "wrapper"
  mkCompare :: Compare -> IO (FunPtr Compare)

Calls to wrapper stubs like mkCompare allocate storage, which should be released with freeHaskellFunPtr when no longer required.

To convert FunPtr values to corresponding Haskell functions, one can define a dynamic stub for the specific foreign type, e.g.

type IntFunction = CInt -> IO ()
foreign import ccall "dynamic"
  mkFun :: FunPtr IntFunction -> IntFunction
Instances
Eq (FunPtr a) 
Instance details

Defined in GHC.Ptr

Methods

(==) :: FunPtr a -> FunPtr a -> Bool #

(/=) :: FunPtr a -> FunPtr a -> Bool #

Ord (FunPtr a) 
Instance details

Defined in GHC.Ptr

Methods

compare :: FunPtr a -> FunPtr a -> Ordering #

(<) :: FunPtr a -> FunPtr a -> Bool #

(<=) :: FunPtr a -> FunPtr a -> Bool #

(>) :: FunPtr a -> FunPtr a -> Bool #

(>=) :: FunPtr a -> FunPtr a -> Bool #

max :: FunPtr a -> FunPtr a -> FunPtr a #

min :: FunPtr a -> FunPtr a -> FunPtr a #

Show (FunPtr a)

Since: base-2.1

Instance details

Defined in GHC.Ptr

Methods

showsPrec :: Int -> FunPtr a -> ShowS #

show :: FunPtr a -> String #

showList :: [FunPtr a] -> ShowS #

Storable (FunPtr a)

Since: base-2.1

Instance details

Defined in Foreign.Storable

Methods

sizeOf :: FunPtr a -> Int #

alignment :: FunPtr a -> Int #

peekElemOff :: Ptr (FunPtr a) -> Int -> IO (FunPtr a) #

pokeElemOff :: Ptr (FunPtr a) -> Int -> FunPtr a -> IO () #

peekByteOff :: Ptr b -> Int -> IO (FunPtr a) #

pokeByteOff :: Ptr b -> Int -> FunPtr a -> IO () #

peek :: Ptr (FunPtr a) -> IO (FunPtr a) #

poke :: Ptr (FunPtr a) -> FunPtr a -> IO () #

data Void #

Uninhabited data type

Since: base-4.8.0.0

Instances
Eq Void

Since: base-4.8.0.0

Instance details

Defined in Data.Void

Methods

(==) :: Void -> Void -> Bool #

(/=) :: Void -> Void -> Bool #

Data Void

Since: base-4.8.0.0

Instance details

Defined in Data.Void

Methods

gfoldl :: (forall d b. Data d => c (d -> b) -> d -> c b) -> (forall g. g -> c g) -> Void -> c Void #

gunfold :: (forall b r. Data b => c (b -> r) -> c r) -> (forall r. r -> c r) -> Constr -> c Void #

toConstr :: Void -> Constr #

dataTypeOf :: Void -> DataType #

dataCast1 :: Typeable t => (forall d. Data d => c (t d)) -> Maybe (c Void) #

dataCast2 :: Typeable t => (forall d e. (Data d, Data e) => c (t d e)) -> Maybe (c Void) #

gmapT :: (forall b. Data b => b -> b) -> Void -> Void #

gmapQl :: (r -> r' -> r) -> r -> (forall d. Data d => d -> r') -> Void -> r #

gmapQr :: (r' -> r -> r) -> r -> (forall d. Data d => d -> r') -> Void -> r #

gmapQ :: (forall d. Data d => d -> u) -> Void -> [u] #

gmapQi :: Int -> (forall d. Data d => d -> u) -> Void -> u #

gmapM :: Monad m => (forall d. Data d => d -> m d) -> Void -> m Void #

gmapMp :: MonadPlus m => (forall d. Data d => d -> m d) -> Void -> m Void #

gmapMo :: MonadPlus m => (forall d. Data d => d -> m d) -> Void -> m Void #

Ord Void

Since: base-4.8.0.0

Instance details

Defined in Data.Void

Methods

compare :: Void -> Void -> Ordering #

(<) :: Void -> Void -> Bool #

(<=) :: Void -> Void -> Bool #

(>) :: Void -> Void -> Bool #

(>=) :: Void -> Void -> Bool #

max :: Void -> Void -> Void #

min :: Void -> Void -> Void #

Read Void

Reading a Void value is always a parse error, considering Void as a data type with no constructors.

Since: base-4.8.0.0

Instance details

Defined in Data.Void

Show Void

Since: base-4.8.0.0

Instance details

Defined in Data.Void

Methods

showsPrec :: Int -> Void -> ShowS #

show :: Void -> String #

showList :: [Void] -> ShowS #

Ix Void

Since: base-4.8.0.0

Instance details

Defined in Data.Void

Methods

range :: (Void, Void) -> [Void] #

index :: (Void, Void) -> Void -> Int #

unsafeIndex :: (Void, Void) -> Void -> Int

inRange :: (Void, Void) -> Void -> Bool #

rangeSize :: (Void, Void) -> Int #

unsafeRangeSize :: (Void, Void) -> Int

Generic Void 
Instance details

Defined in Data.Void

Associated Types

type Rep Void :: Type -> Type #

Methods

from :: Void -> Rep Void x #

to :: Rep Void x -> Void #

Semigroup Void

Since: base-4.9.0.0

Instance details

Defined in Data.Void

Methods

(<>) :: Void -> Void -> Void #

sconcat :: NonEmpty Void -> Void #

stimes :: Integral b => b -> Void -> Void #

Exception Void

Since: base-4.8.0.0

Instance details

Defined in Data.Void

type Rep Void

Since: base-4.8.0.0

Instance details

Defined in Data.Void

type Rep Void = D1 (MetaData "Void" "Data.Void" "base" False) (V1 :: Type -> Type)

type CString = Ptr CChar #

A C string is a reference to an array of C characters terminated by NUL.

newtype CInt #

Haskell type representing the C int type.

Constructors

CInt Int32 
Instances
Bounded CInt 
Instance details

Defined in Foreign.C.Types

Enum CInt 
Instance details

Defined in Foreign.C.Types

Methods

succ :: CInt -> CInt #

pred :: CInt -> CInt #

toEnum :: Int -> CInt #

fromEnum :: CInt -> Int #

enumFrom :: CInt -> [CInt] #

enumFromThen :: CInt -> CInt -> [CInt] #

enumFromTo :: CInt -> CInt -> [CInt] #

enumFromThenTo :: CInt -> CInt -> CInt -> [CInt] #

Eq CInt 
Instance details

Defined in Foreign.C.Types

Methods

(==) :: CInt -> CInt -> Bool #

(/=) :: CInt -> CInt -> Bool #

Integral CInt 
Instance details

Defined in Foreign.C.Types

Methods

quot :: CInt -> CInt -> CInt #

rem :: CInt -> CInt -> CInt #

div :: CInt -> CInt -> CInt #

mod :: CInt -> CInt -> CInt #

quotRem :: CInt -> CInt -> (CInt, CInt) #

divMod :: CInt -> CInt -> (CInt, CInt) #

toInteger :: CInt -> Integer #

Num CInt 
Instance details

Defined in Foreign.C.Types

Methods

(+) :: CInt -> CInt -> CInt #

(-) :: CInt -> CInt -> CInt #

(*) :: CInt -> CInt -> CInt #

negate :: CInt -> CInt #

abs :: CInt -> CInt #

signum :: CInt -> CInt #

fromInteger :: Integer -> CInt #

Ord CInt 
Instance details

Defined in Foreign.C.Types

Methods

compare :: CInt -> CInt -> Ordering #

(<) :: CInt -> CInt -> Bool #

(<=) :: CInt -> CInt -> Bool #

(>) :: CInt -> CInt -> Bool #

(>=) :: CInt -> CInt -> Bool #

max :: CInt -> CInt -> CInt #

min :: CInt -> CInt -> CInt #

Read CInt 
Instance details

Defined in Foreign.C.Types

Real CInt 
Instance details

Defined in Foreign.C.Types

Methods

toRational :: CInt -> Rational #

Show CInt 
Instance details

Defined in Foreign.C.Types

Methods

showsPrec :: Int -> CInt -> ShowS #

show :: CInt -> String #

showList :: [CInt] -> ShowS #

Storable CInt 
Instance details

Defined in Foreign.C.Types

Methods

sizeOf :: CInt -> Int #

alignment :: CInt -> Int #

peekElemOff :: Ptr CInt -> Int -> IO CInt #

pokeElemOff :: Ptr CInt -> Int -> CInt -> IO () #

peekByteOff :: Ptr b -> Int -> IO CInt #

pokeByteOff :: Ptr b -> Int -> CInt -> IO () #

peek :: Ptr CInt -> IO CInt #

poke :: Ptr CInt -> CInt -> IO () #

Bits CInt 
Instance details

Defined in Foreign.C.Types

FiniteBits CInt 
Instance details

Defined in Foreign.C.Types

newtype CSize #

Haskell type representing the C size_t type.

Constructors

CSize Word64 
Instances
Bounded CSize 
Instance details

Defined in Foreign.C.Types

Enum CSize 
Instance details

Defined in Foreign.C.Types

Eq CSize 
Instance details

Defined in Foreign.C.Types

Methods

(==) :: CSize -> CSize -> Bool #

(/=) :: CSize -> CSize -> Bool #

Integral CSize 
Instance details

Defined in Foreign.C.Types

Num CSize 
Instance details

Defined in Foreign.C.Types

Ord CSize 
Instance details

Defined in Foreign.C.Types

Methods

compare :: CSize -> CSize -> Ordering #

(<) :: CSize -> CSize -> Bool #

(<=) :: CSize -> CSize -> Bool #

(>) :: CSize -> CSize -> Bool #

(>=) :: CSize -> CSize -> Bool #

max :: CSize -> CSize -> CSize #

min :: CSize -> CSize -> CSize #

Read CSize 
Instance details

Defined in Foreign.C.Types

Real CSize 
Instance details

Defined in Foreign.C.Types

Methods

toRational :: CSize -> Rational #

Show CSize 
Instance details

Defined in Foreign.C.Types

Methods

showsPrec :: Int -> CSize -> ShowS #

show :: CSize -> String #

showList :: [CSize] -> ShowS #

Storable CSize 
Instance details

Defined in Foreign.C.Types

Methods

sizeOf :: CSize -> Int #

alignment :: CSize -> Int #

peekElemOff :: Ptr CSize -> Int -> IO CSize #

pokeElemOff :: Ptr CSize -> Int -> CSize -> IO () #

peekByteOff :: Ptr b -> Int -> IO CSize #

pokeByteOff :: Ptr b -> Int -> CSize -> IO () #

peek :: Ptr CSize -> IO CSize #

poke :: Ptr CSize -> CSize -> IO () #

Bits CSize 
Instance details

Defined in Foreign.C.Types

FiniteBits CSize 
Instance details

Defined in Foreign.C.Types

newtype CChar #

Haskell type representing the C char type.

Constructors

CChar Int8 
Instances
Bounded CChar 
Instance details

Defined in Foreign.C.Types

Enum CChar 
Instance details

Defined in Foreign.C.Types

Eq CChar 
Instance details

Defined in Foreign.C.Types

Methods

(==) :: CChar -> CChar -> Bool #

(/=) :: CChar -> CChar -> Bool #

Integral CChar 
Instance details

Defined in Foreign.C.Types

Num CChar 
Instance details

Defined in Foreign.C.Types

Ord CChar 
Instance details

Defined in Foreign.C.Types

Methods

compare :: CChar -> CChar -> Ordering #

(<) :: CChar -> CChar -> Bool #

(<=) :: CChar -> CChar -> Bool #

(>) :: CChar -> CChar -> Bool #

(>=) :: CChar -> CChar -> Bool #

max :: CChar -> CChar -> CChar #

min :: CChar -> CChar -> CChar #

Read CChar 
Instance details

Defined in Foreign.C.Types

Real CChar 
Instance details

Defined in Foreign.C.Types

Methods

toRational :: CChar -> Rational #

Show CChar 
Instance details

Defined in Foreign.C.Types

Methods

showsPrec :: Int -> CChar -> ShowS #

show :: CChar -> String #

showList :: [CChar] -> ShowS #

Storable CChar 
Instance details

Defined in Foreign.C.Types

Methods

sizeOf :: CChar -> Int #

alignment :: CChar -> Int #

peekElemOff :: Ptr CChar -> Int -> IO CChar #

pokeElemOff :: Ptr CChar -> Int -> CChar -> IO () #

peekByteOff :: Ptr b -> Int -> IO CChar #

pokeByteOff :: Ptr b -> Int -> CChar -> IO () #

peek :: Ptr CChar -> IO CChar #

poke :: Ptr CChar -> CChar -> IO () #

Bits CChar 
Instance details

Defined in Foreign.C.Types

FiniteBits CChar 
Instance details

Defined in Foreign.C.Types

newtype CWchar #

Haskell type representing the C wchar_t type.

Constructors

CWchar Int32 
Instances
Bounded CWchar 
Instance details

Defined in Foreign.C.Types

Enum CWchar 
Instance details

Defined in Foreign.C.Types

Eq CWchar 
Instance details

Defined in Foreign.C.Types

Methods

(==) :: CWchar -> CWchar -> Bool #

(/=) :: CWchar -> CWchar -> Bool #

Integral CWchar 
Instance details

Defined in Foreign.C.Types

Num CWchar 
Instance details

Defined in Foreign.C.Types

Ord CWchar 
Instance details

Defined in Foreign.C.Types

Read CWchar 
Instance details

Defined in Foreign.C.Types

Real CWchar 
Instance details

Defined in Foreign.C.Types

Show CWchar 
Instance details

Defined in Foreign.C.Types

Storable CWchar 
Instance details

Defined in Foreign.C.Types

Bits CWchar 
Instance details

Defined in Foreign.C.Types

FiniteBits CWchar 
Instance details

Defined in Foreign.C.Types

newtype CULong #

Haskell type representing the C unsigned long type.

Constructors

CULong Word64 
Instances
Bounded CULong 
Instance details

Defined in Foreign.C.Types

Enum CULong 
Instance details

Defined in Foreign.C.Types

Eq CULong 
Instance details

Defined in Foreign.C.Types

Methods

(==) :: CULong -> CULong -> Bool #

(/=) :: CULong -> CULong -> Bool #

Integral CULong 
Instance details

Defined in Foreign.C.Types

Num CULong 
Instance details

Defined in Foreign.C.Types

Ord CULong 
Instance details

Defined in Foreign.C.Types

Read CULong 
Instance details

Defined in Foreign.C.Types

Real CULong 
Instance details

Defined in Foreign.C.Types

Show CULong 
Instance details

Defined in Foreign.C.Types

Storable CULong 
Instance details

Defined in Foreign.C.Types

Bits CULong 
Instance details

Defined in Foreign.C.Types

FiniteBits CULong 
Instance details

Defined in Foreign.C.Types

Utilities for string types

withCStringField :: forall fname a b. (CanReadFieldArray fname a, FieldType fname a ~ CChar, VulkanMarshal a) => a -> (CString -> IO b) -> IO b Source #

Perform an action on a C string field. The string pointers should not be used outside the callback. It will point to a correct location only as long as the struct is alive.

unsafeCStringField :: forall fname a. (CanReadFieldArray fname a, FieldType fname a ~ CChar, VulkanMarshal a) => a -> CString Source #

Get pointer to a memory location of the C string field in a structure.

getStringField :: forall fname a. (CanReadFieldArray fname a, FieldType fname a ~ CChar, VulkanMarshal a) => a -> String Source #

readStringField :: forall fname a. (CanReadFieldArray fname a, FieldType fname a ~ CChar, VulkanMarshal a) => Ptr a -> IO String Source #

writeStringField :: forall fname a. (CanWriteFieldArray fname a, FieldType fname a ~ CChar, VulkanMarshal a) => Ptr a -> String -> IO () Source #

cmpCStrings :: CString -> CString -> Ordering Source #

Check first if two CString point to the same memory location. Otherwise, compare them using C strcmp function.

cmpCStringsN :: CString -> CString -> Int -> Ordering Source #

Check first if two CString point to the same memory location. Otherwise, compare them using C strncmp function. It may be useful to provide maximum number of characters to compare.