@pixi/3d
    Preparing search index...

    Interface TransmissionOptions

    Options for a Material3D's transmission group (KHR_materials_transmission with KHR_materials_volume): glass and other surfaces you see through

    Through a transmissive mesh you see the background and the opaque meshes, tinted by its base colour and blurred by its roughness, but not other transmissive or blended meshes. On WebGL, glass in a view drawn straight onto an opaque canvas shows nothing through. Start the application with useBackBuffer: true, or, when the scene has doubleSided materials, whose lighting that option breaks, give the view composite: true.

    const glass = new Material3D({ roughness: 0.05, transmission: { thickness: 0.5 } });
    
    interface TransmissionOptions {
        attenuationColor?: ColorSource;
        attenuationDistance?: number;
        factor?: number;
        texture?: Texture<TextureSource<any>>;
        thickness?: number;
        thicknessTexture?: Texture<TextureSource<any>>;
    }
    Index
    attenuationColor?: ColorSource

    Colour white light turns after travelling attenuationDistance through the volume

    0xffffff
    
    const bottleGreen = new Material3D({
    transmission: { thickness: 0.5, attenuationDistance: 1, attenuationColor: 0x2e8b57 },
    });
    attenuationDistance?: number

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

    Left out, light isn't absorbed. Absorption also needs thickness above 0.

    const wine = new Material3D({
    transmission: { thickness: 1, attenuationDistance: 1, attenuationColor: 0x7a0f1e },
    });
    factor?: number

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

    1
    
    const frosted = new Material3D({ roughness: 0.6, transmission: { factor: 0.9 } });
    
    texture?: Texture<TextureSource<any>>

    Map whose red channel scales factor

    const stainedGlass = new Material3D({ transmission: { texture: leadingMask } });
    
    thickness?: number

    Thickness of the volume in the mesh's own units, scaled with the mesh

    0 makes a thin wall: light doesn't bend and isn't absorbed.

    0
    
    const block = new Material3D({ transmission: { thickness: 1 } });
    
    thicknessTexture?: Texture<TextureSource<any>>

    Map whose green channel scales thickness

    const bottle = new Material3D({ transmission: { thickness: 0.3, thicknessTexture: wallThickness } });