vdpau: Declare texture object as immutable using helper function.
Cc: mesa-stable Closes: https://gitlab.freedesktop.org/mesa/mesa/-/issues/10618 Signed-off-by: Chris Rankin <rankincj@gmail.com> Reviewed-by: Marek Olšák <marek.olsak@amd.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/27681> (cherry picked from commit e1e84b0721312b5b5b085571d6a5e0504f01d4fb)
This commit is contained in:
parent
d50d8ea2ba
commit
c8bdf6129a
2 changed files with 3 additions and 2 deletions
|
|
@ -1964,7 +1964,7 @@
|
||||||
"description": "vdpau: Declare texture object as immutable using helper function.",
|
"description": "vdpau: Declare texture object as immutable using helper function.",
|
||||||
"nominated": true,
|
"nominated": true,
|
||||||
"nomination_type": 0,
|
"nomination_type": 0,
|
||||||
"resolution": 0,
|
"resolution": 1,
|
||||||
"main_sha": null,
|
"main_sha": null,
|
||||||
"because_sha": null,
|
"because_sha": null,
|
||||||
"notes": null
|
"notes": null
|
||||||
|
|
|
||||||
|
|
@ -39,6 +39,7 @@
|
||||||
#include "glformats.h"
|
#include "glformats.h"
|
||||||
#include "texobj.h"
|
#include "texobj.h"
|
||||||
#include "teximage.h"
|
#include "teximage.h"
|
||||||
|
#include "textureview.h"
|
||||||
#include "api_exec_decl.h"
|
#include "api_exec_decl.h"
|
||||||
|
|
||||||
#include "state_tracker/st_cb_texture.h"
|
#include "state_tracker/st_cb_texture.h"
|
||||||
|
|
@ -179,7 +180,7 @@ register_surface(struct gl_context *ctx, GLboolean isOutput,
|
||||||
}
|
}
|
||||||
|
|
||||||
/* This will disallow respecifying the storage. */
|
/* This will disallow respecifying the storage. */
|
||||||
tex->Immutable = GL_TRUE;
|
_mesa_set_texture_view_state(ctx, tex, target, 1);
|
||||||
_mesa_unlock_texture(ctx, tex);
|
_mesa_unlock_texture(ctx, tex);
|
||||||
|
|
||||||
_mesa_reference_texobj(&surf->textures[i], tex);
|
_mesa_reference_texobj(&surf->textures[i], tex);
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue