Re: 24-bit-per-pixel limit to Gdk RGB ?
- From: Peter Finderup Lund <firefly diku dk>
- To: individual <individual mi cl>
- Cc: gtk-app-devel-list gnome org
- Subject: Re: 24-bit-per-pixel limit to Gdk RGB ?
- Date: Wed, 19 Feb 2003 09:27:47 +0100 (MET)
On Wed, 19 Feb 2003, individual wrote:
Thank you to all those who helped me with this issue. I now understand
bit depths a bit better.
I gave it a shot, and the Gtk one came out very quickly, and looks
great. In 24 bpp colour!
I had a harder time with the xlib one, for some reason that I am as
likely to figure out as the origin of the Moais on Easter Island, I had
to add space every RGB triplet with a leading 0.
That's because you got a 32-bit visual -- or because you used a 32-bit
pixmap format. You can ask for a list of visuals (they are numbered --
but the number varies between X servers) and pick the one you like best.
xdpyinfo will tell you which visuals you can choose between and their
characteristics if you want to make an easy one-off test program.
You can also use different pixmap formats. AFAIR you ask for a list of
supported bit depths and then simply make a pixmap of that depth (the
depth is part of the pixmap structure).
-Peter
"Of course, I'm not unbiased, but in my humble opinion, I've
gotten close to something that I can be really proud of."
-- Knuth on The Art of Computer Programming.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]