struct pipe_surface *surf,
unsigned width, unsigned height,
enum pipe_format format,
- unsigned flags)
+ unsigned flags,
+ unsigned tex_usage)
{
const unsigned alignment = 64;
surf->format = format;
surf->cpp = pf_get_size(format);
surf->pitch = round_up(width, alignment / surf->cpp);
+ surf->usage = flags;
#ifdef GALLIUM_CELL /* XXX a bit of a hack */
height = round_up(height, TILE_SIZE);
xm_surface_release(struct pipe_winsys *winsys, struct pipe_surface **s)
{
struct pipe_surface *surf = *s;
+ assert(!surf->texture);
surf->refcount--;
if (surf->refcount == 0) {
if (surf->buffer)
}
-struct pipe_winsys *
+static struct pipe_winsys *
xmesa_get_pipe_winsys(struct xmesa_visual *xm_vis)
{
static struct xmesa_pipe_winsys *ws = NULL;