diff options
author | Paul Berry <[email protected]> | 2012-09-10 11:30:14 -0700 |
---|---|---|
committer | Paul Berry <[email protected]> | 2012-09-12 14:44:12 -0700 |
commit | bc6cafa045d8de839090fe2d82716b3afbd54701 (patch) | |
tree | dd2d2073b3bcd797e34b796170534d1105885af8 | |
parent | c130ce7b2b26b4b67d4bf2b6dd1044a200efe25d (diff) |
i965/blorp: Don't create a dummy renderbuffer just to fetch image offsets.
This is unnecessary--the image offsets can be read directly out of the
miptree using intel_miptree_get_image_offset.
-rw-r--r-- | src/mesa/drivers/dri/i965/brw_blorp.cpp | 9 |
1 files changed, 1 insertions, 8 deletions
diff --git a/src/mesa/drivers/dri/i965/brw_blorp.cpp b/src/mesa/drivers/dri/i965/brw_blorp.cpp index 6acc59187d4..af1156c39b1 100644 --- a/src/mesa/drivers/dri/i965/brw_blorp.cpp +++ b/src/mesa/drivers/dri/i965/brw_blorp.cpp @@ -53,14 +53,7 @@ brw_blorp_mip_info::set(struct intel_mipmap_tree *mt, this->width = mt->level[level].width; this->height = mt->level[level].height; - /* Construct a dummy renderbuffer just to extract tile offsets. */ - struct intel_renderbuffer rb; - rb.mt = mt; - rb.mt_level = level; - rb.mt_layer = layer; - intel_renderbuffer_set_draw_offset(&rb); - x_offset = rb.draw_x; - y_offset = rb.draw_y; + intel_miptree_get_image_offset(mt, level, 0, layer, &x_offset, &y_offset); } void |