X-Git-Url: http://4ch.mooo.com/gitweb/?a=blobdiff_plain;ds=sidebyside;f=src%2Flib%2Fmodex16.c;h=2b489c2bb6e432a433cad481b555925da20f96c9;hb=4b59d025ac5e1eea1fe4fdb58fb1de101990f872;hp=6bd22e85d67a1a7b8e840fabe12f832cb6f3816b;hpb=2a01a752cb8c451f199d156cf12e6837ce11ab93;p=16.git diff --git a/src/lib/modex16.c b/src/lib/modex16.c index 6bd22e85..2b489c2b 100755 --- a/src/lib/modex16.c +++ b/src/lib/modex16.c @@ -56,7 +56,8 @@ void VGAmodeX(sword vq, global_game_variables_t *gv) int86(0x10, &in, &out); gv->old_mode = out.h.al; // enter mode - modex__320x240_256__Enter(gv); + //modex__320x240_256__Enter(gv); + modex__256x192_256__Enter(gv); } } @@ -76,25 +77,33 @@ modex__320x240_256__Enter(global_game_variables_t *gv) { word i; dword far*ptr=(dword far*)VGA; /* used for faster screen clearing */ - word CRTParms[] = { - 0x4f01, /* horizontal display enable end */ - 0x5002, /* */ - 0x5404, /* */ - 0x8005, /* */ - 0x0d06, /* vertical total */ - 0x3e07, /* overflow (bit 8 of vertical counts) */ - 0x4109, /* cell height (2 to double-scan */ - 0xea10, /* v sync start */ - 0xac11, /* v sync end and protect cr0-cr7 */ - 0xdf12, /* vertical displayed */ - 0x2813, /* offset/logical width */ - 0x0014, /* turn off dword mode */ - 0xe715, /* v blank start */ - 0x0616, /* v blank end */ - 0xe317 /* turn on byte mode */ - }; - - int CRTParmCount = sizeof(CRTParms) / sizeof(CRTParms[0]); + + int CRTParmCount = sizeof(ModeX_320x240regs) / sizeof(ModeX_320x240regs[0]); + /* width and height */ + //TODO WWWW + + /* common mode X initiation stuff~ */ + modexsetBaseXMode(); + + /* send the CRTParms */ + for(i=0; i