Using JPG image files in my app

helpingtogrowhelpingtogrow Member, PRO Posts: 74

I have a lot of images in my app. I've been using PNG files but they are too large.
Can I use JPG images with 30% compression?
Thanks

Comments

  • famekraftsfamekrafts Member, BASIC Posts: 834

    You can use any format accepted by the engine.

    If you are using photoshop, use a plugin called superpng. It saves half the size of the png file. Just google it but works only with photoshop.

  • jamie_cjamie_c ImagineLabs.rocks Member, PRO Posts: 5,772

    I believe all images are converted into PNG files by the engine so I don't think it will make a difference.

  • adent42adent42 Key Master, Head Chef, Executive Chef, Member, PRO Posts: 3,159

    @helpingtogrow so there's a trick to it and it may require updating some xml.

    GameSalad imports everything as pngs in the app.

    When we generate the apps, we convert them to a proprietary less compressed format for faster loading.

    If app size matters more than loading time, here's what you do:

    • After you drag the images into your game, open the game project images/ directory (on Mac right click on the gameproj and click "Show Package Contents". Drag your jpgs into the project (make sure they have the same name as the pngs) and remove all the pngs.

    • Open the file assets.xml in the root the project and change all the .png file names to .jpg.

    This will let your project use jpgs. I believe we will also not convert jpg files to our loading optimized format on publishing (I haven't done this in a while, which is why I'm not 100% sure).

    You will lose the protection of our proprietary image format and your game will load slightly slower (mostly a problem for older devices), but you will save on download / package size.

    Even though I'm telling you all this, this is not an "officially" supported workflow, so you'll be on your own if anything goes wrong or the engine loads the game funny. Be sure to back stuff up.

Sign In or Register to comment.