vulkan-3.26.1: Bindings to the Vulkan graphics API.
Safe HaskellSafe-Inferred
LanguageHaskell2010

Vulkan.Core10.BufferView

Synopsis

Documentation

createBufferView Source #

Arguments

:: forall a io. (Extendss BufferViewCreateInfo a, PokeChain a, MonadIO io) 
=> Device

device is the logical device that creates the buffer view.

-> BufferViewCreateInfo a

pCreateInfo is a pointer to a BufferViewCreateInfo structure containing parameters to be used to create the buffer view.

-> ("allocator" ::: Maybe AllocationCallbacks)

pAllocator controls host memory allocation as described in the Memory Allocation chapter.

-> io BufferView 

vkCreateBufferView - Create a new buffer view object

Valid Usage (Implicit)

  • device must be a valid Device handle

Return Codes

Success
Failure

See Also

VK_VERSION_1_0, AllocationCallbacks, BufferView, BufferViewCreateInfo, Device

withBufferView :: forall a io r. (Extendss BufferViewCreateInfo a, PokeChain a, MonadIO io) => Device -> BufferViewCreateInfo a -> Maybe AllocationCallbacks -> (io BufferView -> (BufferView -> io ()) -> r) -> r Source #

A convenience wrapper to make a compatible pair of calls to createBufferView and destroyBufferView

To ensure that destroyBufferView is always called: pass bracket (or the allocate function from your favourite resource management library) as the last argument. To just extract the pair pass (,) as the last argument.

destroyBufferView Source #

Arguments

:: forall io. MonadIO io 
=> Device

device is the logical device that destroys the buffer view.

-> BufferView

bufferView is the buffer view to destroy.

-> ("allocator" ::: Maybe AllocationCallbacks)

pAllocator controls host memory allocation as described in the Memory Allocation chapter.

-> io () 

vkDestroyBufferView - Destroy a buffer view object

Valid Usage

  • All submitted commands that refer to bufferView must have completed execution
  • If AllocationCallbacks were provided when bufferView was created, a compatible set of callbacks must be provided here
  • If no AllocationCallbacks were provided when bufferView was created, pAllocator must be NULL

Valid Usage (Implicit)

  • device must be a valid Device handle
  • If bufferView is not NULL_HANDLE, bufferView must be a valid BufferView handle
  • If pAllocator is not NULL, pAllocator must be a valid pointer to a valid AllocationCallbacks structure
  • If bufferView is a valid handle, it must have been created, allocated, or retrieved from device

Host Synchronization

  • Host access to bufferView must be externally synchronized

See Also

VK_VERSION_1_0, AllocationCallbacks, BufferView, Device

data BufferViewCreateInfo (es :: [Type]) Source #

VkBufferViewCreateInfo - Structure specifying parameters of a newly created buffer view

Description

The buffer view has a buffer view usage identifying which descriptor types can be created from it. This usage can be defined by including the BufferUsageFlags2CreateInfoKHR structure in the pNext chain, and specifying the usage value there. If this structure is not included, it is equal to the BufferCreateInfo::usage value used to create buffer.

Valid Usage

  • offset must be less than the size of buffer

Valid Usage (Implicit)

See Also

VK_VERSION_1_0, Buffer, BufferViewCreateFlags, DeviceSize, Format, StructureType, createBufferView

Constructors

BufferViewCreateInfo 

Fields

  • next :: Chain es

    pNext is NULL or a pointer to a structure extending this structure.

  • flags :: BufferViewCreateFlags

    flags is reserved for future use.

  • buffer :: Buffer

    buffer is a Buffer on which the view will be created.

  • format :: Format

    format is a Format describing the format of the data elements in the buffer.

  • offset :: DeviceSize

    offset is an offset in bytes from the base address of the buffer. Accesses to the buffer view from shaders use addressing that is relative to this starting offset.

  • range :: DeviceSize

    range is a size in bytes of the buffer view. If range is equal to WHOLE_SIZE, the range from offset to the end of the buffer is used. If WHOLE_SIZE is used and the remaining size of the buffer is not a multiple of the texel block size of format, the nearest smaller multiple is used.

Instances

Instances details
Extensible BufferViewCreateInfo Source # 
Instance details

Defined in Vulkan.Core10.BufferView

Methods

extensibleTypeName :: String Source #

getNext :: forall (es :: [Type]). BufferViewCreateInfo es -> Chain es Source #

setNext :: forall (ds :: [Type]) (es :: [TYPE LiftedRep]). BufferViewCreateInfo ds -> Chain es -> BufferViewCreateInfo es Source #

extends :: forall e b proxy. Typeable e => proxy e -> (Extends BufferViewCreateInfo e => b) -> Maybe b Source #

Show (Chain es) => Show (BufferViewCreateInfo es) Source # 
Instance details

Defined in Vulkan.Core10.BufferView

(Extendss BufferViewCreateInfo es, PeekChain es) => FromCStruct (BufferViewCreateInfo es) Source # 
Instance details

Defined in Vulkan.Core10.BufferView

(Extendss BufferViewCreateInfo es, PokeChain es) => ToCStruct (BufferViewCreateInfo es) Source # 
Instance details

Defined in Vulkan.Core10.BufferView

es ~ ('[] :: [Type]) => Zero (BufferViewCreateInfo es) Source # 
Instance details

Defined in Vulkan.Core10.BufferView

newtype BufferView Source #

VkBufferView - Opaque handle to a buffer view object

See Also

VK_VERSION_1_0, ExportMetalTextureInfoEXT, WriteDescriptorSet, createBufferView, destroyBufferView

Constructors

BufferView Word64 

Instances

Instances details
Storable BufferView Source # 
Instance details

Defined in Vulkan.Core10.Handles

Show BufferView Source # 
Instance details

Defined in Vulkan.Core10.Handles

Eq BufferView Source # 
Instance details

Defined in Vulkan.Core10.Handles

Ord BufferView Source # 
Instance details

Defined in Vulkan.Core10.Handles

HasObjectType BufferView Source # 
Instance details

Defined in Vulkan.Core10.Handles

IsHandle BufferView Source # 
Instance details

Defined in Vulkan.Core10.Handles

Zero BufferView Source # 
Instance details

Defined in Vulkan.Core10.Handles

newtype BufferViewCreateFlags Source #

VkBufferViewCreateFlags - Reserved for future use

Description

BufferViewCreateFlags is a bitmask type for setting a mask, but is currently reserved for future use.

See Also

VK_VERSION_1_0, BufferViewCreateInfo

Instances

Instances details
Storable BufferViewCreateFlags Source # 
Instance details

Defined in Vulkan.Core10.Enums.BufferViewCreateFlags

Bits BufferViewCreateFlags Source # 
Instance details

Defined in Vulkan.Core10.Enums.BufferViewCreateFlags

FiniteBits BufferViewCreateFlags Source # 
Instance details

Defined in Vulkan.Core10.Enums.BufferViewCreateFlags

Read BufferViewCreateFlags Source # 
Instance details

Defined in Vulkan.Core10.Enums.BufferViewCreateFlags

Show BufferViewCreateFlags Source # 
Instance details

Defined in Vulkan.Core10.Enums.BufferViewCreateFlags

Eq BufferViewCreateFlags Source # 
Instance details

Defined in Vulkan.Core10.Enums.BufferViewCreateFlags

Ord BufferViewCreateFlags Source # 
Instance details

Defined in Vulkan.Core10.Enums.BufferViewCreateFlags

Zero BufferViewCreateFlags Source # 
Instance details

Defined in Vulkan.Core10.Enums.BufferViewCreateFlags