aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa/main/pipelineobj.c
diff options
context:
space:
mode:
authorFabian Bieler <[email protected]>2014-03-07 10:33:54 +0100
committerMarek Olšák <[email protected]>2015-07-23 00:59:25 +0200
commit6435b2909e4f1b82268a1c5769c0c228cda768e0 (patch)
treebebd1706155dd51368a1d0d586b227c559c71e87 /src/mesa/main/pipelineobj.c
parent5852b5d2fa02d7716c2fbf859d058a2881416e9c (diff)
mesa: support tess stages in glGetProgramPipelineiv
Reviewed-by: Jordan Justen <[email protected]> Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]>
Diffstat (limited to 'src/mesa/main/pipelineobj.c')
-rw-r--r--src/mesa/main/pipelineobj.c15
1 files changed, 11 insertions, 4 deletions
diff --git a/src/mesa/main/pipelineobj.c b/src/mesa/main/pipelineobj.c
index bdf343a6763..8035c14b022 100644
--- a/src/mesa/main/pipelineobj.c
+++ b/src/mesa/main/pipelineobj.c
@@ -588,6 +588,7 @@ _mesa_GetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params)
/* Are geometry shaders available in this context?
*/
const bool has_gs = _mesa_has_geometry_shaders(ctx);
+ const bool has_tess = _mesa_has_tessellation(ctx);;
if (!pipe) {
_mesa_error(ctx, GL_INVALID_OPERATION,
@@ -615,11 +616,17 @@ _mesa_GetProgramPipelineiv(GLuint pipeline, GLenum pname, GLint *params)
? pipe->CurrentProgram[MESA_SHADER_VERTEX]->Name : 0;
return;
case GL_TESS_EVALUATION_SHADER:
- /* NOT YET SUPPORTED */
- break;
+ if (!has_tess)
+ break;
+ *params = pipe->CurrentProgram[MESA_SHADER_TESS_EVAL]
+ ? pipe->CurrentProgram[MESA_SHADER_TESS_EVAL]->Name : 0;
+ return;
case GL_TESS_CONTROL_SHADER:
- /* NOT YET SUPPORTED */
- break;
+ if (!has_tess)
+ break;
+ *params = pipe->CurrentProgram[MESA_SHADER_TESS_CTRL]
+ ? pipe->CurrentProgram[MESA_SHADER_TESS_CTRL]->Name : 0;
+ return;
case GL_GEOMETRY_SHADER:
if (!has_gs)
break;