Skip to content

Latest commit

 

History

History
37 lines (20 loc) · 8.8 KB

hair-and-skin-material-properties.md

File metadata and controls

37 lines (20 loc) · 8.8 KB
description
Hair and skin shader

Hair and skin material properties

Summary

Published: Apr 05 2024 by manavortex
Last documented edit: Apr 05 2024 by manavortex

This page gives an explanation of properties for the hair and skin shaders.

Wait, that's not what I want!

Hair material

Strand_IDTexture - Paths to an identity map (.xbm).
This is a greyscale texture where every masked hair strand has a single, unique greyscale value. gradientEntriesID colour gradient in hair profile (.hp) is mapped to this texture.
Strand_GradientTexture - Paths to a root map (.xbm). This is a greyscale texture with a vertical black to white gradient from root to tip. gradientEntriesRootToTip colour gradient in hair profile (.hp) is mapped to this texture.
Strand_AlphaTexture - Paths to an opacity mask texture (.xbm). Black = fully transparent. White = fully opaque.
RoughnessScale

Scalar with a decimal value between 0 and 1.0. Determines how rough or smooth hair material look. 0 = least rough (high specular, shiny reflection characteristics). 1.0 = most rough (high diffuse, matte reflection characteristics). Hair will look unnatural if this is too low (shiny).

See#roughness-metalness for a picture

RoughnessBiasScalar with a decimal value between 0 and 1.0 that is applied between min and max RoughnessScale, which changes the suddenness of its onset.
AlphaCutoff
FlowTexture - Paths to an anisotropic rotation map (.xbm). Anisotropy is a reflection characteristic of materials with fine grooves/ridges predominately following the same direction. The reflection will become blurred and stretched perpendicular to the direction of the grooves.
FlowStrengthScalar with a decimal value between 0 and 1.0. Anisotropic materials have unique reflection characteristics as a result of their grooved/ridged surface. The more anisotropic a material is, the more its reflection is influenced (stretched/blurred) by the direction of its grooves/ridges. 0 = fully isotropic. 1.0 = fully anisotropic. Hair should have high or full anisotropy.
VertexColorStrengthScalar with a decimal value between 0 and 1.0. Determines how much influence vertex colour has in the material. Vertex colour is a mesh attribute (colour, red channel). Cyberpunk hair meshes are vertex coloured red on the cap mesh and the innermost layer of hair clumps. They fade to black at the outermost layer of hair clumps. RGB 255, 0, 0 = max dull/dark. RGB 0, 0, 0 = max bright/glossy.
ScatteringScalar with a decimal value between 0 and 1.0. Effect is not well understood at this time. Related to some internal light scattering function in hair shader. It affects the colour and reflection characterics of hair materials. There is some interaction between this and advanced game options for hair rendering. Specifically AlphaShifts R, TT, TRT (light scattering modes), single scattering and multiple scattering. Default values can be overridden with CET console commands. e.g. GameOptions.SetFloat("Editor/Characters/Hair/AlphaShifts", "TRT", 0.375000
ShadowStrength
ShadowMin
ShadowMax
ShadowRoughness
DebugHairColor
HairProfileHairParameters - Paths to a hair profile or .hp file. Hair profiles contain 2x arrays named gradientEntriesID and gradientEntriesRootToTip. Each array contains a set of colour values and gradient stop positions. They are mapped to the greyscale identity and root maps respectively, which are blended to form the hair material's base colour. Cheap method to create a large variety of editable hair colour variations without the need to use large, colour textures.

Skin material

AlbedoTexture - Paths to an albedo texture (.xbm). This texture is used to determine the base colour of skin. Most skin albedo maps are pale/caucasian and tinted darker tones via TintColor.
SecondaryAlbedoTexture - Paths to a secondary albedo texture (.xbm) with alpha transparency, which is blended with Albedo. Intended for secondary colour details like freckles. Commonly used by texture frameworks to blend tattoos with Albedo.
SecondaryAlbedoInfluence
NormalTexture - Paths to a primary global normal map (.xbm).
DetailNormalTexture - Paths to a secondary global normal map (.xbm). This is typically used for muscle/vein definition and is blended with primary normal.
RoughnessScalar with a decimal value between 0 and 1.0. Determines how wet/shiny or dry/matte skin material appears. 0 = least rough (most wet/shiny). 1.0 = most roughness (most dry/matte). See #roughness-metalness for a picture
DetailRoughnessBiasMin
DetailRoughnessBiasMax
MicroDetailUVScale01Scalar - UV scale compensation factor for microdetail_n01.xbm. See Fig. 1. Value is an integer between 0 and 100. A particular value is required for this detail normal map to tile seamlessly depending on the UV scale of the body part mesh. See Fig. 2.
MicroDetailUVScale02Scalar - UV scale compensation factor for microdetail_n02.xbm. See Fig. 1. Value is an integer between 0 and 100. A particular value is required for this detail normal map to tile seamlessly depending on the UV scale of the body part mesh. See Fig. 2.
MicroDetailTexture - Paths to a microdetail texture (.xbm). See Fig. 1. This is a tileable detail normal map, typically used for pore structures. There are 3x by default (microdetail_n01.xbm, microdetail_n02.xbm and a 2:1 combination of the two textures called microdetail_n.xbm).
MicroDetailInfluenceScalar with a decimal value between 0 and 1.0. Determines normal strength of microdetail_n01 and microdetail_n02. See Fig 1.
TintColorMask
TintColorColor - RGB uint8 colour value multiplied with the per pixel colour of Albedo and SecondaryAlbedo texture. Used to make all of the skin tone options in character creator (ca_almond, ca_senna, bl_dark etc).
TintScale
SkinProfile
Detailmap_Stretch
EmissiveMask
EmissiveEV
Detailmap_Squash
CavityIntensity
BloodflowTexture - Path to a bloodflow (vein) texture (.xbm).
BloodColor
DetailNormalInfluence

Fig. 1 - Microdetail _n.xbm

Left: Tiled by MicroDetailUVScale01
Right: Tiled by MicroDetailUVScale02

Player female average meshes with checkboard material showing differences in UV scale between body parts.