Foundry Virtual Tabletop - API Documentation - Version 14
    Preparing search index...

    The shader definition which powers the TokenRing.

    Hierarchy (View Summary)

    Index

    Properties

    initialUniforms: object

    The initial values of the shader uniforms.

    _batchFragmentShader: string = ...
    _batchVertexShader: string = ...
    batchGeometry: { id: string; normalized: boolean; size: number; type: TYPES }[] = ...
    batchRendererClass: typeof BatchRenderer = BatchRenderer

    The batch renderer to use.

    batchShaderGeneratorClass: typeof BatchShaderGenerator = BatchShaderGenerator

    The batch generator to use.

    batchVertexSize: number = ...
    classPluginName: string = "tokenRingBatch"
    CONTRAST: string = ...

    Contrast adjustment

    depthShaderClass: typeof DepthSamplerShader = DepthSamplerShader

    The depth shader class associated with this shader.

    EXPOSURE: string = ...

    Exposure adjustment.

    nullUvs: Float32Array = ...

    A null UVs array used for nulled texture position.

    pausable: boolean = false
    reservedTextureUnits: number = ...
    SATURATION: string = ...

    Saturation adjustment

    _fragmentShader: string = ...

    The fragment shader source. Subclasses can override it.

    _vertexShader: string = ...

    The vertex shader source. Subclasses can override it.

    Accessors

    • get depthShader(): DepthSamplerShader

      The depth shader associated with this shader. The depth shader is lazily constructed.

      Returns DepthSamplerShader

    • get enabled(): boolean

      Activate or deactivate this sampler. If set to false, the batch rendering is redirected to "batch". Otherwise, the batch rendering is directed toward the instance pluginName (might be null)

      Returns boolean

    • get paused(): boolean

      Pause or Unpause this sampler. If set to true, the shader is disabled. Otherwise, it is enabled. Contrary to enabled, a shader might decide to refuse a pause, to continue to render animations per example.

      Returns boolean

    • get pluginName(): string | null

      The plugin name associated for this instance, if any. Returns "batch" if the shader is disabled.

      Returns string | null

    • get ADJUSTMENTS(): string

      The adjustments made into fragment shaders.

      Returns string

    • get batchFragmentShader(): string

      Returns string

    • get batchVertexShader(): string

      Returns string

    • get defaultUniforms(): {
          fadeOcclusion: number;
          occludedAlpha: number;
          occlusionElevation: number;
          occlusionTexture: null;
          radialOcclusion: number;
          sampler: null;
          screenDimensions: number[];
          surfaceOcclusion: number;
          tintAlpha: number[];
          unoccludedAlpha: number;
          visionOcclusion: number;
      }

      Returns {
          fadeOcclusion: number;
          occludedAlpha: number;
          occlusionElevation: number;
          occlusionTexture: null;
          radialOcclusion: number;
          sampler: null;
          screenDimensions: number[];
          surfaceOcclusion: number;
          tintAlpha: number[];
          unoccludedAlpha: number;
          visionOcclusion: number;
      }

    Methods

    • Parameters

      • element: any
      • attributeBuffer: any
      • indexBuffer: any
      • aIndex: any
      • iIndex: any

      Returns void

    • Parameters

      • maxTex: any

      Returns {
          occlusionTexture: any;
          screenDimensions: number[];
          time: number;
          tokenRingTexture: any;
      }

    • Create a batch plugin for this sampler class.

      Returns any

      The batch plugin class linked to this sampler class.

    • Register the plugin for this sampler.

      Parameters

      • Optionaloptions: { force?: object } = {}

        The options

        • Optionalforce?: object

          Override the plugin of the same name that is already registered?

      Returns void