- Home /
Stenciling on Unity iPhone
Greetings all!
Once again I am stumped on how to translate a technique using Unity iPhone. Basically I have a game where the user will swipe the screen and the idea is that where they swipe will 'reveal' the texture underneath. Think of it like a scratch ticket for the lotto or a flash light.
Normally I would make something like this by accessing the stencil buffer, or writing a specific alpha shader. Does anyone have advice on an equivalent approach for the iphone? Is there a way to draw a brush into an alpha texture and use that as a stencil mask ?
Answer by TowerOfBricks · May 16, 2011 at 07:51 PM
Use a drawing script (unifycommunity wiki) to draw on a Texture2D. Then use that on a plane and place it in front of the camera. A bit dirty, but it might work.
Your answer
Follow this Question
Related Questions
shader for tree leaves + lightmap 1 Answer
Stencil buffer and transparency 0 Answers
Perfomance disparity between 3G and iTouch (iPhone 4) 1 Answer
Painting stencil on a surface. 6 Answers
plz let me know how to use sprite mask? 0 Answers