Skip to content

Commit

Permalink
opencv#6443 Cast maxscale from double to float for scale calculation.
Browse files Browse the repository at this point in the history
  • Loading branch information
bobpaulin committed Apr 21, 2016
1 parent b973b73 commit bb8faec
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/createsamples/utility.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -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);
Expand Down

0 comments on commit bb8faec

Please sign in to comment.