Skip to content
体验新版
项目
组织
正在加载...
登录
切换导航
打开侧边栏
Greenplum
Opencv
提交
b1d01dc7
O
Opencv
项目概览
Greenplum
/
Opencv
11 个月 前同步成功
通知
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,发现更多精彩内容 >>
提交
b1d01dc7
编写于
8月 25, 2014
作者:
V
Vadim Pisarevsky
浏览文件
操作
浏览文件
下载
差异文件
Merge pull request #3157 from PhilLab:pnpFix
上级
5301fe72
e95c33dd
变更
3
隐藏空白更改
内联
并排
Showing
3 changed file
with
17 addition
and
17 deletion
+17
-17
modules/calib3d/src/dls.h
modules/calib3d/src/dls.h
+7
-7
modules/calib3d/src/epnp.h
modules/calib3d/src/epnp.h
+5
-5
modules/calib3d/src/p3p.h
modules/calib3d/src/p3p.h
+5
-5
未找到文件。
modules/calib3d/src/dls.h
浏览文件 @
b1d01dc7
...
...
@@ -24,9 +24,9 @@ private:
{
for
(
int
i
=
0
;
i
<
N
;
i
++
)
{
p
.
at
<
double
>
(
0
,
i
)
=
opoints
.
at
<
OpointType
>
(
0
,
i
).
x
;
p
.
at
<
double
>
(
1
,
i
)
=
opoints
.
at
<
OpointType
>
(
0
,
i
).
y
;
p
.
at
<
double
>
(
2
,
i
)
=
opoints
.
at
<
OpointType
>
(
0
,
i
).
z
;
p
.
at
<
double
>
(
0
,
i
)
=
opoints
.
at
<
OpointType
>
(
i
).
x
;
p
.
at
<
double
>
(
1
,
i
)
=
opoints
.
at
<
OpointType
>
(
i
).
y
;
p
.
at
<
double
>
(
2
,
i
)
=
opoints
.
at
<
OpointType
>
(
i
).
z
;
// compute mean of object points
mn
.
at
<
double
>
(
0
)
+=
p
.
at
<
double
>
(
0
,
i
);
...
...
@@ -34,12 +34,12 @@ private:
mn
.
at
<
double
>
(
2
)
+=
p
.
at
<
double
>
(
2
,
i
);
// make z into unit vectors from normalized pixel coords
double
sr
=
std
::
pow
(
ipoints
.
at
<
IpointType
>
(
0
,
i
).
x
,
2
)
+
std
::
pow
(
ipoints
.
at
<
IpointType
>
(
0
,
i
).
y
,
2
)
+
(
double
)
1
;
double
sr
=
std
::
pow
(
ipoints
.
at
<
IpointType
>
(
i
).
x
,
2
)
+
std
::
pow
(
ipoints
.
at
<
IpointType
>
(
i
).
y
,
2
)
+
(
double
)
1
;
sr
=
std
::
sqrt
(
sr
);
z
.
at
<
double
>
(
0
,
i
)
=
ipoints
.
at
<
IpointType
>
(
0
,
i
).
x
/
sr
;
z
.
at
<
double
>
(
1
,
i
)
=
ipoints
.
at
<
IpointType
>
(
0
,
i
).
y
/
sr
;
z
.
at
<
double
>
(
0
,
i
)
=
ipoints
.
at
<
IpointType
>
(
i
).
x
/
sr
;
z
.
at
<
double
>
(
1
,
i
)
=
ipoints
.
at
<
IpointType
>
(
i
).
y
/
sr
;
z
.
at
<
double
>
(
2
,
i
)
=
(
double
)
1
/
sr
;
}
...
...
modules/calib3d/src/epnp.h
浏览文件 @
b1d01dc7
...
...
@@ -27,12 +27,12 @@ class epnp {
{
for
(
int
i
=
0
;
i
<
number_of_correspondences
;
i
++
)
{
pws
[
3
*
i
]
=
opoints
.
at
<
OpointType
>
(
0
,
i
).
x
;
pws
[
3
*
i
+
1
]
=
opoints
.
at
<
OpointType
>
(
0
,
i
).
y
;
pws
[
3
*
i
+
2
]
=
opoints
.
at
<
OpointType
>
(
0
,
i
).
z
;
pws
[
3
*
i
]
=
opoints
.
at
<
OpointType
>
(
i
).
x
;
pws
[
3
*
i
+
1
]
=
opoints
.
at
<
OpointType
>
(
i
).
y
;
pws
[
3
*
i
+
2
]
=
opoints
.
at
<
OpointType
>
(
i
).
z
;
us
[
2
*
i
]
=
ipoints
.
at
<
IpointType
>
(
0
,
i
).
x
*
fu
+
uc
;
us
[
2
*
i
+
1
]
=
ipoints
.
at
<
IpointType
>
(
0
,
i
).
y
*
fv
+
vc
;
us
[
2
*
i
]
=
ipoints
.
at
<
IpointType
>
(
i
).
x
*
fu
+
uc
;
us
[
2
*
i
+
1
]
=
ipoints
.
at
<
IpointType
>
(
i
).
y
*
fv
+
vc
;
}
}
double
reprojection_error
(
const
double
R
[
3
][
3
],
const
double
t
[
3
]);
...
...
modules/calib3d/src/p3p.h
浏览文件 @
b1d01dc7
...
...
@@ -37,11 +37,11 @@ class p3p
points
.
resize
(
20
);
for
(
int
i
=
0
;
i
<
4
;
i
++
)
{
points
[
i
*
5
]
=
ipoints
.
at
<
IpointType
>
(
0
,
i
).
x
*
fx
+
cx
;
points
[
i
*
5
+
1
]
=
ipoints
.
at
<
IpointType
>
(
0
,
i
).
y
*
fy
+
cy
;
points
[
i
*
5
+
2
]
=
opoints
.
at
<
OpointType
>
(
0
,
i
).
x
;
points
[
i
*
5
+
3
]
=
opoints
.
at
<
OpointType
>
(
0
,
i
).
y
;
points
[
i
*
5
+
4
]
=
opoints
.
at
<
OpointType
>
(
0
,
i
).
z
;
points
[
i
*
5
]
=
ipoints
.
at
<
IpointType
>
(
i
).
x
*
fx
+
cx
;
points
[
i
*
5
+
1
]
=
ipoints
.
at
<
IpointType
>
(
i
).
y
*
fy
+
cy
;
points
[
i
*
5
+
2
]
=
opoints
.
at
<
OpointType
>
(
i
).
x
;
points
[
i
*
5
+
3
]
=
opoints
.
at
<
OpointType
>
(
i
).
y
;
points
[
i
*
5
+
4
]
=
opoints
.
at
<
OpointType
>
(
i
).
z
;
}
}
void
init_inverse_parameters
();
...
...
编辑
预览
Markdown
is supported
0%
请重试
或
添加新附件
.
添加附件
取消
You are about to add
0
people
to the discussion. Proceed with caution.
先完成此消息的编辑!
取消
想要评论请
注册
或
登录