MorphTarget

Defines a target to use with MorphTargetManager

see

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

Hierarchy

  • MorphTarget

Implements

Index

Constructors

constructor

Find examples in Playground
  • 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>

    Returns MorphTarget

Properties

animationPropertiesOverride

Find examples in Playground
animationPropertiesOverride: Nullable<AnimationPropertiesOverride>

Gets or sets the animation properties override

animations

Find examples in Playground
animations: Animation[]

Gets or sets the list of animations

hasNormals

Find examples in Playground
hasNormals: boolean

Gets a boolean defining if the target contains normal data

hasPositions

Find examples in Playground
hasPositions: boolean

Gets a boolean defining if the target contains position data

hasTangents

Find examples in Playground
hasTangents: boolean

Gets a boolean defining if the target contains tangent data

id

Find examples in Playground
id: string

Gets or sets the id of the morph Target

influence

Find examples in Playground
influence: number

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

name

Find examples in Playground
name: string

defines the name of the target

onInfluenceChanged

Find examples in Playground
onInfluenceChanged: Observable<boolean>

Observable raised when the influence changes

Methods

getClassName

Find examples in Playground
  • getClassName(): string
  • Returns the string "MorphTarget"

    Returns string

    "MorphTarget"

getNormals

Find examples in Playground
  • Gets the normal data stored in this target

    Returns Nullable<FloatArray>

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

getPositions

Find examples in Playground
  • Gets the position data stored in this target

    Returns Nullable<FloatArray>

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

getTangents

Find examples in Playground
  • Gets the tangent data stored in this target

    Returns Nullable<FloatArray>

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

serialize

Find examples in Playground
  • serialize(): any
  • Serializes the current target into a Serialization object

    Returns any

    the serialized object

setNormals

Find examples in Playground
  • Affects normal data to this target

    Parameters

    Returns void

setPositions

Find examples in Playground
  • Affects position data to this target

    Parameters

    Returns void

setTangents

Find examples in Playground
  • Affects tangent data to this target

    Parameters

    Returns void

Static FromMesh

Find examples in Playground
  • 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 Parse

Find examples in Playground
  • Creates a new target from serialized data

    Parameters

    • serializationObject: any

      defines the serialized data to use

    Returns MorphTarget

    a new MorphTarget

Generated using TypeDoc