[PR #201] [MERGED] Proper color buffers color handling and various fixes #1389

Closed
opened 2026-02-27 21:12:21 +03:00 by kerem · 0 comments
Owner

📋 Pull Request Information

Original PR: https://github.com/shadps4-emu/shadPS4/pull/201
Author: @psucien
Created: 6/15/2024
Status: Merged
Merged: 6/15/2024
Merged by: @georgemoralis

Base: mainHead: stabilization_4


📝 Commits (10+)

  • 1e69f83 libraries: fix for Windows crash during LLE libc initialization
  • be6f523 renderer_vulkan: fixed buffers alignments
  • 142ad54 gnmdriver: fix for pm4 dump name in some erroneous cases
  • a0fe34b tracy: added PthreadMutex markup
  • 37cbdad renderer_vulkan: static vector for vertex buffers ranges
  • fd8ceac video_core: shaders hash switched to one from binary header
  • bdb2357 texture_cache: don't set color attachment usage flag for packed images
  • e6f773f videoout: register buffers in texture cache at VO creation time
  • b9602af renderer_vulkan: sRGB swapchain
  • b2b45bf video_core: added support for alternate CB channels order

📊 Changes

23 files changed (+164 additions, -45 deletions)

View changed files

📝 src/common/debug.h (+3 -0)
📝 src/core/libraries/gnmdriver/gnmdriver.cpp (+6 -6)
📝 src/core/libraries/kernel/thread_management.cpp (+19 -0)
📝 src/core/libraries/kernel/thread_management.h (+2 -0)
📝 src/core/libraries/videoout/driver.cpp (+1 -0)
📝 src/video_core/amdgpu/liverpool.h (+16 -1)
📝 src/video_core/renderer_vulkan/liverpool_to_vk.cpp (+27 -1)
📝 src/video_core/renderer_vulkan/liverpool_to_vk.h (+3 -0)
📝 src/video_core/renderer_vulkan/renderer_vulkan.cpp (+0 -13)
📝 src/video_core/renderer_vulkan/renderer_vulkan.h (+24 -2)
📝 src/video_core/renderer_vulkan/vk_compute_pipeline.cpp (+3 -2)
📝 src/video_core/renderer_vulkan/vk_graphics_pipeline.cpp (+3 -2)
📝 src/video_core/renderer_vulkan/vk_graphics_pipeline.h (+1 -1)
📝 src/video_core/renderer_vulkan/vk_instance.cpp (+1 -0)
📝 src/video_core/renderer_vulkan/vk_instance.h (+5 -0)
📝 src/video_core/renderer_vulkan/vk_pipeline_cache.cpp (+12 -7)
📝 src/video_core/renderer_vulkan/vk_swapchain.cpp (+3 -3)
📝 src/video_core/texture_cache/image.cpp (+15 -4)
📝 src/video_core/texture_cache/image.h (+2 -0)
📝 src/video_core/texture_cache/image_view.cpp (+8 -0)

...and 3 more files

📄 Description

In the scope of this PR several issues were addressed:

  • a crash on mutex initialization caused by regression from the previous commit
  • invalid storage buffers alignment as well as missing flag for highlighting use of std430 on uniforms
  • incorrect name for the dumped command list if it was a second submit in the first frame
  • inefficient vector container in vertex buffer ranges allocation
  • meaningless hash for shaders now is aligned to the real ucode
  • trivial fixes for various formats handling in texture cache and detiler
  • on-demand allocation of VO surfaces which resulted in a chance of picking wrong format by the texture cache
  • incorrect handling of alternate component order in color buffers
  • incorrect work with sRGB output images

Also, a tracy markup for mutexes added for better syncs introspection.


🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.

## 📋 Pull Request Information **Original PR:** https://github.com/shadps4-emu/shadPS4/pull/201 **Author:** [@psucien](https://github.com/psucien) **Created:** 6/15/2024 **Status:** ✅ Merged **Merged:** 6/15/2024 **Merged by:** [@georgemoralis](https://github.com/georgemoralis) **Base:** `main` ← **Head:** `stabilization_4` --- ### 📝 Commits (10+) - [`1e69f83`](https://github.com/shadps4-emu/shadPS4/commit/1e69f83d9e47530e493d9e4fca8367c5b1827374) libraries: fix for Windows crash during LLE libc initialization - [`be6f523`](https://github.com/shadps4-emu/shadPS4/commit/be6f523b6e63a96dec91ea0bd3a423e348f8b75e) renderer_vulkan: fixed buffers alignments - [`142ad54`](https://github.com/shadps4-emu/shadPS4/commit/142ad5487601a342f00d0bf5f57a0da084eb5326) gnmdriver: fix for pm4 dump name in some erroneous cases - [`a0fe34b`](https://github.com/shadps4-emu/shadPS4/commit/a0fe34b01f85b5354595b1c77f395c85f63e0026) tracy: added PthreadMutex markup - [`37cbdad`](https://github.com/shadps4-emu/shadPS4/commit/37cbdad57bd8f1543b9f60abcc3a0b89c7fa09ad) renderer_vulkan: static vector for vertex buffers ranges - [`fd8ceac`](https://github.com/shadps4-emu/shadPS4/commit/fd8ceacef7cf8c831e3afc34de38ca6ca1ba5647) video_core: shaders hash switched to one from binary header - [`bdb2357`](https://github.com/shadps4-emu/shadPS4/commit/bdb235716a07bd9f45a894e567b038b2ce6477f3) texture_cache: don't set color attachment usage flag for packed images - [`e6f773f`](https://github.com/shadps4-emu/shadPS4/commit/e6f773f9504e947a2b86177b26488151b0f4bad6) videoout: register buffers in texture cache at VO creation time - [`b9602af`](https://github.com/shadps4-emu/shadPS4/commit/b9602afc82d45262b82108de932fc9d13cebb56c) renderer_vulkan: sRGB swapchain - [`b2b45bf`](https://github.com/shadps4-emu/shadPS4/commit/b2b45bf480554634317b94583b2158083fa90d94) video_core: added support for alternate CB channels order ### 📊 Changes **23 files changed** (+164 additions, -45 deletions) <details> <summary>View changed files</summary> 📝 `src/common/debug.h` (+3 -0) 📝 `src/core/libraries/gnmdriver/gnmdriver.cpp` (+6 -6) 📝 `src/core/libraries/kernel/thread_management.cpp` (+19 -0) 📝 `src/core/libraries/kernel/thread_management.h` (+2 -0) 📝 `src/core/libraries/videoout/driver.cpp` (+1 -0) 📝 `src/video_core/amdgpu/liverpool.h` (+16 -1) 📝 `src/video_core/renderer_vulkan/liverpool_to_vk.cpp` (+27 -1) 📝 `src/video_core/renderer_vulkan/liverpool_to_vk.h` (+3 -0) 📝 `src/video_core/renderer_vulkan/renderer_vulkan.cpp` (+0 -13) 📝 `src/video_core/renderer_vulkan/renderer_vulkan.h` (+24 -2) 📝 `src/video_core/renderer_vulkan/vk_compute_pipeline.cpp` (+3 -2) 📝 `src/video_core/renderer_vulkan/vk_graphics_pipeline.cpp` (+3 -2) 📝 `src/video_core/renderer_vulkan/vk_graphics_pipeline.h` (+1 -1) 📝 `src/video_core/renderer_vulkan/vk_instance.cpp` (+1 -0) 📝 `src/video_core/renderer_vulkan/vk_instance.h` (+5 -0) 📝 `src/video_core/renderer_vulkan/vk_pipeline_cache.cpp` (+12 -7) 📝 `src/video_core/renderer_vulkan/vk_swapchain.cpp` (+3 -3) 📝 `src/video_core/texture_cache/image.cpp` (+15 -4) 📝 `src/video_core/texture_cache/image.h` (+2 -0) 📝 `src/video_core/texture_cache/image_view.cpp` (+8 -0) _...and 3 more files_ </details> ### 📄 Description In the scope of this PR several issues were addressed: - a crash on mutex initialization caused by regression from the previous commit - invalid storage buffers alignment as well as missing flag for highlighting use of std430 on uniforms - incorrect name for the dumped command list if it was a second submit in the first frame - inefficient vector container in vertex buffer ranges allocation - meaningless hash for shaders now is aligned to the real ucode - trivial fixes for various formats handling in texture cache and detiler - on-demand allocation of VO surfaces which resulted in a chance of picking wrong format by the texture cache - incorrect handling of alternate component order in color buffers - incorrect work with sRGB output images Also, a tracy markup for mutexes added for better syncs introspection. --- <sub>🔄 This issue represents a GitHub Pull Request. It cannot be merged through Gitea due to API limitations.</sub>
kerem 2026-02-27 21:12:21 +03:00
Sign in to join this conversation.
No milestone
No project
No assignees
1 participant
Notifications
Due date
The due date is invalid or out of range. Please use the format "yyyy-mm-dd".

No due date set.

Dependencies

No dependencies set.

Reference
starred/shadPS4#1389
No description provided.