C51 COMPILER V7.06 GUI 08/02/2005 13:30:00 PAGE 1 C51 COMPILER V7.06, COMPILATION OF MODULE GUI OBJECT MODULE PLACED IN GUI.OBJ COMPILER INVOKED BY: d:\Keil777\C51\BIN\C51.EXE GUI.C BROWSE DEBUG OBJECTEXTEND stmt level source 1 #include *** WARNING C318 IN LINE 1 OF GUI.C: can't open file 'graphics.h' 2 #include 3 #include *** WARNING C318 IN LINE 3 OF GUI.C: can't open file 'fcntl.h' 4 #include *** WARNING C318 IN LINE 4 OF GUI.C: can't open file 'io.h' 5 6 void advlogo(void) 7 { 8 1 static FILE *stream; *** ERROR C141 IN LINE 8 OF GUI.C: syntax error near '*' 9 1 signed int cnt; 10 1 char filename[30]="logo.bmp"; 11 1 unsigned char pbuf[256]; 12 1 unsigned long picsize; 13 1 unsigned long info_start; 14 1 unsigned int ix,iy,fx,fy; 15 1 unsigned char cbyte,colour; 16 1 17 1 unsigned int cx,cy; 18 1 unsigned int ht=154; 19 1 float scale=1; 20 1 21 1 int handle; 22 1 unsigned long songlength; 23 1 24 1 cy=400; 25 1 cx=320; 26 1 27 1 handle = open(filename, O_RDONLY); 28 1 songlength=filelength(handle); 29 1 close(handle); 30 1 31 1 32 1 if(songlength==99638) 33 1 { 34 2 stream = fopen(filename,"rb"); 35 2 cnt=0; 36 2 do 37 2 { 38 3 getc(stream); 39 3 cnt++; 40 3 } 41 2 while(cnt<1078); 42 2 43 2 cnt=0; 44 2 do 45 2 { 46 3 getc(stream); 47 3 cnt++; 48 3 } 49 2 while(cnt<6400); 50 2 51 2 iy=cy+ht/2; C51 COMPILER V7.06 GUI 08/02/2005 13:30:00 PAGE 2 52 2 fy=cy-ht/2; 53 2 54 2 do 55 2 { 56 3 ix=0; 57 3 do 58 3 { 59 4 cbyte=getc(stream); 60 4 if(cbyte==0) {colour=BLUE;} 61 4 if(cbyte!=0) {colour=LIGHTBLUE;} 62 4 if( ((ix>20) && (ix<620)) && ((iy>340) && (iy<472)) ) 63 4 { 64 5 putpixel((ix/scale),(iy/scale),colour); 65 5 } 66 4 ix++; 67 4 } 68 3 while(ix<640); 69 3 iy--; 70 3 } 71 2 while(iy>fy); 72 2 fclose(stream); 73 2 74 2 75 2 } 76 1 77 1 } 78 79 void c_box(unsigned int wait_time,unsigned int ccolor) 80 { 81 1 unsigned int cx,cy; 82 1 83 1 cx=320; 84 1 cy=240; 85 1 86 1 setcolor(ccolor); 87 1 88 1 do 89 1 { 90 2 rectangle(320-cx,240-cy,320+cx,240+cy); 91 2 if(cx>0) {cx--;} 92 2 if(cy>0) {cy--;} 93 2 94 2 } 95 1 while((cx>0)||(cy>0)); 96 1 97 1 setcolor(YELLOW); 98 1 } 99 100 void e_box(unsigned int center_x, unsigned int center_y, unsigned int length, unsigned int height) 101 { 102 1 unsigned int left, right; 103 1 unsigned int top, bottom; 104 1 unsigned int cx,cy; 105 1 106 1 cx=0; 107 1 cy=0; 108 1 109 1 do 110 1 { 111 2 setcolor(WHITE); 112 2 rectangle(center_x-cx,center_y-cy,center_x+cx,center_y+cy); 113 2 setcolor(DARKGRAY); C51 COMPILER V7.06 GUI 08/02/2005 13:30:00 PAGE 3 114 2 rectangle(center_x-cx+1,center_y-cy+1,center_x+cx-1,center_y+cy-1); 115 2 setcolor(WHITE); 116 2 rectangle(center_x-cx+2,center_y-cy+2,center_x+cx-2,center_y+cy-2); 117 2 setcolor(BLUE); 118 2 rectangle(center_x-cx+3,center_y-cy+3,center_x+cx-3,center_y+cy-3); 119 2 120 2 if(cx