[SOLVED] How to completely color an image?

Questions about the LÖVE API, installing LÖVE and other support related questions go here.
Forum rules
Before you make a thread asking for help, read this.
Post Reply
slimefriend
Prole
Posts: 7
Joined: Thu Dec 01, 2016 2:45 am

[SOLVED] How to completely color an image?

Post by slimefriend »

Apologies if this has been explained before somewhere else, but is there a way in code to completely color something? (not just tint it). Like this:
whiteimg.png
whiteimg.png (789 Bytes) Viewed 1910 times
Last edited by slimefriend on Tue Feb 07, 2017 2:18 am, edited 1 time in total.
User avatar
Positive07
Party member
Posts: 1014
Joined: Sun Aug 12, 2012 4:34 pm
Location: Argentina

Re: How to completely color an image?

Post by Positive07 »

Check this really old thread, basically [wiki]BlendMode[/wiki]s wont help you, I actually got it to work with BlendModes by drawing the same thing MANY times but that is not nice at all, instead you should use shaders, and the shader that slime posted in that thread should get you started
for i, person in ipairs(everybody) do
[tab]if not person.obey then person:setObey(true) end
end
love.system.openURL(github.com/pablomayobre)
slimefriend
Prole
Posts: 7
Joined: Thu Dec 01, 2016 2:45 am

Re: How to completely color an image?

Post by slimefriend »

This totally worked! And was very easy! I should really look more into shaders. Anyway, thanks for your help!
Post Reply

Who is online

Users browsing this forum: Bing [Bot], Google [Bot] and 4 guests