PDA

View Full Version : Tile alpha channel blending darker than expected



brainArid
April 23rd, 2020, 02:13
Hi, I'm a big fan of all the features that you all have managed to pack into FGU so far!

I was playing around with tiles that use transparency to blend between foreground and background for a more natural edge and found that the edges appeared to be darker than expected. An example:

34219

34220

I did a quick test to make sure that there wasn't something funny with the asset that I was using. I created a simple .png with an alpha gradient on the diagonal:

34221

And imported it into FGU as a tile, and found that again the alpha was blending darker than expected:

34223

pollux
April 23rd, 2020, 16:49
Not sure if the devs need this or not, but it would certainly be easier for me to judge the gradients if the backgrounds were the same in each case. Maybe export a white image from Gimp into FGU, and show the same gradient on top of the same white layer in FGU and Gimp?

brainArid
April 23rd, 2020, 19:33
Not sure if the devs need this or not, but it would certainly be easier for me to judge the gradients if the backgrounds were the same in each case. Maybe export a white image from Gimp into FGU, and show the same gradient on top of the same white layer in FGU and Gimp?

Thanks pollux. You're right that might be easier to understand. I added a couple different colors in this example:

34255

pollux
April 23rd, 2020, 19:52
That certainly makes it crystal clear. FGU almost looks like the gradient gets rounded to 3 regions with unnaturally sharp transitions between them. I have no further insight to add, but I feel certain that you've provided enough detail for a dev to investigate.

pindercarl
April 23rd, 2020, 21:04
Thanks pollux. You're right that might be easier to understand. I added a couple different colors in this example:

34255

The majority of the ruleset and theme assets were created using pre-multiplied alphas. To match FGC, the shaders in FGU are using pre-multiplied alphas. Technically, PNGs do not contain alpha channels. They contain a transparency channel. So, unlike other format types, we're not able to determine the intention of the user. I may switch the image layers over to using straight alphas and leave the UI elements to continue using pre-multiplied alphas.

Thanks for bringing this up.

brainArid
April 24th, 2020, 15:26
The majority of the ruleset and theme assets were created using pre-multiplied alphas. To match FGC, the shaders in FGU are using pre-multiplied alphas. Technically, PNGs do not contain alpha channels. They contain a transparency channel. So, unlike other format types, we're not able to determine the intention of the user. I may switch the image layers over to using straight alphas and leave the UI elements to continue using pre-multiplied alphas.

Thanks for bringing this up.

Thank you all for your awesome product :)