nv50,nvc0: copy writable flag on surface creation
authorChristoph Bumiller <e0425955@student.tuwien.ac.at>
Fri, 1 Mar 2013 20:37:37 +0000 (21:37 +0100)
committerChristoph Bumiller <e0425955@student.tuwien.ac.at>
Tue, 12 Mar 2013 11:55:36 +0000 (12:55 +0100)
src/gallium/drivers/nv50/nv50_miptree.c
src/gallium/drivers/nv50/nv50_resource.c

index 7883edbe75e52f2a998dfe3937875b46788121c3..b6eddb43d3f2ed0881c9b3f5ab04dfee428eed19 100644 (file)
@@ -406,6 +406,7 @@ nv50_surface_from_miptree(struct nv50_miptree *mt,
    pipe_resource_reference(&ps->texture, &mt->base.base);
 
    ps->format = templ->format;
+   ps->writable = templ->writable;
    ps->u.tex.level = templ->u.tex.level;
    ps->u.tex.first_layer = templ->u.tex.first_layer;
    ps->u.tex.last_layer = templ->u.tex.last_layer;
index d5c330decc4039bd58cd3a5ea47b11ef2636702a..43c6998da3eb29ec06faeb2d58e1245e6f467fa4 100644 (file)
@@ -43,6 +43,7 @@ nv50_surface_from_buffer(struct pipe_context *pipe,
    pipe_resource_reference(&sf->base.texture, pbuf);
 
    sf->base.format = templ->format;
+   sf->base.writable = templ->writable;
    sf->base.u.buf.first_element = templ->u.buf.first_element;
    sf->base.u.buf.last_element = templ->u.buf.last_element;