[Mesa-dev] [v8 9/9] i965: enable image external sampling for imported dma-buffers

Pohjolainen, Topi topi.pohjolainen at intel.com
Thu Jul 24 02:21:10 PDT 2014


On Wed, Jun 18, 2014 at 03:11:52PM -0700, Anuj Phogat wrote:
> On Wed, Jul 24, 2013 at 5:06 PM, Chad Versace
> <chad.versace at linux.intel.com> wrote:
> > This patch is
> > Reviewed-by: Chad Versace <chad.versace at linux.intel.com>
> > with the understanding that it depends on previous patches.
> >
> > I'll begin reviewing your Piglit tests now.
> >
> >
> > On 07/24/2013 03:23 AM, Topi Pohjolainen wrote:
> >>
> >> Signed-off-by: Topi Pohjolainen <topi.pohjolainen at intel.com>
> >> ---
> >>   src/mesa/drivers/dri/i965/intel_extensions.c | 1 +
> >>   src/mesa/drivers/dri/i965/intel_tex_image.c  | 7 +++++++
> >>   2 files changed, 8 insertions(+)
> >>
> >> diff --git a/src/mesa/drivers/dri/i965/intel_extensions.c
> >> b/src/mesa/drivers/dri/i965/intel_extensions.c
> >> index 409d40b..655467c 100644
> >> --- a/src/mesa/drivers/dri/i965/intel_extensions.c
> >> +++ b/src/mesa/drivers/dri/i965/intel_extensions.c
> >> @@ -122,6 +122,7 @@ intelInitExtensions(struct gl_context *ctx)
> >>      ctx->Extensions.OES_EGL_image = true;
> >>      ctx->Extensions.OES_draw_texture = true;
> >>      ctx->Extensions.OES_standard_derivatives = true;
> >> +   ctx->Extensions.OES_EGL_image_external = true;
> >>
> >>      if (brw->gen >= 6)
> >>         ctx->Const.GLSLVersion = 140;
> >> diff --git a/src/mesa/drivers/dri/i965/intel_tex_image.c
> >> b/src/mesa/drivers/dri/i965/intel_tex_image.c
> >> index 7d478d1..0f0a27d 100644
> >> --- a/src/mesa/drivers/dri/i965/intel_tex_image.c
> >> +++ b/src/mesa/drivers/dri/i965/intel_tex_image.c
> >> @@ -378,6 +378,13 @@ intel_image_target_texture_2d(struct gl_context *ctx,
> >> GLenum target,
> >>         return;
> >>      }
> >>
> >> +   if (target == GL_TEXTURE_EXTERNAL_OES && !image->dma_buf_imported) {
> >> +      _mesa_error(ctx, GL_INVALID_OPERATION,
> >> +            "glEGLImageTargetTexture2DOES(external target is enabled only
> >> "
> >> +               "for images created with EGL_EXT_image_dma_buf_import");
> >> +      return;
> >> +   }
> >> +
> This condition makes following GLES3 CTS tests to fail:
> egl_image_external.TestTargetTextureValid
> egl_image_external.TestSimple
> 
> Tests pass if we get rid of this error condition.

Chad and I modified the CTS to provide dma-buf based images. Is your suite
built with that? You should be getting alsoe various errors other than these
two with the original.

> 
> >>      /* Disallow depth/stencil textures: we don't have a way to pass the
> >>       * separate stencil miptree of a GL_DEPTH_STENCIL texture through.
> >>       */
> >>
> >
> > _______________________________________________
> > mesa-dev mailing list
> > mesa-dev at lists.freedesktop.org
> > http://lists.freedesktop.org/mailman/listinfo/mesa-dev


More information about the mesa-dev mailing list