----- Original Message -----
From: "Kenneth Russell" <firstname.lastname@example.org
To: "Gregg Tavares (勤)" <email@example.com
Cc: "public webgl" <firstname.lastname@example.org
Sent: Tuesday, May 1, 2012 4:45:37 PM
Subject: Re: [Public WebGL] Proposal: Generate INVALID_VALUE if value >= MAX_TEXTURE_IMAGE_UNITS on uniform1f(v) for samplers
On Tue, May 1, 2012 at 3:13 PM, Gregg Tavares (勤) <email@example.com
> A developer ran into a bug today where their app was working on Linux but
> not Mac and Windows.
> The issue was they were calling
> gl.uniform1f(someSamplerLocation, gl.TEXTURE0);
> when they should have been calling
> gl.uniform1f(someSamplerLocation, 0);
> You could say this is their fault for writing bad code but the thing is
> there are no errors for this condition defined by OpenGL ES or WebGL AFAIK.
> It just happens that on Linux calling gl.uniform1f(someSamplerLocation,
> 33984) uses texture unit 0 and on Mac and Windows it does something else.
> Given that uniforms are program specific and given that at runtime we know
> whether or not a particular location is a sampler, should we generate an
> if the value set for a sampler uniform is greater than or
This sounds good to me.