www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2001/07/19/11:51:27

From: Sterten AT aol DOT com
Message-ID: <c.18b29f66.28885b90@aol.com>
Date: Thu, 19 Jul 2001 11:49:36 EDT
Subject: Re: pokeb peekb
To: eliz AT is DOT elta DOT co DOT il
CC: djgpp AT delorie DOT com
MIME-Version: 1.0
X-Mailer: AOL 3.0 16-bit for Windows sub 60
Reply-To: djgpp AT delorie DOT com

Eli Zaretskii wrote:
 
 >#include <conio.h>
 >This will pull in the correct definition of ScreenPrimary.

OK.

 >You wanted to do something extremely system-dependent, and you didn't 
 >even know that a C program must have a main function.

I seem to recall that some C-dialects don't need main() ,
but I could be wrong

 >That's quite a steep learning curve, if you ask me.

if that is already a steep learning curve , then I wonder how many
hours a newby is supposed to invest before he can use DJGPP !?!


here is my final version, it compiles to about 90KBytes.
I also use it with slight modifications
for incrementing pixels in mode 13h :

#include<go32.h> 
int main() { // increments screenbyte at (x,y) , gcc video3.c -o video3.exe 
int x=57,y=16;
_farpokeb(_dos_ds,0xb8000+y*160+x*2,_farpeekb(_dos_ds,0xb8000+y*160+x*2)+1);}


sometimes, but not always , I also need for compiling :
#include<farptr.h>

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019