Skip to content

Commit

Permalink
Fix a rendering corruption for CCS format texture
Browse files Browse the repository at this point in the history
This is a workaround solution to fix rendering corruption
for CCS format texture when copying the compressed data.

TODO: Improve this solution
when identifying the true root cause of this issue.

Tracked-On: OAM-113382
Signed-off-by: Li,Gaoshun <[email protected]>
  • Loading branch information
gaoshunli authored and ShenghuaLinINTEL committed Feb 26, 2024
1 parent bc94661 commit 900ea1b
Showing 1 changed file with 9 additions and 0 deletions.
9 changes: 9 additions & 0 deletions src/gallium/drivers/iris/iris_resource.c
Original file line number Diff line number Diff line change
Expand Up @@ -2746,6 +2746,15 @@ iris_texture_subdata(struct pipe_context *ctx,
isl_aux_usage_has_compression(res->aux.usage) ||
resource_is_busy(ice, res) ||
iris_bo_mmap_mode(res->bo) == IRIS_MMAP_NONE) {
/* This is a workaround solution to fix rendering corruption
* for CCS format texture when copying the compressed data.
*
* TODO: Improve this solution when identifying the true root cause of this issue.
*/
iris_foreach_batch(ice, batch) {
if (iris_batch_references(batch, res->bo))
iris_batch_flush(batch);
}
return u_default_texture_subdata(ctx, resource, level, usage, box,
data, stride, layer_stride);
}
Expand Down

0 comments on commit 900ea1b

Please sign in to comment.