LensRenderingPipeline

Hierarchy

Index

Constructors

constructor

  • constructor

    Effect parameters are as follow: { chromatic_aberration: number; // from 0 to x (1 for realism) edge_blur: number; // from 0 to x (1 for realism) distortion: number; // from 0 to x (1 for realism) grain_amount: number; // from 0 to 1 grain_texture: BABYLON.Texture; // texture to use for grain effect; if unset, use random B&W noise dof_focus_distance: number; // depth-of-field: focus distance; unset to disable (disabled by default) dof_aperture: number; // depth-of-field: focus blur bias (default: 1) dof_darken: number; // depth-of-field: darken that which is out of focus (from 0 to 1, disabled by default) dof_pentagon: boolean; // depth-of-field: makes a pentagon-like "bokeh" effect dof_gain: number; // depth-of-field: highlights gain; unset to disable (disabled by default) dof_threshold: number; // depth-of-field: highlights threshold (default: 1) blur_noise: boolean; // add a little bit of noise to the blur (default: true) } Note: if an effect parameter is unset, effect is disabled

    Parameters

    • name: string

      The rendering pipeline name

    • parameters: any

      An object containing all parameters (see above)

    • scene: Scene

      The scene linked to this pipeline

    • Optional ratio: number

      The size of the postprocesses (0.5 means that your postprocess will have a width = canvas.width 0.5 and a height = canvas.height 0.5)

    • Optional cameras: Camera[]

      The array of cameras that the rendering pipeline will be attached to

    Returns LensRenderingPipeline

Properties

HighlightsEnhancingEffect

HighlightsEnhancingEffect: string

The highlights enhancing PostProcess id in the pipeline

LensChromaticAberrationEffect

LensChromaticAberrationEffect: string

The chromatic aberration PostProcess id in the pipeline

LensDepthOfFieldEffect

LensDepthOfFieldEffect: string

The depth-of-field PostProcess id in the pipeline

isSupported

isSupported: boolean

Methods

addEffect

disableChromaticAberration

  • disableChromaticAberration(): void
  • Returns void

disableDepthOfField

  • disableDepthOfField(): void
  • Returns void

disableEdgeBlur

  • disableEdgeBlur(): void
  • Returns void

disableEdgeDistortion

  • disableEdgeDistortion(): void
  • Returns void

disableGrain

  • disableGrain(): void
  • Returns void

disableHighlights

  • disableHighlights(): void
  • Returns void

disableNoiseBlur

  • disableNoiseBlur(): void
  • Returns void

disablePentagonBokeh

  • disablePentagonBokeh(): void
  • Returns void

dispose

  • dispose(disableDepthRender?: boolean): void
  • Removes the internal pipeline assets and detaches the pipeline from the scene cameras

    Parameters

    • Optional disableDepthRender: boolean

    Returns void

enableNoiseBlur

  • enableNoiseBlur(): void
  • Returns void

enablePentagonBokeh

  • enablePentagonBokeh(): void
  • Returns void

getClassName

  • getClassName(): string

setAperture

  • setAperture(amount: number): void
  • Parameters

    • amount: number

    Returns void

setChromaticAberration

  • setChromaticAberration(amount: number): void
  • Parameters

    • amount: number

    Returns void

setDarkenOutOfFocus

  • setDarkenOutOfFocus(amount: number): void
  • Parameters

    • amount: number

    Returns void

setEdgeBlur

  • setEdgeBlur(amount: number): void
  • Parameters

    • amount: number

    Returns void

setEdgeDistortion

  • setEdgeDistortion(amount: number): void
  • Parameters

    • amount: number

    Returns void

setFocusDistance

  • setFocusDistance(amount: number): void
  • Parameters

    • amount: number

    Returns void

setGrainAmount

  • setGrainAmount(amount: number): void
  • Parameters

    • amount: number

    Returns void

setHighlightsGain

  • setHighlightsGain(amount: number): void
  • Parameters

    • amount: number

    Returns void

setHighlightsThreshold

  • setHighlightsThreshold(amount: number): void
  • Parameters

    • amount: number

    Returns void

Generated using TypeDoc