summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/samplerobj.c
diff options
context:
space:
mode:
authorHenri Verbeet <hverbeet@gmail.com>2011-07-04 00:57:43 +0200
committerHenri Verbeet <hverbeet@gmail.com>2011-07-07 20:30:13 +0200
commite01e30b916dcbe01471a573ecaddb509cb9f0969 (patch)
tree79a7b45063f6ed8a0b76a64dea52144f42428920 /src/mesa/main/samplerobj.c
parentbfe284fd26e96b71c7cf46e6365b3697d68cde83 (diff)
downloadexternal_mesa3d-e01e30b916dcbe01471a573ecaddb509cb9f0969.zip
external_mesa3d-e01e30b916dcbe01471a573ecaddb509cb9f0969.tar.gz
external_mesa3d-e01e30b916dcbe01471a573ecaddb509cb9f0969.tar.bz2
mesa: Fix the BindSampler unit limit.
I'm not sure about this one. The current code actually follows the spec, but considering the spec is supposed to be written against GL 3.2 I'd say the spec is broken. I filled out a spec feedback form over a month ago, but either the form is broken, or nobody cares. Signed-off-by: Henri Verbeet <hverbeet@gmail.com> Reviewed-by: Brian Paul <brianp@vmware.com> Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Diffstat (limited to 'src/mesa/main/samplerobj.c')
-rw-r--r--src/mesa/main/samplerobj.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/mesa/main/samplerobj.c b/src/mesa/main/samplerobj.c
index f7774fd..8f8d87b 100644
--- a/src/mesa/main/samplerobj.c
+++ b/src/mesa/main/samplerobj.c
@@ -251,7 +251,7 @@ _mesa_BindSampler(GLuint unit, GLuint sampler)
struct gl_sampler_object *sampObj;
GET_CURRENT_CONTEXT(ctx);
- if (unit >= ctx->Const.MaxTextureImageUnits) {
+ if (unit >= ctx->Const.MaxCombinedTextureImageUnits) {
_mesa_error(ctx, GL_INVALID_VALUE, "glBindSampler(unit %u)", unit);
return;
}