Skip to content
GitLab
Menu
Projects
Groups
Snippets
Loading...
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
OpenDAS
dlib
Commits
a48cde58
"tests/dist/git@developer.sourcefind.cn:OpenDAS/dgl.git" did not exist on "996a9364fc1c2711013dee081057a299b534cc5e"
Commit
a48cde58
authored
Aug 24, 2012
by
Davis King
Browse files
fleshed the full_object_detection out a little more.
parent
2e619438
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
17 additions
and
0 deletions
+17
-0
dlib/image_processing/full_object_detection.h
dlib/image_processing/full_object_detection.h
+17
-0
No files found.
dlib/image_processing/full_object_detection.h
View file @
a48cde58
...
...
@@ -24,6 +24,8 @@ namespace dlib
const
std
::
vector
<
point
>&
movable_parts_
)
:
rect
(
rect_
),
movable_parts
(
movable_parts_
)
{}
full_object_detection
(){}
explicit
full_object_detection
(
const
rectangle
&
rect_
)
:
rect
(
rect_
)
{}
...
...
@@ -32,6 +34,21 @@ namespace dlib
std
::
vector
<
point
>
movable_parts
;
// it should always be the case that rect.contains(movable_parts[i]) == true
};
// ----------------------------------------------------------------------------------------
inline
bool
all_parts_in_rect
(
const
full_object_detection
&
obj
)
{
for
(
unsigned
long
i
=
0
;
i
<
obj
.
movable_parts
.
size
();
++
i
)
{
if
(
obj
.
rect
.
contains
(
obj
.
movable_parts
[
i
])
==
false
&&
obj
.
movable_parts
[
i
]
!=
MOVABLE_PART_NOT_PRESENT
)
return
false
;
}
return
true
;
}
// ----------------------------------------------------------------------------------------
}
...
...
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