Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1,280 changes: 590 additions & 690 deletions Cargo.lock

Large diffs are not rendered by default.

7 changes: 3 additions & 4 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ wgpu = { version = "29.0.1", default-features = false, features = ["std", "parki
pollster = "0.4.0"

# rust-gpu
cargo-gpu-install = { version = "0.10.0-alpha.1" }
spirv-std = { version = "0.10.0-alpha.1" }
cargo-gpu-install = { version = "0.10.0" }
spirv-std = { version = "0.10.0" }

# other
glam = { version = "0.32.0", default-features = false }
glam = { version = "0.33.11", default-features = false }
bytemuck = { version = "1.24.0", features = ["derive"] }
raw-window-handle = "0.6.2"
winit = "0.30.0"
Expand Down Expand Up @@ -62,7 +62,6 @@ filter_map_next = "warn"
flat_map_option = "warn"
float_cmp_const = "warn"
fn_params_excessive_bools = "warn"
from_iter_instead_of_collect = "warn"
if_let_mutex = "warn"
implicit_clone = "warn"
imprecise_flops = "warn"
Expand Down
22 changes: 8 additions & 14 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -4,27 +4,21 @@ Examples on how to setup rust-gpu with various APIs, use-cases and integration p

## Generating a project

Install cargo-generate
Install our `cargo gpu` cli, if you haven't already:

```sh
cargo install cargo-generate
```shell
cargo install cargo-gpu
```

or if you have [no time, use cargo-binstall](https://github.com/cargo-bins/cargo-binstall):
Then generate a rust-gpu project with:

```sh
cargo binstall cargo-generate
```shell
cargo gpu generate
```

Then generate this template and answer the questions to configure it: (more details below)
(This subcommand is merely a wrapper around [`cargo-generate`](https://crates.io/crates/cargo-generate/))

```sh
cargo generate --git https://github.com/Rust-GPU/rust-gpu-template
```

If you don't want to install `cargo generate`, you can also go to the
[
`generated/` folder](https://github.com/Rust-GPU/rust-gpu-template/tree/main/generated/) and navigate its subfolders, each level corresponding to the questions below.
If you don't want to install `cargo generate`, you can also go to the [`generated/` folder](https://github.com/Rust-GPU/rust-gpu-template/tree/main/generated/) and navigate its subfolders, each level corresponding to the questions below.

## Questions

Expand Down
6 changes: 3 additions & 3 deletions generated/graphics/ash/cargo-gpu/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ gpu-allocator = { version = "0.28.0", default-features = false, features = ["std

# rust-gpu
# While `cargo-gpu` is backwards compatible with older rust-gpu versions, easiest is to just match the versions exactly.
cargo-gpu-install = { version = "0.10.0-alpha.1" }
spirv-std = { version = "0.10.0-alpha.1" }
cargo-gpu-install = { version = "0.10.0" }
spirv-std = { version = "0.10.0" }

# other
glam = { version = "0.32.0", default-features = false }
glam = { version = "0.33.11", default-features = false }
bytemuck = { version = "1.24.0", features = ["derive"] }
raw-window-handle = "0.6.2"
winit = "0.30.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ impl MyBuffer {
impl Drop for MyBuffer {
fn drop(&mut self) {
if !self.destroyed {
panic!("dropping Buffer {} without destroying it", &self.name);
panic!("dropping Buffer {} without destroying it", self.name);
}
}
}
6 changes: 3 additions & 3 deletions generated/graphics/ash/spirv-builder/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,11 @@ gpu-allocator = { version = "0.28.0", default-features = false, features = ["std

# rust-gpu
# The version of the dependencies `spirv-builder` and `spirv-std` must match exactly!
spirv-builder = { version = "0.10.0-alpha.1" }
spirv-std = { version = "0.10.0-alpha.1" }
spirv-builder = { version = "0.10.0" }
spirv-std = { version = "0.10.0" }

# other
glam = { version = "0.32.0", default-features = false }
glam = { version = "0.33.11", default-features = false }
bytemuck = { version = "1.24.0", features = ["derive"] }
raw-window-handle = "0.6.2"
winit = "0.30.0"
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ impl MyBuffer {
impl Drop for MyBuffer {
fn drop(&mut self) {
if !self.destroyed {
panic!("dropping Buffer {} without destroying it", &self.name);
panic!("dropping Buffer {} without destroying it", self.name);
}
}
}
2 changes: 1 addition & 1 deletion generated/graphics/ash/spirv-builder/rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[toolchain]
channel = "nightly-2026-04-11"
channel = "nightly-2026-07-03"
components = ["rust-src", "rustc-dev", "llvm-tools"]
6 changes: 3 additions & 3 deletions generated/graphics/wgpu/cargo-gpu/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ pollster = "0.4.0"

# rust-gpu
# While `cargo-gpu` is backwards compatible with older rust-gpu versions, easiest is to just match the versions exactly.
cargo-gpu-install = { version = "0.10.0-alpha.1" }
spirv-std = { version = "0.10.0-alpha.1" }
cargo-gpu-install = { version = "0.10.0" }
spirv-std = { version = "0.10.0" }

# other
glam = { version = "0.32.0", default-features = false }
glam = { version = "0.33.11", default-features = false }
bytemuck = { version = "1.24.0", features = ["derive"] }
raw-window-handle = "0.6.2"
winit = "0.30.0"
Expand Down
6 changes: 3 additions & 3 deletions generated/graphics/wgpu/spirv-builder/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -22,11 +22,11 @@ pollster = "0.4.0"

# rust-gpu
# The version of the dependencies `spirv-builder` and `spirv-std` must match exactly!
spirv-builder = { version = "0.10.0-alpha.1" }
spirv-std = { version = "0.10.0-alpha.1" }
spirv-builder = { version = "0.10.0" }
spirv-std = { version = "0.10.0" }

# other
glam = { version = "0.32.0", default-features = false }
glam = { version = "0.33.11", default-features = false }
bytemuck = { version = "1.24.0", features = ["derive"] }
raw-window-handle = "0.6.2"
winit = "0.30.0"
Expand Down
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[toolchain]
channel = "nightly-2026-04-11"
channel = "nightly-2026-07-03"
components = ["rust-src", "rustc-dev", "llvm-tools"]
8 changes: 4 additions & 4 deletions graphics/Cargo.toml.liquid
Original file line number Diff line number Diff line change
Expand Up @@ -30,16 +30,16 @@ pollster = "0.4.0"
# rust-gpu
{% if integration == "spirv-builder" -%}
# The version of the dependencies `spirv-builder` and `spirv-std` must match exactly!
spirv-builder = { version = "0.10.0-alpha.1" }
spirv-builder = { version = "0.10.0" }
{% endif -%}
{% if integration == "cargo-gpu" -%}
# While `cargo-gpu` is backwards compatible with older rust-gpu versions, easiest is to just match the versions exactly.
cargo-gpu-install = { version = "0.10.0-alpha.1" }
cargo-gpu-install = { version = "0.10.0" }
{% endif -%}
spirv-std = { version = "0.10.0-alpha.1" }
spirv-std = { version = "0.10.0" }

# other
glam = { version = "0.32.0", default-features = false }
glam = { version = "0.33.11", default-features = false }
bytemuck = { version = "1.24.0", features = ["derive"] }
raw-window-handle = "0.6.2"
winit = "0.30.0"
Expand Down
2 changes: 1 addition & 1 deletion graphics/mygraphics/src/ash_renderer/buffer.rs
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ impl MyBuffer {
impl Drop for MyBuffer {
fn drop(&mut self) {
if !self.destroyed {
panic!("dropping Buffer {} without destroying it", &self.name);
panic!("dropping Buffer {} without destroying it", self.name);
}
}
}
2 changes: 1 addition & 1 deletion graphics/rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[toolchain]
channel = "nightly-2026-04-11"
channel = "nightly-2026-07-03"
components = ["rust-src", "rustc-dev", "llvm-tools"]
2 changes: 1 addition & 1 deletion rust-toolchain.toml
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
[toolchain]
channel = "nightly-2026-04-11"
channel = "nightly-2026-07-03"
components = ["rust-src", "rustc-dev", "llvm-tools"]
Loading