====== Graphics on the GameTank ====== In most systems, a sprite is a graphical resource of limited size that can be moved across the screen without modifying the playfield. Not so on the GameTank. A "sprite" here can have any size (up to 127x127 pixels) but cannot be moved. It //will// modify the playfield. **The GameTank approach is to completely redraw the entire screen for every frame**. This is achieved thanks to the the system's blitter which is theoretically fast enough to update the screen 2 to 3 times per screen refresh, thus maintaining a 60 FPS animation (note: the Atari Lynx follows a similar approach). ===== VRAM ===== In order to achieve maximum efficiency, graphical assets need to be loaded in VRAM using ''allocate_sprite()''. This function specifies a VRAM bank. Sprites can then be drawn by calling ''queue_draw_sprite()'', referencing the SpriteSlot returned by ''allocate_sprite()''. See [[development:csdk:2.0:sprites|Importing and Drawing Sprites]] for further information. ===== Double Buffer ===== The C SDK provides easy double buffering to avoid any flickering. A typical animation loop in C looks like this: while(1) { // Draw stuff await_draw_queue(); await_vsync(1); flip_pages(); // Business logic }