Skip to content

Commit 0dce58d

Browse files
changed websys features in core and hal to align with used features (#2922)
Co-authored-by: Connor Fitzgerald <connorwadefitzgerald@gmail.com>
1 parent 4cbf8cf commit 0dce58d

File tree

3 files changed

+5
-2
lines changed

3 files changed

+5
-2
lines changed

CHANGELOG.md

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -60,6 +60,7 @@ the same every time it is rendered, we now warn if it is missing.
6060

6161
#### General
6262
- Improve the validation and error reporting of buffer mappings by @nical in [#2848](https://github.com/gfx-rs/wgpu/pull/2848)
63+
- Fix compilation errors when using wgpu-core in isolation while targetting `wasm32-unknown-unknown` by @Seamooo in [#2922](https://github.com/gfx-rs/wgpu/pull/2922)
6364
- Fixed opening of RenderDoc library by @abuffseagull in [#2930](https://github.com/gfx-rs/wgpu/pull/2930)
6465

6566
### Changes

wgpu-core/Cargo.toml

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,11 @@ path = "../wgpu-hal"
5656
package = "wgpu-hal"
5757
version = "0.13"
5858

59+
[target.'cfg(all(target_arch = "wasm32", not(target_os = "emscripten")))'.dependencies]
60+
web-sys = { version = "0.3", features = ["HtmlCanvasElement", "OffscreenCanvas"] }
61+
5962
[target.'cfg(target_arch = "wasm32")'.dependencies]
6063
hal = { path = "../wgpu-hal", package = "wgpu-hal", version = "0.13", features = ["gles"] }
61-
web-sys = { version = "0.3", features = ["HtmlCanvasElement"] }
6264

6365
[target.'cfg(all(not(target_arch = "wasm32"), any(target_os = "ios", target_os = "macos")))'.dependencies]
6466
hal = { path = "../wgpu-hal", package = "wgpu-hal", version = "0.13", features = ["metal"] }

wgpu-hal/Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -88,7 +88,7 @@ core-graphics-types = "0.1"
8888

8989
[target.'cfg(all(target_arch = "wasm32", not(target_os = "emscripten")))'.dependencies]
9090
wasm-bindgen = { version = "0.2" }
91-
web-sys = { version = "0.3", features = ["Window", "HtmlCanvasElement", "WebGl2RenderingContext"] }
91+
web-sys = { version = "0.3", features = ["Window", "HtmlCanvasElement", "WebGl2RenderingContext", "OffscreenCanvas"] }
9292
js-sys = { version = "0.3" }
9393

9494
[target.'cfg(target_os = "android")'.dependencies]

0 commit comments

Comments
 (0)