LWRP and alpha

Node-based Shader Editor

LWRP and alpha

Postby JavierDuran » Wed Jan 02, 2019 11:48 am

Hi,

I'm using ASE with the LWRP and I'm having some issues. The thing is that I can't use an alpha gradient. All I get is a dark grey color where the alpha should be transparent.
Image

I've tried some blend modes, shader types, etc. but I can't make it work properly. Am I doing something wrong?

Thank you!
JavierDuran
 
Posts: 5
Joined: Wed Jan 02, 2019 11:25 am

Re: LWRP and alpha

Postby Amplify_Borba » Wed Jan 02, 2019 2:52 pm

Hello, thank you for getting in touch and for your support!

Please refer to the example below:

Image

Using the default LightWeight PBR template as a starting point, I've changed both RenderType and Queue within the Subshader Tags section to Transparent, and the Blend Mode to Alpha Blend.

Please let me know if this helps!
Customer Relations at Amplify Creations
Learn more about our offering: Amplify Creations Products
Amplify Shader Editor won the Asset Store Best Tool Award - Thank you for your support!
User avatar
Amplify_Borba
 
Posts: 1239
Joined: Mon Jul 24, 2017 9:50 am

Re: LWRP and alpha

Postby JavierDuran » Wed Jan 02, 2019 4:02 pm

Hummm it works better, but it's doing something wrong when applied to a particle system. The alpha is blending well with other geometry, but not with their own particles.
Image

It seems to be something with the sorting, but I'm not sure if it's an ASE or Unity problem. In standard render mode (neither lightweight nor HD) there's no problem with this but when using the legacy particle alpha blend in LWRP a pink square is rendered.
JavierDuran
 
Posts: 5
Joined: Wed Jan 02, 2019 11:25 am

Re: LWRP and alpha

Postby Amplify_Borba » Wed Jan 02, 2019 4:42 pm

If you need to author shaders for use with Unity's Particle System, you'll need to set the Shader Type to 'Particles Alpha Blended' so that you use our custom template that was specifically developed for this purpose.

Image

It should work with both LW and HD SRPs, just be sure that you use the Template Parameter node in order to access template specific properties / global variables such as the Particle Texture ( _MainTex ), Tint Color ( _TintColor ) and Soft Particles Factor ( _InvFade ).
Customer Relations at Amplify Creations
Learn more about our offering: Amplify Creations Products
Amplify Shader Editor won the Asset Store Best Tool Award - Thank you for your support!
User avatar
Amplify_Borba
 
Posts: 1239
Joined: Mon Jul 24, 2017 9:50 am

Re: LWRP and alpha

Postby JavierDuran » Thu Jan 03, 2019 7:55 am

This is what I get when using the legacy particle alpha blend:
Image

I've updated all materials to LWRP but it still rendering that pink square :S
JavierDuran
 
Posts: 5
Joined: Wed Jan 02, 2019 11:25 am

Re: LWRP and alpha

Postby Amplify_Borba » Thu Jan 03, 2019 10:11 am

I've set up a simple particle shader and tested it on the latest ASE ( 1.6.1r3 ) and LWRP ( 4.6.0 ) versions and its working as expected in Unity 2018.3.0f2. I would assume it to also be working on earlier versions with the legacy LWRP ( 3.0.0 ), could you please share which versions you're currently on?

I've used the following simple setup with default Output Node parameters, which you may also use as a reference:

Image
Customer Relations at Amplify Creations
Learn more about our offering: Amplify Creations Products
Amplify Shader Editor won the Asset Store Best Tool Award - Thank you for your support!
User avatar
Amplify_Borba
 
Posts: 1239
Joined: Mon Jul 24, 2017 9:50 am

Re: LWRP and alpha

Postby JavierDuran » Wed Jan 09, 2019 4:33 pm

Hi,

For some magical reason, it's working well... but now I'm having a new issue: the light is broken when using LRWP PBR and I don't know why. The last week it was working as expected D:

I was able to reproduce it in a new project with just a simple shader and one game object.
Image
Image

If I switch to a standard shader it works, but when using LWRP I get this strange shadow :(
JavierDuran
 
Posts: 5
Joined: Wed Jan 02, 2019 11:25 am

Re: LWRP and alpha

Postby Amplify_Borba » Thu Jan 10, 2019 2:15 pm

That is definitely strange, I've just tested a simple scene with a Lightweight PBR shader at the default settings on a new project, and can't seem to replicate the issue:

Image

This was on Unity 2018.3.0f2 with ASE v1.6.1r4 and LW RP v4.6.0.

Could you share a sample project with the issue present to [email protected] for us to debug on our side?
Customer Relations at Amplify Creations
Learn more about our offering: Amplify Creations Products
Amplify Shader Editor won the Asset Store Best Tool Award - Thank you for your support!
User avatar
Amplify_Borba
 
Posts: 1239
Joined: Mon Jul 24, 2017 9:50 am

Re: LWRP and alpha

Postby JavierDuran » Fri Jan 11, 2019 7:29 am

Hi,

I'm sorry, I'm so bussy that I'm writing my posts too fast and skipping information.

This issue is only happening on Android builds, testing on a Samsung Galaxy S6 and a Samsung Galaxy S8. I'll send you an email with a simple scene right now. I'm using Unity 2018.3.0f2 and Amplify Shader Editor 1.6.1 (the last from the Asset Store). The LWRP is the last from the package manager too.

Thank you!
JavierDuran
 
Posts: 5
Joined: Wed Jan 02, 2019 11:25 am


Return to Amplify Shader Editor

Who is online

Users browsing this forum: No registered users and 0 guests