8#include "MinimumDifference.h"
36 for(
double l = 1.0; l <= pattern.Lines(); l++) {
37 for(
double s = 1.0; s <= pattern.Samples(); s++) {
41 double pdn = pattern.GetValue(samp, line);
42 double sdn = subsearch.GetValue(samp, line);
45 diff += fabs(pdn - sdn);
61 return (fit1 <= fit2);
A small chip of data used for pattern matching.
Minimum difference pattern matching.
virtual bool CompareFits(double fit1, double fit2)
This virtual method must return if the 1st fit is equal to or better than the second fit.
virtual double MatchAlgorithm(Chip &pattern, Chip &subsearch)
Minimum difference match algorithm.
Container for cube-like labels.
This is free and unencumbered software released into the public domain.
bool IsSpecial(const double d)
Returns if the input pixel is special.