Hi Pekka,

If we remove the view from scenegraph, application will be blocked. Because it 
is not getting any surface frame events.
It is not OK to block unexpected applications. Especially if the application is 
sending output of a camera or digital TV, weston should always get latest 
buffer from the application.

You might say that camera application can use wl_display_sync instead 
wl_surface_frame. This would cause stutter and frame drop issues, because 
camera stream and display are not in synch.

I know that I have to modify weston_compositor_pick_view(). I will send a patch 
if this one is accepted.

Best regards

Emre Ucan
Engineering Software Base (ADITG/ESB)

Tel. +49 5121 49 6937

> -----Original Message-----
> From: Pekka Paalanen [mailto:ppaala...@gmail.com]
> Sent: Donnerstag, 19. April 2018 11:12
> To: Ucan, Emre (ADITG/ESB)
> Cc: wayland-devel@lists.freedesktop.org
> Subject: Re: [PATCH weston] libweston: don't accumulate damage from
> transparent views
> 
> On Wed, 18 Apr 2018 15:44:26 +0200
> Emre Ucan <eu...@de.adit-jv.com> wrote:
> 
> > If view is set to be entirely transparent,
> > there is no need to accumulate its damage.
> >
> > This is an important optimization for
> > using view transparency. Because otherwise
> > transparent views are rendered like an
> > opaque view, and their pixel values
> > are set to 0 in fragment shader.
> >
> > Signed-off-by: Emre Ucan <eu...@de.adit-jv.com>
> > ---
> >  libweston/compositor.c | 5 ++++-
> >  1 file changed, 4 insertions(+), 1 deletion(-)
> >
> > diff --git a/libweston/compositor.c b/libweston/compositor.c
> > index a9de4ac..4bcf120 100644
> > --- a/libweston/compositor.c
> > +++ b/libweston/compositor.c
> > @@ -2122,7 +2122,10 @@ compositor_accumulate_damage(struct
> weston_compositor *ec)
> >             pixman_region32_init(&opaque);
> >
> >             wl_list_for_each(ev, &ec->view_list, link) {
> > -                   if (ev->plane != plane)
> > +                   /* If view is set to be entirely transparent,
> > +                    * there is no need to accumulate its damage.
> > +                    */
> > +                   if (ev->plane != plane || ev->alpha == 0.0f)
> >                             continue;
> >
> >                     view_accumulate_damage(ev, &opaque);
> 
> Hi,
> 
> why this instead of removing the whole view from the scenegraph?
> 
> You would also need to exclude the view in
> weston_compositor_pick_view(), and adding these rendering special cases
> around doesn't feel very good to me.
> 
> 
> Thanks,
> pq
_______________________________________________
wayland-devel mailing list
wayland-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/wayland-devel

Reply via email to