bevyengine / bevyengine/bevy

Show how to tests shaders using Bevy

Open
#24,236 0 comments 3 reactions 0 assignees View on GitHub
A-Rendering C-Feature C-Testing
Dominant language
Rust
Stars
48.2k
Forks
4.8k
Avg merge
3d 22h
Merged PRs (30d)
161

Description

## What problem does this solve or what need does it fill?

Shaders are hard to tests, but with a little work unit tests are possible.

## What solution would you like?

Take inspiration from wgpu shader tests https://github.com/gfx-rs/wgpu/tree/trunk/tests/tests/wgpu-gpu/shader

A test takes a compute shader template, plugs the types / code, calls the shader, read back the result, and assert the result. See https://github.com/gfx-rs/wgpu/blob/trunk/tests/tests/wgpu-gpu/shader/mod.rs#L200

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.