fast-dhash 1.0.0

A fast rust implementation of the perceptual hash dhash
Documentation

Fast DHash

A fast rust implementation of the perceptual hash dhash.

The main difference with other rust implementations, and the reason it is called fast, is that it uses multi-threading and doesn't rely internally on the image crate methods.

Usage

use fast_dhash::Dhash;
use image::open;
use std::path::Path;

let path = Path::new("../image.jpg");
let image = open(path);

if let Ok(image) = image {
    let hash = Dhash::new(
        image.as_bytes(),
        image.width(),
        image.height(),
        image.color().channel_count(),
    );
    println!("hash: {}", hash);
    // hash: d6a288ac6d5cce14
}