From 62d9de6a368a50dcb62b2b97a5fb02a3858b0977 Mon Sep 17 00:00:00 2001 From: Akshay Date: Sat, 3 Apr 2021 14:36:12 +0530 Subject: fix reflect figure --- src/symmetry.rs | 2 +- src/utils.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/symmetry.rs b/src/symmetry.rs index 60ff791..6d4aed2 100644 --- a/src/symmetry.rs +++ b/src/symmetry.rs @@ -18,7 +18,7 @@ impl Symmetry { (Some(x), Some(y)) => { let along_x = mirror_figure(figure, x, Axis::X); let along_y = mirror_figure(figure, y, Axis::Y); - let reflected = reflect_figure(figure, (x, y).into()); + let reflected = reflect_figure(figure, (y, x).into()); along_x .into_iter() .chain(along_y) diff --git a/src/utils.rs b/src/utils.rs index 6819e71..bee5782 100644 --- a/src/utils.rs +++ b/src/utils.rs @@ -106,5 +106,5 @@ pub fn load_file>(path: P) -> Result { .open(&path)?; let mut buf = Vec::new(); image.read_to_end(&mut buf)?; - Ok(Image::decode(&mut (Cursor::new(buf))).unwrap()) // TODO: obi erro + Ok(Image::decode(&mut (Cursor::new(buf))).unwrap()) // TODO: obi error } -- cgit v1.2.3