summaryrefslogtreecommitdiffstats
path: root/wgpu/src/window
diff options
context:
space:
mode:
authorLibravatar Héctor Ramón Jiménez <hector@hecrj.dev>2024-04-03 23:39:38 +0200
committerLibravatar Héctor Ramón Jiménez <hector@hecrj.dev>2024-04-03 23:39:38 +0200
commitcc05cb9be4a1de5f0427f93ce64e658be0703f8b (patch)
tree0e8e70848d29101a5a214a1462ddb5f578fdf5c2 /wgpu/src/window
parentd461f23e8dd34c5de73e0aa176a3301b01564652 (diff)
downloadiced-cc05cb9be4a1de5f0427f93ce64e658be0703f8b.tar.gz
iced-cc05cb9be4a1de5f0427f93ce64e658be0703f8b.tar.bz2
iced-cc05cb9be4a1de5f0427f93ce64e658be0703f8b.zip
Fix broken doc links in `iced_wgpu` and `iced_graphics`
Diffstat (limited to 'wgpu/src/window')
-rw-r--r--wgpu/src/window/compositor.rs11
1 files changed, 5 insertions, 6 deletions
diff --git a/wgpu/src/window/compositor.rs b/wgpu/src/window/compositor.rs
index 55490c39..d546a6dc 100644
--- a/wgpu/src/window/compositor.rs
+++ b/wgpu/src/window/compositor.rs
@@ -54,7 +54,7 @@ impl Compositor {
compatible_window: Option<W>,
) -> Result<Self, Error> {
let instance = wgpu::Instance::new(wgpu::InstanceDescriptor {
- backends: settings.internal_backend,
+ backends: settings.backends,
..Default::default()
});
@@ -63,7 +63,7 @@ impl Compositor {
#[cfg(not(target_arch = "wasm32"))]
if log::max_level() >= log::LevelFilter::Info {
let available_adapters: Vec<_> = instance
- .enumerate_adapters(settings.internal_backend)
+ .enumerate_adapters(settings.backends)
.iter()
.map(wgpu::Adapter::get_info)
.collect();
@@ -197,8 +197,7 @@ impl Compositor {
}
}
-/// Creates a [`Compositor`] and its [`Backend`] for the given [`Settings`] and
-/// window.
+/// Creates a [`Compositor`] with the given [`Settings`] and window.
pub async fn new<W: compositor::Window>(
settings: Settings,
compatible_window: W,
@@ -206,7 +205,7 @@ pub async fn new<W: compositor::Window>(
Compositor::request(settings, Some(compatible_window)).await
}
-/// Presents the given primitives with the given [`Compositor`] and [`Backend`].
+/// Presents the given primitives with the given [`Compositor`].
pub fn present<T: AsRef<str>>(
compositor: &mut Compositor,
renderer: &mut Renderer,
@@ -273,7 +272,7 @@ impl graphics::Compositor for Compositor {
match backend {
None | Some("wgpu") => Ok(new(
Settings {
- internal_backend: wgpu::util::backend_bits_from_env()
+ backends: wgpu::util::backend_bits_from_env()
.unwrap_or(wgpu::Backends::all()),
..settings.into()
},