fuzzysearch/fuzzysearch-common/src/lib.rs

15 lines
366 B
Rust
Raw Normal View History

2020-12-07 23:41:32 +00:00
pub mod types;
2021-02-21 06:26:29 +00:00
#[cfg(feature = "video")]
2020-12-07 23:41:32 +00:00
pub mod video;
/// Create an instance of img_hash with project defaults.
pub fn get_hasher() -> img_hash::Hasher<[u8; 8]> {
use img_hash::{HashAlg::Gradient, HasherConfig};
HasherConfig::with_bytes_type::<[u8; 8]>()
.hash_alg(Gradient)
.hash_size(8, 8)
.preproc_dct()
.to_hasher()
}