I'm porting the substance designer metal rough shader over to shaderFX for 3dsmax (2017 in this case) and I'm getting a black seam at what looks like the ends of my environment map - I can't work out what's causing it for the life of me. (I'm aware it's tipped over 90degrees, I'll sort that later)
The specularIBL and diffuse IBLs in use are substance's panorama map run through cmft studio, they're sampled in a custom code node and I'm using the same importance sampling algorithms as allegorithmic. It doesn't seem to make any difference if I switch environment maps or don't use .hdr etc etc
edit: I should point out I'm using panoramas rather than cubemaps
I'm having the same seam issue in Maya. Does anyone who actually knows how this sort of stuff works have a clue as to where I should start looking ?
ta
Replies
I've seen this before, the issue is actually present in the substance shaders too, I was never able to diagnose where this seam came from since I assumed the texture lookup would just repeat when doing the equirectangular sampling. I took a look around and couldn't find much information about it but it does seem to be tied to texture resolution IIRC, the higher size env map, the smaller the seam.
Let me know if you find anything else too!
EDIT:
Apparently my Google-Fu is better today than it was a few months ago:
https://makc3d.wordpress.com/2017/01/19/sampling-equirectangular-textures/
Last point mentions the seam, they use a seam mask to get rid of it, could be a good starting point. I'll keep looking for a more elegant solution!
You might be able to get away with setting the texture mode to clamp
a brief look at the seam mask thing makes some sense - it's a bit crap though IMO ..
I'll give it a crack later..
I scratched my head for a bit and then asked a render programmer.
Assuming I understood what I was told, it turns out the seam was caused by mipping - the GPU knows that the UVs are far apart but the positions are very close together so it thinks what it's drawing is a very long way away and thus drops to a very low mip
The quick (and acceptable) fix is to force the sampler to use the top mip - This works fine because I'm using a precomputed diffuse IBL.
The proper solution sounded very complicated and I got lost halfway through the conversation.
.. now I just have to work out how to make the texture point in the right direction...