compiz/compiz_optional-fbo.patch

56 lines
1.6 KiB
Diff
Raw Normal View History

Author: David Nusinow <dnusinow@debian.org>
Description: Add a command-line option for disabling the use of FBOs
This is to work around buggy drivers. Add the --no-fbo option to
command-line to compiz.
Origin: vendor, debian (0.3.6-1)
--- a/include/compiz-core.h
+++ b/include/compiz-core.h
@@ -219,6 +219,7 @@ extern Bool useCow;
extern Bool noDetection;
extern Bool useDesktopHints;
extern Bool onlyCurrentScreen;
+extern Bool noFBO;
extern char **initialPlugins;
extern int nInitialPlugins;
--- a/src/main.c
+++ b/src/main.c
@@ -66,6 +66,7 @@ Bool strictBinding = TRUE;
Bool noDetection = FALSE;
Bool useDesktopHints = FALSE;
Bool onlyCurrentScreen = FALSE;
+Bool noFBO = FALSE;
static Bool debugOutput = FALSE;
#ifdef USE_COW
@@ -87,6 +88,7 @@ usage (void)
"[--keep-desktop-hints] "
"[--loose-binding] "
"[--replace]\n "
+ "[--no-fbo] "
"[--sm-disable] "
"[--sm-client-id ID] "
"[--only-current-screen]\n "
@@ -346,6 +348,10 @@ main (int argc, char **argv)
{
onlyCurrentScreen = TRUE;
}
+ else if (!strcmp (argv[i], "--no-fbo"))
+ {
+ noFBO = TRUE;
+ }
#ifdef USE_COW
else if (!strcmp (argv[i], "--use-root-window"))
--- a/src/screen.c
+++ b/src/screen.c
@@ -2183,7 +2183,7 @@ addScreen (CompDisplay *display,
s->generateMipmap = NULL;
s->fbo = 0;
- if (strstr (glExtensions, "GL_EXT_framebuffer_object"))
+ if (!noFBO && strstr (glExtensions, "GL_EXT_framebuffer_object"))
{
s->genFramebuffers = (GLGenFramebuffersProc)
getProcAddress (s, "glGenFramebuffersEXT");