Skip to content

fix: resolve false positives with isPixelTransparent helper#250

Merged
tafelnl merged 1 commit intomainfrom
fix/ios-ispixeltransparent-check
May 8, 2026
Merged

fix: resolve false positives with isPixelTransparent helper#250
tafelnl merged 1 commit intomainfrom
fix/ios-ispixeltransparent-check

Conversation

@tafelnl
Copy link
Copy Markdown
Member

@tafelnl tafelnl commented Apr 29, 2026

We changed this logic in #245 to workaround a specific bug for Metal-backed views. However, it returns false positives. For example a black pixel is also seen as transparent, because the all four (checked) bytes are 0.

This PR actually combines the two approaches into a combined more foolproof approach. It uses the snapshot approach to capture the pixel, but it uses the old approach of parsing it into a pixel array.

@tafelnl tafelnl merged commit 72fc5ba into main May 8, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants