aboutsummaryrefslogtreecommitdiffstats
path: root/src/mesa
diff options
context:
space:
mode:
authorChad Versace <[email protected]>2011-05-31 14:18:22 -0700
committerChad Versace <[email protected]>2011-06-08 10:06:40 -0700
commit84294fe26ca5860c34e6541f633be4d093ab57f2 (patch)
tree764e9619390d1f8830c52e775e08ed36689f5637 /src/mesa
parentbeb8b7da20c862549b96a500226caf3a610342d9 (diff)
intel: Add function intel_renderbuffer_set_hiz_region()
It's the analog of intel_renderbuffer_set_region(), but for the hiz region of course. CC: Ian Romanick <[email protected]> CC: Kristian Høgsberg <[email protected]> Acked-by: Eric Anholt <[email protected]> Reviewed-by: Kenneth Graunke <[email protected]> Signed-off-by: Chad Versace <[email protected]>
Diffstat (limited to 'src/mesa')
-rw-r--r--src/mesa/drivers/dri/intel/intel_fbo.c12
-rw-r--r--src/mesa/drivers/dri/intel/intel_fbo.h5
2 files changed, 17 insertions, 0 deletions
diff --git a/src/mesa/drivers/dri/intel/intel_fbo.c b/src/mesa/drivers/dri/intel/intel_fbo.c
index 7434e0efff6..83f622d437e 100644
--- a/src/mesa/drivers/dri/intel/intel_fbo.c
+++ b/src/mesa/drivers/dri/intel/intel_fbo.c
@@ -321,6 +321,18 @@ intel_renderbuffer_set_region(struct intel_context *intel,
}
+void
+intel_renderbuffer_set_hiz_region(struct intel_context *intel,
+ struct intel_renderbuffer *rb,
+ struct intel_region *region)
+{
+ struct intel_region *old = rb->hiz_region;
+ rb->hiz_region = NULL;
+ intel_region_reference(&rb->hiz_region, region);
+ intel_region_release(&old);
+}
+
+
/**
* Create a new intel_renderbuffer which corresponds to an on-screen window,
* not a user-created renderbuffer.
diff --git a/src/mesa/drivers/dri/intel/intel_fbo.h b/src/mesa/drivers/dri/intel/intel_fbo.h
index 212dd9aadc8..e9929b095ff 100644
--- a/src/mesa/drivers/dri/intel/intel_fbo.h
+++ b/src/mesa/drivers/dri/intel/intel_fbo.h
@@ -113,6 +113,11 @@ intel_renderbuffer_set_region(struct intel_context *intel,
struct intel_renderbuffer *irb,
struct intel_region *region);
+extern void
+intel_renderbuffer_set_hiz_region(struct intel_context *intel,
+ struct intel_renderbuffer *rb,
+ struct intel_region *region);
+
extern struct intel_renderbuffer *
intel_create_renderbuffer(gl_format format);