[prev in list] [next in list] [prev in thread] [next in thread] 

List:       cairo-commit
Subject:    [cairo-commit] src/cairo-gl-gradient.c
From:       ickle () kemper ! freedesktop ! org (Chris Wilson)
Date:       2012-12-01 17:10:43
Message-ID: 20121201171043.81F641004A () kemper ! freedesktop ! org
[Download RAW message or body]

 src/cairo-gl-gradient.c |    2 ++
 1 file changed, 2 insertions(+)

New commits:
commit 9f43f096b22a13f02d638b86b4460c7ed66d3c96
Author: Henry Song <henry.song@samsung.com>
Date:   Sat Dec 1 17:08:56 2012 +0000

    gl: Flush context upon evicting a gradient
    
    As the random selection of a gradient can possible destroy the currently
    active gradient, we need to flush the context in order to flush any
    references to the texture before deletion.

diff --git a/src/cairo-gl-gradient.c b/src/cairo-gl-gradient.c
index 1c1f972..ac32921 100644
--- a/src/cairo-gl-gradient.c
+++ b/src/cairo-gl-gradient.c
@@ -328,6 +328,8 @@ _cairo_gl_gradient_destroy (cairo_gl_gradient_t *gradient)
 	return;
 
     if (_cairo_gl_context_acquire (gradient->device, &ctx) == CAIRO_STATUS_SUCCESS) {
+	/* The gradient my still be active in the last operation, so flush */
+	_cairo_gl_composite_flush (ctx);
         glDeleteTextures (1, &gradient->tex);
         ignore = _cairo_gl_context_release (ctx, CAIRO_STATUS_SUCCESS);
     }
_______________________________________________
cairo-commit mailing list
cairo-commit@lists.cairographics.org
http://lists.cairographics.org/mailman/listinfo/cairo-commit
[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic