Options
All
  • Public
  • Public/Protected
  • All
Menu

Class SerializationPipeline

A pipeline for serializing the physics scene. A pipeline for serializing the physics scene.

To avoid leaking WASM resources, this MUST be freed manually with queryPipeline.free() once you are done using it (and all the rigid-bodies it created).

To avoid leaking WASM resources, this MUST be freed manually with queryPipeline.free() once you are done using it (and all the rigid-bodies it created).

Hierarchy

  • SerializationPipeline

Index

Constructors

Properties

Methods

Constructors

constructor

  • Parameters

    • Optional raw: RawSerializationPipeline

    Returns SerializationPipeline

  • Parameters

    • Optional raw: RawSerializationPipeline

    Returns SerializationPipeline

Properties

raw

raw: RawSerializationPipeline

Methods

deserializeAll

  • deserializeAll(data: Uint8Array): World
  • deserializeAll(data: Uint8Array): World
  • Deserialize the complete physics state from a single byte array.

    Parameters

    • data: Uint8Array

      The byte array to deserialize.

    Returns World

  • Deserialize the complete physics state from a single byte array.

    Parameters

    • data: Uint8Array

      The byte array to deserialize.

    Returns World

free

  • free(): void
  • free(): void
  • Release the WASM memory occupied by this serialization pipeline.

    Returns void

  • Release the WASM memory occupied by this serialization pipeline.

    Returns void

serializeAll

  • Serialize a complete physics state into a single byte array.

    Parameters

    • gravity: Vector

      The current gravity affecting the simulation.

    • integrationParameters: IntegrationParameters

      The integration parameters of the simulation.

    • islands: IslandManager
    • broadPhase: BroadPhase

      The broad-phase of the simulation.

    • narrowPhase: NarrowPhase

      The narrow-phase of the simulation.

    • bodies: RigidBodySet

      The rigid-bodies taking part into the simulation.

    • colliders: ColliderSet

      The colliders taking part into the simulation.

    • joints: JointSet

      The joints taking part into the simulation.

    Returns Uint8Array

  • Serialize a complete physics state into a single byte array.

    Parameters

    • gravity: Vector

      The current gravity affecting the simulation.

    • integrationParameters: IntegrationParameters

      The integration parameters of the simulation.

    • islands: IslandManager
    • broadPhase: BroadPhase

      The broad-phase of the simulation.

    • narrowPhase: NarrowPhase

      The narrow-phase of the simulation.

    • bodies: RigidBodySet

      The rigid-bodies taking part into the simulation.

    • colliders: ColliderSet

      The colliders taking part into the simulation.

    • joints: JointSet

      The joints taking part into the simulation.

    Returns Uint8Array

Generated using TypeDoc