Thanks for the code, I'm sure it will come in handy. Here are the next couple of questions
![Wink ;)](./images/smilies/icon_wink.gif)
<br><br>First, I'm wondering which methods to implement for alpha blending. There's the option of loading two images (sprite and its alpha), scanning the alpha, trying to create a alpha value map on the run and then use it against another bitmap (background) to produce the desired effect. This approach is the most straightforward, if not simplistic. Another way to go about this process would be to pre-process the alpha bitmap and create (before runtime) a table of locations and their alpha values. This would save time since I won't have to scan through the alpha bitmap @ runtime as well reduce the amount of memory used (one less bitmap to load). The problem is creating this table of values, I'm not sure how to go about that.<br>Second, optimisations. I've heard some really good ideas in regards to optimising the alpha-blending code. One of them mentioned doing calculations and transformation of the loaded bitmaps (eg. for sprites) before the actual rendering loop kicks in, as it only leaves you to add the current framebuffer to the background to produce the desired effect (if anyone could elaborate on that, perhaps in a more practical fashion, I would appreciate it). Also, I think it was on your (Jacco) page that I saw some ideas on how to avoid using floating point variables in the calculations to increase the speed. Finally, I've seen some code for 86x asm that performs alpha blending, and was wondering if anyone's knowledgeble enough to port it into ARM asm. I personally only dealt with 86x and Z80 asm and currently am studying MIPS, so ARM is the grey area for me...<br><br>Keep up the good comments, I really appreciate the input!