~amaranth/compiz/no_wrapper

« back to all changes in this revision

Viewing changes to debian/patches/060_move_checks_to_compiz.patch

  • Committer: Travis Watkins
  • Date: 2009-11-03 13:44:12 UTC
  • Revision ID: amaranth@ubuntu.com-20091103134412-3lngzwswjffh2si8
added max texture size check

Show diffs side-by-side

added added

removed removed

Lines of Context:
1
1
Index: compiz-0.8.4/src/main.c
2
2
===================================================================
3
 
--- compiz-0.8.4.orig/src/main.c        2009-09-12 03:45:06.000000000 -0500
4
 
+++ compiz-0.8.4/src/main.c     2009-11-01 11:19:32.474850983 -0600
 
3
--- compiz-0.8.4.orig/src/main.c        2009-11-03 07:39:05.837283646 -0600
 
4
+++ compiz-0.8.4/src/main.c     2009-11-03 07:39:20.767284176 -0600
5
5
@@ -74,6 +74,13 @@
6
6
 
7
7
 CompMetadata coreMetadata;
132
132
 
133
133
Index: compiz-0.8.4/src/screen.c
134
134
===================================================================
135
 
--- compiz-0.8.4.orig/src/screen.c      2009-10-10 22:14:20.000000000 -0500
136
 
+++ compiz-0.8.4/src/screen.c   2009-11-01 11:15:33.634748818 -0600
 
135
--- compiz-0.8.4.orig/src/screen.c      2009-11-03 07:39:05.847296790 -0600
 
136
+++ compiz-0.8.4/src/screen.c   2009-11-03 07:39:20.767284176 -0600
137
137
@@ -1722,7 +1722,7 @@
138
138
     Window              *children;
139
139
     unsigned int        nchildren;
197
197
        s->textureNonPowerOfTwo = 1;
198
198
Index: compiz-0.8.4/src/texture.c
199
199
===================================================================
200
 
--- compiz-0.8.4.orig/src/texture.c     2009-09-01 00:38:22.000000000 -0500
201
 
+++ compiz-0.8.4/src/texture.c  2009-11-01 11:15:33.634748818 -0600
 
200
--- compiz-0.8.4.orig/src/texture.c     2009-11-03 07:39:05.857274944 -0600
 
201
+++ compiz-0.8.4/src/texture.c  2009-11-03 07:39:53.717381188 -0600
202
202
@@ -33,6 +33,8 @@
203
203
 
204
204
 #include <compiz-core.h>
208
208
 static CompMatrix _identity_matrix = {
209
209
     1.0f, 0.0f,
210
210
     0.0f, 1.0f,
211
 
@@ -250,7 +252,7 @@
 
211
@@ -244,13 +246,21 @@
 
212
     CompFBConfig *config = &screen->glxPixmapFBConfigs[depth];
 
213
     int          attribs[7], i = 0;
 
214
 
 
215
+    if (width > screen->maxTextureSize || height > screen->maxTextureSize)
 
216
+    {
 
217
+       compLogMessage ("core", CompLogLevelWarn,
 
218
+                       "Exceeded max texture size");
 
219
+
 
220
+       launchFallbackWM ();
 
221
+    }
 
222
+
 
223
     if (!config->fbConfig)
 
224
     {
 
225
        compLogMessage ("core", CompLogLevelWarn,
212
226
                        "No GLXFBConfig for depth %d",
213
227
                        depth);
214
228
 
217
231
     }
218
232
 
219
233
     attribs[i++] = GLX_TEXTURE_FORMAT_EXT;
220
 
@@ -295,7 +297,7 @@
 
234
@@ -295,7 +305,7 @@
221
235
        compLogMessage ("core", CompLogLevelWarn,
222
236
                        "glXCreatePixmap failed");
223
237
 
226
240
     }
227
241
 
228
242
     if (!target)
229
 
@@ -345,7 +347,7 @@
 
243
@@ -345,7 +355,7 @@
230
244
        (*screen->destroyPixmap) (screen->display->display, texture->pixmap);
231
245
        texture->pixmap = None;
232
246