Skip to content

daijh/wgpu_compute_playground

Repository files navigation

WebGPU Compute Playground

WebGPU Supported C++ CMake Platform License

A lightweight playground for experimenting with WebGPU compute shaders using the native C++ API. This project builds on top of the Dawn project, which is an open-source implementation of the WebGPU standard. It provides a basic framework to write, build, and run WebGPU compute pipelines directly from C++, allowing for low-level control and experimentation without the browser environment.

Getting Started

  1. Clone the Repository:

    git clone https://github.com/daijh/wgpu_compute_playground.git 
    cd webgpu_compute_playground
  2. Initialize/Update Submodules:

    git submodule update --init
  3. Build the Project:

    cmake -S . -B build
    cmake --build build -j8
  4. Run:

    Known Issue on Windows: You might need to copy D3DCompiler_47.dll and vulkan-1.dll from C:\Windows\System32 into the build\wgpu\Debug\ directory for the application to run correctly.

    # Windows
    build\wgpu\Debug\basic_compute.exe
    
    # Linux
    build/wgpu/basic_compute

Contributing

Contributions are welcome! If you have any ideas for improvements, new features, or bug fixes, feel free to open an issue or submit a pull request.

License

This project is licensed under the BSD 3-Clause "New" or "Revised" License. See the LICENSE file for more information.

About

Lightweight C++ playground for WebGPU compute shader.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published