X-Git-Url: http://review.tizen.org/git/?a=blobdiff_plain;f=dali%2Fpublic-api%2Fmath%2Frandom.h;h=1b08956942622ac6a351c956f73908c24af912cf;hb=646f736e77b085c86e982c0d1d4b895c2a431330;hp=2d5d2372aa8dcb2e38ec5c066066f3d0f4714ca9;hpb=af9100d2cfdd582fcd5702d3394c9c4936072d8e;p=platform%2Fcore%2Fuifw%2Fdali-core.git diff --git a/dali/public-api/math/random.h b/dali/public-api/math/random.h index 2d5d237..1b08956 100644 --- a/dali/public-api/math/random.h +++ b/dali/public-api/math/random.h @@ -2,7 +2,7 @@ #define __DALI_RANDOM_H__ /* - * Copyright (c) 2017 Samsung Electronics Co., Ltd. + * Copyright (c) 2018 Samsung Electronics Co., Ltd. * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -54,13 +54,13 @@ inline float Range(float f0, float f1) static bool initialized( false ); if( !initialized ) { - auto seed = time( NULL ); + uint32_t seed = static_cast( time( NULL ) ); srand( seed ); initialized = true; } - auto randValue = rand(); - return (randValue & 0xfff) * (1.0f/4095.0f) * (max-min) + min; + int32_t randValue = rand(); + return static_cast(randValue & 0xfff) * (1.0f/4095.0f) * (max-min) + min; } /**