Commit Graph

10 Commits

Author SHA1 Message Date
George Staplin
b772d64fce XQuartz: GL: Remove the inclusion of glcontextmodes.h.
Add some commentary about future directions needed for the GLX drawable
creation and destruction code.

Match xalloc with xfree.

I made some minor formatting improvements.
2008-11-22 11:37:08 -07:00
George Staplin
17f6a261fc XQuartz: GL: Add a branch to prevent a NULL DrawablePtr structure access.
In attach() check for pDraw being NULL, and also print an ErrorF message,
because we eventually want to track down why this is occuring.

It's unclear how this occurs, but as I noted in the 1.4 branch, I believe that
the DrawablePtr/struct _Drawable -> id is the member being accessed that causes
KERN_PROTECTION_FAILURE at 0x0000000000000004

This passes my tests using: env LIBGL_ALWAYS_INDIRECT=1 ./sometest.

I fixed a warning: caused by initializing the screen->base.visuals with the
configs.  It is a ** not a *.  It seems that some other part of GLX will
initialize this for us.
2008-11-22 11:06:28 -07:00
George Staplin
047ac0b4fd XQuartz: GL: Add 1 __GLXconfig for testing purposes. Now glxgears runs.
It looks much better with the new GLX/libGL, perhaps because of the old libGL
not understanding all of the tags written.  At least glxgears works with both.

glxgears is not a test for all OpenGL features, so most likely some things
are broken still.  Direct rendering is known to not work, or at least being
reported as not working.
2008-11-21 18:27:42 -07:00
George Staplin
594e81c397 XQuartz: GL: Convert some of the indirect.c code to work with the change to __GLXconfig.
Fix some obvious errors with uninitialized new members of GLX structs.

Add a type argument for the screen's drawable creation function, and pass the type to
__glXDrawableInit().

GLX still doesn't work.  There is more work needed to get it working again.  This gets
it building at least, although there are some warnings in the dispatch table setup,
that seem to be caused by const differences.

I also #if 0ed a bunch of function bodies that will need to be revisited soon.
2008-11-21 17:31:10 -07:00
George Peter Staplin
caa049246f XQuartz: GL: Work around problems with really deep visuals.
GL/capabilities.c: #if 0 (for now) any capabilities above 8 bits per channel,
because they introduce drawing problems.

GL/indirect.c: Comment out some visual setup code that shouldn't be running, and
actually seemed to cause some problems.  The current visualConfigs.c code seems
to do a reasonable job of setting up visuals for XQuartz.

GL/visualConfigs.c: Make use of the proper visual .class.   Eliminate depth 0.
It seems we really just want 24 for now, and 0 I think was a flaw in the original
code.
(cherry picked from commit 1e5f63f15e)
2008-11-05 19:20:50 -08:00
Jeremy Huddleston
b7ec1fa59c XQuartz: LP64 related casting fixes from Bob Murphy
(cherry picked from commit ea71710aaa)
2008-10-31 19:03:23 -07:00
George Peter Staplin
73566cef7c XQuartz: GL: Add feature detection of color sizes, and accum sizes.
This gives us a *lot* more visuals, and they should be more accurate.
Some of the visuals may have been wrong before.  This may enable more
OpenGL programs to behave correctly.

I also suspect libGL needs a little work to handle some of these correctly.
(cherry picked from commit 98a084ce9c)
2008-10-28 21:59:24 -07:00
Jeremy Huddleston
cc228b8869 XQuartz: GLX - enable_stereo defaults option should work now
(cherry picked from commit 3a6898f487)
2008-10-04 21:15:54 -07:00
Kristian Høgsberg
bd81faff8c Drop glcore GLX provider.
Obsoleted by the DRI swrast driver.
(cherry picked from commit 77ff8fd507)
2008-06-26 16:14:51 -04:00
Jeremy Huddleston
d88da6638e Moved Apple GL bits into our DDX subtree
(cherry picked from commit c9356f3289)
(cherry picked from commit d09c520b32)
2008-06-26 16:14:51 -04:00