Home | History | Annotate | Download | only in main

Lines Matching refs:ctx

108 _mesa_initialize_context( struct gl_context *ctx,
123 _mesa_free_context_data( struct gl_context *ctx );
126 _mesa_destroy_context( struct gl_context *ctx );
134 _mesa_check_init_viewport(struct gl_context *ctx, GLuint width, GLuint height);
137 _mesa_make_current( struct gl_context *ctx, struct gl_framebuffer *drawBuffer,
141 _mesa_share_state(struct gl_context *ctx, struct gl_context *ctxToShare);
149 _mesa_init_get_hash(struct gl_context *ctx);
156 _mesa_get_dispatch(struct gl_context *ctx);
160 _mesa_set_mvp_with_dp4( struct gl_context *ctx,
165 _mesa_valid_to_render(struct gl_context *ctx, const char *where);
173 _mesa_record_error( struct gl_context *ctx, GLenum error );
177 _mesa_finish(struct gl_context *ctx);
180 _mesa_flush(struct gl_context *ctx);
201 * \param ctx GL context.
208 #define FLUSH_VERTICES(ctx, newstate) \
211 _mesa_debug(ctx, "FLUSH_VERTICES in %s\n", MESA_FUNCTION);\
212 if (ctx->Driver.NeedFlush & FLUSH_STORED_VERTICES) \
213 ctx->Driver.FlushVertices(ctx, FLUSH_STORED_VERTICES); \
214 ctx->NewState |= newstate; \
220 * \param ctx GL context.
227 #define FLUSH_CURRENT(ctx, newstate) \
230 _mesa_debug(ctx, "FLUSH_CURRENT in %s\n", MESA_FUNCTION); \
231 if (ctx->Driver.NeedFlush & FLUSH_UPDATE_CURRENT) \
232 ctx->Driver.FlushVertices(ctx, FLUSH_UPDATE_CURRENT); \
233 ctx->NewState |= newstate; \
240 * \param ctx GL context.
243 #define ASSERT_OUTSIDE_BEGIN_END_WITH_RETVAL(ctx, retval) \
245 if (ctx->Driver.CurrentExecPrimitive != PRIM_OUTSIDE_BEGIN_END) { \
246 _mesa_error(ctx, GL_INVALID_OPERATION, "Inside glBegin/glEnd"); \
255 * \param ctx GL context.
257 #define ASSERT_OUTSIDE_BEGIN_END(ctx) \
259 if (ctx->Driver.CurrentExecPrimitive != PRIM_OUTSIDE_BEGIN_END) { \
260 _mesa_error(ctx, GL_INVALID_OPERATION, "Inside glBegin/glEnd"); \
269 * \param ctx GL context.
271 #define ASSERT_OUTSIDE_BEGIN_END_AND_FLUSH(ctx) \
273 ASSERT_OUTSIDE_BEGIN_END(ctx); \
274 FLUSH_VERTICES(ctx, 0); \
281 * \param ctx GL context.
284 #define ASSERT_OUTSIDE_BEGIN_END_AND_FLUSH_WITH_RETVAL(ctx, retval) \
286 ASSERT_OUTSIDE_BEGIN_END_WITH_RETVAL(ctx, retval); \
287 FLUSH_VERTICES(ctx, 0); \
297 _mesa_is_desktop_gl(const struct gl_context *ctx)
299 return ctx->API == API_OPENGL || ctx->API == API_OPENGL_CORE;
307 _mesa_is_gles(const struct gl_context *ctx)
309 return ctx->API == API_OPENGLES || ctx->API == API_OPENGLES2;
317 _mesa_is_gles3(const struct gl_context *ctx)
319 return ctx->API == API_OPENGLES2 && ctx->Version >= 30;