Mail Archives: djgpp/2001/07/19/06:14:53
On Thu, 19 Jul 2001 Sterten AT aol DOT com wrote:
> 1) what's the shortest complete program that pokes a face (ascii 1)
> into the exact middle of the screen and exits to DOS ?
_farpokeb (_dos_ds, ScreenPrimary + 12*160 + 80, 1);
(This is not a complete program, but the rest is easy to add.)
> 2) what , if it has to be fast (~50 cycles)
The above line of code expands into 2 instructions of inline assembly.
How much faster can you ask it to be?
> 3) what , if it is required to compile on a large variety of compilers ?
Forget it: the glyph which will be displayed when you put ASCII 001 to
the screen is not the same on each system, and the way to print directly
to the screen memory is different on every OS and each compiler.
- Raw text -