at CodeWeavers for the patch. From his description:
Fix a display bug with the X server. The Generic Rootless extension
installs overrides for certain GC (graphics context) operations. Within
these overrides, they temporarily uninstall themselves, perform their work,
and then reinstall themselves. Except sometimes they would return early
and wouldn't reinstall themselves when they should. Now they do in all cases.
Fix a bug in RootlessCopyWindow where early returns could leave the screen's
dispatch table entry for CopyWindow unwrapped. We think that this is
another case (hopefully the last) of the rootless drawing bug.
These hints allow an acceleration architecture to optimize allocation of certain
types of pixmaps, such as pixmaps that will serve as backing pixmaps for
redirected windows.
This was an attempt to avoid scratch gc creation and validation for paintwin
because that was expensive. This is not the case in current servers, and the
danger of failure to implement it correctly (as seen in all previous
implementations) is high enough to justify removing it. No performance
difference detected with x11perf -create -move -resize -circulate on Xvfb.
Leave the screen hooks for PaintWindow* in for now to avoid ABI change.
DamagePendingRegion returns a pointer to the region of a drawable that will
be damaged by the current operation for damage records that chose to get damage
reported only at the end of the operation.
over to new system.
Need to update documentation and address some remaining vestiges of
old system such as CursorRec structure, fb "offman" structure, and
FontRec privates.
Composite's automatic redirection is a more general mechanism than the
ad-hoc BS machinery, so it's much prettier to implement the one in terms
of the other. Composite now wraps ChangeWindowAttributes and activates
automatic redirection for windows with backing store requested. The old
backing store infrastructure is completely gutted: ABI-visible structures
retain the function pointers, but they never get called, and all the
open-coded conditionals throughout the DIX layer to implement BS are gone.
Note that this is still not a strictly complete implementation of backing
store, since Composite will throw the bits away on unmap and therefore
WhenMapped and Always hints are equivalent.
This new function walks the composite region and calls a rectangle
compositing function on each compositing rectangle. Previously there
were buggy duplicates of this code in fbcompose.c and
miext/rootles/safealpha/safeAlphaPicture.c.
Additionally, protect libcw setup behind checks for Render, to avoid
segfaulting if Render isn't available (xnest).
The previous setup was an ABI-preserving dance, which is better nuked now.
Now, anything that needs libcw must explicitly initialize it, and
miDisableCompositeWrapper (previously only called by EXA and presumably binary
drivers) is gone.
Get rid of almost all uses of these definitions. They're still defined for
delinquent out-of-tree drivers, and also for the Mesa build. As well as
for miinitext.c. But largely gone.
backing drawable if the serial numbers differ. Fixes crash in XAA which
occurred when the DDX bumped the serial number on the backing drawable and
expected it to get re-validated, and we didn't because the wrapped drawable
hadn't been bumped.
- Merge various fb/ bits of COMPOSITE support from xserver, which weren't
necessary before due to cw hiding the issues. Fixes offset calculations
for a number of operations, and may pull some fixes that cairo has
wanted for XAA as well.
- Add a new call, miDisableCompositeWrapper(), which a DDX can call to keep
cw from getting initialized from the damage code. While it would be
cleaner to have each DDX initialize it if it needs it, we don't have
control over all of them (e.g. nvidia).
- Use the miDisableCompositeWrapper() to keep cw from getting set up for
screens using EXA, because EXA is already aware of composite. Avoiding
cw improved performance 0-35% on operations tested by ajax in x11perf.
Add XSERV_t, TRANS_SERVER, TRANS_REOPEN to quash warnings.
Add #include <dix-config.h> or <xorg-config.h>, as appropriate, to all
source files in the xserver/xorg tree, predicated on defines of
HAVE_{DIX,XORG}_CONFIG_H. Change all Xfont includes to
<X11/fonts/foo.h>.
change "foo.h" to <X11/foo.h> for core headers, e.g. X.h, Xpoll.h;
change "foo.h", "extensions/foo.h" and "X11/foo.h" to
<X11/extensions/foo.h> for extension headers, e.g. Xv.h;
change "foo.[ch]" to <X11/Xtrans/foo.[ch]> for Xtrans files.
not at the backing pixmap's origin. Resulted in incorrect rendering in
at least aisleriot, fluxbox, and KDE apps, and probably many more.
While here, move the ParentRelative loop above the drawable grab -- may
improve correctness with ParentRelative background origins as well.
Note that the border code doesn't handle ParentRelative yet.
according to the rules as I understand them (bug #1045), not everybody
follows the rules. GC funcs were being called on the same GC from
within GC ops, and the cwValidateGC caused a loop in the funcs chain
that resulted in a crash, notably in cwPolylines.
to me.
Clean up transition between cheap and expensive GC wrappers by using the
prologue and epilogue macros. Before, the GC would be left unvalidated
sometimes which would cause all kinds of entertaining bugs against a
DDX which cares (XAA).
Eliminate needless (and, it turns out, dangerous) call to ChangeGC on
DestroyGCPrivate.
in cwSetWindowPixmap, check if the pixmap is the screen pixmap and disable
the wrapper by setting the private to NULL.
None works.
Copy filter to backing picture during validation.
Mark picture serialNumber when setting Filter or Transform so Validate
occurs.
Initialize xf86Screens[i]->pScreen to NULL so that RADEON driver doesn't
crash during server reset using old pScreen.
visuals. Necessary to keep Flash from crashing.
Must call ValidateGC/ValidatePicture on "real" GC/Picture to ensure
pCompositeClip is set correctly.
Need to take the composite clip from the "real" GC/Picture and turn it into
the clientClip for the backing version.
Adjust pixmap screen origin to account for drawable->x/y Change debugging
output a bit (disabled by default)
not, DamageSetup will wrap some operations first, and the cw
initializes during ExtensionInit, so cw comes higher in the wrapping
chain. cw going first will result in damage getting confused when the
drawables get changed around.
- Fix wrapping of GC ops/funcs according to policy described in bug #1045.
- Remove ValidateGC/ValidatePictures on the redirected drawables/pictures
-- it's not needed, and DDXs shouldn't be seeing redirected drawables
in render or GC ops/funcs when cw is running.
- Mark all GC/Picture state as dirty when moving from redirected to
non-redirected, since it hadn't been passed down in Change* or
Validate* while redirected.
- Remove CreatePicture wrapper that didn't do anything.
- Comment on why AddTraps wrapper isn't needed.
Xnest was half-using midispcur and doing a bad job of it. Replace all of
that code with mipointer which does a lot of the work.
Support DDXen which don't provide GetWindowPixmap, or which return NULL for
the root pixmap.
Replace miSprite implementation with Damage-based one. Otherwise damage and
misprite conflict causing looping.
Change pScreen usage around a bit to eliminate warnings
the flagged bits from a source picture. Approved in principle by
keithp.
- Use CopyPicture and SetTransform to update most of the backing picture's
state in the composite wrapper. Filters are still missing.
- Don't allocate a picture private, now that we calculate clipping properly
and don't need the serialNumber or stateChanges.
- Use the format of the source pixmap rather than generating the format
from the window's visual.
- Wrap the rest of the Render primitives that were stubbed out before.
list changes.
- Use FillTiled instead of FillSolid for painting tiled border/background
pixmaps, and don't needlessly change the scratch GC's defaults.
- Use the preferred dixChangeGC instead of DoChangeGC.
- Simplify a silly loop and clean up a couple of comments.
appears stable in limited testing.
- Allocate the picture private, avoiding segfault.
- Wrap PaintWindow to draw the background/border to the backing pixmap
(based on Deron Johnson's comptran.c).
- Set the x_off/y_off returns to translate coordinates properly.
- Don't bother allocating temporary areas for the modified coordinates.
Layers above are responsible for handling lower layers changing the
arguments, so cw doesn't have to worry about it. mibstore.c has to do
the allocation because it calls down twice (front buffer and backing
store). (Suggested by keithp)
- Handle the mode argument to PolyPoint, Polylines, and FillPolygon.
- Remove some dead elements in the cw privates.
- Kill a prototype warning in compinit.c by adding the cw.h header.
has several issues, including:
- CopyWindow and PaintWindow wrappers missing (will be done soon)
- Some segfaults seen in the Render wrappers.
- Xprt server build breaks with Composite.
- DDXs must be recompiled for Composite due to VisualRec size change.
- Composite bugs pointed out by Deron Johnson in email.
Also, reorder XFixes initialization according to comments by Keith which
are also in xserver CVS.
- Fix launch of X clients by double clicking in the Finder when there is a
space in the path (Torrey T. Lyons).
- Interpret scroll wheel mouse events correctly when shift is held down
(Benjamin Burke).
- Add option to always use Mac command key equivalents (John Harper and
Torrey T. Lyons).
- Add support for dynamic screen configuration changes in rootless mode
(John Harper and Torrey T. Lyons).
- Add documentation on generic rootless layer (Torrey T. Lyons).
Move extern function declarations to window.h
Cleaned up code since client's saveSet is no longer defined as a pointer*
Added externs back in
Change #if to #ifdef to fix compiler warning
Add function declarations that were inadvertently removed by previous check
in
Disable extensions that are not (yet) supported by DMX