tjbrunetto

Hi Esoteric Team,

Unity is about to allow all users working in 2D to have 2D specific lighting. The way they allow the lighting to work is by changing the material of the objects in Unity. The material in Spine I imagine is a bit different from this new material. Is there going to be support for a lighting system that works with Spine objects in Unity?

Tim
tjbrunetto
  • Сообщения: 90

Harald

Hi Tim,

Yes, we are planning to support the 2D Renderer and 2D Light pipeline introduced in Unity 2019.2 (although experimental).
There is now an issue ticket here:
[unity] Support 2D Lights of Unity 2019.2 · #1413

Note however that we have other important tickets to support recent Unity additions in line before this task.

We have just recently finished development of a Spine LWRP Shaders UPM package that now provides support for the previously existing Spine shaders Spine/Skeleton Lit and Spine/Sprite/Pixel Lit and Vertex Lit which rendered pink due to not being supported in LWRP.
There will be an official release blog post soon (however, the Spine 3.8 release comes first). It was tracked in this ticket if you are interested:
https://github.com/EsotericSoftware/spine-runtimes/issues/1255
Аватара пользователя
Harald

Harri
  • Сообщения: 1225

IndieDoroid

Harald писал(а):Hi Tim,

Yes, we are planning to support the 2D Renderer and 2D Light pipeline introduced in Unity 2019.2 (although experimental).
There is now an issue ticket here:
[unity] Support 2D Lights of Unity 2019.2 · #1413

Note however that we have other important tickets to support recent Unity additions in line before this task.

We have just recently finished development of a Spine LWRP Shaders UPM package that now provides support for the previously existing Spine shaders Spine/Skeleton Lit and Spine/Sprite/Pixel Lit and Vertex Lit which rendered pink due to not being supported in LWRP.
There will be an official release blog post soon (however, the Spine 3.8 release comes first). It was tracked in this ticket if you are interested:
https://github.com/EsotericSoftware/spine-runtimes/issues/1255
Oh wow this is AMAZING news! We can finally take advantage of LWRP in unity! Any news on supporting light map baking as well? :)
Аватара пользователя
IndieDoroid
  • Сообщения: 133

Harald

Glad you like it :).

Which use case of lightmap baking are you thinking of regarding the Spine shaders?
BTW: Light Probes are supported in the new LWRP shaders.
Аватара пользователя
Harald

Harri
  • Сообщения: 1225

IndieDoroid

Harald писал(а):Glad you like it :).

Which use case of lightmap baking are you thinking of regarding the Spine shaders?
BTW: Light Probes are supported in the new LWRP shaders.
In terms of use case, being able to bake the light and shadow information, overall, helps a ton for optimization and performance.

You mean Light Probes will work on the newest Spine/ Sprite/ Pixel Lit (LWRP) shaders, right? :o

Because I tried using Light Probes last year but it didn't work with the Spine Shaders. I was tempted to switch everything over to Unity's standard shader, but it made some Spine assets look awful. :zipper: :scared:
Аватара пользователя
IndieDoroid
  • Сообщения: 133

Harald

IndieDoroid писал(а):In terms of use case, being able to bake the light and shadow information, overall, helps a ton for optimization and performance.
The questions is why would you want to assign the Spine shader at static geometry? Lightmaps will not affect dynamic objects. Typically you will have light probes in place that save the lighting state at a point during time ob lightmap baking and then have your dynamic objects lit by those light probes.
IndieDoroid писал(а):You mean Light Probes will work on the newest Spine/ Sprite/ Pixel Lit (LWRP) shaders, right? :o
Yes, they are supported in the glorious new Lightweight Render Pipeline/Spine/Sprite shader. :)
IndieDoroid писал(а):Because I tried using Light Probes last year but it didn't work with the Spine Shaders. I was tempted to switch everything over to Unity's standard shader, but it made some Spine assets look awful. :zipper: :scared:
Sorry to hear that. Actually the previous Spine/Sprite shaders supported light probes by enabling the Spherical Harmonics parameter. Thanks for the hint, I will change this name on the 3.8-beta branch, as this is hiding the actual feature from those who know that light probes are stored as spherical harmonics.

Btw: even more features are enabled by enabling the Spherical Harmonics parameter, if you look at the hint-text:
"Enable to use spherical harmonics to calculate ambient light / light probes. In vertex-lit mode this will be approximated from scenes ambient trilight settings."
Аватара пользователя
Harald

Harri
  • Сообщения: 1225

IndieDoroid

Harald писал(а):The questions is why would you want to assign the Spine shader at static geometry? Lightmaps will not affect dynamic objects. Typically you will have light probes in place that save the lighting state at a point during time ob lightmap baking and then have your dynamic objects lit by those light probes.
I prefer the flattened look of the Spine Shader on my environmental assets. :)
Harald писал(а):Yes, they are supported in the glorious new Lightweight Render Pipeline/Spine/Sprite shader. :)
I can't wait to give these a try! But I wonder how painful it's going to be to convert all my scenes to LWRP ... I guess I'll find out lol
Harald писал(а):Sorry to hear that. Actually the previous Spine/Sprite shaders supported light probes by enabling the Spherical Harmonics parameter. Thanks for the hint, I will change this name on the 3.8-beta branch, as this is hiding the actual feature from those who know that light probes are stored as spherical harmonics.

Btw: even more features are enabled by enabling the Spherical Harmonics parameter, if you look at the hint-text:
"Enable to use spherical harmonics to calculate ambient light / light probes. In vertex-lit mode this will be approximated from scenes ambient trilight settings."
Oh wow! I didn't knot the full extent of Spherical Harmonics, was this something you guys added or was it always there in the original shader? :scared:

Will these LWRP shaders work with 2018.4 ? Or we should update to 2019.2?
Аватара пользователя
IndieDoroid
  • Сообщения: 133

Harald

IndieDoroid писал(а):I prefer the flattened look of the Spine Shader on my environmental assets. :)
Ok, I didn't expect that. :)
IndieDoroid писал(а):Oh wow! I didn't knot the full extent of Spherical Harmonics, was this something you guys added or was it always there in the original shader? :scared:
Spherical harmonics have been supported in the Spine/Sprite shaders for quite some time, it was not added too recently. BTW: I have renamed the paremeter and released a new unitypackage yesterday.
IndieDoroid писал(а):Will these LWRP shaders work with 2018.4 ? Or we should update to 2019.2?
We recommend using Unity 2019.1 when using Unity's LWRP packages in general.
Long story: The LWRP packages available for Unity 2018 were different and marked as preview packages, ending at version number 4.10. Using this preview package, we received shader compile errors which we did not get to resolve quickly, so out of the box this will not be compatible. We support versions of the com.unity.render-pipelines.lightweight package from 5.7.2 onward, which I fear cannot simply be copied over to an existing Unity 2018 project.
Аватара пользователя
Harald

Harri
  • Сообщения: 1225

IndieDoroid

Harald писал(а):Spherical harmonics have been supported in the Spine/Sprite shaders for quite some time, it was not added too recently. BTW: I have renamed the paremeter and released a new unitypackage yesterday.

We recommend using Unity 2019.1 when using Unity's LWRP packages in general.
Long story: The LWRP packages available for Unity 2018 were different and marked as preview packages, ending at version number 4.10. Using this preview package, we received shader compile errors which we did not get to resolve quickly, so out of the box this will not be compatible. We support versions of the com.unity.render-pipelines.lightweight package from 5.7.2 onward, which I fear cannot simply be copied over to an existing Unity 2018 project.
Ok got it! Thanks for the update. No big deal, I'll probably move over to 2019 at some point! 8)
Аватара пользователя
IndieDoroid
  • Сообщения: 133

Spiral Circus

I have a project in production and we've just opened a branch for upgrading to the 2D Rendering in URP. It's looking like that is ultimately we would like transition over to it in the main branch too, but we'd need to get our spine animations to work with the new renderer.

I noticed that all of my spine animations are properly lit by the 2D renderer if i use Unity's LWRP-2D-Sprite-Lit-Default shader except my main character who appears completely black. The only difference I can see that might be causing this is that my main character has multiple materials (3, one for each seperate atlas texture it uses).

Could anyone offer any insight into why this might be the case? I'd love to find a workaround that would let me keep progressing with the 2D lighting system while you folks work on proper compatible shaders.
Spiral Circus
  • Сообщения: 18

Harald

Thanks for sharing any workarounds in the meantime, very much appreciated!
We are sorry that it takes longer than we would have liked it to take to get to this task.
Аватара пользователя
Harald

Harri
  • Сообщения: 1225

Arnissan

With 2019.3 and its 2D tools stable release upon us it would be nice to see Spine support as well.
Arnissan
  • Сообщения: 61

foriero

Yes, guys, please, 2019.3 is a pretty essential update for devs, and we will transition there as soon as it is out. ( Given that Spine is ready )
Founder & CEO Foriero s.r.o.
https://studio.foriero.com
Аватара пользователя
foriero
  • Сообщения: 269

AgitAngst

Our company is really hopes for Spine and 2D tools friendship.
AgitAngst
  • Сообщения: 4

Jamez0r

Jumping on the bandwagon here - my team is starting on a project where we are spending the next two months making a vertical slice demo that we'll be using to try to get a publisher. Lighting is a huge part of the visuals, so I'm in a weird in-between state where I'm not sure if I can use the new 2D tools or not (I would REALLY like to).

I think I'll give it a try with the Unity LWRP-2D-Sprite-Lit-Default shader like @SpiralCircus was mentioning. None of my characters need to use more than one material. Worth giving it a try!
Аватара пользователя
Jamez0r
  • Сообщения: 107

Spiral Circus

Just to let people know, it wasn't the multiple materials that was causing my problem. Pretty sure it was unrelated to Spine and was just some quirk of my particular prefab setup. I rebuilt the prefab and it worked again.

I have since put together several shaders in shadergraph using the 2D master nodes (lit and unlit) with URP and they all work perfectly with spine animations. So don't feel like you shouldn't try the new unity systems because you're waiting on spine support. Unity's built-in URP + 2D renderer shaders work perfectly.
Spiral Circus
  • Сообщения: 18

Harald

Thanks for the confirmation of the importance of Unity 2019.3 support and the 2D Lighting tools, we are currently removing the last hurdles of general problems with Unity 2019.3 and can then finally implement support for the 2D lighting tools.
Аватара пользователя
Harald

Harri
  • Сообщения: 1225

IndieDoroid

Harald писал(а):Thanks for the confirmation of the importance of Unity 2019.3 support and the 2D Lighting tools, we are currently removing the last hurdles of general problems with Unity 2019.3 and can then finally implement support for the 2D lighting tools.
Whoohooooooo!! :)
Аватара пользователя
IndieDoroid
  • Сообщения: 133

Harald

We are glad to announce the first (for now experimental) upload of the Universal Render Pipeline extension package, including support for 2D Renderer (and thus 2D lights):
Spine Unity Download

Please note that you need to use the special newer spine-unity 3.8 runtime package as noted on the download page, as it contains some necessary modifications.


We will officially release this package next week if everything goes well.
Аватара пользователя
Harald

Harri
  • Сообщения: 1225

Spiral Circus

Thanks for all you hard work.
Spiral Circus
  • Сообщения: 18

Jamez0r

Harald писал(а):We are glad to announce the first (for now experimental) upload of the Universal Render Pipeline extension package, including support for 2D Renderer (and thus 2D lights):
Spine Unity Download

Please note that you need to use the special newer spine-unity 3.8 runtime package as noted on the download page, as it contains some necessary modifications.


We will officially release this package next week if everything goes well.
:nerd: :nerd: :nerd: :nerd: :nerd: :nerd: :nerd: :nerd:

Thank you!
Аватара пользователя
Jamez0r
  • Сообщения: 107

Harald

You're welcome, we wanted to get this done before the Holidays as a kind of Christmas present from Esoteric Software! :)

The packages are now listed as official packages on the download page. For now two 2D shaders are included in the UPM package:
  • Universal Render Pipeline/2D/Spine/Skeleton Lit, as a universal 2D Renderer variant of the Spine/Skeleton Lit shader, and
  • Universal Render Pipeline/2D/Spine/Sprite, as a universal 2D Renderer variant of the Spine/Sprite/Vertex Lit and Pixel Lit shaders.
More will follow.
Аватара пользователя
Harald

Harri
  • Сообщения: 1225

Jamez0r

Harald писал(а):You're welcome, we wanted to get this done before the Holidays as a kind of Christmas present from Spine! :)

The packages are now listed as official packages on the download page. For now two 2D shaders are included in the UPM package:
  • Universal Render Pipeline/2D/Spine/Skeleton Lit, as a universal 2D Renderer variant of the Spine/Skeleton Lit shader, and
  • Universal Render Pipeline/2D/Spine/Sprite, as a universal 2D Renderer variant of the Spine/Sprite/Vertex Lit and Pixel Lit shaders.
More will follow.
Alright!! 8)
Аватара пользователя
Jamez0r
  • Сообщения: 107

RemDust

Harald писал(а):We are glad to announce the first (for now experimental) upload of the Universal Render Pipeline extension package, including support for 2D Renderer (and thus 2D lights):
Spine Unity Download

Please note that you need to use the special newer spine-unity 3.8 runtime package as noted on the download page, as it contains some necessary modifications.


We will officially release this package next week if everything goes well.
Thank youuuu guys !
:party: :party: :party:
RemDust
  • Сообщения: 155

IndieDoroid

Harald писал(а):You're welcome, we wanted to get this done before the Holidays as a kind of Christmas present from Esoteric Software! :)

The packages are now listed as official packages on the download page. For now two 2D shaders are included in the UPM package:
  • Universal Render Pipeline/2D/Spine/Skeleton Lit, as a universal 2D Renderer variant of the Spine/Skeleton Lit shader, and
  • Universal Render Pipeline/2D/Spine/Sprite, as a universal 2D Renderer variant of the Spine/Sprite/Vertex Lit and Pixel Lit shaders.
More will follow.
:nerd: :nerd: :nerd: :nerd: :nerd: :nerd: :nerd: :nerd: :nerd: :nerd:
Аватара пользователя
IndieDoroid
  • Сообщения: 133


Вернуться в Unity