public void Compute2(Mat image, out KeyPoint[] keypoints, Mat imgDescriptor)
{
if (IsDisposed)
throw new ObjectDisposedException(GetType().Name);
if (image == null)
throw new ArgumentNullException(nameof(image));
if (imgDescriptor == null)
throw new ArgumentNullException(nameof(imgDescriptor));
using (var keypointsVec = new VectorOfKeyPoint())
{
NativeMethods.features2d_BOWImgDescriptorExtractor_compute2(
ptr, image.CvPtr, keypointsVec.CvPtr, imgDescriptor.CvPtr);
keypoints = keypointsVec.ToArray();
}
GC.KeepAlive(image);
GC.KeepAlive(imgDescriptor);
}