/// <summary>
        /// Unite .Learn() results for this and another searchers which represent
        /// same templates
        /// </summary>
        public void UniteWith(ImageSearcher other)
        {
            if (!TemplatesEqual(other))
                throw new InvalidOperationException("Objects represent different templates");

            UniteDifferences(ref maxDifference, other.maxDifference);
            UniteDifferences(ref smallPictureMaxDifference, other.smallPictureMaxDifference);
        }
 /// <exception cref="System.ArgumentException">Invalid template</exception>
 /// <exception cref="System.ArgumentNullException"></exception>
 public BitmapSearcher(Bitmap template, SimpleColor transparentColor)
 {
     if (object.ReferenceEquals(template, null))
         throw new ArgumentNullException("template");
     searcher = new ImageSearcher(Converter.ToMatrix(template), transparentColor);
 }
 public bool TemplatesEqual(ImageSearcher other)
 {
     return ImageComparer.Equals(GetTemplate(), other.GetTemplate());
 }