Browse Source

cleanup imports

master
Drew Short 5 years ago
parent
commit
b90d10a6cf
  1. 5
      src/hash/ahash.rs
  2. 4
      src/hash/dhash.rs
  3. 6
      src/hash/phash.rs
  4. 1
      src/lib.rs

5
src/hash/ahash.rs

@ -2,9 +2,6 @@
// //
// Licensed under the MIT license<LICENSE-MIT or http://opensource.org/licenses/MIT>. // Licensed under the MIT license<LICENSE-MIT or http://opensource.org/licenses/MIT>.
// This file may not be copied, modified, or distributed except according to those terms. // This file may not be copied, modified, or distributed except according to those terms.
extern crate image;
use std::path::Path; use std::path::Path;
use cache::Cache; use cache::Cache;
@ -12,7 +9,7 @@ use cache::Cache;
use super::prepare_image; use super::prepare_image;
use super::{HashType, PerceptualHash, Precision, PreparedImage}; use super::{HashType, PerceptualHash, Precision, PreparedImage};
use self::image::GenericImageView;
use super::image::GenericImageView;
pub struct AHash<'a> { pub struct AHash<'a> {
prepared_image: Box<PreparedImage<'a>>, prepared_image: Box<PreparedImage<'a>>,

4
src/hash/dhash.rs

@ -2,8 +2,6 @@
// //
// Licensed under the MIT license<LICENSE-MIT or http://opensource.org/licenses/MIT>. // Licensed under the MIT license<LICENSE-MIT or http://opensource.org/licenses/MIT>.
// This file may not be copied, modified, or distributed except according to those terms. // This file may not be copied, modified, or distributed except according to those terms.
extern crate image;
use std::path::Path; use std::path::Path;
use cache::Cache; use cache::Cache;
@ -11,7 +9,7 @@ use cache::Cache;
use super::prepare_image; use super::prepare_image;
use super::{HashType, PerceptualHash, Precision, PreparedImage}; use super::{HashType, PerceptualHash, Precision, PreparedImage};
use self::image::GenericImageView;
use super::image::GenericImageView;
pub struct DHash<'a> { pub struct DHash<'a> {
prepared_image: Box<PreparedImage<'a>>, prepared_image: Box<PreparedImage<'a>>,

6
src/hash/phash.rs

@ -2,20 +2,16 @@
// //
// Licensed under the MIT license<LICENSE-MIT or http://opensource.org/licenses/MIT>. // Licensed under the MIT license<LICENSE-MIT or http://opensource.org/licenses/MIT>.
// This file may not be copied, modified, or distributed except according to those terms. // This file may not be copied, modified, or distributed except according to those terms.
extern crate image;
use std::path::Path; use std::path::Path;
use cache::Cache; use cache::Cache;
use super::dft; use super::dft;
use super::dft::Transform; use super::dft::Transform;
use super::image::Pixel;
use super::image::{DynamicImage, GenericImageView, Pixel};
use super::prepare_image; use super::prepare_image;
use super::{HashType, PerceptualHash, Precision, PreparedImage}; use super::{HashType, PerceptualHash, Precision, PreparedImage};
use self::image::{DynamicImage, GenericImageView};
pub struct PHash<'a> { pub struct PHash<'a> {
prepared_image: Box<PreparedImage<'a>>, prepared_image: Box<PreparedImage<'a>>,
} }

1
src/lib.rs

@ -6,7 +6,6 @@
// Enable nightly features for extra testing behind the bench feature // Enable nightly features for extra testing behind the bench feature
#![cfg_attr(feature = "bench", feature(test))] #![cfg_attr(feature = "bench", feature(test))]
extern crate image;
extern crate libc; extern crate libc;
extern crate rustc_serialize; extern crate rustc_serialize;
#[cfg(feature = "bench")] #[cfg(feature = "bench")]

Loading…
Cancel
Save