aboutsummaryrefslogtreecommitdiff
path: root/nx-X11/programs
diff options
context:
space:
mode:
authorUlrich Sibiller <uli42@gmx.de>2021-03-29 23:07:18 +0200
committerMike Gabriel <mike.gabriel@das-netzwerkteam.de>2021-06-08 08:23:35 +0200
commit555cbcb325887b3e19bf7ffc3890f60485681e54 (patch)
treeb88aa4b39c18377a7b6ed8fe7b77283f18405293 /nx-X11/programs
parent2739d0868f849a186f7b06cb0032ee0d2c599532 (diff)
downloadnx-libs-555cbcb325887b3e19bf7ffc3890f60485681e54.tar.gz
nx-libs-555cbcb325887b3e19bf7ffc3890f60485681e54.tar.bz2
nx-libs-555cbcb325887b3e19bf7ffc3890f60485681e54.zip
nxagent: add command line switch to enable composite
We have it disabled by default but there hasn't been a way to enable it.
Diffstat (limited to 'nx-X11/programs')
-rw-r--r--nx-X11/programs/Xserver/composite/compext.c6
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Args.c11
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/Options.c2
-rw-r--r--nx-X11/programs/Xserver/hw/nxagent/man/nxagent.14
-rw-r--r--nx-X11/programs/Xserver/os/utils.c4
5 files changed, 20 insertions, 7 deletions
diff --git a/nx-X11/programs/Xserver/composite/compext.c b/nx-X11/programs/Xserver/composite/compext.c
index 8513c6d73..a63b02075 100644
--- a/nx-X11/programs/Xserver/composite/compext.c
+++ b/nx-X11/programs/Xserver/composite/compext.c
@@ -39,6 +39,7 @@ static DevPrivateKeyRec CompositeClientPrivateKeyRec;
#define CompositeClientPrivateKey (&CompositeClientPrivateKeyRec)
#else /* !defined(NXAGENT_SERVER) */
+#include "../hw/nxagent/Options.h"
static int CompositeClientPrivIndex = -1;
#endif /* !defined(NXAGENT_SERVER) */
@@ -623,6 +624,11 @@ CompositeExtensionInit (void)
/* Assume initialization is going to fail */
noCompositeExtension = TRUE;
+#ifdef NXAGENT_SERVER
+ if (!nxagentOption(Composite))
+ return;
+#endif
+
fprintf(stderr, "COMPOSITE: trying to initialize extension.\n");
for (s = 0; s < screenInfo.numScreens; s++) {
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Args.c b/nx-X11/programs/Xserver/hw/nxagent/Args.c
index 9ecf2fb8a..f96c2e238 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Args.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Args.c
@@ -737,6 +737,14 @@ int ddxProcessArgument(int argc, char *argv[], int i)
return 1;
}
+ /* the composite extension is disabled by default so we provide a
+ way to enable it */
+ if (!strcmp(argv[i], "-composite"))
+ {
+ nxagentChangeOption(Composite, True);
+ return 1;
+ }
+
if (!strcmp(argv[i], "-nodamage"))
{
nxagentChangeOption(UseDamage, False);
@@ -2106,7 +2114,8 @@ void ddxUseMsg(void)
ErrorF("-sync synchronize with the real server\n");
#ifdef RENDER
ErrorF("-norender disable the use of the render extension\n");
- ErrorF("-nocomposite disable the use of the composite extension\n");
+ ErrorF("-nocomposite disable the use of the composite extension (default)\n");
+ ErrorF("-composite enable the use of the composite extension\n");
#endif
ErrorF("-nopersistent disable disconnection/reconnection to the X display on SIGHUP\n");
ErrorF("-noshmem disable use of shared memory extension\n");
diff --git a/nx-X11/programs/Xserver/hw/nxagent/Options.c b/nx-X11/programs/Xserver/hw/nxagent/Options.c
index afc6899e3..be6e5d5e1 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/Options.c
+++ b/nx-X11/programs/Xserver/hw/nxagent/Options.c
@@ -129,7 +129,7 @@ void nxagentInitOptions(void)
nxagentOptions.DisplayBuffer = UNDEFINED;
nxagentOptions.DisplayCoalescence = 0;
- nxagentOptions.Composite = True;
+ nxagentOptions.Composite = False;
nxagentOptions.IgnoreVisibility = False;
diff --git a/nx-X11/programs/Xserver/hw/nxagent/man/nxagent.1 b/nx-X11/programs/Xserver/hw/nxagent/man/nxagent.1
index ebc528d37..74349cda7 100644
--- a/nx-X11/programs/Xserver/hw/nxagent/man/nxagent.1
+++ b/nx-X11/programs/Xserver/hw/nxagent/man/nxagent.1
@@ -506,8 +506,8 @@ nx/nx option on session resumption
.B \-norender
disable the use of the render extension
.TP 8
-.B \-nocomposite
-disable the use of the composite extension
+.B \-nocomposite/-composite
+disable/enable the use of the composite extension (default ist disabled)
.TP 8
.B \-nopersistent
disable disconnection/reconnection to the X display on
diff --git a/nx-X11/programs/Xserver/os/utils.c b/nx-X11/programs/Xserver/os/utils.c
index 853a33736..c788fae01 100644
--- a/nx-X11/programs/Xserver/os/utils.c
+++ b/nx-X11/programs/Xserver/os/utils.c
@@ -146,9 +146,7 @@ Bool noTestExtensions;
Bool noBigReqExtension = FALSE;
#endif
#ifdef COMPOSITE
-/* COMPOSITE is disabled by default for now until the
- * interface is stable */
-Bool noCompositeExtension = TRUE;
+Bool noCompositeExtension = FALSE;
#endif
#ifdef DAMAGE
Bool noDamageExtension = FALSE;