[Gtk-sharp-list] How to get X11 window (for OpenGL rendering)?
Fri, 16 Apr 2004 05:52:30 +0100
I think what you need is to use the macro:
Note that you will need to wrap the macro in a C function, and p/invoke
to it. Then, from C#/Gtk#, you can write code like:
Window window = ...;
int id = gdk_drawable_xid(window);
I would guess you will also need the xdisplay, even if you system
handles the GLContext. Use the macro:
You can take a look in the CVS of GtkGL# (module "gtkgl-sharp", password
(btw, you need to export CVS_RSH=SSH).
On Fri, 2004-04-16 at 05:01, J. Perkins wrote:
> Disclaimer: I know almost nothing about Gtk or Gtk#. I am learning, slowly.
> I have a C++ rendering system that I am trying to wrap with C# and Gtk#.
> It wants an X11 Window to render into. Googling makes it look like it
> is possible to get an X11 window from a Gtk window, but I don't see
> anything in Gtk# that looks like it would work. Is this possible?
> FYI, I can't use the various Gtk-GL addons for this application, since
> this system creates and manages its own GL context under the hood. I've
> looked at some of the C sources, but again I don't see how they
> translate to Gtk#
> Help much appreciated,
> Gtk-sharp-list maillist - Gtkemail@example.com
Bruno Fernandez-Ruiz <firstname.lastname@example.org>
The Olympum Group, http://www.olympum.com