Hey guys. Nice to make your acquaintance. I'm quite new to allegro so please bear with my lack of knowledge.
I'm currently developing a tiling engine for my game and have come across two potential ways of rendering the tiles to the screen.
One is that in every frame, I calculate which sub rectangle of the tilemap intersect with the camera, and call many al_draw_bitmap_region per frame to render the tiles from my tilesheet bitmap to the screen.
The other one is that as soon as I have a tilemap loaded, I pre-render my entire tilemap onto a large bitmap (by calling many al_draw_bitmap_region), and every frame I simply render (al_draw_bitmap) that large bitmap to the screen. I got this method from reading the source of Flixel, and thought it is a rather smart way of doing this. But knowing that flash/AS is inherently different from allegro + C/C++, I'm dubious of whether or not this is a good idea in our case.
I'm not sure which one would be more efficient and I don't actually know how to test it :S. So here I am hoping that you guys could give me some tips.
Thanks in advance for any replies!