PocketMatrix forums

A read-only archive of the PocketMatrix forums (2001–2014). Posting and accounts are closed.

GapiDraw heavy memusage and possible 8bit surfaces ?

Hello,

i'm using GapiDraw for a while now and it's really straight forward to use and has good performance. But I think there is something that could drastically decrease memory usage.

As I've understand it right, all GapiDraw Surfaces are 16Bit (or even 24 ?). So if I load a 32Color 5Bit PNG, GapiDraw nevertheless uses 16bit. Isn't it possible without big cuts, that it just uses the Bit-Depth of the loaded image ?

The Game we're currently developing is really using too much mem because of this, and our images are just from 4 - 8bit. Would be great if someone could tell us that internal support for lower bit-depths will be added in the future, or tell us, why it should not be useful.

Thank you,

Michael Ritter
ritter@x-sites.de
It's an issue of performance hit. 8-bit surfaces require a tranformation to 16-bit on blits.

You can implement them yourself though through GetBuffer/ReleaseBuffer and custom blitters/loaders.

The Arm Procs are also optimized for 32-bit and 8-bit incurs an additional performance hit from that.
Thanx for the quick answer.

Looks like we have to think about something we could tell the people, why we need around 32+ MB of ram :O. ;)

Do you (or someone here) has any info, what percentage of the PocketPC users own additional storage cards, so that they have at least the full 32/64Mb free for your programs ?

Greets,

Michael Ritter
Like I said, you can still implement this yourself thanks to getbuffer/releasebuffer. It's actually not that difficult and the performance hit may not affect your game all that much. Also, the performance hit somewhat nullifies it self due to the reduced memory traffic.

You've other options as well though. Reduce the framerate of your graphics, introduce a dynamic caching mechanism (Sprite Pool as I like to call it) reduce the size of the graphics (As in width/height) etc.