Main Page   File List   Globals  

tests/test5.c

00001 /***************************************************************************
00002                        test.c  -  tests if rectfill works
00003                              -------------------
00004     begin                : Sat Feb 16 2002
00005     copyright            : (C) 2000 by Daniele Venzano
00006     email                : webvenza@libero.it
00007  ***************************************************************************/
00008 
00009 /***************************************************************************
00010  *                                                                         *
00011  *   This program is free software; you can redistribute it and/or modify  *
00012  *   it under the terms of the GNU General Public License as published by  *
00013  *   the Free Software Foundation; version 2 of the License.               *
00014  *                                                                         *
00015  ***************************************************************************/
00016 #include "FBlib.h"
00017 #include <stdio.h>
00018 #include <stdlib.h>
00019 #include <time.h>
00020 
00021 #define MAX_SECS 30
00022 #define UPDATE_INTERVAL 5
00023 
00024 int update;
00025 
00026 void sig_alarm(int sig)
00027 {
00028         update=1;
00029         
00030 }
00031 
00032 int main()
00033 {
00034         FB_initlib("/dev/fb0");
00035         FB_clear_screen(FB_makecol(0,0,0,0));
00036         FB_rectfill(10, 12, 100, 120, FB_makecol(255,0,0,0));
00037         FB_rectfill(90, 12, 300, 120, FB_makecol(0,255,0,0));
00038         FB_rectfill(20, 100, 120, 400, FB_makecol(0,0,255,0));
00039         FB_rectfill(90, 100, 300, 400, FB_makecol(213,31,125,0));
00040         getchar();
00041         FB_clear_screen(FB_makecol(0,0,0,0));
00042         FB_exit();
00043         return 0;
00044 }

Generated on Sat Jul 5 09:04:52 2003 for LibFB by doxygen1.2.18