Implement the Gaussian Blur node (#933)

This commit is contained in:
Dennis Kobert
2022-12-31 21:12:02 +01:00
committed by Keavon Chambers
parent 74bfd630a9
commit a9601ab164
11 changed files with 578 additions and 51 deletions

View File

@@ -132,7 +132,7 @@ pub fn export_image_node<'n>() -> impl Node<(Image, &'n str), Output = Result<()
FnNode::new(|input: (Image, &str)| {
let (image, path) = input;
let mut new_image = image::ImageBuffer::new(image.width, image.height);
for ((x, y, pixel), color) in new_image.enumerate_pixels_mut().zip((&image).into_iter()) {
for ((x, y, pixel), color) in new_image.enumerate_pixels_mut().zip((&image).data.iter()) {
let color: Color = *color;
assert!(x < image.width);
assert!(y < image.height);