David Catuhe 6 lat temu
rodzic
commit
6248db3864

+ 1 - 0
Tools/Config/config.json

@@ -596,6 +596,7 @@
             "uncheckedLintImports": [
             "uncheckedLintImports": [
                 "react",
                 "react",
                 "react-dom",
                 "react-dom",
+                "dagre",
                 "re-resizable",
                 "re-resizable",
                 "glTF"
                 "glTF"
             ],
             ],

+ 15 - 15
Tools/Gulp/helpers/gulp-validateImports.js

@@ -10,7 +10,7 @@ var config = require("../../Config/config");
 const indexExlclusion = ["States", "EmitterTypes"];
 const indexExlclusion = ["States", "EmitterTypes"];
 const forbiddenImports = ["meshBuilder"];
 const forbiddenImports = ["meshBuilder"];
 
 
-const mapping = { };
+const mapping = {};
 config.modules.forEach(moduleName => {
 config.modules.forEach(moduleName => {
     mapping[config[moduleName].build.umd.packageName] = moduleName;
     mapping[config[moduleName].build.umd.packageName] = moduleName;
 });
 });
@@ -196,7 +196,7 @@ var validateImports = function(data, fileLocation, options) {
 function gulpValidateImports(options) {
 function gulpValidateImports(options) {
     var globalErrors = [];
     var globalErrors = [];
 
 
-    return through.obj(function (file, enc, cb) {
+    return through.obj(function(file, enc, cb) {
         if (file.isNull()) {
         if (file.isNull()) {
             cb(null, file);
             cb(null, file);
             return;
             return;
@@ -204,7 +204,7 @@ function gulpValidateImports(options) {
         if (file.isStream()) {
         if (file.isStream()) {
             cb(new PluginError("Validate imports", "Streaming not supported."));
             cb(new PluginError("Validate imports", "Streaming not supported."));
         }
         }
-        
+
         let data = file.contents.toString();
         let data = file.contents.toString();
         let result = validateImports(data, file.path, options);
         let result = validateImports(data, file.path, options);
 
 
@@ -218,20 +218,20 @@ function gulpValidateImports(options) {
         }
         }
 
 
         return cb();
         return cb();
-    }, 
-    function endStream(cb) {
-        if (globalErrors.length > 0) {
-            for (let error of globalErrors) {
-                colorConsole.error(error.message + " " + error.path);
-            }
-            colorConsole.error(`Import validation failed with ${globalErrors.length} errors.`);
+    },
+        function endStream(cb) {
+            if (globalErrors.length > 0) {
+                for (let error of globalErrors) {
+                    colorConsole.error(error.message + " " + error.path);
+                }
+                colorConsole.error(`Import validation failed with ${globalErrors.length} errors.`);
 
 
-            var finalMessage = new PluginError('gulp-validateImports', `gulp-validateImports: ${globalErrors.length} errors found.`);
-            this.emit('error', finalMessage);
-        }
+                var finalMessage = new PluginError('gulp-validateImports', `gulp-validateImports: ${globalErrors.length} errors found.`);
+                this.emit('error', finalMessage);
+            }
 
 
-        cb();
-    });
+            cb();
+        });
 }
 }
 
 
 module.exports = gulpValidateImports;
 module.exports = gulpValidateImports;

+ 1 - 1
nodeEditor/src/components/diagram/texture/textureNodeModel.tsx

@@ -6,7 +6,7 @@ import { GlobalState } from '../../../globalState';
 import { TexturePropertyTabComponent } from './texturePropertyTabComponent';
 import { TexturePropertyTabComponent } from './texturePropertyTabComponent';
 import { NodeCreationOptions, GraphEditor } from '../../../graphEditor';
 import { NodeCreationOptions, GraphEditor } from '../../../graphEditor';
 import { DiagramModel } from 'storm-react-diagrams/dist/@types/src/models/DiagramModel';
 import { DiagramModel } from 'storm-react-diagrams/dist/@types/src/models/DiagramModel';
-import { TextureBlock } from 'babylonjs/Materials/Node/Blocks/Fragment/textureBlock';
+import { TextureBlock } from 'babylonjs/Materials/Node/Blocks/Dual/textureBlock';
 
 
 /**
 /**
  * Texture node model which stores information about a node editor block
  * Texture node model which stores information about a node editor block

+ 1 - 1
nodeEditor/src/graphEditor.tsx

@@ -22,7 +22,7 @@ import { TextureNodeModel } from './components/diagram/texture/textureNodeModel'
 import { DefaultPortModel } from './components/diagram/defaultPortModel';
 import { DefaultPortModel } from './components/diagram/defaultPortModel';
 import { InputNodeFactory } from './components/diagram/input/inputNodeFactory';
 import { InputNodeFactory } from './components/diagram/input/inputNodeFactory';
 import { InputNodeModel } from './components/diagram/input/inputNodeModel';
 import { InputNodeModel } from './components/diagram/input/inputNodeModel';
-import { TextureBlock } from 'babylonjs/Materials/Node/Blocks/Fragment/textureBlock';
+import { TextureBlock } from 'babylonjs/Materials/Node/Blocks/Dual/textureBlock';
 import { LogComponent, LogEntry } from './components/log/logComponent';
 import { LogComponent, LogEntry } from './components/log/logComponent';
 import { LightBlock } from 'babylonjs/Materials/Node/Blocks/Dual/lightBlock';
 import { LightBlock } from 'babylonjs/Materials/Node/Blocks/Dual/lightBlock';
 import { LightNodeModel } from './components/diagram/light/lightNodeModel';
 import { LightNodeModel } from './components/diagram/light/lightNodeModel';

+ 0 - 1
src/Materials/Node/Blocks/Dual/textureBlock.ts

@@ -164,7 +164,6 @@ export class TextureBlock extends NodeMaterialBlock {
         state.samplers.push(this._samplerName);
         state.samplers.push(this._samplerName);
         state._samplerDeclaration += `uniform sampler2D ${this._samplerName};\r\n`;
         state._samplerDeclaration += `uniform sampler2D ${this._samplerName};\r\n`;
 
 
-
         // Fragment
         // Fragment
         state.sharedData.blocksWithDefines.push(this);
         state.sharedData.blocksWithDefines.push(this);
         state.sharedData.bindableBlocks.push(this);
         state.sharedData.bindableBlocks.push(this);