Which is better for performance / memory: GS alpha or baked alpha?

vikingviking Member, PRO Posts: 322

I have a series of patterns that I would like to use in my game and they are all going to be very faint in the background. So I have two options: 1) Reduce the alpha value of the actor in the background to 0.2 so that the pattern blends into the color of the scene. 2) Reduce the opacity value of the image to 20% from 100% in Photoshop before I save the file and import it into GameSalad and then keep the actor alpha at 1.0. Any idea which option will take up less memory and be faster for GS to render?

Comments

  • fZoleefZolee Member, PRO Posts: 34

    Just did a quick test in PS, seems like if I reduce the opacity to 20%, it doesn't effect the file size (so it shouldn't be faster to load). I would keep the alpha in PS 100%, so it gives you the flexibility to change it later up and down in GS however you like.
    But I can be wrong, maybe GS experts can correct/confirm this. :#

  • The_Gamesalad_GuruThe_Gamesalad_Guru Member Posts: 9,922

    @viking said:
    I have a series of patterns that I would like to use in my game and they are all going to be very faint in the background. So I have two options: 1) Reduce the alpha value of the actor in the background to 0.2 so that the pattern blends into the color of the scene. 2) Reduce the opacity value of the image to 20% from 100% in Photoshop before I save the file and import it into GameSalad and then keep the actor alpha at 1.0. Any idea which option will take up less memory and be faster for GS to render?

    Things like this don't matter as to performance. The main way to gain good performance is having tight and solid logic. A games performance is based on it's scan rate or fps. This is how fast the code is scanned and how organized your code is to firing in proper order. Things like image size and sounds, in general, have little effect on performance, unless they are uniquely huge. Focus on how good your code is.

  • SocksSocks London, UK.Member Posts: 12,822

    @viking said:
    I have a series of patterns that I would like to use in my game and they are all going to be very faint in the background. So I have two options: 1) Reduce the alpha value of the actor in the background to 0.2 so that the pattern blends into the color of the scene. 2) Reduce the opacity value of the image to 20% from 100% in Photoshop before I save the file and import it into GameSalad and then keep the actor alpha at 1.0. Any idea which option will take up less memory and be faster for GS to render?

    I can't imagine any reason why one would be a better option than the other when it comes to memory use or processor / graphics strain.

  • vikingviking Member, PRO Posts: 322

    Ok then. Thanks for the input.

  • SocksSocks London, UK.Member Posts: 12,822

    @viking said:
    Ok then. Thanks for the input.

    Why not test it, spawn a grid of 500 small actors, set them to rotate or move up and down (or whatever), pass this test file over to your phone or tablet and see whether the frame rate is effected by either option.

  • GeorgeGSGeorgeGS Member, PRO Posts: 478

    Off the top of my head I believe changing the alpha of an actor means it is rendered in a slightly different way, but I expect the performance is the same. It doesn't make any difference for memory or loading.

  • jay2dxjay2dx Member Posts: 611
    edited April 2016

    The only time I do this is if I want part of the actor to be slightly transparent as you can not do that in GS of cause, usually use it for buttons etc,

Sign In or Register to comment.