Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: dt1000 on April 09, 2017, 02:36:04 PM

Title: Having an issue with Render Textures... please help!
Post by: dt1000 on April 09, 2017, 02:36:04 PM
Hi there!
I am having trouble getting a Render Texture from a camera to display properly in nGUI.
I am using this fur shader to render fuzzy dice:
https://forum.unity3d.com/threads/furfx-mobile-physics-based-fur-shaders.202417/ (https://forum.unity3d.com/threads/furfx-mobile-physics-based-fur-shaders.202417/)

In-game they look great!
(http://i67.tinypic.com/14aegwy.png)

However, I want to show them in the GUI as well but there seems to be an issue with the transparency...
(http://i64.tinypic.com/28uib2s.png)

The die on the left looks perfect, but the fuzzy die on the right is ghostly.

I have a camera, which is generating a Render Texture, which is then applied to a UITexture object.
I wrote a shader which just halves the alpha value and it worked fine... until I put the Texture into a panel (for scrolling) and the ghosting returned.

Any idea what I might be doing wrong?

Here are the camera settings:
(http://i63.tinypic.com/2v7tfnb.png)

And here are the Render Texture settings...
(http://i67.tinypic.com/vdfor9.png)

Thanks in advance for your help!

Cheers,
Dan
Title: Re: Having an issue with Render Textures... please help!
Post by: dt1000 on April 09, 2017, 10:32:58 PM
Fixed it!

Just changed the blend mode on the specific fur shader I was using, as per this forum post:
http://answers.unity3d.com/questions/525188/transparent-shader-final-alpha-value-wrong.html (http://answers.unity3d.com/questions/525188/transparent-shader-final-alpha-value-wrong.html)
:D