DecalTexture

    Decal.swift:30
    enum DecalTexture

    Cases

    Other members in extension

    View members

    Hide members

    This section is hidden by default because it contains too many (16) members.

    Type members

    Instance members

    • var albedoMix: Double

      Blends the albedo Color of the decal with albedo Color of the underlying mesh. This can be set to 0.0 to create a decal that only affects normal or ORM. In this case, an albedo texture is still required as its alpha channel will determine where the normal and ORM will be overridden. See also modulate.

    • var cullMask: UInt32

      Specifies which layers this decal will project on. By default, Decals affect all layers. This is used so you can specify which types of objects receive the Decal and which do not. This is especially useful so you can ensure that dynamic objects don’t accidentally receive a Decal intended for the terrain under them.

    • var distanceFadeBegin: Double

      The distance from the camera at which the Decal begins to fade away (in 3D units).

    • var distanceFadeEnabled: Bool

      If true, decals will smoothly fade away when far from the active Camera3D starting at distanceFadeBegin. The Decal will fade out over distanceFadeBegin + distanceFadeLength, after which it will be culled and not sent to the shader at all. Use this to reduce the number of active Decals in a scene and thus improve performance.

    • var distanceFadeLength: Double

      The distance over which the Decal fades (in 3D units). The Decal becomes slowly more transparent over this distance and is completely invisible at the end. Higher values result in a smoother fade-out transition, which is more suited when the camera moves fast.

    • var emissionEnergy: Double

      Energy multiplier for the emission texture. This will make the decal emit light at a higher or lower intensity, independently of the albedo color. See also modulate.

    • var lowerFade: Double

      Sets the curve over which the decal will fade as the surface gets further from the center of the AABB. Only positive values are valid (negative values will be clamped to 0.0). See also upperFade.

    • var modulate: Color

      Changes the Color of the Decal by multiplying the albedo and emission colors with this value. The alpha component is only taken into account when multiplying the albedo color, not the emission color. See also emissionEnergy and albedoMix to change the emission and albedo intensity independently of each other.

    • var normalFade: Double

      Fades the Decal if the angle between the Decal’s AABB and the target surface becomes too large. A value of 0 projects the Decal regardless of angle, a value of 1 limits the Decal to surfaces that are nearly perpendicular.

    • var size: Vector3

      Sets the size of the AABB used by the decal. All dimensions must be set to a value greater than zero (they will be clamped to 0.001 if this is not the case). The AABB goes from -size/2 to size/2.

    • var textureAlbedo: Texture2D?

      Texture2D with the base Color of the Decal. Either this or the textureEmission must be set for the Decal to be visible. Use the alpha channel like a mask to smoothly blend the edges of the decal with the underlying object.

    • var textureEmission: Texture2D?

      Texture2D with the emission Color of the Decal. Either this or the textureAlbedo must be set for the Decal to be visible. Use the alpha channel like a mask to smoothly blend the edges of the decal with the underlying object.

    • var textureNormal: Texture2D?

      Texture2D with the per-pixel normal map for the decal. Use this to add extra detail to decals.

    • var textureOrm: Texture2D?

      Texture2D storing ambient occlusion, roughness, and metallic for the decal. Use this to add extra detail to decals.

    • var upperFade: Double

      Sets the curve over which the decal will fade as the surface gets further from the center of the AABB. Only positive values are valid (negative values will be clamped to 0.0). See also lowerFade.

    Citizens in SwiftGodot

    Conformances

    Type members

    Instance members

    Type features

    Instance features