Documentation ¶
Index ¶
- Constants
- Variables
- func FromBytes[E any](src []byte) []E
- func SetLogLevel(level LogLevel)
- func ToBytes[E any](src []E) []byte
- type Adapter
- func (p *Adapter) EnumerateFeatures() []FeatureName
- func (p *Adapter) GetLimits() SupportedLimits
- func (p *Adapter) GetProperties() AdapterProperties
- func (p *Adapter) HasFeature(feature FeatureName) bool
- func (p *Adapter) Release()
- func (p *Adapter) RequestDevice(descriptor *DeviceDescriptor) (*Device, error)
- type AdapterProperties
- type AdapterType
- type AddressMode
- type BackendType
- type BindGroup
- type BindGroupDescriptor
- type BindGroupEntry
- type BindGroupLayout
- type BindGroupLayoutDescriptor
- type BindGroupLayoutEntry
- type BlendComponent
- type BlendFactor
- type BlendOperation
- type BlendState
- type Buffer
- func (p *Buffer) Destroy()
- func (p *Buffer) GetMappedRange(offset, size uint) []byte
- func (p *Buffer) GetSize() uint64
- func (p *Buffer) GetUsage() BufferUsage
- func (p *Buffer) MapAsync(mode MapMode, offset uint64, size uint64, callback BufferMapCallback) (err error)
- func (p *Buffer) Release()
- func (p *Buffer) Unmap() (err error)
- type BufferBindingLayout
- type BufferBindingType
- type BufferDescriptor
- type BufferInitDescriptor
- type BufferMapAsyncStatus
- type BufferMapCallback
- type BufferMapState
- type BufferUsage
- type Color
- type ColorTargetState
- type ColorWriteMask
- type CommandBuffer
- type CommandBufferDescriptor
- type CommandEncoder
- func (p *CommandEncoder) BeginComputePass(descriptor *ComputePassDescriptor) *ComputePassEncoder
- func (p *CommandEncoder) BeginRenderPass(descriptor *RenderPassDescriptor) *RenderPassEncoder
- func (p *CommandEncoder) ClearBuffer(buffer *Buffer, offset uint64, size uint64) (err error)
- func (p *CommandEncoder) CopyBufferToBuffer(source *Buffer, sourceOffset uint64, destination *Buffer, ...) (err error)
- func (p *CommandEncoder) CopyBufferToTexture(source *ImageCopyBuffer, destination *ImageCopyTexture, copySize *Extent3D) (err error)
- func (p *CommandEncoder) CopyTextureToBuffer(source *ImageCopyTexture, destination *ImageCopyBuffer, copySize *Extent3D) (err error)
- func (p *CommandEncoder) CopyTextureToTexture(source *ImageCopyTexture, destination *ImageCopyTexture, copySize *Extent3D) (err error)
- func (p *CommandEncoder) Finish(descriptor *CommandBufferDescriptor) (*CommandBuffer, error)
- func (p *CommandEncoder) InsertDebugMarker(markerLabel string) (err error)
- func (p *CommandEncoder) PopDebugGroup() (err error)
- func (p *CommandEncoder) PushDebugGroup(groupLabel string) (err error)
- func (p *CommandEncoder) Release()
- func (p *CommandEncoder) ResolveQuerySet(querySet *QuerySet, firstQuery uint32, queryCount uint32, destination *Buffer, ...) (err error)
- func (p *CommandEncoder) WriteTimestamp(querySet *QuerySet, queryIndex uint32) (err error)
- type CommandEncoderDescriptor
- type CompareFunction
- type CompilationInfoRequestStatus
- type CompilationMessageType
- type CompositeAlphaMode
- type ComputePassDescriptor
- type ComputePassEncoder
- func (p *ComputePassEncoder) BeginPipelineStatisticsQuery(querySet *QuerySet, queryIndex uint32)
- func (p *ComputePassEncoder) DispatchWorkgroups(workgroupCountX, workgroupCountY, workgroupCountZ uint32)
- func (p *ComputePassEncoder) DispatchWorkgroupsIndirect(indirectBuffer *Buffer, indirectOffset uint64)
- func (p *ComputePassEncoder) End() (err error)
- func (p *ComputePassEncoder) EndPipelineStatisticsQuery()
- func (p *ComputePassEncoder) InsertDebugMarker(markerLabel string)
- func (p *ComputePassEncoder) PopDebugGroup()
- func (p *ComputePassEncoder) PushDebugGroup(groupLabel string)
- func (p *ComputePassEncoder) Release()
- func (p *ComputePassEncoder) SetBindGroup(groupIndex uint32, group *BindGroup, dynamicOffsets []uint32)
- func (p *ComputePassEncoder) SetPipeline(pipeline *ComputePipeline)
- type ComputePassTimestampLocation
- type ComputePipeline
- type ComputePipelineDescriptor
- type ConstantEntry
- type CreatePipelineAsyncStatus
- type CullMode
- type DepthStencilState
- type Device
- func (p *Device) CreateBindGroup(descriptor *BindGroupDescriptor) (*BindGroup, error)
- func (p *Device) CreateBindGroupLayout(descriptor *BindGroupLayoutDescriptor) (*BindGroupLayout, error)
- func (p *Device) CreateBuffer(descriptor *BufferDescriptor) (*Buffer, error)
- func (p *Device) CreateBufferInit(descriptor *BufferInitDescriptor) (*Buffer, error)
- func (p *Device) CreateCommandEncoder(descriptor *CommandEncoderDescriptor) (*CommandEncoder, error)
- func (p *Device) CreateComputePipeline(descriptor *ComputePipelineDescriptor) (*ComputePipeline, error)
- func (p *Device) CreatePipelineLayout(descriptor *PipelineLayoutDescriptor) (*PipelineLayout, error)
- func (p *Device) CreateQuerySet(descriptor *QuerySetDescriptor) (*QuerySet, error)
- func (p *Device) CreateRenderBundleEncoder(descriptor *RenderBundleEncoderDescriptor) (*RenderBundleEncoder, error)
- func (p *Device) CreateRenderPipeline(descriptor *RenderPipelineDescriptor) (*RenderPipeline, error)
- func (p *Device) CreateSampler(descriptor *SamplerDescriptor) (*Sampler, error)
- func (p *Device) CreateShaderModule(descriptor *ShaderModuleDescriptor) (*ShaderModule, error)
- func (p *Device) CreateSwapChain(surface *Surface, descriptor *SwapChainDescriptor) (*SwapChain, error)
- func (p *Device) CreateTexture(descriptor *TextureDescriptor) (*Texture, error)
- func (p *Device) EnumerateFeatures() []FeatureName
- func (p *Device) GetLimits() SupportedLimits
- func (p *Device) GetQueue() *Queue
- func (p *Device) HasFeature(feature FeatureName) bool
- func (p *Device) Poll(wait bool, wrappedSubmissionIndex *WrappedSubmissionIndex) (queueEmpty bool)
- func (p *Device) Release()
- type DeviceDescriptor
- type DeviceLostCallback
- type DeviceLostReason
- type Dx12Compiler
- type Error
- type ErrorFilter
- type ErrorType
- type Extent3D
- type FeatureName
- type FilterMode
- type FragmentState
- type FrontFace
- type GlobalReport
- type HubReport
- type ImageCopyBuffer
- type ImageCopyTexture
- type IndexFormat
- type Instance
- func (p *Instance) CreateSurface(descriptor *SurfaceDescriptor) *Surface
- func (p *Instance) EnumerateAdapters(options *InstanceEnumerateAdapterOptons) []*Adapter
- func (p *Instance) GenerateReport() GlobalReport
- func (p *Instance) Release()
- func (p *Instance) RequestAdapter(options *RequestAdapterOptions) (*Adapter, error)
- type InstanceBackend
- type InstanceDescriptor
- type InstanceEnumerateAdapterOptons
- type Limits
- type LoadOp
- type LogLevel
- type MapMode
- type MipmapFilterMode
- type MultisampleState
- type Origin3D
- type PipelineLayout
- type PipelineLayoutDescriptor
- type PipelineStatisticName
- type PowerPreference
- type PresentMode
- type PrimitiveState
- type PrimitiveTopology
- type ProgrammableStageDescriptor
- type PushConstantRange
- type QuerySet
- type QuerySetDescriptor
- type QueryType
- type Queue
- func (p *Queue) OnSubmittedWorkDone(callback QueueWorkDoneCallback)
- func (p *Queue) Release()
- func (p *Queue) Submit(commands ...*CommandBuffer) (submissionIndex SubmissionIndex)
- func (p *Queue) WriteBuffer(buffer *Buffer, bufferOffset uint64, data []byte) (err error)
- func (p *Queue) WriteTexture(destination *ImageCopyTexture, data []byte, dataLayout *TextureDataLayout, ...) (err error)
- type QueueWorkDoneCallback
- type QueueWorkDoneStatus
- type RenderBundle
- type RenderBundleDescriptor
- type RenderBundleEncoder
- func (p *RenderBundleEncoder) Draw(vertexCount, instanceCount, firstVertex, firstInstance uint32)
- func (p *RenderBundleEncoder) DrawIndexed(indexCount, instanceCount, firstIndex, baseVertex, firstInstance uint32)
- func (p *RenderBundleEncoder) DrawIndexedIndirect(indirectBuffer *Buffer, indirectOffset uint64)
- func (p *RenderBundleEncoder) DrawIndirect(indirectBuffer *Buffer, indirectOffset uint64)
- func (p *RenderBundleEncoder) Finish(descriptor *RenderBundleDescriptor) *RenderBundle
- func (p *RenderBundleEncoder) InsertDebugMarker(markerLabel string)
- func (p *RenderBundleEncoder) PopDebugGroup()
- func (p *RenderBundleEncoder) PushDebugGroup(groupLabel string)
- func (p *RenderBundleEncoder) Release()
- func (p *RenderBundleEncoder) SetBindGroup(groupIndex uint32, group *BindGroup, dynamicOffsets []uint32)
- func (p *RenderBundleEncoder) SetIndexBuffer(buffer *Buffer, format IndexFormat, offset uint64, size uint64)
- func (p *RenderBundleEncoder) SetPipeline(pipeline *RenderPipeline)
- func (p *RenderBundleEncoder) SetVertexBuffer(slot uint32, buffer *Buffer, offset uint64, size uint64)
- type RenderBundleEncoderDescriptor
- type RenderPassColorAttachment
- type RenderPassDepthStencilAttachment
- type RenderPassDescriptor
- type RenderPassEncoder
- func (p *RenderPassEncoder) BeginOcclusionQuery(queryIndex uint32)
- func (p *RenderPassEncoder) BeginPipelineStatisticsQuery(querySet *QuerySet, queryIndex uint32)
- func (p *RenderPassEncoder) Draw(vertexCount, instanceCount, firstVertex, firstInstance uint32)
- func (p *RenderPassEncoder) DrawIndexed(indexCount uint32, instanceCount uint32, firstIndex uint32, baseVertex int32, ...)
- func (p *RenderPassEncoder) DrawIndexedIndirect(indirectBuffer *Buffer, indirectOffset uint64)
- func (p *RenderPassEncoder) DrawIndirect(indirectBuffer *Buffer, indirectOffset uint64)
- func (p *RenderPassEncoder) End() (err error)
- func (p *RenderPassEncoder) EndOcclusionQuery()
- func (p *RenderPassEncoder) EndPipelineStatisticsQuery()
- func (p *RenderPassEncoder) ExecuteBundles(bundles ...*RenderBundle)
- func (p *RenderPassEncoder) InsertDebugMarker(markerLabel string)
- func (p *RenderPassEncoder) MultiDrawIndexedIndirect(encoder *RenderPassEncoder, buffer Buffer, offset uint64, count uint32)
- func (p *RenderPassEncoder) MultiDrawIndexedIndirectCount(encoder *RenderPassEncoder, buffer Buffer, offset uint64, countBuffer Buffer, ...)
- func (p *RenderPassEncoder) MultiDrawIndirect(encoder *RenderPassEncoder, buffer Buffer, offset uint64, count uint32)
- func (p *RenderPassEncoder) MultiDrawIndirectCount(encoder *RenderPassEncoder, buffer Buffer, offset uint64, countBuffer Buffer, ...)
- func (p *RenderPassEncoder) PopDebugGroup()
- func (p *RenderPassEncoder) PushDebugGroup(groupLabel string)
- func (p *RenderPassEncoder) Release()
- func (p *RenderPassEncoder) SetBindGroup(groupIndex uint32, group *BindGroup, dynamicOffsets []uint32)
- func (p *RenderPassEncoder) SetBlendConstant(color *Color)
- func (p *RenderPassEncoder) SetIndexBuffer(buffer *Buffer, format IndexFormat, offset uint64, size uint64)
- func (p *RenderPassEncoder) SetPipeline(pipeline *RenderPipeline)
- func (p *RenderPassEncoder) SetPushConstants(stages ShaderStage, offset uint32, data []byte)
- func (p *RenderPassEncoder) SetScissorRect(x, y, width, height uint32)
- func (p *RenderPassEncoder) SetStencilReference(reference uint32)
- func (p *RenderPassEncoder) SetVertexBuffer(slot uint32, buffer *Buffer, offset uint64, size uint64)
- func (p *RenderPassEncoder) SetViewport(x, y, width, height, minDepth, maxDepth float32)
- type RenderPassTimestampLocation
- type RenderPipeline
- type RenderPipelineDescriptor
- type RequestAdapterOptions
- type RequestAdapterStatus
- type RequestDeviceStatus
- type RequiredLimits
- type Sampler
- type SamplerBindingLayout
- type SamplerBindingType
- type SamplerDescriptor
- type ShaderModule
- type ShaderModuleDescriptor
- type ShaderModuleGLSLDescriptor
- type ShaderModuleSPIRVDescriptor
- type ShaderModuleWGSLDescriptor
- type ShaderStage
- type StencilFaceState
- type StencilOperation
- type StorageReport
- type StorageTextureAccess
- type StorageTextureBindingLayout
- type StoreOp
- type SubmissionIndex
- type SupportedLimits
- type Surface
- type SurfaceCapabilities
- type SurfaceDescriptor
- type SurfaceDescriptorFromAndroidNativeWindow
- type SurfaceDescriptorFromMetalLayer
- type SurfaceDescriptorFromWaylandSurface
- type SurfaceDescriptorFromWindowsHWND
- type SurfaceDescriptorFromXcbWindow
- type SurfaceDescriptorFromXlibWindow
- type SwapChain
- type SwapChainDescriptor
- type Texture
- func (p *Texture) AsImageCopy() *ImageCopyTexture
- func (p *Texture) CreateView(descriptor *TextureViewDescriptor) (*TextureView, error)
- func (p *Texture) Destroy()
- func (p *Texture) GetDepthOrArrayLayers() uint32
- func (p *Texture) GetDimension() TextureDimension
- func (p *Texture) GetFormat() TextureFormat
- func (p *Texture) GetHeight() uint32
- func (p *Texture) GetMipLevelCount() uint32
- func (p *Texture) GetSampleCount() uint32
- func (p *Texture) GetUsage() TextureUsage
- func (p *Texture) GetWidth() uint32
- func (p *Texture) Release()
- type TextureAspect
- type TextureBindingLayout
- type TextureDataLayout
- type TextureDescriptor
- type TextureDimension
- type TextureFormat
- type TextureSampleType
- type TextureUsage
- type TextureView
- type TextureViewDescriptor
- type TextureViewDimension
- type Version
- type VertexAttribute
- type VertexBufferLayout
- type VertexFormat
- type VertexState
- type VertexStepMode
- type WrappedSubmissionIndex
Constants ¶
View Source
const ( ArrayLayerCountUndefined = 0xffffffff CopyStrideUndefined = 0xffffffff LimitU32Undefined uint32 = 0xffffffff LimitU64Undefined uint64 = 0xffffffffffffffff MipLevelCountUndefined = 0xffffffff WholeMapSize = ^uint(0) WholeSize = 0xffffffffffffffff )
View Source
const ( // Buffer-Texture copies must have `TextureDataLayout.BytesPerRow` aligned to this number. // // This doesn't apply to `(*Queue).WriteTexture()`. CopyBytesPerRowAlignment = 256 // An offset into the query resolve buffer has to be aligned to this. QueryResolveBufferAlignment = 256 // Buffer to buffer copy as well as buffer clear offsets and sizes must be aligned to this number. CopyBufferAlignment = 4 // Size to align mappings. MapAlignment = 8 // Vertex buffer strides have to be aligned to this number. VertexStrideAlignment = 4 // Alignment all push constants need PushConstantAlignment = 4 // Maximum queries in a query set QuerySetMaxQueries = 8192 // Size of a single piece of query data. QuerySize = 8 )
Variables ¶
View Source
var ( Color_Transparent = Color{0, 0, 0, 0} Color_Black = Color{0, 0, 0, 1} Color_White = Color{1, 1, 1, 1} Color_Red = Color{1, 0, 0, 1} Color_Green = Color{0, 1, 0, 1} Color_Blue = Color{0, 0, 1, 1} BlendComponent_Replace = BlendComponent{ SrcFactor: BlendFactor_One, DstFactor: BlendFactor_Zero, Operation: BlendOperation_Add, } BlendComponent_Over = BlendComponent{ SrcFactor: BlendFactor_One, DstFactor: BlendFactor_OneMinusSrcAlpha, Operation: BlendOperation_Add, } BlendState_Replace = BlendState{ Color: BlendComponent_Replace, Alpha: BlendComponent_Replace, } BlendState_AlphaBlending = BlendState{ Color: BlendComponent{ SrcFactor: BlendFactor_SrcAlpha, DstFactor: BlendFactor_OneMinusSrcAlpha, Operation: BlendOperation_Add, }, Alpha: BlendComponent_Over, } BlendState_PremultipliedAlphaBlending = BlendState{ Color: BlendComponent_Over, Alpha: BlendComponent_Over, } )
Functions ¶
func SetLogLevel ¶
func SetLogLevel(level LogLevel)
Types ¶
type Adapter ¶
type Adapter struct {
// contains filtered or unexported fields
}
func (*Adapter) EnumerateFeatures ¶
func (p *Adapter) EnumerateFeatures() []FeatureName
func (*Adapter) GetLimits ¶
func (p *Adapter) GetLimits() SupportedLimits
func (*Adapter) GetProperties ¶
func (p *Adapter) GetProperties() AdapterProperties
func (*Adapter) HasFeature ¶
func (p *Adapter) HasFeature(feature FeatureName) bool
func (*Adapter) RequestDevice ¶
func (p *Adapter) RequestDevice(descriptor *DeviceDescriptor) (*Device, error)
type AdapterProperties ¶
type AdapterProperties struct { VendorId uint32 VendorName string Architecture string DeviceId uint32 Name string DriverDescription string AdapterType AdapterType BackendType BackendType }
type AdapterType ¶
type AdapterType uint32
const ( AdapterType_DiscreteGPU AdapterType = 0x00000000 AdapterType_IntegratedGPU AdapterType = 0x00000001 AdapterType_CPU AdapterType = 0x00000002 AdapterType_Unknown AdapterType = 0x00000003 )
func (AdapterType) String ¶
func (v AdapterType) String() string
type AddressMode ¶
type AddressMode uint32
const ( AddressMode_Repeat AddressMode = 0x00000000 AddressMode_MirrorRepeat AddressMode = 0x00000001 AddressMode_ClampToEdge AddressMode = 0x00000002 )
func (AddressMode) String ¶
func (v AddressMode) String() string
type BackendType ¶
type BackendType uint32
const ( BackendType_Undefined BackendType = 0x00000000 BackendType_Null BackendType = 0x00000001 BackendType_WebGPU BackendType = 0x00000002 BackendType_D3D11 BackendType = 0x00000003 BackendType_D3D12 BackendType = 0x00000004 BackendType_Metal BackendType = 0x00000005 BackendType_Vulkan BackendType = 0x00000006 BackendType_OpenGL BackendType = 0x00000007 BackendType_OpenGLES BackendType = 0x00000008 )
func (BackendType) String ¶
func (v BackendType) String() string
type BindGroupDescriptor ¶
type BindGroupDescriptor struct { Label string Layout *BindGroupLayout Entries []BindGroupEntry }
type BindGroupEntry ¶
type BindGroupLayout ¶
type BindGroupLayout struct {
// contains filtered or unexported fields
}
func (*BindGroupLayout) Release ¶ added in v0.16.1
func (p *BindGroupLayout) Release()
type BindGroupLayoutDescriptor ¶
type BindGroupLayoutDescriptor struct { Label string Entries []BindGroupLayoutEntry }
type BindGroupLayoutEntry ¶
type BindGroupLayoutEntry struct { Binding uint32 Visibility ShaderStage Buffer BufferBindingLayout Sampler SamplerBindingLayout Texture TextureBindingLayout StorageTexture StorageTextureBindingLayout }
type BlendComponent ¶
type BlendComponent struct { Operation BlendOperation SrcFactor BlendFactor DstFactor BlendFactor }
type BlendFactor ¶
type BlendFactor uint32
const ( BlendFactor_Zero BlendFactor = 0x00000000 BlendFactor_One BlendFactor = 0x00000001 BlendFactor_Src BlendFactor = 0x00000002 BlendFactor_OneMinusSrc BlendFactor = 0x00000003 BlendFactor_SrcAlpha BlendFactor = 0x00000004 BlendFactor_OneMinusSrcAlpha BlendFactor = 0x00000005 BlendFactor_Dst BlendFactor = 0x00000006 BlendFactor_OneMinusDst BlendFactor = 0x00000007 BlendFactor_DstAlpha BlendFactor = 0x00000008 BlendFactor_OneMinusDstAlpha BlendFactor = 0x00000009 BlendFactor_SrcAlphaSaturated BlendFactor = 0x0000000A BlendFactor_Constant BlendFactor = 0x0000000B BlendFactor_OneMinusConstant BlendFactor = 0x0000000C )
func (BlendFactor) String ¶
func (v BlendFactor) String() string
type BlendOperation ¶
type BlendOperation uint32
const ( BlendOperation_Add BlendOperation = 0x00000000 BlendOperation_Subtract BlendOperation = 0x00000001 BlendOperation_ReverseSubtract BlendOperation = 0x00000002 BlendOperation_Min BlendOperation = 0x00000003 BlendOperation_Max BlendOperation = 0x00000004 )
func (BlendOperation) String ¶
func (v BlendOperation) String() string
type BlendState ¶
type BlendState struct { Color BlendComponent Alpha BlendComponent }
type Buffer ¶
type Buffer struct {
// contains filtered or unexported fields
}
func (*Buffer) GetMappedRange ¶
func (*Buffer) GetUsage ¶ added in v0.16.1
func (p *Buffer) GetUsage() BufferUsage
type BufferBindingLayout ¶
type BufferBindingLayout struct { Type BufferBindingType HasDynamicOffset bool MinBindingSize uint64 }
type BufferBindingType ¶
type BufferBindingType uint32
const ( BufferBindingType_Undefined BufferBindingType = 0x00000000 BufferBindingType_Uniform BufferBindingType = 0x00000001 BufferBindingType_Storage BufferBindingType = 0x00000002 BufferBindingType_ReadOnlyStorage BufferBindingType = 0x00000003 )
func (BufferBindingType) String ¶
func (v BufferBindingType) String() string
type BufferDescriptor ¶
type BufferDescriptor struct { Label string Usage BufferUsage Size uint64 MappedAtCreation bool }
type BufferInitDescriptor ¶
type BufferInitDescriptor struct { Label string Contents []byte Usage BufferUsage }
type BufferMapAsyncStatus ¶
type BufferMapAsyncStatus uint32
const ( BufferMapAsyncStatus_Success BufferMapAsyncStatus = 0x00000000 BufferMapAsyncStatus_ValidationError BufferMapAsyncStatus = 0x00000001 BufferMapAsyncStatus_Unknown BufferMapAsyncStatus = 0x00000002 BufferMapAsyncStatus_DeviceLost BufferMapAsyncStatus = 0x00000003 BufferMapAsyncStatus_DestroyedBeforeCallback BufferMapAsyncStatus = 0x00000004 BufferMapAsyncStatus_UnmappedBeforeCallback BufferMapAsyncStatus = 0x00000005 BufferMapAsyncStatus_MappingAlreadyPending BufferMapAsyncStatus = 0x00000006 BufferMapAsyncStatus_OffsetOutOfRange BufferMapAsyncStatus = 0x00000007 BufferMapAsyncStatus_SizeOutOfRange BufferMapAsyncStatus = 0x00000008 )
func (BufferMapAsyncStatus) String ¶
func (v BufferMapAsyncStatus) String() string
type BufferMapCallback ¶
type BufferMapCallback func(BufferMapAsyncStatus)
type BufferMapState ¶ added in v0.16.1
type BufferMapState uint32
const ( BufferMapState_Unmapped BufferMapState = 0x00000000 BufferMapState_Pending BufferMapState = 0x00000001 BufferMapState_Mapped BufferMapState = 0x00000002 )
func (BufferMapState) String ¶ added in v0.16.1
func (v BufferMapState) String() string
type BufferUsage ¶
type BufferUsage uint32
const ( BufferUsage_None BufferUsage = 0x00000000 BufferUsage_MapRead BufferUsage = 0x00000001 BufferUsage_MapWrite BufferUsage = 0x00000002 BufferUsage_CopySrc BufferUsage = 0x00000004 BufferUsage_CopyDst BufferUsage = 0x00000008 BufferUsage_Index BufferUsage = 0x00000010 BufferUsage_Vertex BufferUsage = 0x00000020 BufferUsage_Uniform BufferUsage = 0x00000040 BufferUsage_Storage BufferUsage = 0x00000080 BufferUsage_Indirect BufferUsage = 0x00000100 BufferUsage_QueryResolve BufferUsage = 0x00000200 )
func (BufferUsage) String ¶
func (v BufferUsage) String() string
type ColorTargetState ¶
type ColorTargetState struct { Format TextureFormat Blend *BlendState WriteMask ColorWriteMask }
type ColorWriteMask ¶
type ColorWriteMask uint32
const ( ColorWriteMask_None ColorWriteMask = 0x00000000 ColorWriteMask_Red ColorWriteMask = 0x00000001 ColorWriteMask_Green ColorWriteMask = 0x00000002 ColorWriteMask_Blue ColorWriteMask = 0x00000004 ColorWriteMask_Alpha ColorWriteMask = 0x00000008 ColorWriteMask_All ColorWriteMask = 0x0000000F )
func (ColorWriteMask) String ¶
func (v ColorWriteMask) String() string
type CommandBuffer ¶
type CommandBuffer struct {
// contains filtered or unexported fields
}
func (*CommandBuffer) Release ¶ added in v0.16.1
func (p *CommandBuffer) Release()
type CommandBufferDescriptor ¶
type CommandBufferDescriptor struct {
Label string
}
type CommandEncoder ¶
type CommandEncoder struct {
// contains filtered or unexported fields
}
func (*CommandEncoder) BeginComputePass ¶
func (p *CommandEncoder) BeginComputePass(descriptor *ComputePassDescriptor) *ComputePassEncoder
func (*CommandEncoder) BeginRenderPass ¶
func (p *CommandEncoder) BeginRenderPass(descriptor *RenderPassDescriptor) *RenderPassEncoder
func (*CommandEncoder) ClearBuffer ¶
func (p *CommandEncoder) ClearBuffer(buffer *Buffer, offset uint64, size uint64) (err error)
func (*CommandEncoder) CopyBufferToBuffer ¶
func (*CommandEncoder) CopyBufferToTexture ¶
func (p *CommandEncoder) CopyBufferToTexture(source *ImageCopyBuffer, destination *ImageCopyTexture, copySize *Extent3D) (err error)
func (*CommandEncoder) CopyTextureToBuffer ¶
func (p *CommandEncoder) CopyTextureToBuffer(source *ImageCopyTexture, destination *ImageCopyBuffer, copySize *Extent3D) (err error)
func (*CommandEncoder) CopyTextureToTexture ¶
func (p *CommandEncoder) CopyTextureToTexture(source *ImageCopyTexture, destination *ImageCopyTexture, copySize *Extent3D) (err error)
func (*CommandEncoder) Finish ¶
func (p *CommandEncoder) Finish(descriptor *CommandBufferDescriptor) (*CommandBuffer, error)
func (*CommandEncoder) InsertDebugMarker ¶
func (p *CommandEncoder) InsertDebugMarker(markerLabel string) (err error)
func (*CommandEncoder) PopDebugGroup ¶
func (p *CommandEncoder) PopDebugGroup() (err error)
func (*CommandEncoder) PushDebugGroup ¶
func (p *CommandEncoder) PushDebugGroup(groupLabel string) (err error)
func (*CommandEncoder) Release ¶ added in v0.16.1
func (p *CommandEncoder) Release()
func (*CommandEncoder) ResolveQuerySet ¶ added in v0.16.1
func (*CommandEncoder) WriteTimestamp ¶ added in v0.16.1
func (p *CommandEncoder) WriteTimestamp(querySet *QuerySet, queryIndex uint32) (err error)
type CommandEncoderDescriptor ¶
type CommandEncoderDescriptor struct {
Label string
}
type CompareFunction ¶
type CompareFunction uint32
const ( CompareFunction_Undefined CompareFunction = 0x00000000 CompareFunction_Never CompareFunction = 0x00000001 CompareFunction_Less CompareFunction = 0x00000002 CompareFunction_LessEqual CompareFunction = 0x00000003 CompareFunction_Greater CompareFunction = 0x00000004 CompareFunction_GreaterEqual CompareFunction = 0x00000005 CompareFunction_Equal CompareFunction = 0x00000006 CompareFunction_NotEqual CompareFunction = 0x00000007 CompareFunction_Always CompareFunction = 0x00000008 )
func (CompareFunction) String ¶
func (v CompareFunction) String() string
type CompilationInfoRequestStatus ¶
type CompilationInfoRequestStatus uint32
const ( CompilationInfoRequestStatus_Success CompilationInfoRequestStatus = 0x00000000 CompilationInfoRequestStatus_Error CompilationInfoRequestStatus = 0x00000001 CompilationInfoRequestStatus_DeviceLost CompilationInfoRequestStatus = 0x00000002 CompilationInfoRequestStatus_Unknown CompilationInfoRequestStatus = 0x00000003 )
func (CompilationInfoRequestStatus) String ¶
func (v CompilationInfoRequestStatus) String() string
type CompilationMessageType ¶
type CompilationMessageType uint32
const ( CompilationMessageType_Error CompilationMessageType = 0x00000000 CompilationMessageType_Warning CompilationMessageType = 0x00000001 CompilationMessageType_Info CompilationMessageType = 0x00000002 )
func (CompilationMessageType) String ¶
func (v CompilationMessageType) String() string
type CompositeAlphaMode ¶ added in v0.15.1
type CompositeAlphaMode uint32
const ( CompositeAlphaMode_Auto CompositeAlphaMode = 0x00000000 CompositeAlphaMode_Opaque CompositeAlphaMode = 0x00000001 CompositeAlphaMode_PreMultiplied CompositeAlphaMode = 0x00000002 CompositeAlphaMode_PostMultiplied CompositeAlphaMode = 0x00000003 CompositeAlphaMode_Inherit CompositeAlphaMode = 0x00000004 )
func (CompositeAlphaMode) String ¶ added in v0.15.1
func (v CompositeAlphaMode) String() string
type ComputePassDescriptor ¶
type ComputePassDescriptor struct {
Label string
}
type ComputePassEncoder ¶
type ComputePassEncoder struct {
// contains filtered or unexported fields
}
func (*ComputePassEncoder) BeginPipelineStatisticsQuery ¶ added in v0.16.1
func (p *ComputePassEncoder) BeginPipelineStatisticsQuery(querySet *QuerySet, queryIndex uint32)
func (*ComputePassEncoder) DispatchWorkgroups ¶
func (p *ComputePassEncoder) DispatchWorkgroups(workgroupCountX, workgroupCountY, workgroupCountZ uint32)
func (*ComputePassEncoder) DispatchWorkgroupsIndirect ¶
func (p *ComputePassEncoder) DispatchWorkgroupsIndirect(indirectBuffer *Buffer, indirectOffset uint64)
func (*ComputePassEncoder) End ¶
func (p *ComputePassEncoder) End() (err error)
func (*ComputePassEncoder) EndPipelineStatisticsQuery ¶ added in v0.16.1
func (p *ComputePassEncoder) EndPipelineStatisticsQuery()
func (*ComputePassEncoder) InsertDebugMarker ¶
func (p *ComputePassEncoder) InsertDebugMarker(markerLabel string)
func (*ComputePassEncoder) PopDebugGroup ¶
func (p *ComputePassEncoder) PopDebugGroup()
func (*ComputePassEncoder) PushDebugGroup ¶
func (p *ComputePassEncoder) PushDebugGroup(groupLabel string)
func (*ComputePassEncoder) Release ¶ added in v0.16.1
func (p *ComputePassEncoder) Release()
func (*ComputePassEncoder) SetBindGroup ¶
func (p *ComputePassEncoder) SetBindGroup(groupIndex uint32, group *BindGroup, dynamicOffsets []uint32)
func (*ComputePassEncoder) SetPipeline ¶
func (p *ComputePassEncoder) SetPipeline(pipeline *ComputePipeline)
type ComputePassTimestampLocation ¶
type ComputePassTimestampLocation uint32
const ( ComputePassTimestampLocation_Beginning ComputePassTimestampLocation = 0x00000000 ComputePassTimestampLocation_End ComputePassTimestampLocation = 0x00000001 )
func (ComputePassTimestampLocation) String ¶
func (v ComputePassTimestampLocation) String() string
type ComputePipeline ¶
type ComputePipeline struct {
// contains filtered or unexported fields
}
func (*ComputePipeline) GetBindGroupLayout ¶
func (p *ComputePipeline) GetBindGroupLayout(groupIndex uint32) *BindGroupLayout
func (*ComputePipeline) Release ¶ added in v0.16.1
func (p *ComputePipeline) Release()
type ComputePipelineDescriptor ¶
type ComputePipelineDescriptor struct { Label string Layout *PipelineLayout Compute ProgrammableStageDescriptor }
type ConstantEntry ¶
type CreatePipelineAsyncStatus ¶
type CreatePipelineAsyncStatus uint32
const ( CreatePipelineAsyncStatus_Success CreatePipelineAsyncStatus = 0x00000000 CreatePipelineAsyncStatus_ValidationError CreatePipelineAsyncStatus = 0x00000001 CreatePipelineAsyncStatus_InternalError CreatePipelineAsyncStatus = 0x00000002 CreatePipelineAsyncStatus_DeviceLost CreatePipelineAsyncStatus = 0x00000003 CreatePipelineAsyncStatus_DeviceDestroyed CreatePipelineAsyncStatus = 0x00000004 CreatePipelineAsyncStatus_Unknown CreatePipelineAsyncStatus = 0x00000005 )
func (CreatePipelineAsyncStatus) String ¶
func (v CreatePipelineAsyncStatus) String() string
type DepthStencilState ¶
type DepthStencilState struct { Format TextureFormat DepthWriteEnabled bool DepthCompare CompareFunction StencilFront StencilFaceState StencilBack StencilFaceState StencilReadMask uint32 StencilWriteMask uint32 DepthBias int32 DepthBiasSlopeScale float32 DepthBiasClamp float32 }
type Device ¶
type Device struct {
// contains filtered or unexported fields
}
func (*Device) CreateBindGroup ¶
func (p *Device) CreateBindGroup(descriptor *BindGroupDescriptor) (*BindGroup, error)
func (*Device) CreateBindGroupLayout ¶
func (p *Device) CreateBindGroupLayout(descriptor *BindGroupLayoutDescriptor) (*BindGroupLayout, error)
func (*Device) CreateBuffer ¶
func (p *Device) CreateBuffer(descriptor *BufferDescriptor) (*Buffer, error)
func (*Device) CreateBufferInit ¶
func (p *Device) CreateBufferInit(descriptor *BufferInitDescriptor) (*Buffer, error)
func (*Device) CreateCommandEncoder ¶
func (p *Device) CreateCommandEncoder(descriptor *CommandEncoderDescriptor) (*CommandEncoder, error)
func (*Device) CreateComputePipeline ¶
func (p *Device) CreateComputePipeline(descriptor *ComputePipelineDescriptor) (*ComputePipeline, error)
func (*Device) CreatePipelineLayout ¶
func (p *Device) CreatePipelineLayout(descriptor *PipelineLayoutDescriptor) (*PipelineLayout, error)
func (*Device) CreateQuerySet ¶ added in v0.16.1
func (p *Device) CreateQuerySet(descriptor *QuerySetDescriptor) (*QuerySet, error)
func (*Device) CreateRenderBundleEncoder ¶
func (p *Device) CreateRenderBundleEncoder(descriptor *RenderBundleEncoderDescriptor) (*RenderBundleEncoder, error)
func (*Device) CreateRenderPipeline ¶
func (p *Device) CreateRenderPipeline(descriptor *RenderPipelineDescriptor) (*RenderPipeline, error)
func (*Device) CreateSampler ¶
func (p *Device) CreateSampler(descriptor *SamplerDescriptor) (*Sampler, error)
func (*Device) CreateShaderModule ¶
func (p *Device) CreateShaderModule(descriptor *ShaderModuleDescriptor) (*ShaderModule, error)
func (*Device) CreateSwapChain ¶
func (p *Device) CreateSwapChain(surface *Surface, descriptor *SwapChainDescriptor) (*SwapChain, error)
func (*Device) CreateTexture ¶
func (p *Device) CreateTexture(descriptor *TextureDescriptor) (*Texture, error)
func (*Device) EnumerateFeatures ¶
func (p *Device) EnumerateFeatures() []FeatureName
func (*Device) GetLimits ¶
func (p *Device) GetLimits() SupportedLimits
func (*Device) HasFeature ¶
func (p *Device) HasFeature(feature FeatureName) bool
type DeviceDescriptor ¶
type DeviceDescriptor struct { Label string RequiredFeatures []FeatureName RequiredLimits *RequiredLimits DeviceLostCallback DeviceLostCallback TracePath string }
type DeviceLostCallback ¶ added in v0.16.1
type DeviceLostCallback func(reason DeviceLostReason, message string)
type DeviceLostReason ¶
type DeviceLostReason uint32
const ( DeviceLostReason_Undefined DeviceLostReason = 0x00000000 DeviceLostReason_Destroyed DeviceLostReason = 0x00000001 )
func (DeviceLostReason) String ¶
func (v DeviceLostReason) String() string
type Dx12Compiler ¶ added in v0.15.1
type Dx12Compiler uint32
const ( Dx12Compiler_Undefined Dx12Compiler = 0x00000000 Dx12Compiler_Fxc Dx12Compiler = 0x00000001 Dx12Compiler_Dxc Dx12Compiler = 0x00000002 )
func (Dx12Compiler) String ¶ added in v0.15.1
func (v Dx12Compiler) String() string
type ErrorFilter ¶
type ErrorFilter uint32
const ( ErrorFilter_Validation ErrorFilter = 0x00000000 ErrorFilter_OutOfMemory ErrorFilter = 0x00000001 ErrorFilter_Internal ErrorFilter = 0x00000002 )
func (ErrorFilter) String ¶
func (v ErrorFilter) String() string
type FeatureName ¶
type FeatureName uint32
const ( FeatureName_Undefined FeatureName = 0x00000000 FeatureName_DepthClipControl FeatureName = 0x00000001 FeatureName_Depth32FloatStencil8 FeatureName = 0x00000002 FeatureName_TimestampQuery FeatureName = 0x00000003 FeatureName_PipelineStatisticsQuery FeatureName = 0x00000004 FeatureName_TextureCompressionBC FeatureName = 0x00000005 FeatureName_TextureCompressionETC2 FeatureName = 0x00000006 FeatureName_TextureCompressionASTC FeatureName = 0x00000007 FeatureName_IndirectFirstInstance FeatureName = 0x00000008 FeatureName_ShaderF16 FeatureName = 0x00000009 FeatureName_RG11B10UfloatRenderable FeatureName = 0x0000000A FeatureName_BGRA8UnormStorage FeatureName = 0x0000000B FeatureName_Float32Filterable FeatureName = 0x0000000C NativeFeature_PushConstants FeatureName = 0x60000001 NativeFeature_TextureAdapterSpecificFormatFeatures FeatureName = 0x60000002 NativeFeature_MultiDrawIndirect FeatureName = 0x60000003 NativeFeature_MultiDrawIndirectCount FeatureName = 0x60000004 NativeFeature_VertexWritableStorage FeatureName = 0x60000005 )
func (FeatureName) String ¶
func (v FeatureName) String() string
type FilterMode ¶
type FilterMode uint32
const ( FilterMode_Nearest FilterMode = 0x00000000 FilterMode_Linear FilterMode = 0x00000001 )
func (FilterMode) String ¶
func (v FilterMode) String() string
type FragmentState ¶
type FragmentState struct { Module *ShaderModule EntryPoint string Targets []ColorTargetState }
type GlobalReport ¶
type HubReport ¶
type HubReport struct { Adapters StorageReport Devices StorageReport PipelineLayouts StorageReport ShaderModules StorageReport BindGroupLayouts StorageReport BindGroups StorageReport CommandBuffers StorageReport RenderBundles StorageReport RenderPipelines StorageReport ComputePipelines StorageReport QuerySets StorageReport Buffers StorageReport Textures StorageReport TextureViews StorageReport Samplers StorageReport }
type ImageCopyBuffer ¶
type ImageCopyBuffer struct { Layout TextureDataLayout Buffer *Buffer }
type ImageCopyTexture ¶
type ImageCopyTexture struct { Texture *Texture MipLevel uint32 Origin Origin3D Aspect TextureAspect }
type IndexFormat ¶
type IndexFormat uint32
const ( IndexFormat_Undefined IndexFormat = 0x00000000 IndexFormat_Uint16 IndexFormat = 0x00000001 IndexFormat_Uint32 IndexFormat = 0x00000002 )
func (IndexFormat) String ¶
func (v IndexFormat) String() string
type Instance ¶ added in v0.15.1
type Instance struct {
// contains filtered or unexported fields
}
func CreateInstance ¶ added in v0.15.1
func CreateInstance(descriptor *InstanceDescriptor) *Instance
func (*Instance) CreateSurface ¶ added in v0.15.1
func (p *Instance) CreateSurface(descriptor *SurfaceDescriptor) *Surface
func (*Instance) EnumerateAdapters ¶ added in v0.16.1
func (p *Instance) EnumerateAdapters(options *InstanceEnumerateAdapterOptons) []*Adapter
func (*Instance) GenerateReport ¶ added in v0.15.1
func (p *Instance) GenerateReport() GlobalReport
func (*Instance) RequestAdapter ¶ added in v0.15.1
func (p *Instance) RequestAdapter(options *RequestAdapterOptions) (*Adapter, error)
type InstanceBackend ¶ added in v0.15.1
type InstanceBackend uint32
const ( InstanceBackend_None InstanceBackend = 0x00000000 InstanceBackend_Vulkan InstanceBackend = 0x00000002 InstanceBackend_Metal InstanceBackend = 0x00000004 InstanceBackend_DX12 InstanceBackend = 0x00000008 InstanceBackend_DX11 InstanceBackend = 0x00000010 InstanceBackend_GL InstanceBackend = 0x00000020 InstanceBackend_Secondary InstanceBackend = 0x00000030 InstanceBackend_BrowserWebGPU InstanceBackend = 0x00000040 InstanceBackend_Primary InstanceBackend = 0x0000004E )
func (InstanceBackend) String ¶ added in v0.15.1
func (v InstanceBackend) String() string
type InstanceDescriptor ¶ added in v0.15.1
type InstanceDescriptor struct { Backends InstanceBackend Dx12ShaderCompiler Dx12Compiler DxilPath string DxcPath string }
type InstanceEnumerateAdapterOptons ¶ added in v0.16.1
type InstanceEnumerateAdapterOptons struct {
Backends InstanceBackend
}
type Limits ¶
type Limits struct { MaxTextureDimension1D uint32 MaxTextureDimension2D uint32 MaxTextureDimension3D uint32 MaxTextureArrayLayers uint32 MaxBindGroups uint32 MaxBindingsPerBindGroup uint32 MaxDynamicUniformBuffersPerPipelineLayout uint32 MaxDynamicStorageBuffersPerPipelineLayout uint32 MaxSampledTexturesPerShaderStage uint32 MaxSamplersPerShaderStage uint32 MaxStorageBuffersPerShaderStage uint32 MaxStorageTexturesPerShaderStage uint32 MaxUniformBuffersPerShaderStage uint32 MaxUniformBufferBindingSize uint64 MaxStorageBufferBindingSize uint64 MinUniformBufferOffsetAlignment uint32 MinStorageBufferOffsetAlignment uint32 MaxVertexBuffers uint32 MaxBufferSize uint64 MaxVertexAttributes uint32 MaxVertexBufferArrayStride uint32 MaxInterStageShaderComponents uint32 MaxInterStageShaderVariables uint32 MaxColorAttachments uint32 MaxColorAttachmentBytesPerSample uint32 MaxComputeWorkgroupStorageSize uint32 MaxComputeInvocationsPerWorkgroup uint32 MaxComputeWorkgroupSizeX uint32 MaxComputeWorkgroupSizeY uint32 MaxComputeWorkgroupSizeZ uint32 MaxComputeWorkgroupsPerDimension uint32 MaxPushConstantSize uint32 }
func DefaultLimits ¶ added in v0.15.1
func DefaultLimits() Limits
type MipmapFilterMode ¶
type MipmapFilterMode uint32
const ( MipmapFilterMode_Nearest MipmapFilterMode = 0x00000000 MipmapFilterMode_Linear MipmapFilterMode = 0x00000001 )
func (MipmapFilterMode) String ¶
func (v MipmapFilterMode) String() string
type MultisampleState ¶
type PipelineLayout ¶
type PipelineLayout struct {
// contains filtered or unexported fields
}
func (*PipelineLayout) Release ¶ added in v0.16.1
func (p *PipelineLayout) Release()
type PipelineLayoutDescriptor ¶
type PipelineLayoutDescriptor struct { Label string BindGroupLayouts []*BindGroupLayout PushConstantRanges []PushConstantRange }
type PipelineStatisticName ¶
type PipelineStatisticName uint32
const ( PipelineStatisticName_VertexShaderInvocations PipelineStatisticName = 0x00000000 PipelineStatisticName_ClipperInvocations PipelineStatisticName = 0x00000001 PipelineStatisticName_ClipperPrimitivesOut PipelineStatisticName = 0x00000002 PipelineStatisticName_FragmentShaderInvocations PipelineStatisticName = 0x00000003 PipelineStatisticName_ComputeShaderInvocations PipelineStatisticName = 0x00000004 )
func (PipelineStatisticName) String ¶
func (v PipelineStatisticName) String() string
type PowerPreference ¶
type PowerPreference uint32
const ( PowerPreference_Undefined PowerPreference = 0x00000000 PowerPreference_LowPower PowerPreference = 0x00000001 PowerPreference_HighPerformance PowerPreference = 0x00000002 )
func (PowerPreference) String ¶
func (v PowerPreference) String() string
type PresentMode ¶
type PresentMode uint32
const ( PresentMode_Immediate PresentMode = 0x00000000 PresentMode_Mailbox PresentMode = 0x00000001 PresentMode_Fifo PresentMode = 0x00000002 )
func (PresentMode) String ¶
func (v PresentMode) String() string
type PrimitiveState ¶
type PrimitiveState struct { Topology PrimitiveTopology StripIndexFormat IndexFormat FrontFace FrontFace CullMode CullMode }
type PrimitiveTopology ¶
type PrimitiveTopology uint32
const ( PrimitiveTopology_PointList PrimitiveTopology = 0x00000000 PrimitiveTopology_LineList PrimitiveTopology = 0x00000001 PrimitiveTopology_LineStrip PrimitiveTopology = 0x00000002 PrimitiveTopology_TriangleList PrimitiveTopology = 0x00000003 PrimitiveTopology_TriangleStrip PrimitiveTopology = 0x00000004 )
func (PrimitiveTopology) String ¶
func (v PrimitiveTopology) String() string
type ProgrammableStageDescriptor ¶
type ProgrammableStageDescriptor struct { Module *ShaderModule EntryPoint string }
type PushConstantRange ¶
type PushConstantRange struct { Stages ShaderStage Start uint32 End uint32 }
type QuerySetDescriptor ¶ added in v0.16.1
type QuerySetDescriptor struct { Label string Type QueryType Count uint32 PipelineStatistics []PipelineStatisticName }
type Queue ¶
type Queue struct {
// contains filtered or unexported fields
}
func (*Queue) OnSubmittedWorkDone ¶ added in v0.16.1
func (p *Queue) OnSubmittedWorkDone(callback QueueWorkDoneCallback)
func (*Queue) Submit ¶
func (p *Queue) Submit(commands ...*CommandBuffer) (submissionIndex SubmissionIndex)
func (*Queue) WriteBuffer ¶
func (*Queue) WriteTexture ¶
func (p *Queue) WriteTexture(destination *ImageCopyTexture, data []byte, dataLayout *TextureDataLayout, writeSize *Extent3D) (err error)
type QueueWorkDoneCallback ¶ added in v0.16.1
type QueueWorkDoneCallback func(QueueWorkDoneStatus)
type QueueWorkDoneStatus ¶
type QueueWorkDoneStatus uint32
const ( QueueWorkDoneStatus_Success QueueWorkDoneStatus = 0x00000000 QueueWorkDoneStatus_Error QueueWorkDoneStatus = 0x00000001 QueueWorkDoneStatus_Unknown QueueWorkDoneStatus = 0x00000002 QueueWorkDoneStatus_DeviceLost QueueWorkDoneStatus = 0x00000003 )
func (QueueWorkDoneStatus) String ¶
func (v QueueWorkDoneStatus) String() string
type RenderBundle ¶
type RenderBundle struct {
// contains filtered or unexported fields
}
func (*RenderBundle) Release ¶ added in v0.16.1
func (p *RenderBundle) Release()
type RenderBundleDescriptor ¶
type RenderBundleDescriptor struct {
Label string
}
type RenderBundleEncoder ¶
type RenderBundleEncoder struct {
// contains filtered or unexported fields
}
func (*RenderBundleEncoder) Draw ¶
func (p *RenderBundleEncoder) Draw(vertexCount, instanceCount, firstVertex, firstInstance uint32)
func (*RenderBundleEncoder) DrawIndexed ¶
func (p *RenderBundleEncoder) DrawIndexed(indexCount, instanceCount, firstIndex, baseVertex, firstInstance uint32)
func (*RenderBundleEncoder) DrawIndexedIndirect ¶
func (p *RenderBundleEncoder) DrawIndexedIndirect(indirectBuffer *Buffer, indirectOffset uint64)
func (*RenderBundleEncoder) DrawIndirect ¶
func (p *RenderBundleEncoder) DrawIndirect(indirectBuffer *Buffer, indirectOffset uint64)
func (*RenderBundleEncoder) Finish ¶
func (p *RenderBundleEncoder) Finish(descriptor *RenderBundleDescriptor) *RenderBundle
func (*RenderBundleEncoder) InsertDebugMarker ¶
func (p *RenderBundleEncoder) InsertDebugMarker(markerLabel string)
func (*RenderBundleEncoder) PopDebugGroup ¶
func (p *RenderBundleEncoder) PopDebugGroup()
func (*RenderBundleEncoder) PushDebugGroup ¶
func (p *RenderBundleEncoder) PushDebugGroup(groupLabel string)
func (*RenderBundleEncoder) Release ¶ added in v0.16.1
func (p *RenderBundleEncoder) Release()
func (*RenderBundleEncoder) SetBindGroup ¶
func (p *RenderBundleEncoder) SetBindGroup(groupIndex uint32, group *BindGroup, dynamicOffsets []uint32)
func (*RenderBundleEncoder) SetIndexBuffer ¶
func (p *RenderBundleEncoder) SetIndexBuffer(buffer *Buffer, format IndexFormat, offset uint64, size uint64)
func (*RenderBundleEncoder) SetPipeline ¶
func (p *RenderBundleEncoder) SetPipeline(pipeline *RenderPipeline)
func (*RenderBundleEncoder) SetVertexBuffer ¶
func (p *RenderBundleEncoder) SetVertexBuffer(slot uint32, buffer *Buffer, offset uint64, size uint64)
type RenderBundleEncoderDescriptor ¶
type RenderBundleEncoderDescriptor struct { Label string ColorFormats []TextureFormat DepthStencilFormat TextureFormat SampleCount uint32 DepthReadOnly bool StencilReadOnly bool }
type RenderPassColorAttachment ¶
type RenderPassColorAttachment struct { View *TextureView ResolveTarget *TextureView LoadOp LoadOp StoreOp StoreOp ClearValue Color }
type RenderPassDescriptor ¶
type RenderPassDescriptor struct { Label string ColorAttachments []RenderPassColorAttachment DepthStencilAttachment *RenderPassDepthStencilAttachment }
type RenderPassEncoder ¶
type RenderPassEncoder struct {
// contains filtered or unexported fields
}
func (*RenderPassEncoder) BeginOcclusionQuery ¶ added in v0.16.1
func (p *RenderPassEncoder) BeginOcclusionQuery(queryIndex uint32)
func (*RenderPassEncoder) BeginPipelineStatisticsQuery ¶ added in v0.16.1
func (p *RenderPassEncoder) BeginPipelineStatisticsQuery(querySet *QuerySet, queryIndex uint32)
func (*RenderPassEncoder) Draw ¶
func (p *RenderPassEncoder) Draw(vertexCount, instanceCount, firstVertex, firstInstance uint32)
func (*RenderPassEncoder) DrawIndexed ¶
func (*RenderPassEncoder) DrawIndexedIndirect ¶
func (p *RenderPassEncoder) DrawIndexedIndirect(indirectBuffer *Buffer, indirectOffset uint64)
func (*RenderPassEncoder) DrawIndirect ¶
func (p *RenderPassEncoder) DrawIndirect(indirectBuffer *Buffer, indirectOffset uint64)
func (*RenderPassEncoder) End ¶
func (p *RenderPassEncoder) End() (err error)
func (*RenderPassEncoder) EndOcclusionQuery ¶ added in v0.16.1
func (p *RenderPassEncoder) EndOcclusionQuery()
func (*RenderPassEncoder) EndPipelineStatisticsQuery ¶ added in v0.16.1
func (p *RenderPassEncoder) EndPipelineStatisticsQuery()
func (*RenderPassEncoder) ExecuteBundles ¶
func (p *RenderPassEncoder) ExecuteBundles(bundles ...*RenderBundle)
func (*RenderPassEncoder) InsertDebugMarker ¶
func (p *RenderPassEncoder) InsertDebugMarker(markerLabel string)
func (*RenderPassEncoder) MultiDrawIndexedIndirect ¶ added in v0.1.4
func (p *RenderPassEncoder) MultiDrawIndexedIndirect(encoder *RenderPassEncoder, buffer Buffer, offset uint64, count uint32)
func (*RenderPassEncoder) MultiDrawIndexedIndirectCount ¶ added in v0.1.4
func (p *RenderPassEncoder) MultiDrawIndexedIndirectCount(encoder *RenderPassEncoder, buffer Buffer, offset uint64, countBuffer Buffer, countBufferOffset uint64, maxCount uint32)
func (*RenderPassEncoder) MultiDrawIndirect ¶ added in v0.1.4
func (p *RenderPassEncoder) MultiDrawIndirect(encoder *RenderPassEncoder, buffer Buffer, offset uint64, count uint32)
func (*RenderPassEncoder) MultiDrawIndirectCount ¶ added in v0.1.4
func (p *RenderPassEncoder) MultiDrawIndirectCount(encoder *RenderPassEncoder, buffer Buffer, offset uint64, countBuffer Buffer, countBufferOffset uint64, maxCount uint32)
func (*RenderPassEncoder) PopDebugGroup ¶
func (p *RenderPassEncoder) PopDebugGroup()
func (*RenderPassEncoder) PushDebugGroup ¶
func (p *RenderPassEncoder) PushDebugGroup(groupLabel string)
func (*RenderPassEncoder) Release ¶ added in v0.16.1
func (p *RenderPassEncoder) Release()
func (*RenderPassEncoder) SetBindGroup ¶
func (p *RenderPassEncoder) SetBindGroup(groupIndex uint32, group *BindGroup, dynamicOffsets []uint32)
func (*RenderPassEncoder) SetBlendConstant ¶
func (p *RenderPassEncoder) SetBlendConstant(color *Color)
func (*RenderPassEncoder) SetIndexBuffer ¶
func (p *RenderPassEncoder) SetIndexBuffer(buffer *Buffer, format IndexFormat, offset uint64, size uint64)
func (*RenderPassEncoder) SetPipeline ¶
func (p *RenderPassEncoder) SetPipeline(pipeline *RenderPipeline)
func (*RenderPassEncoder) SetPushConstants ¶
func (p *RenderPassEncoder) SetPushConstants(stages ShaderStage, offset uint32, data []byte)
func (*RenderPassEncoder) SetScissorRect ¶
func (p *RenderPassEncoder) SetScissorRect(x, y, width, height uint32)
func (*RenderPassEncoder) SetStencilReference ¶
func (p *RenderPassEncoder) SetStencilReference(reference uint32)
func (*RenderPassEncoder) SetVertexBuffer ¶
func (p *RenderPassEncoder) SetVertexBuffer(slot uint32, buffer *Buffer, offset uint64, size uint64)
func (*RenderPassEncoder) SetViewport ¶
func (p *RenderPassEncoder) SetViewport(x, y, width, height, minDepth, maxDepth float32)
type RenderPassTimestampLocation ¶
type RenderPassTimestampLocation uint32
const ( RenderPassTimestampLocation_Beginning RenderPassTimestampLocation = 0x00000000 RenderPassTimestampLocation_End RenderPassTimestampLocation = 0x00000001 )
func (RenderPassTimestampLocation) String ¶
func (v RenderPassTimestampLocation) String() string
type RenderPipeline ¶
type RenderPipeline struct {
// contains filtered or unexported fields
}
func (*RenderPipeline) GetBindGroupLayout ¶
func (p *RenderPipeline) GetBindGroupLayout(groupIndex uint32) *BindGroupLayout
func (*RenderPipeline) Release ¶ added in v0.16.1
func (p *RenderPipeline) Release()
type RenderPipelineDescriptor ¶
type RenderPipelineDescriptor struct { Label string Layout *PipelineLayout Vertex VertexState Primitive PrimitiveState DepthStencil *DepthStencilState Multisample MultisampleState Fragment *FragmentState }
type RequestAdapterOptions ¶
type RequestAdapterOptions struct { CompatibleSurface *Surface PowerPreference PowerPreference ForceFallbackAdapter bool BackendType BackendType }
type RequestAdapterStatus ¶
type RequestAdapterStatus uint32
const ( RequestAdapterStatus_Success RequestAdapterStatus = 0x00000000 RequestAdapterStatus_Error RequestAdapterStatus = 0x00000002 RequestAdapterStatus_Unknown RequestAdapterStatus = 0x00000003 )
func (RequestAdapterStatus) String ¶
func (v RequestAdapterStatus) String() string
type RequestDeviceStatus ¶
type RequestDeviceStatus uint32
const ( RequestDeviceStatus_Success RequestDeviceStatus = 0x00000000 RequestDeviceStatus_Error RequestDeviceStatus = 0x00000001 RequestDeviceStatus_Unknown RequestDeviceStatus = 0x00000002 )
func (RequestDeviceStatus) String ¶
func (v RequestDeviceStatus) String() string
type RequiredLimits ¶
type RequiredLimits struct {
Limits Limits
}
type SamplerBindingLayout ¶
type SamplerBindingLayout struct {
Type SamplerBindingType
}
type SamplerBindingType ¶
type SamplerBindingType uint32
const ( SamplerBindingType_Undefined SamplerBindingType = 0x00000000 SamplerBindingType_Filtering SamplerBindingType = 0x00000001 SamplerBindingType_NonFiltering SamplerBindingType = 0x00000002 SamplerBindingType_Comparison SamplerBindingType = 0x00000003 )
func (SamplerBindingType) String ¶
func (v SamplerBindingType) String() string
type SamplerDescriptor ¶
type SamplerDescriptor struct { Label string AddressModeU AddressMode AddressModeV AddressMode AddressModeW AddressMode MagFilter FilterMode MinFilter FilterMode MipmapFilter MipmapFilterMode LodMinClamp float32 LodMaxClamp float32 Compare CompareFunction MaxAnisotrophy uint16 }
type ShaderModule ¶
type ShaderModule struct {
// contains filtered or unexported fields
}
func (*ShaderModule) Release ¶ added in v0.16.1
func (p *ShaderModule) Release()
type ShaderModuleDescriptor ¶
type ShaderModuleDescriptor struct { Label string SPIRVDescriptor *ShaderModuleSPIRVDescriptor WGSLDescriptor *ShaderModuleWGSLDescriptor GLSLDescriptor *ShaderModuleGLSLDescriptor }
type ShaderModuleGLSLDescriptor ¶
type ShaderModuleGLSLDescriptor struct { Code string Defines map[string]string ShaderStage ShaderStage }
type ShaderModuleSPIRVDescriptor ¶
type ShaderModuleSPIRVDescriptor struct {
Code []byte
}
type ShaderModuleWGSLDescriptor ¶
type ShaderModuleWGSLDescriptor struct {
Code string
}
type ShaderStage ¶
type ShaderStage uint32
const ( ShaderStage_None ShaderStage = 0x00000000 ShaderStage_Vertex ShaderStage = 0x00000001 ShaderStage_Fragment ShaderStage = 0x00000002 ShaderStage_Compute ShaderStage = 0x00000004 )
func (ShaderStage) String ¶
func (v ShaderStage) String() string
type StencilFaceState ¶
type StencilFaceState struct { Compare CompareFunction FailOp StencilOperation DepthFailOp StencilOperation PassOp StencilOperation }
type StencilOperation ¶
type StencilOperation uint32
const ( StencilOperation_Keep StencilOperation = 0x00000000 StencilOperation_Zero StencilOperation = 0x00000001 StencilOperation_Replace StencilOperation = 0x00000002 StencilOperation_Invert StencilOperation = 0x00000003 StencilOperation_IncrementClamp StencilOperation = 0x00000004 StencilOperation_DecrementClamp StencilOperation = 0x00000005 StencilOperation_IncrementWrap StencilOperation = 0x00000006 StencilOperation_DecrementWrap StencilOperation = 0x00000007 )
func (StencilOperation) String ¶
func (v StencilOperation) String() string
type StorageReport ¶
type StorageTextureAccess ¶
type StorageTextureAccess uint32
const ( StorageTextureAccess_Undefined StorageTextureAccess = 0x00000000 StorageTextureAccess_WriteOnly StorageTextureAccess = 0x00000001 )
func (StorageTextureAccess) String ¶
func (v StorageTextureAccess) String() string
type StorageTextureBindingLayout ¶
type StorageTextureBindingLayout struct { Access StorageTextureAccess Format TextureFormat ViewDimension TextureViewDimension }
type SubmissionIndex ¶
type SubmissionIndex uint64
type SupportedLimits ¶
type SupportedLimits struct {
Limits Limits
}
type Surface ¶
type Surface struct {
// contains filtered or unexported fields
}
func (*Surface) GetCapabilities ¶ added in v0.15.1
func (p *Surface) GetCapabilities(adapter *Adapter) (ret SurfaceCapabilities)
func (*Surface) GetPreferredFormat ¶
func (p *Surface) GetPreferredFormat(adapter *Adapter) TextureFormat
type SurfaceCapabilities ¶ added in v0.15.1
type SurfaceCapabilities struct { Formats []TextureFormat PresentModes []PresentMode AlphaModes []CompositeAlphaMode }
type SurfaceDescriptor ¶
type SurfaceDescriptor struct { Label string WindowsHWND *SurfaceDescriptorFromWindowsHWND XcbWindow *SurfaceDescriptorFromXcbWindow XlibWindow *SurfaceDescriptorFromXlibWindow MetalLayer *SurfaceDescriptorFromMetalLayer WaylandSurface *SurfaceDescriptorFromWaylandSurface AndroidNativeWindow *SurfaceDescriptorFromAndroidNativeWindow }
type SwapChain ¶
type SwapChain struct {
// contains filtered or unexported fields
}
func (*SwapChain) GetCurrentTextureView ¶
func (p *SwapChain) GetCurrentTextureView() (*TextureView, error)
type SwapChainDescriptor ¶
type SwapChainDescriptor struct { Usage TextureUsage Format TextureFormat Width uint32 Height uint32 PresentMode PresentMode AlphaMode CompositeAlphaMode ViewFormats []TextureFormat }
type Texture ¶
type Texture struct {
// contains filtered or unexported fields
}
func (*Texture) AsImageCopy ¶
func (p *Texture) AsImageCopy() *ImageCopyTexture
func (*Texture) CreateView ¶
func (p *Texture) CreateView(descriptor *TextureViewDescriptor) (*TextureView, error)
func (*Texture) GetDepthOrArrayLayers ¶ added in v0.16.1
func (*Texture) GetDimension ¶ added in v0.16.1
func (p *Texture) GetDimension() TextureDimension
func (*Texture) GetFormat ¶ added in v0.16.1
func (p *Texture) GetFormat() TextureFormat
func (*Texture) GetMipLevelCount ¶ added in v0.16.1
func (*Texture) GetSampleCount ¶ added in v0.16.1
func (*Texture) GetUsage ¶ added in v0.16.1
func (p *Texture) GetUsage() TextureUsage
type TextureAspect ¶
type TextureAspect uint32
const ( TextureAspect_All TextureAspect = 0x00000000 TextureAspect_StencilOnly TextureAspect = 0x00000001 TextureAspect_DepthOnly TextureAspect = 0x00000002 )
func (TextureAspect) String ¶
func (v TextureAspect) String() string
type TextureBindingLayout ¶
type TextureBindingLayout struct { SampleType TextureSampleType ViewDimension TextureViewDimension Multisampled bool }
type TextureDataLayout ¶
type TextureDescriptor ¶
type TextureDescriptor struct { Label string Usage TextureUsage Dimension TextureDimension Size Extent3D Format TextureFormat MipLevelCount uint32 SampleCount uint32 }
type TextureDimension ¶
type TextureDimension uint32
const ( TextureDimension_1D TextureDimension = 0x00000000 TextureDimension_2D TextureDimension = 0x00000001 TextureDimension_3D TextureDimension = 0x00000002 )
func (TextureDimension) String ¶
func (v TextureDimension) String() string
type TextureFormat ¶
type TextureFormat uint32
const ( TextureFormat_Undefined TextureFormat = 0x00000000 TextureFormat_R8Unorm TextureFormat = 0x00000001 TextureFormat_R8Snorm TextureFormat = 0x00000002 TextureFormat_R8Uint TextureFormat = 0x00000003 TextureFormat_R8Sint TextureFormat = 0x00000004 TextureFormat_R16Uint TextureFormat = 0x00000005 TextureFormat_R16Sint TextureFormat = 0x00000006 TextureFormat_R16Float TextureFormat = 0x00000007 TextureFormat_RG8Unorm TextureFormat = 0x00000008 TextureFormat_RG8Snorm TextureFormat = 0x00000009 TextureFormat_RG8Uint TextureFormat = 0x0000000A TextureFormat_RG8Sint TextureFormat = 0x0000000B TextureFormat_R32Float TextureFormat = 0x0000000C TextureFormat_R32Uint TextureFormat = 0x0000000D TextureFormat_R32Sint TextureFormat = 0x0000000E TextureFormat_RG16Uint TextureFormat = 0x0000000F TextureFormat_RG16Sint TextureFormat = 0x00000010 TextureFormat_RG16Float TextureFormat = 0x00000011 TextureFormat_RGBA8Unorm TextureFormat = 0x00000012 TextureFormat_RGBA8UnormSrgb TextureFormat = 0x00000013 TextureFormat_RGBA8Snorm TextureFormat = 0x00000014 TextureFormat_RGBA8Uint TextureFormat = 0x00000015 TextureFormat_RGBA8Sint TextureFormat = 0x00000016 TextureFormat_BGRA8Unorm TextureFormat = 0x00000017 TextureFormat_BGRA8UnormSrgb TextureFormat = 0x00000018 TextureFormat_RGB10A2Unorm TextureFormat = 0x00000019 TextureFormat_RG11B10Ufloat TextureFormat = 0x0000001A TextureFormat_RGB9E5Ufloat TextureFormat = 0x0000001B TextureFormat_RG32Float TextureFormat = 0x0000001C TextureFormat_RG32Uint TextureFormat = 0x0000001D TextureFormat_RG32Sint TextureFormat = 0x0000001E TextureFormat_RGBA16Uint TextureFormat = 0x0000001F TextureFormat_RGBA16Sint TextureFormat = 0x00000020 TextureFormat_RGBA16Float TextureFormat = 0x00000021 TextureFormat_RGBA32Float TextureFormat = 0x00000022 TextureFormat_RGBA32Uint TextureFormat = 0x00000023 TextureFormat_RGBA32Sint TextureFormat = 0x00000024 TextureFormat_Stencil8 TextureFormat = 0x00000025 TextureFormat_Depth16Unorm TextureFormat = 0x00000026 TextureFormat_Depth24Plus TextureFormat = 0x00000027 TextureFormat_Depth24PlusStencil8 TextureFormat = 0x00000028 TextureFormat_Depth32Float TextureFormat = 0x00000029 TextureFormat_Depth32FloatStencil8 TextureFormat = 0x0000002A TextureFormat_BC1RGBAUnorm TextureFormat = 0x0000002B TextureFormat_BC1RGBAUnormSrgb TextureFormat = 0x0000002C TextureFormat_BC2RGBAUnorm TextureFormat = 0x0000002D TextureFormat_BC2RGBAUnormSrgb TextureFormat = 0x0000002E TextureFormat_BC3RGBAUnorm TextureFormat = 0x0000002F TextureFormat_BC3RGBAUnormSrgb TextureFormat = 0x00000030 TextureFormat_BC4RUnorm TextureFormat = 0x00000031 TextureFormat_BC4RSnorm TextureFormat = 0x00000032 TextureFormat_BC5RGUnorm TextureFormat = 0x00000033 TextureFormat_BC5RGSnorm TextureFormat = 0x00000034 TextureFormat_BC6HRGBUfloat TextureFormat = 0x00000035 TextureFormat_BC6HRGBFloat TextureFormat = 0x00000036 TextureFormat_BC7RGBAUnorm TextureFormat = 0x00000037 TextureFormat_BC7RGBAUnormSrgb TextureFormat = 0x00000038 TextureFormat_ETC2RGB8Unorm TextureFormat = 0x00000039 TextureFormat_ETC2RGB8UnormSrgb TextureFormat = 0x0000003A TextureFormat_ETC2RGB8A1Unorm TextureFormat = 0x0000003B TextureFormat_ETC2RGB8A1UnormSrgb TextureFormat = 0x0000003C TextureFormat_ETC2RGBA8Unorm TextureFormat = 0x0000003D TextureFormat_ETC2RGBA8UnormSrgb TextureFormat = 0x0000003E TextureFormat_EACR11Unorm TextureFormat = 0x0000003F TextureFormat_EACR11Snorm TextureFormat = 0x00000040 TextureFormat_EACRG11Unorm TextureFormat = 0x00000041 TextureFormat_EACRG11Snorm TextureFormat = 0x00000042 TextureFormat_ASTC4x4Unorm TextureFormat = 0x00000043 TextureFormat_ASTC4x4UnormSrgb TextureFormat = 0x00000044 TextureFormat_ASTC5x4Unorm TextureFormat = 0x00000045 TextureFormat_ASTC5x4UnormSrgb TextureFormat = 0x00000046 TextureFormat_ASTC5x5Unorm TextureFormat = 0x00000047 TextureFormat_ASTC5x5UnormSrgb TextureFormat = 0x00000048 TextureFormat_ASTC6x5Unorm TextureFormat = 0x00000049 TextureFormat_ASTC6x5UnormSrgb TextureFormat = 0x0000004A TextureFormat_ASTC6x6Unorm TextureFormat = 0x0000004B TextureFormat_ASTC6x6UnormSrgb TextureFormat = 0x0000004C TextureFormat_ASTC8x5Unorm TextureFormat = 0x0000004D TextureFormat_ASTC8x5UnormSrgb TextureFormat = 0x0000004E TextureFormat_ASTC8x6Unorm TextureFormat = 0x0000004F TextureFormat_ASTC8x6UnormSrgb TextureFormat = 0x00000050 TextureFormat_ASTC8x8Unorm TextureFormat = 0x00000051 TextureFormat_ASTC8x8UnormSrgb TextureFormat = 0x00000052 TextureFormat_ASTC10x5Unorm TextureFormat = 0x00000053 TextureFormat_ASTC10x5UnormSrgb TextureFormat = 0x00000054 TextureFormat_ASTC10x6Unorm TextureFormat = 0x00000055 TextureFormat_ASTC10x6UnormSrgb TextureFormat = 0x00000056 TextureFormat_ASTC10x8Unorm TextureFormat = 0x00000057 TextureFormat_ASTC10x8UnormSrgb TextureFormat = 0x00000058 TextureFormat_ASTC10x10Unorm TextureFormat = 0x00000059 TextureFormat_ASTC10x10UnormSrgb TextureFormat = 0x0000005A TextureFormat_ASTC12x10Unorm TextureFormat = 0x0000005B TextureFormat_ASTC12x10UnormSrgb TextureFormat = 0x0000005C TextureFormat_ASTC12x12Unorm TextureFormat = 0x0000005D TextureFormat_ASTC12x12UnormSrgb TextureFormat = 0x0000005E )
func (TextureFormat) String ¶
func (v TextureFormat) String() string
type TextureSampleType ¶
type TextureSampleType uint32
const ( TextureSampleType_Undefined TextureSampleType = 0x00000000 TextureSampleType_Float TextureSampleType = 0x00000001 TextureSampleType_UnfilterableFloat TextureSampleType = 0x00000002 TextureSampleType_Depth TextureSampleType = 0x00000003 TextureSampleType_Sint TextureSampleType = 0x00000004 TextureSampleType_Uint TextureSampleType = 0x00000005 )
func (TextureSampleType) String ¶
func (v TextureSampleType) String() string
type TextureUsage ¶
type TextureUsage uint32
const ( TextureUsage_None TextureUsage = 0x00000000 TextureUsage_CopySrc TextureUsage = 0x00000001 TextureUsage_CopyDst TextureUsage = 0x00000002 TextureUsage_TextureBinding TextureUsage = 0x00000004 TextureUsage_StorageBinding TextureUsage = 0x00000008 TextureUsage_RenderAttachment TextureUsage = 0x00000010 )
func (TextureUsage) String ¶
func (v TextureUsage) String() string
type TextureView ¶
type TextureView struct {
// contains filtered or unexported fields
}
func (*TextureView) Release ¶ added in v0.16.1
func (p *TextureView) Release()
type TextureViewDescriptor ¶
type TextureViewDescriptor struct { Label string Format TextureFormat Dimension TextureViewDimension BaseMipLevel uint32 MipLevelCount uint32 BaseArrayLayer uint32 ArrayLayerCount uint32 Aspect TextureAspect }
type TextureViewDimension ¶
type TextureViewDimension uint32
const ( TextureViewDimension_Undefined TextureViewDimension = 0x00000000 TextureViewDimension_1D TextureViewDimension = 0x00000001 TextureViewDimension_2D TextureViewDimension = 0x00000002 TextureViewDimension_2DArray TextureViewDimension = 0x00000003 TextureViewDimension_Cube TextureViewDimension = 0x00000004 TextureViewDimension_CubeArray TextureViewDimension = 0x00000005 TextureViewDimension_3D TextureViewDimension = 0x00000006 )
func (TextureViewDimension) String ¶
func (v TextureViewDimension) String() string
type VertexAttribute ¶
type VertexAttribute struct { Format VertexFormat Offset uint64 ShaderLocation uint32 }
type VertexBufferLayout ¶
type VertexBufferLayout struct { ArrayStride uint64 StepMode VertexStepMode Attributes []VertexAttribute }
type VertexFormat ¶
type VertexFormat uint32
const ( VertexFormat_Undefined VertexFormat = 0x00000000 VertexFormat_Uint8x2 VertexFormat = 0x00000001 VertexFormat_Uint8x4 VertexFormat = 0x00000002 VertexFormat_Sint8x2 VertexFormat = 0x00000003 VertexFormat_Sint8x4 VertexFormat = 0x00000004 VertexFormat_Unorm8x2 VertexFormat = 0x00000005 VertexFormat_Unorm8x4 VertexFormat = 0x00000006 VertexFormat_Snorm8x2 VertexFormat = 0x00000007 VertexFormat_Snorm8x4 VertexFormat = 0x00000008 VertexFormat_Uint16x2 VertexFormat = 0x00000009 VertexFormat_Uint16x4 VertexFormat = 0x0000000A VertexFormat_Sint16x2 VertexFormat = 0x0000000B VertexFormat_Sint16x4 VertexFormat = 0x0000000C VertexFormat_Unorm16x2 VertexFormat = 0x0000000D VertexFormat_Unorm16x4 VertexFormat = 0x0000000E VertexFormat_Snorm16x2 VertexFormat = 0x0000000F VertexFormat_Snorm16x4 VertexFormat = 0x00000010 VertexFormat_Float16x2 VertexFormat = 0x00000011 VertexFormat_Float16x4 VertexFormat = 0x00000012 VertexFormat_Float32 VertexFormat = 0x00000013 VertexFormat_Float32x2 VertexFormat = 0x00000014 VertexFormat_Float32x3 VertexFormat = 0x00000015 VertexFormat_Float32x4 VertexFormat = 0x00000016 VertexFormat_Uint32 VertexFormat = 0x00000017 VertexFormat_Uint32x2 VertexFormat = 0x00000018 VertexFormat_Uint32x3 VertexFormat = 0x00000019 VertexFormat_Uint32x4 VertexFormat = 0x0000001A VertexFormat_Sint32 VertexFormat = 0x0000001B VertexFormat_Sint32x2 VertexFormat = 0x0000001C VertexFormat_Sint32x3 VertexFormat = 0x0000001D VertexFormat_Sint32x4 VertexFormat = 0x0000001E )
func (VertexFormat) Size ¶
func (v VertexFormat) Size() uint64
func (VertexFormat) String ¶
func (v VertexFormat) String() string
type VertexState ¶
type VertexState struct { Module *ShaderModule EntryPoint string Buffers []VertexBufferLayout }
type VertexStepMode ¶
type VertexStepMode uint32
const ( VertexStepMode_Vertex VertexStepMode = 0x00000000 VertexStepMode_Instance VertexStepMode = 0x00000001 VertexStepMode_VertexBufferNotUsed VertexStepMode = 0x00000002 )
func (VertexStepMode) String ¶
func (v VertexStepMode) String() string
type WrappedSubmissionIndex ¶
type WrappedSubmissionIndex struct { Queue *Queue SubmissionIndex SubmissionIndex }
Source Files ¶
- adapter.go
- buffer.go
- buffer_ext.go
- command_encoder.go
- compute_pass_encoder.go
- compute_pipeline.go
- defaults.go
- device.go
- device_ext.go
- enums.go
- error.go
- instance.go
- queue.go
- render_bundle_encoder.go
- render_pass_encoder.go
- render_pipeline.go
- surface.go
- swap_chain.go
- texture.go
- texture_ext.go
- vendor.go
- wgpu.go
- wgpu_c_cb.go
- wgpu_ext.go
Click to show internal directories.
Click to hide internal directories.