From 013e1e1c8c2d306e2ce7a01556f95018a2c216ad Mon Sep 17 00:00:00 2001 From: Max Bradbury Date: Sat, 7 Nov 2020 10:54:52 +0000 Subject: [PATCH] resize cropped image (plugin doesn't seem to allow specification of size) --- src/lib.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/src/lib.rs b/src/lib.rs index 576a296..949d2bf 100644 --- a/src/lib.rs +++ b/src/lib.rs @@ -83,6 +83,7 @@ pub fn load_image(image_base64: String) -> String { Ok(image) => { match image::load_from_memory(image.as_ref()) { Ok(image) => { + let image = image.resize(128, 128, CatmullRom); state.image = Some(image); "OK" },