E_Alpha_Mask_Rect: Do not force update if pixmap of ec does not have buffer 53/317253/1
authorChangyeon Lee <cyeon.lee@samsung.com>
Fri, 27 Dec 2024 07:07:42 +0000 (16:07 +0900)
committerchangyeon lee <cyeon.lee@samsung.com>
Fri, 27 Dec 2024 08:59:31 +0000 (08:59 +0000)
eglImage is destroyed in e_comp_object_native_surface_set(FALSE)
and the force update fails becuase the pixmap of ec does not have a buffer.
so the frame of ec is in a show state, but since the buffer of ec is not set,
garbage may be displayed on the screen.

Change-Id: I17fd5552fbc5e5691c39bf3bb0434844b876b3de

src/bin/compmgr/e_alpha_mask_rect.c

index 10a55d1ba290e2f0aea02fe0cfda08de44f41c2a..526894fcbf1a692b9fe1d2ae8b010bb15f5d802d 100644 (file)
@@ -251,11 +251,14 @@ e_alpha_mask_rect_create(E_Client *ec)
     * set before, changing alpha value can't be applied to egl image.
     */
    // TODO : view
-   e_comp_object_native_surface_set(ec->frame, EINA_FALSE);
-   e_pixmap_image_refresh(ec->pixmap);
-   e_view_client_damage(view_client, 0, 0, ec->w, ec->h);
-   e_view_client_dirty(view_client);
-   e_view_client_render(view_client);
+   if (e_pixmap_resource_get(ec->pixmap))
+     {
+        e_comp_object_native_surface_set(ec->frame, EINA_FALSE);
+        e_pixmap_image_refresh(ec->pixmap);
+        e_view_client_damage(view_client, 0, 0, ec->w, ec->h);
+        e_view_client_dirty(view_client);
+        e_view_client_render(view_client);
+     }
 
    e_comp_wl_subsurface_restack(ec);
    e_alpha_mask_rect_restack(rect);