@glowjs/core 2024.9.25 → 2024.10.31

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -40,6 +40,10 @@ export declare class App extends EventDispatcher {
40
40
  * DOM容器
41
41
  */
42
42
  container: HTMLDivElement;
43
+ /**
44
+ * 富文本容器
45
+ */
46
+ richContainer: HTMLDivElement;
43
47
  /**
44
48
  * 根路径
45
49
  */
@@ -65,5 +65,9 @@ export declare enum EntityType {
65
65
  /**
66
66
  * POI标记
67
67
  */
68
- POI = 32768
68
+ POI = 32768,
69
+ /**
70
+ * 管道
71
+ */
72
+ Pipe = 65536
69
73
  }
@@ -24,7 +24,7 @@ export declare class LeakLine extends Entity {
24
24
  */
25
25
  toJson(): any;
26
26
  /**
27
- * 从JSON对象反序列化(仅生成层级树
27
+ * 从JSON对象反序列化(仅生成层级树)
28
28
  * @param json JSON对象
29
29
  */
30
30
  fromJson(json: any): void;
@@ -3,10 +3,11 @@ import { Entity } from './Entity';
3
3
  import { LeakLine } from './LeakLine';
4
4
  import { Text3D } from './Text3D';
5
5
  import { POI } from './POI';
6
+ import { Pipe } from './Pipe';
6
7
  /**
7
8
  * 其它实体
8
9
  */
9
- export type OtherEntity = Text3D | LeakLine | POI;
10
+ export type OtherEntity = Text3D | LeakLine | POI | Pipe;
10
11
  /**
11
12
  * 判断实体是否为其它实体
12
13
  * @param entity 实体
@@ -0,0 +1,68 @@
1
+ import { App } from "../core/App";
2
+ import { Point3D } from "../misc";
3
+ import { Entity } from "./Entity";
4
+ /**
5
+ * 管道
6
+ */
7
+ export declare class Pipe extends Entity {
8
+ /**
9
+ * 默认半径
10
+ */
11
+ static defaultRadius: number;
12
+ /**
13
+ * 点集
14
+ */
15
+ readonly points: Point3D[];
16
+ /**
17
+ * 贴图ID
18
+ */
19
+ textureId: string;
20
+ private _material;
21
+ private _animationSpeed;
22
+ private _radius;
23
+ /**
24
+ * 是否默认隐藏
25
+ */
26
+ defaultHidden: boolean;
27
+ /**
28
+ * 实例化一个管道对象
29
+ * @param app 应用
30
+ */
31
+ constructor(app: App);
32
+ /**
33
+ * 获取或设置动画速度
34
+ */
35
+ get animationSpeed(): number;
36
+ set animationSpeed(value: number);
37
+ /**
38
+ * 获取或设置半径
39
+ */
40
+ get radius(): number;
41
+ set radius(value: number);
42
+ /**
43
+ * 获取是否允许被冻结材质
44
+ */
45
+ get canFreezeMaterial(): boolean;
46
+ /**
47
+ * 序列化成JSON对象
48
+ */
49
+ toJson(): any;
50
+ /**
51
+ * 从JSON对象反序列化(仅生成层级树)
52
+ * @param json JSON对象
53
+ */
54
+ fromJson(json: any): void;
55
+ /**
56
+ * 创建(仅当前层级可见对象)
57
+ * @param force 是否强制
58
+ */
59
+ build(force?: boolean): Promise<void>;
60
+ /**
61
+ * 拆毁
62
+ */
63
+ unbuild(): void;
64
+ /**
65
+ * 释放
66
+ */
67
+ dispose(): void;
68
+ }
@@ -55,6 +55,7 @@ export { Group } from './entity/Group';
55
55
  export { Thing } from './entity/Thing';
56
56
  export { DecorateGrid } from './entity/DecorateGrid';
57
57
  export { POI } from './entity/POI';
58
+ export { Pipe } from './entity/Pipe';
58
59
  export { Component } from './entity/component/Component';
59
60
  export { Style } from './entity/component/Style';
60
61
  export { Animator } from './entity/component/Animator';
@@ -81,5 +81,13 @@ export declare enum SystemResId {
81
81
  /**
82
82
  * 装饰线框
83
83
  */
84
- DecorateGrid = "aeb46e27018fa8aef1ab9809c442167f"
84
+ DecorateGrid = "aeb46e27018fa8aef1ab9809c442167f",
85
+ /**
86
+ * 默认管道贴图
87
+ */
88
+ DefaultPipeTexture = "bd276fe64d6f7270f246195792285af0",
89
+ /**
90
+ * 管道
91
+ */
92
+ Pipe = "79caea2506eb4a8ee18c22cb140858d4"
85
93
  }
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@glowjs/core",
3
- "version": "2024.09.25",
3
+ "version": "2024.10.31",
4
4
  "description": "GlowJS数字孪生引擎核心库。",
5
5
  "main": "./dist/glow.core.js",
6
6
  "types": "./dist/typings/index.d.ts",