Texture layout validation accepts multisampled BC formats #356

Closed
opened 2026-11-27 21:21:10 +00:00 by Damokles2 · 2 comments
Damokles2 commented 2026-11-27 21:21:10 +00:00 (Migrated from github.com)
Contributor

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by Damokles2 on 2026-11-27T21:21:10Z.


I found a small CPU-reproducible texture layout validation issue in victory-formats.

Layout::new() currently accepts a 4×4 BC1_UNORM texture with four samples and SW_64KB_R_X, returning a 65,536-byte allocation.

Single-sample BC1 and four-sample RGBA8 both pass as expected.

D3D12 does not support multisampled BC1 resources.

I am investigating whether compressed formats should be explicitly rejected by the multisample layout validation.

Original VIctory PR Marvisak/VIctory#3385 changes the related swizzle validation but does not address this format combination.

Is anyone already working on this? If not, I would like to prepare a small correction with synthetic CPU regression tests.

AI-assisted with OpenAI Codex.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:issue:6654651759 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/356). Originally posted by [Damokles2](https://github.com/Damokles2) on 2026-11-27T21:21:10Z. --- I found a small CPU-reproducible texture layout validation issue in victory-formats. Layout::new() currently accepts a 4×4 BC1_UNORM texture with four samples and SW_64KB_R_X, returning a 65,536-byte allocation. Single-sample BC1 and four-sample RGBA8 both pass as expected. D3D12 does not support multisampled BC1 resources. I am investigating whether compressed formats should be explicitly rejected by the multisample layout validation. Original VIctory PR Marvisak/VIctory#3385 changes the related swizzle validation but does not address this format combination. Is anyone already working on this? If not, I would like to prepare a small correction with synthetic CPU regression tests. AI-assisted with OpenAI Codex.
trustno1-coder commented 2026-11-28 00:43:50 +00:00 (Migrated from github.com)
Author
Contributor

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by trustno1-coder on 2026-11-28T00:43:50Z.


Thanks, that's a good catch. Go ahead: a small correction with CPU tests is welcome as a pull request.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7231149148 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/356#issuecomment-7231149148). Originally posted by [trustno1-coder](https://github.com/trustno1-coder) on 2026-11-28T00:43:50Z. --- Thanks, that's a good catch. Go ahead: a small correction with CPU tests is welcome as a pull request.
trustno1-coder commented 2026-11-28 02:50:31 +00:00 (Migrated from github.com)
Author
Contributor

Imported from trustno1-coder/VIctory-NVIDIA. Originally posted by trustno1-coder on 2026-11-28T02:50:31Z.


Fixed in v2026.11.27.10 by #386 (Damokles2): multisampled block-compressed texture layouts are now refused.

<!-- greyfinch-sync:trustno1-coder/VIctory-NVIDIA:comment:7232628310 --> Imported from [trustno1-coder/VIctory-NVIDIA](https://github.com/trustno1-coder/VIctory-NVIDIA/issues/356#issuecomment-7232628310). Originally posted by [trustno1-coder](https://github.com/trustno1-coder) on 2026-11-28T02:50:31Z. --- Fixed in [v2026.11.27.10](https://github.com/trustno1-coder/VIctory-NVIDIA/releases/tag/v2026.11.27.10) by #386 (Damokles2): multisampled block-compressed texture layouts are now refused.
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
trustno1-coder/VIctory-NVIDIA#356
No description provided.