Message-ID: <37E294DB.87A9535D@gtcom.net> From: Krogg X-Mailer: Mozilla 4.61 [en] (Win95; U) X-Accept-Language: en-US,en-GB,en,ja MIME-Version: 1.0 Newsgroups: comp.os.msdos.djgpp Subject: Re: Allegro,BITMAP *buffer; References: <37E1B735 DOT C564EEB AT gtcom DOT net> <05a4d7f6 DOT 74e084f3 AT usw-ex0102-016 DOT remarq DOT com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Lines: 70 Date: Fri, 17 Sep 1999 15:22:03 -0400 NNTP-Posting-Host: 12.16.179.35 X-Trace: eagle.america.net 937596355 12.16.179.35 (Fri, 17 Sep 1999 15:25:55 EDT) NNTP-Posting-Date: Fri, 17 Sep 1999 15:25:55 EDT Organization: 24hoursupport.com To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Reply-To: djgpp AT delorie DOT com > In article <37E1B735 DOT C564EEB AT gtcom DOT net>, Krogg > wrote: > > BITMAP *buffer=create_bitmap(1024,768); > > If i comment it out my program will compile and > > run fine and if i load some other program that > > uses the same code it will compile fine as well.. > > Does my program have a hex on it? > > the error i get is: > > Compiling: XXXX.c > > In function `main': > > XXXX.c(39) Error: parse error before `*' > Varence wrote: > > Looks like an error caused by a preprocessor instruction > being inserted into the code. Check that none of your > project files has some kind of #define for buffer. no chance of this,I even tried different labels for the buffer instead of "buffer" and i have also tried the code like so: BITMAP *buffer; buffer=create_bitmap(1024,768); > Also, try declaring BITMAP *buffer at the head of the > function, and buffer = create_bitmap(1024,768) after. If > you have other instructions prior to this, rather than just > declarations, your compiler might be spewing. > If i understand you correctly then you are saying do this: BITMAP *buffer; int main(void) { buffer=create_bitmap(1024,768); } instead of doing this: int main(void) { BITMAP *buffer=create_bitmap(1024,768); } OK,I tried it and it worked great.I dont understand why but I will think about it a while and see if i can.Thanks, my program looks nice in double buffering. Thanks,and Be Cool, Krogg -- |"""""<`.THE PRINCE ,'>"""""""""""""""""""""""""""""""""""| | `.`/""""""\,',' my sig is too big, | |SEE HIS ( / \ \' SEE HIS but its really cool. | | FACE \/<> <>\/ SMILE | | / W \ Visit my ascii art site: | | ,'\_|||||_/`. http://www.gtcom.net/~krogg/ascii/ | | ,',' ||| `.`. krogg DOT no DOT to DOT spam AT gtcom DOT net | |____<,' TIME TO DIE `.>____Remove no.to.spam to reply____|