I want to precache some bitmaps and then create a series of layers with small details. e.g. hands of watch. I guess this can be done by me manually combining bitmaps respecting the .a channel and sending it in to the BitmapLayer. But I was wondering if it can be achieved within the framework.
I am trying to see if transparency can be achieved. The documentation states that the alpha channel is used for blending. However, I can't seem to achieve any form of blending. I am drawing in a Layer using the callback and accessing the bitmap directly. The value of .a makes no difference to the image drawn.
Where would the .a channel be used in the framework for blending?
With the new 3.0 SDK and colors, you need the GCompOpSet
compositing mode for transparency to work.
Simply call bitmap_layer_set_compositing_mode()
and set the compositing mode to GCompOpSet
.