Versions in this module Expand all Collapse all v0 v0.31.0 Aug 2, 2026 Changes in this version + var ErrComputeRequiresSPIRV = errors.New(...) — darwin/amd64, linux/amd64, windows/amd64 + type API struct — darwin/amd64, linux/amd64, windows/amd64 + func (API) CreateInstance(_ *hal.InstanceDescriptor) (hal.Instance, error) + func (API) Variant() gputypes.Backend + type Adapter struct — darwin/amd64, linux/amd64, windows/amd64 + func (a *Adapter) Destroy() + func (a *Adapter) Open(_ gputypes.Features, _ gputypes.Limits) (hal.OpenDevice, error) + func (a *Adapter) SurfaceCapabilities(_ hal.Surface) *hal.SurfaceCapabilities + func (a *Adapter) TextureFormatCapabilities(_ gputypes.TextureFormat) hal.TextureFormatCapabilities + type BindGroup struct — darwin/amd64, linux/amd64, windows/amd64 + type Buffer struct — darwin/amd64, linux/amd64, windows/amd64 + func (b *Buffer) GetData() []byte + func (b *Buffer) NativeHandle() uintptr + func (b *Buffer) WriteData(offset uint64, data []byte) + type CommandEncoder struct — darwin/amd64, linux/amd64, windows/amd64 + func (c *CommandEncoder) BeginComputePass(desc *hal.ComputePassDescriptor) hal.ComputePassEncoder + func (c *CommandEncoder) BeginEncoding(_ string) error + func (c *CommandEncoder) BeginRenderPass(desc *hal.RenderPassDescriptor) hal.RenderPassEncoder + func (c *CommandEncoder) ClearBuffer(buffer hal.Buffer, offset, size uint64) + func (c *CommandEncoder) CopyBufferToBuffer(src, dst hal.Buffer, regions []hal.BufferCopy) + func (c *CommandEncoder) CopyBufferToTexture(src hal.Buffer, dst hal.Texture, regions []hal.BufferTextureCopy) + func (c *CommandEncoder) CopyTextureToBuffer(src hal.Texture, dst hal.Buffer, regions []hal.BufferTextureCopy) + func (c *CommandEncoder) CopyTextureToTexture(src, dst hal.Texture, regions []hal.TextureCopy) + func (c *CommandEncoder) Destroy() + func (c *CommandEncoder) DiscardEncoding() + func (c *CommandEncoder) EndEncoding() (hal.CommandBuffer, error) + func (c *CommandEncoder) ResetAll(_ []hal.CommandBuffer) + func (c *CommandEncoder) ResolveQuerySet(_ hal.QuerySet, _, _ uint32, _ hal.Buffer, _ uint64) + func (c *CommandEncoder) TransitionBuffers(_ []hal.BufferBarrier) + func (c *CommandEncoder) TransitionTextures(_ []hal.TextureBarrier) + type ComputePassEncoder struct — darwin/amd64, linux/amd64, windows/amd64 + func (c *ComputePassEncoder) Dispatch(x, y, z uint32) + func (c *ComputePassEncoder) DispatchIndirect(_ hal.Buffer, _ uint64) + func (c *ComputePassEncoder) End() + func (c *ComputePassEncoder) SetBindGroup(index uint32, bg hal.BindGroup, dynamicOffsets []uint32) + func (c *ComputePassEncoder) SetPipeline(p hal.ComputePipeline) + type ComputePipeline struct — darwin/amd64, linux/amd64, windows/amd64 + type Device struct — darwin/amd64, linux/amd64, windows/amd64 + func (d *Device) CreateBindGroup(desc *hal.BindGroupDescriptor) (hal.BindGroup, error) + func (d *Device) CreateBindGroupLayout(_ *hal.BindGroupLayoutDescriptor) (hal.BindGroupLayout, error) + func (d *Device) CreateBuffer(desc *hal.BufferDescriptor) (hal.Buffer, error) + func (d *Device) CreateCommandEncoder(_ *hal.CommandEncoderDescriptor) (hal.CommandEncoder, error) + func (d *Device) CreateComputePipeline(desc *hal.ComputePipelineDescriptor) (hal.ComputePipeline, error) + func (d *Device) CreateFence() (hal.Fence, error) + func (d *Device) CreatePipelineLayout(_ *hal.PipelineLayoutDescriptor) (hal.PipelineLayout, error) + func (d *Device) CreateQuerySet(_ *hal.QuerySetDescriptor) (hal.QuerySet, error) + func (d *Device) CreateRenderBundleEncoder(_ *hal.RenderBundleEncoderDescriptor) (hal.RenderBundleEncoder, error) + func (d *Device) CreateRenderPipeline(desc *hal.RenderPipelineDescriptor) (hal.RenderPipeline, error) + func (d *Device) CreateSampler(desc *hal.SamplerDescriptor) (hal.Sampler, error) + func (d *Device) CreateShaderModule(desc *hal.ShaderModuleDescriptor) (hal.ShaderModule, error) + func (d *Device) CreateTexture(desc *hal.TextureDescriptor) (hal.Texture, error) + func (d *Device) CreateTextureView(texture hal.Texture, _ *hal.TextureViewDescriptor) (hal.TextureView, error) + func (d *Device) Destroy() + func (d *Device) DestroyBindGroup(_ hal.BindGroup) + func (d *Device) DestroyBindGroupLayout(_ hal.BindGroupLayout) + func (d *Device) DestroyBuffer(_ hal.Buffer) + func (d *Device) DestroyComputePipeline(_ hal.ComputePipeline) + func (d *Device) DestroyFence(_ hal.Fence) + func (d *Device) DestroyPipelineLayout(_ hal.PipelineLayout) + func (d *Device) DestroyQuerySet(_ hal.QuerySet) + func (d *Device) DestroyRenderBundle(_ hal.RenderBundle) + func (d *Device) DestroyRenderPipeline(_ hal.RenderPipeline) + func (d *Device) DestroySampler(_ hal.Sampler) + func (d *Device) DestroyShaderModule(_ hal.ShaderModule) + func (d *Device) DestroyTexture(_ hal.Texture) + func (d *Device) DestroyTextureView(_ hal.TextureView) + func (d *Device) FreeCommandBuffer(_ hal.CommandBuffer) + func (d *Device) GetFenceStatus(fence hal.Fence) (bool, error) + func (d *Device) MapBuffer(buffer hal.Buffer, offset, size uint64) (hal.BufferMapping, error) + func (d *Device) ResetFence(fence hal.Fence) error + func (d *Device) UnmapBuffer(_ hal.Buffer) error + func (d *Device) Wait(fence hal.Fence, value uint64, _ time.Duration) (bool, error) + func (d *Device) WaitIdle() error + type Fence struct — darwin/amd64, linux/amd64, windows/amd64 + type Instance struct — darwin/amd64, linux/amd64, windows/amd64 + func (i *Instance) CreateSurface(target hal.SurfaceTarget) (hal.Surface, error) + func (i *Instance) Destroy() + func (i *Instance) EnumerateAdapters(_ hal.Surface) []hal.ExposedAdapter + type Queue struct — darwin/amd64, linux/amd64, windows/amd64 + func (q *Queue) GetTimestampPeriod() float32 + func (q *Queue) PollCompleted() uint64 + func (q *Queue) Present(surface hal.Surface, texture hal.SurfaceTexture, damageRects []image.Rectangle) error + func (q *Queue) SetSwapchainSuppressed(_ bool) + func (q *Queue) Submit(_ []hal.CommandBuffer) (uint64, error) + func (q *Queue) SupportsCommandBufferCopies() bool + func (q *Queue) WriteBuffer(buffer hal.Buffer, offset uint64, data []byte) error + func (q *Queue) WriteTexture(dst *hal.ImageCopyTexture, data []byte, layout *hal.ImageDataLayout, ...) error + type RenderPassEncoder struct — darwin/amd64, linux/amd64, windows/amd64 + func (r *RenderPassEncoder) Draw(vertexCount, instanceCount, firstVertex, firstInstance uint32) + func (r *RenderPassEncoder) DrawIndexed(indexCount, instanceCount, firstIndex uint32, baseVertex int32, ...) + func (r *RenderPassEncoder) DrawIndexedIndirect(_ hal.Buffer, _ uint64, _ uint32) + func (r *RenderPassEncoder) DrawIndirect(_ hal.Buffer, _ uint64, _ uint32) + func (r *RenderPassEncoder) End() + func (r *RenderPassEncoder) ExecuteBundle(_ hal.RenderBundle) + func (r *RenderPassEncoder) SetBindGroup(index uint32, bg hal.BindGroup, dynamicOffsets []uint32) + func (r *RenderPassEncoder) SetBlendConstant(_ *gputypes.Color) + func (r *RenderPassEncoder) SetIndexBuffer(buf hal.Buffer, format gputypes.IndexFormat, offset uint64) + func (r *RenderPassEncoder) SetPipeline(p hal.RenderPipeline) + func (r *RenderPassEncoder) SetScissorRect(x, y, w, h uint32) + func (r *RenderPassEncoder) SetStencilReference(ref uint32) + func (r *RenderPassEncoder) SetVertexBuffer(slot uint32, buf hal.Buffer, offset uint64) + func (r *RenderPassEncoder) SetViewport(x, y, w, h, minDepth, maxDepth float32) + func (r *RenderPassEncoder) Stats() RenderPassStats + type RenderPassStats struct + ColorLoadOp gputypes.LoadOp + DrawCount uint32 + HasScissor bool + Height uint32 + ScissorRect image.Rectangle + Width uint32 + type RenderPipeline struct — darwin/amd64, linux/amd64, windows/amd64 + type Resource struct — darwin/amd64, linux/amd64, windows/amd64 + func (r *Resource) AddPendingRef() + func (r *Resource) CurrentUsage() gputypes.TextureUsage + func (r *Resource) DecPendingRef() + func (r *Resource) Destroy() + func (r *Resource) NativeHandle() uintptr + type SamplerResource struct — darwin/amd64, linux/amd64, windows/amd64 + Desc *hal.SamplerDescriptor + func (s *SamplerResource) NativeHandle() uintptr + type ShaderModule struct — darwin/amd64, linux/amd64, windows/amd64 + func (sm *ShaderModule) ParsedModule() *shader.Module + type Surface struct — darwin/amd64, linux/amd64, windows/amd64 + func (s *Surface) AcquireTexture(_ hal.Fence) (*hal.AcquiredSurfaceTexture, error) + func (s *Surface) ActualExtent() (width, height uint32) + func (s *Surface) Configure(_ hal.Device, config *hal.SurfaceConfiguration) error + func (s *Surface) DiscardTexture(_ hal.SurfaceTexture) + func (s *Surface) GetFramebuffer() []byte + func (s *Surface) PresentPixels(data []byte, width, height uint32, damageRects []image.Rectangle) error + func (s *Surface) ReadPixels() []byte + func (s *Surface) Unconfigure(_ hal.Device) + func (s *Surface) WritePixels(data []byte, width, height uint32) error + type SurfaceTexture struct — darwin/amd64, linux/amd64, windows/amd64 + type Texture struct — darwin/amd64, linux/amd64, windows/amd64 + func (t *Texture) Clear(color gputypes.Color) + func (t *Texture) CurrentUsage() gputypes.TextureUsage + func (t *Texture) GetData() []byte + func (t *Texture) NativeHandle() uintptr + func (t *Texture) WriteData(offset uint64, data []byte) + type TextureView struct — darwin/amd64, linux/amd64, windows/amd64 + func (v *TextureView) NativeHandle() uintptr