Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
0
Issues
0
List
Board
Labels
Milestones
Merge Requests
0
Merge Requests
0
CI / CD
CI / CD
Pipelines
Jobs
Schedules
Charts
Packages
Packages
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
submodule
opencv
Commits
b7be4942
Commit
b7be4942
authored
Feb 24, 2015
by
Mansour Moufid
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Cast some image coordinates and sizes to double.
parent
06b97b7b
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
12 additions
and
4 deletions
+12
-4
test_reproject_image_to_3d.cpp
modules/calib3d/test/test_reproject_image_to_3d.cpp
+6
-1
test_undistort_badarg.cpp
modules/calib3d/test/test_undistort_badarg.cpp
+4
-1
perf_imgproc.cpp
modules/gpu/perf/perf_imgproc.cpp
+2
-2
No files found.
modules/calib3d/test/test_reproject_image_to_3d.cpp
View file @
b7be4942
...
...
@@ -137,7 +137,12 @@ protected:
{
InT
d
=
disp
(
y
,
x
);
double
from
[
4
]
=
{
x
,
y
,
d
,
1
};
double
from
[
4
]
=
{
static_cast
<
double
>
(
x
),
static_cast
<
double
>
(
y
),
static_cast
<
double
>
(
d
),
1.0
,
};
Mat_
<
double
>
res
=
Q
*
Mat_
<
double
>
(
4
,
1
,
from
);
res
/=
res
(
3
,
0
);
...
...
modules/calib3d/test/test_undistort_badarg.cpp
View file @
b7be4942
...
...
@@ -101,7 +101,10 @@ void CV_UndistortPointsBadArgTest::run(int)
img_size
.
height
=
600
;
double
cam
[
9
]
=
{
150.
f
,
0.
f
,
img_size
.
width
/
2.
f
,
0
,
300.
f
,
img_size
.
height
/
2.
f
,
0.
f
,
0.
f
,
1.
f
};
double
dist
[
4
]
=
{
0.01
,
0.02
,
0.001
,
0.0005
};
double
s_points
[
N_POINTS2
]
=
{
img_size
.
width
/
4
,
img_size
.
height
/
4
};
double
s_points
[
N_POINTS2
]
=
{
static_cast
<
double
>
(
img_size
.
width
)
/
4.0
,
static_cast
<
double
>
(
img_size
.
height
)
/
4.0
,
};
double
d_points
[
N_POINTS2
];
double
p
[
9
]
=
{
155.
f
,
0.
f
,
img_size
.
width
/
2.
f
+
img_size
.
width
/
50.
f
,
0
,
310.
f
,
img_size
.
height
/
2.
f
+
img_size
.
height
/
50.
f
,
0.
f
,
0.
f
,
1.
f
};
double
r
[
9
]
=
{
1
,
0
,
0
,
0
,
1
,
0
,
0
,
0
,
1
};
...
...
modules/gpu/perf/perf_imgproc.cpp
View file @
b7be4942
...
...
@@ -253,7 +253,7 @@ PERF_TEST_P(Sz_Depth_Cn_Inter_Border, ImgProc_WarpAffine,
const
double
aplha
=
CV_PI
/
4
;
const
double
mat
[
2
*
3
]
=
{
std
::
cos
(
aplha
),
-
std
::
sin
(
aplha
),
s
rc
.
cols
/
2
,
std
::
cos
(
aplha
),
-
std
::
sin
(
aplha
),
s
tatic_cast
<
double
>
(
src
.
cols
)
/
2.0
,
std
::
sin
(
aplha
),
std
::
cos
(
aplha
),
0
};
const
cv
::
Mat
M
(
2
,
3
,
CV_64F
,
(
void
*
)
mat
);
...
...
@@ -301,7 +301,7 @@ PERF_TEST_P(Sz_Depth_Cn_Inter_Border, ImgProc_WarpPerspective,
declare
.
in
(
src
,
WARMUP_RNG
);
const
double
aplha
=
CV_PI
/
4
;
double
mat
[
3
][
3
]
=
{
{
std
::
cos
(
aplha
),
-
std
::
sin
(
aplha
),
s
rc
.
cols
/
2
},
double
mat
[
3
][
3
]
=
{
{
std
::
cos
(
aplha
),
-
std
::
sin
(
aplha
),
s
tatic_cast
<
double
>
(
src
.
cols
)
/
2.0
},
{
std
::
sin
(
aplha
),
std
::
cos
(
aplha
),
0
},
{
0.0
,
0.0
,
1.0
}};
const
cv
::
Mat
M
(
3
,
3
,
CV_64F
,
(
void
*
)
mat
);
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment