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
52050ebe
Commit
52050ebe
authored
Feb 08, 2019
by
Alexander Alekhin
Browse files
Options
Browse Files
Download
Plain Diff
Merge pull request #13760 from AnastasiaaSenina:fix-bug
parents
3091d10b
d7b1f28a
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
2 additions
and
0 deletions
+2
-0
camshift.cpp
modules/video/src/camshift.cpp
+2
-0
No files found.
modules/video/src/camshift.cpp
View file @
52050ebe
...
...
@@ -167,6 +167,8 @@ cv::RotatedRect cv::CamShift( InputArray _probImage, Rect& window,
double
rotate_a
=
cs
*
cs
*
mu20
+
2
*
cs
*
sn
*
mu11
+
sn
*
sn
*
mu02
;
double
rotate_c
=
sn
*
sn
*
mu20
-
2
*
cs
*
sn
*
mu11
+
cs
*
cs
*
mu02
;
rotate_a
=
std
::
max
(
0.0
,
rotate_a
);
// avoid negative result due calculation numeric errors
rotate_c
=
std
::
max
(
0.0
,
rotate_c
);
// avoid negative result due calculation numeric errors
double
length
=
std
::
sqrt
(
rotate_a
*
inv_m00
)
*
4
;
double
width
=
std
::
sqrt
(
rotate_c
*
inv_m00
)
*
4
;
...
...
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