Hello Everyone!
I'm looking to change the image color to give it a Yellow accent or red accent.. i can easily implement an image and replace the background but i want to do so with an Animation. like slowly transform the colors to yellow and red..
What's the shader i need? and can use tween to slowly change the colors of the image? Thank you!
Shader to colorize an image to red and yellow
Forum rules
Before you make a thread asking for help, read this.
Before you make a thread asking for help, read this.
Re: Shader to colorize an image to red and yellow
Do you mean you want to change the whole image to slowly become yellow, or to tint the whole thing yellow? Because you can do both without a shader; the first by drawing a yellow rectangle over the image that slowly fills up with Alpha and the second by using graphics.setColor.
Re: Shader to colorize an image to red and yellow
I want to make the image displayed Yellow. not making the whole background yellow... How can i tween( using tween library ) the values? Thanks
Re: Shader to colorize an image to red and yellow
You don't need a shader for this. Just set the color to yellow before drawing it:
Code: Select all
love.graphics.setColor(255, 255, 0)
love.graphics.draw(myImage, 100, 100)
-- don't forget to set the color back to white or else all draw operations after it will appear yellow
love.graphics.setColor(255, 255, 255)
macOS 10.14 Mojave | LÖVE 11.2
Who is online
Users browsing this forum: Ahrefs [Bot] and 2 guests