• Help with SetMaterial
    4 replies, posted
Hello there! I'm trying to made original color of icon16 became white color. [LUA] surface.SetMaterial( Material("icon16/money_dollar.png") ) surface.SetDrawColor(255,255,255,255) [/LUA] How i can get white color? Please any suggestions! Thanks
using surface.SetDrawColor() in this context doesn't give you the results you want. you'll probably have to do some sort of post processing.
A note, don't use Material() in Paint or whatever. Store its output as a variable outside of your Paint and just use the variable instead of calling Material() every time. If the player doesn't have the texture on their client, they'll be calling and trying to precache the Material constantly, therefore causing massive lag.
[QUOTE=cynaraos;49145840]using surface.SetDrawColor() in this context doesn't give you the results you want. you'll probably have to do some sort of post processing.[/QUOTE] Seems post processing not a right way, but could you show any demo?
What you want is not really possible without editing the image in a image editor program and basically creating a new texture.
Sorry, you need to Log In to post a reply to this thread.