=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= =- -= =- Source Code for switching Video Modes without using BIOS -= =- January 2, 1998 Version 3.0 -= =- -= =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= =- See the README.TXT file for the Disclaimer and other info -= =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= ** Note ** This code does not update BIOS when in real mode. So if you need that particular functionality, you will have to add this yourself. =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- =- Currently supported Video Modes: -= Mode Number =- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- =- 03H -=- 320 x 200 x 256 -= 03H =- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- =- 10H -=- 640 x 350 x 16 -= 10H =- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- =- 12H -=- 640 x 480 x 16 -= 12H =- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- =- 13H -=- 320 x 200 x 256 -= 13H =- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- =- Chain 4 -=- unchained 320 x 200 x 256 -= 14H =- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- =- Mode X -=- unchained 320 x 240 x 256 -= 15H =- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- =- Mode A -=- unchained 320 x 400 x 256 -= 16H =- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- =- Mode B -=- unchained 360 x 480 x 256 -= 17H =- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- =- Mode C -=- 640 x 400 x 16 -= 18H =- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- To set a video mode using the procedure I already have written: PUSH *VALUE* ; Where value is the mode number CALL SETVIDEOMODE and thats it the videomode gets set. Once the video mode is set, you can program each video mode as normal. Just remember, you can't rely on BIOS so if you need the palette set to the proper values, you need to set them yourself. =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= If you want to use this code in your programs, all you need is which ever mode you want from MODES.INC and also the procedure SETMODE. Just MOV SI, OFFSET *MODE* ; Where mode is the mode from MODES.INC CALL SETMODE If you want the unchained modes, you also need a bit of code from the SETVIDEOMODE procedure in MAIN.ASM. =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= I have also included some source for clearing the screen and plotting a pixel in all of the unchained modes. This includes Chain-4, Mode X, Mode A, and Mode B. The nice feature about this is that all of the modes use exactly the same memory structure so the same code can be used to program all. =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=