video mode question

ben pedersen ben_pedersen at canrem.uucp
Mon Dec 17 18:21:09 AEST 1990


Subject: Re: video mode question

In article <66205 at unix.cis.pitt.edu>, brs at unix.cis.pitt.edu
(Brian Stupar) writes...
BS>does anyone know how to set the video mode to 80 x 43?  i have
BS>tried using int 10 func 00, but any values over 11 result in
BS>no change in the screen mode.  the interrupt list documents
BS>mode values up to around 70, but any over 11 have no effect.
BS>is there something i'm missing, something i've done wrong, or
BS>is this mode not available for use?  the machine is 386 based
BS>with VGA graphics.

The following function written by <steverimmer at canremote.uucp>,
(Steve Rimmer) in COMPUTING NOW! Jan1990 works well for me -

/* select the 8x8 font for 43 line mode */
set43line()
{
    union REGS r;
    int cpage;

    /* get current page */
    r.x.ax = 0x0f00;
    int86(0x10, &r, &r);
    cpage = r.h.bh;

    /* set page to zero */
    r.x.ax = 0x0500;
    int86(0x10, &r, &r);

    /* load 8x8 character set */
    r.x.ax = 0x1112;
    r.h.bl = 0;
    int86(0x10, &r, &r);

    /* set old active page */
    r.x.ax = 0x0500 + cpage;
    int86(0x10, &r, &r);
}

/* select the 8x14 font for 25 line mode */
set25line()
{
    union REGS r;
    int cpage;

    /* get current page */
    r.x.ax = 0x0f00;
    int86(0x10, &r, &r);
    cpage = r.h.bh;

    /* set page to zero */
    r.x.ax = 0x0500;
    int86(0x10, &r, &r);

    /* load 8x14 character set */
    r.x.ax = 0x1111;
    r.h.bl = 0;
    int86(0x10, &r, &r);

    /* set old active page */
    r.x.ax = 0x0500 + cpage;
    int86(0x10, &r, &r);
}

Hope this is of use to you.

--Regards!
---
 ~ DeLuxe}aa #5459 ~ 
--
Canada Remote Systems.  Toronto, Ontario
NorthAmeriNet Host



More information about the Comp.lang.c mailing list