Well...what kind of code is that smartguy240?
Here is old DOS FritzOS code that does all the box painting code.:
#include <go32.h> #include <sys/farptr.h>
// INIT GRAPHICS // YOU should DO this in your BOOTSECTOR, like this // BUT without the C comments: // mov ax, 13h // int 10h
// Now, put a pixel on the screen: void putpixel_13h(int x, int y, int color) { _farpokeb(_dos_ds, 0xA0000+y*320+x, color); }
// Call This to draw boxes: void Box( int clr, int start_x, int start_y, int end_x, int end_y ) { int i, y; for ( i = start_x; i < end_x; i++ ) for ( y = start_y; y < end_y; y++ ) // NOTE: THIS IS SERVERLY NOT OPTIMIZED putpixel_13h( i, y, clr )
void start() { // Test PutPixel, put a red pixel in the top putpixel_13h( 12, 12, 4 );
// test box drawing: make a blue box Box( 1, 90, 90, 199, 199 ); }
#ifndef __DJGPP__ #error I NEED DJGPP! #endif // THIS HAS BEEN MODIFIED FOR DGJPP
|