mirror of
https://github.com/opencv/opencv.git
synced 2024-11-27 12:40:05 +08:00
Merge pull request #24477 from asmorkalov:as/SimpleBlobDetector_js
Add JavaScript bindings for SimpleBlobDetector
This commit is contained in:
commit
81907af74c
@ -99,6 +99,10 @@ typedef QRCodeDetectorAruco::Params QRCodeDetectorAruco_Params;
|
||||
using namespace cv::dnn;
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_OPENCV_FEATURES2D
|
||||
typedef SimpleBlobDetector::Params SimpleBlobDetector_Params;
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_OPENCV_VIDEO
|
||||
typedef TrackerMIL::Params TrackerMIL_Params;
|
||||
#endif
|
||||
|
@ -62,6 +62,15 @@ QUnit.test('Detectors', function(assert) {
|
||||
assert.equal(kp.size(), 53, 'AKAZE');
|
||||
});
|
||||
|
||||
QUnit.test('SimpleBlobDetector', function(assert) {
|
||||
let image = generateTestFrame();
|
||||
|
||||
let kp = new cv.KeyPointVector();
|
||||
let sbd = new cv.SimpleBlobDetector();
|
||||
sbd.detect(image, kp);
|
||||
assert.equal(kp.size(), 0);
|
||||
});
|
||||
|
||||
QUnit.test('BFMatcher', function(assert) {
|
||||
// Generate key points.
|
||||
let image = generateTestFrame();
|
||||
|
@ -158,7 +158,8 @@ features2d = {'Feature2D': ['detect', 'compute', 'detectAndCompute', 'descriptor
|
||||
'FastFeatureDetector': ['create', 'setThreshold', 'getThreshold', 'setNonmaxSuppression', 'getNonmaxSuppression', 'setType', 'getType', 'getDefaultName'],
|
||||
'AgastFeatureDetector': ['create', 'setThreshold', 'getThreshold', 'setNonmaxSuppression', 'getNonmaxSuppression', 'setType', 'getType', 'getDefaultName'],
|
||||
'GFTTDetector': ['create', 'setMaxFeatures', 'getMaxFeatures', 'setQualityLevel', 'getQualityLevel', 'setMinDistance', 'getMinDistance', 'setBlockSize', 'getBlockSize', 'setHarrisDetector', 'getHarrisDetector', 'setK', 'getK', 'getDefaultName'],
|
||||
# 'SimpleBlobDetector': ['create'],
|
||||
'SimpleBlobDetector': ['create', 'setParams', 'getParams', 'getDefaultName'],
|
||||
'SimpleBlobDetector_Params': [],
|
||||
'KAZE': ['create', 'setExtended', 'getExtended', 'setUpright', 'getUpright', 'setThreshold', 'getThreshold', 'setNOctaves', 'getNOctaves', 'setNOctaveLayers', 'getNOctaveLayers', 'setDiffusivity', 'getDiffusivity', 'getDefaultName'],
|
||||
'AKAZE': ['create', 'setDescriptorType', 'getDescriptorType', 'setDescriptorSize', 'getDescriptorSize', 'setDescriptorChannels', 'getDescriptorChannels', 'setThreshold', 'getThreshold', 'setNOctaves', 'getNOctaves', 'setNOctaveLayers', 'getNOctaveLayers', 'setDiffusivity', 'getDiffusivity', 'getDefaultName'],
|
||||
'DescriptorMatcher': ['add', 'clear', 'empty', 'isMaskSupported', 'train', 'match', 'knnMatch', 'radiusMatch', 'clone', 'create'],
|
||||
|
Loading…
Reference in New Issue
Block a user