Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

GRAPHICS: Fix incorrect Win cursor mask behavior when a non-white color is masked #4885

Merged
merged 1 commit into from Apr 6, 2023

Conversation

elasota
Copy link
Contributor

@elasota elasota commented Apr 6, 2023

Currently the cursor loader flags pixels as inverted if the pixel's color index is non-zero.

Per the WDDM spec, a pixel with 1 in the AND field is inverted if the color is white. No behavior is defined for pixels with non-white color, but in practice, the behavior Windows uses is that any other color becomes transparent.

This fixes the cursor loader to reflect that behavior.

Fixes https://bugs.scummvm.org/ticket/14386

@elasota elasota force-pushed the fix-riven-cursors branch 4 times, most recently from 5057263 to 27ff350 Compare April 6, 2023 03:08
…e and treat any other color with AND mask value 1 as transparent.

Fixes incorrect cursor transparency in Riven.
@sev-
Copy link
Member

sev- commented Apr 6, 2023

Thank you!

@sev- sev- merged commit e99485a into scummvm:master Apr 6, 2023
8 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
2 participants