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
77fa8d9d
Commit
77fa8d9d
authored
Feb 15, 2016
by
Eric Zavesky
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
- fix windows-based warnings for type casts
parent
335f7e79
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
6 additions
and
6 deletions
+6
-6
planar_tracking.cpp
...torial_code/features2D/AKAZE_tracking/planar_tracking.cpp
+6
-6
No files found.
samples/cpp/tutorial_code/features2D/AKAZE_tracking/planar_tracking.cpp
View file @
77fa8d9d
...
...
@@ -47,8 +47,8 @@ void Tracker::setFirstFrame(const Mat frame, vector<Point2f> bb, string title, S
const
Point
*
ptContain
=
{
&
ptMask
[
0
]
};
int
iSize
=
static_cast
<
int
>
(
bb
.
size
());
for
(
size_t
i
=
0
;
i
<
bb
.
size
();
i
++
)
{
ptMask
[
i
].
x
=
bb
[
i
].
x
;
ptMask
[
i
].
y
=
bb
[
i
].
y
;
ptMask
[
i
].
x
=
static_cast
<
int
>
(
bb
[
i
].
x
)
;
ptMask
[
i
].
y
=
static_cast
<
int
>
(
bb
[
i
].
y
)
;
}
first_frame
=
frame
.
clone
();
cv
::
Mat
matMask
=
cv
::
Mat
::
zeros
(
frame
.
size
(),
CV_8UC1
);
...
...
@@ -172,10 +172,10 @@ int main(int argc, char **argv)
vector
<
Point2f
>
bb
;
if
(
argc
<
4
)
{
//attempt to alow GUI selection
cv
::
Rect2d
uBox
=
selectROI
(
video_name
,
frame
);
bb
.
push_back
(
cv
::
Point2f
(
uBox
.
x
,
uBox
.
y
));
bb
.
push_back
(
cv
::
Point2f
(
uBox
.
x
+
uBox
.
width
,
uBox
.
y
));
bb
.
push_back
(
cv
::
Point2f
(
uBox
.
x
+
uBox
.
width
,
uBox
.
y
+
uBox
.
height
));
bb
.
push_back
(
cv
::
Point2f
(
uBox
.
x
,
uBox
.
y
+
uBox
.
height
));
bb
.
push_back
(
cv
::
Point2f
(
static_cast
<
float
>
(
uBox
.
x
),
static_cast
<
float
>
(
uBox
.
y
)
));
bb
.
push_back
(
cv
::
Point2f
(
static_cast
<
float
>
(
uBox
.
x
+
uBox
.
width
),
static_cast
<
float
>
(
uBox
.
y
)
));
bb
.
push_back
(
cv
::
Point2f
(
static_cast
<
float
>
(
uBox
.
x
+
uBox
.
width
),
static_cast
<
float
>
(
uBox
.
y
+
uBox
.
height
)
));
bb
.
push_back
(
cv
::
Point2f
(
static_cast
<
float
>
(
uBox
.
x
),
static_cast
<
float
>
(
uBox
.
y
+
uBox
.
height
)
));
}
else
{
FileStorage
fs
(
argv
[
3
],
FileStorage
::
READ
);
...
...
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