[Mesa-dev] Mesa (master): draw: fix flat shading and screen-space linear interpolation in clipper

Marek Olšák maraeo at gmail.com
Wed Jul 11 03:51:32 PDT 2012

On Wed, Jul 11, 2012 at 11:04 AM, Olivier Galibert <galibert at pobox.com> wrote:
> On Tue, Jul 10, 2012 at 03:51:22PM +0200, Marek Ol??ák wrote:
>> I just wanted to tell you Stephane's change cannot work and it even
>> has no effect at the moment. The native integer support is global in
>> core Mesa. It's because integer uniforms are converted to floats based
>> on the global NativeInteger flag for all shader stages and that can't
>> be fixed easily, because uniforms can be shared between shaders.
>> Basically, all drivers must advertise integer support either for all
>> shader stages or none.
> Really?  I mean the idea here is that drivers like i915g which don't
> have native integers in the fragger are going to advertise native
> integers in the vs but stay at glsl 1.20.  Can you have integer
> uniforms without 1.30+?  I don't think so.

Dude, you should really learn GLSL. The idea to emulate integers is
even older than the GLSL itself. It first appeared in HLSL and NVIDIA
Cg on hardware that wasn't even GL2-capable.

>From the GLSL 1.2 spec:
"The uniform qualifier can be used with any of the basic data types,
...", then the section 4.1 lists the basic data types (like ivec4).


More information about the mesa-dev mailing list