mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2025-12-26 23:40:10 +01:00
v3d: Use u_box_pixels_to_blocks helper
Rather than open-coding. Signed-off-by: Alyssa Rosenzweig <alyssa@collabora.com> Reviewed-by: Emma Anholt <emma@anholt.net> Reviewed-by: Juan A. Suarez <jasuarez@igalia.com> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14370>
This commit is contained in:
parent
b920ace4bc
commit
6f07159a1d
1 changed files with 1 additions and 6 deletions
|
|
@ -283,12 +283,7 @@ v3d_resource_transfer_map(struct pipe_context *pctx,
|
|||
*pptrans = ptrans;
|
||||
|
||||
/* Our load/store routines work on entire compressed blocks. */
|
||||
ptrans->box.x /= util_format_get_blockwidth(format);
|
||||
ptrans->box.y /= util_format_get_blockheight(format);
|
||||
ptrans->box.width = DIV_ROUND_UP(ptrans->box.width,
|
||||
util_format_get_blockwidth(format));
|
||||
ptrans->box.height = DIV_ROUND_UP(ptrans->box.height,
|
||||
util_format_get_blockheight(format));
|
||||
u_box_pixels_to_blocks(&ptrans->box, &ptrans->box, format);
|
||||
|
||||
struct v3d_resource_slice *slice = &rsc->slices[level];
|
||||
if (rsc->tiled) {
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue