delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1997/06/09/15:04:28

From: aho450s AT nic DOT smsu DOT edu (Tony O'Bryan)
Newsgroups: comp.os.msdos.djgpp
Subject: Re: ALLEGRO: custom color palletes
Date: Mon, 09 Jun 1997 15:17:36 GMT
Organization: Southwest Missouri State University
Lines: 17
Message-ID: <339994d2.13014541@ursa.smsu.edu>
References: <33946B2C DOT 5CD6 AT popd DOT ix DOT netcom DOT com>
NNTP-Posting-Host: forseti.i17.smsu.edu
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp

On Tue, 03 Jun 1997 12:06:20 -0700, Alan Reed <#areed AT popd DOT ix DOT netcom DOT com> wrote:

>essentially I am just trying to figure out how to make global palletes
>and just define them once. 

Easy.  Make a separate PCX file for each palette you want to use.  Go into
Grabber and create a palette type for each palette you want to use.  For each
PCX file, load it using the load bitmap function from within Grabber, highlight
the palette entry that you want to store the colors in, the grab the palette
from the PCX file.  Save the palette file to disk and you now have a single file
with all the palettes you want.

From within your program, define a global DATAFILE * variable and load the
Grabber file into it.

This is especially useful if you have several programs that use the same
palettes.  That way you only have to go through the Grabber procedure once.

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019