Options
All
  • Public
  • Public/Protected
  • All
Menu

Class PathGroup

楼层模型元素

Hierarchy

Index

Constructors

constructor

  • new PathGroup(paths?: object[][], options?: undefined | object): PathGroup
  • example
    const paths = new PathGroup([[
      { x: -3.0271134856048567, y: -8.9271859189251 },
      { x: 4.224184307967123, y: -9.642908272680536 },
      { x: 2.224184307967123, y: -1.642908272680536 },
    ]]);
    stage.bindElement(paths);
    // 重新载入新路线组
    paths.load([
      [{ x: 0, y: 0 }, { x: 4.224184307967123, y: -39.642908272680536 }],
      ...
    ])

    Parameters

    • Optional paths: object[][]

      路线数据, 二维数组, 数组内每个元素为一条路径数据, 每个元素是一个数组, 数组包含的子元素为x, y坐标. 默认z高度为0.

    • Optional options: undefined | object

    Returns PathGroup

Methods

dispose

  • dispose(): void
  • Returns void

load

  • load(paths: object[][], options?: undefined | object): void
  • 加载多条路线

    Parameters

    • paths: object[][]

      路线数据

    • Optional options: undefined | object

    Returns void

updatePathZ

  • updatePathZ(path: Path): void
  • Parameters

    Returns void

updatePathsZ

  • updatePathsZ(): void
  • Returns void