Files
metal2vulkan/crates
Anees Iqbal 7dbc98a73b Hold an sRGB RGBX write within the device encode's bound of its twin's
rgbx_writes_store_green_as_x writes the same floats into an RGBX texture and
its RGBA8 twin, and requires equal bytes with X equal to green. For the sRGB
twin, both writes are the MSL transfer by the device's `Pow` (FAST-PATHS row
67: an 8-bit sRGB storage texture through its UNORM alias). Each is within one
code of Metal's (PrecisionNote::DevicePackConversion). The two modules' `Pow`
answer otherwise for two of the 256 texels on the Apple M3 Max through
MoltenVK 1.4.2, a code apart.

What changed:
- An sRGB texel passes if its X field is its own green exactly and each field
  is within SRGB_WRITES_APART (2) codes of the twin's, one code from Metal's
  on each side.
- Where such texels occur, device-pack-conversion must have been announced.
- Non-sRGB formats are still held to the twin's bytes.

Verified: the test passes on the Apple M3 Max through MoltenVK 1.4.2
(--cfg m2v_gpu), with two texels within the bound.

(cherry picked from commit 178ae2f517cbf03bfbb6d918c600072292f9a12f)
(cherry picked from commit fca95e4b465dc4b0ac71cb6c9d3521198443b5fc)
2026-11-03 02:03:17 -08:00
..