mirror of
https://gitlab.freedesktop.org/mesa/mesa.git
synced 2026-05-05 05:18:08 +02:00
asahi: Legalize compression before blitting
Fixes invalid recursive blitting. Signed-off-by: Alyssa Rosenzweig <alyssa@rosenzweig.io> Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/24635>
This commit is contained in:
parent
7ac6176ea5
commit
ae81eb9d50
3 changed files with 14 additions and 1 deletions
|
|
@ -63,6 +63,15 @@ agx_blit(struct pipe_context *pipe, const struct pipe_blit_info *info)
|
|||
unreachable("Unsupported blit");
|
||||
}
|
||||
|
||||
/* Legalize compression /before/ calling into u_blitter to avoid recursion.
|
||||
* u_blitter bans recursive usage.
|
||||
*/
|
||||
agx_legalize_compression(ctx, agx_resource(info->dst.resource),
|
||||
info->dst.format);
|
||||
|
||||
agx_legalize_compression(ctx, agx_resource(info->src.resource),
|
||||
info->src.format);
|
||||
|
||||
agx_blitter_save(ctx, ctx->blitter, info->render_condition_enable);
|
||||
util_blitter_blit(ctx->blitter, info);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@
|
|||
#include "agx_tilebuffer.h"
|
||||
#include "pool.h"
|
||||
|
||||
static void
|
||||
void
|
||||
agx_legalize_compression(struct agx_context *ctx, struct agx_resource *rsrc,
|
||||
enum pipe_format format)
|
||||
{
|
||||
|
|
|
|||
|
|
@ -657,6 +657,10 @@ agx_map_texture_gpu(struct agx_resource *rsrc, unsigned z)
|
|||
void agx_decompress(struct agx_context *ctx, struct agx_resource *rsrc,
|
||||
const char *reason);
|
||||
|
||||
void agx_legalize_compression(struct agx_context *ctx,
|
||||
struct agx_resource *rsrc,
|
||||
enum pipe_format format);
|
||||
|
||||
struct agx_transfer {
|
||||
struct pipe_transfer base;
|
||||
void *map;
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue