-
Notifications
You must be signed in to change notification settings - Fork 823
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
Fix ColorMatrix tint method #921
base: master
Are you sure you want to change the base?
Conversation
Thanks a lot for the pull request, and sorry for the late reply (I was on a vacation). May I ask where you've got this information from? I must admit the existing code was just copied from here, and I haven't checked if the output is identical to what Adobe Animate produces. The problem with this change is that it will change the color output of all all existing users of this method, which might be problematic. What do others say? I'd prefer to have the same output as Adobe Animate, but I'm not too happy changing people's tinting. 😐 |
I've checked it myself, comparing graphic results, your and my code.
You're right except if developers that use it expect the same result as in Animate. The safer solution is certainly to change the documentation for tint removing the description and create an editorTint method with the description you have at the moment for tint :) |
Thanks for the update! To everybody else in the loop: what's your opinion on this? Any heavy users of this method around? |
I used tint in m'y previous game an i remember having problems to get the same result as in flash pro. I think the solution to create an another method is good, so no need to find every usage of the tint method to retune it on the next update :) |
I found strange behaviors in Starling. Using the same shader in PixiJs and Starling, the result is different. |
Thanks for the feedback, @binouze! @mathieuanthoine: What you're describing might be a difference in how PixiJS handles premultiplied alpha. In Starling 2, all colors are expected to use premultiplied alpha, and I'm making up for that in the shader. I don't know what PixiJS does in this respect. (Could be something else entirely, of course — I just thought I mention it.) |
I'm not as solid as I would like about Shaders in Starling/AS3, how can I help to fix the tint method ? |
@mathieuanthoine Do you mean that in PixiJS, the results are identical with those from Adobe Animate, but Starling produces different results (even with your changes)? |
@PrimaryFeather Not exactly If in PixiJS I use the shader I give you for Starling, you will have the same tint as Animate. I think the best way to check if the shader is the good one would be to apply the shader on a classic MovieClip in Animate. |
To get the exact Adobe Animate tint, you need to remove the LUMA factor from the tint method.