Index:
[thread]
[date]
[subject]
[author]
From: Andrew Apted <ajapted@netspace.net.au>
To : ggi-develop@eskimo.com
Date: Fri, 17 Jul 1998 00:10:36 +1000
Re: New ggi_graphtype
Marcus writes:
> > There is hardware like this, for example RGB 6:6:4 and (IIRC) RGB 5:7:4,
> > so these need to be specifiable in the graphtype, especially since the
> > graphtype is now the pixel-format as well. Yes, applications will
> > usually specify GT_AUTO for the subscheme, but they might *get back* an
> > RGB 6:6:4 format, so the graphtype must differentiate it from any other
> > 16 bit format (like RGB 5:6:5).
>
> Well, you might be right. In that case I'd say we have two alternatives:
> a) Make the graphtype a struct
> b) Remove the subscheme from the graphtype and put the information in
> the mode-struct instead.
I think we should stick to the subscheme idea. The values of subscheme
can be arbitrary -- so long as they differentiate different modes at the
same scheme + depth. This way, graphtype == pixel format ==
ggi_plb_common_setup == get/put buffer format. Multible problems
solved in one fell swoop.
> The new members in ggi_mode would then be:
> ggi_pixel red_mask,
> ggi_pixel green_mask,
> ggi_pixel blue_mask,
> int reverse_endian,
There's no harm having that functionaly *in addition* to the graphtype,
maybe as an API call (e.g. ggiGetTrueColorMask(vis,*r,*g,*b)) or maybe
in some public structure -- although I doubt ggi_mode is the best place.
> (For the 16-bit truecolor case reverse_bitness is replaced by the
> masks. And for indexed modes... Well, what is "reverse bitorder"
> on a indexed mode anyway?
On modes < 8, "reverse bitorder" is the different between sp1a8lbl
(low bit left) and sp1a8hbl (high bit left), for example.
> On a sidenote - the size entry should go away from the ggi_mode
> struct.
Agreed. Monitor size seems like information that won't be available
with most targets anyway. Maybe add a ggiGetMonitorSize() function to
libggimisc ?
Cheers,
_____________________________________________ ____
\ /
Andrew Apted <andrew@ggi-project.org> \/
Index:
[thread]
[date]
[subject]
[author]