ail: Add compression_layer_stride_B field
So we can index into the compression buffer of layered images. Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/20446>
This commit is contained in:
@@ -220,7 +220,8 @@ ail_initialize_compression(struct ail_layout *layout)
|
||||
height_px = DIV_ROUND_UP(height_px, 2);
|
||||
}
|
||||
|
||||
layout->size_B += compbuf_B * layout->depth_px;
|
||||
layout->compression_layer_stride_B = compbuf_B;
|
||||
layout->size_B += layout->compression_layer_stride_B * layout->depth_px;
|
||||
}
|
||||
|
||||
void
|
||||
|
||||
@@ -125,6 +125,9 @@ struct ail_layout {
|
||||
/* Offset of the start of the compression metadata buffer */
|
||||
uint32_t metadata_offset_B;
|
||||
|
||||
/* Stride between subsequent layers in the compression metadata buffer */
|
||||
uint32_t compression_layer_stride_B;
|
||||
|
||||
/* Size of entire texture */
|
||||
uint32_t size_B;
|
||||
};
|
||||
|
||||
Reference in New Issue
Block a user