WIP: dds_png: decode R8G8 integer previews #2319

Merged
leonida/mandy
ZroIsHere merged 1 commit from fix/dds-png-rg8-integer into main 2026-11-26 18:28:49 +00:00

Pull request successfully merged and closed

ZroIsHere commented 2026-11-26 13:46:08 +00:00

Summary

Add DDS preview decoding for DXGI R8G8_UINT (format 50) and R8G8_SINT (format 52). UINT channel bytes map directly to PNG red and green. SINT values map from the signed integer range [-128, 127] to [0, 255] by adding 128. Blue is zero and alpha is opaque.

The decoder validates row pitch and truncated payloads. Update the tex_export.py help text to include both formats.

Validation

  • git diff --check
  • Python AST parse
  • Tests not run.
## Summary Add DDS preview decoding for DXGI R8G8_UINT (format 50) and R8G8_SINT (format 52). UINT channel bytes map directly to PNG red and green. SINT values map from the signed integer range [-128, 127] to [0, 255] by adding 128. Blue is zero and alpha is opaque. The decoder validates row pitch and truncated payloads. Update the tex_export.py help text to include both formats. ## Validation - git diff --check - Python AST parse - Tests not run.
aslan2142 commented 2026-11-26 18:29:01 +00:00

Merged through the integration PR #2394 (DDS preview formats batch), as head 81df9f5ed, with a merge commit, so your commits stay yours.

  • Test added: a synthetic test for R8G8_UINT and R8G8_SINT, with padded rows and truncation.
  • Decoder: unchanged.

Thanks @ZroIsHere.

AI-assisted (Claude Code, Claude Opus 5.5 and Claude Fable 5.2)

Merged through the integration PR #2394 (DDS preview formats batch), as head `81df9f5ed`, with a merge commit, so your commits stay yours. - **Test added:** a synthetic test for R8G8_UINT and R8G8_SINT, with padded rows and truncation. - **Decoder:** unchanged. Thanks @ZroIsHere. AI-assisted (Claude Code, Claude Opus 5.5 and Claude Fable 5.2)
Sign in to join this conversation.
No description provided.