intel: revive intel_layout_get_slice_tile_offset()
Surface Base Address are required to be page-aligned when the surface is
tiled. When one wants to directly point to a single miplevel or a single
array layer, one has to leverage X Offset and Y Offset to keep Surface Base
Address page-aligned. This function can return valid
(Surface Base Address, X Offset, Y Offset)
for any given subresource.
diff --git a/icd/intel/layout.h b/icd/intel/layout.h
index fb36ee6..bf26190 100644
--- a/icd/intel/layout.h
+++ b/icd/intel/layout.h
@@ -292,4 +292,9 @@
layout->bo_height * layout->block_height);
}
+unsigned
+intel_layout_get_slice_tile_offset(const struct intel_layout *layout,
+ unsigned level, unsigned slice,
+ unsigned *x_offset, unsigned *y_offset);
+
#endif /* LAYOUT_H */