Options
All
  • Public
  • Public/Protected
  • All
Menu

A container group which contains visual effects rendered above the primary group.

Hierarchy

  • any
    • EffectsCanvasGroup

Index

Constructors

Properties

globalLightSource: LightSource

The current global light source.

animateLightSources: boolean = true

Whether to currently animate light sources.

animateVisionSources: boolean = true

Whether to currently animate vision sources.

lightSources: Collection<string, LightSource> = ...

A mapping of light sources which are active within the rendered Scene.

visionSources: Collection<string, VisionSource> = ...

A Collection of vision sources which are currently active within the rendered Scene.

visualEffectsMaskingFilters: Set<VisualEffectsMaskingFilter>

A set of vision mask filters used in visual effects group

A layer of background alteration effects which change the appearance of the primary group render texture.

A layer which adds illumination-based effects to the scene.

A layer which adds color-based effects to the scene.

visibility: CanvasVisibility

A layer which controls the current visibility of the scene.

Methods

  • clearEffects(): void
  • Clear all effects containers and animated sources.

    Returns void

  • draw(): Promise<void>
  • Draw the component layers of the canvas group.

    Returns Promise<void>

  • initializeLightSources(): void
  • Initialize LightSource objects for all AmbientLightDocument instances which exist within the active Scene.

    Returns void

  • refreshLightSources(): void
  • Refresh the state and uniforms of all LightSource objects.

    Returns void

  • refreshVisionSources(): void
  • Refresh the state and uniforms of all LightSource objects.

    Returns void

  • refreshLighting(): void
  • Refresh the active display of lighting.

    Returns void

  • tearDown(): Promise<void>
  • Perform a deconstruction workflow for this canvas group when the canvas is retired.

    Returns Promise<void>

  • toggleMaskingFilters(enabled?: boolean): void
  • Activate vision masking for visual effects

    Parameters

    • enabled: boolean = true

    Returns void

  • activatePostProcessingFilters(filterMode: string, postProcessingModes?: string[], uniforms?: any): void
  • Activate post-processing effects for a certain effects channel.

    Parameters

    • filterMode: string

      The filter mode to target.

    • postProcessingModes: string[] = []
    • uniforms: any = {}

    Returns void

  • resetPostProcessingFilters(): void
  • Reset post-processing modes on all Visual Effects masking filters.

    Returns void

  • activateAnimation(): void
  • Activate light source animation for AmbientLight objects within this layer

    Returns void

  • deactivateAnimation(): void
  • Deactivate light source animation for AmbientLight objects within this layer

    Returns void

  • animateDarkness(target?: number, duration?: number): Promise<any>
  • Animate a smooth transition of the darkness overlay to a target value. Only begin animating if another animation is not already in progress.

    Parameters

    • target: number = 1.0

      The target darkness level between 0 and 1

    • duration: number = {}

      The desired animation time in milliseconds. Default is 10 seconds

    Returns Promise<any>

    A Promise which resolves once the animation is complete

  • Update the global light source which provide global illumination to the Scene.

    Returns GlobalLightSource

  • #createLayers(): void
  • Create the child layers of the effects group.

    Returns void

  • #addVisionEffects(): void
  • Add effect meshes for active vision sources.

    Returns void

  • #animateSources(dt: number): void
  • The ticker handler which manages animation delegation

    Parameters

    • dt: number

      Delta time

    Returns void