Options
All
  • Public
  • Public/Protected
  • All
Menu

Class MorphTarget

Defines a target to use with MorphTargetManager

see

https://doc.babylonjs.com/how_to/how_to_use_morphtargets

Hierarchy

  • MorphTarget

Implements

Index

Constructors

constructor

  • Creates a new MorphTarget

    Parameters

    • name: string

      defines the name of the target

    • Optional influence: number

      defines the influence to use

    • Optional scene: Nullable<Scene>

      defines the scene the morphtarget belongs to

    Returns MorphTarget

Properties

animationsSearch playground for animations

animations: Animation[]

Gets or sets the list of animations

idSearch playground for id

id: string

Gets or sets the id of the morph Target

nameSearch playground for name

name: string

defines the name of the target

onInfluenceChangedSearch playground for onInfluenceChanged

onInfluenceChanged: Observable<boolean>

Observable raised when the influence changes

Accessors

animationPropertiesOverride

hasNormals

  • get hasNormals(): boolean
  • Gets a boolean defining if the target contains normal data

    Returns boolean

hasPositions

  • get hasPositions(): boolean
  • Gets a boolean defining if the target contains position data

    Returns boolean

hasTangents

  • get hasTangents(): boolean
  • Gets a boolean defining if the target contains tangent data

    Returns boolean

hasUVs

  • get hasUVs(): boolean
  • Gets a boolean defining if the target contains texture coordinates data

    Returns boolean

influence

  • get influence(): number
  • set influence(influence: number): any
  • Gets or sets the influence of this target (ie. its weight in the overall morphing)

    Returns number

  • Gets or sets the influence of this target (ie. its weight in the overall morphing)

    Parameters

    • influence: number

    Returns any

uniqueId

  • get uniqueId(): number
  • Gets the unique ID of this manager

    Returns number

Methods

cloneSearch playground for clone

  • Clone the current target

    Returns MorphTarget

    a new MorphTarget

getClassNameSearch playground for getClassName

  • getClassName(): string
  • Returns the string "MorphTarget"

    Returns string

    "MorphTarget"

getNormalsSearch playground for getNormals

  • Gets the normal data stored in this target

    Returns Nullable<FloatArray>

    a FloatArray containing the normal data (or null if not present)

getPositionsSearch playground for getPositions

  • Gets the position data stored in this target

    Returns Nullable<FloatArray>

    a FloatArray containing the position data (or null if not present)

getTangentsSearch playground for getTangents

  • Gets the tangent data stored in this target

    Returns Nullable<FloatArray>

    a FloatArray containing the tangent data (or null if not present)

getUVsSearch playground for getUVs

  • Gets the texture coordinates data stored in this target

    Returns Nullable<FloatArray>

    a FloatArray containing the texture coordinates data (or null if not present)

serializeSearch playground for serialize

  • serialize(): any
  • Serializes the current target into a Serialization object

    Returns any

    the serialized object

setNormalsSearch playground for setNormals

  • Affects normal data to this target

    Parameters

    Returns void

setPositionsSearch playground for setPositions

  • Affects position data to this target

    Parameters

    Returns void

setTangentsSearch playground for setTangents

  • Affects tangent data to this target

    Parameters

    Returns void

setUVsSearch playground for setUVs

  • Affects texture coordinates data to this target

    Parameters

    Returns void

Static FromMeshSearch playground for FromMesh

  • Creates a MorphTarget from mesh data

    Parameters

    • mesh: AbstractMesh

      defines the source mesh

    • Optional name: string

      defines the name to use for the new target

    • Optional influence: number

      defines the influence to attach to the target

    Returns MorphTarget

    a new MorphTarget

Static ParseSearch playground for Parse

  • Creates a new target from serialized data

    Parameters

    • serializationObject: any

      defines the serialized data to use

    • Optional scene: Scene

      defines the hosting scene

    Returns MorphTarget

    a new MorphTarget

Legend

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