Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Allow users to opt-out of default winit features #3228

Merged
merged 3 commits into from
Aug 10, 2023

Conversation

emilk
Copy link
Owner

@emilk emilk commented Aug 10, 2023

For eframe and egui-winit the following is now true:

  • The default features includes winit/default
  • With --no-default-features, no winit features are enabled
  • There is a wayland feature mapping to winit/wayland (see egui_winit: support winit with default features disabled #1971 for motivation)
  • There is a x11 feature mapping to winit/x11, so we can test --no-default-features --features x11 on CI.
  • For more fine-grained control of winit feature flags, user can just depend on winit themselves

@emilk emilk added eframe Relates to epi and eframe egui-wgpu labels Aug 10, 2023
@emilk emilk changed the title Do not enable winit features by default Allow users to opt-out of default winit features Aug 10, 2023
@emilk emilk added the egui-winit porblems related to winit label Aug 10, 2023
@emilk emilk merged commit 7e035c6 into master Aug 10, 2023
35 checks passed
@emilk emilk deleted the emilk/no-default-winit-features branch August 10, 2023 15:09
Speak2Erase added a commit to Speak2Erase/Luminol that referenced this pull request Nov 20, 2023
Speak2Erase added a commit to Astrabit-ST/Luminol that referenced this pull request Nov 22, 2023
* refactor: 🚧 Split luminol into separate crates

* refactor: 🚧 Start working out dependencies

* Sorta figure out dependencies

* Sorta start getting somewhere

* Move Luminol into crates folder

* Move the filesystem trait out of luminol-core

* refactor: 🚧 refactor luminol-graphics and it's a mess

* refactor:

* refactor: add UpdateState to luminol-core and move various traits

* refactor(filesystem): ♻️ require FileSystem::File to be 'static

* refactor: ♻️ don't take an &'static reference to graphics state

* refactor: ♻️ refactor modals

* refactor: ♻️ unify tabs and windows

* refactor: ♻️ start to fix up windows

* refactor: ♻️ hack together things so that they compile

* refactor: ♻️ partially resolve async code issues

* refactor: ♻️ it compiles (with a LOT of unfinished things)

* refactor: ♻️ NOW it compiles

* fix(graphics): 🐛 fix sprite shader compilation

* fix(data cache): ♻️ get data cache semi-working

* refactor(data cache): ♻️ actually load data cache

* refactor(config): ♻️ store code theme in global state again

* fix(ui): 🐛 fix windows and tabs not being added

* refactor: ♻️ use workspace metadata for package metadata

* refactor: ♻️ remove generic parameters on update state by using dynamic dispatch

I couldn't get generics to allow adding tabs or windows inside tabs or windows

* refactor(tabs): ♻️ pass update state when requesting tab name

* fix(tabs): 🐛 fix tabs not adding properly

* Update window.rs

* fix: 🐛 get top bar loading projects

* fix: 🐛 fix new project creation

because reqwest requires tokio we need to spawn a tokio runtime. i do not think this scales well to web

* refactor: 🚧 try splitting up the map tab

* Enable -Zthreads compiler flag

* Update nightly in workflows

* revert: ⏪ Undo making cursor state an enum (will tackle this later)

* Sorta resolve dependencies on wasm

Still a mess (and is especially complicated by the fact that you can't specify workspace target specific dependencies)

* Fix backing web filesystem implementation

Still need to work on the project filesystem though!
I'll be honest, I'm not sure how this will work, especially with the way I have the native filesystem set up

* Fix native build

* Remove jobs flag

* Fix audio on wasm

* Temporarily impl Send + Sync for wgpu callbacks

In wgpu 0.17 wgpu types are not Send + Sync, because they reference things in the JS heap (meaning they cannot leave the thread they were created on)

egui_wgpu's CallbackTrait requires Send + Sync even on wasm and we need to store wgpu types in callbacks. The callback_resources typemap passed to callbacks doesn't need to be Send + Sync.. but I can't find a simple way to add anything to the typemap.

emilk/egui#1399 feels relevant

* Fix winit not compiling in CI

emilk/egui#3228

* Get wasm filesystem compiling

* Get luminol compiling on wasm!

* Fix missed rename

* Dumb typo

* Move luminol crate to be root package

Trunk doesn't like virtual workspaces unfortunately
:(

* Run workspace tests

* fix(audio): 🐛 Completely read audio file on wasm

* perf(wasm): ⚡ Use oneshot crate for oneshot channels

* fix(filesystem): 🐛 Pass idb key instead of path to Filesystem::from_idb_key

* refactor(tilemap): ♻️ Use naga oil instead of const_format

* fix(ui): 🐛 Fix top bar opening & closing projects

* Bump nightly in trunk build

* Remove luminol- in folder prefixes
mkeeter added a commit to mkeeter/fidget that referenced this pull request Apr 12, 2024
This lets us work around emilk/egui#3228
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
eframe Relates to epi and eframe egui-wgpu egui-winit porblems related to winit
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Wayland build error without wayland feature
1 participant