matching curor on other windows - how?
Diana Esch-Mosher <[email protected]> 17 Jan 2003 10:52:26 -0700
| Newsgroups | gmane.comp.gnome.gtkglarea |
|---|---|
| Message-ID | <1042825946.28697.27.camel@delores> |
I have multiple windows that each contain a GtkGLArea for viewing remotely-sensed images. I would like to display a cursor (that follows the main cursor) in the other windows. I was redrawing the other windows, based on the motion-notify in the main window, and then just using openGL to draw a simple crosshair cursor. Well this works, but the cursor is irritatingly jerky. Yeah, hardware acceleration helps a lot, but I don't want to depend on this. I really don't need/want to redraw the underlying image! I found that I could just make_current, use opengl to do a GL_COLOR_LOGICAL_OP with an XOR, write where my cursor was and then the cursor's new position, swap_buffers. Yeah, this is much faster, but I really would like to have a cursor where I could specify the color! I have combed the web for information on other options and tried to understand overlays, but I must confess I'm a newbie and this seems tied to hardware more than I'd like and not that straightforward. I guess I'd really like to understand how the gtk cursor renders to the active display without having to redraw the underlaying image each time. Understanding that I might have a clue how to proceed. I see no way to directly use gtk_cursor to help me out here. Can someone help enlighten me!?!?! Thanks, Diana Esch-Mosher