gpu

command
v0.27.1 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 10, 2026 License: MIT Imports: 6 Imported by: 0

Documentation

Overview

Package main demonstrates the GPU backend for gogpu/gg.

This example shows how to:

  • Create and initialize the gpu GPU backend directly
  • Render a scene using GPU acceleration
  • Handle fallback to software rendering

The GPU backend uses WebGPU (via gogpu/wgpu) for hardware-accelerated 2D graphics rendering. When GPU is not available, it falls back to software rendering via scene.Renderer.

Note: The GPU rendering pipeline is implemented but GPU operations currently run as stubs. When gogpu/wgpu implements texture readback and buffer mapping, actual GPU rendering will be enabled.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL