[gtk+/wip/baedert/gl: 9/11] gl renderer: Properly delete all shader programs
- From: Timm Bäder <baedert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gtk+/wip/baedert/gl: 9/11] gl renderer: Properly delete all shader programs
- Date: Fri, 29 Dec 2017 05:00:04 +0000 (UTC)
commit e0436b3d5974520c774951b7e139a6d56e60f83d
Author: Timm Bäder <mail baedert org>
Date: Fri Dec 29 05:31:49 2017 +0100
gl renderer: Properly delete all shader programs
gsk/gl/gskglrenderer.c | 10 +++-------
1 files changed, 3 insertions(+), 7 deletions(-)
---
diff --git a/gsk/gl/gskglrenderer.c b/gsk/gl/gskglrenderer.c
index cbaff88..5a5594a 100644
--- a/gsk/gl/gskglrenderer.c
+++ b/gsk/gl/gskglrenderer.c
@@ -1869,6 +1869,7 @@ static void
gsk_gl_renderer_unrealize (GskRenderer *renderer)
{
GskGLRenderer *self = GSK_GL_RENDERER (renderer);
+ guint i;
if (self->gl_context == NULL)
return;
@@ -1880,13 +1881,8 @@ gsk_gl_renderer_unrealize (GskRenderer *renderer)
*/
g_array_set_size (self->render_ops, 0);
-
- glDeleteProgram (self->blend_program.id);
- glDeleteProgram (self->blit_program.id);
- glDeleteProgram (self->color_program.id);
- glDeleteProgram (self->coloring_program.id);
- glDeleteProgram (self->color_matrix_program.id);
- glDeleteProgram (self->linear_gradient_program.id);
+ for (i = 0; i < GL_N_PROGRAMS; i ++)
+ glDeleteProgram (self->programs[i].id);
gsk_gl_renderer_destroy_buffers (self);
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]