@babylonjs/node-geometry-editor 6.17.1 → 6.19.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";
@@ -48,8 +49,9 @@ import { IntFloatConverterBlock } from "@babylonjs/core/Meshes/Node/Blocks/intFl
48
49
  import { ConditionBlock } from "@babylonjs/core/Meshes/Node/Blocks/conditionBlock";
49
50
  import { GeometryCollectionBlock } from "@babylonjs/core/Meshes/Node/Blocks/geometryCollectionBlock";
50
51
  import { GeometryInfoBlock } from "@babylonjs/core/Meshes/Node/Blocks/geometryInfoBlock";
52
+ import { MappingBlock } from "@babylonjs/core/Meshes/Node/Blocks/mappingBlock";
51
53
  export class BlockTools {
52
- static GetBlockFromString(data: string): GeometryInfoBlock | GeometryCollectionBlock | 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;
54
+ static GetBlockFromString(data: string): GeometryInfoBlock | GeometryCollectionBlock | GeometryOptimizeBlock | NullBlock | TeleportInBlock | TeleportOutBlock | DebugBlock | IntFloatConverterBlock | ConditionBlock | MappingBlock | 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;
53
55
  static GetColorFromConnectionNodeType(type: NodeGeometryBlockConnectionPointTypes): string;
54
56
  static GetConnectionNodeTypeFromString(type: string): NodeGeometryBlockConnectionPointTypes.Int | NodeGeometryBlockConnectionPointTypes.Float | NodeGeometryBlockConnectionPointTypes.Vector2 | NodeGeometryBlockConnectionPointTypes.Vector3 | NodeGeometryBlockConnectionPointTypes.Vector4 | NodeGeometryBlockConnectionPointTypes.Matrix | NodeGeometryBlockConnectionPointTypes.AutoDetect;
55
57
  static GetStringFromConnectionNodeType(type: NodeGeometryBlockConnectionPointTypes): "" | "Int" | "Float" | "Vector2" | "Vector3" | "Vector4" | "Matrix";
@@ -136,6 +138,7 @@ export class PreviewManager {
136
138
  private _nodeGeometry;
137
139
  private _onBuildObserver;
138
140
  private _onFrameObserver;
141
+ private _onExportToGLBObserver;
139
142
  private _onAnimationCommandActivatedObserver;
140
143
  private _onUpdateRequiredObserver;
141
144
  private _onPreviewBackgroundChangedObserver;
@@ -209,7 +212,7 @@ interface IInputsPropertyTabComponentProps {
209
212
  }
210
213
  export class InputsPropertyTabComponent extends React.Component<IInputsPropertyTabComponentProps> {
211
214
  constructor(props: IInputsPropertyTabComponentProps);
212
- processInputBlockUpdate(ib: GeometryInputBlock): void;
215
+ processInputBlockUpdate(): void;
213
216
  renderInputBlock(block: GeometryInputBlock): JSX.Element | null;
214
217
  render(): JSX.Element;
215
218
  }
@@ -305,7 +308,7 @@ export class PropertyTabComponent extends React.Component<IPropertyTabComponentP
305
308
  constructor(props: IPropertyTabComponentProps);
306
309
  componentDidMount(): void;
307
310
  componentWillUnmount(): void;
308
- processInputBlockUpdate(ib: GeometryInputBlock): void;
311
+ processInputBlockUpdate(): void;
309
312
  renderInputBlock(block: GeometryInputBlock): JSX.Element | null;
310
313
  load(file: File): void;
311
314
  loadFrame(file: File): void;
@@ -313,6 +316,7 @@ export class PropertyTabComponent extends React.Component<IPropertyTabComponentP
313
316
  customSave(): void;
314
317
  saveToSnippetServer(): void;
315
318
  loadFromSnippet(): void;
319
+ exportAsGLB(): void;
316
320
  render(): JSX.Element;
317
321
  }
318
322
  export {};
@@ -356,6 +360,7 @@ export class GlobalState {
356
360
  lockObject: LockObject;
357
361
  pointerOverCanvas: boolean;
358
362
  onRefreshPreviewMeshControlComponentRequiredObservable: Observable<void>;
363
+ onExportToGLBRequired: Observable<void>;
359
364
  customSave?: {
360
365
  label: string;
361
366
  action: (data: string) => Promise<void>;
@@ -3559,6 +3564,7 @@ export class NodePort {
3559
3564
  node: GraphNode;
3560
3565
  protected _element: HTMLDivElement;
3561
3566
  protected _img: HTMLImageElement;
3567
+ protected _pip: HTMLDivElement;
3562
3568
  protected _stateManager: StateManager;
3563
3569
  protected _portLabelElement: Element;
3564
3570
  protected _onCandidateLinkMovedObserver: Nullable<Observer<Nullable<Vector2>>>;
@@ -3667,7 +3673,7 @@ export class StateManager {
3667
3673
  }>;
3668
3674
  exportData: (data: any, frame?: Nullable<GraphFrame>) => string;
3669
3675
  isElbowConnectionAllowed: (nodeA: FrameNodePort | NodePort, nodeB: FrameNodePort | NodePort) => boolean;
3670
- applyNodePortDesign: (data: IPortData, element: HTMLElement, img: HTMLImageElement) => void;
3676
+ applyNodePortDesign: (data: IPortData, element: HTMLElement, img: HTMLImageElement, pip: HTMLDivElement) => void;
3671
3677
  storeEditorData: (serializationObject: any, frame?: Nullable<GraphFrame>) => void;
3672
3678
  getEditorDataMap: () => {
3673
3679
  [key: number]: number;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@babylonjs/node-geometry-editor",
3
- "version": "6.17.1",
3
+ "version": "6.19.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.1",
26
+ "@babylonjs/core": "^6.19.0",
27
27
  "react": "^17.0.2",
28
28
  "react-dom": "^17.0.2"
29
29
  },