Author : Jay
Page : << Previous 2
explained in the
next lesson, so don't worry about this for now
******************************************************************/
acquire_screen();// Get the screen
draw_sprite(buffer, my_pic, my_pic_x, my_pic_y);//Draw the picture to the buffer
blit(buffer, screen, 0,0,0,0,640,480);//Draw the buffer to the screen
release_screen();// Release it
/*
Uncomment the following 3 lines, and comment out the 4 previous lines in order
to view an UNBUFFERED mode of drawing.
*/
//acquire_screen();// Get the screen
//draw_sprite(screen, my_pic, my_pic_x, my_pic_y);
//release_screen();// Release it
}
destroy_bitmap(my_pic);//Release the bitmap data
destroy_bitmap(buffer);//Release the bitmap data
return(0);// Exit with no errors
}
END_OF_MAIN(); // This must be called right after the closing bracket of your MAIN function.
// It is Allegro specific
Page : << Previous 2