Material things with stride

Hello there! im trying to create a template for materials , i want to expose doubts and weird thing i found along the way feel free to expose them too.

First one comes with normalsmaps,
im trying to create a color that gives a zero normal offset, as i saw in other places should be
R:0.5 G:0.5 B:1 for some reason that doesnt works in gamma stride, seems that normal shader is quite displaced,
image
here comes the right color input for a zero normal input and the output of stride…


so… when stride no normalmap input is like that,., whats wrong?

any ideas?

There is some flag “Reconstruct Z” for normal maps in stride editor, they work as expected of you set this flag to true. I’m suspecting is some sort of flag to apply inverse transpose in shader or another calculation… Do you have this flag set?

Yes i saw that flag before, doesnt affect to the shading at all, seems more belong to other thing. would be nice to find it, as is nice when there is no normal map to get the same as we have it, and use color for normal set
lets check what can be thanks antokhio

image

best solution as you dont get a normal map is disable,
but the other question keeps me wondeing

image

small hint, we have the IsAssigned node for this…

yes but still main issue is between normal and shader. so i set a color that goes to a normal value. And the color i set correspond to normal value = 0 , if its a zero normal shouldnt distort when i plug normal node for material.
Check the shots
please

Hmm, in stride editor the difference quite significant and it does affect shading, suspect that it’s maybe a bug? I think maybe you can try with stride to check what it does in there comparing to gamma?

the correct way is to disable the feature. if it is on, it will generate shader code that will make the material more expensive. if the normal map feature is off, the shader is simpler, which is good.

anthokio you catch me, yes maybe its a bug, cant test in strdie editor. would be nice we check this things maybe not everybody see it, but i feel it, i mean for resume, if you input azero normal value to a normal map in gamma the value is displaced

that is correct, but the thing is that the ColorIn expect colors in sRGB space, but normal maps are just values and are interpreted as such. you can see that the pixel format of FileTexture and FileTextureNormal is different. so what you can do is to put a sRGBToRGB node after the color, or use an upcoming preview that has the optional “Is Normal” input that you can enable.

1 Like

This topic was automatically closed 365 days after the last reply. New replies are no longer allowed.