st/mesa: remove the const qualifier for a few st_sampler_view instances

It will be needed by following commits.

Reviewed-By: Mike Blumenkrantz <michael.blumenkrantz@gmail.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/11428>
This commit is contained in:
Marek Olšák 2021-06-06 05:35:31 -04:00 committed by Marge Bot
parent 4c95370949
commit 8fe705b6b4
2 changed files with 6 additions and 6 deletions

View File

@ -164,14 +164,14 @@ out:
* *
* Performs no additional validation. * Performs no additional validation.
*/ */
const struct st_sampler_view * struct st_sampler_view *
st_texture_get_current_sampler_view(const struct st_context *st, st_texture_get_current_sampler_view(const struct st_context *st,
const struct st_texture_object *stObj) const struct st_texture_object *stObj)
{ {
const struct st_sampler_views *views = p_atomic_read(&stObj->sampler_views); struct st_sampler_views *views = p_atomic_read(&stObj->sampler_views);
for (unsigned i = 0; i < views->count; ++i) { for (unsigned i = 0; i < views->count; ++i) {
const struct st_sampler_view *sv = &views->views[i]; struct st_sampler_view *sv = &views->views[i];
if (sv->view && sv->view->context == st->pipe) if (sv->view && sv->view->context == st->pipe)
return sv; return sv;
} }
@ -590,7 +590,7 @@ st_get_texture_sampler_view_from_stobj(struct st_context *st,
bool glsl130_or_later, bool glsl130_or_later,
bool ignore_srgb_decode) bool ignore_srgb_decode)
{ {
const struct st_sampler_view *sv; struct st_sampler_view *sv;
bool srgb_skip_decode = false; bool srgb_skip_decode = false;
if (!ignore_srgb_decode && samp->Attrib.sRGBDecode == GL_SKIP_DECODE_EXT) if (!ignore_srgb_decode && samp->Attrib.sRGBDecode == GL_SKIP_DECODE_EXT)
@ -640,7 +640,7 @@ struct pipe_sampler_view *
st_get_buffer_sampler_view_from_stobj(struct st_context *st, st_get_buffer_sampler_view_from_stobj(struct st_context *st,
struct st_texture_object *stObj) struct st_texture_object *stObj)
{ {
const struct st_sampler_view *sv; struct st_sampler_view *sv;
struct st_buffer_object *stBuf = struct st_buffer_object *stBuf =
st_buffer_object(stObj->base.BufferObject); st_buffer_object(stObj->base.BufferObject);

View File

@ -69,7 +69,7 @@ void
st_delete_texture_sampler_views(struct st_context *st, st_delete_texture_sampler_views(struct st_context *st,
struct st_texture_object *stObj); struct st_texture_object *stObj);
const struct st_sampler_view * struct st_sampler_view *
st_texture_get_current_sampler_view(const struct st_context *st, st_texture_get_current_sampler_view(const struct st_context *st,
const struct st_texture_object *stObj); const struct st_texture_object *stObj);