How build a FPG32 (sample)

Started by SplinterGU, April 02, 2009, 01:57:02 PM

« previous - next »

0 Members and 1 Guest are viewing this topic.

SplinterGU

[code language="bennu"]import "mod_screen";
import "mod_video";
import "mod_map";
import "mod_draw";

global
  int cubo;
  int lib;

begin
   set_mode(640,480,32);

   cubo=new_map(100,100,32);

   drawing_map(0,cubo);
   drawing_color(rgb(0,0,200));
   draw_box(50,0,100,100);
   drawing_color(rgb(0,100,200));
   draw_box(0,0,50,100);
   drawing_color(rgba(100,0,200,50));
   draw_box(25,0,75,25);
   /* Hole */
   drawing_color(rgba(255,255,0,200));
   draw_box(35,35,65,65);
   drawing_color(rgba(255,0,255,64));
   draw_box(45,45,55,55);

   lib = fpg_new();
   fpg_add(lib,1,0,cubo);
   save_fpg(lib,"fpg32.fpg");

End
[/code]
Download Lastest BennuGD Release: http://www.bennugd.org/node/2

blostec

Great sample, it's perfect to do tests with 32 bits fpg's. Thanks!