diff options
author | Pierre-Eric Pelloux-Prayer <[email protected]> | 2019-04-29 19:23:36 +0200 |
---|---|---|
committer | Marek Olšák <[email protected]> | 2019-08-06 17:02:52 -0400 |
commit | 58030d2b3ded667585f4f5e7bc459008f7ba7e8f (patch) | |
tree | f3dde92d24711e041a97a2d60dc72d2ee01bed67 /src/mesa/main/texgen.c | |
parent | b4c54894bba085966c52cb515bd72927e4ec4939 (diff) |
mesa: replace _mesa_get_current_fixedfunc_tex_unit with _mesa_get_fixedfunc_tex_unit
The new function implements the same feature but doesn't depend
on ctx->Texture.CurrentUnit.
This change allows to use it from indexed functions.
Reviewed-by: Marek Olšák <[email protected]>
Diffstat (limited to 'src/mesa/main/texgen.c')
-rw-r--r-- | src/mesa/main/texgen.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/src/mesa/main/texgen.c b/src/mesa/main/texgen.c index 4eb2f60464a..96d0228d8ca 100644 --- a/src/mesa/main/texgen.c +++ b/src/mesa/main/texgen.c @@ -85,7 +85,7 @@ _mesa_TexGenfv( GLenum coord, GLenum pname, const GLfloat *params ) return; } - texUnit = _mesa_get_current_fixedfunc_tex_unit(ctx); + texUnit = _mesa_get_fixedfunc_tex_unit(ctx, ctx->Texture.CurrentUnit); texgen = get_texgen(ctx, texUnit, coord); if (!texgen) { @@ -297,7 +297,7 @@ _mesa_GetTexGendv( GLenum coord, GLenum pname, GLdouble *params ) return; } - texUnit = _mesa_get_current_fixedfunc_tex_unit(ctx); + texUnit = _mesa_get_fixedfunc_tex_unit(ctx, ctx->Texture.CurrentUnit); texgen = get_texgen(ctx, texUnit, coord); if (!texgen) { @@ -334,7 +334,7 @@ _mesa_GetTexGenfv( GLenum coord, GLenum pname, GLfloat *params ) return; } - texUnit = _mesa_get_current_fixedfunc_tex_unit(ctx); + texUnit = _mesa_get_fixedfunc_tex_unit(ctx, ctx->Texture.CurrentUnit); texgen = get_texgen(ctx, texUnit, coord); if (!texgen) { @@ -379,7 +379,7 @@ _mesa_GetTexGeniv( GLenum coord, GLenum pname, GLint *params ) return; } - texUnit = _mesa_get_current_fixedfunc_tex_unit(ctx); + texUnit = _mesa_get_fixedfunc_tex_unit(ctx, ctx->Texture.CurrentUnit); texgen = get_texgen(ctx, texUnit, coord); if (!texgen) { |