Function createMaterial

  • Internal

    Create a material, depending on the rendering technique provided in the options.

    Parameters

    • rendererCapabilities: WebGLCapabilities

      The capabilities of the renderer that will use the material.

    • options: MaterialOptions

      The material options the subsequent functions need.

    • Optional onTextureCreated: ((texture) => void)

      Optional callback for each texture created for the material, getting a promise that will be resolved once the texture is loaded. Texture is not uploaded to GPU.

        • (texture): void
        • Parameters

          • texture: Promise<Texture>

          Returns void

    Returns THREE.Material | undefined

    new material instance that matches technique.name.

Generated using TypeDoc