-
Notifications
You must be signed in to change notification settings - Fork 101
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
Tiles drawn with white pixels #139
Comments
I spoke too soon. The issue appears in all acts, just much less noticable. aside from the background color not matching black like on desktop, this looks like an index is mismatched. need to look into the specific index and pixel shader |
Experimented using different blend mode and still got the same behavior. |
Playing with the palettes directly shows that this appears to be an issue with index 254 across at least act 1 and 3 (the only ones that I've tested). The working assumption is that for some reason this value gets rounded up to index 255, which is white. Going to play around with texture filtering and wrapping and if need be, clamping the 0.5f offset to prevent a possible unwanted rounding because 254 is close enough to 2^8 (256). |
Texture filtering looks alright -- I assigned the renders to the default values. My guess is that this is caused by some rounding issue relating to the pixel (frag) shader for the upper index. This will require more extensive investigation to a more permanent suitable fix, however in the meantime I've added a workaround to the shader to translate index 255 to index 254 which has had no apparent side effects (have not tested or looked for legitimate uses of index 255). I'm uncomfortable with this fix until I can figure out why this is happening in only newest version of android. Index 255 is the same in every included palette ( |
Noticed this issue on the latest version of Android where the 0 index on tiles shows up as white, even though
glClearColor
is set to black. Only occurs on acts 3-5 so far from what I've seen. This did not used to happen on older versions of Android, and does not occur on PC.Tiles have always been drawn incorrectly where index 0 is transparent, and since the background is black and index 0 is black, it hasn't mattered, but something with the newer OpenGL ES may be effecting this behavior. I have a special draw setting for tiles that should draw index 0 as black, it might not be enabled, or the palettes might need to be looked at. Another possibility is the transparency draw call, i.e., are the tiles being drawn on the newer version of android as opaque, causing white pixels because it can't blit them correctly.
The text was updated successfully, but these errors were encountered: