Class PolygonsModule

拉伸模块,用来绘制批量拉伸

Hierarchy (view full)

Implements

Constructors

Properties

_app?: App
_destroyed: boolean = false
appRenderIndex: number = 0
borderPolyline: LineSegments2
borderStyle: LineMaterialParameters
entity: Entity
extData: {
    [key: string]: any;
} = {}

Type declaration

  • [key: string]: any
facePosIndex: Map<number, {
    face: [number, number, number];
    polyIndex: number;
}> = ...

Type declaration

  • face: [number, number, number]
  • polyIndex: number
highlightData: PolygonItemData[]
highlightIndexMap: Map<string, number> = ...
highlightPolygons: Mesh<BufferGeometry<NormalBufferAttributes>, Material | Material[], Object3DEventMap>
highlightStyle: MeshBasicMaterialParameters
instanceId: number = ++AppObject._instanceIdCounter
isXYPlane: boolean
onSetApp: Signal = ...
polygons: Mesh<BufferGeometry<NormalBufferAttributes>, Material | Material[], Object3DEventMap>
showBorder: boolean
showVertex: boolean
style: MeshBasicMaterialParameters
useBvh: boolean
vertexEntity: SymbolEntity
vertexStyle?: SymbolMaterialProps & {
    pointBorderColor?: ColorRepresentation;
    pointColor?: ColorRepresentation;
    pointSize?: number;
}

Type declaration

  • Optional pointBorderColor?: ColorRepresentation
  • Optional pointColor?: ColorRepresentation
  • Optional pointSize?: number
moduleName: string = "PolygonsModule"

Accessors

  • get app(): App
  • Returns App

  • set app(value): void
  • Parameters

    Returns void

  • get destroyed(): boolean
  • Whether it has been destroyed.

    Returns boolean

  • get enabled(): boolean
  • Indicates whether the component is enabled.

    Returns boolean

  • set enabled(value): void
  • Parameters

    • value: boolean

    Returns void

Methods

  • Parameters

    • toClassInst: any
    • Optional methodNames: string[]
    • Optional addMethods: string[]
    • Optional filterName: string[]

    Returns void

  • 清除所有高亮

    Returns void

  • 触发指定事件名称.

    Parameters

    • event: string

      Event name

    • Rest ...data: any

      Data

    Returns boolean

    • Whether the dispatching is successful
  • 获取拉伸边框对象

    Returns LineSegments2

  • 通过faceIndex获取

    Parameters

    • faceIndex: number

      面索引值

    • Optional isRefData: boolean

      返回的是否是数据引用的对象,默认false,将克隆新的数据

    Returns {
        data: PolygonItemData;
        face: [number, number, number];
    } | {
        borderColor?: ColorRepresentation;
        color?: ColorRepresentation | ColorRepresentation[];
        coordinates: [number, number, number][] | [number, number, number][][];
        data: undefined;
        disableEdit?: boolean;
        face: number[];
        hidden?: boolean;
        id?: string;
        opacity?: number;
        showVertex?: boolean;
    }

  • 获取拉伸对象

    Returns Mesh<BufferGeometry<NormalBufferAttributes>, Material | Material[], Object3DEventMap>

  • 确定是否存在事件侦听

    Parameters

    • event: string

      事件名

    Returns boolean

    返回是否存在相应的事件

  • 获取某项高亮与否

    Parameters

    • id: string

      id

    Returns boolean

  • 是否显示顶点

    Returns boolean

  • 返回具有指定事件名称的侦听总数.

    Parameters

    • event: string

      Event name

    Returns number

    The count of listeners

  • 刷新高亮数据

    Returns void

  • 通过事件名移除所有监听.

    Parameters

    • Optional event: string

      Event name, delete all events if not passed

    Returns void

  • 修改数据

    Parameters

    Returns void

  • 设置某项高亮与否

    Parameters

    • id: string

      id

    • Optional ishighlight: boolean

      是否

    • Optional disableAutoRefreshData: boolean

      不自动刷新,需要调用 refreshHighlight 来刷新

    Returns void

  • 设置是否显示顶点

    Parameters

    • show: boolean
    • Optional symbolStyleOptions: {
          pixelRaycasting?: boolean;
          style?: SymbolMaterialProps;
          useBvh?: boolean;
      }
      • Optional pixelRaycasting?: boolean

        像素大小拾取

      • Optional style?: SymbolMaterialProps

        样式

      • Optional useBvh?: boolean

        是否使用bvh射线查询。默认是

    Returns void

  • Returns {
        app: App;
        children: {
            getValue: (() => boolean);
            label: string;
            setValue: ((v) => void);
            type: string;
        }[];
        expanded: boolean;
        label: string;
        type: string;
    }

    • app: App
    • children: {
          getValue: (() => boolean);
          label: string;
          setValue: ((v) => void);
          type: string;
      }[]
    • expanded: boolean
    • label: string
    • type: string
  • 更新高亮样式

    Parameters

    • style: MeshBasicMaterialParameters

    Returns void

  • 更新样式

    Parameters

    • style: MeshBasicMaterialParameters

    Returns void