diff options
author | Jason Ekstrand <jason.ekstrand@intel.com> | 2016-07-19 19:04:03 -0700 |
---|---|---|
committer | Jason Ekstrand <jason.ekstrand@intel.com> | 2016-08-17 14:46:22 -0700 |
commit | 75deae9c9064382976aa261e1ff3057939c22cd5 (patch) | |
tree | d33069c8008a522f0e7cd67fb1cfa818c259e36e /src/mesa/drivers/dri/i965/brw_blorp.h | |
parent | 57664c869ffcea436449f77a36dd6538c934c125 (diff) |
i965/blorp: Add a new brw_blorp_surf intermediate struct
At the moment, this seems to make all of the interfaces messier rather than
clener. However, it does provide a representation of a surface that
simultaneously contains everything and is completely unaware of miptrees.
Reviewed-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Diffstat (limited to 'src/mesa/drivers/dri/i965/brw_blorp.h')
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_blorp.h | 30 |
1 files changed, 28 insertions, 2 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_blorp.h b/src/mesa/drivers/dri/i965/brw_blorp.h index d3697984ce7..ed6af838b4e 100644 --- a/src/mesa/drivers/dri/i965/brw_blorp.h +++ b/src/mesa/drivers/dri/i965/brw_blorp.h @@ -35,6 +35,32 @@ struct brw_wm_prog_key; extern "C" { #endif +struct brw_blorp_surf +{ + const struct isl_surf *surf; + drm_intel_bo *bo; + uint32_t offset; + + const struct isl_surf *aux_surf; + drm_intel_bo *aux_bo; + uint32_t aux_offset; + enum isl_aux_usage aux_usage; + + union isl_color_value clear_color; +}; + +void +brw_blorp_surf_for_miptree(struct brw_context *brw, + struct brw_blorp_surf *surf, + struct intel_mipmap_tree *mt, + bool is_render_target, + unsigned *level, + struct isl_surf tmp_surfs[2]); + +enum isl_format +brw_blorp_to_isl_format(struct brw_context *brw, mesa_format format, + bool is_render_target); + void brw_blorp_blit_miptrees(struct brw_context *brw, struct intel_mipmap_tree *src_mt, @@ -91,9 +117,9 @@ struct brw_blorp_surface_info void brw_blorp_surface_info_init(struct brw_context *brw, struct brw_blorp_surface_info *info, - struct intel_mipmap_tree *mt, + const struct brw_blorp_surf *surf, unsigned int level, unsigned int layer, - mesa_format format, bool is_render_target); + enum isl_format format, bool is_render_target); struct brw_blorp_coord_transform |