[beryl-commits] compiz mirror: Changes to 'master' (05bbdb545b6885b35fa87e41f78ddba69e5356f2)

compiz at server.beryl-project.org compiz at server.beryl-project.org
Fri Jun 1 02:33:15 CEST 2007


New commits:
commit 05bbdb545b6885b35fa87e41f78ddba69e5356f2
Author: David Reveman <davidr at novell.com>
Date:   Thu May 31 20:25:47 2007 -0400

    Track output changes.

commit 9631928833ff76ffa1d3d46535cf8c3ab2758fcc
Merge: b2f47aa2a1c50db237635324799883d08e166e77 97a4a6c90a935088e75c73371a054b5c4b8d5d10
Author: David Reveman <davidr at novell.com>
Date:   Thu May 31 20:06:55 2007 -0400

    Merge branch 'master' of git+ssh://git.freedesktop.org/git/xorg/app/compiz

commit b2f47aa2a1c50db237635324799883d08e166e77
Merge: 5ca24d1b4f15c70d2c6073b910b8fdd8187941e5 0a1e76975d0dd55cb788db2c90a088c1125cb2a0
Author: David Reveman <davidr at novell.com>
Date:   Thu May 31 17:46:24 2007 -0400

    Merge branch 'master' of git+ssh://git.freedesktop.org/git/xorg/app/compiz

commit 5ca24d1b4f15c70d2c6073b910b8fdd8187941e5
Merge: 436c0e9d8da504a4b6d2947b1ea7de6daa3f20f9 de76d335a4083cf9fce37465e264b5d458c38133
Author: David Reveman <davidr at novell.com>
Date:   Thu May 31 13:58:06 2007 -0400

    Merge branch 'master' of git+ssh://git.freedesktop.org/git/xorg/app/compiz

commit 436c0e9d8da504a4b6d2947b1ea7de6daa3f20f9
Author: David Reveman <davidr at novell.com>
Date:   Thu May 31 13:40:34 2007 -0400

    Remove whitespace.

commit 0e02a98ade9aeb1d374a46931e7fdc735a7e750d
Author: David Reveman <davidr at novell.com>
Date:   Thu May 31 11:54:53 2007 -0400

    Fix byte order check in imageBufferToTexture.


 plugins/zoom.c |   21 +++++++++++++--------
 src/texture.c  |    6 +++---
 2 files changed, 16 insertions(+), 11 deletions(-)


Modified: compiz/plugins/zoom.c
===================================================================
--- compiz/plugins/zoom.c
+++ compiz/plugins/zoom.c
@@ -250,28 +250,33 @@ zoomPaintOutput (CompScreen		 *s,
 		 const ScreenPaintAttrib *sAttrib,
 		 const CompTransform	 *transform,
 		 Region		         region,
-		 int			 output,
+		 CompOutput		 *output,
 		 unsigned int		 mask)
 {
     CompTransform zTransform = *transform;
     Bool	  status;
+    int		  i, outputNum = -1;
 
     ZOOM_SCREEN (s);
 
-    if (zs->zoomed & (1 << output))
+    for (i = 0; i < s->nOutputDev; i++)
+	if (output == &s->outputDev[i])
+	    outputNum = i;
+
+    if (outputNum >= 0 && (zs->zoomed & (1 << outputNum)))
     {
 	int	saveFilter;
 	ZoomBox	box;
 	float	scale, x, y, x1, y1;
-	float	oWidth = s->outputDev[output].width;
-	float	oHeight = s->outputDev[output].height;
+	float	oWidth = output->width;
+	float	oHeight = output->height;
 
 	mask &= ~PAINT_SCREEN_REGION_MASK;
 
-	zoomGetCurrentZoom (s, output, &box);
+	zoomGetCurrentZoom (s, outputNum, &box);
 
-	x1 = box.x1 - s->outputDev[output].region.extents.x1;
-	y1 = box.y1 - s->outputDev[output].region.extents.y1;
+	x1 = box.x1 - output->region.extents.x1;
+	y1 = box.y1 - output->region.extents.y1;
 
 	scale = oWidth / (box.x2 - box.x1);
 
@@ -288,7 +293,7 @@ zoomPaintOutput (CompScreen		 *s,
 
 	saveFilter = s->filter[SCREEN_TRANS_FILTER];
 
-	if ((zs->zoomOutput != output || !zs->adjust) && scale > 3.9f)
+	if ((zs->zoomOutput != outputNum || !zs->adjust) && scale > 3.9f)
 	    s->filter[SCREEN_TRANS_FILTER] = COMP_TEXTURE_FILTER_FAST;
 
 	UNWRAP (zs, s, paintOutput);

Modified: compiz/src/texture.c
===================================================================
--- compiz/src/texture.c
+++ compiz/src/texture.c
@@ -138,7 +138,7 @@ imageToTexture (CompScreen   *screen,
 
     glBindTexture (texture->target, texture->name);
 
-    glTexImage2D (texture->target, 0, GL_RGBA, width, height, 0, 
+    glTexImage2D (texture->target, 0, GL_RGBA, width, height, 0,
 		  format, type, data);
 
     texture->filter = GL_NEAREST;
@@ -168,10 +168,10 @@ imageBufferToTexture (CompScreen   *screen,
 {
 #if IMAGE_BYTE_ORDER == MSBFirst
     return imageToTexture (screen, texture, image, width, height,
-			   GL_BGRA, GL_UNSIGNED_BYTE);
+			   GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV);
 #else
     return imageToTexture (screen, texture, image, width, height,
-			   GL_BGRA, GL_UNSIGNED_INT_8_8_8_8_REV);
+			   GL_BGRA, GL_UNSIGNED_BYTE);
 #endif
 }
 



More information about the commits mailing list