On Wed 11 May 2016, Kristian Høgsberg wrote:
> From: Kristian Høgsberg Kristensen <kristian.h.kristen...@intel.com>
> 
> ---
>  src/mesa/drivers/dri/i965/intel_mipmap_tree.c |  3 ++
>  src/mesa/drivers/dri/i965/intel_mipmap_tree.h |  5 +++
>  src/mesa/drivers/dri/i965/intel_tex_image.c   | 49 
> ++++++++++++++++++++++++++-
>  src/mesa/drivers/dri/i965/intel_tex_obj.h     |  2 ++
>  4 files changed, 58 insertions(+), 1 deletion(-)

Everything in this patch looks good to me, except...

> diff --git a/src/mesa/drivers/dri/i965/intel_tex_obj.h 
> b/src/mesa/drivers/dri/i965/intel_tex_obj.h
> index 750e4c3..ad78570 100644
> --- a/src/mesa/drivers/dri/i965/intel_tex_obj.h
> +++ b/src/mesa/drivers/dri/i965/intel_tex_obj.h
> @@ -58,6 +58,8 @@ struct intel_texture_object
>      * since the mt is shared across views with differing formats.
>      */
>     mesa_format _Format;
> +
> +   struct __DRIimageRec *dri_image;
>  };

You don't use this field until patch 9, so it should probably be rebased
into that patch.

But... it seems messy that intel_texture_object links to a DRI object.
If any object in i965 would have a need to do that, it would be
intel_renderbuffer; but intel_renderbuffer doesn't. Since
intel_renderbuffer doesn't link to a DRI object, it's weird that
intel_texture_object does.

Based on how it's used in patch 9, I think it suffices to add an
intel_image_format to intel_texture_object instead of an DRIImage.
_______________________________________________
mesa-dev mailing list
mesa-dev@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/mesa-dev

Reply via email to