summaryrefslogtreecommitdiffstats
path: root/src/mesa/main/pipelineobj.h
diff options
context:
space:
mode:
authorGregory Hainaut <[email protected]>2013-06-28 13:54:06 -0700
committerIan Romanick <[email protected]>2014-02-21 15:41:02 -0800
commitf4c13a890fa24ff1f998e7cac0ecc31505a29403 (patch)
treea5512875a085758f11c18f92c486f085da577a9f /src/mesa/main/pipelineobj.h
parent0f137a1d73c415dc8744d4b9e6c194232715f023 (diff)
mesa/sso: Add pipeline container/state
V1: * Extend gl_shader_state as pipeline object state * Add a new container gl_pipeline_shader_state that contains binding point of the previous object * Update mesa init/free shader state due to the extension of the attibute * Add an init/free pipeline function for the context V2: * Rename gl_shader_state to gl_pipeline_object * Rename Pipeline.PipelineObj to Pipeline.Current * Formatting improvement V3 (idr): * Split out from previous uber patch. * Remove '#if 0' debug printfs. V4 (idr): * Fix some errors in comments. Suggested by Jordan. Reviewed-by: Ian Romanick <[email protected]> Reviewed-by: Jordan Justen <[email protected]>
Diffstat (limited to 'src/mesa/main/pipelineobj.h')
-rw-r--r--src/mesa/main/pipelineobj.h25
1 files changed, 25 insertions, 0 deletions
diff --git a/src/mesa/main/pipelineobj.h b/src/mesa/main/pipelineobj.h
index 56d32ccef74..46d5fab4230 100644
--- a/src/mesa/main/pipelineobj.h
+++ b/src/mesa/main/pipelineobj.h
@@ -34,6 +34,31 @@ extern "C" {
struct _glapi_table;
struct gl_context;
+struct gl_pipeline_object;
+
+extern void
+_mesa_delete_pipeline_object(struct gl_context *ctx, struct gl_pipeline_object *obj);
+
+extern void
+_mesa_init_pipeline(struct gl_context *ctx);
+
+extern void
+_mesa_free_pipeline_data(struct gl_context *ctx);
+
+extern void
+_mesa_reference_pipeline_object_(struct gl_context *ctx,
+ struct gl_pipeline_object **ptr,
+ struct gl_pipeline_object *obj);
+
+static inline void
+_mesa_reference_pipeline_object(struct gl_context *ctx,
+ struct gl_pipeline_object **ptr,
+ struct gl_pipeline_object *obj)
+{
+ if (*ptr != obj)
+ _mesa_reference_pipeline_object_(ctx, ptr, obj);
+}
+
extern void GLAPIENTRY
_mesa_UseProgramStages(GLuint pipeline, GLbitfield stages, GLuint program);