From 03a9994280c14e18be4bae14f4a9b667f8444d67 Mon Sep 17 00:00:00 2001 From: keithw Date: Fri, 10 Aug 2007 16:03:38 +0100 Subject: move dri_bo() to a header file --- src/mesa/drivers/dri/intel_winsys/intel_winsys.h | 20 ++++++++++++++++++++ .../drivers/dri/intel_winsys/intel_winsys_i915.c | 2 +- .../drivers/dri/intel_winsys/intel_winsys_pipe.c | 15 --------------- 3 files changed, 21 insertions(+), 16 deletions(-) (limited to 'src/mesa/drivers') diff --git a/src/mesa/drivers/dri/intel_winsys/intel_winsys.h b/src/mesa/drivers/dri/intel_winsys/intel_winsys.h index 6d4a5a4df32..2c8aa20c2a3 100644 --- a/src/mesa/drivers/dri/intel_winsys/intel_winsys.h +++ b/src/mesa/drivers/dri/intel_winsys/intel_winsys.h @@ -31,6 +31,8 @@ struct intel_context; struct pipe_context; struct pipe_winsys; +struct pipe_buffer_handle; +struct _DriBufferObject; struct pipe_winsys * intel_create_pipe_winsys( struct intel_context *intel ); @@ -42,4 +44,22 @@ struct pipe_context * intel_create_i915simple( struct intel_context *intel ); + +/* Turn the pipe opaque buffer pointer into a dri_bufmgr opaque + * buffer pointer... + */ +static INLINE struct _DriBufferObject * +dri_bo( struct pipe_buffer_handle *bo ) +{ + return (struct _DriBufferObject *)bo; +} + +static INLINE struct pipe_buffer_handle * +pipe_bo( struct _DriBufferObject *bo ) +{ + return (struct pipe_buffer_handle *)bo; +} + + + #endif diff --git a/src/mesa/drivers/dri/intel_winsys/intel_winsys_i915.c b/src/mesa/drivers/dri/intel_winsys/intel_winsys_i915.c index 51e3055cb0c..56a27a9c319 100644 --- a/src/mesa/drivers/dri/intel_winsys/intel_winsys_i915.c +++ b/src/mesa/drivers/dri/intel_winsys/intel_winsys_i915.c @@ -116,7 +116,7 @@ static void intel_i915_batch_flush( struct i915_winsys *sws ) struct intel_context *intel = intel_i915_winsys(sws)->intel; intel_batchbuffer_flush( intel->batch ); - if (0) intel_i915_batch_wait_idle( sws ); +// if (0) intel_i915_batch_wait_idle( sws ); } diff --git a/src/mesa/drivers/dri/intel_winsys/intel_winsys_pipe.c b/src/mesa/drivers/dri/intel_winsys/intel_winsys_pipe.c index 22daac6ea43..7f47b93f096 100644 --- a/src/mesa/drivers/dri/intel_winsys/intel_winsys_pipe.c +++ b/src/mesa/drivers/dri/intel_winsys/intel_winsys_pipe.c @@ -51,21 +51,6 @@ struct intel_pipe_winsys { -/* Turn the pipe opaque buffer pointer into a dri_bufmgr opaque - * buffer pointer... - */ -static inline struct _DriBufferObject * -dri_bo( struct pipe_buffer_handle *bo ) -{ - return (struct _DriBufferObject *)bo; -} - -static inline struct pipe_buffer_handle * -pipe_bo( struct _DriBufferObject *bo ) -{ - return (struct pipe_buffer_handle *)bo; -} - /* Turn a pipe winsys into an intel/pipe winsys: */ static inline struct intel_pipe_winsys * -- cgit v1.2.3