Options
All
  • Public
  • Public/Protected
  • All
Menu

Class that holds the different stencil states of a material Usage example: https://playground.babylonjs.com/#CW5PRI#10

Hierarchy

  • MaterialStencilState

Implements

  • IStencilState

Index

Constructors

  • Creates a material stencil state instance

    Returns MaterialStencilState

Accessors

  • get enabled(): boolean
  • set enabled(value: boolean): void
  • Enables or disables the stencil test

    Returns boolean

  • Enables or disables the stencil test

    Parameters

    • value: boolean

    Returns void

  • get func(): number
  • set func(value: number): void
  • Gets or sets the stencil function

    Returns number

  • Gets or sets the stencil function

    Parameters

    • value: number

    Returns void

  • get funcMask(): number
  • set funcMask(value: number): void
  • Gets or sets the stencil function mask

    Returns number

  • Gets or sets the stencil function mask

    Parameters

    • value: number

    Returns void

  • get funcRef(): number
  • set funcRef(value: number): void
  • Gets or sets the stencil function reference

    Returns number

  • Gets or sets the stencil function reference

    Parameters

    • value: number

    Returns void

  • get mask(): number
  • set mask(value: number): void
  • Gets or sets the stencil mask

    Returns number

  • Gets or sets the stencil mask

    Parameters

    • value: number

    Returns void

  • get opDepthFail(): number
  • set opDepthFail(value: number): void
  • Gets or sets the operation when the depth test fails

    Returns number

  • Gets or sets the operation when the depth test fails

    Parameters

    • value: number

    Returns void

  • get opStencilDepthPass(): number
  • set opStencilDepthPass(value: number): void
  • Gets or sets the operation when the stencil+depth test succeeds

    Returns number

  • Gets or sets the operation when the stencil+depth test succeeds

    Parameters

    • value: number

    Returns void

  • get opStencilFail(): number
  • set opStencilFail(value: number): void
  • Gets or sets the operation when the stencil test fails

    Returns number

  • Gets or sets the operation when the stencil test fails

    Parameters

    • value: number

    Returns void

Methods

  • Makes a duplicate of the current configuration into another one.

    Parameters

    Returns void

  • getClassName(): string
  • Get the current class name, useful for serialization or dynamic coding.

    Returns string

    "MaterialStencilState"

  • parse(source: any, scene: Scene, rootUrl: string): void
  • Parses a stencil state configuration from a serialized object.

    Parameters

    • source: any

      Serialized object.

    • scene: Scene

      Defines the scene we are parsing for

    • rootUrl: string

      Defines the rootUrl to load from

    Returns void

  • reset(): void
  • Resets all the stencil states to default values

    Returns void

  • serialize(): any
  • Serializes this stencil configuration.

    Returns any

    • An object with the serialized config.

Legend

  • Constructor
  • Property
  • Method
  • Accessor
  • Property
  • Method
  • Inherited constructor
  • Static method

Settings

Theme