void _cogl_path_fill_nodes (CoglPath *path, CoglDrawFlags flags) { gboolean needs_fallback = FALSE; CoglPipeline *pipeline = cogl_get_source (); _cogl_pipeline_foreach_layer_internal (pipeline, validate_layer_cb, &needs_fallback); if (needs_fallback) { _cogl_path_fill_nodes_with_clipped_rectangle (path); return; } _cogl_path_build_fill_attribute_buffer (path); _cogl_framebuffer_draw_indexed_attributes (cogl_get_draw_framebuffer (), pipeline, COGL_VERTICES_MODE_TRIANGLES, 0, /* first_vertex */ path->data->fill_vbo_n_indices, path->data->fill_vbo_indices, path->data->fill_attributes, COGL_PATH_N_ATTRIBUTES, flags); }
void _cogl_primitive_draw (CoglPrimitive *primitive, CoglFramebuffer *framebuffer, CoglPipeline *pipeline, CoglDrawFlags flags) { if (primitive->indices) _cogl_framebuffer_draw_indexed_attributes (framebuffer, pipeline, primitive->mode, primitive->first_vertex, primitive->n_vertices, primitive->indices, primitive->attributes, primitive->n_attributes, flags); else _cogl_framebuffer_draw_attributes (framebuffer, pipeline, primitive->mode, primitive->first_vertex, primitive->n_vertices, primitive->attributes, primitive->n_attributes, flags); }