Cargo Features

[dependencies]
egui-wgpu = { version = "0.34.1", default-features = false, features = ["capture", "winit", "wayland", "x11", "fragile-send-sync-non-atomic-wasm", "macos-window-resize-jitter-fix"] }
default = fragile-send-sync-non-atomic-wasm, macos-window-resize-jitter-fix

These default features are set whenever egui-wgpu is added without default-features = false somewhere in the dependency tree.

Enables webgl of wgpu

wgpu:

Enables the GLES backend on WebAssembly only.

capture winit?

Enables the capture module for capturing screenshots.

Enables egui

Optional dependencies:

Affects egui-wgpu::capture

winit = capture

Enable winit integration. On Linux, requires either wayland or x11

Enables egui, rwh_06 of winit

Affects egui-wgpu::winit

wayland

Enables Wayland support for winit.

Enables wayland of optional winit

x11

Enables x11 support for winit.

Enables x11 of optional winit

fragile-send-sync-non-atomic-wasm default

Make the renderer Sync on wasm, exploiting that by default wasm isn't multithreaded. It may make code easier, especially when targeting both native and web. On native most wgpu objects are send and sync, on the web they are not (by nature of the WebGPU specification). This is not supported in multithreaded WASM. Thus that usage is guarded against with compiler errors in wgpu.

Enables fragile-send-sync-non-atomic-wasm of wgpu

macos-window-resize-jitter-fix default

Enables present_with_transaction surface flag temporary during window resize on MacOS.

Enables metal of wgpu