mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-06 09:28:07 +02:00
mesa: fix using texture id 0 with VDPAURegisterSurfaceNV()
Signed-off-by: Samuel Pitoiset <samuel.pitoiset@gmail.com> Reviewed-by: Christian König <christian.koenig@amd.com> Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
This commit is contained in:
parent
51a7e0d14f
commit
7f47c31f8c
1 changed files with 3 additions and 3 deletions
|
|
@ -145,11 +145,11 @@ register_surface(struct gl_context *ctx, GLboolean isOutput,
|
|||
surf->output = isOutput;
|
||||
for (i = 0; i < numTextureNames; ++i) {
|
||||
struct gl_texture_object *tex;
|
||||
tex = _mesa_lookup_texture(ctx, textureNames[i]);
|
||||
|
||||
tex = _mesa_lookup_texture_err(ctx, textureNames[i],
|
||||
"VDPAURegisterSurfaceNV");
|
||||
if (tex == NULL) {
|
||||
free(surf);
|
||||
_mesa_error(ctx, GL_INVALID_OPERATION,
|
||||
"VDPAURegisterSurfaceNV(texture ID not found)");
|
||||
return (GLintptr)NULL;
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue