public record class TexturedOrmFeatureOcclusion, roughness and metalness from one packed map — R, G and B in that order.
Remarks
The packing every pipeline converged on, and it matters beyond tidiness: a streaming pool is bounded in pages, so three maps per material would spend three times the residency on the same information. OcclusionMap is a float — the whole of what a material could say about occlusion before this — and roughness and metalness were constants on the base workflow.
⚠ It reads the base albedo back out of the surface, so the feature before it must leave its own metalness at zero. At metalness zero the base workflow writes the albedo into diffuseColor untouched and f0 at the dielectric constant, which is recoverable; at any other value the albedo has already been split between the two channels by a factor this cannot see. A material that sets metalness on its base feature and supplies one from a map is asking two things for one channel — the map wins, and what it multiplies is whatever the split left behind.
Same conditions as every other sampling feature: a name rather than a handle, a device with HasBindless, and a host that paired the name through MaterialRenderFeature.TextureIndices.
Fields and properties (5)
public string OrmMapWhat the material calls the packed map it wants sampled.
public float OcclusionStrengthHow much of the map's occlusion is applied, 0 for none.
public float RoughnessWhat the map's roughness channel is scaled by.
public float MetalnessAnd its metalness channel.
public string ShaderNameThe Raven shader implementing this feature, from Raven/Library/Material.
Methods (2)
public static string OrmIndexParameter(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_TexturedOrmFeatureSerializerVixen.Rendering
- WorldRendererVixen.Engine.Renderer