소스 검색

Fix bug incremental loading + importMesh

I was trying to use importMesh with incremental loading, but I always got a 404 when trying to fetch each mesh files.
Babylon tries to fetch url like this : http://localhost/undefinedMeshFileName.babylonmeshdata, in parseMesh method (l 275), parsedMesh.delayLoadingFile is not null (l 304), but rootUrl is not found, so setting "undefinedMeshFileName.babylonmeshdata" in mesh.delayLoadingFile (l 306), so adding rootUrl in parseMesh call (l 503) seems to fix this bug.
OBRE Nicolas 12 년 전
부모
커밋
fd91ccb6d0
1개의 변경된 파일2개의 추가작업 그리고 2개의 파일을 삭제
  1. 2 2
      Babylon/Tools/babylon.sceneLoader.js

+ 2 - 2
Babylon/Tools/babylon.sceneLoader.js

@@ -500,7 +500,7 @@
                             }
                         }
 
-                        var mesh = parseMesh(parsedMesh, scene);
+                        var mesh = parseMesh(parsedMesh, scene, rootUrl);
                         meshes.push(mesh);
                     }
                 }
@@ -635,4 +635,4 @@
             }, progressCallBack, database);
         }
     };
-})();
+})();