GdkBitmap - turning pixels OFF
- From: Kent Humphries <kenth vpac org>
- To: gtk-app-devel-list gnome org
- Subject: GdkBitmap - turning pixels OFF
- Date: Wed, 08 Mar 2006 16:24:10 +1100
Hi,
I'm a relative newbie to the Gtk+/Gdk world and am having trouble with
the GdkBitmap.
I am creating GdkBitmaps in order to create clip masks. The mask is used
for a graphics context which I then pass as an argument to
gdk_draw_drawable. Basically I have two 'layers' which should be
exclusively independent. That is, where one 'layer' is visible (clipped
in by the mask), the other layer should be clipped out, and vice-versa.
In order to do this, and in order to update the masks as I update the
layers, I need to be able to 'turn' pixels off. I am using a Cairo
surface to write to the Bitmap. Is there a specific colour I can specify
that will be 'off' for the bitmap. I think there's some way to do this
with a GdkGC, but I can't figure it out.....
Scenario: I paint an entire 'mask' bitmap black which would clip the
entire bitmap's area. I then want to remove a small portion of the
bitmap, ie make it transparent/clear/white/off/unset again. Using Cairo
and painting an opaque white, or transparent white over the top does not
work.
Help......
Thanks. Kent.
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]