Mail Archives: djgpp/1999/07/17/10:10:59
Hello all,
I am just a beginner, so bear with me.
I am reading several tutorials on game programming using DJGPP to gain some
basic game programming skills in 13h mode. After hours of trying out
snippets and reading the DJGPP FAQ and browsing the info.exe, I found out
that I couldn't access 0xA000 directly. "use the so-called "farptr"
functions like _farpeekb and _farpokew" is stated in the FAQ. I tried a lot
and I finally got a pixel plotted on the screen using the <go32.h> and its
functions:
_farsetsel(_dos_ds);
_farnspokeb(0xA0000 + y*320 + x, color);
- What is the "farptr" for ? And what is a poke and a peek ?
- I noticed that there are lots of functions that look so much like the above:
_farpokeb
_farpokew
_farnspokew
etc.
which is now the best or easiest way for me to use for this plotting
pixel stuff.
- Why are there so many functions that look like they are far or near types
? The compiler is 32bit and in the FAQ stated that DJGPP doesn't even
recognise the far and near types ?!?!
- Also a tutorial mentioned that I could disable/enable the protected mode
using __djgpp_nearptr_enable();
and __djgpp_nearptr_disable() for pixel plotting. But it also stated that
it could damage the DOS area and block the system ?! How much damage can it
do? Would it be permanent ?
Regards
Mark.
- Raw text -