projects
/
platform
/
upstream
/
opencv.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
b973b73
)
#6443 Cast maxscale from double to float for scale calculation.
author
Bob Paulin
<bob@apache.org>
Thu, 21 Apr 2016 12:47:13 +0000
(07:47 -0500)
committer
Bob Paulin
<bob@apache.org>
Thu, 21 Apr 2016 12:47:13 +0000
(07:47 -0500)
apps/createsamples/utility.cpp
patch
|
blob
|
history
diff --git
a/apps/createsamples/utility.cpp
b/apps/createsamples/utility.cpp
index
ddcc1eb
..
cf2bdeb
100644
(file)
--- a/
apps/createsamples/utility.cpp
+++ b/
apps/createsamples/utility.cpp
@@
-1372,7
+1372,7
@@
void cvCreateTestSamples( const char* infoname,
if( maxscale < 1.0F ) continue;
- scale = (maxscale - 1.0F) * rand() / RAND_MAX + 1.0F;
+ scale = (
(float)
maxscale - 1.0F) * rand() / RAND_MAX + 1.0F;
width = (int) (scale * winwidth);
height = (int) (scale * winheight);