[][src]Function blockhash::blockhash64

pub fn blockhash64<I: Image>(img: &I) -> Blockhash64

Generates a 64-bit perceptual hash of an image.

Examples

use blockhash::{blockhash64, Blockhash64};

let img = image::open("images/512x512_rgb.png").unwrap();
let hash = blockhash64(&img);

assert_eq!(
    hash,
    Blockhash64::from([0xaf, 0x05, 0x75, 0x29, 0x7c, 0x4c, 0x4c, 0xe3]),
);