int pitch; /* in pixels */
int height; /* in pixels */
bool y_inverted;
+ bool direct_display;
/* Extension needed for SHM YUV texture */
int offset[3]; /* offset per plane */
gs->buffer_type = BUFFER_TYPE_SHM;
gs->needs_full_upload = true;
gs->y_inverted = true;
+ gs->direct_display = false;
gs->surface = es;
egl_image_unref(gs->images[i]);
gs->num_images = 0;
+ gs->pitch = buffer->width;
+ gs->height = buffer->height;
+ gs->buffer_type = BUFFER_TYPE_EGL;
+ gs->y_inverted = buffer->y_inverted;
+ gs->direct_display = dmabuf->direct_display;
+ surface->is_opaque = dmabuf_is_opaque(dmabuf);
+
/*
* We try to always hold an imported EGLImage from the dmabuf
* to prevent the client from preventing re-imports. But, we also
*
* Here we release the cache reference which has to be final.
*/
+ if (dmabuf->direct_display)
+ return;
+
image = linux_dmabuf_buffer_get_user_data(dmabuf);
/* The dmabuf_image should have been created during the import */
}
gs->shader = image->shader;
- gs->pitch = buffer->width;
- gs->height = buffer->height;
- gs->buffer_type = BUFFER_TYPE_EGL;
- gs->y_inverted = buffer->y_inverted;
- surface->is_opaque = dmabuf_is_opaque(dmabuf);
}
static void
gs->num_textures = 0;
gs->buffer_type = BUFFER_TYPE_NULL;
gs->y_inverted = true;
+ gs->direct_display = false;
es->is_opaque = false;
return;
}
*/
gs->pitch = 1;
gs->y_inverted = true;
+ gs->direct_display = false;
gs->surface = surface;