Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Greenplum
Opencv
提交
6a689d82
O
Opencv
项目概览
Greenplum
/
Opencv
大约 1 年 前同步成功
通知
7
Star
0
Fork
0
代码
文件
提交
分支
Tags
贡献者
分支图
Diff
Issue
0
列表
看板
标记
里程碑
合并请求
0
DevOps
流水线
流水线任务
计划
Wiki
0
Wiki
分析
仓库
DevOps
项目成员
Pages
O
Opencv
项目概览
项目概览
详情
发布
仓库
仓库
文件
提交
分支
标签
贡献者
分支图
比较
Issue
0
Issue
0
列表
看板
标记
里程碑
合并请求
0
合并请求
0
Pages
DevOps
DevOps
流水线
流水线任务
计划
分析
分析
仓库分析
DevOps
Wiki
0
Wiki
成员
成员
收起侧边栏
关闭侧边栏
动态
分支图
创建新Issue
流水线任务
提交
Issue看板
体验新版 GitCode,发现更多精彩内容 >>
提交
6a689d82
编写于
11月 23, 2010
作者:
E
Ethan Rublee
浏览文件
操作
浏览文件
下载
电子邮件补丁
差异文件
Continue to refeactor the dynamic stuff - may have broken build on last commit.
Fairly certain that it builds now.
上级
f6b08189
变更
2
隐藏空白更改
内联
并排
Showing
2 changed file
with
30 addition
and
5 deletion
+30
-5
modules/features2d/include/opencv2/features2d/features2d.hpp
modules/features2d/include/opencv2/features2d/features2d.hpp
+28
-3
modules/features2d/src/brief.cpp
modules/features2d/src/brief.cpp
+2
-2
未找到文件。
modules/features2d/include/opencv2/features2d/features2d.hpp
浏览文件 @
6a689d82
...
...
@@ -1481,6 +1481,12 @@ public:
* Beware that this is not thread safe - as the adjustment of parameters breaks the const
* of the detection routine...
* /TODO Make this const correct and thread safe
*
* sample usage:
//will create a detector that attempts to find 100 - 110 FAST Keypoints, and will at most run
//FAST feature detection 10 times until that number of keypoints are found
Ptr<FeatureDetector> detector(new DynamicDetector (100, 110, 10,new FastAdjuster(20,true)));
*/
class
CV_EXPORTS
DynamicDetector
:
public
FeatureDetector
{
public:
...
...
@@ -1503,8 +1509,14 @@ private:
Ptr
<
AdjusterAdapter
>
adjuster_
;
};
class
FastAdjuster
:
public
AdjusterAdapter
{
/**\brief an adjust for the FAST detector. This will basically decrement or increment the
* threshhold by 1
*/
class
CV_EXPORTS
FastAdjuster
:
public
AdjusterAdapter
{
public:
/**\param init_thresh the initial threshhold to start with, default = 20
* \param nonmax whether to use non max or not for fast feature detection
*/
FastAdjuster
(
int
init_thresh
=
20
,
bool
nonmax
=
true
);
virtual
void
tooFew
(
int
min
,
int
n_detected
);
virtual
void
tooMany
(
int
max
,
int
n_detected
);
...
...
@@ -1518,7 +1530,11 @@ protected:
};
struct
StarAdjuster
:
public
AdjusterAdapter
{
/** An adjuster for StarFeatureDetector, this one adjusts the responseThreshold for now
* TODO find a faster way to converge the parameters for Star - use CvStarDetectorParams
*/
struct
CV_EXPORTS
StarAdjuster
:
public
AdjusterAdapter
{
StarAdjuster
(
double
initial_thresh
=
30.0
);
virtual
void
tooFew
(
int
min
,
int
n_detected
);
virtual
void
tooMany
(
int
max
,
int
n_detected
);
...
...
@@ -1528,9 +1544,10 @@ protected:
std
::
vector
<
cv
::
KeyPoint
>&
keypoints
,
const
cv
::
Mat
&
mask
=
cv
::
Mat
())
const
;
double
thresh_
;
CvStarDetectorParams
params_
;
//todo use these instead of thresh_
};
struct
SurfAdjuster
:
public
AdjusterAdapter
{
struct
CV_EXPORTS
SurfAdjuster
:
public
AdjusterAdapter
{
SurfAdjuster
();
virtual
void
tooFew
(
int
min
,
int
n_detected
);
virtual
void
tooMany
(
int
max
,
int
n_detected
);
...
...
@@ -1821,6 +1838,8 @@ struct CV_EXPORTS HammingLUT
typedef
unsigned
char
ValueType
;
typedef
int
ResultType
;
/** this will count the bits in a ^ b
*/
ResultType
operator
()(
const
unsigned
char
*
a
,
const
unsigned
char
*
b
,
int
size
)
const
;
/** \brief given a byte, count the bits using a compile time generated look up table
...
...
@@ -1838,7 +1857,13 @@ struct CV_EXPORTS HammingLUT
struct
CV_EXPORTS
Hamming
{
typedef
unsigned
char
ValueType
;
//! important that this is signed as weird behavior happens
// in BruteForce if not
typedef
int
ResultType
;
/** this will count the bits in a ^ b, using __builtin_popcountl try compiling with sse4
*/
ResultType
operator
()(
const
unsigned
char
*
a
,
const
unsigned
char
*
b
,
int
size
)
const
;
};
...
...
modules/features2d/src/brief.cpp
浏览文件 @
6a689d82
...
...
@@ -92,7 +92,7 @@ void pixelTests64(const Mat& sum, const std::vector<KeyPoint>& keypoints, Mat& d
namespace
cv
{
ResultType
HammingLUT
::
operator
()(
const
unsigned
char
*
a
,
const
unsigned
char
*
b
,
int
size
)
const
HammingLUT
::
ResultType
HammingLUT
::
operator
()(
const
unsigned
char
*
a
,
const
unsigned
char
*
b
,
int
size
)
const
{
ResultType
result
=
0
;
for
(
int
i
=
0
;
i
<
size
;
i
++
)
...
...
@@ -101,7 +101,7 @@ ResultType HammingLUT::operator()( const unsigned char* a, const unsigned char*
}
return
result
;
}
ResultType
Hamming
::
operator
()(
const
unsigned
char
*
a
,
const
unsigned
char
*
b
,
int
size
)
const
Hamming
::
ResultType
Hamming
::
operator
()(
const
unsigned
char
*
a
,
const
unsigned
char
*
b
,
int
size
)
const
{
#if __GNUC__
ResultType
result
=
0
;
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录