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

Strange New Sprite Behavior #420

Open
ArendDanielek opened this issue Oct 2, 2018 · 0 comments
Open

Strange New Sprite Behavior #420

ArendDanielek opened this issue Oct 2, 2018 · 0 comments

Comments

@ArendDanielek
Copy link
Collaborator

Description

Repro

Import any multicolored sprite into the engine (preferrably with whites, light colors, pure colors, dark colors, and blacks in the image)
Create a Sprite and give the new sprite the imported SpriteSource.
Change the Material to "AdditiveSprite".
Notice how the colors look strangely faded, not truly "added" like in the previous Zero engine.
Select the Renderer Object.
Change the ClearColor to Black, with Alpha of 0.
Notice that the closer a color is to white, the more white it becomes when "Additive"
Use the gradient window to slide the ClearColor between black and white, still transparent.
Notice how the colors of the multicolored Sprite react as though the ClearColor was fully opaque.
. . .
Change the Material of the multicolored Sprite back to "AlphaSprite".
Create a new Sprite, just a white square, and place it over the multi-colored Sprite
Change the white square's Material to "AlphaSprite"
Try moving the white square in front of the muticolored Sprite (which is an AlphaSprite)
Notice that even when the AlphaSprite is far behind the AdditiveSprite, it is rendered in full color as though "in front" of the AdditiveSprite.

Expected

The "Additive" Sprites should mask over whatever is in front of them, and appear behind what is behind them.
They should also add only to colors that actually appear on screen.
When Adding black, that's +0, so black parts of Additive Sprites should be transparent, because they don't add any color to the screen.

Happened

"Additive" Sprites always appeared "behind" Alpha Sprites, regardless of actual position.
"Additive" Sprites appear to be always "behind" the Renderer's ClearColor.
"Additive: Sprites appear especially odd when the Renderer's ClearColor is transparent, as they maintain their color as though it were opaque and still "in front" of them.

User Data

  • UserName:

Zero Engine Data

  • Revision: 406
  • ChangeSet: a461d49
  • Platform: Win32
  • Build Version Name: 1.1.0.406 a461d49 2017-10-02 Release Win32
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

No branches or pull requests

1 participant