Needed to transfer.
Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/12053>
return &nresource->base;
}
+static uint8_t *
+agx_rsrc_offset(struct agx_resource *rsrc, unsigned level, unsigned z)
+{
+ struct agx_bo *bo = rsrc->bo;
+ uint8_t *map = ((uint8_t *) bo->ptr.cpu) + rsrc->slices[level].offset;
+ map += z * rsrc->array_stride;
+
+ return map;
+}
+
static void
agx_resource_destroy(struct pipe_screen *screen,
struct pipe_resource *prsrc)