🚀 go-pugleaf

RetroBBS NetNews Server

Inspired by RockSolid Light RIP Retro Guy

Article View: comp.windows.ms.programmer
Article #3009

Reading System Palette

#3009
From: Mark Brezina
Date: Tue, 04 Jun 1991 15:49
17 lines
1024 bytes
	Hi.  I'm trying to read the system palette as a series of RGB values.   But no entries are retrieved when I use the following piece of code:

	LPPALETTEENTRY	SystemPalette;
	PALETTEENTRY	LogPaletteEntries[256];
	HDC		hDC;
	int		nEntries;

	hDC = GetDC( hWnd );
	SystemPalette = LogPaletteEntries;
	nEntries = GetSystemPaletteEntries( hDC, 0, 16, (LPPALETTEENTRY) System
					    Palette );
	ReleaseDC( hWnd, hDC );


I'm using a 256 color VGA monitor and a 16 color screen.  Has anyone got this
function to work?
Technical Details
Message-ID: <1991Jun4.154955.16447@maytag.waterloo.edu>
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!caen!spool.mu.edu!news.cs.indiana.edu!maytag!csg.uwaterloo.ca!markb

Show Full Headers
Complete Article Headers
Path: arc1-ca.pugleaf.net!utzoo!utgpu!news-server.csri.toronto.edu!rpi!zaphod.mps.ohio-state.edu!caen!spool.mu.edu!news.cs.indiana.edu!maytag!csg.uwaterloo.ca!markb
From: markb@csg.uwaterloo.ca (Mark Brezina)
Newsgroups: comp.windows.ms.programmer
Subject: Reading System Palette
Message-ID: <1991Jun4.154955.16447@maytag.waterloo.edu>
Date: 4 Jun 91 15:49:55 GMT
Article-I.D.: maytag.1991Jun4.154955.16447
Sender: news@maytag.waterloo.edu (News Owner)
Organization: University of Waterloo
Lines: 17