🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.os.os2.programmer
Article #148

Re: How do I iterate through Physical Screen Colors?

#148
From: David Charlap
Date: Tue, 03 Nov 1992 21:26
21 lines
1863 bytes
In article <Bx55v3.Dww@usenet.ucs.indiana.edu> sthiagar@bronze.ucs.indiana.edu (sivasailam thiagarajan) writes:
>In article <1992Nov2.182223.9326@njitgw.njit.edu> dic5340@hertz.njit.edu (David Charlap) writes:
>>Just do a GpiSetColor(hps, colorIndex); The GpiSetColor function sets
>>drawing to the color specified at the given palette index.  The
>>constants like CLR_BLACK, CLR_RED, etc simply map to the numbers 0
>>through 15, which are the colors that you shouldn't remap unless you
>>run out of spare palette entries.
>
>I wish it were that easy, but this doesn't seem to work. The
>rectangles corresponding to numbers larger than the CLR_* indices all
>seem to map to white. And nothing changes, even when I run WinGIF
>seamlessly to change the physical palette.

I think this will be the case unless you do a DosRealizePalette().  I
know this won't change any palette entries, but it may enable the
colors for your application's use.
-- 
David Charlap         |"there aren't 50,000 things for which it's worth writing
dic5340@hertz.njit.edu| software; and the computer industry doesn't have enough
----------------------+ programmers to create that much good software.
Therefore, most of it must be worthless" -- Boris Beizer "The Frozen Keyboard"
Technical Details
Message-ID: <1992Nov3.212622.9318@njitgw.njit.edu>
Path: arc1-ca.pugleaf.net!sparky!uunet!walter!bellcore!rutgers!njitgw.njit.edu!hertz.njit.edu!dic5340
References: <Bx3H05.L0s@usenet.ucs.indiana.edu> <1992Nov2.182223.9326@njitgw.njit.edu> <Bx55v3.Dww@usenet.ucs.indiana.edu>

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!sparky!uunet!walter!bellcore!rutgers!njitgw.njit.edu!hertz.njit.edu!dic5340
From: dic5340@hertz.njit.edu (David Charlap)
Newsgroups: comp.os.os2.programmer
Subject: Re: How do I iterate through Physical Screen Colors?
Message-ID: <1992Nov3.212622.9318@njitgw.njit.edu>
Date: 3 Nov 92 21:26:22 GMT
References: <Bx3H05.L0s@usenet.ucs.indiana.edu> <1992Nov2.182223.9326@njitgw.njit.edu> <Bx55v3.Dww@usenet.ucs.indiana.edu>
Sender: news@njit.edu
Distribution: na
Organization: New Jersey Institute of Technology, Newark, N.J.
Lines: 21
Nntp-Posting-Host: hertz.njit.edu