Skip to content

v0.30.24 — Surface API contract + Metal -race fix

Choose a tag to compare

@kolkov kolkov released this 29 Jul 15:21
0d02699

Fixed

  • Browser/Rust Surface missing methodsPresentPixels, WritePixels,
    SetPrepareFrame, and SetPresentsWithTransaction now exist on all backends.
    Missing methods return clear errors or no-op, matching ADR-047 (unified public
    API). Fixes WASM build failure introduced by gogpu PR #370. (#281)

  • Metal checkptr abort under -race — ObjC block callback trampolines used
    unsafe.Pointer(blockPtr + 32) which violates Go's pointer provenance rules.
    Replaced with unsafe.Add(unsafe.Pointer(blockPtr), 32) (Go 1.17+) at all 4
    block callback locations. go test -race now works on Metal compute. (#280)

Added

  • Compile-time Surface API contract — anonymous interface assertion
    (var _ interface{...} = (*Surface)(nil)) in each backend file enforces that
    all public methods exist at compile time (ADR-047 enforcement).

  • CI cross-compile jobGOOS=js GOARCH=wasm (browser) and -tags=rust
    (Rust FFI) builds added to CI pipeline. Missing Surface methods now fail the
    PR, not the downstream consumer.

CI

  • Android SDK setup: use pre-installed SDK instead of third-party action (v3/v4 both crash on Preview license)
  • goffi version check updated v0.6.1 → v0.6.2 in Android preview script
  • DX12 command.go formatting fixed