Simple Shader with SampleTexture2D is crashing on VisionOs

We have a simple shadergraph shader with a SampleTexutre2D, but it seems to be crashing on vision os with:

MTLDebugValidateMTLPixelFormat, line 1499: error ‘pixelFormat (40) is not a valid MTLPixelFormat.’

Is that node currently not supported?

And is there a list of supported/unsupported nodes?

It is supported. However, it sounds like the texture format you’re using is not. Format 40 is MTLPixelFormatB5G6R5Unorm, which should be supported according to the docs, but we haven’t tested with every format. Is this a RenderTexture, by any chance? RenderTextures only support a limited number of formats, and we’ve only really tested with RGBA32 and RGBAHalf. At any rate, using a different texture format should resolve the issue.

Yes, it’s here.

It is a simple color texture we sample to adjust team colors for the units.

We used RGB 16bit for the textures. We will try different formats to see if that can help resolve it.

1 Like

If that doesn’t work, feel free to submit a bug report with a repro case and let us know the incident number (IN-#####) so that we can look into it.

Switching formats worked, thank you!

1 Like