Istok.WebGPU.Native.Android 0.0.5-preview

This is a prerelease version of Istok.WebGPU.Native.Android.
dotnet add package Istok.WebGPU.Native.Android --version 0.0.5-preview
                    
NuGet\Install-Package Istok.WebGPU.Native.Android -Version 0.0.5-preview
                    
This command is intended to be used within the Package Manager Console in Visual Studio, as it uses the NuGet module's version of Install-Package.
<PackageReference Include="Istok.WebGPU.Native.Android" Version="0.0.5-preview" />
                    
For projects that support PackageReference, copy this XML node into the project file to reference the package.
<PackageVersion Include="Istok.WebGPU.Native.Android" Version="0.0.5-preview" />
                    
Directory.Packages.props
<PackageReference Include="Istok.WebGPU.Native.Android" />
                    
Project file
For projects that support Central Package Management (CPM), copy this XML node into the solution Directory.Packages.props file to version the package.
paket add Istok.WebGPU.Native.Android --version 0.0.5-preview
                    
#r "nuget: Istok.WebGPU.Native.Android, 0.0.5-preview"
                    
#r directive can be used in F# Interactive and Polyglot Notebooks. Copy this into the interactive tool or source code of the script to reference the package.
#:package Istok.WebGPU.Native.Android@0.0.5-preview
                    
#:package directive can be used in C# file-based apps starting in .NET 10 preview 4. Copy this into a .cs file before any lines of code to reference the package.
#addin nuget:?package=Istok.WebGPU.Native.Android&version=0.0.5-preview&prerelease
                    
Install as a Cake Addin
#tool nuget:?package=Istok.WebGPU.Native.Android&version=0.0.5-preview&prerelease
                    
Install as a Cake Tool

WebGPU C# Bindings

A high-performance, cross-platform C# wrapper for WebGPU, providing a unified API for desktop, mobile, and web environments.

The primary goal of this project is to provide a single, consistent API that allows you to write graphics code once and run it everywhere.

Key Features

  • Unified API: Identical code paths for Windows, Linux, macOS, iOS, Android, and WebAssembly.

  • Web-Idiomatic Design: The API is designed to closely mirror the Browser WebGPU API. This includes descriptor naming conventions and default values, making it intuitive for those familiar with the JavaScript/TypeScript standard.

  • Auto-Generated: Bindings are strictly generated from the official webgpu.json specification.

Supported Platforms

Platform Backend Implementation
Windows, Linux, macOS wgpu-native v29.0.0.0
Android, iOS wgpu-native v29.0.0.0
Browser (WebAssembly) Google Dawn v20260324.184550

Browser Native Plugin Build Instructions (WebAssembly)

To update the library for the browser, you must use the Emscripten SDK (emsdk 3.1.56 for dotnet 10).

  1. Initialize Emscripten:
emsdk activate 3.1.56
source ./emsdk_env.sh
  1. Compile the Library: Navigate to your Dawn binary package and run:
    cd [path_to_dawn_bin]/emdawnwebgpu_pkg/webgpu/
    emcc -c src/webgpu.cpp -o wgpu_native.a -I./include -std=c++20 -s WASM=1

Project Architecture

The solution is divided into several layers to ensure flexibility and ease of maintenance:

  • Istok.WebGPU.LowLevel.Generator: A specialized tool that parses the webgpu.json definition to generate C# bindings.
  • Istok.WebGPU.LowLevel: Contains the raw, auto-generated bindings.
  • Istok.WebGPU: The main high-level library. It wraps the low-level layer to provide the Web-Idiomatic Design.
  • Istok.WebGPU.Native.*: Projects (including .Android, .Browser, .iOS) that bundle the required native binaries for their respective platforms.
  • Istok.WebGPU.View.*: (including .Browser, .SDL) Provides a unified interface for window management, including surface creation and handling display dimensions.

License

This project is available under the MIT License.

Product Compatible and additional computed target framework versions.
.NET net10.0-android36.0 is compatible. 
Compatible target framework(s)
Included target framework(s) (in package)
Learn more about Target Frameworks and .NET Standard.
  • net10.0-android36.0

    • No dependencies.

NuGet packages

This package is not used by any NuGet packages.

GitHub repositories

This package is not used by any popular GitHub repositories.

Version Downloads Last Updated
0.0.5-preview 49 6/12/2026
0.0.4-preview 50 6/12/2026
0.0.3-preview 60 5/21/2026
0.0.2-preview 58 5/19/2026
0.0.1-preview 52 5/14/2026