I'm trying to figure out how to use an overlay plane. I'm running:
Redhat 7.3 and the Linux kernel 2.4.18-10
NVidia Quadro2 video card
XFree86 4.2.0
GLX 4.0.2-1.0.3123
I'm new to openGL so what I'm trying to do may be flawed.
Here is the sequence:
dpy= XOpenDisplay()
glXQueryVersion()
- reports major=1, minor=2
main_visual= glxChooseVisual()
main_context=
glXCreateContext(dpy,overlay_visual,0.GL_TRUE)
overlay_visual= glxChooseVisual()
with GLX_LEVEL = 1
overlay_context=
glXCreateContext(dpy,overlay_visual,0.GL_TRUE)
win= XCreateWindow() using the main visual's
screen, depth, and visual
glXMakeCurrent(dpy,win,main_context) to
access the main plane
- Drawing commands for main plane go here
glXMakeCurrent(dpy,win,overlay_context) to
access the overlay plane
- At this point I get a "BadMatch" error which
I think is because the overlay context was
created with overlay_visual and win was
created with main_visual. What am I doing
wrong?
One thing that is interesting, "xprop -root"
displays the SERVER_OVERLAY_VISUALS, but glxinfo
doesn't display anything about overlays.
begin:vcard
n:Hammond;Eric
tel;work:(607)721-4585
x-mozilla-html:FALSE
org:L-3 Communications' Link Simulation and Training
adr:;;;;;;
version:2.1
email;internet:[EMAIL PROTECTED]
note:(607) 721-4585
x-mozilla-cpt:;19648
fn:Eric Hammond
end:vcard