Commit 2d2499f6 authored by Hamdi Sahloul's avatar Hamdi Sahloul

BLOB - Support RGBA

parent 004a1cd6
......@@ -311,7 +311,7 @@ void SimpleBlobDetectorImpl::detect(InputArray image, std::vector<cv::KeyPoint>&
//TODO: support mask
keypoints.clear();
Mat grayscaleImage;
if (image.channels() == 3)
if (image.channels() == 3 || image.channels() == 4)
cvtColor(image, grayscaleImage, COLOR_BGR2GRAY);
else
grayscaleImage = image.getMat();
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment