Options
All
  • Public
  • Public/Protected
  • All
Menu

Class State

A state connects a geometry to the results (scalar, vector, displacement and transformations) for a given time, frequency, load case etc.

A model can have an arbitrary number of states, but only one can be shown at any given time.

To create an animation you can create multiple states, and then only change the UnstructGridModel.currentStateIndex property to advance the animation.

A state must have one and only one geometry.

The state can also have a scalar, vector, displacement and transformation result.

For the results, you only have to specify the results for the parts that have results. Results are mapped to part via the zero based part index.

Hierarchy

  • State

Index

Accessors

geometry

geometry: Geometry

The one and only geometry in this state

name

name: string

The user defined name of the state

referenceValue

referenceValue: number

The user defined reference value of the state (time, frequency, load case index, etc)

Methods

getBoundingBox

getFringesResultRange

  • getFringesResultRange(): Range
  • Get the min/max value of the scalar result in this part.

    Returns Range

getPartDisplacementsAt

  • Get the displacement result at the given zero based index

    Parameters

    • partIndex: number

    Returns PartDisplacements

getPartFringesAt

  • Returns the PartScalars defining the fringes result shown on the given part

    Parameters

    • partIndex: number

    Returns PartScalars

getPartTransformationAt

  • getPartTransformationAt(partIndex: number): Mat4
  • Get the transformation matrix for the given part in this state

    Parameters

    • partIndex: number

    Returns Mat4

getPartVectorsAt

  • Returns the PartVectors defining the vector result shown on the given part

    Parameters

    • partIndex: number

    Returns PartVectors

getVectorLengthRange

  • getVectorLengthRange(): Range
  • The range (min/max) of the vector lengths in all parts

    Returns Range

removeAllPartDisplacements

  • removeAllPartDisplacements(): void
  • Remove all displacement results in this state

    Returns void

removeAllPartFringes

  • removeAllPartFringes(): void
  • Remove all scalar fringes results from this state

    Returns void

removeAllPartTransformations

  • removeAllPartTransformations(): void
  • Remove the transformation matrices for all parts in this state

    Returns void

removeAllPartVectors

  • removeAllPartVectors(): void
  • Remove all vector results for all parts in this state

    Returns void

setPartDisplacementsAt

  • setPartDisplacementsAt(partIndex: number, partDisplacements: PartDisplacements): void

setPartFringesAt

  • setPartFringesAt(partIndex: number, partFringes: PartScalars): void
  • Set the scalar result that should be shown as fringes for the given part in this state.

    Note: The PartSettings.fringesVisible property must be true to show the result (default true)

    Parameters

    Returns void

setPartTransformationAt

  • setPartTransformationAt(partIndex: number, partTransformationMatrix: Mat4): void
  • Set the transformation result (matrix) for the given part in this state.

    Parameters

    • partIndex: number
    • partTransformationMatrix: Mat4

    Returns void

setPartVectorsAt

  • setPartVectorsAt(partIndex: number, partVectors: PartVectors): void
  • Set the vector result that should be shown as vector arrows for the given part in this state.

    Note: The PartSettings.vectorsVisible property must be true to show the result (default true)

    Parameters

    Returns void

Generated using TypeDoc