From 3836ca7a17f410d30871c2254dcc0f2400876636 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A9ctor=20Ram=C3=B3n=20Jim=C3=A9nez?= Date: Tue, 20 Jan 2026 02:01:42 +0100 Subject: [PATCH 1/7] Update `wgpu` to `28` --- Cargo.toml | 2 +- examples/hello-world.rs | 1 + src/cache.rs | 6 +++--- src/text_render.rs | 5 ++--- 4 files changed, 7 insertions(+), 7 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 44452ef..77cce77 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -8,7 +8,7 @@ repository = "https://github.com/iced-rs/cryoglyph" license = "MIT OR Apache-2.0 OR Zlib" [dependencies] -wgpu = { version = "27", default-features = false, features = ["wgsl"] } +wgpu = { version = "28", default-features = false, features = ["wgsl"] } etagere = "0.2" cosmic-text = "0.16" lru = { version = "0.16", default-features = false } diff --git a/examples/hello-world.rs b/examples/hello-world.rs index 9197b0d..06106d6 100644 --- a/examples/hello-world.rs +++ b/examples/hello-world.rs @@ -213,6 +213,7 @@ impl winit::application::ApplicationHandler for Application { depth_stencil_attachment: None, timestamp_writes: None, occlusion_query_set: None, + multiview_mask: None, }); text_renderer.render(&atlas, &viewport, &mut pass).unwrap(); diff --git a/src/cache.rs b/src/cache.rs index 61d2e4d..f66164d 100644 --- a/src/cache.rs +++ b/src/cache.rs @@ -42,7 +42,7 @@ impl Cache { label: Some("glyphon sampler"), min_filter: FilterMode::Nearest, mag_filter: FilterMode::Nearest, - mipmap_filter: FilterMode::Nearest, + mipmap_filter: wgpu::MipmapFilterMode::Nearest, lod_min_clamp: 0f32, lod_max_clamp: 0f32, ..Default::default() @@ -139,7 +139,7 @@ impl Cache { let pipeline_layout = device.create_pipeline_layout(&PipelineLayoutDescriptor { label: None, bind_group_layouts: &[&atlas_layout, &uniforms_layout], - push_constant_ranges: &[], + immediate_size: 0, }); Self(Arc::new(Inner { @@ -237,7 +237,7 @@ impl Cache { }, depth_stencil: depth_stencil.clone(), multisample, - multiview: None, + multiview_mask: None, cache: None, }); diff --git a/src/text_render.rs b/src/text_render.rs index 8b73fe7..431a954 100644 --- a/src/text_render.rs +++ b/src/text_render.rs @@ -39,7 +39,7 @@ impl TextRenderer { let pipeline = atlas.get_or_create_pipeline(device, multisample, depth_stencil); Self { - staging_belt: StagingBelt::new(vertex_buffer_size), + staging_belt: StagingBelt::new(device.clone(), vertex_buffer_size), vertex_buffer, vertex_buffer_size, pipeline, @@ -295,7 +295,6 @@ impl TextRenderer { &self.vertex_buffer, 0, NonZeroU64::new(vertices_raw.len() as u64).expect("Non-empty vertices"), - device, ) .copy_from_slice(vertices_raw); } else { @@ -312,7 +311,7 @@ impl TextRenderer { self.vertex_buffer_size = buffer_size; self.staging_belt.finish(); - self.staging_belt = StagingBelt::new(buffer_size); + self.staging_belt = StagingBelt::new(device.clone(), buffer_size); } self.staging_belt.finish(); From c49de15bce4d8254ac136d1be9911960cc85ce12 Mon Sep 17 00:00:00 2001 From: Ashley Wulber Date: Fri, 13 Sep 2024 11:24:00 -0400 Subject: [PATCH 2/7] fix: cosmic-text --- Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index 44452ef..018c9d7 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -10,7 +10,7 @@ license = "MIT OR Apache-2.0 OR Zlib" [dependencies] wgpu = { version = "27", default-features = false, features = ["wgsl"] } etagere = "0.2" -cosmic-text = "0.16" +cosmic-text = { git = "https://github.com/pop-os/cosmic-text.git" } lru = { version = "0.16", default-features = false } rustc-hash = "2" From 1d68895e9c4c9b73739f826e81c2e3012c155cce Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A9ctor=20Ram=C3=B3n=20Jim=C3=A9nez?= Date: Thu, 19 Feb 2026 19:13:45 +0100 Subject: [PATCH 3/7] Update `cosmic-text` to `0.18` --- Cargo.toml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/Cargo.toml b/Cargo.toml index 77cce77..97f8d71 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -10,7 +10,7 @@ license = "MIT OR Apache-2.0 OR Zlib" [dependencies] wgpu = { version = "28", default-features = false, features = ["wgsl"] } etagere = "0.2" -cosmic-text = "0.16" +cosmic-text = "0.18" lru = { version = "0.16", default-features = false } rustc-hash = "2" From e429a025df36ab8145708acb309080ae3deec17a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?H=C3=A9ctor=20Ram=C3=B3n=20Jim=C3=A9nez?= Date: Thu, 23 Apr 2026 19:43:09 +0900 Subject: [PATCH 4/7] Update `cosmic-text` to `0.19` --- Cargo.toml | 2 +- benches/prepare.rs | 6 +++--- examples/hello-world.rs | 10 +++------- src/lib.rs | 3 +-- src/text_render.rs | 3 +-- 5 files changed, 9 insertions(+), 15 deletions(-) diff --git a/Cargo.toml b/Cargo.toml index 97f8d71..1fa37fb 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -10,7 +10,7 @@ license = "MIT OR Apache-2.0 OR Zlib" [dependencies] wgpu = { version = "28", default-features = false, features = ["wgsl"] } etagere = "0.2" -cosmic-text = "0.18" +cosmic-text = "0.19" lru = { version = "0.16", default-features = false } rustc-hash = "2" diff --git a/benches/prepare.rs b/benches/prepare.rs index e6d800b..c214d93 100644 --- a/benches/prepare.rs +++ b/benches/prepare.rs @@ -73,8 +73,8 @@ fn run_bench(ctx: &mut Criterion) { .copied() .map(|s| { let mut text_buffer = Buffer::new(&mut font_system, Metrics::relative(1.0, 10.0)); - text_buffer.set_size(&mut font_system, Some(20.0), None); - text_buffer.set_text(&mut font_system, s, &attrs, shaping, None); + text_buffer.set_size(Some(20.0), None); + text_buffer.set_text(s, &attrs, shaping, None); text_buffer.shape_until_scroll(&mut font_system, false); text_buffer }) @@ -85,7 +85,7 @@ fn run_bench(ctx: &mut Criterion) { let text_areas: Vec