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
29cfeb7c
Commit
29cfeb7c
authored
Mar 22, 2013
by
Andrey Kamaev
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Fix build of apps and samples
parent
688d170d
Hide whitespace changes
Inline
Side-by-side
Showing
6 changed files
with
13 additions
and
13 deletions
+13
-13
common.hpp
apps/sft/include/sft/common.hpp
+1
-1
latentsvm_multidetect.cpp
samples/cpp/latentsvm_multidetect.cpp
+4
-4
linemod.cpp
samples/cpp/linemod.cpp
+3
-3
peopledetect.cpp
samples/cpp/peopledetect.cpp
+2
-2
stitching_detailed.cpp
samples/cpp/stitching_detailed.cpp
+2
-2
video_dmtx.cpp
samples/cpp/video_dmtx.cpp
+1
-1
No files found.
apps/sft/include/sft/common.hpp
View file @
29cfeb7c
...
...
@@ -54,7 +54,7 @@ namespace sft
using
cv
::
Mat
;
struct
ICF
;
typedef
std
::
s
tring
string
;
typedef
cv
::
S
tring
string
;
typedef
std
::
vector
<
ICF
>
Icfvector
;
typedef
std
::
vector
<
sft
::
string
>
svector
;
...
...
samples/cpp/latentsvm_multidetect.cpp
View file @
29cfeb7c
...
...
@@ -47,7 +47,7 @@ static void detectAndDrawObjects( Mat& image, LatentSvmDetector& detector, const
cout
<<
"Detection time = "
<<
tm
.
getTimeSec
()
<<
" sec"
<<
endl
;
const
vector
<
s
tring
>
classNames
=
detector
.
getClassNames
();
const
vector
<
S
tring
>
classNames
=
detector
.
getClassNames
();
CV_Assert
(
colors
.
size
()
==
classNames
.
size
()
);
for
(
size_t
i
=
0
;
i
<
detections
.
size
();
i
++
)
...
...
@@ -63,7 +63,7 @@ static void detectAndDrawObjects( Mat& image, LatentSvmDetector& detector, const
}
}
static
void
readDirectory
(
const
string
&
directoryName
,
vector
<
s
tring
>&
filenames
,
bool
addDirectoryName
=
true
)
static
void
readDirectory
(
const
string
&
directoryName
,
vector
<
S
tring
>&
filenames
,
bool
addDirectoryName
=
true
)
{
filenames
.
clear
();
...
...
@@ -123,7 +123,7 @@ int main(int argc, char* argv[])
if
(
argc
>
4
)
numThreads
=
atoi
(
argv
[
4
]);
}
vector
<
s
tring
>
images_filenames
,
models_filenames
;
vector
<
S
tring
>
images_filenames
,
models_filenames
;
readDirectory
(
images_folder
,
images_filenames
);
readDirectory
(
models_folder
,
models_filenames
);
...
...
@@ -134,7 +134,7 @@ int main(int argc, char* argv[])
exit
(
-
1
);
}
const
vector
<
s
tring
>&
classNames
=
detector
.
getClassNames
();
const
vector
<
S
tring
>&
classNames
=
detector
.
getClassNames
();
cout
<<
"Loaded "
<<
classNames
.
size
()
<<
" models:"
<<
endl
;
for
(
size_t
i
=
0
;
i
<
classNames
.
size
();
i
++
)
{
...
...
samples/cpp/linemod.cpp
View file @
29cfeb7c
...
...
@@ -130,7 +130,7 @@ static void writeLinemod(const cv::Ptr<cv::linemod::Detector>& detector, const s
cv
::
FileStorage
fs
(
filename
,
cv
::
FileStorage
::
WRITE
);
detector
->
write
(
fs
);
std
::
vector
<
std
::
s
tring
>
ids
=
detector
->
classIds
();
std
::
vector
<
cv
::
S
tring
>
ids
=
detector
->
classIds
();
fs
<<
"classes"
<<
"["
;
for
(
int
i
=
0
;
i
<
(
int
)
ids
.
size
();
++
i
)
{
...
...
@@ -177,7 +177,7 @@ int main(int argc, char * argv[])
{
detector
=
readLinemod
(
argv
[
1
]);
std
::
vector
<
std
::
s
tring
>
ids
=
detector
->
classIds
();
std
::
vector
<
cv
::
S
tring
>
ids
=
detector
->
classIds
();
num_classes
=
detector
->
numClasses
();
printf
(
"Loaded %s with %d classes and %d templates
\n
"
,
argv
[
1
],
num_classes
,
detector
->
numTemplates
());
...
...
@@ -260,7 +260,7 @@ int main(int argc, char * argv[])
// Perform matching
std
::
vector
<
cv
::
linemod
::
Match
>
matches
;
std
::
vector
<
std
::
s
tring
>
class_ids
;
std
::
vector
<
cv
::
S
tring
>
class_ids
;
std
::
vector
<
cv
::
Mat
>
quantized_images
;
match_timer
.
start
();
detector
->
match
(
sources
,
(
float
)
matching_threshold
,
matches
,
class_ids
,
quantized_images
);
...
...
samples/cpp/peopledetect.cpp
View file @
29cfeb7c
...
...
@@ -84,13 +84,13 @@ int main(int argc, char** argv)
}
std
::
string
src
=
parser
.
get
<
std
::
string
>
(
"frame"
);
std
::
vector
<
std
::
s
tring
>
frames
;
std
::
vector
<
cv
::
S
tring
>
frames
;
cv
::
glob
(
parser
.
get
<
std
::
string
>
(
"frame"
),
frames
);
std
::
cout
<<
"collected "
<<
src
<<
" "
<<
frames
.
size
()
<<
" frames."
<<
std
::
endl
;
for
(
int
i
=
0
;
i
<
(
int
)
frames
.
size
();
++
i
)
{
std
::
string
&
frame_sourse
=
frames
[
i
];
std
::
string
frame_sourse
=
frames
[
i
];
cv
::
Mat
frame
=
cv
::
imread
(
frame_sourse
);
if
(
frame
.
empty
())
...
...
samples/cpp/stitching_detailed.cpp
View file @
29cfeb7c
...
...
@@ -121,7 +121,7 @@ static void printUsage()
// Default command line args
vector
<
s
tring
>
img_names
;
vector
<
S
tring
>
img_names
;
bool
preview
=
false
;
bool
try_gpu
=
false
;
double
work_megapix
=
0.6
;
...
...
@@ -446,7 +446,7 @@ int main(int argc, char* argv[])
// Leave only images we are sure are from the same panorama
vector
<
int
>
indices
=
leaveBiggestComponent
(
features
,
pairwise_matches
,
conf_thresh
);
vector
<
Mat
>
img_subset
;
vector
<
s
tring
>
img_names_subset
;
vector
<
S
tring
>
img_names_subset
;
vector
<
Size
>
full_img_sizes_subset
;
for
(
size_t
i
=
0
;
i
<
indices
.
size
();
++
i
)
{
...
...
samples/cpp/video_dmtx.cpp
View file @
29cfeb7c
...
...
@@ -53,7 +53,7 @@ namespace
break
;
cv
::
Mat
gray
;
cv
::
cvtColor
(
frame
,
gray
,
CV_RGB2GRAY
);
vector
<
s
tring
>
codes
;
vector
<
S
tring
>
codes
;
Mat
corners
;
findDataMatrix
(
gray
,
codes
,
corners
);
drawDataMatrixCodes
(
frame
,
codes
,
corners
);
...
...
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