Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

texture_cache: Implement subresource specific uploads #1451

Open
wants to merge 3 commits into
base: main
Choose a base branch
from

Conversation

raphaelthegreat
Copy link
Collaborator

It is a common pattern for games to clear specific subresources of an image (either a mipmap or a layer). Bloodborne renders to an texture cube by individually clearing the faces with compute dispatches and rendering to them. Red Dead Redemption clears the first mipmap of images that have many. Without this handling subsequent usages of said image can either clear subresources that were rendered or trash the image with cpu data if a gpu buffer doesn't happen to cover the entire image size.

Before merging, support for images with more than 64 subresources needs to be added (will trigger an assert for now).

@bigol83
Copy link
Contributor

bigol83 commented Oct 26, 2024

Red Dead Redemption has random green textures, sometimes they are on buildings, other times they are on grass
Cattura

@mizinin
Copy link

mizinin commented Oct 27, 2024

Red Dead Redemption has random green textures, sometimes they are on buildings, other times they are on grass

Same in Bloodborne
1

@raphaelthegreat
Copy link
Collaborator Author

raphaelthegreat commented Oct 27, 2024

There is a complement change to this PR in the works that should fix the RDR issue, as this PR exposes the preexisting problem. For BB not sure, we will see

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants