PNG is slow?

0 favourites
  • 7 posts
From the Asset Store
Buildings - Isometric view - PNG transparent - multi styles, multi fonctions buildings
  • I read an article about PNG and RLE TARGA. What do you think? I'm not too knowledged in digital image formats, but figured it was an interesting topic.

    astronautz.com/wordpress/why-pngs-are-a-poor-choice-for-games

  • I believe that only holds true for loading textures into memory, which means that only preloading time is affected.

  • Oh, I see. Plus, I was reading this. It would seem Scirra had already worked on the matter of loading times considering images.

  • DiGiCORE : in fact, what they said isn't very relevant to HTML5. They are working with native binaries. When going native, XCode on iOS is using a fileformat that is indeed having the .png extension, but in fact it's not a true PNG (for efficiency reason, Apple swap internally the channel order of their file, to let OpenGL ES, the backend displaying the images and doing manipulations on them, go faster).

    Because of that, if you load true PNG files in an XCode project, without "optimzing" them the Apple way (swapping the channels), the app is going to do it at load time. Meaning you'll be slower than any other fileformat.

    As the original author is saying, when you optimize them, and make a pass of PNGCrush or a similar tool on them, they are as fast (or close) to other file format.

    Finally, browser (HTML5) don't support natively TGA. You can only go with BMP/JPG/PNG(and XBM/PBM but don't deal with that, it's old, buggy and unuseful).

    If you want to load another file format, you need to create a wrapper to deal with that format in JS, and it's going to be slower that the eventual benefit of a "faster" file format...

  • Try Construct 3

    Develop games in your browser. Powerful, performant & highly capable.

    Try Now Construct 3 users don't see these ads
  • Good discussion, and great insight

    All I know is TGA files are large and contain much more information then required by web browsers/pages/apps.

    I only use it for prints because of its loss-less quality.

  • Thanks Pode. Very interesting.

  • If you measure the time from pressing 'download' to when the game starts up, PNG is still probably faster since it will reduce the download size a lot more!

Jump to:
Active Users
There are 1 visitors browsing this topic (0 users and 1 guests)