native: HDR target dumps misdecode infinities and NaNs #411

Open
opened 2026-11-27 17:15:17 +00:00 by theappartment · 3 comments
theappartment commented 2026-11-27 17:15:17 +00:00 (Migrated from github.com)
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by theappartment on 2026-11-27T17:15:17Z.


VICTORY_DUMP_TARGETS excludes non-finite RGB values from its statistics and preview. The decoder misclassifies some of those values as finite in DXGI formats 10 (R16G16B16A16_FLOAT) and 26 (R11G11B10_FLOAT). This can inflate the reported range or show invalid channels as bright pixels while diagnosing lighting.

A synthetic RGBA16F texel with RGB words 7c00 fc00 fe00 decodes as [NaN, -65536, -98304] on main. The expected values are [+inf, -inf, NaN]. A synthetic packed texel with R/G/B fields 0x7c0 / 0x7e0 / 0x3e0 decodes as [65536, 98304, 65536]. The expected values are [+inf, NaN, +inf].

I plan to fix the diagnostic decoder and add a synthetic regression covering both formats, including finite inputs. This change affects target dumps only.

Direct3D floating-point format rules

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:issue:6651305490 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/411). Originally posted by [theappartment](https://github.com/theappartment) on 2026-11-27T17:15:17Z. --- `VICTORY_DUMP_TARGETS` excludes non-finite RGB values from its statistics and preview. The decoder misclassifies some of those values as finite in DXGI formats 10 (`R16G16B16A16_FLOAT`) and 26 (`R11G11B10_FLOAT`). This can inflate the reported range or show invalid channels as bright pixels while diagnosing lighting. A synthetic RGBA16F texel with RGB words `7c00 fc00 fe00` decodes as `[NaN, -65536, -98304]` on main. The expected values are `[+inf, -inf, NaN]`. A synthetic packed texel with R/G/B fields `0x7c0 / 0x7e0 / 0x3e0` decodes as `[65536, 98304, 65536]`. The expected values are `[+inf, NaN, +inf]`. I plan to fix the diagnostic decoder and add a synthetic regression covering both formats, including finite inputs. This change affects target dumps only. [Direct3D floating-point format rules](https://learn.microsoft.com/en-us/windows/win32/direct3d11/floating-point-rules)
theappartment commented 2026-11-27 17:15:38 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by theappartment on 2026-11-27T17:15:38Z.


/claim

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7224207714 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/411#issuecomment-7224207714). Originally posted by [theappartment](https://github.com/theappartment) on 2026-11-27T17:15:38Z. --- /claim
github-actions[bot] commented 2026-11-27 17:15:50 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by github-actions[bot] on 2026-11-27T17:15:50Z.


Claimed by @theappartment. Open a draft pull request with Refs #411 in its description within 24 hours, or the claim expires.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7224211422 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/411#issuecomment-7224211422). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-11-27T17:15:50Z. --- Claimed by @theappartment. Open a draft pull request with `Refs #411` in its description within 24 hours, or the claim expires.
github-actions[bot] commented 2026-11-28 18:59:13 +00:00 (Migrated from github.com)
Author
Contributor

Imported from LakshanSivakumar/Native-Victory-macOS. Originally posted by github-actions[bot] on 2026-11-28T18:59:13Z.


The claim by @theappartment has expired: no pull request referenced it within 24 hours. This issue is free to claim.

<!-- greyfinch-sync:LakshanSivakumar/Native-Victory-macOS:comment:7244202586 --> Imported from [LakshanSivakumar/Native-Victory-macOS](https://github.com/LakshanSivakumar/Native-Victory-macOS/issues/411#issuecomment-7244202586). Originally posted by [github-actions[bot]](https://github.com/apps/github-actions) on 2026-11-28T18:59:13Z. --- The claim by @theappartment has expired: no pull request referenced it within 24 hours. This issue is free to claim.
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
LakshanSivakumar/Native-Victory-macOS#411
No description provided.