diff options
| author | Laurenz <laurmaedje@gmail.com> | 2022-05-25 21:31:12 +0200 |
|---|---|---|
| committer | Laurenz <laurmaedje@gmail.com> | 2022-05-25 21:56:22 +0200 |
| commit | 0170913d5413aab4c1f2bd7d56b9b7138f676012 (patch) | |
| tree | fbe77af9ac3c3cfa63ffde3d861987e8d1276ac5 /src/export | |
| parent | b6b6e3692404e32873892810bebeb1122f34c52e (diff) | |
Rebrand queries as memoization
Diffstat (limited to 'src/export')
| -rw-r--r-- | src/export/render.rs | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/src/export/render.rs b/src/export/render.rs index 9c37791e..aa60e67e 100644 --- a/src/export/render.rs +++ b/src/export/render.rs @@ -12,7 +12,6 @@ use crate::geom::{ self, Geometry, Length, Paint, PathElement, Shape, Size, Stroke, Transform, }; use crate::image::{Image, RasterImage, Svg}; -use crate::query::query_ref; use crate::Context; /// Export a frame into a rendered image. @@ -244,7 +243,7 @@ fn render_outline_glyph( // Rasterize the glyph with `pixglyph`. // Try to retrieve a prepared glyph or prepare it from scratch if it // doesn't exist, yet. - let bitmap = query_ref( + let bitmap = crate::memo::memoized_ref( (&ctx.fonts, text.face_id, id), |(fonts, face_id, id)| pixglyph::Glyph::load(fonts.get(face_id).ttf(), id), |glyph| glyph.as_ref().map(|g| g.rasterize(ts.tx, ts.ty, ppem)), |
