Documentation ¶
Index ¶
Constants ¶
const ( ExactMatching = AlgorithmName("exact") FuzzyMatching = AlgorithmName("fuzzy") PositiveIfOnlyImageMatching = AlgorithmName("positive_if_only_image") SampleAreaMatching = AlgorithmName("sample_area") SobelFuzzyMatching = AlgorithmName("sobel") )
const ( // MaxDifferentPixels is the optional key used to specify the MaxDifferentPixels parameter of // algorithms FuzzyMatching and SobelFuzzyMatching. MaxDifferentPixels = AlgorithmParamOptKey("fuzzy_max_different_pixels") // PixelDeltaThreshold is the optional key used to specify the PixelDeltaThreshold parameter of // algorithms FuzzyMatching and SobelFuzzyMatching. PixelDeltaThreshold = AlgorithmParamOptKey("fuzzy_pixel_delta_threshold") // PixelPerChannelDeltaThreshold is the optional key used to specify the // PixelPerChannelDeltaThreshold parameter of algorithms FuzzyMatching and SobelFuzzyMatching. PixelPerChannelDeltaThreshold = AlgorithmParamOptKey("fuzzy_pixel_per_channel_delta_threshold") // IgnoredBorderThickness is the optional key used to specify the IgnoredBorderThickness // parameter of algorithms FuzzyMatching and SobelFuzzyMatching. IgnoredBorderThickness = AlgorithmParamOptKey("fuzzy_ignored_border_thickness") // EdgeThreshold is the optional key used to specify the EdgeThreshold parameter of the // SobelFuzzyMatching algorithm. EdgeThreshold = AlgorithmParamOptKey("sobel_edge_threshold") // SampleAreaWidth is the optional key used to specify the SampleAreaWidth // parameter of the SampleAreaMatching algorithm. SampleAreaWidth = AlgorithmParamOptKey("sample_area_width") // MaxDifferentPixelsPerArea is the optional key used to specify the // MaxDifferentPixelsPerArea parameter of the SampleAreaMatching algorithm. MaxDifferentPixelsPerArea = AlgorithmParamOptKey("sample_area_max_different_pixels_per_area") // SampleAreaChannelDeltaThreshold is the optional key used to specify the // SampleAreaChannelDeltaThreshold parameter of the SampleAreaMatching algorithm. SampleAreaChannelDeltaThreshold = AlgorithmParamOptKey("sample_area_channel_delta_threshold") )
const AlgorithmNameOptKey = "image_matching_algorithm"
AlgorithmNameOptKey is the optional key used to indicate a non-exact matching algorithm.
Variables ¶
This section is empty.
Functions ¶
func MakeMatcher ¶
func MakeMatcher(optionalKeys map[string]string) (AlgorithmName, Matcher, error)
MakeMatcher takes a map of optional keys and returns the specified image matching algorithm name, and the corresponding Matcher instance (or nil if none is specified).
It returns a non-nil error if the specified image matching algorithm is invalid, or if any required parameters are not found, or if the parameter values are not valid.
Types ¶
type AlgorithmName ¶
type AlgorithmName string
AlgorithmName is a non-exact image matching algorithm specified via the AlgorithmNameOptKey optional key, e.g. "fuzzy".
type AlgorithmParamOptKey ¶
type AlgorithmParamOptKey string
AlgorithmParamOptKey is an optional key indicating a parameter for the specified non-exact image matching algorithm, e.g. "fuzzy_max_different_pixels".