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
71ae8e0d
Commit
71ae8e0d
authored
Mar 27, 2017
by
Alexander Alekhin
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #1088 from cbalint13:lsc_fix
parents
38758066
90105169
Show whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
0 deletions
+3
-0
lsc.cpp
modules/ximgproc/src/lsc.cpp
+3
-0
No files found.
modules/ximgproc/src/lsc.cpp
View file @
71ae8e0d
...
...
@@ -768,6 +768,8 @@ inline void SuperpixelLSCImpl::PostEnforceLabelConnectivity( int threshold )
double
W
=
W1
+
W2
;
if
(
(
Label1
>
0
)
&&
(
Label2
>
0
)
)
{
for
(
int
b
=
0
;
b
<
m_nr_channels
;
b
++
)
{
centerC1
[
b
][
Label2
]
=
float
((
W2
*
centerC1
[
b
][
Label2
]
+
W1
*
centerC1
[
b
][
Label1
])
/
W
);
...
...
@@ -785,6 +787,7 @@ inline void SuperpixelLSCImpl::PostEnforceLabelConnectivity( int threshold )
int
y
=
(
*
S
).
yLoc
[
i
];
m_klabels
.
at
<
int
>
(
y
,
x
)
=
Label2
;
}
}
vector
<
Superpixel
>::
iterator
Stmp
;
Stmp
=
find
(
Sarray
.
begin
(),
Sarray
.
end
(),
Label2
);
...
...
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