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
f12702be
Commit
f12702be
authored
Aug 28, 2013
by
Vadim Pisarevsky
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
fixed bugs in rectangular morphology case
parent
771feb61
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
3 deletions
+4
-3
morph.cpp
modules/imgproc/src/morph.cpp
+4
-3
No files found.
modules/imgproc/src/morph.cpp
View file @
f12702be
...
...
@@ -1182,6 +1182,7 @@ static bool IPPMorphReplicate(int op, const Mat &src, Mat &dst, const Mat &kerne
default:
return
false
;
}
#undef IPP_MORPH_CASE
IppiSize
roiSize
=
{
src
.
cols
,
src
.
rows
};
IppiSize
kernelSize
=
{
ksize
.
width
,
ksize
.
height
};
...
...
@@ -1206,7 +1207,7 @@ static bool IPPMorphReplicate(int op, const Mat &src, Mat &dst, const Mat &kerne
AutoBuffer
<
uchar
>
buf
(
bufSize
+
64
);
uchar
*
buffer
=
alignPtr
((
uchar
*
)
buf
,
32
);
return
morphRectFunc
(
_src
->
data
,
(
int
)
_src
->
step
[
0
],
dst
.
data
,
(
int
)
dst
.
step
[
0
],
roiSize
,
kernelSize
,
point
,
buffer
);
roiSize
,
kernelSize
,
point
,
buffer
)
>=
0
;
}
return
false
;
}
...
...
@@ -1268,7 +1269,7 @@ static bool IPPMorphOp(int op, InputArray _src, OutputArray _dst,
rectKernel
=
true
;
iterations
=
1
;
}
else
if
(
iterations
>
1
&&
countNonZero
(
kernel
)
==
kernel
.
rows
*
kernel
.
cols
)
else
if
(
iterations
>
=
1
&&
countNonZero
(
kernel
)
==
kernel
.
rows
*
kernel
.
cols
)
{
ksize
=
Size
(
ksize
.
width
+
(
iterations
-
1
)
*
(
ksize
.
width
-
1
),
ksize
.
height
+
(
iterations
-
1
)
*
(
ksize
.
height
-
1
)),
...
...
@@ -1475,7 +1476,7 @@ static void convertConvKernel( const IplConvKernel* src, cv::Mat& dst, cv::Point
int
i
,
size
=
src
->
nRows
*
src
->
nCols
;
for
(
i
=
0
;
i
<
size
;
i
++
)
dst
.
data
[
i
]
=
(
uchar
)
src
->
values
[
i
]
;
dst
.
data
[
i
]
=
(
uchar
)
(
src
->
values
[
i
]
!=
0
)
;
}
...
...
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