Skip to content

Commit 630d538

Browse files
committed
refactor(render): move WgpuWrapper into bevy_utils
1 parent 0432792 commit 630d538

File tree

3 files changed

+7
-2
lines changed

3 files changed

+7
-2
lines changed

crates/bevy_render/Cargo.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -65,7 +65,9 @@ bevy_render_macros = { path = "macros", version = "0.16.0-dev" }
6565
bevy_time = { path = "../bevy_time", version = "0.16.0-dev" }
6666
bevy_transform = { path = "../bevy_transform", version = "0.16.0-dev" }
6767
bevy_window = { path = "../bevy_window", version = "0.16.0-dev" }
68-
bevy_utils = { path = "../bevy_utils", version = "0.16.0-dev" }
68+
bevy_utils = { path = "../bevy_utils", version = "0.16.0-dev", features = [
69+
"wgpu_wrapper",
70+
] }
6971
bevy_tasks = { path = "../bevy_tasks", version = "0.16.0-dev" }
7072
bevy_image = { path = "../bevy_image", version = "0.16.0-dev" }
7173
bevy_mesh = { path = "../bevy_mesh", version = "0.16.0-dev" }

crates/bevy_utils/Cargo.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,8 @@ keywords = ["bevy"]
1111
[features]
1212
default = ["parallel"]
1313

14+
wgpu_wrapper = ["dep:send_wrapper"]
15+
1416
# Provides access to the `Parallel` type.
1517
parallel = ["bevy_platform/std", "dep:thread_local"]
1618

@@ -20,7 +22,7 @@ bevy_platform = { path = "../bevy_platform", version = "0.16.0-dev", default-fea
2022
thread_local = { version = "1.0", optional = true }
2123

2224
[target.'cfg(all(target_arch = "wasm32", target_feature = "atomics"))'.dependencies]
23-
send_wrapper = "0.6.0"
25+
send_wrapper = { version = "0.6.0", optional = true }
2426

2527
[dev-dependencies]
2628
static_assertions = "1.1.0"

crates/bevy_utils/src/lib.rs

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,7 @@ pub mod prelude {
4848

4949
pub mod synccell;
5050
pub mod syncunsafecell;
51+
#[cfg(feature = "wgpu_wrapper")]
5152
mod wgpu_wrapper;
5253

5354
mod default;

0 commit comments

Comments
 (0)