draw_set_mapped_vertex_buffer(draw, i, NULL);
}
if (indexBuffer) {
- draw_set_mapped_element_buffer(draw, 0, NULL);
+ draw_set_mapped_element_buffer(draw, 0, 0, NULL);
}
/*
unsigned mode, unsigned start, unsigned count)
{
cell_draw_range_elements( pipe, indexBuffer,
- indexSize, indeBias,
+ indexSize, indexBias,
0, 0xffffffff,
mode, start, count );
}
#include "pipe/p_context.h"
#include "pipe/p_defines.h"
#include "util/u_inlines.h"
-
+#include "util/u_transfer.h"
#include "util/u_format.h"
#include "util/u_math.h"
#include "util/u_memory.h"
#include "cell_context.h"
#include "cell_screen.h"
#include "cell_state.h"
-#include "cell_resource.h"
+#include "cell_texture.h"
#include "state_tracker/sw_winsys.h"
static void
-cell_resource_destroy(struct pipe_resource *pt)
+cell_resource_destroy(struct pipe_screen *scrn, struct pipe_resource *pt)
{
- struct cell_screen *screen = cell_screen(pt->screen);
+ struct cell_screen *screen = cell_screen(scrn);
struct sw_winsys *winsys = screen->winsys;
struct cell_resource *ct = cell_resource(pt);
{
struct cell_resource *ct = cell_resource(resource);
struct cell_transfer *ctrans;
- enum pipe_format *format = resource->format;
+ enum pipe_format format = resource->format;
assert(resource);
- assert(level <= resource->last_level);
+ assert(sr.level <= resource->last_level);
/* make sure the requested region is in the image bounds */
assert(box->x + box->width <= u_minify(resource->width0, sr.level));
}
+static struct pipe_resource *
+cell_resource_from_handle(struct pipe_screen *screen,
+ const struct pipe_resource *templat,
+ struct winsys_handle *handle)
+{
+ /* XXX todo */
+ return NULL;
+}
+
+
+static boolean
+cell_resource_get_handle(struct pipe_screen *scree,
+ struct pipe_resource *tex,
+ struct winsys_handle *handle)
+{
+ /* XXX todo */
+ return FALSE;
+}
void
}
void
-cell_init_transfer_funcs(struct cell_context *cell)
+cell_init_texture_transfer_funcs(struct cell_context *cell)
{
cell->pipe.get_transfer = cell_get_transfer;
cell->pipe.transfer_destroy = cell_transfer_destroy;
static void
-cell_vbuf_draw(struct vbuf_render *vbr,
- const ushort *indices,
- uint nr_indices)
+cell_vbuf_draw_elements(struct vbuf_render *vbr,
+ const ushort *indices,
+ uint nr_indices)
{
struct cell_vbuf_render *cvbr = cell_vbuf_render(vbr);
struct cell_context *cell = cvbr->cell;
cell->vbuf_render->base.map_vertices = cell_vbuf_map_vertices;
cell->vbuf_render->base.unmap_vertices = cell_vbuf_unmap_vertices;
cell->vbuf_render->base.set_primitive = cell_vbuf_set_primitive;
- cell->vbuf_render->base.draw = cell_vbuf_draw;
+ cell->vbuf_render->base.draw_elements = cell_vbuf_draw_elements;
cell->vbuf_render->base.release_vertices = cell_vbuf_release_vertices;
cell->vbuf_render->base.destroy = cell_vbuf_destroy;