Graphics performance question in retrogaming project

mataruamatarua Auckland, New ZealandMember Posts: 854
I have the option to use either actors that are rendered on to a black background and use the 'screen' graphic blending mode as they are on a black background that works fine. This way they are 8bit PNG files.

Or I can bring them in as clear alpha channel 24bit files and don't do any graphic blending.

Any ideas on what would be best performance wise?

@quantumsheep you maybe dealt with this in your Air Supply Infinite yeah?

How did you do yours?

Might be an obscure question as it only really works for games with black backgrounds.

Cheers, M@

Comments

  • SocksSocks London, UK.Member Posts: 12,822
    edited November 2013
    I have the option to use either actors that are rendered on to a black background and use the 'screen' graphic blending mode as they are on a black background that works fine. This way they are 8bit PNG files.

    Or I can bring them in as clear alpha channel 24bit files and don't do any graphic blending.

    Any ideas on what would be best performance wise?
    @matarua

    Whether your images are 8bit or 24bit they will be converted to / held in a 24bit colour space when playing on the device (this is true of all iOS devices).

    Example: a 1000 x 1000 pixel file @ 24bit that is 10Mb will occupy 10Mb of RAM - and a 1000 x 1000 pixel file @ 8bit that is 3MB will also occupy 10Mb of RAM.

    So, word length is irrelevant when it comes to RAM use / performance, only pixel dimension matters as everything is seen as 24bit, which means 8bit files won't give you any performance advantages, although the game's memory footprint will be smaller when it comes to downloading or storing the app on the target device.

    Note: You can have 8bit files with an alpha channel.
  • mataruamatarua Auckland, New ZealandMember Posts: 854
    @Socks yep I am aware of that thanks - it's kind of my space and learnt the memory usage thing the hard way early on in this game >>> 895KB of images was using 330MB of memory. :-/

    What I am more referring to is an moving rotating group of actors that moves over layers of each other - is a black square block easier to render than an alpha channel?

    But to be the black square block it has to have 'screen' applied.

    That essentially makes it appear transparent in the black parts.

    Is that a bit clearer? Any ideas on that?
  • quantumsheepquantumsheep Member Posts: 8,188
    a screenshot might help, sir!

    Dr. Sam Beckett never returned home...
    Twitter: https://twitter.com/Quantum_Sheep
    Web: https://quantumsheep.itch.io

  • mataruamatarua Auckland, New ZealandMember Posts: 854
    Since I am not pro just at the mo I can't but will tweet it to you k :)
  • tatiangtatiang Member, Sous Chef, PRO, Senior Sous-Chef Posts: 11,949
    @matarua see my signature for instructions on how to embed an image here.

    New to GameSalad? (FAQs)   |   Tutorials   |   Templates   |   Greenleaf Games   |   Educator & Certified GameSalad User

  • mataruamatarua Auckland, New ZealandMember Posts: 854
    Thanks @tatiang - I am getting pro for Christmas this year - I was asked what I wanted and thought that's an idea :D

    image

    Here's the thing - clear cut with alpha channel or flat using screen blending mode - the result is identical - but I was wondering if it's better to use screen - vs alpha channel.

    It's a bit of a wacky question I know sorry but I was interested to see if you guys had any ideas on what's best if you have lots of actors swarming all over each other over a moving background and bullets and missiles and star streams and all that sort of stuff.

    Cheers, M@
  • quantumsheepquantumsheep Member Posts: 8,188
    I think it's something you'll have to test out to see what looks best!

    For your info, in Infinite I had the particles fade out as well as enlarge - so they get bigger and fade to alpha 0, allowing the next particle below it to show, which in turn did the same thing as well ad infinitum (if you'll pardon the gag!).

    Doing it this way meant that the images could be smaller and 'full' with no transparency on the image - which meant better performance and file size stuff.

    Hope that helps!

    QS =D

    Dr. Sam Beckett never returned home...
    Twitter: https://twitter.com/Quantum_Sheep
    Web: https://quantumsheep.itch.io

  • mataruamatarua Auckland, New ZealandMember Posts: 854
    You got that humming pretty well and I thought I would ask going forward, a bit of an esoteric question - but even the Speccy had a transparent colour eh - but not 256 levels of transparency :-B

    I was impressed with the star streams and grids and stuff - they work really well :)

    Thanks for the tips and I can't wait to release this 'mini' game I am making - it's getting there.
Sign In or Register to comment.