Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in / Register
Toggle navigation
O
opencv_contrib
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_contrib
Commits
4bfc2ab8
Commit
4bfc2ab8
authored
Aug 21, 2015
by
Vladimir
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fixed segmentation fault error in TRACK_vot::getNextFrame()
parent
aa26cc62
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
9 additions
and
10 deletions
+9
-10
track_vot.cpp
modules/datasets/samples/track_vot.cpp
+2
-2
track_vot.cpp
modules/datasets/src/track_vot.cpp
+4
-1
multiTracker_dataset.cpp
modules/tracking/samples/multiTracker_dataset.cpp
+2
-4
tracker_dataset.cpp
modules/tracking/samples/tracker_dataset.cpp
+1
-3
No files found.
modules/datasets/samples/track_vot.cpp
View file @
4bfc2ab8
...
@@ -82,8 +82,8 @@ int main(int argc, char *argv[])
...
@@ -82,8 +82,8 @@ int main(int argc, char *argv[])
for
(
int
i
=
0
;
i
<
dataset
->
getDatasetLength
(
datasetID
);
i
++
)
for
(
int
i
=
0
;
i
<
dataset
->
getDatasetLength
(
datasetID
);
i
++
)
{
{
Mat
frame
;
Mat
frame
;
dataset
->
getNextFrame
(
frame
);
if
(
!
dataset
->
getNextFrame
(
frame
))
break
;
//Draw Ground Truth BB
//Draw Ground Truth BB
vector
<
Point2d
>
gtPoints
=
dataset
->
getGT
();
vector
<
Point2d
>
gtPoints
=
dataset
->
getGT
();
for
(
int
j
=
0
;
j
<
(
int
)(
gtPoints
.
size
()
-
1
);
j
++
)
for
(
int
j
=
0
;
j
<
(
int
)(
gtPoints
.
size
()
-
1
);
j
++
)
...
...
modules/datasets/src/track_vot.cpp
View file @
4bfc2ab8
...
@@ -210,7 +210,10 @@ namespace cv
...
@@ -210,7 +210,10 @@ namespace cv
bool
TRACK_votImpl
::
getNextFrame
(
Mat
&
frame
)
bool
TRACK_votImpl
::
getNextFrame
(
Mat
&
frame
)
{
{
frame
=
imread
(
data
[
activeDatasetID
-
1
][
frameCounter
]
->
imagePath
);
if
(
frameCounter
>=
(
int
)
data
[
activeDatasetID
-
1
].
size
())
return
false
;
string
imgPath
=
data
[
activeDatasetID
-
1
][
frameCounter
]
->
imagePath
;
frame
=
imread
(
imgPath
);
frameCounter
++
;
frameCounter
++
;
return
!
frame
.
empty
();
return
!
frame
.
empty
();
}
}
...
...
modules/tracking/samples/multiTracker_dataset.cpp
View file @
4bfc2ab8
...
@@ -50,7 +50,7 @@ using namespace std;
...
@@ -50,7 +50,7 @@ using namespace std;
using
namespace
cv
;
using
namespace
cv
;
using
namespace
cv
::
datasets
;
using
namespace
cv
::
datasets
;
#define NUM_TEST_FRAMES 100
#define NUM_TEST_FRAMES 100
0
static
Mat
image
;
static
Mat
image
;
static
bool
paused
;
static
bool
paused
;
...
@@ -170,10 +170,8 @@ int main(int argc, char *argv[])
...
@@ -170,10 +170,8 @@ int main(int argc, char *argv[])
//Time measurment
//Time measurment
int64
e1
=
getTickCount
();
int64
e1
=
getTickCount
();
if
(
initialized
){
if
(
initialized
){
dataset
->
getNextFrame
(
frame
);
if
(
!
dataset
->
getNextFrame
(
frame
))
if
(
frame
.
empty
()){
break
;
break
;
}
frame
.
copyTo
(
image
);
frame
.
copyTo
(
image
);
}
}
...
...
modules/tracking/samples/tracker_dataset.cpp
View file @
4bfc2ab8
...
@@ -169,10 +169,8 @@ int main(int argc, char *argv[])
...
@@ -169,10 +169,8 @@ int main(int argc, char *argv[])
//Time measurment
//Time measurment
int64
e1
=
getTickCount
();
int64
e1
=
getTickCount
();
if
(
initialized
){
if
(
initialized
){
dataset
->
getNextFrame
(
frame
);
if
(
!
dataset
->
getNextFrame
(
frame
))
if
(
frame
.
empty
()){
break
;
break
;
}
frame
.
copyTo
(
image
);
frame
.
copyTo
(
image
);
}
}
...
...
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