PNG size question

Hi all,

I have 1024x768 PNG images for the backgrounds in my game and the sizes vary from around 800kb to around 1800kb.

I was wondering what is the most likely factor in making one file so much bigger than another?

In their psd state they seem to have very little difference in the amount of layers.

It’s not a bug – it’s an undocumented feature

Comments

  • Fal01Fal01 Member Posts: 460
    Cheers, I was hoping it would be something I could adjust but I can't really adjust the colours. :-<

    It’s not a bug – it’s an undocumented feature

  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    edited October 2013

    Hi @Fal01, as @jonmulcahy says, more colours means more size, in other words, by using Save for Web & Devices in Photoshop, saving as PNG24 will be about 3 times the file size of a PNG8... so you say you can't adjust the colours, which is fair enough, but some of your images might use 256 colours or less and so can be saved as PNG8 without any loss of quality. Note that the file sizes, whether PNG8 or PNG24 will still be a bit more than the file size shown from the file in your folder/desktop wherever; this is not too much more though and nothing to worry about, in the main.

    Another thing to point out, there are some PNG optimisation programs about, where you can reduce the size of PNGs even further, (TinyPNG & ImageAlpha come to mind) but beware that sometimes GSC will make this the size before it was optimised anyway.... (so you need to replace the file in the Images folder in the package contents of the GSC file to get the benefit...)

    So mainly I'd stick to saving PNGs in 8bit mode where possible, as I previously described; that alone will save up to two thirds of the file size.

    A tip for you, btw, you can drag a psd file - with multiple layers or not - straight into GSC and it automatically will convert it to a PNG for you but the file size will be something like 10 times larger than even a PNG24 (I don't know why) so avoid doing this ever...

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • JSprojectJSproject Member Posts: 730
    @Fal01, Looks like you're targeting IPAD based on the 1024x768 resolution for your backgrounds. If that is the case then just a friendly heads up here... you need to make those backgrounds 2048x1536 instead (and check Resolution Independence in GS) since Retina graphics is a requirement from Apple.
  • Fal01Fal01 Member Posts: 460
    Cheers @gyroscope, @JSproject
    It turns out that the images which are predominantly green are the ones with larger file sizes, which is a bummer since my game is based in the forest! :(|)

    It’s not a bug – it’s an undocumented feature

  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    edited October 2013

    So if they're predominantly green, it sounds like they are "ripe" to save as PNG8, as previously described, reducing the file size by two thirds!!

    But remember, as @JSproject mentioned, you have to have your image size as 2048x1536 (for full backgrounds, or twice the size for smaller sizes) for iPad apps to take into account retina graphics.

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • darrelfdarrelf Member Posts: 243
    I have many background images in my game and so use jpegs to save loads of space.
    It does mean importing, then opening package contents and changing the text file (very carefully) and replacing the png files with jpegs but it can be so worth it...
  • Fal01Fal01 Member Posts: 460
    Yeah I thought that but apparently they have been accepting submissions with non retina images re this discussion-http://forums.gamesalad.com/discussion/60772/what-s-the-largest-a-gs-project-can-be-and-have-a-published-app-store-size-under-the-100-mb-cap#latest

    It’s not a bug – it’s an undocumented feature

  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    edited October 2013
    Yeah I thought that but apparently they have been accepting submissions with non retina images re this discussion-http://forums.gamesalad.com/discussion/60772/what-s-the-largest-a-gs-project-can-be-and-have-a-published-app-store-size-under-the-100-mb-cap#latest
    Ah right, interesting, I didn't know that, I thought they insisted on retina display size images... although I reckon it won't be too long before that happens... ;-)

    Good point from @darrelf about saving as jpeg to save a lot of file space although to point out, for those who don't know, this is only useful if your image doesn't need any transparency (which, OK, most background images don't!) but worth pointing out...

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • Fal01Fal01 Member Posts: 460
    Cheers @darrelf,

    Great tip, i'll try that!

    It’s not a bug – it’s an undocumented feature

  • Fal01Fal01 Member Posts: 460
    @gyroscope,
    Hopefully after i've released my game. [-O<

    It’s not a bug – it’s an undocumented feature

  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922
    @Fal01 please don't spread misinformation. Although a few people might have gotten past the reviewers Apple rules do require all Apps to support Retina, this is the formal policy. Try and hope to get past the reviewers at your own risk. If you want to gamble with doing lots of work and getting rejected that's fine but don't say Apple is accepting apps without retnia as that is not true.
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    edited October 2013
    @gyroscope,
    Hopefully after i've released my game. [-O<
    :-bd I'll hope for you too!! (I'm sure you'll be OK... fingers crossed...) B-)

    Edit: just read @FryingBaconStudios comment... so extra good luck...

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • Fal01Fal01 Member Posts: 460
    @FryingBaconStudios, Cheers.

    Disclaimer: Fal01 will not take any responsibility for any loss of earnings broken limbs or lack of libido experienced as a result of reading or acting on the (mis)information contained in this or any other thread featuring the afore mentioned.
    Amen!

    It’s not a bug – it’s an undocumented feature

  • jonmulcahyjonmulcahy Member, Sous Chef Posts: 10,408
    Download a png conpressor like imageoptium. It'll really reduce the file size
  • gyroscopegyroscope I am here.Member, Sous Chef, PRO Posts: 6,598
    edited October 2013
    Download a png conpressor like imageoptium. It'll really reduce the file size

    ...
    Another thing to point out, there are some PNG optimisation programs about, where you can reduce the size of PNGs even further, (TinyPNG & ImageAlpha come to mind) but beware that sometimes GSC will make this the size before it was optimised anyway.... (so you need to replace the file in the Images folder in the package contents of the GSC file to get the benefit...)
    :P ;-)

    ""You are in a maze of twisty passages, all alike." - Zork        temp domain http://spidergriffin.wix.com/alphaghostapps

  • Fal01Fal01 Member Posts: 460
    Cheers @FryingBaconStudios,
    Dragging the entire images folder into image optim is a far more efficient method than what i've been doing for the last 3 hours. :(|)

    It’s not a bug – it’s an undocumented feature

Sign In or Register to comment.