Split DRICreateSurface into 3 functions.
Make CreateSurfaceForPixmap use xp_configure_surface. I suspect this is partly why
GLXPixmaps never worked.
It will require some more work and thoughts for pbuffers, unless we fake those with
pixmaps and surfaces.
(cherry picked from commit 9cf264e677)
Reorder some header files and provide some types earlier on.
Remove the static __GLXextensionInfo __glDDXExtensionInfo; that isn't
used in 1.4 or 1.5, and seems to have been removed from 1.6. Remove
the data structures associated with that too.
Remove __glXAquaDrawableResize. The GLX structure doesn't use
it anymore, and the Apple version did nothing useful before.
__glXAquaDrawableSwapBuffers(): base no longer contains a drawGlxc
member. Now provide the the Apple/Aqua context in the __GLXAquaDrawable
struct. Add the context member to the __GLXAquaDrawable struct.
Remove the fallback configs. They aren't used in 1.4 or 1.5 either.
Remove init_visuals(). It's not used in 1.4 or 1.5 either.
In the drawable constructor initialize the state properly, including
the new context member.
Remove glAquaResetExtension() -- it's not used anymore.
This has been tested remotely and proven to work with glxgears,
fire, various texture programs I wrote, and various Mesa demos.
(cherry picked from commit d514152195)
rlAccel is not longer compatable, and it's not worth fixing
Don't override DeviceCursorInitialize with a noop
Don't do a SwitchCoreKeyboard (which wasn't even needed in the first place)
(cherry picked from commit c137f68168)
Use a __GLXconfig linked list struct to store the configurations for the
fbconfigs and visuals in a pGlxScreen.
Also, remove the __GLXvisualConfig/GlxSetVisualConfigs code that isn't used
anymore. There is more code we can remove later, but I want to do that in
separate commits.
(cherry picked from commit 94162b0f8a)
A better approach which ensures we have a L modifier key down if we are told neither are down and atleast one is down... =/
(cherry picked from commit bc13dda345)
It was incorrectly blamed for some crashes a few months ago, and it should be
safe to use until we get an EXA driver to replace it.
(cherry picked from commit 8121f30bd2)
This old behavior was used as a workaround for the menubar behavior in the older server,
but we handle it better now and need to update our screens when we toggle the rootless
state instead.
(cherry picked from commit 508aa95bc2)
A grep on xorg/* revealed there's no consumer of this define.
Quote Alan Coopersmith:
"The consumer was in past versions of the headers now located
in proto/x11proto - for instance, in X11R6.0's xc/include/Xproto.h,
all the event definitions were only available if NEED_EVENTS were
defined, and all the reply definitions required NEED_REPLIES.
Looks like Xproto.h dropped them by X11R6.3, which didn't have
the #ifdef's anymore, so these are truly ancient now."
Signed-off-by: Peter Hutterer <peter.hutterer@redhat.com>
Signed-off-by: Adam Jackson <ajax@redhat.com>
Add various GLX extensions to the list of supported extensions.
Reformat the oddly formatted code in some areas.
Use xalloc and xfree instead of malloc and free.
(cherry picked from commit 755f53eb40)
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.
(cherry picked from commit b772d64fce)
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.
(cherry picked from commit 17f6a261fc)
Added a configure option called --enable-standalone-xpbproxy which is useful for deveoping xpbproxy.
The 'active' switch in preferences just disables the in-server xpbproxy (not this standalone).
(cherry picked from commit 4294493632)
This prevents visuals with odd sizes. The machine I use didn't have
this problem, but it shows up on some others.
(cherry picked from commit ed181382dd)
Use the settings queried from the system in xprScreen.c, rather than those 2 calls.
The 2 calls increased the total number of visuals a great deal (when using GLXEXT),
and not all of the visuals were usable with GLX. Some of the visuals aren't usable
with GLX still, such as DirectColor, but that seems to be acceptable based on my
understanding of the manual that states "a subset of visuals are made available
for OpenGL rendering."
(cherry picked from commit 373b8a5f32)
It was returning inverted values in comparison to the 1.4 branch. This resulted in
the windows not drawing due to a deep path of: RootlessReorderWindow ->
SCREENREC(pScreen)->imp->DoReorderWindow(winRec) - > xprDoReorderWindow ->
AppleWMDoReorderWindow.
(cherry picked from commit d1d398db76)
GL/capabilities.c: Add handleDepthModes(), and extend
handleRendererDescription() for the various depth and multisampling flags.
Add initialization of the new config options to initConfig().
GL/capabilities.h: Add depth and multisample config members.
GL/visualConfigs.c: Add depth and multisampling support to the visual config
setup.
(cherry picked from commit f527381eea)
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)
This is used in libGL to determine a preferred visual. glxinfo -v will also
report "visualCaveat=Slow" for such visuals.
(cherry picked from commit d5c17f585a)
It seems that we were calling copy_completed: too soon. Now we return instead
of falling through to the free_propdata, and copy_completed:.
(cherry picked from commit 5797d5b662)
This may work, unfortunately I don't have test apps that fail.
The way it works is by using an NSImage class initWithPasteboard:
method, which we then get the TIFFRepresentation of, and convert
to PNG or JPEG.
The TIFFRepresentation uses NSTIFFCompressionNone; which should be
lossless.
(cherry picked from commit 8d048cfa95)
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)
We need to revisit the GL/indirect.c changes. I think indirect.c should
be using the same feature detection and GLX visual config code. The
indirect changes will require testing...
(cherry picked from commit 49b7a7c6f2)
Add dump_prefs() for instrospection.
Make prefs_get_bool a little more clear.
In get_property don't assume that the Mac realloc(NULL, 0); returns
non-NULL. We shouldn't depend on implementation-defined behavior too
much.
Add more commentary in various spots.
Add TARGETS in the TARGETS response. I don't know why some X11 apps
do this, but it could be something that some weird toolkit/app tests
for.
In reload_preferences add preferences synchronization, so that xpbproxy
reloads the preferences, and picks up any changes.
Fix a typo/misspelling of the sync_clipboard_to_pasteboard preference.
(cherry picked from commit 165cbbb90c)
Use ErrorF for an error message after an xcalloc failure, and return instead of falling through to GlxSetVisualConfigs, or abort()ing at the test branch.
(cherry picked from commit 1056700971)
instead of calling CFRunLoopRun() directly. The leak wasn't reproducible on
this machine, but someone was able to produce a leak trace with Instruments
that indicates it was leaking in the CFRunLoopRun() path.
x-input.m: dequeue and ignore events when pbproxy_active is false.
x-selection.h: add an is_active method that is used by x-input.m to ignore
events.
x-selection.m: Handle nearly every preference, except for primary_on_grab,
which I don't really understand yet.
(cherry picked from commit 4d51ad851e)