Saving transparent PNGs

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
Tassilo
Prole
Posts: 14
Joined: Wed Jun 29, 2016 9:23 am
Contact:

Saving transparent PNGs

Post by Tassilo »

Dear Lovers.
I am looking for a way to save the results of my app Pixel-Me ( https://store.steampowered.com/app/875460/PixelMe/ ) as transparent PNGs. I currently do the following to save images:

Code: Select all

savedata = canvas:newImageData( 1, 1, 2+offsetx, 2+offsety, 64, 64 )
savedata:encode("png",filename)
From what I have seen, captureScreenshot has been changed in 11, having lost its savealpha boolean. Any way to embed alpha information to encode? Anything to keep in mind for the setup of the canvas? How about using a shader?

Thank you!
User avatar
zorg
Party member
Posts: 3441
Joined: Thu Dec 13, 2012 2:55 pm
Location: Absurdistan, Hungary
Contact:

Re: Saving transparent PNGs

Post by zorg »

did you try the new function out already? are you certain it has lost the ability to save alpha values, and not the ability to save -without- alpha information?
Me and my stuff :3True Neutral Aspirant. Why, yes, i do indeed enjoy sarcastically correcting others when they make the most blatant of spelling mistakes. No bullying or trolling the innocent tho.
Post Reply

Who is online

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