Hi! > Thanks for the tip. I looked at the source code and it looks like you are > using C functions for particular situations such as X coordinate a multiple > of 2, etc. But for the arbitrary case where these specific conditions are > not satisfied, you resort to using the PalmOS functions. Is this the case or > am I missing something? > Is it true that in the arbitrary case (no special conditions satisfied by > the sprite bitmaps) there is no faster way to draw than the PalmOS methods? The current state of Razor is only an intermediate step towards the final goal, with 4bpp being slightly behind 8bpp. Right now I am using an optimized copying loop for the ideal case, in which entire bytes can be copied, and let the OS handle the arbitrary case. I am absolutely convinced that it won't be hard to be a lot faster than the OS for the arbitrary case. I just haven't gotten around to doing this yet.
> Another approach might be for me to only redraw a portion of the screen. > second. Suppose that I can identify say 6 non-overlapping rectangles > whatever). My >question is: if I were to just set 6 clipping rectangles > within the my image and rebuild the portions of the image within those 6 > clipping rectangles, would that be faster than redrawing? I know that in I know of a game named "Rogue Bomber" at SourceForge. They switched from such a dirty rectangle list to a version that redraws larger regions than are neccessary, and copies the entire doublebuffer. They report a big increase in speed. The setup and execution costs for clipped copying and clipped drawing are rather high. See their discussion article at http://sourceforge.net/forum/forum.php?thread_id=687137&forum_id=61067 In Razor! I also do not determine the dirty rectangles precisely. I only do vertical calculations and always affect the entire width of the screen. I also merge all dirty rectangles into a single one, which is then processed. The only case where this is noticeable less efficient than a less crude method is when you have few sprites, some at the very top of the screen, some at the very bottom. This is merged into one dirty rectangle that covers the entire screen, instead of two small ones. Cheers, Tilo -- For information on using the Palm Developer Forums, or to unsubscribe, please see http://www.palmos.com/dev/support/forums/
