What uses the most system memory! please advise :)

jay2dxjay2dx Member Posts: 611

Hi GS community just a quick question here, I searched the furum but couldn't find anything usfull, something ive been wondering while making my platformer game.

Game type Platformer "not sure this matters" but you get an idea!

tileset 32pixels and 64pixels ect..

So my question is what uses the most system memory?:

instances of actors . ie "a platform floor actor as a 64x64actor" but using 32 of these to make up a 2048pixel floor surface.

or

one actor with a tiled texture ie "floor actor as a 64x2048 actor"

Im just looking for best practice for tile sets in platformers as I use a rule to auto snap everything to the correct pixel orientation and it works best with sized actors, well its faster for placement as the rule can be modified for any size.

but yes im wondering about best practice for conserving GS memory, and I know using lots of 64x64 actors will add up!

any thoughts would be great.

Comments

  • jay2dxjay2dx Member Posts: 611

    anyone?

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

    @jay2dx said:
    anyone?

    The smaller image uses less memory.

  • BlackCloakGSBlackCloakGS Member, PRO Posts: 2,250
    edited April 2015

    Image and sounds take the most memory. Music is streamed from disk.

    For images here is a quick equation for how much memory a image will take in GameSalad 0.13

    ((((widthInPixels X hightInPixels ) X 32) /8 ) / 1024 ) / 1024 = MB in memory

  • jay2dxjay2dx Member Posts: 611

    cool thanks for the reply @BlackCloakGS i guess a combination of my two methods for images and displaying actors will be best practice!

    I've spent the night making the same level in both ways, there doesn't seem much difference to frame rate tbh, so i think ill go with a tile set for standard actors and bespoke stuff just normal images etc with collision actors..

    if anyone else has any insight feel free to add to this.

  • jay2dxjay2dx Member Posts: 611
    edited April 2015

    @Socks said:

    so 10 smaller images/actor "instances" tiled together will use less memory than an actor of the same combined size! i see, thanks..

    so does does this mean an actor say 64x1024 with a tiled texture at 64x64 use the same/roughly memory as if its an 64x64 actor?

    and thanks for the reply mate

  • SocksSocks London, UK.Member Posts: 12,822
    edited April 2015

    @jay2dx said:
    so does does this mean an actor say 64x1024 with a tiled texture at 64x64 use the same/roughly memory as if its an 64x64 actor?

    Actors don't use up memory beyond the tiny amount of code involved, if you create a 64x64 pixel actor, and then increase its size to 128,000 x 128,000 pixels the memory use will not increase.

    If we get rid of all terms like 'picture', 'texture', 'sprite', 'actor', 'image' (etc etc) that often get used interchangeably, then the question could be:

    "Does a 64x64 pixel tiled image use the same amount of memory as a 64x64 pixel image"

    Which could be further reduced to: "does tiling an image increase memory usage", and the answer to that is 'no’ (beyond the tiny amount of code involved).

  • jay2dxjay2dx Member Posts: 611

    Agree @socks turned out GS handles it all very well either way so I'm worrying for nothing :) and I'm just going to get back on with it.

    Go GameSalad :)

Sign In or Register to comment.