From ef30ce97a6bc0a9a6e625df6964e1cdea0ccee4b Mon Sep 17 00:00:00 2001 From: Paul Berry Date: Wed, 3 Oct 2012 15:39:52 -0700 Subject: mesa: Create pointers for multithread marshalling dispatch table. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit This patch splits the context's CurrentDispatch pointer into two pointers, CurrentClientDispatch, and CurrentServerDispatch, so that when doing multithread marshalling, we can distinguish between the dispatch table that's being used by the client (to serialize GL calls into the marshal buffer) and the dispatch table that's being used by the server (to execute the GL calls). Acked-by: Timothy Arceri Acked-by: Marek Olšák Tested-by: Dieter Nützel Tested-by: Mike Lothian --- src/mesa/main/varray.c | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'src/mesa/main/varray.c') diff --git a/src/mesa/main/varray.c b/src/mesa/main/varray.c index c4283551882..92e3f4d1f8a 100644 --- a/src/mesa/main/varray.c +++ b/src/mesa/main/varray.c @@ -1558,7 +1558,7 @@ _mesa_MultiDrawArrays( GLenum mode, const GLint *first, for (i = 0; i < primcount; i++) { if (count[i] > 0) { - CALL_DrawArrays(ctx->CurrentDispatch, (mode, first[i], count[i])); + CALL_DrawArrays(ctx->CurrentClientDispatch, (mode, first[i], count[i])); } } } @@ -1578,7 +1578,7 @@ _mesa_MultiModeDrawArraysIBM( const GLenum * mode, const GLint * first, for ( i = 0 ; i < primcount ; i++ ) { if ( count[i] > 0 ) { GLenum m = *((GLenum *) ((GLubyte *) mode + i * modestride)); - CALL_DrawArrays(ctx->CurrentDispatch, ( m, first[i], count[i] )); + CALL_DrawArrays(ctx->CurrentServerDispatch, ( m, first[i], count[i] )); } } } @@ -1600,8 +1600,8 @@ _mesa_MultiModeDrawElementsIBM( const GLenum * mode, const GLsizei * count, for ( i = 0 ; i < primcount ; i++ ) { if ( count[i] > 0 ) { GLenum m = *((GLenum *) ((GLubyte *) mode + i * modestride)); - CALL_DrawElements(ctx->CurrentDispatch, ( m, count[i], type, - indices[i] )); + CALL_DrawElements(ctx->CurrentServerDispatch, ( m, count[i], type, + indices[i] )); } } } -- cgit v1.2.3