Skip to content

Commit

Permalink
Fix shadow span issue
Browse files Browse the repository at this point in the history
Backports part of
WebKit/WebKit@7bc1ae1
to fix a problem with shadows getting cut off.
  • Loading branch information
mnutt committed Sep 6, 2024
1 parent 9a33154 commit 06d2f5e
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion Source/WebCore/platform/graphics/ShadowBlur.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -348,7 +348,7 @@ void ShadowBlur::blurLayerImage(std::span<uint8_t> imageData, const IntSize& siz
sum += next.front() - prev.front();
}

for (; i < dim && ptr.size() <= stride && prev.size() >= stride; ptr = ptr.subspan(stride), prev = prev.subspan(stride), ++i) {
for (; i < dim && ptr.size() >= stride && prev.size() >= stride; ptr = ptr.subspan(stride), prev = prev.subspan(stride), ++i) {
ptr[0] = (sum * invCount) >> blurSumShift;
sum += alpha2 - prev.front();
}
Expand Down

0 comments on commit 06d2f5e

Please sign in to comment.