summaryrefslogtreecommitdiff
path: root/src/mesa
diff options
context:
space:
mode:
authorTimothy Arceri <tarceri@itsqueeze.com>2017-06-28 14:46:06 +1000
committerTimothy Arceri <tarceri@itsqueeze.com>2017-06-29 08:54:11 +1000
commit87bc32166afc00dedd1e95b1e11ceef26a994fe0 (patch)
tree3db2373b7ac77996241dede8d9f7b43edc0e2007 /src/mesa
parentaed0fc5efd1283c2a7f45f27b1dac1a6e8471c2a (diff)
mesa: add KHR_no_error support for glBindFragDataLocation*()
Reviewed-by: Samuel Pitoiset <samuel.pitoiset@gmail.com>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/main/shader_query.cpp30
-rw-r--r--src/mesa/main/shaderapi.h8
2 files changed, 38 insertions, 0 deletions
diff --git a/src/mesa/main/shader_query.cpp b/src/mesa/main/shader_query.cpp
index 6e373ef6411..f2bdcaab121 100644
--- a/src/mesa/main/shader_query.cpp
+++ b/src/mesa/main/shader_query.cpp
@@ -280,6 +280,21 @@ _mesa_BindFragDataLocation(GLuint program, GLuint colorNumber,
}
void GLAPIENTRY
+_mesa_BindFragDataLocation_no_error(GLuint program, GLuint colorNumber,
+ const GLchar *name)
+{
+ GET_CURRENT_CONTEXT(ctx);
+
+ if (!name)
+ return;
+
+ struct gl_shader_program *const shProg =
+ _mesa_lookup_shader_program(ctx, program);
+
+ bind_frag_data_location(shProg, name, colorNumber, 0);
+}
+
+void GLAPIENTRY
_mesa_BindFragDataLocationIndexed(GLuint program, GLuint colorNumber,
GLuint index, const GLchar *name)
{
@@ -316,6 +331,21 @@ _mesa_BindFragDataLocationIndexed(GLuint program, GLuint colorNumber,
bind_frag_data_location(shProg, name, colorNumber, index);
}
+void GLAPIENTRY
+_mesa_BindFragDataLocationIndexed_no_error(GLuint program, GLuint colorNumber,
+ GLuint index, const GLchar *name)
+{
+ GET_CURRENT_CONTEXT(ctx);
+
+ if (!name)
+ return;
+
+ struct gl_shader_program *const shProg =
+ _mesa_lookup_shader_program(ctx, program);
+
+ bind_frag_data_location(shProg, name, colorNumber, index);
+}
+
GLint GLAPIENTRY
_mesa_GetFragDataIndex(GLuint program, const GLchar *name)
{
diff --git a/src/mesa/main/shaderapi.h b/src/mesa/main/shaderapi.h
index b2229f7ced6..b7ba7ab84a6 100644
--- a/src/mesa/main/shaderapi.h
+++ b/src/mesa/main/shaderapi.h
@@ -158,6 +158,14 @@ _mesa_BindFragDataLocationIndexed(GLuint program, GLuint colorNumber,
GLuint index, const GLchar *name);
extern void GLAPIENTRY
+_mesa_BindFragDataLocation_no_error(GLuint program, GLuint colorNumber,
+ const GLchar *name);
+
+extern void GLAPIENTRY
+_mesa_BindFragDataLocationIndexed_no_error(GLuint program, GLuint colorNumber,
+ GLuint index, const GLchar *name);
+
+extern void GLAPIENTRY
_mesa_GetActiveAttrib(GLuint, GLuint, GLsizei, GLsizei *, GLint *,
GLenum *, GLchar *);