struct pipe_texture *texture,
unsigned face, unsigned level)
{
+ struct softpipe_context *softpipe = softpipe_context( pipe );
+ unsigned i;
+
+ if(softpipe->dirty_render_cache) {
+ for (i = 0; i < softpipe->framebuffer.nr_cbufs; i++) {
+ if(softpipe->framebuffer.cbufs[i] &&
+ softpipe->framebuffer.cbufs[i]->texture == texture)
+ return PIPE_REFERENCED_FOR_WRITE;
+ }
+ if(softpipe->framebuffer.zsbuf &&
+ softpipe->framebuffer.zsbuf->texture == texture)
+ return PIPE_REFERENCED_FOR_WRITE;
+ }
+
+ /* FIXME: we also need to do the same for the texture cache */
+
return PIPE_UNREFERENCED;
}
struct draw_stage *vbuf;
struct softpipe_vbuf_render *vbuf_render;
+ boolean dirty_render_cache;
+
struct softpipe_tile_cache *cbuf_cache[PIPE_MAX_COLOR_BUFS];
struct softpipe_tile_cache *zsbuf_cache;
* to unmap surfaces when flushing.
*/
softpipe_unmap_transfers(softpipe);
+
+ softpipe->dirty_render_cache = FALSE;
}
/* Enable to dump BMPs of the color/depth buffers each frame */