Path: utzoo!attcan!uunet!ns-mx!iowasp!deimos!ux1.cso.uiuc.edu!uwm.edu!rpi!zaphod.mps.ohio-state.edu!uakari.primate.wisc.edu!ames!amdahl!nsc!pyramid!leadsv!zech From: zech@leadsv.UUCP (Bill Zech) Newsgroups: comp.lang.pascal Subject: Re: 256 colour mode in TP5.0 Summary: VGA registers are readable Message-ID: <10334@leadsv.UUCP> Date: 14 Mar 90 06:42:26 GMT References: <25F744E5.8753@maccs.dcss.mcmaster.ca> <18812@shamash.cdc.com> Organization: LOCKHEED, Sunnyvale, CA Lines: 19 In article <18812@shamash.cdc.com>, mpe@shamash.cdc.com (2375) writes: > The problem of capturing images using turbo pascal is that there is no way > to read the palette registers back from the display controller card. Within > the run-time environment, an array of previous values is used by the BGI > graphics manager to shadow the palette contents. Long before you invoke your > getimage program, a TSR that captures the int 10 interupt commands which update > the CRT control, must monitor all int 10's for potential palette updates. > Also, each shell opened by the user, loads it's own version of the command.com > and *.bgi file base and therefore creates a yet another set of palette array > registers. Good luck. This is not true for a VGA card. All the registers (save one minor one, I believe) are both readable and writable. The EGA and CGA boards were write-only, but the VGA fixes that problem. Also, I believe there is a procedure in the graphics.tpu to read the pallete registers. - Bill