mirror of
https://github.com/gfx-rs/wgpu.git
synced 2026-04-22 03:02:01 -04:00
[rs] Small comment on WebGPU backend bit, readme update
This commit is contained in:
@@ -8,7 +8,7 @@
|
||||
|
||||
wgpu-rs is an idiomatic Rust wrapper over [wgpu-core](https://github.com/gfx-rs/wgpu). It's designed to be suitable for general purpose graphics and computation needs of Rust community.
|
||||
|
||||
Currently wgpu-rs works on native platforms, but [WASM support is currently being added](https://github.com/gfx-rs/wgpu-rs/issues/101) as well.
|
||||
wgpu-rs can target both the natively supported backends and WASM directly.
|
||||
|
||||
## Gallery
|
||||
|
||||
|
||||
@@ -634,6 +634,9 @@ impl crate::Context for Context {
|
||||
options: &crate::RequestAdapterOptions<'_>,
|
||||
_backends: wgt::BackendBit,
|
||||
) -> Self::RequestAdapterFuture {
|
||||
//TODO: support this check, return `None` if the flag is not set.
|
||||
// It's not trivial, since we need the Future logic to have this check,
|
||||
// and currently the Future her has no room for extra parameter `backends`.
|
||||
//assert!(backends.contains(wgt::BackendBit::BROWSER_WEBGPU));
|
||||
let mut mapped_options = web_sys::GpuRequestAdapterOptions::new();
|
||||
let mapped_power_preference = match options.power_preference {
|
||||
|
||||
Reference in New Issue
Block a user