I got my Arduboy this week and have built a few small test apps (particle effects, bitmap rendering etc) and am currently working on a Bomberman clone using the Arduboy2 library. I’ll share my code when the tile engine is reasonably complete.
The thing that confuses me the most so far is masks. There are a bunch of masked drawing functions (drawSelfMasked, drawPlusMask etc), and most of the tools can generate masks in addition to pixel data from our png sources.
Pixel data + mask data takes up twice the memory so I assume there must be a very good reason to use it. However; even after reading the header-files I have no idea what the concept of “masking” means, or what the different masked drawing functions are for. I think it might have to do with transparency - are masked pixels transparent?
I’d be super grateful for any insights. Here’s some questions from the top of my mind:
When is a mask necessary to use?
Is drawing masked bitmapdata significantly slower?
What are the differences between the various masked drawing functions?
Is one function generally preferred (performance wise) over the others?
These forums have already been tremendously helpful, so thank you all for your time and effort!