[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Public WebGL] Chrome sampler2D issue



On Mon, Sep 13, 2010 at 9:38 AM, Marco Di Benedetto
<marco.dibenedetto@isti.cnr.it> wrote:
>  Hi,
>
> I noticed that on some systems, launching chrome without --use-gl=desktop
> (without it, it means it's using ANGLE, am I right?) causes
> gl.getActiveUniform() to return a wrong type for sampler2D program uniforms.
> More in detail, result.type is gl.INT instead of gl.SAMPLER_2D. Actually you
> use gl.uniform1i() to set the sampler texture unit index, but indeed it must
> be reported as a sampler2D. This causes several problems when reflection on
> uniforms is heavily used (see SpiderGL).
> The problem does not arise in all systems I tried, it seems an unknown
> mixture of OS, graphics board and graphics drivers.

Gregg found recently that many OpenGL drivers are reporting incorrect
types for matrix uniforms as well (reporting them as vectors instead
of matrices). There is a plan to use the ANGLE shader validator to
store the types of uniforms and use its information rather than that
from the underlying GL implementation for these queries. Since the
majority of browsers supporting WebGL are using the ANGLE validator,
this would fix this issue in all of them.

-Ken

-----------------------------------------------------------
You are currently subscribed to public_webgl@khronos.org.
To unsubscribe, send an email to majordomo@khronos.org with
the following command in the body of your email: