Source: src/si_graphics.cc
|
|
|
|
//Processing graphics
#include
using namespace std;
#include
#include
deque bitmap_sector(BITMAP *bmp, int x1, int y1, int x2, int y2, int sx, int sy)
{
deque l;
BITMAP *tmp;
int a, b;
for(a=y1; a!=y2+1; a++) {
for(b=x1; b!=x2+1; b++) {
tmp = create_bitmap(sx, sy);
blit(bmp, tmp, (b-1)*sx, (a-1)*sy, 0, 0, sx, sy);
l.push_back(tmp);
// clear(screen)
// draw_sprite(screen, tmp, 10, 10);
// readkey();
}
}
return l;
}
void destroy_bitmap_safe(BITMAP *b)
{
cout<<"Destroying bitmap ... ";
if(!b) {
cout<<"already NULL bitmap"<
Generated by: georgik on armada on Sat Jul 24 07:07:15 2004, using kdoc 2.0a54. |