Skip to content

Supports WebGPU or WebGL or wgpu? #112

Closed

Description

@WREQI
No description provided.

Activity

  1. proggeramlug commented on Apr 21, 2026

    @proggeramlug
    Contributor

    Perry doesn't ship WebGPU/WebGL/wgpu bindings directly - the TypeScript runtime doesn't expose a GPUDevice or WebGLRenderingContext today.

    What it does support is hosting a native Metal/wgpu engine underneath your TypeScript app. The perry-runtime crate has ios-game-loop and watchos-game-loop features (added in v0.5.106 and v0.5.114) that hand the main thread to a native UIApplicationMain / WKApplicationMain, let your native library create the window + Metal view + wgpu surface, and run your _perry_user_main on a background thread for game logic. Compile with --target ios --features ios-game-loop (or watchos-simulator / watchos).

    he reference integration is https://github.com/bloom-Engine/engine, which uses wgpu (and Metal, DirectX etc.) under the hood. If you want to drive WebGPU-style rendering from TypeScript today, wrapping bloom (or your own wgpu-based renderer) as a Perry native library via perry.nativeLibrary in package.json is the path. Fair warning, bloom is also very early, but this is probably what you are looking for. (It's a perry sister project)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions