/// <summary>
        /// Process image looking for interest points.
        /// </summary>
        /// <typeparam name="TPoint">The type of returned feature points.</typeparam>
        /// <typeparam name="TFeature">The type of extracted features.</typeparam>
        /// <param name="featureDetector">Feature detector.</param>
        /// <param name="image">Source image data to process.</param>
        /// <returns>Returns list of found interest points.</returns>
        public static List <TPoint> ProcessImage <TPoint, TFeature>(this IFeatureDetector <TPoint, TFeature> featureDetector, Gray <byte>[,] image)
            where TPoint : IFeatureDescriptor <TFeature>
        {
            List <TPoint> points;

            using (var uImg = image.Lock())
            {
                points = featureDetector.ProcessImage(uImg.AsAForgeImage());
            }

            return(points);
        }
 /// <summary>
 /// Process image looking for interest points.
 /// </summary>
 /// <typeparam name="TPoint">The type of returned feature points.</typeparam>
 /// <typeparam name="TFeature">The type of extracted features.</typeparam>
 /// <param name="featureDetector">Feature detector.</param>
 /// <param name="image">Source image data to process.</param>
 /// <returns>Returns list of found interest points.</returns>
 public static List <TPoint> ProcessImage <TPoint, TFeature>(this IFeatureDetector <TPoint, TFeature> featureDetector, Image <Gray, byte> image)
     where TPoint : IFeatureDescriptor <TFeature>
 {
     return(featureDetector.ProcessImage(image.ToAForgeImage(copyAlways: false, failIfCannotCast: true)));
 }