From: Bjorn Hansen Newsgroups: comp.os.msdos.djgpp Subject: what's wrong with this code? Date: Sat, 01 Aug 1998 12:02:52 -0800 Organization: ISPNews http://ispnews.com Lines: 17 Message-ID: <35C3746C.5BEA866A@xyz.net> NNTP-Posting-Host: hom-3-28.xyz.net Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit NNTP-Posting-Date: 1 Aug 1998 20:04:29 GMT To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp Precedence: bulk I know that this must be something simple that I am missing but when I try to compile this: #include #include main() { char v; v=_farpeekb(_dos_ds,0xA0000); printf("%c",v); } I get a Error of '_dos_ds' undeclared what am I doing wrong or not doing? d info files I finally achieved >for the monitor to give me a sign that it actually changed to a mode 13h -- >the graphics mode. However it will not show a pixel, a box or a line. >[...]Here is the program that I am trying to work with: [...] >void GrLine(int x1,int y1,int x2,int y2,GrColor c) etc... why don't you use the Allego library, and use: void do_line(BITMAP *bmp, int x1, y1, x2, y2, int d, void (*proc)()); Calculates all the points along a line from point (x1, y1) to (x2, y2), calling the supplied function for each one. This will be passed a copy of the bmp parameter, the x and y position, and a copy of the d parameter, so it is suitable for use with putpixel(). there are lots of other good graphics routines in it. cheers