Hi,
I tried to find something about it in the forum but i couldn't find anything.
i have an object which has a glowing texture which fades the alpha from 0% to 100%.
the fading texture is above an another texture. And when the fading texture is at halve of the alpha it seems to getting dark in unity but not in Spine.
I tried tif vs jpg because i read something about Pre-Multiplied Alpha or something but
that didn't work ether.
Page 1 of 1
nimao
You do not have the required permissions to view the files attached to this post.
8 years ago
- nimao
- Posts: 6
Søren
I'll get Mitch on the batmobile, he should be able to help out 

8 years ago
-
Søren - Posts: 2453
Pharan
Mitch, you're up.
Just for diagnosis' sake, can you show us what shader you're using for the Material? And also the png's import settings in Unity?
I'm not sure if Spine Editor itself uses PMA. But if it does, and you're using PMA too with the
There's likely no reason to use .tif though.
Just for diagnosis' sake, can you show us what shader you're using for the Material? And also the png's import settings in Unity?
I'm not sure if Spine Editor itself uses PMA. But if it does, and you're using PMA too with the
Spine/Skeleton
shader in Spine-Unity, theoretically, they should look the same.There's likely no reason to use .tif though.
Spine-Unity Docs Repo, and check out the Unofficial Spine Users Tumblr.
8 years ago
-
Pharan - Posts: 5366
Mitch
In my experience you shouldn't animate the alpha of a Glow texture. You should use a black background and put the glow on top of it and set it to Additive in the Spine slot* properties. When you want to glow/unglow it, animate the Color from White to Black rather than the Alpha. This plays nicer with additive blending. I have no idea what Spine is doing to make it look "Right".
---

The fireball has no alpha in its texture what so ever; black background with stuff painted on top.

This is what the exported atlas' alpha looks like for the mage.
Comparison with a glowyball instead

Glowyball source

And my regular workflow for making glowballs.
http://www.xdtech.net/spine/Greenball.psd
---

The fireball has no alpha in its texture what so ever; black background with stuff painted on top.

This is what the exported atlas' alpha looks like for the mage.
Comparison with a glowyball instead

Glowyball source

And my regular workflow for making glowballs.
http://www.xdtech.net/spine/Greenball.psd
8 years ago
-
Mitch - Posts: 978
Nate
Spine just uses PMA and proper blending. 
Additive will often look nice, but it depends on the background. The glow will look great on a black background, but you won't be able to see much on a brighter background.
Replace your glow ball image with a huge cow image and see if it fades like you expect.


Additive will often look nice, but it depends on the background. The glow will look great on a black background, but you won't be able to see much on a brighter background.
Replace your glow ball image with a huge cow image and see if it fades like you expect.

8 years ago
-
Nate - Posts: 12208
Søren
Huge cow image solves everything 

8 years ago
-
Søren - Posts: 2453
Mitch

Let's be brovines.
8 years ago
-
Mitch - Posts: 978
nimao
thaaanks for all the help!
we use spine with tk2d in unity could that be the problem?
i tried out the additive solution but in unity i can add only one shader so the glow doesn't show up or the whole thing glows. Or is there a way to add two shader? or is it because we use tk2d?
import settings and material/shader:
we use spine with tk2d in unity could that be the problem?
i tried out the additive solution but in unity i can add only one shader so the glow doesn't show up or the whole thing glows. Or is there a way to add two shader? or is it because we use tk2d?
import settings and material/shader:
textures.png
You do not have the required permissions to view the files attached to this post.
8 years ago
- nimao
- Posts: 6
Mitch
Bah, no one says "TK2D" until after I post lol.
Anyway...
Make sure you have TK2D Premultiply Alpha checked

And you can use the Spine Skeleton shader. The TK2D shaders don't use the same methods as the Spine editor so if the goal is to keep everything looking the same, you should use the provided shaders

PS:
I just updated the TK2D runtimes to be more in-line with the Spine-Unity ones.
They're available here and on Git.
http://www.esotericsoftware.com/files/r ... itypackage
There are a couple bugs, make sure when you create a SkeletonDataAsset that you assign the tk2dSpriteCollectionData before the JSON or it will have a bad day.
Anyway...
Make sure you have TK2D Premultiply Alpha checked

And you can use the Spine Skeleton shader. The TK2D shaders don't use the same methods as the Spine editor so if the goal is to keep everything looking the same, you should use the provided shaders


PS:
I just updated the TK2D runtimes to be more in-line with the Spine-Unity ones.
They're available here and on Git.
http://www.esotericsoftware.com/files/r ... itypackage
There are a couple bugs, make sure when you create a SkeletonDataAsset that you assign the tk2dSpriteCollectionData before the JSON or it will have a bad day.
8 years ago
-
Mitch - Posts: 978
nimao
Awesoooome! it worked! thanksss!
8 years ago
- nimao
- Posts: 6
Mitch
nimao wrote:Awesoooome! it worked! thanksss!

8 years ago
-
Mitch - Posts: 978
Mark topic unread
• Page 1 of 1
Return to Editor
- All times are UTC