Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

AppGameKit Chat / Best way for transparent JPEG

FPSC Reloaded TGC Backer
Years of Service
User Offline
Joined: 17th Apr 2007
Location: Berlin
Posted: 8th Feb 2019 09:50
What could be the best way to use transparent JPEGs?
Why JPEGs? If you have large images, photographies and such, PNG files need a long time to load and need much space on the disk. So JPEGs are the way to go. But! They have no transparency layer.
The idea is, to combine the benefits of both in some way.

First I tried to create a program that reads the transparency data out of an 24+8 Bit PNG and creates a JPEG and a PNG out of that. Maybe I don't need the memblocks Pixel by Pixel, maybe I could use it also with some Mask-Commands, don't know.
It is a prototype.

So the result has to be more tiny in space and better looking in visual terms than what you could get out of the PNG optimised directly from tinypng or such programs. And in some way, this does.

So the question is: Is that the best way? Could it be in some way faster? Or Would it better, to slice big pictures in smaller parts, create more sprites and have only transparency on the edges? So maybe we could have a JPEG in the middle, but at the corner, there are some PNGs with transparency saved in it or so.

And how much would the performance suffer from this? Maybe there is a program, that does, what I tried to do. Maybe it does it much better

For what would that be a use case? For animations with real people, or for unique visuals not only created out of tiles.


Login to view attachments
Years of Service
User Offline
Joined: 8th Oct 2017
Posted: 8th Feb 2019 09:59
Excellent work here - ill take a good look a little later after work.

Login to post a reply

Server time is: 2019-02-20 08:29:28
Your offset time is: 2019-02-20 08:29:28