Index: [thread] [date] [subject] [author]
  From: Andrew Apted <ajapted@netspace.net.au>
  To  : ggi-develop@eskimo.com
  Date: Sat, 12 Sep 1998 23:59:48 +1000

Re: GT_2BIT?

Stefan writes:

>  On Sat, 12 Sep 1998, Andrew Apted wrote:
>  
>  > Q: do we upgrade the drivers for the new scheme, or what ?
>  
>  I have missed something here... what new scheme?

Graphtypes now have four fields: the `scheme' field (which can be
GT_TEXT, GT_PALETTE, GT_TRUECOLOR or GT_GREYSCALE), the `subscheme'
field (a few special uses, like specifying reverse bit/byte order), and
the `depth' and `size' fields (depth specifies number of bits of usuable
color info, and size is the pixel width in bits.  EG: 15/16 and 24/32).

The old GT_xxBIT defines are mainly for compatibility, and are defined
as follows:

    #define GT_TEXT16       GT_CONSTRUCT(4, GT_TEXT, 16)
    #define GT_TEXT32       GT_CONSTRUCT(8, GT_TEXT, 32)
    #define GT_1BIT         GT_CONSTRUCT(1, GT_PALETTE, 1)
    #define GT_2BIT         GT_CONSTRUCT(2, GT_PALETTE, 2)
    #define GT_4BIT         GT_CONSTRUCT(4, GT_PALETTE, 4)
    #define GT_8BIT         GT_CONSTRUCT(8, GT_PALETTE, 8)
    #define GT_15BIT        GT_CONSTRUCT(15, GT_TRUECOLOR, 16)
    #define GT_16BIT        GT_CONSTRUCT(16, GT_TRUECOLOR, 16)
    #define GT_24BIT        GT_CONSTRUCT(24, GT_TRUECOLOR, 24)
    #define GT_32BIT        GT_CONSTRUCT(24, GT_TRUECOLOR, 32)

LibGGI makes use of this new info (which is in ggi/types.h), but the KGI
drivers are still using the old enumerated graphtypes in kgi/types.h.

Cheers,
_____________________________________________  ____
                                               \  /
  Andrew Apted   <andrew@ggi-project.org>       \/
  

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