Class ShaderMaterial2<E, ET>

Type Parameters

Hierarchy (view full)

Implements

Constructors

Properties

appliedMeshes: Set<any> = ...

Managed internally, do not change manually

assetType: "material" = ...
constructor: typeof ShaderMaterial2
extraUniformsToUpload: Record<string, IUniform<any>> = {}
isAShaderMaterial: true = true
isRawShaderMaterial: boolean
materialExtensions: MaterialExtension[] = []
registerMaterialExtensions: ((this, customMaterialExtensions) => void) = iMaterialCommons.registerMaterialExtensions

Type declaration

setDirty: ((this, options?) => void) = iMaterialCommons.setDirty

Type declaration

type: "ShaderMaterial" | "RawShaderMaterial" = 'ShaderMaterial'
unregisterMaterialExtensions: ((this, customMaterialExtensions) => void) = iMaterialCommons.unregisterMaterialExtensions

Type declaration

MaterialProperties: {
    alphaTest: number;
    alphaToCoverage: boolean;
    blendDst: 205;
    blendDstAlpha: null;
    blendEquation: 100;
    blendEquationAlpha: null;
    blendSrc: 204;
    blendSrcAlpha: null;
    blending: 1;
    clipIntersection: boolean;
    clipShadows: boolean;
    clipping: boolean;
    clippingPlanes: null;
    colorWrite: boolean;
    defaultAttributeValues: {};
    defines: {};
    depthFunc: 3;
    depthTest: boolean;
    depthWrite: boolean;
    dithering: boolean;
    extensions: {};
    fog: boolean;
    forceSinglePass: boolean;
    fragmentShader: string;
    glslVersion: null;
    isRawShaderMaterial: boolean;
    lights: boolean;
    name: string;
    opacity: number;
    polygonOffset: boolean;
    polygonOffsetFactor: number;
    polygonOffsetUnits: number;
    precision: null;
    premultipliedAlpha: boolean;
    shadowSide: null;
    side: 0;
    stencilFail: 7680;
    stencilFunc: 519;
    stencilFuncMask: number;
    stencilRef: number;
    stencilWrite: boolean;
    stencilWriteMask: number;
    stencilZFail: 7680;
    stencilZPass: 7680;
    toneMapped: boolean;
    transparent: boolean;
    uniforms: {};
    uniformsGroups: {};
    userData: {};
    vertexColors: boolean;
    vertexShader: string;
    visible: boolean;
    wireframe: boolean;
    wireframeLinewidth: number;
} = ...

Type declaration

  • alphaTest: number
  • alphaToCoverage: boolean
  • blendDst: 205
  • blendDstAlpha: null
  • blendEquation: 100
  • blendEquationAlpha: null
  • blendSrc: 204
  • blendSrcAlpha: null
  • blending: 1
  • clipIntersection: boolean
  • clipShadows: boolean
  • clipping: boolean
  • clippingPlanes: null
  • colorWrite: boolean
  • defaultAttributeValues: {}
    • defines: {}
      • depthFunc: 3
      • depthTest: boolean
      • depthWrite: boolean
      • dithering: boolean
      • extensions: {}
        • fog: boolean
        • forceSinglePass: boolean
        • fragmentShader: string
        • glslVersion: null
        • isRawShaderMaterial: boolean
        • lights: boolean
        • name: string
        • opacity: number
        • polygonOffset: boolean
        • polygonOffsetFactor: number
        • polygonOffsetUnits: number
        • precision: null
        • premultipliedAlpha: boolean
        • shadowSide: null
        • side: 0
        • stencilFail: 7680
        • stencilFunc: 519
        • stencilFuncMask: number
        • stencilRef: number
        • stencilWrite: boolean
        • stencilWriteMask: number
        • stencilZFail: 7680
        • stencilZPass: 7680
        • toneMapped: boolean
        • transparent: boolean
        • uniforms: {}
          • uniformsGroups: {}
            • userData: {}
              • vertexColors: boolean
              • vertexShader: string
              • visible: boolean
              • wireframe: boolean
              • wireframeLinewidth: number
              TYPE: "ShaderMaterial2" = 'ShaderMaterial2'
              TypeSlug: "shaderMat" = 'shaderMat'

              Accessors

              Methods

              • Disposes the material from the GPU. Set force to false if not sure the material is used by any object in the scene. // todo add check for visible in scene also? or is that overkill

                Returns this

              • Sets the values of this material based on the values of the passed material or an object with material properties The input is expected to be a valid material or a deserialized material parameters object(including the deserialized userdata)

                Parameters

                Returns this

              Generated using TypeDoc