@babylonjs/node-editor 6.15.0 → 6.16.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.
@@ -95,8 +95,10 @@ import { TriPlanarBlock } from "@babylonjs/core/Materials/Node/Blocks/triPlanarB
|
|
95
95
|
import { MatrixDeterminantBlock } from "@babylonjs/core/Materials/Node/Blocks/matrixDeterminantBlock";
|
96
96
|
import { MatrixTransposeBlock } from "@babylonjs/core/Materials/Node/Blocks/matrixTransposeBlock";
|
97
97
|
import { CurveBlock } from "@babylonjs/core/Materials/Node/Blocks/curveBlock";
|
98
|
+
import { NodeMaterialTeleportInBlock } from "@babylonjs/core/Materials/Node/Blocks/Teleport/teleportInBlock";
|
99
|
+
import { NodeMaterialTeleportOutBlock } from "@babylonjs/core/Materials/Node/Blocks/Teleport/teleportOutBlock";
|
98
100
|
export class BlockTools {
|
99
|
-
static GetBlockFromString(data: string, scene: Scene, nodeMaterial: NodeMaterial): HeightToNormalBlock | ElbowBlock | TwirlBlock | VoronoiNoiseBlock | ScreenSpaceBlock | CloudBlock | MatrixBuilderBlock | DesaturateBlock | RefractBlock | ReflectBlock | DerivativeBlock | Rotate2dBlock | NormalBlendBlock | WorleyNoise3DBlock | SimplexPerlin3DBlock | BonesBlock | InstancesBlock | MorphTargetsBlock | DiscardBlock | ImageProcessingBlock | ColorMergerBlock | VectorMergerBlock | ColorSplitterBlock | VectorSplitterBlock | TextureBlock | ReflectionTextureBlock | LightBlock | FogBlock | VertexOutputBlock | FragmentOutputBlock | AddBlock | ClampBlock | ScaleBlock | CrossBlock | DotBlock | PowBlock | MultiplyBlock | TransformBlock | TrigonometryBlock | RemapBlock | NormalizeBlock | FresnelBlock | LerpBlock | NLerpBlock | DivideBlock | SubtractBlock | ModBlock | StepBlock | SmoothStepBlock | OneMinusBlock | ReciprocalBlock | ViewDirectionBlock | LightInformationBlock | MaxBlock | MinBlock | LengthBlock | DistanceBlock | NegateBlock | PerturbNormalBlock | TBNBlock | RandomNumberBlock | ReplaceColorBlock | PosterizeBlock | ArcTan2Block | GradientBlock | FrontFacingBlock | MeshAttributeExistsBlock | WaveBlock | InputBlock | PBRMetallicRoughnessBlock | SheenBlock | AnisotropyBlock | ReflectionBlock | ClearCoatBlock | RefractionBlock | SubSurfaceBlock | CurrentScreenBlock | ParticleTextureBlock | ParticleRampGradientBlock | ParticleBlendMultiplyBlock | FragCoordBlock | ScreenSizeBlock | SceneDepthBlock | ConditionalBlock | ImageSourceBlock | ClipPlanesBlock | FragDepthBlock | ShadowMapBlock | TriPlanarBlock | MatrixTransposeBlock | MatrixDeterminantBlock | CurveBlock | null;
|
101
|
+
static GetBlockFromString(data: string, scene: Scene, nodeMaterial: NodeMaterial): NodeMaterialTeleportInBlock | NodeMaterialTeleportOutBlock | HeightToNormalBlock | ElbowBlock | TwirlBlock | VoronoiNoiseBlock | ScreenSpaceBlock | CloudBlock | MatrixBuilderBlock | DesaturateBlock | RefractBlock | ReflectBlock | DerivativeBlock | Rotate2dBlock | NormalBlendBlock | WorleyNoise3DBlock | SimplexPerlin3DBlock | BonesBlock | InstancesBlock | MorphTargetsBlock | DiscardBlock | ImageProcessingBlock | ColorMergerBlock | VectorMergerBlock | ColorSplitterBlock | VectorSplitterBlock | TextureBlock | ReflectionTextureBlock | LightBlock | FogBlock | VertexOutputBlock | FragmentOutputBlock | AddBlock | ClampBlock | ScaleBlock | CrossBlock | DotBlock | PowBlock | MultiplyBlock | TransformBlock | TrigonometryBlock | RemapBlock | NormalizeBlock | FresnelBlock | LerpBlock | NLerpBlock | DivideBlock | SubtractBlock | ModBlock | StepBlock | SmoothStepBlock | OneMinusBlock | ReciprocalBlock | ViewDirectionBlock | LightInformationBlock | MaxBlock | MinBlock | LengthBlock | DistanceBlock | NegateBlock | PerturbNormalBlock | TBNBlock | RandomNumberBlock | ReplaceColorBlock | PosterizeBlock | ArcTan2Block | GradientBlock | FrontFacingBlock | MeshAttributeExistsBlock | WaveBlock | InputBlock | PBRMetallicRoughnessBlock | SheenBlock | AnisotropyBlock | ReflectionBlock | ClearCoatBlock | RefractionBlock | SubSurfaceBlock | CurrentScreenBlock | ParticleTextureBlock | ParticleRampGradientBlock | ParticleBlendMultiplyBlock | FragCoordBlock | ScreenSizeBlock | SceneDepthBlock | ConditionalBlock | ImageSourceBlock | ClipPlanesBlock | FragDepthBlock | ShadowMapBlock | TriPlanarBlock | MatrixTransposeBlock | MatrixDeterminantBlock | CurveBlock | null;
|
100
102
|
static GetColorFromConnectionNodeType(type: NodeMaterialBlockConnectionPointTypes): string;
|
101
103
|
static GetConnectionNodeTypeFromString(type: string): NodeMaterialBlockConnectionPointTypes.Float | NodeMaterialBlockConnectionPointTypes.Vector2 | NodeMaterialBlockConnectionPointTypes.Vector3 | NodeMaterialBlockConnectionPointTypes.Vector4 | NodeMaterialBlockConnectionPointTypes.Color3 | NodeMaterialBlockConnectionPointTypes.Color4 | NodeMaterialBlockConnectionPointTypes.Matrix | NodeMaterialBlockConnectionPointTypes.AutoDetect;
|
102
104
|
static GetStringFromConnectionNodeType(type: NodeMaterialBlockConnectionPointTypes): "" | "Float" | "Vector2" | "Vector3" | "Vector4" | "Matrix" | "Color3" | "Color4";
|
@@ -591,6 +593,7 @@ export class BlockNodeData implements INodeData {
|
|
591
593
|
getPortByName(name: string): IPortData | null;
|
592
594
|
dispose(): void;
|
593
595
|
prepareHeaderIcon(iconDiv: HTMLDivElement, img: HTMLImageElement): void;
|
596
|
+
get invisibleEndpoints(): import("@babylonjs/core/Materials/Node/Blocks").NodeMaterialTeleportOutBlock[] | null;
|
594
597
|
constructor(data: NodeMaterialBlock, nodeContainer: INodeContainer);
|
595
598
|
}
|
596
599
|
|
@@ -784,6 +787,40 @@ export class RemapDisplayManager implements IDisplayManager {
|
|
784
787
|
updatePreviewContent(nodeData: INodeData, contentArea: HTMLDivElement): void;
|
785
788
|
}
|
786
789
|
|
790
|
+
}
|
791
|
+
declare module "@babylonjs/node-editor/graphSystem/display/teleportInDisplayManager" {
|
792
|
+
import { IDisplayManager } from "@babylonjs/node-editor/nodeGraphSystem/interfaces/displayManager";
|
793
|
+
import { INodeData } from "@babylonjs/node-editor/nodeGraphSystem/interfaces/nodeData";
|
794
|
+
import { StateManager } from "@babylonjs/node-editor/nodeGraphSystem/stateManager";
|
795
|
+
import { Nullable } from "@babylonjs/core/types";
|
796
|
+
export class TeleportInDisplayManager implements IDisplayManager {
|
797
|
+
private _hasHighlights;
|
798
|
+
getHeaderClass(): string;
|
799
|
+
shouldDisplayPortLabels(): boolean;
|
800
|
+
getHeaderText(nodeData: INodeData): string;
|
801
|
+
getBackgroundColor(nodeData: INodeData): string;
|
802
|
+
updatePreviewContent(nodeData: INodeData, contentArea: HTMLDivElement): void;
|
803
|
+
onSelectionChanged(nodeData: INodeData, selectedData: Nullable<INodeData>, manager: StateManager): void;
|
804
|
+
onDispose(nodeData: INodeData, manager: StateManager): void;
|
805
|
+
}
|
806
|
+
|
807
|
+
}
|
808
|
+
declare module "@babylonjs/node-editor/graphSystem/display/teleportOutDisplayManager" {
|
809
|
+
import { IDisplayManager } from "@babylonjs/node-editor/nodeGraphSystem/interfaces/displayManager";
|
810
|
+
import { INodeData } from "@babylonjs/node-editor/nodeGraphSystem/interfaces/nodeData";
|
811
|
+
import { StateManager } from "@babylonjs/node-editor/nodeGraphSystem/stateManager";
|
812
|
+
import { Nullable } from "@babylonjs/core/types";
|
813
|
+
export class TeleportOutDisplayManager implements IDisplayManager {
|
814
|
+
private _hasHighlights;
|
815
|
+
getHeaderClass(): string;
|
816
|
+
shouldDisplayPortLabels(): boolean;
|
817
|
+
getHeaderText(nodeData: INodeData): string;
|
818
|
+
getBackgroundColor(nodeData: INodeData): string;
|
819
|
+
updatePreviewContent(nodeData: INodeData, contentArea: HTMLDivElement): void;
|
820
|
+
onSelectionChanged(nodeData: INodeData, selectedData: Nullable<INodeData>, manager: StateManager): void;
|
821
|
+
onDispose(nodeData: INodeData, manager: StateManager): void;
|
822
|
+
}
|
823
|
+
|
787
824
|
}
|
788
825
|
declare module "@babylonjs/node-editor/graphSystem/display/textureDisplayManager" {
|
789
826
|
import { IDisplayManager } from "@babylonjs/node-editor/nodeGraphSystem/interfaces/displayManager";
|
@@ -880,7 +917,7 @@ export class FramePropertyTabComponent extends React.Component<IFramePropertyTab
|
|
880
917
|
}
|
881
918
|
declare module "@babylonjs/node-editor/graphSystem/properties/genericNodePropertyComponent" {
|
882
919
|
import * as React from "react";
|
883
|
-
import { IEditablePropertyOption } from "@babylonjs/core/
|
920
|
+
import { IEditablePropertyOption } from "@babylonjs/core/Decorators/nodeDecorator";
|
884
921
|
import { IPropertyComponentProps } from "@babylonjs/node-editor/nodeGraphSystem/interfaces/propertyComponentProps";
|
885
922
|
export class GenericPropertyComponent extends React.Component<IPropertyComponentProps> {
|
886
923
|
constructor(props: IPropertyComponentProps);
|
@@ -1014,6 +1051,18 @@ export class NodePortPropertyTabComponent extends React.Component<IFrameNodePort
|
|
1014
1051
|
render(): JSX.Element;
|
1015
1052
|
}
|
1016
1053
|
|
1054
|
+
}
|
1055
|
+
declare module "@babylonjs/node-editor/graphSystem/properties/teleportOutNodePropertyComponent" {
|
1056
|
+
import * as React from "react";
|
1057
|
+
import { IPropertyComponentProps } from "@babylonjs/node-editor/nodeGraphSystem/interfaces/propertyComponentProps";
|
1058
|
+
export class TeleportOutPropertyTabComponent extends React.Component<IPropertyComponentProps> {
|
1059
|
+
private _onUpdateRequiredObserver;
|
1060
|
+
constructor(props: IPropertyComponentProps);
|
1061
|
+
componentDidMount(): void;
|
1062
|
+
componentWillUnmount(): void;
|
1063
|
+
render(): JSX.Element;
|
1064
|
+
}
|
1065
|
+
|
1017
1066
|
}
|
1018
1067
|
declare module "@babylonjs/node-editor/graphSystem/properties/texturePropertyTabComponent" {
|
1019
1068
|
import * as React from "react";
|
@@ -3645,6 +3694,7 @@ export class GraphNode {
|
|
3645
3694
|
private _onSelectionBoxMovedObserver;
|
3646
3695
|
private _onFrameCreatedObserver;
|
3647
3696
|
private _onUpdateRequiredObserver;
|
3697
|
+
private _onHighlightNodeObserver;
|
3648
3698
|
private _ownerCanvas;
|
3649
3699
|
private _isSelected;
|
3650
3700
|
private _displayManager;
|
@@ -3693,6 +3743,8 @@ export class GraphNode {
|
|
3693
3743
|
|
3694
3744
|
}
|
3695
3745
|
declare module "@babylonjs/node-editor/nodeGraphSystem/interfaces/displayManager" {
|
3746
|
+
import { Nullable } from "@babylonjs/core/types";
|
3747
|
+
import { StateManager } from "@babylonjs/node-editor/nodeGraphSystem/stateManager";
|
3696
3748
|
import { INodeData } from "@babylonjs/node-editor/nodeGraphSystem/interfaces/nodeData";
|
3697
3749
|
import { IPortData } from "@babylonjs/node-editor/nodeGraphSystem/interfaces/portData";
|
3698
3750
|
export interface VisualContentDescription {
|
@@ -3705,6 +3757,8 @@ export interface IDisplayManager {
|
|
3705
3757
|
updateFullVisualContent?(data: INodeData, visualContent: VisualContentDescription): void;
|
3706
3758
|
getBackgroundColor(data: INodeData): string;
|
3707
3759
|
getHeaderText(data: INodeData): string;
|
3760
|
+
onSelectionChanged?(data: INodeData, selectedData: Nullable<INodeData>, manager: StateManager): void;
|
3761
|
+
onDispose?(nodeData: INodeData, manager: StateManager): void;
|
3708
3762
|
}
|
3709
3763
|
|
3710
3764
|
}
|
@@ -3732,6 +3786,7 @@ export interface INodeData {
|
|
3732
3786
|
getPortByName: (name: string) => Nullable<IPortData>;
|
3733
3787
|
inputs: IPortData[];
|
3734
3788
|
outputs: IPortData[];
|
3789
|
+
invisibleEndpoints?: Nullable<any[]>;
|
3735
3790
|
}
|
3736
3791
|
|
3737
3792
|
}
|
@@ -3961,7 +4016,7 @@ export class StateManager {
|
|
3961
4016
|
onFrameCreatedObservable: Observable<GraphFrame>;
|
3962
4017
|
onUpdateRequiredObservable: Observable<any>;
|
3963
4018
|
onGraphNodeRemovalObservable: Observable<GraphNode>;
|
3964
|
-
onSelectionBoxMoved: Observable<
|
4019
|
+
onSelectionBoxMoved: Observable<DOMRect | ClientRect>;
|
3965
4020
|
onCandidateLinkMoved: Observable<Nullable<Vector2>>;
|
3966
4021
|
onCandidatePortSelectedObservable: Observable<Nullable<FrameNodePort | NodePort>>;
|
3967
4022
|
onNewNodeCreatedObservable: Observable<GraphNode>;
|
@@ -3976,6 +4031,10 @@ export class StateManager {
|
|
3976
4031
|
needRepositioning?: boolean | undefined;
|
3977
4032
|
smartAdd?: boolean | undefined;
|
3978
4033
|
}>;
|
4034
|
+
onHighlightNodeObservable: Observable<{
|
4035
|
+
data: any;
|
4036
|
+
active: boolean;
|
4037
|
+
}>;
|
3979
4038
|
exportData: (data: any, frame?: Nullable<GraphFrame>) => string;
|
3980
4039
|
isElbowConnectionAllowed: (nodeA: FrameNodePort | NodePort, nodeB: FrameNodePort | NodePort) => boolean;
|
3981
4040
|
applyNodePortDesign: (data: IPortData, element: HTMLElement, img: HTMLImageElement) => void;
|
@@ -3991,11 +4050,12 @@ export class StateManager {
|
|
3991
4050
|
|
3992
4051
|
}
|
3993
4052
|
declare module "@babylonjs/node-editor/nodeGraphSystem/tools" {
|
4053
|
+
import { GraphCanvasComponent } from "@babylonjs/node-editor/nodeGraphSystem/graphCanvas";
|
3994
4054
|
import { GraphNode } from "@babylonjs/node-editor/nodeGraphSystem/graphNode";
|
3995
4055
|
import { NodeLink } from "@babylonjs/node-editor/nodeGraphSystem/nodeLink";
|
3996
4056
|
import { FramePortData } from "@babylonjs/node-editor/nodeGraphSystem/types/framePortData";
|
3997
4057
|
export const IsFramePortData: (variableToCheck: any) => variableToCheck is FramePortData;
|
3998
|
-
export const RefreshNode: (node: GraphNode, visitedNodes?: Set<GraphNode>, visitedLinks?: Set<NodeLink
|
4058
|
+
export const RefreshNode: (node: GraphNode, visitedNodes?: Set<GraphNode>, visitedLinks?: Set<NodeLink>, canvas?: GraphCanvasComponent) => void;
|
3999
4059
|
|
4000
4060
|
}
|
4001
4061
|
declare module "@babylonjs/node-editor/nodeGraphSystem/typeLedger" {
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@babylonjs/node-editor",
|
3
|
-
"version": "6.
|
3
|
+
"version": "6.16.0",
|
4
4
|
"main": "dist/babylon.nodeEditor.max.js",
|
5
5
|
"module": "dist/babylon.nodeEditor.max.js",
|
6
6
|
"esnext": "dist/babylon.nodeEditor.max.js",
|
@@ -23,7 +23,7 @@
|
|
23
23
|
"@types/react-dom": ">=16.0.9"
|
24
24
|
},
|
25
25
|
"devDependencies": {
|
26
|
-
"@babylonjs/core": "^6.
|
26
|
+
"@babylonjs/core": "^6.16.0",
|
27
27
|
"react": "^17.0.2",
|
28
28
|
"react-dom": "^17.0.2"
|
29
29
|
},
|