summaryrefslogtreecommitdiffstats
path: root/src/intel
diff options
context:
space:
mode:
authorPohjolainen, Topi <[email protected]>2016-10-11 22:26:35 +0300
committerJason Ekstrand <[email protected]>2016-11-17 12:03:24 -0800
commit7c560e8ccc60f26c145fbbcb281e431e65bbce55 (patch)
tree20fd3c08ac5f9714176cf677238d08d331774445 /src/intel
parentd7bd8c15d66a438a6680522915f746ce75e8d60c (diff)
intel/blorp: Add plumbing for color resolve slice details
Signed-off-by: Topi Pohjolainen <[email protected]> Reviewed-by: Jason Ekstrand <[email protected]>
Diffstat (limited to 'src/intel')
-rw-r--r--src/intel/blorp/blorp.h3
-rw-r--r--src/intel/blorp/blorp_clear.c9
2 files changed, 9 insertions, 3 deletions
diff --git a/src/intel/blorp/blorp.h b/src/intel/blorp/blorp.h
index 1a38cc96509..4e5a3a33ad6 100644
--- a/src/intel/blorp/blorp.h
+++ b/src/intel/blorp/blorp.h
@@ -169,7 +169,8 @@ blorp_clear_attachments(struct blorp_batch *batch,
void
blorp_ccs_resolve(struct blorp_batch *batch,
- struct blorp_surf *surf, enum isl_format format);
+ struct blorp_surf *surf, uint32_t level, uint32_t layer,
+ enum isl_format format);
/**
* For an overview of the HiZ operations, see the following sections of the
diff --git a/src/intel/blorp/blorp_clear.c b/src/intel/blorp/blorp_clear.c
index ea80c193c57..5c40e2f0557 100644
--- a/src/intel/blorp/blorp_clear.c
+++ b/src/intel/blorp/blorp_clear.c
@@ -542,13 +542,18 @@ blorp_clear_attachments(struct blorp_batch *batch,
void
blorp_ccs_resolve(struct blorp_batch *batch,
- struct blorp_surf *surf, enum isl_format format)
+ struct blorp_surf *surf, uint32_t level, uint32_t layer,
+ enum isl_format format)
{
struct blorp_params params;
blorp_params_init(&params);
+ /* Layered and mipmapped fast clear is only available from Gen8 onwards. */
+ assert(ISL_DEV_GEN(batch->blorp->isl_dev) >= 8 ||
+ (level == 0 && layer == 0));
+
brw_blorp_surface_info_init(batch->blorp, &params.dst, surf,
- 0 /* level */, 0 /* layer */, format, true);
+ level, layer, format, true);
/* From the Ivy Bridge PRM, Vol2 Part1 11.9 "Render Target Resolve":
*