Index: [thread] [date] [subject] [author]
  From: Marcus Sundberg <e94_msu@elixir.e.kth.se>
  To  : ggi-develop@eskimo.com
  Date: Sat, 08 Aug 1998 17:04:19 +0200

Re: palettes, etc

> Quoting Marcus Sundberg (e94_msu@elixir.e.kth.se):
> > > i'm a bit confused with the palette system... if i'm using a 16bit resolution
> > > (say 640x480x16bpp), do i HAVE to build a palette?
> > > i've developed with Allegro (a DOS/DJGPP graphics/games lib, really cool), and
> > > you only need to work with palettes when using a 8bpp res, not in 16bpp+... is
> > > this the case with libGGI?
> > 
> > No, it's not even possible to set/build a palette on a 16-bit mode.
> > What are you trying to do that makes you think you have to set
> > a palette?
> Well, looking though all the demos they all had a palette definition, etc..
> so, i guess these definitions are only for 8bpp resoloutions? hmm.. well, if i
> _do_ actually get around to start on developing annything in/for GGI is it ok
> to force people to use 16+bpp?
> 
> urgh, i'm really confused now...
> 
> all i want to know is: do i have to define a palette, even though i'm aiming
> for development with 16+bit graphics? and if i do that, will it be ok for
> people using KGI as well as libGGI/X11?

Ok, I'll just give you some facts, please ask again if it doesn't
answer all your questions:

* If you try setting a palette in a non-paletteusing mode nothing at all
  will happen.
* If you don't set a palette in a paletteusing mode the palette is undefined
  ie, it may be all black or all purple.
* Note that you don't need to set the whole palette if you don't want to
  - if you only need 16 colors you can set only 16 colors of the palette
  and use those.

* Every _wellwritten_ GGI application should support at least 8,15,16 and 32
  bit modes, and it is strongly advised that it support 24-bit modes as
  well. (15-bit modes are not so common, but if you support 16-bit it's
  just a few lines of code extra)
* If you don't support all these modes your application will fail to run
  on some hardware and targets.

//Marcus
-- 
-------------------------------+------------------------------------
        Marcus Sundberg        | http://www.stacken.kth.se/~mackan
 Royal Institute of Technology |       Phone: +46 707 295404
       Stockholm, Sweden       |      E-Mail: e94_msu@e.kth.se


Index: [thread] [date] [subject] [author]