Path: utzoo!utgpu!news-server.csri.toronto.edu!rutgers!dimacs.rutgers.edu!mips!daver!vsi1!octopus!stever From: stever@Octopus.COM (Steve Resnick ) Newsgroups: comp.os.msdos.programmer Subject: Re: Writing a program that uses a mouse - help needed Message-ID: <1990Nov14.205619.27265@Octopus.COM> Date: 14 Nov 90 20:56:19 GMT References: <1990Nov5.003125.7426@frey.nu.oz.au> <0093F67C.47A771C0@router.jhuapl.edu> <1583@ukpoit.co.uk> Reply-To: stever@octopus.UUCP (Steve Resnick ) Distribution: comp Organization: Octopus Enterprises, Cupertino CA Lines: 39 In article <1583@ukpoit.co.uk> alan@ukc.ac.uk (Alan Barclay) writes: > >I'm trying to get a set of colors so I can use text mode but >with a graduation from deep red->white->deep green. I'm using >a VGA and Microsoft C 5.1, the following code sets up the colors > >long newcolormap[] = >{ > 0x000000L, 0x00003fL, 0x0a0a3fL, 0x14143fL, > 0x1e1e3fL, 0x28283fL, 0x32323fL, 0x1f1f1fL, > 0x323f32L, 0x283f28L, 0x1e3f1eL, 0x143f14L, > 0x0a3f0aL, 0x003f00L, 0x3f0000L, 0x3f3f3fL >}; > >void setupvga(void) >{ > _remapallpalette(newcolormap); >} > >but I have to use the Norton Command Centre to change the normal >pallete colors (0,1,..,5,20,7,56,57,..,63) to sequential numbers >(0,1,...,15) as the colors at 20 & 56 .. 63 don't change. Does any >one know how to set the pallete colors like NCC does or alternately >how to set these colors over 16. According to my references here, BIOS int 10H function 10H sets the palette registers (like NCC does) for EGA/VGA display adapters. The information is quite lengthy however. I am relatively sure that this is listed in Ralf Brown's interrupt list. You may want to look there. Hope this helps.... Steve -- ---------------------------------------------------------------------------- steve.resnick@f105.n143.z1.FIDONET.ORG - or - apple!camphq!105!steve.resnick Flames, grammar errors, spelling errrors >/dev/nul The Asylum OS/2 BBS - (408)263-8017 IFNA 1:143/105.0