summaryrefslogtreecommitdiffstats
path: root/src/mesa/shader/shader_api.h
diff options
context:
space:
mode:
authorBrian <[email protected]>2006-12-19 18:02:03 -0700
committerBrian <[email protected]>2006-12-19 18:02:03 -0700
commit5b01c5e9d2c0283cc31981b6c85dc6392144b3db (patch)
tree754a7cf9d00ce39e8dfee63a5af6439f8c1d5be4 /src/mesa/shader/shader_api.h
parent46b06bdb2664b7a553fdc9e30367001ab39db804 (diff)
Overhaul of GLSL API functions, dispatching, etc.
Diffstat (limited to 'src/mesa/shader/shader_api.h')
-rw-r--r--src/mesa/shader/shader_api.h111
1 files changed, 109 insertions, 2 deletions
diff --git a/src/mesa/shader/shader_api.h b/src/mesa/shader/shader_api.h
index 388692b623e..723f92690d3 100644
--- a/src/mesa/shader/shader_api.h
+++ b/src/mesa/shader/shader_api.h
@@ -31,6 +31,13 @@
#include "mtypes.h"
+/**
+ * Internal functions
+ */
+
+extern void
+_mesa_init_shader_state(GLcontext * ctx);
+
extern struct gl_linked_program *
_mesa_new_linked_program(GLcontext *ctx, GLuint name);
@@ -52,8 +59,108 @@ extern struct gl_program *
_mesa_lookup_shader(GLcontext *ctx, GLuint name);
-extern GLvoid
-_mesa_init_shaderobjects(GLcontext * ctx);
+/**
+ * API/Driver functions
+ */
+
+extern void
+_mesa_attach_shader(GLcontext *ctx, GLuint program, GLuint shader);
+
+extern void
+_mesa_bind_attrib_location(GLcontext *ctx, GLuint program, GLuint index,
+ const GLchar *name);
+
+extern void
+_mesa_compile_shader(GLcontext *ctx, GLuint shaderObj);
+
+extern GLuint
+_mesa_create_shader(GLcontext *ctx, GLenum type);
+
+extern GLuint
+_mesa_create_program(GLcontext *ctx);
+
+extern void
+_mesa_delete_program2(GLcontext *ctx, GLuint name);
+
+extern void
+_mesa_delete_shader(GLcontext *ctx, GLuint shader);
+
+extern void
+_mesa_detach_shader(GLcontext *ctx, GLuint program, GLuint shader);
+
+extern void
+_mesa_get_active_attrib(GLcontext *ctx, GLuint program, GLuint index,
+ GLsizei maxLength, GLsizei *length, GLint *size,
+ GLenum *type, GLchar *name);
+
+extern void
+_mesa_get_active_uniform(GLcontext *ctx, GLuint program, GLuint index,
+ GLsizei maxLength, GLsizei *length, GLint *size,
+ GLenum *type, GLchar *name);
+
+extern void
+_mesa_get_attached_shaders(GLcontext *ctx, GLuint program, GLsizei maxCount,
+ GLsizei *count, GLuint *obj);
+
+extern GLint
+_mesa_get_attrib_location(GLcontext *ctx, GLuint program,
+ const GLchar *name);
+
+extern GLuint
+_mesa_get_handle(GLcontext *ctx, GLenum pname);
+
+extern void
+_mesa_get_programiv(GLcontext *ctx, GLuint program,
+ GLenum pname, GLint *params);
+
+extern void
+_mesa_get_program_info_log(GLcontext *ctx, GLuint program, GLsizei bufSize,
+ GLsizei *length, GLchar *infoLog);
+
+extern void
+_mesa_get_shaderiv(GLcontext *ctx, GLuint shader, GLenum pname, GLint *params);
+
+extern void
+_mesa_get_shader_info_log(GLcontext *ctx, GLuint shader, GLsizei bufSize,
+ GLsizei *length, GLchar *infoLog);
+
+extern void
+_mesa_get_shader_source(GLcontext *ctx, GLuint shader, GLsizei maxLength,
+ GLsizei *length, GLchar *sourceOut);
+
+extern void
+_mesa_get_uniformfv(GLcontext *ctx, GLuint program, GLint location,
+ GLfloat *params);
+
+extern GLint
+_mesa_get_uniform_location(GLcontext *ctx, GLuint program, const GLchar *name);
+
+extern GLboolean
+_mesa_is_program(GLcontext *ctx, GLuint name);
+
+extern GLboolean
+_mesa_is_shader(GLcontext *ctx, GLuint name);
+
+extern void
+_mesa_link_program(GLcontext *ctx, GLuint program);
+
+extern void
+_mesa_shader_source(GLcontext *ctx, GLuint shader, const GLchar *source);
+
+extern void
+_mesa_uniform(GLcontext *ctx, GLint location, GLsizei count,
+ const GLvoid *values, GLenum type);
+
+void
+_mesa_uniform_matrix(GLcontext *ctx, GLint cols, GLint rows,
+ GLenum matrixType, GLint location, GLsizei count,
+ GLboolean transpose, const GLfloat *values);
+
+extern void
+_mesa_use_program(GLcontext *ctx, GLuint program);
+
+extern void
+_mesa_validate_program(GLcontext *ctx, GLuint program);
#endif /* SHADER_API_H */