KHRMaterialsDiffuseTransmission

  • experimental

KHR_materials_diffuse_transmission defines diffuse transmission on a glTF PBR material.

Illustration

Figure: Sphere using KHR_materials_diffuse_transmission with varying roughness (0.0, 0.2, 0.4). Source: Khronos Group.

Adds a Lambertian diffuse transmission BSDF to the metallic-roughness material. Thin, dielectric objects like leaves or paper diffusely transmit incoming light to the opposite side of the surface. For optically thick media (volumes) with short scattering distances and therefore dense scattering behavior, a diffuse transmission lobe is a phenomenological plausible and cheap approximation.

Properties:

Example

import { KHRMaterialsDiffuseTransmission, DiffuseTransmission } from '@gltf-transform/extensions';

// Create an Extension attached to the Document.
const diffuseTransmissionExtension = document.createExtension(KHRMaterialsDiffuseTransmission);

// Create DiffuseTransmission property.
const diffuseTransmission = diffuseTransmission.createDiffuseTransmission()
.setDiffuseTransmissionFactor(1.0);

// Assign to a Material.
material.setExtension('KHR_materials_diffuse_transmission', diffuseTransmission);

Hierarchy

Static properties

EXTENSION_NAME: "KHR_materials_diffuse_transmission"

Properties

extensionName: "KHR_materials_diffuse_transmission"

Methods

  • dispose(): void
  • isRequired(): boolean
  • Indicates to the client whether it is OK to load the asset when this extension is not recognized. Optional extensions are generally preferred, if there is not a good reason to require a client to completely fail when an extension isn't known.

  • listProperties(): ExtensionProperty[]
  • Indicates to the client whether it is OK to load the asset when this extension is not recognized. Optional extensions are generally preferred, if there is not a good reason to require a client to completely fail when an extension isn't known.

Function symbol, where the argument and output are a box labeled 'glTF'.

Made by Don McCurdy. Documentation built with greendoc and published under Creative Commons Attribution 3.0.