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
b2e0873a
Commit
b2e0873a
authored
Nov 10, 2016
by
Alexander Alekhin
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #7629 from alalek:issue_7626
parents
a2d6d96e
183c7535
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
8 additions
and
2 deletions
+8
-2
contours.cpp
modules/imgproc/src/contours.cpp
+8
-2
No files found.
modules/imgproc/src/contours.cpp
View file @
b2e0873a
...
...
@@ -50,10 +50,15 @@
static
const
CvPoint
icvCodeDeltas
[
8
]
=
{
CvPoint
(
1
,
0
),
CvPoint
(
1
,
-
1
),
CvPoint
(
0
,
-
1
),
CvPoint
(
-
1
,
-
1
),
CvPoint
(
-
1
,
0
),
CvPoint
(
-
1
,
1
),
CvPoint
(
0
,
1
),
CvPoint
(
1
,
1
)
};
#if CV_SSE2
static
inline
unsigned
int
trailingZeros
(
unsigned
int
value
)
{
CV_DbgAssert
(
value
!=
0
);
// undefined for zero input (https://en.wikipedia.org/wiki/Find_first_set)
#if defined(_MSC_VER)
#if (_MSC_VER < 1500)
return
_BitScanForward
(
value
);
#if (_MSC_VER < 1700)
unsigned
long
index
=
0
;
_BitScanForward
(
&
index
,
value
);
return
(
unsigned
int
)
index
;
#else
return
_tzcnt_u32
(
value
);
#endif
...
...
@@ -70,6 +75,7 @@ inline unsigned int trailingZeros(unsigned int value) {
return
MultiplyDeBruijnBitPosition
[((
uint32_t
)((
value
&
-
value
)
*
0x077CB531U
))
>>
27
];
#endif
}
#endif
CV_IMPL
void
cvStartReadChainPoints
(
CvChain
*
chain
,
CvChainPtReader
*
reader
)
...
...
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