Skip to content

Commit 33f1379

Browse files
committed
Fix blank sampling on Raspberry PI
1 parent cbf3bde commit 33f1379

File tree

2 files changed

+5
-1
lines changed

2 files changed

+5
-1
lines changed

pathfinder/common/i32x4.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55

66
#include "../config.h"
77

8-
#ifdef __ANDROID__
8+
#if defined(__ANDROID__) || (defined(__linux__) && defined(__ARM_ARCH))
99
// A C/C++ header file that converts Intel SSE intrinsics to Arm/Aarch64 NEON intrinsics.
1010
#include <sse2neon.h>
1111
#else

pathfinder/core/paint/palette.cpp

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -321,6 +321,10 @@ PaintLocationsInfo Palette::assign_paint_locations(const std::shared_ptr<PaintTe
321321
if (!pattern.smoothing_enabled()) {
322322
sampling_flags.value |= TextureSamplingFlags::NEAREST_MIN | TextureSamplingFlags::NEAREST_MAG;
323323
}
324+
// Raspberry PI only supports NEAREST for NPOT textures.
325+
#if defined(__linux__) && defined(__ARM_ARCH)
326+
sampling_flags.value |= TextureSamplingFlags::NEAREST_MIN | TextureSamplingFlags::NEAREST_MAG;
327+
#endif
324328

325329
PaintFilter paint_filter;
326330
// We can have a pattern without a filter.

0 commit comments

Comments
 (0)