From bd953e872f22690bd232a758383883100d9347d0 Mon Sep 17 00:00:00 2001 From: Keith Whitwell Date: Mon, 15 Sep 2008 13:47:25 +0100 Subject: mesa: get another class of degenerate dlists working Primitive begin in one dlist, end in another. --- src/mesa/main/dlist.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'src/mesa/main') diff --git a/src/mesa/main/dlist.c b/src/mesa/main/dlist.c index 63a00e04f5..9f6f4d96f4 100644 --- a/src/mesa/main/dlist.c +++ b/src/mesa/main/dlist.c @@ -6788,6 +6788,11 @@ _mesa_EndList(void) _mesa_error(ctx, GL_INVALID_OPERATION, "glEndList"); return; } + + /* Call before emitting END_OF_LIST, in case the driver wants to + * emit opcodes itself. + */ + ctx->Driver.EndList(ctx); (void) ALLOC_INSTRUCTION(ctx, OPCODE_END_OF_LIST, 0); @@ -6801,8 +6806,6 @@ _mesa_EndList(void) if (MESA_VERBOSE & VERBOSE_DISPLAY_LIST) mesa_print_display_list(ctx->ListState.CurrentListNum); - ctx->Driver.EndList(ctx); - ctx->ListState.CurrentList = NULL; ctx->ListState.CurrentListNum = 0; ctx->ListState.CurrentListPtr = NULL; -- cgit v1.2.3