Documentation ¶
Overview ¶
Package tom64b_hasher is a perceptual image hashing Implementation based on the php Implementation at https://github.com/Tom64b/dHash
Index ¶
- type Implementation
- func (imp Implementation) Distance(h1 imhash_interfaces.PerceptualHash, h2 imhash_interfaces.PerceptualHash) (imhash_interfaces.HammingDistance, error)
- func (imp Implementation) GetHandle() string
- func (imp Implementation) HashFromPath(path string) (imhash_interfaces.PerceptualHash, error)
- func (imp Implementation) HashFromString(hashAsString string) (imhash_interfaces.PerceptualHash, error)
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Implementation ¶
type Implementation struct { }
Implementation is the specific Implementation of the hashing service
func (Implementation) Distance ¶
func (imp Implementation) Distance(h1 imhash_interfaces.PerceptualHash, h2 imhash_interfaces.PerceptualHash) (imhash_interfaces.HammingDistance, error)
Distance calculates the hamming distance between two hashes
func (Implementation) GetHandle ¶
func (imp Implementation) GetHandle() string
func (Implementation) HashFromPath ¶
func (imp Implementation) HashFromPath(path string) (imhash_interfaces.PerceptualHash, error)
HashFromPath creates a hash from an image file at the given path
func (Implementation) HashFromString ¶
func (imp Implementation) HashFromString(hashAsString string) (imhash_interfaces.PerceptualHash, error)
HashFromString recreates a hash from a hash string use it to recreate a hash from a stored value
Click to show internal directories.
Click to hide internal directories.