AGC: samplers with DISABLE_CUBE_WRAP are rejected, so ps5-opengl titles stop at their first sampler (PPSA99005) #2577

Closed
opened 2026-10-10 06:50:28 +00:00 by AlxcBTW · 1 comment
AlxcBTW commented 2026-10-10 06:50:28 +00:00 (Migrated from github.com)
Contributor

Imported from boykopovar/AnyPS5. Originally posted by AlxcBTW on 2026-10-10T06:50:28Z.


PPSA99005 (ps5-opengl showcase) stops at guest sampler descriptor disables seamless cube filtering which is not implemented. ps5-opengl's Mesa sets DISABLE_CUBE_WRAP (S# word 0 bit 28) on every sampler, because non-seamless cube maps are GL's default.

Cause

DecodeSamplerResource rejects the bit. Vulkan has the same mode: RADV sets DISABLE_CUBE_WRAP exactly when a sampler is created with VK_SAMPLER_CREATE_NON_SEAMLESS_CUBE_MAP_BIT_EXT (Mesa 35b085c4, src/amd/vulkan/radv_sampler.c:214,230, src/amd/common/ac_descriptors.c:123).

Fix

AlxcBTW:fix/agc-non-seamless-cube (ab27ae2c, on main c963432d). Full CI, with the change merged into main c72d5ce1, passes on Linux, macOS and Windows. I can't open it as a PR while intake is limited, so it's here if a collaborator wants to cherry-pick it.

  • The device enables VK_EXT_non_seamless_cube_map when nonSeamlessCubeMap is supported, and samplers with the bit are created with VK_SAMPLER_CREATE_NON_SEAMLESS_CUBE_MAP_BIT_EXT.
  • The bit only changes cube filtering. Without the extension the sampler is still created, and only a cube texture sampled through it throws (RequireNonSeamlessCube, checked where RequireDegammaFormat is). TechnicalDebt's cube texture entry is updated.

Tested

Windows 11, WinLibs GCC 15.2.0 r7, NVIDIA RTX 5070 Laptop (616.92). The Radeon 880M (AMD 2.0.353) exposes the extension too.

  • agc_driver_graphics covers decoding, the create flag with and without the device feature, and the cube-only rejection. ctest -R ^agc: 269/269.
  • PPSA99005 with its import PRs merged gets past the sampler (the full chain is in #2026).

AI-assisted: yes (Claude Code).

<!-- greyfinch-sync:boykopovar/AnyPS5:issue:5788929132 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/issues/2577). Originally posted by [AlxcBTW](https://github.com/AlxcBTW) on 2026-10-10T06:50:28Z. --- PPSA99005 (ps5-opengl showcase) stops at `guest sampler descriptor disables seamless cube filtering which is not implemented`. ps5-opengl's Mesa sets `DISABLE_CUBE_WRAP` (S# word 0 bit 28) on every sampler, because non-seamless cube maps are GL's default. ### Cause `DecodeSamplerResource` rejects the bit. Vulkan has the same mode: RADV sets `DISABLE_CUBE_WRAP` exactly when a sampler is created with `VK_SAMPLER_CREATE_NON_SEAMLESS_CUBE_MAP_BIT_EXT` (Mesa `35b085c4`, `src/amd/vulkan/radv_sampler.c:214,230`, `src/amd/common/ac_descriptors.c:123`). ### Fix [`AlxcBTW:fix/agc-non-seamless-cube`](https://github.com/AlxcBTW/AnyPS5/pull/1) (`ab27ae2c`, on `main` c963432d). [Full CI](https://github.com/AlxcBTW/AnyPS5/actions/runs/38021726433), with the change merged into `main` c72d5ce1, passes on Linux, macOS and Windows. I can't open it as a PR while intake is limited, so it's here if a collaborator wants to cherry-pick it. - The device enables `VK_EXT_non_seamless_cube_map` when `nonSeamlessCubeMap` is supported, and samplers with the bit are created with `VK_SAMPLER_CREATE_NON_SEAMLESS_CUBE_MAP_BIT_EXT`. - The bit only changes cube filtering. Without the extension the sampler is still created, and only a cube texture sampled through it throws (`RequireNonSeamlessCube`, checked where `RequireDegammaFormat` is). TechnicalDebt's cube texture entry is updated. ### Tested Windows 11, WinLibs GCC 15.2.0 r7, NVIDIA RTX 5070 Laptop (616.92). The Radeon 880M (AMD 2.0.353) exposes the extension too. - `agc_driver_graphics` covers decoding, the create flag with and without the device feature, and the cube-only rejection. `ctest -R ^agc`: 269/269. - PPSA99005 with its import PRs merged gets past the sampler (the full chain is in #2026). AI-assisted: yes (Claude Code).
LeandroLP23 commented 2026-10-10 08:29:55 +00:00 (Migrated from github.com)
Author
Contributor

Imported from boykopovar/AnyPS5. Originally posted by LeandroLP23 on 2026-10-10T08:29:55Z.


@AlxcBTW's ab27ae2c no longer applies to current main: Sampler.hpp and Sampler.cpp conflict with the opaque-black-border check main added in the same places (ReadsOpaqueBlackBorder, RequireBorderSwizzle). Keeping both additions resolves it; nothing else changes. Rebased commit (still authored by AlxcBTW): LeandroLP23:rebase/agc-non-seamless-cube (5fb611c8, on main 89a1fb4e, also merges cleanly onto 6cc33583).

Tested on a Radeon 860M (RDNA 3.5), AMD driver 32.0.13058.8001, which exposes VK_EXT_non_seamless_cube_map, so the device path is used rather than the fallback check. Windows 11 (26300), WinLibs GCC 15.2.0 r7, Release: all 247 agc_driver tests pass, agc_driver_graphics (which holds the new sampler tests) passes 3/3, conventions pass.

ps5-opengl doesn't reach its first sampler on Windows yet: with the imports it needs added it stops earlier, at #2580's registration error (details there).

<!-- greyfinch-sync:boykopovar/AnyPS5:comment:6095690449 --> Imported from [boykopovar/AnyPS5](https://github.com/boykopovar/AnyPS5/issues/2577#issuecomment-6095690449). Originally posted by [LeandroLP23](https://github.com/LeandroLP23) on 2026-10-10T08:29:55Z. --- @AlxcBTW's ab27ae2c no longer applies to current `main`: `Sampler.hpp` and `Sampler.cpp` conflict with the opaque-black-border check `main` added in the same places (`ReadsOpaqueBlackBorder`, `RequireBorderSwizzle`). Keeping both additions resolves it; nothing else changes. Rebased commit (still authored by AlxcBTW): [`LeandroLP23:rebase/agc-non-seamless-cube`](https://github.com/LeandroLP23/AnyPS5/tree/rebase/agc-non-seamless-cube) (`5fb611c8`, on `main` 89a1fb4e, also merges cleanly onto 6cc33583). Tested on a Radeon 860M (RDNA 3.5), AMD driver 32.0.13058.8001, which exposes `VK_EXT_non_seamless_cube_map`, so the device path is used rather than the fallback check. Windows 11 (26300), WinLibs GCC 15.2.0 r7, Release: all 247 `agc_driver` tests pass, `agc_driver_graphics` (which holds the new sampler tests) passes 3/3, conventions pass. ps5-opengl doesn't reach its first sampler on Windows yet: with the imports it needs added it stops earlier, at #2580's registration error (details there).
Sign in to join this conversation.
No labels
No milestone
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.

Reference
boykopovar/AnyPS5#2577
No description provided.