summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/forest.rs4
-rw-r--r--src/frontier/image.rs2
-rw-r--r--src/frontier/mean.rs2
-rw-r--r--src/frontier/min.rs2
-rw-r--r--src/main.rs4
-rw-r--r--src/soft.rs4
6 files changed, 9 insertions, 9 deletions
diff --git a/src/forest.rs b/src/forest.rs
index 56dff7e..d4f5083 100644
--- a/src/forest.rs
+++ b/src/forest.rs
@@ -2,8 +2,8 @@
use acap::distance::Proximity;
use acap::kd::FlatKdTree;
+use acap::knn::{NearestNeighbors, Neighborhood};
use acap::vp::FlatVpTree;
-use acap::{NearestNeighbors, Neighborhood};
use std::iter::{self, Extend, FromIterator};
@@ -165,7 +165,7 @@ mod tests {
use acap::euclid::Euclidean;
use acap::exhaustive::ExhaustiveSearch;
- use acap::{NearestNeighbors, Neighbor};
+ use acap::knn::{NearestNeighbors, Neighbor};
use rand::prelude::*;
diff --git a/src/frontier/image.rs b/src/frontier/image.rs
index 8b4c233..5db33b8 100644
--- a/src/frontier/image.rs
+++ b/src/frontier/image.rs
@@ -5,7 +5,7 @@ use super::{Frontier, Pixel, Target};
use crate::color::{ColorSpace, Rgb8};
use crate::soft::SoftKdTree;
-use acap::NearestNeighbors;
+use acap::knn::NearestNeighbors;
use image::RgbImage;
diff --git a/src/frontier/mean.rs b/src/frontier/mean.rs
index e59e45c..25bee7d 100644
--- a/src/frontier/mean.rs
+++ b/src/frontier/mean.rs
@@ -5,7 +5,7 @@ use super::{neighbors, Frontier, RcPixel, Target};
use crate::color::{ColorSpace, Rgb8};
use crate::soft::SoftKdForest;
-use acap::NearestNeighbors;
+use acap::knn::NearestNeighbors;
use std::iter;
diff --git a/src/frontier/min.rs b/src/frontier/min.rs
index 5c298e7..8c5099d 100644
--- a/src/frontier/min.rs
+++ b/src/frontier/min.rs
@@ -5,7 +5,7 @@ use super::{neighbors, Frontier, RcPixel, Target};
use crate::color::{ColorSpace, Rgb8};
use crate::soft::SoftKdForest;
-use acap::NearestNeighbors;
+use acap::knn::NearestNeighbors;
use rand::Rng;
diff --git a/src/main.rs b/src/main.rs
index fc7dfff..adb05b1 100644
--- a/src/main.rs
+++ b/src/main.rs
@@ -326,7 +326,7 @@ impl App {
self.get_colors(AllColors::new(r, g, b))
}
SourceArg::Image(ref path) => {
- let img = image::open(path)?.into_rgb();
+ let img = image::open(path)?.into_rgb8();
self.width.get_or_insert(img.width());
self.height.get_or_insert(img.height());
self.get_colors(ImageColors::from(img))
@@ -372,7 +372,7 @@ impl App {
match &self.args.frontier {
FrontierArg::Image(ref path) => {
- let img = image::open(path)?.into_rgb();
+ let img = image::open(path)?.into_rgb8();
self.paint_on(colors, ImageFrontier::<C>::new(&img))
}
FrontierArg::Min => {
diff --git a/src/soft.rs b/src/soft.rs
index 3edaa10..694d0e7 100644
--- a/src/soft.rs
+++ b/src/soft.rs
@@ -4,8 +4,8 @@ use super::forest::{KdForest, VpForest};
use acap::distance::Proximity;
use acap::kd::FlatKdTree;
+use acap::knn::{NearestNeighbors, Neighborhood};
use acap::vp::FlatVpTree;
-use acap::{NearestNeighbors, Neighborhood};
use std::iter;
use std::iter::FromIterator;
@@ -148,7 +148,7 @@ mod tests {
use acap::coords::Coordinates;
use acap::euclid::{euclidean_distance, Euclidean, EuclideanDistance};
- use acap::Neighbor;
+ use acap::knn::Neighbor;
type Point = Euclidean<[f32; 3]>;