mesa/sso: Add gl_pipeline_object parameter to _mesa_use_shader_program
authorGregory Hainaut <gregory.hainaut@gmail.com>
Sat, 29 Jun 2013 00:18:35 +0000 (17:18 -0700)
committerIan Romanick <ian.d.romanick@intel.com>
Tue, 25 Mar 2014 17:25:25 +0000 (10:25 -0700)
commit4caa9db71ce05dc2cc86177ca42655c2011fbe4a
tree525a073f1192e185ba35fdb8f3610fd213d7c02a
parentde4f85f52d0002cfd0105e932141cfdb108f1a61
mesa/sso: Add gl_pipeline_object parameter to _mesa_use_shader_program

Extend use_shader_program to support a different target. Allow to reuse the
function to update the pipeline state. Note I bypass the flush when target
isn't current. Maybe it would be better to create a new UseProgramStages
driver function

This was originally included in another patch, but it was split out by
Ian Romanick.

Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
Reviewed-by: Eric Anholt <eric@anholt.net>
src/mesa/drivers/common/meta.c
src/mesa/main/shaderapi.c
src/mesa/main/shaderapi.h