mirror of
https://github.com/shadps4-emu/shadPS4.git
synced 2026-10-12 02:22:27 +00:00
texture_cache: initialize added depth-overlap subresources (#5229)
* texture_cache: initialize added depth-overlap subresources [skip ci] AI-assisted extraction and verification by Codex. Human code/comment review and human-written PR text required before upstream submission. Source integration: e6cf874a170c528068627bb43f2c6bc2e89e4375. Original commits: e78385ae. * tests: remove depth-overlap fixture after review [skip ci] Remove the standalone depth-growth CMake target and modeled regression fixture as requested in upstream PR #5229. The five-line production initialization fix is unchanged. Validation: inspected the exact file diff; no new build or test run because only the standalone test files were removed. The prior fixture results and limitations remain in the earlier commit history. AI-assisted change by Codex.
This commit is contained in:
@@ -244,6 +244,11 @@ ImageId TextureCache::ResolveDepthOverlap(const ImageInfo& requested_info, Bindi
|
||||
// Inherit image usage
|
||||
auto& new_image = slot_images[new_image_id];
|
||||
new_image.usage = cache_image.usage;
|
||||
if (new_info.num_samples == 1 &&
|
||||
(new_info.resources.layers > cache_image.info.resources.layers ||
|
||||
new_info.resources.levels > cache_image.info.resources.levels)) {
|
||||
RefreshImage(new_image);
|
||||
}
|
||||
new_image.flags &= ~ImageFlagBits::Dirty;
|
||||
// When creating a depth buffer through overlap resolution don't clear it on first use.
|
||||
new_image.info.meta_info.htile_clear_mask = 0;
|
||||
|
||||
Reference in New Issue
Block a user