summaryrefslogtreecommitdiffstats
path: root/src/mesa/state_tracker
diff options
context:
space:
mode:
authorBrian Paul <brianp@vmware.com>2014-01-27 12:06:39 -0700
committerBrian Paul <brianp@vmware.com>2014-02-02 06:47:32 -0700
commited7211589161c3ec3157b669120b5bf49dd54d54 (patch)
tree979b1fdb39292baa0e39d568e105e513caf38554 /src/mesa/state_tracker
parentf09a1261add801d75e42d74a8f648a6b31766c28 (diff)
downloadexternal_mesa3d-ed7211589161c3ec3157b669120b5bf49dd54d54.zip
external_mesa3d-ed7211589161c3ec3157b669120b5bf49dd54d54.tar.gz
external_mesa3d-ed7211589161c3ec3157b669120b5bf49dd54d54.tar.bz2
st/mesa: use _mesa_get_current_tex_object() in st_context_teximage()
Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Diffstat (limited to 'src/mesa/state_tracker')
-rw-r--r--src/mesa/state_tracker/st_manager.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/mesa/state_tracker/st_manager.c b/src/mesa/state_tracker/st_manager.c
index b7757e9..215b276 100644
--- a/src/mesa/state_tracker/st_manager.c
+++ b/src/mesa/state_tracker/st_manager.c
@@ -469,7 +469,6 @@ st_context_teximage(struct st_context_iface *stctxi,
{
struct st_context *st = (struct st_context *) stctxi;
struct gl_context *ctx = st->ctx;
- struct gl_texture_unit *texUnit = _mesa_get_current_tex_unit(ctx);
struct gl_texture_object *texObj;
struct gl_texture_image *texImage;
struct st_texture_object *stObj;
@@ -495,7 +494,8 @@ st_context_teximage(struct st_context_iface *stctxi,
return FALSE;
}
- texObj = _mesa_select_tex_object(ctx, texUnit, target);
+ texObj = _mesa_get_current_tex_object(ctx, target);
+
_mesa_lock_texture(ctx, texObj);
stObj = st_texture_object(texObj);