mesa/subroutines: count number subroutines properly.
authorDave Airlie <airlied@redhat.com>
Tue, 17 May 2016 04:22:57 +0000 (14:22 +1000)
committerDave Airlie <airlied@redhat.com>
Mon, 23 May 2016 06:19:57 +0000 (16:19 +1000)
commit7fa0250f9446ec57caab581b8cac2c011c1cb497
treea7f28af88db8317e1976ac53d23d37d4cecd10ac
parent22db9b10ebd46c777a87da890f5089ad24686441
mesa/subroutines: count number subroutines properly.

The code was implementing the ACTIVE_SUBROUTINE_UNIFORMS
incorrectly, using the number of types not the number of
uniforms. This is different than the locations as the
locations may be sparsly allocated.

This fixes:
GL43-CTS.shader_subroutine.four_subroutines_with_two_uniforms

Reviewed-by: Chris Forbes <chrisforbes@google.com>
Signed-off-by: Dave Airlie <airlied@redhat.com>
src/compiler/glsl/linker.cpp
src/mesa/main/mtypes.h
src/mesa/main/shaderapi.c