Tasharen Entertainment Forum

Support => NGUI 3 Support => Topic started by: Magic Frame on December 02, 2014, 05:49:56 AM

Title: Change pixel color of UISprite
Post by: Magic Frame on December 02, 2014, 05:49:56 AM
Hi all,

I have a Sprite, this Sprite is white and black, is possible access to color pixel? and change black color to green color for example?

best regards
Title: Re: Change pixel color of UISprite
Post by: ArenMook on December 02, 2014, 12:26:56 PM
Only if you write some custom shader for that. NGUI lets you tint the whole sprite, not select pixels. In general it's much easier to create a custom sprite made up of different sprites. For example if you have a sprite of a human with pants and shirt, you can instead split it up into several ones -- a sprite for human's skin, another sprite for human's shirt, and one more for human's pants. You can then tint them individually.