Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 7527b88

Browse files
committed
tidy
1 parent 13d2f95 commit 7527b88

File tree

1 file changed

+7
-1
lines changed

1 file changed

+7
-1
lines changed

impeller/entity/contents/filters/gaussian_blur_filter_contents_unittests.cc

Lines changed: 7 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,12 @@
1111
#include "impeller/geometry/geometry_asserts.h"
1212
#include "impeller/renderer/testing/mocks.h"
1313

14+
#if FML_OS_MACOSX
15+
#define IMPELLER_RAND arc4random
16+
#else
17+
#define IMPELLER_RAND rand
18+
#endif
19+
1420
namespace impeller {
1521
namespace testing {
1622

@@ -582,7 +588,7 @@ TEST(GaussianBlurFilterContentsTest, LerpHackKernelSamplesComplex) {
582588
float data[33];
583589
srand(0);
584590
for (int i = 0; i < 33; i++) {
585-
data[i] = 255.0 * static_cast<double>(arc4random()) / RAND_MAX;
591+
data[i] = 255.0 * static_cast<double>(IMPELLER_RAND()) / RAND_MAX;
586592
}
587593

588594
auto sampler = [data](Point point) -> Scalar {

0 commit comments

Comments
 (0)