<div dir="ltr"><br><div class="gmail_extra"><br><div class="gmail_quote">On Tue, Feb 24, 2015 at 4:17 PM, Ian Romanick <span dir="ltr"><<a href="mailto:idr@freedesktop.org" target="_blank">idr@freedesktop.org</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex">Series is<br>
<br>
Reviewed-by: Ian Romanick <<a href="mailto:ian.d.romanick@intel.com">ian.d.romanick@intel.com</a>><br>
<br>
Should probably wait for Anuj, Neil, or Jason to respond to patch 2.<br>
They know the code here much better than I.<br><div class="HOEnZb"><div class="h5"></div></div></blockquote><div><br></div><div>Heh... I was waiting for someone else to look at it before I gave an R-B and scarred them off.  I wanted a second set of eyes.  So here's mine now.<br><br></div><div>Reviewed-by: Jason Ekstrand <<a href="mailto:jason.ekstrand@intel.com">jason.ekstrand@intel.com</a>><br><br></div><div>for the series.<br></div><div>--Jason<br></div><div> </div><blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div class="HOEnZb"><div class="h5">
On 02/24/2015 03:20 PM, Laura Ekstrand wrote:<br>
> This moves the line setting immutability for the texture to after<br>
> _mesa_initialize_texture_object so that the initializer function will not<br>
> cancel it out. Moreover, because of the ARB_texture_view extension, immutable<br>
> textures must have NumLayers > 0, or depth will equal (0-1)=0xFFFFFFFF during<br>
> SURFACE_STATE setup, which triggers assertions.<br>
><br>
> v2: Review from Kenneth Graunke:<br>
>    - Include more explanation in the commit message.<br>
>    - Make texture setup bug fixes into a separate patch.<br>
> ---<br>
>  src/mesa/drivers/common/meta_tex_subimage.c | 5 ++++-<br>
>  1 file changed, 4 insertions(+), 1 deletion(-)<br>
><br>
> diff --git a/src/mesa/drivers/common/meta_tex_subimage.c b/src/mesa/drivers/common/meta_tex_subimage.c<br>
> index 68c8273..2d2b9d8 100644<br>
> --- a/src/mesa/drivers/common/meta_tex_subimage.c<br>
> +++ b/src/mesa/drivers/common/meta_tex_subimage.c<br>
> @@ -100,8 +100,11 @@ create_texture_for_pbo(struct gl_context *ctx, bool create_pbo,<br>
>     _mesa_GenTextures(1, tmp_tex);<br>
>     tex_obj = _mesa_lookup_texture(ctx, *tmp_tex);<br>
>     tex_obj->Target = depth > 1 ? GL_TEXTURE_2D_ARRAY : GL_TEXTURE_2D;<br>
> -   tex_obj->Immutable = GL_TRUE;<br>
>     _mesa_initialize_texture_object(ctx, tex_obj, *tmp_tex, GL_TEXTURE_2D);<br>
> +   /* This must be set after _mesa_initialize_texture_object, not before. */<br>
> +   tex_obj->Immutable = GL_TRUE;<br>
> +   /* This is required for interactions with ARB_texture_view. */<br>
> +   tex_obj->NumLayers = 1;<br>
><br>
>     internal_format = _mesa_get_format_base_format(pbo_format);<br>
><br>
><br>
<br>
</div></div><div class="HOEnZb"><div class="h5">_______________________________________________<br>
mesa-dev mailing list<br>
<a href="mailto:mesa-dev@lists.freedesktop.org">mesa-dev@lists.freedesktop.org</a><br>
<a href="http://lists.freedesktop.org/mailman/listinfo/mesa-dev" target="_blank">http://lists.freedesktop.org/mailman/listinfo/mesa-dev</a><br>
</div></div></blockquote></div><br></div></div>