Variable MaterialHelperConst

MaterialHelper: Readonly<{
    changeMaterial: ((entity: IMeshRendererEntityMethods, primitive: Primitive, material: Material) => void);
    createClassicUberMaterial: ((options?: {
        additionalName: undefined | string;
        isLighting: undefined | boolean;
        isMorphing: undefined | boolean;
        isShadow: undefined | boolean;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createColorGradingUsingLUTsMaterial: ((options: {
        additionalName?: string;
        colorAttachmentsNumber?: number;
        maxInstancesNumber?: number;
        texture?: Texture;
        uri?: string;
    }, targetRenderPass: RenderPass) => Material);
    createDepthEncodeMaterial: ((options?: {
        additionalName: undefined | string;
        depthPow: undefined | number;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createDepthMomentEncodeMaterial: ((options?: {
        additionalName: undefined | string;
        isMorphing: undefined | boolean;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createDetectHighLuminanceMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }, textureToDetectHighLuminance: AbstractTexture) => Material);
    createEntityUIDOutputMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createEnvConstantMaterial: ((options?: {
        additionalName: undefined | string;
        makeOutputSrgb: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createFXAA3QualityMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createFlatMaterial: ((options?: {
        additionalName: undefined | string;
        isMorphing: undefined | boolean;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createFurnaceTestMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createGammaCorrectionMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createGaussianBlurForEncodedDepthMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createGaussianBlurMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createMToon0xMaterial: ((options: {
        additionalName?: string;
        debugMode?: any;
        isLighting?: boolean;
        isMorphing?: boolean;
        isOutline?: boolean;
        isSkinning?: boolean;
        makeOutputSrgb?: boolean;
        materialProperties?: Vrm0xMaterialProperty;
        maxInstancesNumber?: number;
        samplers?: Sampler[];
        textures?: any[];
        useTangentAttribute?: boolean;
    }) => Material);
    createMToon1Material: ((options: {
        additionalName?: string;
        debugMode?: any;
        isLighting?: boolean;
        isMorphing?: boolean;
        isOutline?: boolean;
        isSkinning?: boolean;
        makeOutputSrgb?: boolean;
        materialJson: Vrm1_Material;
        maxInstancesNumber?: number;
        samplers?: Sampler[];
        textures?: any[];
        useTangentAttribute?: boolean;
    }) => Material);
    createMatCapMaterial: ((options: {
        additionalName?: string;
        isSkinning?: boolean;
        maxInstancesNumber?: number;
        sampler?: Sampler;
        texture?: Texture;
        uri?: string;
    }) => Material);
    createMaterial: ((materialContent: AbstractMaterialContent, maxInstancesNumber?: number) => Material);
    createPanoramaToCubeMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createParaboloidDepthMomentEncodeMaterial: ((options?: {
        additionalName: undefined | string;
        isMorphing: undefined | boolean;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createPbrUberMaterial: ((options?: {
        additionalName: undefined | string;
        isAnisotropy: undefined | boolean;
        isClearCoat: undefined | boolean;
        isDiffuseTransmission: undefined | boolean;
        isDispersion: undefined | boolean;
        isEmissive: undefined | boolean;
        isEmissiveStrength: undefined | boolean;
        isIridescence: undefined | boolean;
        isLighting: undefined | boolean;
        isMorphing: undefined | boolean;
        isOcclusion: undefined | boolean;
        isShadow: undefined | boolean;
        isSheen: undefined | boolean;
        isSkinning: undefined | boolean;
        isSpecular: undefined | boolean;
        isTransmission: undefined | boolean;
        isVolume: undefined | boolean;
        maxInstancesNumber: undefined | number;
        useNormalTexture: undefined | boolean;
        useTangentAttribute: undefined | boolean;
    }) => Material);
    createPrefilterIBLMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createShadowMapDecodeClassicSingleMaterial: ((options?: {
        additionalName: undefined | string;
        colorAttachmentsNumber: undefined | number;
        isDebugging: undefined | boolean;
        isLighting: undefined | boolean;
        isMorphing: undefined | boolean;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }, depthEncodeRenderPass: RenderPass) => Material);
    createSummedAreaTableMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createSynthesizeHDRMaterial: ((options: {
        additionalName?: string;
        maxInstancesNumber?: number;
    }, synthesizeTextures: AbstractTexture[]) => Material);
    createToneMappingMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material);
    createVarianceShadowMapDecodeClassicSingleMaterial: ((options: {
        additionalName?: string;
        colorAttachmentsNumberDepth?: number;
        colorAttachmentsNumberSquareDepth?: number;
        depthCameraComponent?: CameraComponent;
        isDebugging?: boolean;
        isLighting?: boolean;
        isMorphing?: boolean;
        isSkinning?: boolean;
        maxInstancesNumber?: number;
    }, encodedDepthRenderPasses: RenderPass[]) => Material);
    recreateMaterial: ((materialContent: AbstractMaterialContent, maxInstancesNumber?: number) => Material);
    reuseOrRecreateCustomMaterial: ((currentMaterial: Material, vertexShaderStr: string, pixelShaderStr: string, options?: {
        isLighting: undefined | boolean;
        isMorphing: undefined | boolean;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material);
}> = ...

Type declaration

  • changeMaterial: ((entity: IMeshRendererEntityMethods, primitive: Primitive, material: Material) => void)
      • (entity, primitive, material): void
      • Changes the material assigned to a specific primitive on an entity. This function updates the primitive's material and triggers necessary render state updates.

        Parameters

        Returns void

  • createClassicUberMaterial: ((options?: {
        additionalName: undefined | string;
        isLighting: undefined | boolean;
        isMorphing: undefined | boolean;
        isShadow: undefined | boolean;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a Classic Uber material for traditional non-PBR rendering. This material is suitable for classic shading models and legacy content.

        Parameters

        • options: {
              additionalName: undefined | string;
              isLighting: undefined | boolean;
              isMorphing: undefined | boolean;
              isShadow: undefined | boolean;
              isSkinning: undefined | boolean;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the Classic material

          • additionalName: undefined | string

            Additional name suffix for the material

          • isLighting: undefined | boolean

            Enable lighting calculations

          • isMorphing: undefined | boolean

            Enable morph target animation support

          • isShadow: undefined | boolean

            Enable shadow mapping support

          • isSkinning: undefined | boolean

            Enable skeletal animation support

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Classic Uber Material instance

  • createColorGradingUsingLUTsMaterial: ((options: {
        additionalName?: string;
        colorAttachmentsNumber?: number;
        maxInstancesNumber?: number;
        texture?: Texture;
        uri?: string;
    }, targetRenderPass: RenderPass) => Material)
      • (options, targetRenderPass): Material
      • Creates a material for color grading using LUT (Look-Up Table) textures. This material applies color correction and grading effects using 3D LUT textures.

        Parameters

        • options: {
              additionalName?: string;
              colorAttachmentsNumber?: number;
              maxInstancesNumber?: number;
              texture?: Texture;
              uri?: string;
          }

          Configuration object for the color grading material

          • OptionaladditionalName?: string

            Additional name suffix for the material

          • OptionalcolorAttachmentsNumber?: number

            Number of color attachments

          • OptionalmaxInstancesNumber?: number

            Maximum number of material instances

          • Optionaltexture?: Texture

            Pre-loaded LUT texture

          • Optionaluri?: string

            URI path to the LUT texture

        • targetRenderPass: RenderPass

          The render pass to apply color grading to

        Returns Material

        A configured Color Grading using LUTs Material instance

  • createDepthEncodeMaterial: ((options?: {
        additionalName: undefined | string;
        depthPow: undefined | number;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a material for encoding depth values into color channels. This material is used for depth-based effects and shadow mapping.

        Parameters

        • options: {
              additionalName: undefined | string;
              depthPow: undefined | number;
              isSkinning: undefined | boolean;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the depth encode material

          • additionalName: undefined | string

            Additional name suffix for the material

          • depthPow: undefined | number

            Power value for depth encoding (affects depth precision)

          • isSkinning: undefined | boolean

            Enable skeletal animation support

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Depth Encode Material instance

  • createDepthMomentEncodeMaterial: ((options?: {
        additionalName: undefined | string;
        isMorphing: undefined | boolean;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a material for encoding depth moments for variance shadow mapping. This material generates depth and depth-squared values for soft shadow techniques.

        Parameters

        • options: {
              additionalName: undefined | string;
              isMorphing: undefined | boolean;
              isSkinning: undefined | boolean;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the depth moment material

          • additionalName: undefined | string

            Additional name suffix for the material

          • isMorphing: undefined | boolean

            Enable morph target animation support

          • isSkinning: undefined | boolean

            Enable skeletal animation support

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Depth Moment Encode Material instance

  • createDetectHighLuminanceMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }, textureToDetectHighLuminance: AbstractTexture) => Material)
      • (options?, textureToDetectHighLuminance): Material
      • Creates a material for detecting high luminance areas in textures. This material is typically used in HDR rendering pipelines for bloom effects.

        Parameters

        • options: {
              additionalName: undefined | string;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the high luminance detection material

          • additionalName: undefined | string

            Additional name suffix for the material

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        • textureToDetectHighLuminance: AbstractTexture

          The texture to analyze for high luminance areas

        Returns Material

        A configured Detect High Luminance Material instance

  • createEntityUIDOutputMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a material for outputting entity unique identifiers to render targets. This material is used for object picking and selection by rendering entity IDs.

        Parameters

        • options: {
              additionalName: undefined | string;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the entity UID output material

          • additionalName: undefined | string

            Additional name suffix for the material

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Entity UID Output Material instance

  • createEnvConstantMaterial: ((options?: {
        additionalName: undefined | string;
        makeOutputSrgb: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a material for rendering environment constant colors. This material is typically used for skyboxes or environment background rendering.

        Parameters

        • options: {
              additionalName: undefined | string;
              makeOutputSrgb: undefined | boolean;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the environment material

          • additionalName: undefined | string

            Additional name suffix for the material

          • makeOutputSrgb: undefined | boolean

            Whether to convert output to sRGB color space

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Environment Constant Material instance

  • createFXAA3QualityMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a FXAA (Fast Approximate Anti-Aliasing) post-processing material. This material applies FXAA3 quality anti-aliasing to reduce edge aliasing.

        Parameters

        • options: {
              additionalName: undefined | string;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the FXAA material

          • additionalName: undefined | string

            Additional name suffix for the material

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured FXAA3 Quality Material instance

  • createFlatMaterial: ((options?: {
        additionalName: undefined | string;
        isMorphing: undefined | boolean;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a flat shading material with uniform color rendering. This material renders objects with flat, unlit colors without lighting calculations.

        Parameters

        • options: {
              additionalName: undefined | string;
              isMorphing: undefined | boolean;
              isSkinning: undefined | boolean;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the flat material

          • additionalName: undefined | string

            Additional name suffix for the material

          • isMorphing: undefined | boolean

            Enable morph target animation support

          • isSkinning: undefined | boolean

            Enable skeletal animation support

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Flat Material instance

  • createFurnaceTestMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a furnace test material for validating material energy conservation. This material is used for testing purposes to ensure materials conserve energy properly.

        Parameters

        • options: {
              additionalName: undefined | string;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the furnace test material

          • additionalName: undefined | string

            Additional name suffix for the material

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Furnace Test Material instance

  • createGammaCorrectionMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a material for gamma correction post-processing. This material applies gamma correction to convert linear color space to sRGB.

        Parameters

        • options: {
              additionalName: undefined | string;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the gamma correction material

          • additionalName: undefined | string

            Additional name suffix for the material

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Gamma Correction Material instance

  • createGaussianBlurForEncodedDepthMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a material for Gaussian blur applied to encoded depth textures. This material is used for creating soft shadows by blurring depth maps.

        Parameters

        • options: {
              additionalName: undefined | string;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the Gaussian blur material

          • additionalName: undefined | string

            Additional name suffix for the material

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Gaussian Blur for Encoded Depth Material instance

  • createGaussianBlurMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a material for Gaussian blur post-processing effects. This material applies Gaussian blur for various effects like depth of field or bloom.

        Parameters

        • options: {
              additionalName: undefined | string;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the Gaussian blur material

          • additionalName: undefined | string

            Additional name suffix for the material

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Gaussian Blur Material instance

  • createMToon0xMaterial: ((options: {
        additionalName?: string;
        debugMode?: any;
        isLighting?: boolean;
        isMorphing?: boolean;
        isOutline?: boolean;
        isSkinning?: boolean;
        makeOutputSrgb?: boolean;
        materialProperties?: Vrm0xMaterialProperty;
        maxInstancesNumber?: number;
        samplers?: Sampler[];
        textures?: any[];
        useTangentAttribute?: boolean;
    }) => Material)
      • (options): Material
      • Creates an MToon 0.x material for VRM character rendering with toon shading. This material implements the MToon 0.x specification for anime/toon-style rendering.

        Parameters

        • options: {
              additionalName?: string;
              debugMode?: any;
              isLighting?: boolean;
              isMorphing?: boolean;
              isOutline?: boolean;
              isSkinning?: boolean;
              makeOutputSrgb?: boolean;
              materialProperties?: Vrm0xMaterialProperty;
              maxInstancesNumber?: number;
              samplers?: Sampler[];
              textures?: any[];
              useTangentAttribute?: boolean;
          }

          Configuration object for the MToon 0.x material

          • OptionaladditionalName?: string

            Additional name suffix for the material

          • OptionaldebugMode?: any

            Debug mode settings

          • OptionalisLighting?: boolean

            Enable lighting calculations

          • OptionalisMorphing?: boolean

            Enable morph target animation support

          • OptionalisOutline?: boolean

            Enable outline rendering

          • OptionalisSkinning?: boolean

            Enable skeletal animation support

          • OptionalmakeOutputSrgb?: boolean

            Whether to convert output to sRGB color space

          • OptionalmaterialProperties?: Vrm0xMaterialProperty

            MToon material property definitions

          • OptionalmaxInstancesNumber?: number

            Maximum number of material instances

          • Optionalsamplers?: Sampler[]

            Array of texture samplers

          • Optionaltextures?: any[]

            Array of textures used by the material

          • OptionaluseTangentAttribute?: boolean

            Use tangent attributes for normal mapping

        Returns Material

        A configured MToon 0.x Material instance

  • createMToon1Material: ((options: {
        additionalName?: string;
        debugMode?: any;
        isLighting?: boolean;
        isMorphing?: boolean;
        isOutline?: boolean;
        isSkinning?: boolean;
        makeOutputSrgb?: boolean;
        materialJson: Vrm1_Material;
        maxInstancesNumber?: number;
        samplers?: Sampler[];
        textures?: any[];
        useTangentAttribute?: boolean;
    }) => Material)
      • (options): Material
      • Creates an MToon 1.0 material for VRM 1.0 character rendering with enhanced toon shading. This material implements the MToon 1.0 specification with improved features over 0.x.

        Parameters

        • options: {
              additionalName?: string;
              debugMode?: any;
              isLighting?: boolean;
              isMorphing?: boolean;
              isOutline?: boolean;
              isSkinning?: boolean;
              makeOutputSrgb?: boolean;
              materialJson: Vrm1_Material;
              maxInstancesNumber?: number;
              samplers?: Sampler[];
              textures?: any[];
              useTangentAttribute?: boolean;
          }

          Configuration object for the MToon 1.0 material

          • OptionaladditionalName?: string

            Additional name suffix for the material

          • OptionaldebugMode?: any

            Debug mode settings

          • OptionalisLighting?: boolean

            Enable lighting calculations

          • OptionalisMorphing?: boolean

            Enable morph target animation support

          • OptionalisOutline?: boolean

            Enable outline rendering

          • OptionalisSkinning?: boolean

            Enable skeletal animation support

          • OptionalmakeOutputSrgb?: boolean

            Whether to convert output to sRGB color space

          • materialJson: Vrm1_Material

            MToon 1.0 material JSON definition

          • OptionalmaxInstancesNumber?: number

            Maximum number of material instances

          • Optionalsamplers?: Sampler[]

            Array of texture samplers

          • Optionaltextures?: any[]

            Array of textures used by the material

          • OptionaluseTangentAttribute?: boolean

            Use tangent attributes for normal mapping

        Returns Material

        A configured MToon 1.0 Material instance

  • createMatCapMaterial: ((options: {
        additionalName?: string;
        isSkinning?: boolean;
        maxInstancesNumber?: number;
        sampler?: Sampler;
        texture?: Texture;
        uri?: string;
    }) => Material)
      • (options): Material
      • Creates a Material Capture (MatCap) material for stylized lighting effects. This material uses a material capture texture to simulate lighting without actual light sources.

        Parameters

        • options: {
              additionalName?: string;
              isSkinning?: boolean;
              maxInstancesNumber?: number;
              sampler?: Sampler;
              texture?: Texture;
              uri?: string;
          }

          Configuration object for the MatCap material

          • OptionaladditionalName?: string

            Additional name suffix for the material

          • OptionalisSkinning?: boolean

            Enable skeletal animation support

          • OptionalmaxInstancesNumber?: number

            Maximum number of material instances

          • Optionalsampler?: Sampler

            Texture sampler for the MatCap texture

          • Optionaltexture?: Texture

            Pre-loaded MatCap texture

          • Optionaluri?: string

            URI path to the MatCap texture

        Returns Material

        A configured MatCap Material instance

  • createMaterial: ((materialContent: AbstractMaterialContent, maxInstancesNumber?: number) => Material)
      • (materialContent, maxInstancesNumber?): Material
      • Creates a new material with the specified material content and maximum instances. This function automatically manages material grouping when instance limits are reached.

        Parameters

        • materialContent: AbstractMaterialContent

          The material content that defines the material's properties and shaders

        • OptionalmaxInstancesNumber: number

          The maximum number of instances that can use this material

        Returns Material

        A newly created Material instance

        Error if material creation fails after exhausting all groups

  • createPanoramaToCubeMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a material for converting panoramic textures to cube map format. This material transforms equirectangular panoramic images into cube map textures.

        Parameters

        • options: {
              additionalName: undefined | string;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the panorama to cube material

          • additionalName: undefined | string

            Additional name suffix for the material

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Panorama to Cube Material instance

  • createParaboloidDepthMomentEncodeMaterial: ((options?: {
        additionalName: undefined | string;
        isMorphing: undefined | boolean;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a material for encoding depth moments in paraboloid projection. This material is used for omnidirectional shadow mapping with paraboloid projections.

        Parameters

        • options: {
              additionalName: undefined | string;
              isMorphing: undefined | boolean;
              isSkinning: undefined | boolean;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the paraboloid depth material

          • additionalName: undefined | string

            Additional name suffix for the material

          • isMorphing: undefined | boolean

            Enable morph target animation support

          • isSkinning: undefined | boolean

            Enable skeletal animation support

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Paraboloid Depth Moment Encode Material instance

  • createPbrUberMaterial: ((options?: {
        additionalName: undefined | string;
        isAnisotropy: undefined | boolean;
        isClearCoat: undefined | boolean;
        isDiffuseTransmission: undefined | boolean;
        isDispersion: undefined | boolean;
        isEmissive: undefined | boolean;
        isEmissiveStrength: undefined | boolean;
        isIridescence: undefined | boolean;
        isLighting: undefined | boolean;
        isMorphing: undefined | boolean;
        isOcclusion: undefined | boolean;
        isShadow: undefined | boolean;
        isSheen: undefined | boolean;
        isSkinning: undefined | boolean;
        isSpecular: undefined | boolean;
        isTransmission: undefined | boolean;
        isVolume: undefined | boolean;
        maxInstancesNumber: undefined | number;
        useNormalTexture: undefined | boolean;
        useTangentAttribute: undefined | boolean;
    }) => Material)
      • (options?): Material
      • Creates a PBR (Physically Based Rendering) Uber material with extensive feature support. This is a comprehensive material that supports various PBR extensions and features.

        Parameters

        • options: {
              additionalName: undefined | string;
              isAnisotropy: undefined | boolean;
              isClearCoat: undefined | boolean;
              isDiffuseTransmission: undefined | boolean;
              isDispersion: undefined | boolean;
              isEmissive: undefined | boolean;
              isEmissiveStrength: undefined | boolean;
              isIridescence: undefined | boolean;
              isLighting: undefined | boolean;
              isMorphing: undefined | boolean;
              isOcclusion: undefined | boolean;
              isShadow: undefined | boolean;
              isSheen: undefined | boolean;
              isSkinning: undefined | boolean;
              isSpecular: undefined | boolean;
              isTransmission: undefined | boolean;
              isVolume: undefined | boolean;
              maxInstancesNumber: undefined | number;
              useNormalTexture: undefined | boolean;
              useTangentAttribute: undefined | boolean;
          } = {}

          Configuration object for the PBR material

          • additionalName: undefined | string

            Additional name suffix for the material

          • isAnisotropy: undefined | boolean

            Enable anisotropy extension (KHR_materials_anisotropy)

          • isClearCoat: undefined | boolean

            Enable clear coat extension (KHR_materials_clearcoat)

          • isDiffuseTransmission: undefined | boolean

            Enable diffuse transmission extension

          • isDispersion: undefined | boolean

            Enable dispersion extension (KHR_materials_dispersion)

          • isEmissive: undefined | boolean

            Enable emissive texture support

          • isEmissiveStrength: undefined | boolean

            Enable emissive strength extension

          • isIridescence: undefined | boolean

            Enable iridescence extension (KHR_materials_iridescence)

          • isLighting: undefined | boolean

            Enable lighting calculations

          • isMorphing: undefined | boolean

            Enable morph target animation support

          • isOcclusion: undefined | boolean

            Enable ambient occlusion texture support

          • isShadow: undefined | boolean

            Enable shadow mapping support

          • isSheen: undefined | boolean

            Enable sheen extension (KHR_materials_sheen)

          • isSkinning: undefined | boolean

            Enable skeletal animation support

          • isSpecular: undefined | boolean

            Enable specular extension (KHR_materials_specular)

          • isTransmission: undefined | boolean

            Enable transmission extension (KHR_materials_transmission)

          • isVolume: undefined | boolean

            Enable volume extension (KHR_materials_volume)

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

          • useNormalTexture: undefined | boolean

            Enable normal texture support

          • useTangentAttribute: undefined | boolean

            Use tangent attributes for normal mapping

        Returns Material

        A configured PBR Uber Material instance

  • createPrefilterIBLMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a material for prefiltering IBL (Image-Based Lighting) environment maps. This material generates prefiltered mipmap levels for environment map reflections.

        Parameters

        • options: {
              additionalName: undefined | string;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the IBL prefilter material

          • additionalName: undefined | string

            Additional name suffix for the material

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Prefilter IBL Material instance

  • createShadowMapDecodeClassicSingleMaterial: ((options?: {
        additionalName: undefined | string;
        colorAttachmentsNumber: undefined | number;
        isDebugging: undefined | boolean;
        isLighting: undefined | boolean;
        isMorphing: undefined | boolean;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }, depthEncodeRenderPass: RenderPass) => Material)
      • (options?, depthEncodeRenderPass): Material
      • Creates a material for decoding classic shadow maps in the rendering pipeline. This material applies shadow mapping techniques to create realistic shadows.

        Parameters

        • options: {
              additionalName: undefined | string;
              colorAttachmentsNumber: undefined | number;
              isDebugging: undefined | boolean;
              isLighting: undefined | boolean;
              isMorphing: undefined | boolean;
              isSkinning: undefined | boolean;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the shadow map decode material

          • additionalName: undefined | string

            Additional name suffix for the material

          • colorAttachmentsNumber: undefined | number

            Number of color attachments

          • isDebugging: undefined | boolean

            Enable debugging features

          • isLighting: undefined | boolean

            Enable lighting calculations

          • isMorphing: undefined | boolean

            Enable morph target animation support

          • isSkinning: undefined | boolean

            Enable skeletal animation support

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        • depthEncodeRenderPass: RenderPass

          The render pass that encodes depth information

        Returns Material

        A configured Shadow Map Decode Classic Material instance

  • createSummedAreaTableMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a material for generating summed area tables from textures. This material is used for efficient area sampling and filtering operations.

        Parameters

        • options: {
              additionalName: undefined | string;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the summed area table material

          • additionalName: undefined | string

            Additional name suffix for the material

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Summed Area Table Material instance

  • createSynthesizeHDRMaterial: ((options: {
        additionalName?: string;
        maxInstancesNumber?: number;
    }, synthesizeTextures: AbstractTexture[]) => Material)
      • (options, synthesizeTextures): Material
      • Creates a material for synthesizing HDR (High Dynamic Range) textures. This material combines multiple textures to create HDR content for advanced lighting.

        Parameters

        • options: {
              additionalName?: string;
              maxInstancesNumber?: number;
          }

          Configuration object for the HDR synthesis material

          • OptionaladditionalName?: string

            Additional name suffix for the material

          • OptionalmaxInstancesNumber?: number

            Maximum number of material instances

        • synthesizeTextures: AbstractTexture[]

          Array of textures to synthesize into HDR

        Returns Material

        A configured Synthesize HDR Material instance

  • createToneMappingMaterial: ((options?: {
        additionalName: undefined | string;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (options?): Material
      • Creates a material for tone mapping HDR content to LDR display. This material converts high dynamic range colors to displayable range using tone mapping algorithms.

        Parameters

        • options: {
              additionalName: undefined | string;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the tone mapping material

          • additionalName: undefined | string

            Additional name suffix for the material

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A configured Tone Mapping Material instance

  • createVarianceShadowMapDecodeClassicSingleMaterial: ((options: {
        additionalName?: string;
        colorAttachmentsNumberDepth?: number;
        colorAttachmentsNumberSquareDepth?: number;
        depthCameraComponent?: CameraComponent;
        isDebugging?: boolean;
        isLighting?: boolean;
        isMorphing?: boolean;
        isSkinning?: boolean;
        maxInstancesNumber?: number;
    }, encodedDepthRenderPasses: RenderPass[]) => Material)
      • (options, encodedDepthRenderPasses): Material
      • Creates a material for decoding variance shadow maps with classic single-pass rendering. This material implements variance shadow mapping for soft shadow effects.

        Parameters

        • options: {
              additionalName?: string;
              colorAttachmentsNumberDepth?: number;
              colorAttachmentsNumberSquareDepth?: number;
              depthCameraComponent?: CameraComponent;
              isDebugging?: boolean;
              isLighting?: boolean;
              isMorphing?: boolean;
              isSkinning?: boolean;
              maxInstancesNumber?: number;
          }

          Configuration object for the variance shadow map material

          • OptionaladditionalName?: string

            Additional name suffix for the material

          • OptionalcolorAttachmentsNumberDepth?: number

            Number of depth color attachments

          • OptionalcolorAttachmentsNumberSquareDepth?: number

            Number of squared depth color attachments

          • OptionaldepthCameraComponent?: CameraComponent

            Camera component for depth calculations

          • OptionalisDebugging?: boolean

            Enable debugging features

          • OptionalisLighting?: boolean

            Enable lighting calculations

          • OptionalisMorphing?: boolean

            Enable morph target animation support

          • OptionalisSkinning?: boolean

            Enable skeletal animation support

          • OptionalmaxInstancesNumber?: number

            Maximum number of material instances

        • encodedDepthRenderPasses: RenderPass[]

          Array of render passes that encode depth information

        Returns Material

        A configured Variance Shadow Map Decode Classic Material instance

  • recreateMaterial: ((materialContent: AbstractMaterialContent, maxInstancesNumber?: number) => Material)
      • (materialContent, maxInstancesNumber?): Material
      • Forces recreation of a material with the specified content, bypassing compatibility checks. Use this when you need to ensure a completely fresh material instance.

        Parameters

        • materialContent: AbstractMaterialContent

          The material content for the new material

        • OptionalmaxInstancesNumber: number

          The maximum number of instances for the material

        Returns Material

        A newly recreated Material instance

  • reuseOrRecreateCustomMaterial: ((currentMaterial: Material, vertexShaderStr: string, pixelShaderStr: string, options?: {
        isLighting: undefined | boolean;
        isMorphing: undefined | boolean;
        isSkinning: undefined | boolean;
        maxInstancesNumber: undefined | number;
    }) => Material)
      • (currentMaterial, vertexShaderStr, pixelShaderStr, options?): Material
      • Reuses an existing custom material or recreates it with new shader code. This function optimizes performance by reusing materials when possible while allowing shader updates.

        Parameters

        • currentMaterial: Material

          The existing material to potentially reuse

        • vertexShaderStr: string

          Vertex shader source code string

        • pixelShaderStr: string

          Pixel/fragment shader source code string

        • options: {
              isLighting: undefined | boolean;
              isMorphing: undefined | boolean;
              isSkinning: undefined | boolean;
              maxInstancesNumber: undefined | number;
          } = {}

          Configuration object for the custom material

          • isLighting: undefined | boolean

            Enable lighting calculations

          • isMorphing: undefined | boolean

            Enable morph target animation support

          • isSkinning: undefined | boolean

            Enable skeletal animation support

          • maxInstancesNumber: undefined | number

            Maximum number of material instances

        Returns Material

        A reused or newly created Custom Material instance