Lines Matching refs:ctx

45 copy_vao(struct gl_context *ctx, const struct gl_vertex_array_object *vao,
49 struct vbo_context *vbo = vbo_context(ctx);
79 ctx->NewState |= _NEW_FF_VERT_PROGRAM;
81 ctx->NewState |= state;
82 ctx->PopAttribState |= pop_state;
98 playback_copy_to_current(struct gl_context *ctx,
108 copy_vao(ctx, node->cold->VAO[VP_MODE_SHADER], ~VERT_BIT_POS & VERT_BIT_ALL,
111 copy_vao(ctx, node->cold->VAO[VP_MODE_FF], VERT_BIT_MAT_ALL,
115 if (color0_changed && ctx->Light.ColorMaterialEnabled) {
116 _mesa_update_color_material(ctx, ctx->Current.Attrib[VBO_ATTRIB_COLOR0]);
124 ctx->Driver.CurrentExecPrimitive = PRIM_OUTSIDE_BEGIN_END;
126 ctx->Driver.CurrentExecPrimitive = prim->mode;
136 bind_vertex_list(struct gl_context *ctx,
139 const gl_vertex_processing_mode mode = ctx->VertexProgram._VPMode;
140 _mesa_set_draw_vao(ctx, node->cold->VAO[mode], _vbo_get_vao_filter(mode));
145 loopback_vertex_list(struct gl_context *ctx,
149 void *buffer = _mesa_bufferobj_map_range(ctx, 0, bo->Size, GL_MAP_READ_BIT, /* ? */
154 _vbo_loopback_vertex_list(ctx, list, buffer);
156 _mesa_bufferobj_unmap(ctx, bo, MAP_INTERNAL);
161 vbo_save_playback_vertex_list_loopback(struct gl_context *ctx, void *data)
166 FLUSH_FOR_DRAW(ctx);
168 if (_mesa_inside_begin_end(ctx) && node->draw_begins) {
172 _mesa_error(ctx, GL_INVALID_OPERATION,
179 loopback_vertex_list(ctx, node);
188 vbo_save_playback_vertex_list_gallium(struct gl_context *ctx,
195 if (!ctx->Driver.DrawGalliumVertexState || ctx->RenderMode != GL_RENDER)
198 const gl_vertex_processing_mode mode = ctx->VertexProgram._VPMode;
204 ctx->Array._DrawVAOEnabledAttribs = enabled;
205 _mesa_set_varying_vp_inputs(ctx, enabled);
207 if (ctx->NewState)
208 _mesa_update_state(ctx);
211 if (!ctx->ValidPrimMask) {
212 _mesa_error(ctx, ctx->DrawGLError, "glCallList");
225 struct gl_program *vp = ctx->VertexProgram._Current;
236 if (node->ctx == ctx) {
241 * one context (ctx above) can use this counter (so that it's only
276 ctx->Driver.DrawGalliumVertexState(ctx, state, info,
282 ctx->Driver.DrawGalliumVertexState(ctx, state, info,
289 playback_copy_to_current(ctx, node);
299 vbo_save_playback_vertex_list(struct gl_context *ctx, void *data, bool copy_to_current)
304 FLUSH_FOR_DRAW(ctx);
306 if (_mesa_inside_begin_end(ctx) && node->draw_begins) {
310 _mesa_error(ctx, GL_INVALID_OPERATION,
315 if (vbo_save_playback_vertex_list_gallium(ctx, node, copy_to_current) == DONE)
318 bind_vertex_list(ctx, node);
321 if (ctx->NewState)
322 _mesa_update_state(ctx);
325 if (!ctx->ValidPrimMask) {
326 _mesa_error(ctx, ctx->DrawGLError, "glCallList");
330 assert(ctx->NewState == 0);
335 ctx->Driver.DrawGalliumMultiMode(ctx, info,
340 ctx->Driver.DrawGallium(ctx, info, 0, &node->start_count, 1);
342 ctx->Driver.DrawGallium(ctx, info, 0, node->start_counts,
348 playback_copy_to_current(ctx, node);