mirror of
https://github.com/emilk/egui.git
synced 2026-06-26 22:53:14 -04:00
updates the wgpu version to 0.20 and changes the API calls accordingly.
I had to update wasm-bindgen to "0.2.92". Otherwise, I got this error
for the demo app:
```
error: failed to select a version for `wasm-bindgen`.
... required by package `js-sys v0.3.69`
... which satisfies dependency `js-sys = "^0.3.69"` of package `eframe v0.27.2 (/home/user/Projects/egui/crates/eframe)`
... which satisfies path dependency `eframe` (locked to 0.27.2) of package `confirm_exit v0.1.0 (/home/user/Projects/egui/examples/confirm_exit)`
versions that meet the requirements `^0.2.92` are: 0.2.92
all possible versions conflict with previously selected packages.
previously selected package `wasm-bindgen v0.2.90`
... which satisfies dependency `wasm-bindgen = "=0.2.90"` of package `egui_demo_app v0.27.2 (/home/user/Projects/egui/crates/egui_demo_app)`
failed to select a version for `wasm-bindgen` which could resolve this conflict
```
Why is it locked to this version right now?
I ran the tests, checked the web demo and my own projects, and
everything seems to work fine with wgpu 0.20.
---------
Co-authored-by: Andreas Reich <r_andreas2@web.de>
91 lines
2.4 KiB
TOML
91 lines
2.4 KiB
TOML
[package]
|
|
name = "egui_demo_app"
|
|
version.workspace = true
|
|
authors = ["Emil Ernerfeldt <emil.ernerfeldt@gmail.com>"]
|
|
license.workspace = true
|
|
edition.workspace = true
|
|
rust-version.workspace = true
|
|
publish = false
|
|
default-run = "egui_demo_app"
|
|
|
|
[lints]
|
|
workspace = true
|
|
|
|
[package.metadata.docs.rs]
|
|
all-features = true
|
|
|
|
[lib]
|
|
crate-type = ["cdylib", "rlib"]
|
|
|
|
|
|
[features]
|
|
default = ["glow", "persistence"]
|
|
|
|
# image_viewer adds about 0.9 MB of WASM
|
|
web_app = ["http", "persistence"]
|
|
|
|
http = ["ehttp", "image", "poll-promise", "egui_extras/image"]
|
|
image_viewer = ["image", "egui_extras/all_loaders", "rfd"]
|
|
persistence = ["eframe/persistence", "egui/persistence", "serde"]
|
|
puffin = ["eframe/puffin", "dep:puffin", "dep:puffin_http"]
|
|
serde = ["dep:serde", "egui_demo_lib/serde", "egui/serde"]
|
|
syntect = ["egui_demo_lib/syntect"]
|
|
|
|
glow = ["eframe/glow"]
|
|
wgpu = ["eframe/wgpu", "bytemuck", "dep:wgpu"]
|
|
wayland = ["eframe/wayland"]
|
|
x11 = ["eframe/x11"]
|
|
|
|
[dependencies]
|
|
chrono = { version = "0.4", default-features = false, features = [
|
|
"js-sys",
|
|
"wasmbind",
|
|
] }
|
|
eframe = { workspace = true, default-features = false, features = [
|
|
"web_screen_reader",
|
|
] }
|
|
egui = { workspace = true, features = [
|
|
"callstack",
|
|
"default",
|
|
"extra_debug_asserts",
|
|
"log",
|
|
] }
|
|
egui_demo_lib = { workspace = true, features = ["default", "chrono"] }
|
|
egui_extras = { workspace = true, features = ["default", "image"] }
|
|
log.workspace = true
|
|
|
|
# Optional dependencies:
|
|
|
|
bytemuck = { version = "1.7.1", optional = true }
|
|
puffin = { workspace = true, optional = true }
|
|
puffin_http = { workspace = true, optional = true }
|
|
# Enable both WebGL & WebGPU when targeting the web (these features have no effect when not targeting wasm32)
|
|
wgpu = { workspace = true, features = ["webgpu", "webgl"], optional = true }
|
|
|
|
|
|
# feature "http":
|
|
ehttp = { version = "0.5", optional = true }
|
|
image = { version = "0.24", optional = true, default-features = false, features = [
|
|
"jpeg",
|
|
"png",
|
|
] }
|
|
poll-promise = { version = "0.3", optional = true, default-features = false }
|
|
|
|
# feature "persistence":
|
|
serde = { version = "1", optional = true, features = ["derive"] }
|
|
|
|
|
|
# native:
|
|
[target.'cfg(not(target_arch = "wasm32"))'.dependencies]
|
|
env_logger = { version = "0.10", default-features = false, features = [
|
|
"auto-color",
|
|
"humantime",
|
|
] }
|
|
rfd = { version = "0.13", optional = true }
|
|
|
|
# web:
|
|
[target.'cfg(target_arch = "wasm32")'.dependencies]
|
|
wasm-bindgen = "=0.2.92"
|
|
wasm-bindgen-futures = "0.4"
|
|
web-sys = "0.3"
|