public record class TexturedNormalMapFeatureReplaces the shading normal from a tangent-space normal map.
Remarks
What NormalMapFeature could not be for as long as a feature could not sample. That one carries a single NormalTS constant, which bends a whole surface one way and is a normal map in name only — useful for a decal or a test and nothing an artist authored.
Same seat as TexturedMetalRoughnessFeature and the same conditions: a name rather than a handle, a device with HasBindless, and a host that paired the name through MaterialRenderFeature.TextureIndices. Without the pairing the index stays zero and the surface is shaded by the table's fallback read as a normal, which is why the fallback being obviously not a surface matters twice over.
Composes beside a base surface rather than replacing one: it writes normalWS and touches nothing else, so a material is a textured base colour and a textured normal, which is the shape every other feature in the chain has.
Fields and properties (3)
public string NormalMapWhat the material calls the tangent-space normal map it wants sampled.
public float StrengthHow far the normal is bent, where 1 is as authored.
public string ShaderNameThe Raven shader implementing this feature, from Raven/Library/Material.
Methods (2)
public static string NormalIndexParameter(string path)What the shader calls the slot, under a composition path.
public void Compile(MaterialCompilationContext context)Writes this feature's parameters, and fills any slots of its own.
Used by (5)
- FrameDocumentTestsThirdPersonShooter.Frame.Tests
- TexturedMaterialTestsVixen.Rendering.Tests
- TypeRegistrationVixen.Rendering
- Vixen_Rendering_Materials_TexturedNormalMapFeatureSerializerVixen.Rendering
- WorldRendererVixen.Engine.Renderer