[PATCH weston 1/3] gl-renderer: Track the buffer type in gl_surface_state

Pekka Paalanen ppaalanen at gmail.com
Tue Jun 11 04:38:20 PDT 2013


On Fri,  7 Jun 2013 16:52:44 +0300
Ander Conselvan de Oliveira <ander.conselvan.de.oliveira at intel.com>
wrote:

> Checking for gs->num_images for determining the previous buffer type
> when attaching is not reliable. The number of images is never cleared
> in the SHM path, so after a switch from an EGL buffer to SHM, every
> following attach of an SHM buffer will happen with gs->num_images > 0,
> and the code will assume the previous buffer was an EGL one.
> 
> Fix this by adding a buffer_type field to gl_surface_state.
> ---
>  src/gl-renderer.c |   21 +++++++++++++++++----
>  1 file changed, 17 insertions(+), 4 deletions(-)

I like tracking buffer type explicitly, rather than inferring from
num_images.

This series looks ok and seems to work ok from what little testing I
did.


Thanks,
pq


More information about the wayland-devel mailing list