@mlightcad/graphic-interface 3.12.5 → 3.13.0

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.
@@ -60,11 +60,16 @@ export interface AcGiEntity {
60
60
  * Return a clone of this object and its direct children (not all descendants).
61
61
  * So it means that you need to gurantee the object is flatten by call method
62
62
  * 'flatten' before calling this function.
63
- * This function will deeply clone geometry in this object. But materials are
64
- * reused directly and not deeply cloned.
63
+ *
64
+ * Implementations may deep-clone geometry, or (for immutable block-template
65
+ * caches) alias leaf buffers and mark them so instance dispose skips them.
66
+ * Materials are reused and not deeply cloned.
67
+ *
68
+ * @param shareGeometry - When true, leaf drawables may alias source
69
+ * geometry buffers instead of deep-cloning them.
65
70
  * @returns Return a clone of this object and optionally all descendants.
66
71
  */
67
- fastDeepClone(): AcGiEntity;
72
+ fastDeepClone(shareGeometry?: boolean): AcGiEntity;
68
73
  /**
69
74
  * Optionally merges same-material drawable leaves so later
70
75
  * {@link fastDeepClone} copies far fewer geometries.
@@ -76,6 +81,16 @@ export interface AcGiEntity {
76
81
  * @returns Nothing.
77
82
  */
78
83
  compactForInstancing?(): void;
84
+ /**
85
+ * Optionally prepares this entity as an immutable block-template cache entry.
86
+ *
87
+ * Typical implementations finalize deferred drawables and drop detached
88
+ * source-entity shells without merging leaves. Used by rendering cache miss
89
+ * paths before {@link fastDeepClone} for scene use.
90
+ *
91
+ * @returns Nothing.
92
+ */
93
+ prepareCacheTemplate?(): void;
79
94
  /**
80
95
  * Optionally releases GPU/CPU resources owned by this entity.
81
96
  *
@@ -1 +1 @@
1
- {"version":3,"file":"AcGiEntity.d.ts","sourceRoot":"","sources":["../src/AcGiEntity.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,YAAY,EAAE,MAAM,4BAA4B,CAAA;AAEzD;;GAEG;AACH,MAAM,WAAW,UAAU;IACzB;;;OAGG;IACH,IAAI,QAAQ,IAAI,MAAM,CAAA;IACtB,IAAI,QAAQ,CAAC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EAAE,MAAM,EAAC;IAE1B;;OAEG;IACH,IAAI,SAAS,IAAI,MAAM,CAAA;IACvB,IAAI,SAAS,CAAC,KAAK,EAAE,MAAM,EAAC;IAE5B;;OAEG;IACH,IAAI,OAAO,IAAI,OAAO,CAAA;IACtB,IAAI,OAAO,CAAC,KAAK,EAAE,OAAO,EAAC;IAE3B;;OAEG;IACH,IAAI,QAAQ,IAAI,MAAM,CAAA;IACtB,IAAI,QAAQ,CAAC,KAAK,EAAE,MAAM,EAAC;IAE3B;;;OAGG;IACH,QAAQ,CAAC,KAAK,EAAE,UAAU,GAAG,IAAI,CAAA;IAEjC;;;;;;OAMG;IACH,QAAQ,CAAC,UAAU,CAAC,EAAE,MAAM,CAAA;IAE5B;;;OAGG;IACH,WAAW,CAAC,MAAM,EAAE,YAAY,GAAG,IAAI,CAAA;IAEvC;;OAEG;IACH,SAAS,IAAI,IAAI,CAAA;IAEjB;;OAEG;IACH,WAAW,IAAI,IAAI,CAAA;IAEnB;;;;;;;;;;;;OAYG;IACH,aAAa,CAAC,aAAa,CAAC,EAAE,OAAO,GAAG,UAAU,CAAA;IAElD;;;;;;;;;OASG;IACH,oBAAoB,CAAC,IAAI,IAAI,CAAA;IAE7B;;;;;;;;OAQG;IACH,oBAAoB,CAAC,IAAI,IAAI,CAAA;IAE7B;;;;;;;;OAQG;IACH,OAAO,CAAC,IAAI,IAAI,CAAA;CACjB"}
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@mlightcad/graphic-interface",
3
- "version": "3.12.5",
3
+ "version": "3.13.0",
4
4
  "license": "MIT",
5
5
  "type": "module",
6
6
  "repository": {
@@ -33,8 +33,8 @@
33
33
  "require": "./dist/graphic-interface.umd.cjs"
34
34
  },
35
35
  "peerDependencies": {
36
- "@mlightcad/common": "1.12.5",
37
- "@mlightcad/geometry-engine": "3.12.5"
36
+ "@mlightcad/common": "1.13.0",
37
+ "@mlightcad/geometry-engine": "3.13.0"
38
38
  },
39
39
  "scripts": {
40
40
  "clean": "rimraf dist lib tsconfig.tsbuildinfo",