mirror of
https://github.com/emilk/egui.git
synced 2026-08-31 22:00:03 -04:00
Add egui_wgpu crate (#1564)
Based on https://github.com/hasenbanck/egui_wgpu_backend `egui-wgpu` is now an official backend for `eframe` (opt-in). Use the `wgpu` feature flag on `eframe` and the `NativeOptions::renderer` settings to pick it. Co-authored-by: Nils Hasenbanck <nils@hasenbanck.de> Co-authored-by: Sven Niederberger <niederberger@embotech.com> Co-authored-by: Sven Niederberger <73159570+s-nie@users.noreply.github.com>
This commit is contained in:
@@ -20,7 +20,7 @@ all-features = true
|
||||
|
||||
|
||||
[features]
|
||||
default = ["default_fonts"]
|
||||
default = ["default_fonts", "glow"]
|
||||
|
||||
# detect dark mode system preference
|
||||
dark-light = ["dep:dark-light"]
|
||||
@@ -29,6 +29,8 @@ dark-light = ["dep:dark-light"]
|
||||
# If you plan on specifying your own fonts you may disable this feature.
|
||||
default_fonts = ["egui/default_fonts"]
|
||||
|
||||
glow = ["dep:glow", "egui_glow"]
|
||||
|
||||
# Enable saving app state to disk.
|
||||
persistence = [
|
||||
"directories-next",
|
||||
@@ -49,19 +51,23 @@ screen_reader = [
|
||||
"tts",
|
||||
]
|
||||
|
||||
# Use WGPU as the backend instead of glow
|
||||
wgpu = ["egui-wgpu"]
|
||||
|
||||
|
||||
[dependencies]
|
||||
egui = { version = "0.18.0", path = "../egui", default-features = false, features = [
|
||||
"bytemuck",
|
||||
"tracing",
|
||||
] }
|
||||
egui_glow = { version = "0.18.0", path = "../egui_glow", default-features = false }
|
||||
glow = "0.11"
|
||||
tracing = "0.1"
|
||||
|
||||
# optional:
|
||||
egui_glow = { version = "0.18.0", path = "../egui_glow", optional = true, default-features = false }
|
||||
egui-wgpu = { version = "0.18.0", path = "../egui-wgpu", optional = true, features = ["winit"] }
|
||||
glow = { version = "0.11", optional = true }
|
||||
ron = { version = "0.7", optional = true }
|
||||
serde = { version = "1", optional = true }
|
||||
serde = { version = "1", optional = true, features = ["derive"] }
|
||||
|
||||
# -------------------------------------------
|
||||
# native:
|
||||
|
||||
Reference in New Issue
Block a user