@pixi/3d
    Preparing search index...

    Interface TransmissionProps

    Runtime controls for a material's transmission group, as material.transmission

    const material = new Material3D({ transmission: {} });
    material.transmission!.thickness = 0.4;
    interface TransmissionProps {
        attenuationDistance: number;
        factor: number;
        texture: Texture;
        thickness: number;
        thicknessTexture: Texture;
        get attenuationColor(): number;
        set attenuationColor(value: ColorSource): void;
    }
    Index
    attenuationDistance: number

    Distance in world units that light travels through the volume before it takes on attenuationColor

    1e9 or more turns absorption off.

    material.transmission!.attenuationDistance = 0.5;
    
    factor: number

    How much light passes through, from 0 (opaque surface) to 1 (clear glass)

    material.transmission!.factor = 0.5;
    
    texture: Texture

    Map whose red channel scales factor

    material.transmission!.texture = await Assets.load('frost-mask.png');
    
    thickness: number

    Thickness of the volume in the mesh's own units; 0 makes a thin wall

    material.transmission!.thickness = 2;
    
    thicknessTexture: Texture

    Map whose green channel scales thickness

    material.transmission!.thicknessTexture = await Assets.load('thickness.png');
    
    • get attenuationColor(): number

      Colour white light turns after travelling attenuationDistance; takes any ColorSource and reads back a hex number, like Container.tint

      Returns number

      material.transmission!.attenuationColor = 'teal';
      
    • set attenuationColor(value: ColorSource): void

      Sets the attenuation colour from any ColorSource

      Parameters

      Returns void