Render Tests : GLSL vs MSL Review
Tests to Review
These are the results of GLSL vs MSL both running on Mac.
Tests are filtered for RMS difference of 0.003
The image addressing modes also hav unexpected "shading" for vclamp, and umirror. There are no bxdf nodes in this test. The other modes do not show this.
Leaving a ping with @dleex and @lkerley as a heads up. I'd like to propose that the Metal results be used as the "reference" for hardware rasterizers but need input as for the diffs here and other outstanding diffs logged. Thanks.
IMO, address modes should be inside the shader. It's ugly that it's relying on API settings as it seems Metal does not support "clamp to border color".
Metal does have a clamp to border color mode - but you can not specify arbitrary colors, just black, white or transparent - I think.
I agree as we find we need to be more portable across more platforms and languages it's probably best if we control of our own destiny and explicitly implement these features in the shader code we control.
Thanks for looking into these diffs. I saw that the color clamp sets no mode at all. Maybe someone could take a look. Frankly, some of these modes are super old and have a hard time matching to OSL as well, so might be worth consider dropping them.
For lighting setup inconsistencies it would be good to make this simpler. It's pretty onerous currently.
In what sense are you seeing lighting setup inconsistencies? between GLSL and MSL? or other render targets?
This was showing up as completely the incorrect shader being rendered sometimes in CI. I ran this locally and I'm getting this really weird result running locally. I have no idea what might be causing this -- seems to be rendering one on top of another ?. This is with SHA: f296eaa01c5034ab67d75985fc397adc6582364d.
My only wild guess is some state is being left behind / not re-initialized ?
I feel like I might have seen this locally the other day - and just chalked it up to a gremlin - but I'll keep an eye out - interestingly it was with this exactly same test too - I wonder if some hash somewhere (shader cache?) accidentally matches.