Fix Clang warning due to implicit conversion from int to float for the RAND_MAX macro (#7717)

* fix compiler warning due to implicit conversion

* fix warnings from plugins too
This commit is contained in:
Rossmaxx
2025-03-02 03:18:37 +05:30
committed by GitHub
parent 3c3441bb0c
commit 050df381b0
4 changed files with 9 additions and 9 deletions

View File

@@ -163,7 +163,7 @@ public:
static inline sample_t noiseSample( const float )
{
return 1.0f - rand() * 2.0f / RAND_MAX;
return 1.0f - rand() * 2.0f / static_cast<float>(RAND_MAX);
}
static sample_t userWaveSample(const SampleBuffer* buffer, const float sample)