[maemo-commits] [maemo-commits] r18790 - in projects/haf/trunk/clutter0.8: clutter clutter/eglx clutter/x11 debian
From: subversion at stage.maemo.org subversion at stage.maemo.orgDate: Thu Jun 25 16:42:03 EEST 2009
- Previous message: [maemo-commits] r18789 - in projects/haf/trunk/gtk+: . gtk
- Next message: [maemo-commits] r18791 - projects/haf/trunk/clutter0.8/debian
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]
Author: gw Date: 2009-06-25 16:41:51 +0300 (Thu, 25 Jun 2009) New Revision: 18790 Modified: projects/haf/trunk/clutter0.8/clutter/clutter-texture.c projects/haf/trunk/clutter0.8/clutter/eglx/clutter-eglx-texture-pixmap.c projects/haf/trunk/clutter0.8/clutter/x11/clutter-x11-texture-pixmap.c projects/haf/trunk/clutter0.8/debian/changelog Log: Gordon: Fixes: NB#124464 - Hildon-desktop crash * clutter/clutter-texture.c: Check for COGL_INVALID_HANDLE texture (other functions in clutter-texture checked, but not _paint) * clutter/eglx/clutter-eglx-texture-pixmap.c: Check for COGL_INVALID_HANDLE texture before rendering shapes. * clutter/x11/clutter-x11-texture-pixmap.c: Check for COGL_INVALID_HANDLE before rendering, alongside the surface (It is possible to have a surface, but no cogl_texture). Fix texture leak if cogl_texture_new_from_foreign failed. Remove red-bordered warning shape (we now render nothing if we were unable to get a texture). Modified: projects/haf/trunk/clutter0.8/clutter/clutter-texture.c =================================================================== --- projects/haf/trunk/clutter0.8/clutter/clutter-texture.c 2009-06-25 12:08:42 UTC (rev 18789) +++ projects/haf/trunk/clutter0.8/clutter/clutter-texture.c 2009-06-25 13:41:51 UTC (rev 18790) @@ -577,6 +577,7 @@ "painting texture '%s'", clutter_actor_get_name (self) ? clutter_actor_get_name (self) : "unknown"); + col.alpha = clutter_actor_get_paint_opacity (self); cogl_color (&col); @@ -587,6 +588,9 @@ x_1, y_1, x_2, y_2, clutter_actor_get_opacity (self)); + if (priv->texture == COGL_INVALID_HANDLE) + return; + if (priv->repeat_x && priv->width > 0) t_w = CFX_QDIV (CLUTTER_INT_TO_FIXED (x_2 - x_1), CLUTTER_INT_TO_FIXED (priv->width)); Modified: projects/haf/trunk/clutter0.8/clutter/eglx/clutter-eglx-texture-pixmap.c =================================================================== --- projects/haf/trunk/clutter0.8/clutter/eglx/clutter-eglx-texture-pixmap.c 2009-06-25 12:08:42 UTC (rev 18789) +++ projects/haf/trunk/clutter0.8/clutter/eglx/clutter-eglx-texture-pixmap.c 2009-06-25 13:41:51 UTC (rev 18790) @@ -388,6 +388,9 @@ width, height, format)) { g_debug ("%s: Unable to create cogl texture", __FUNCTION__); + + glDeleteTextures (1, &priv->texture_id); + CLUTTER_NOTE (TEXTURE, "Falling back to X11 manual mechanism"); priv->use_fallback = TRUE; return; @@ -707,7 +710,9 @@ "pixmap-height", &pixmap_height, NULL); - if (priv->egl_surface == EGL_NO_SURFACE) + if (priv->egl_surface == EGL_NO_SURFACE || + clutter_texture_get_cogl_texture(CLUTTER_TEXTURE(actor)) == + COGL_INVALID_HANDLE) { /* guint window; @@ -718,7 +723,9 @@ __FUNCTION__, name ? name : "null", pixmap, window, pixmap_width, pixmap_height, pixmap_depth);*/ - clutter_eglx_texture_pixmap_paint_fail (actor); + + /* No longer paint red fail rectangle - it just annoys users */ + //clutter_eglx_texture_pixmap_paint_fail (actor); return; } Modified: projects/haf/trunk/clutter0.8/clutter/x11/clutter-x11-texture-pixmap.c =================================================================== --- projects/haf/trunk/clutter0.8/clutter/x11/clutter-x11-texture-pixmap.c 2009-06-25 12:08:42 UTC (rev 18789) +++ projects/haf/trunk/clutter0.8/clutter/x11/clutter-x11-texture-pixmap.c 2009-06-25 13:41:51 UTC (rev 18790) @@ -1451,6 +1451,8 @@ t_h = CFX_ONE; cogl_texture = clutter_texture_get_cogl_texture(CLUTTER_TEXTURE(self)); + if (cogl_texture == COGL_INVALID_HANDLE) + return; /* so now we go through our shapes and render */ for (shape = priv->shapes; shape; shape = shape->next) Modified: projects/haf/trunk/clutter0.8/debian/changelog =================================================================== --- projects/haf/trunk/clutter0.8/debian/changelog 2009-06-25 12:08:42 UTC (rev 18789) +++ projects/haf/trunk/clutter0.8/debian/changelog 2009-06-25 13:41:51 UTC (rev 18790) @@ -1,6 +1,16 @@ clutter (0.8.2-0maemo38~unreleased) unstable; urgency=low - * foo + Gordon: + Fixes: NB#124464 - Hildon-desktop crash + * clutter/clutter-texture.c: Check for COGL_INVALID_HANDLE texture + (other functions in clutter-texture checked, but not _paint) + * clutter/eglx/clutter-eglx-texture-pixmap.c: Check for COGL_INVALID_HANDLE + texture before rendering shapes. + * clutter/x11/clutter-x11-texture-pixmap.c: Check for COGL_INVALID_HANDLE + before rendering, alongside the surface (It is possible to have a surface, + but no cogl_texture). Fix texture leak if cogl_texture_new_from_foreign + failed. Remove red-bordered warning shape (we now render nothing if we + were unable to get a texture). -- Gordon Williams <gordon.williams at collabora.co.uk> Mon, 22 Jun 2009 10:29:47 +0300
- Previous message: [maemo-commits] r18789 - in projects/haf/trunk/gtk+: . gtk
- Next message: [maemo-commits] r18791 - projects/haf/trunk/clutter0.8/debian
- Messages sorted by: [ date ] [ thread ] [ subject ] [ author ]