@babylonjs/node-geometry-editor 6.17.0 → 6.18.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.
@@ -39,6 +39,7 @@ import { SetMaterialIDBlock } from "@babylonjs/core/Meshes/Node/Blocks/Set/setMa
39
39
  import { InstantiateOnVerticesBlock } from "@babylonjs/core/Meshes/Node/Blocks/Instances/instantiateOnVerticesBlock";
40
40
  import { InstantiateOnFacesBlock } from "@babylonjs/core/Meshes/Node/Blocks/Instances/instantiateOnFacesBlock";
41
41
  import { InstantiateOnVolumeBlock } from "@babylonjs/core/Meshes/Node/Blocks/Instances/instantiateOnVolumeBlock";
42
+ import { InstantiateBlock } from "@babylonjs/core/Meshes/Node/Blocks/Instances/instantiateBlock";
42
43
  import { DebugBlock } from "@babylonjs/core/Meshes/Node/Blocks/debugBlock";
43
44
  import { TeleportInBlock } from "@babylonjs/core/Meshes/Node/Blocks/Teleport/teleportInBlock";
44
45
  import { TeleportOutBlock } from "@babylonjs/core/Meshes/Node/Blocks/Teleport/teleportOutBlock";
@@ -46,8 +47,10 @@ import { MapRangeBlock } from "@babylonjs/core/Meshes/Node/Blocks/mapRangeBlock"
46
47
  import { GeometryOptimizeBlock } from "@babylonjs/core/Meshes/Node/Blocks/geometryOptimizeBlock";
47
48
  import { IntFloatConverterBlock } from "@babylonjs/core/Meshes/Node/Blocks/intFloatConverterBlock";
48
49
  import { ConditionBlock } from "@babylonjs/core/Meshes/Node/Blocks/conditionBlock";
50
+ import { GeometryCollectionBlock } from "@babylonjs/core/Meshes/Node/Blocks/geometryCollectionBlock";
51
+ import { GeometryInfoBlock } from "@babylonjs/core/Meshes/Node/Blocks/geometryInfoBlock";
49
52
  export class BlockTools {
50
- static GetBlockFromString(data: string): GeometryOptimizeBlock | NullBlock | TeleportInBlock | TeleportOutBlock | DebugBlock | IntFloatConverterBlock | ConditionBlock | SetMaterialIDBlock | InstantiateOnVolumeBlock | InstantiateOnFacesBlock | InstantiateOnVerticesBlock | MapRangeBlock | NormalizeVectorBlock | MeshBlock | VectorConverterBlock | TranslationBlock | ScalingBlock | AlignBlock | RotationXBlock | RotationYBlock | RotationZBlock | ComputeNormalsBlock | SetPositionsBlock | SetNormalsBlock | SetColorsBlock | SetTangentsBlock | SetUVsBlock | NoiseBlock | RandomBlock | GeometryOutputBlock | GridBlock | DiscBlock | IcoSphereBlock | BoxBlock | TorusBlock | SphereBlock | CylinderBlock | CapsuleBlock | PlaneBlock | GeometryElbowBlock | MergeGeometryBlock | GeometryTransformBlock | GeometryInputBlock | MathBlock | GeometryTrigonometryBlock | null;
53
+ static GetBlockFromString(data: string): GeometryInfoBlock | GeometryCollectionBlock | GeometryOptimizeBlock | NullBlock | TeleportInBlock | TeleportOutBlock | DebugBlock | IntFloatConverterBlock | ConditionBlock | SetMaterialIDBlock | InstantiateOnVolumeBlock | InstantiateOnFacesBlock | InstantiateOnVerticesBlock | InstantiateBlock | MapRangeBlock | NormalizeVectorBlock | MeshBlock | VectorConverterBlock | TranslationBlock | ScalingBlock | AlignBlock | RotationXBlock | RotationYBlock | RotationZBlock | ComputeNormalsBlock | SetPositionsBlock | SetNormalsBlock | SetColorsBlock | SetTangentsBlock | SetUVsBlock | NoiseBlock | RandomBlock | GeometryOutputBlock | GridBlock | DiscBlock | IcoSphereBlock | BoxBlock | TorusBlock | SphereBlock | CylinderBlock | CapsuleBlock | PlaneBlock | GeometryElbowBlock | MergeGeometryBlock | GeometryTransformBlock | GeometryInputBlock | MathBlock | GeometryTrigonometryBlock | null;
51
54
  static GetColorFromConnectionNodeType(type: NodeGeometryBlockConnectionPointTypes): string;
52
55
  static GetConnectionNodeTypeFromString(type: string): NodeGeometryBlockConnectionPointTypes.Int | NodeGeometryBlockConnectionPointTypes.Float | NodeGeometryBlockConnectionPointTypes.Vector2 | NodeGeometryBlockConnectionPointTypes.Vector3 | NodeGeometryBlockConnectionPointTypes.Vector4 | NodeGeometryBlockConnectionPointTypes.Matrix | NodeGeometryBlockConnectionPointTypes.AutoDetect;
53
56
  static GetStringFromConnectionNodeType(type: NodeGeometryBlockConnectionPointTypes): "" | "Int" | "Float" | "Vector2" | "Vector3" | "Vector4" | "Matrix";
@@ -303,7 +306,7 @@ export class PropertyTabComponent extends React.Component<IPropertyTabComponentP
303
306
  constructor(props: IPropertyTabComponentProps);
304
307
  componentDidMount(): void;
305
308
  componentWillUnmount(): void;
306
- processInputBlockUpdate(ib: GeometryInputBlock): void;
309
+ processInputBlockUpdate(): void;
307
310
  renderInputBlock(block: GeometryInputBlock): JSX.Element | null;
308
311
  load(file: File): void;
309
312
  loadFrame(file: File): void;
@@ -358,6 +361,7 @@ export class GlobalState {
358
361
  label: string;
359
362
  action: (data: string) => Promise<void>;
360
363
  };
364
+ resyncHandler?: () => void;
361
365
  get previewMode(): PreviewMode;
362
366
  set previewMode(value: PreviewMode);
363
367
  constructor();
@@ -535,13 +539,18 @@ declare module "@babylonjs/node-geometry-editor/graphSystem/display/inputDisplay
535
539
  import { IDisplayManager } from "@babylonjs/node-geometry-editor/nodeGraphSystem/interfaces/displayManager";
536
540
  import { INodeData } from "@babylonjs/node-geometry-editor/nodeGraphSystem/interfaces/nodeData";
537
541
  import { NodeGeometryBlockConnectionPointTypes } from "@babylonjs/core/Meshes/Node/Enums/nodeGeometryConnectionPointTypes";
542
+ import { Nullable } from "@babylonjs/core/types";
543
+ import { StateManager } from "@babylonjs/node-geometry-editor/nodeGraphSystem/stateManager";
538
544
  export class InputDisplayManager implements IDisplayManager {
545
+ private _hasHighlights;
539
546
  getHeaderClass(nodeData: INodeData): string;
540
547
  getHeaderText(nodeData: INodeData): string;
541
548
  shouldDisplayPortLabels(): boolean;
542
549
  static GetBaseType(type: NodeGeometryBlockConnectionPointTypes): string;
543
550
  getBackgroundColor(nodeData: INodeData): string;
544
551
  updatePreviewContent(nodeData: INodeData, contentArea: HTMLDivElement): void;
552
+ onSelectionChanged(nodeData: INodeData, selectedData: Nullable<INodeData>, manager: StateManager): void;
553
+ onDispose(nodeData: INodeData, manager: StateManager): void;
545
554
  }
546
555
 
547
556
  }
@@ -788,12 +797,14 @@ import { NodeGeometry } from "@babylonjs/core/Meshes/Node/nodeGeometry";
788
797
  import { Observable } from "@babylonjs/core/Misc/observable";
789
798
  import { Color4 } from "@babylonjs/core/Maths/math.color";
790
799
  import { Scene } from "@babylonjs/core/scene";
800
+ import { Mesh } from "@babylonjs/core/Meshes/mesh";
791
801
  /**
792
802
  * Interface used to specify creation options for the node editor
793
803
  */
794
804
  export interface INodeEditorOptions {
795
805
  nodeGeometry: NodeGeometry;
796
- hostScene: Scene;
806
+ hostScene?: Scene;
807
+ hostMesh?: Mesh;
797
808
  hostElement?: HTMLElement;
798
809
  customSave?: {
799
810
  label: string;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@babylonjs/node-geometry-editor",
3
- "version": "6.17.0",
3
+ "version": "6.18.0",
4
4
  "main": "dist/babylon.nodeGeometryEditor.max.js",
5
5
  "module": "dist/babylon.nodeGeometryEditor.max.js",
6
6
  "esnext": "dist/babylon.nodeGeometryEditor.max.js",
@@ -23,7 +23,7 @@
23
23
  "@types/react-dom": ">=16.0.9"
24
24
  },
25
25
  "devDependencies": {
26
- "@babylonjs/core": "^6.17.0",
26
+ "@babylonjs/core": "^6.18.0",
27
27
  "react": "^17.0.2",
28
28
  "react-dom": "^17.0.2"
29
29
  },