Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: aldafor on November 20, 2012, 06:16:52 AM

Title: NGUI camera render to texture
Post by: aldafor on November 20, 2012, 06:16:52 AM
Hi!

I'm trying to make a titles camera with NGUI for one credits scene, so I can use UILabels and tweens for fading and so on. Because the titles should appear over a plane with a custom curve form, I'm experiencing several problems:

- I can't use a UITexture, because It will be drawn on a sprite plane, which I'm not interested on.
- I can't use use the normal unity RenderTexture and draw the camera render target over a gameObject renderer, because It will draw the entire atlas used by font.

I could just go for use unity TextMesh and a normal camera, and set a render texture to use on a game object renderer, but I would like to use as less different techniques as possible, so scene remains more homogeneous just with NGUI (And I don't have to mess around too with different font sources). Any idea for make an NGUI approach?

Make a custom UITexture that use a custom mesh is the first solution that pops in my mind, but I don't know If I'm missing something on the library that makes the trick (still just a few days playing around with it...)
Title: Re: NGUI camera render to texture
Post by: aldafor on November 20, 2012, 09:19:35 AM
To answer miself, and hit me because my stupidity. One college suggest me to try removing the "ColorMask RGB" on all NGUI shaders and it works (Thanks Max!). And actually, getting deep in the forum I manage to find this answer: http://www.tasharen.com/forum/index.php?topic=1944.msg9709#msg9709

Any future implications I should consider because of this change?
Title: Re: NGUI camera render to texture
Post by: ArenMook on November 20, 2012, 03:48:39 PM
No, it's fine.
Title: Re: NGUI camera render to texture
Post by: aldafor on November 23, 2012, 11:03:16 AM
Week has been that full that I've totally forget my good manners... thanks man!