Xref: news2.mv.net comp.os.msdos.djgpp:1164 From: brennan AT mack DOT rt66 DOT com (Brennan "Mr. Wacko" Underwood) Newsgroups: comp.os.msdos.djgpp Subject: Re: Beginning graphics question Date: 13 Feb 1996 20:04:52 -0700 Organization: None, eh? Lines: 49 Message-ID: <4frjgk$j1o@mack.rt66.com> References: <4fbqgg$ljm AT dziuxsolim DOT rutgers DOT edu> <311E4482 DOT 4B0F AT unm DOT edu> NNTP-Posting-Host: mack.rt66.com To: djgpp AT delorie DOT com DJ-Gateway: from newsgroup comp.os.msdos.djgpp In article <311E4482 DOT 4B0F AT unm DOT edu>, (Not his real name) wrote: >Pieter Kunst wrote: >> >> In article <4fbqgg$ljm AT dziuxsolim DOT rutgers DOT edu> Anthony Cowley writes: >> > >> >Please, I'm not looking for libraries to do everything for me. I'm a >> >do-it-yourself kind of guy, so I'd like to use my existing routines. I just >> >need the info above to continue. >> > >> >Plus, I'm a total newbie when it comes to 32-bit coding, so I have no clue >> >here. What should I know? Or where can I get the file that tells me that? >> > > >I know how ya feel, ok, you can't access the video mem the same. V2 >has far pointer functions, they act like far pointers. It goes >something like this. > >#include // far pointer functions >#include // _dos_ds, dos selector > >int screen= 0xa0000; > >int main() >{ > _farsetsel(_dos_ds); // set up selector for _farnspokeb > set_video_mode(0x13); > > _farnspokeb(screen, 2); // "pokes" video mem with a green pixel > > set_video_mode(0x03); > > return 0; >} > >you are prolly saying, "I don't want to use functions, I want to write >directly to memory!" Well, don't worry, compile your programs with >the -O3 and the far functions are lightening fast, just me, if you >don't trust me, trust DJ. Also, look at the sys\farptr.h file. You can find a slightly more eloquent (but not much) version of this at http://www.rt66.com/~brennan/djgpp/ Plus a bunch of other nifty DJGPP+games related stuff. --brennan -- brennan AT rt66 DOT com | "Disco Stu doesn't NEED to advertise."