mesa: glGetProgramResourceLocation
authorTapani Pälli <tapani.palli@intel.com>
Thu, 12 Mar 2015 11:45:22 +0000 (13:45 +0200)
committerTapani Pälli <tapani.palli@intel.com>
Thu, 16 Apr 2015 04:55:56 +0000 (07:55 +0300)
commite0e4d77f0120865b3ca0a4055358fc87d38d1cfe
tree38e663dd90d25ef851687b3b2920d5061d976953
parent2a5a0d19d67b2ccd7eee33a6f3bead66cc2d78ff
mesa: glGetProgramResourceLocation

Patch adds required helper functions to shaderapi.h and
the actual implementation.

corresponding Piglit test:
   arb_program_interface_query-resource-location

The added functionality can be tested by tests for following
functions that are refactored by later patches:

   GetAttribLocation
   GetUniformLocation
   GetFragDataLocation

v2: code cleanup, changes to array element
    syntax checking (Ilia Mirkin)

Signed-off-by: Tapani Pälli <tapani.palli@intel.com>
Reviewed-by: Martin Peres <martin.peres@linux.intel.com>
src/mesa/main/program_resource.c
src/mesa/main/shader_query.cpp
src/mesa/main/shaderapi.h