Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: Argiris on April 21, 2017, 09:58:25 AM

Title: NGUI object geometry
Post by: Argiris on April 21, 2017, 09:58:25 AM
Hello.

We'd like to use the Gradient Shader Pack plugin (https://www.assetstore.unity3d.com/en/#!/content/9403), but the author doesn't know if it will be compatible with NGUI.

He said the following (https://forum.unity3d.com/threads/new-gradient-shader-pack-realtime-animatable-gradient-shaders.186449/page-4#post-3022616).

Any help would be appreciated.

Thanks!
Argiris
Title: Re: NGUI object geometry
Post by: ArenMook on April 22, 2017, 11:32:15 AM
NGUI creates quads and you can use any shader with them. For example if you create a UITexture, then give it a material, it will display that material as-is. You can use any unlit shader (and even lit ones if you enable normals on the panel responsible for the widget). Furthermore, you can use UV2 to feed extra data to your shader, which is useful if you are using a sprite that draws a part of an atlas but still want 0-1 range coordinates for the left/right and bottom/top of your widget's bounds to sample a secondary texture.

So in short -- I see no reason why it won't work.
Title: Re: NGUI object geometry
Post by: Argiris on April 23, 2017, 06:38:12 AM
Thank you, Michael! :)