Defines the basic parameters available for the various shading getter functions.

interface GetShadingParams {
    addUtils?: boolean;
    receiveShadows?: boolean;
    toneMapping?: boolean | ToneMappingTypes;
    useOcclusion?: boolean;
}

Properties

addUtils?: boolean

Whether to add the utils functions such as constants or helper functions. Default to true.

receiveShadows?: boolean

Whether the shading function should account for current shadows. Default to false.

toneMapping?: boolean | ToneMappingTypes

Whether the shading function should apply tone mapping to the resulting color and if so, which one. Default to 'linear'.

useOcclusion?: boolean

Whether ambient occlusion should be accounted when calculating the shading. Default to false. If set to true, a float f32 ambient occlusion value should be passed as the last shading function parameter.