aboutsummaryrefslogtreecommitdiffstats
path: root/src/gallium/state_trackers/xa
diff options
context:
space:
mode:
authorMarek Olšák <[email protected]>2012-12-21 17:03:22 +0100
committerMarek Olšák <[email protected]>2013-01-04 13:18:33 +0100
commit598cc1f74d7ae924e84dee801b456ab7b0b22f84 (patch)
tree5dcbab29d7ed274768892a9890fd1dec5f964a6d /src/gallium/state_trackers/xa
parent4ad5ebaefa3c5918001a40ed6099521aa0142c95 (diff)
gallium: extend pipe_context::flush for it to accept an END_OF_FRAME flag
Usage with pipe_context: pipe->flush(pipe, NULL, PIPE_FLUSH_END_OF_FRAME); Usage with st_context_iface: st->flush(st, ST_FLUSH_END_OF_FRAME, NULL); The flag is only a hint for drivers. Radeon will use it for buffer eviction heuristics in the kernel (e.g. for queries like how many frames have passed since a buffer was used). The flag is currently only generated by st/dri on SwapBuffers. Reviewed-by: Brian Paul <[email protected]> Reviewed-by: Stéphane Marchesin <[email protected]>
Diffstat (limited to 'src/gallium/state_trackers/xa')
-rw-r--r--src/gallium/state_trackers/xa/xa_composite.c2
-rw-r--r--src/gallium/state_trackers/xa/xa_context.c8
-rw-r--r--src/gallium/state_trackers/xa/xa_tracker.c2
-rw-r--r--src/gallium/state_trackers/xa/xa_yuv.c2
4 files changed, 7 insertions, 7 deletions
diff --git a/src/gallium/state_trackers/xa/xa_composite.c b/src/gallium/state_trackers/xa/xa_composite.c
index 17d2d7f727d..eb949b93cd1 100644
--- a/src/gallium/state_trackers/xa/xa_composite.c
+++ b/src/gallium/state_trackers/xa/xa_composite.c
@@ -527,7 +527,7 @@ XA_EXPORT void
xa_composite_done(struct xa_context *ctx)
{
renderer_draw_flush(ctx);
- ctx->pipe->flush(ctx->pipe, &ctx->last_fence);
+ ctx->pipe->flush(ctx->pipe, &ctx->last_fence, 0);
ctx->comp = NULL;
ctx->has_solid_color = FALSE;
diff --git a/src/gallium/state_trackers/xa/xa_context.c b/src/gallium/state_trackers/xa/xa_context.c
index 7b7a90343df..b31d555c50a 100644
--- a/src/gallium/state_trackers/xa/xa_context.c
+++ b/src/gallium/state_trackers/xa/xa_context.c
@@ -119,7 +119,7 @@ xa_surface_dma(struct xa_context *ctx,
}
pipe->transfer_unmap(pipe, transfer);
if (to_surface)
- pipe->flush(pipe, &ctx->last_fence);
+ pipe->flush(pipe, &ctx->last_fence, 0);
}
return XA_ERR_NONE;
}
@@ -244,9 +244,9 @@ xa_copy_done(struct xa_context *ctx)
{
if (!ctx->simple_copy) {
renderer_draw_flush(ctx);
- ctx->pipe->flush(ctx->pipe, &ctx->last_fence);
+ ctx->pipe->flush(ctx->pipe, &ctx->last_fence, 0);
} else
- ctx->pipe->flush(ctx->pipe, &ctx->last_fence);
+ ctx->pipe->flush(ctx->pipe, &ctx->last_fence, 0);
}
static void
@@ -325,7 +325,7 @@ XA_EXPORT void
xa_solid_done(struct xa_context *ctx)
{
renderer_draw_flush(ctx);
- ctx->pipe->flush(ctx->pipe, &ctx->last_fence);
+ ctx->pipe->flush(ctx->pipe, &ctx->last_fence, 0);
ctx->comp = NULL;
ctx->has_solid_color = FALSE;
diff --git a/src/gallium/state_trackers/xa/xa_tracker.c b/src/gallium/state_trackers/xa/xa_tracker.c
index 8bd40ddc7d2..3410144141d 100644
--- a/src/gallium/state_trackers/xa/xa_tracker.c
+++ b/src/gallium/state_trackers/xa/xa_tracker.c
@@ -407,7 +407,7 @@ xa_surface_redefine(struct xa_surface *srf,
xa_min(save_height, template->height0), &src_box);
pipe->resource_copy_region(pipe, texture,
0, 0, 0, 0, srf->tex, 0, &src_box);
- pipe->flush(pipe, &xa->default_ctx->last_fence);
+ pipe->flush(pipe, &xa->default_ctx->last_fence, 0);
}
pipe_resource_reference(&srf->tex, texture);
diff --git a/src/gallium/state_trackers/xa/xa_yuv.c b/src/gallium/state_trackers/xa/xa_yuv.c
index 912ea77c753..9c7c4d68781 100644
--- a/src/gallium/state_trackers/xa/xa_yuv.c
+++ b/src/gallium/state_trackers/xa/xa_yuv.c
@@ -153,7 +153,7 @@ xa_yuv_planar_blit(struct xa_context *r,
box++;
}
- r->pipe->flush(r->pipe, &r->last_fence);
+ r->pipe->flush(r->pipe, &r->last_fence, 0);
xa_ctx_sampler_views_destroy(r);
xa_ctx_srf_destroy(r);