Skip to content
This repository was archived by the owner on Nov 20, 2024. It is now read-only.

Conversation

davidetan
Copy link
Contributor

I finally found the time to test the dark tint batcher, and it works great!
This PR just fixes a small issue with dark color and PMA.

Dark color in Spine has just RGB and no alpha. However, since in Pixi we expect colors to be premultiplied, we need to premultiply the dark color by the world alpha (which is the alpha resulting from the parent and normal color alpha).

You can test the difference using these skeletons:

  • Coin, one of our official examples
  • These orange balls that test dark tint in the two possible ways color alpha can be controlled in Spine (separated and not separated from RGB).

Here are two screenshots at 10% of the animation time of the Coin example.
Before fix:
image

After fix:
image

@davidetan davidetan changed the title Fix dark color not premultiplied by world Fix dark color not premultiplied by world alpha Sep 22, 2024
@GoodBoyDigital GoodBoyDigital merged commit 2a51e07 into pixijs:main Sep 24, 2024
1 check passed
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants