@babylonjs/node-editor 7.25.1 → 7.26.0
Sign up to get free protection for your applications and to get access to all the features.
@@ -316,8 +316,9 @@ import { CurveBlock } from "@babylonjs/core/Materials/Node/Blocks/curveBlock";
|
|
316
316
|
import { PrePassTextureBlock } from "@babylonjs/core/Materials/Node/Blocks/Input/prePassTextureBlock";
|
317
317
|
import { NodeMaterialTeleportInBlock } from "@babylonjs/core/Materials/Node/Blocks/Teleport/teleportInBlock";
|
318
318
|
import { NodeMaterialTeleportOutBlock } from "@babylonjs/core/Materials/Node/Blocks/Teleport/teleportOutBlock";
|
319
|
+
import { ColorConverterBlock } from "@babylonjs/core/Materials/Node/Blocks/colorConverterBlock";
|
319
320
|
export class BlockTools {
|
320
|
-
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 | PrePassTextureBlock | ImageProcessingBlock | ColorMergerBlock | VectorMergerBlock | ColorSplitterBlock | VectorSplitterBlock | TextureBlock | ReflectionTextureBlock | LightBlock | FogBlock | VertexOutputBlock | FragmentOutputBlock | PrePassOutputBlock | 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;
|
321
|
+
static GetBlockFromString(data: string, scene: Scene, nodeMaterial: NodeMaterial): ColorConverterBlock | NodeMaterialTeleportInBlock | NodeMaterialTeleportOutBlock | HeightToNormalBlock | ElbowBlock | TwirlBlock | VoronoiNoiseBlock | ScreenSpaceBlock | CloudBlock | MatrixBuilderBlock | DesaturateBlock | RefractBlock | ReflectBlock | DerivativeBlock | Rotate2dBlock | NormalBlendBlock | WorleyNoise3DBlock | SimplexPerlin3DBlock | BonesBlock | InstancesBlock | MorphTargetsBlock | DiscardBlock | PrePassTextureBlock | ImageProcessingBlock | ColorMergerBlock | VectorMergerBlock | ColorSplitterBlock | VectorSplitterBlock | TextureBlock | ReflectionTextureBlock | LightBlock | FogBlock | VertexOutputBlock | FragmentOutputBlock | PrePassOutputBlock | 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;
|
321
322
|
static GetColorFromConnectionNodeType(type: NodeMaterialBlockConnectionPointTypes): string;
|
322
323
|
static GetConnectionNodeTypeFromString(type: string): NodeMaterialBlockConnectionPointTypes.Float | NodeMaterialBlockConnectionPointTypes.Vector2 | NodeMaterialBlockConnectionPointTypes.Vector3 | NodeMaterialBlockConnectionPointTypes.Vector4 | NodeMaterialBlockConnectionPointTypes.Color3 | NodeMaterialBlockConnectionPointTypes.Color4 | NodeMaterialBlockConnectionPointTypes.Matrix | NodeMaterialBlockConnectionPointTypes.AutoDetect;
|
323
324
|
static GetStringFromConnectionNodeType(type: NodeMaterialBlockConnectionPointTypes): "" | "Float" | "Vector2" | "Vector3" | "Vector4" | "Matrix" | "Color3" | "Color4";
|
@@ -1458,8 +1459,9 @@ import { IDisposable } from "@babylonjs/core/scene";
|
|
1458
1459
|
* Class handling undo / redo operations
|
1459
1460
|
*/
|
1460
1461
|
export class HistoryStack implements IDisposable {
|
1461
|
-
private
|
1462
|
+
private _historyStack;
|
1462
1463
|
private _redoStack;
|
1464
|
+
private _activeData;
|
1463
1465
|
private readonly _maxHistoryLength;
|
1464
1466
|
private _locked;
|
1465
1467
|
private _dataProvider;
|
@@ -1470,13 +1472,19 @@ export class HistoryStack implements IDisposable {
|
|
1470
1472
|
* @param applyUpdate defines the code to execute when undo/redo operation is required
|
1471
1473
|
*/
|
1472
1474
|
constructor(dataProvider: () => any, applyUpdate: (data: any) => void);
|
1475
|
+
/**
|
1476
|
+
* Process key event to handle undo / redo
|
1477
|
+
* @param evt defines the keyboard event to process
|
1478
|
+
* @returns true if the event was processed
|
1479
|
+
*/
|
1480
|
+
processKeyEvent(evt: KeyboardEvent): boolean;
|
1473
1481
|
/**
|
1474
1482
|
* Resets the stack
|
1475
1483
|
*/
|
1476
1484
|
reset(): void;
|
1477
1485
|
private _generateJSONDiff;
|
1478
1486
|
private _applyJSONDiff;
|
1479
|
-
private
|
1487
|
+
private _copy;
|
1480
1488
|
/**
|
1481
1489
|
* Stores the current state
|
1482
1490
|
*/
|
package/package.json
CHANGED
@@ -1,6 +1,6 @@
|
|
1
1
|
{
|
2
2
|
"name": "@babylonjs/node-editor",
|
3
|
-
"version": "7.
|
3
|
+
"version": "7.26.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": "^7.
|
26
|
+
"@babylonjs/core": "^7.26.0",
|
27
27
|
"react": "^17.0.2",
|
28
28
|
"react-dom": "^17.0.2"
|
29
29
|
},
|