diff --git a/modules/calib3d/src/rhorefc.cpp b/modules/calib3d/src/rhorefc.cpp index 4abbd4ec3d..7b30825064 100644 --- a/modules/calib3d/src/rhorefc.cpp +++ b/modules/calib3d/src/rhorefc.cpp @@ -45,6 +45,7 @@ /* Includes */ #include +#include #include #include #include @@ -476,11 +477,7 @@ inline int RHO_HEST_REFC::initialize(void){ lm.tmp1 = NULL; lm.Jte = NULL; -#ifdef _WIN32 - fastSeed(rand()); -#else - fastSeed(random()); -#endif + fastSeed((unsigned)cv::theRNG()); int areAllAllocsSuccessful = ctrl.smpl &&