Drawing CSD on EGL apps
Bill Spitzak
spitzak at gmail.com
Mon Nov 5 14:51:12 PST 2012
Giulio Camuffo wrote:
> I don't see how that would help drawing client side decorations. Or are
> you talking about a different problem?
The problem I am talking about is that on X and Windows, if you have a
window created for OpenGL rendering, the method used to get a "normal
drawing context" (an HDC on Windows and a GC on X) does not work! You
therefore cannot use existing drawing functions (ie toolkits) to draw
into the same window as OpenGL.
I suspect this is about 99% of the reason for people using subwindows to
render OpenGL under X and Windows. It certainly is the reason I do it.
The fact that you have to account for the subwindow in your OpenGL code
is minor in comparison, though I agree it would be nice to add this to
the OpenGL/EGL api. In the same application we make subrectangles out of
the OpenGL window (for dividing the viewer into 4 views) without any
trouble.
Under wayland if you assume the "normal drawing context" is a cairo_t,
and you can make a cairo_t from an OpenGL/EGL buffer, then this does
seem like it would work. The current status of the Cairo OpenGL backend
however worries me.
More information about the wayland-devel
mailing list