Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
D
dlib
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
Wiki
Wiki
Snippets
Snippets
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Jobs
Commits
Issue Boards
Open sidebar
钟尚武
dlib
Commits
d847c130
Commit
d847c130
authored
7 years ago
by
Davis King
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Added neighbors_24
parent
8a48eee4
master
v19.17
v19.16
v19.15
v19.14
v19.13
v19.12
v19.11
No related merge requests found
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
32 additions
and
0 deletions
+32
-0
label_connected_blobs.h
dlib/image_transforms/label_connected_blobs.h
+14
-0
label_connected_blobs_abstract.h
dlib/image_transforms/label_connected_blobs_abstract.h
+18
-0
No files found.
dlib/image_transforms/label_connected_blobs.h
View file @
d847c130
...
...
@@ -13,6 +13,20 @@ namespace dlib
// ----------------------------------------------------------------------------------------
struct
neighbors_24
{
void
operator
()
(
const
point
&
p
,
std
::
vector
<
point
>&
neighbors
)
const
{
for
(
long
i
=
-
2
;
i
<=
2
;
++
i
)
for
(
long
j
=
-
2
;
j
<=
2
;
++
j
)
if
(
i
!=
0
||
j
!=
0
)
neighbors
.
push_back
(
point
(
p
.
x
()
+
i
,
p
.
y
()
+
j
));
}
};
struct
neighbors_8
{
void
operator
()
(
...
...
This diff is collapsed.
Click to expand it.
dlib/image_transforms/label_connected_blobs_abstract.h
View file @
d847c130
...
...
@@ -12,6 +12,24 @@ namespace dlib
// ----------------------------------------------------------------------------------------
struct
neighbors_24
{
/*!
WHAT THIS OBJECT REPRESENTS
This object is a pixel neighborhood generating functor for
use with the label_connected_blobs() routine defined below.
!*/
void
operator
()
(
const
point
&
p
,
std
::
vector
<
point
>&
neighbors
)
const
;
/*!
ensures
- adds the 24 neighboring pixels surrounding p into neighbors
!*/
};
struct
neighbors_8
{
/*!
...
...
This diff is collapsed.
Click to expand it.
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