<html dir="ltr">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">
<style id="owaParaStyle" type="text/css">P {margin-top:0;margin-bottom:0;}</style>
</head>
<body ocsi="0" fpstyle="1">
<div style="direction: ltr;font-family: Tahoma;color: #000000;font-size: 10pt;">commit 9890479b7edc17c3d558682354a0a37d193ff432<br>
Author: Henry Song <henry.song@samsung.com><br>
Date:   Tue Jul 24 15:07:19 2012 -0700<br>
<br>
    gl: translate proper matrix depending up type of gl_operand<br>
<br>
fix bug in test case radial-gradient-mask-source<br>
<br>
diff --git a/src/cairo-gl-operand.c b/src/cairo-gl-operand.c<br>
index 033d45e..40afec4 100644<br>
--- a/src/cairo-gl-operand.c<br>
+++ b/src/cairo-gl-operand.c<br>
@@ -364,8 +364,24 @@ void<br>
 _cairo_gl_operand_translate (cairo_gl_operand_t *operand,<br>
                  double tx, double ty)<br>
 {<br>
-    operand->texture.attributes.matrix.x0 -= tx * operand->texture.attributes.matrix.xx;<br>
-    operand->texture.attributes.matrix.y0 -= ty * operand->texture.attributes.matrix.yy;<br>
+    switch (operand->type) {<br>
+    case CAIRO_GL_OPERAND_TEXTURE:<br>
+    operand->texture.attributes.matrix.x0 -= tx * operand->texture.attributes.matrix.xx;<br>
+    operand->texture.attributes.matrix.y0 -= ty * operand->texture.attributes.matrix.yy;<br>
+    break;<br>
+    case CAIRO_GL_OPERAND_LINEAR_GRADIENT:<br>
+    case CAIRO_GL_OPERAND_RADIAL_GRADIENT_A0:<br>
+    case CAIRO_GL_OPERAND_RADIAL_GRADIENT_NONE:<br>
+    case CAIRO_GL_OPERAND_RADIAL_GRADIENT_EXT:<br>
+    operand->gradient.m.x0 -= tx * operand->gradient.m.xx;<br>
+    operand->gradient.m.y0 -= ty * operand->gradient.m.yy;<br>
+    break;<br>
+    case CAIRO_GL_OPERAND_NONE:<br>
+    case CAIRO_GL_OPERAND_CONSTANT:<br>
+    case CAIRO_GL_OPERAND_COUNT:<br>
+    default:<br>
+    break;<br>
+    }<br>
 }<br>
 <br>
 static cairo_status_t<br>
</div>
</body>
</html>