X-Git-Url: https://git.libre-soc.org/?a=blobdiff_plain;f=src%2Fmesa%2Fmain%2Fcontext.h;h=d5b97ac4fc776d9b1d0609e5bc785eae5ca2eaaf;hb=6aea39641a6c32f780c40e3344096d3e0eccb590;hp=7de10e9924b8fe41a0243d892af853e442b2e6f0;hpb=91af56e3835bbc17f5b110ac472724cd0986503c;p=mesa.git diff --git a/src/mesa/main/context.h b/src/mesa/main/context.h index 7de10e9924b..d5b97ac4fc7 100644 --- a/src/mesa/main/context.h +++ b/src/mesa/main/context.h @@ -50,7 +50,7 @@ #include "errors.h" -#include "imports.h" + #include "extensions.h" #include "mtypes.h" #include "vbo/vbo.h" @@ -66,7 +66,7 @@ struct _glapi_table; /** \name Visual-related functions */ /*@{*/ - + extern struct gl_config * _mesa_create_visual( GLboolean dbFlag, GLboolean stereoFlag, @@ -107,6 +107,9 @@ _mesa_destroy_visual( struct gl_config *vis ); /** \name Context-related functions */ /*@{*/ +extern void +_mesa_initialize(void); + extern GLboolean _mesa_initialize_context( struct gl_context *ctx, gl_api api, @@ -115,7 +118,7 @@ _mesa_initialize_context( struct gl_context *ctx, const struct dd_function_table *driverFunctions); extern void -_mesa_free_context_data( struct gl_context *ctx ); +_mesa_free_context_data(struct gl_context *ctx); extern void _mesa_destroy_context( struct gl_context *ctx ); @@ -244,14 +247,20 @@ do { \ do { \ if (MESA_VERBOSE & VERBOSE_STATE) \ _mesa_debug(ctx, "FLUSH_FOR_DRAW in %s\n", __func__); \ - if (ctx->Driver.NeedFlush) \ - vbo_exec_FlushVertices(ctx, ctx->Driver.NeedFlush); \ + if (ctx->Driver.NeedFlush) { \ + if (ctx->_AllowDrawOutOfOrder) { \ + if (ctx->Driver.NeedFlush & FLUSH_UPDATE_CURRENT) \ + vbo_exec_FlushVertices(ctx, FLUSH_UPDATE_CURRENT); \ + } else { \ + vbo_exec_FlushVertices(ctx, ctx->Driver.NeedFlush); \ + } \ + } \ } while (0) /** * Macro to assert that the API call was made outside the * glBegin()/glEnd() pair, with return value. - * + * * \param ctx GL context. * \param retval value to return in case the assertion fails. */ @@ -266,7 +275,7 @@ do { \ /** * Macro to assert that the API call was made outside the * glBegin()/glEnd() pair. - * + * * \param ctx GL context. */ #define ASSERT_OUTSIDE_BEGIN_END(ctx) \