summaryrefslogtreecommitdiffstats
path: root/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
diff options
context:
space:
mode:
authorTopi Pohjolainen <topi.pohjolainen@intel.com>2016-04-24 10:45:48 +0300
committerTopi Pohjolainen <topi.pohjolainen@intel.com>2016-05-12 19:49:22 +0300
commit1ca02b6ebb424489d7c16be26a9f96359bbce25a (patch)
tree18fb145cee59fb88319b8c7e2484d70f3e2aa14c /src/mesa/drivers/dri/i965/intel_mipmap_tree.c
parenta6e0f1cc7fff4009ea204c75d3f8a2f1e26e42ef (diff)
downloadexternal_mesa3d-1ca02b6ebb424489d7c16be26a9f96359bbce25a.zip
external_mesa3d-1ca02b6ebb424489d7c16be26a9f96359bbce25a.tar.gz
external_mesa3d-1ca02b6ebb424489d7c16be26a9f96359bbce25a.tar.bz2
i965: Add flag telling if miptree is for client consumption
Consider later on adding specific disable flags such as MIPTREE_LAYOUT_DISABLE_AUX_MCS = 1 << 3, /* CCS_D */ MIPTREE_LAYOUT_DISABLE_AUX_CCS_E = 1 << 4, MIPTREE_LAYOUT_DISABLE_AUX = MIPTREE_LAYOUT_DISABLE_AUX_MCS | MIPTREE_LAYOUT_DISABLE_AUX_CCS_E, and equivalent boolean/enums into miptree. Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com> Reviewed-by: Ben Widawsky <ben@bwidawsk.net>
Diffstat (limited to 'src/mesa/drivers/dri/i965/intel_mipmap_tree.c')
-rw-r--r--src/mesa/drivers/dri/i965/intel_mipmap_tree.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
index 86fe07d..8f6dc24 100644
--- a/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
+++ b/src/mesa/drivers/dri/i965/intel_mipmap_tree.c
@@ -392,6 +392,7 @@ intel_miptree_create_layout(struct brw_context *brw,
mt->logical_depth0 = depth0;
mt->fast_clear_state = INTEL_FAST_CLEAR_STATE_NO_MCS;
mt->disable_aux_buffers = (layout_flags & MIPTREE_LAYOUT_DISABLE_AUX) != 0;
+ mt->is_scanout = (layout_flags & MIPTREE_LAYOUT_FOR_SCANOUT) != 0;
exec_list_make_empty(&mt->hiz_map);
mt->cpp = _mesa_get_format_bytes(format);
mt->num_samples = num_samples;
@@ -898,7 +899,7 @@ intel_update_winsys_renderbuffer_miptree(struct brw_context *intel,
height,
1,
pitch,
- 0);
+ MIPTREE_LAYOUT_FOR_SCANOUT);
if (!singlesample_mt)
goto fail;
@@ -957,8 +958,8 @@ intel_miptree_create_for_renderbuffer(struct brw_context *brw,
bool ok;
GLenum target = num_samples > 1 ? GL_TEXTURE_2D_MULTISAMPLE : GL_TEXTURE_2D;
const uint32_t layout_flags = MIPTREE_LAYOUT_ACCELERATED_UPLOAD |
- MIPTREE_LAYOUT_TILING_ANY;
-
+ MIPTREE_LAYOUT_TILING_ANY |
+ MIPTREE_LAYOUT_FOR_SCANOUT;
mt = intel_miptree_create(brw, target, format, 0, 0,
width, height, depth, num_samples,