@realsee/five 6.7.0-alpha.5 → 6.7.0-alpha.6

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.
Files changed (123) hide show
  1. package/docs/assets/hierarchy.js +1 -1
  2. package/docs/assets/search.js +1 -1
  3. package/docs/classes/five.Five.html +1 -1
  4. package/docs/classes/five.Model.html +1 -1
  5. package/docs/classes/five.ModelScene.html +1 -1
  6. package/docs/classes/five.PBMContainer.html +1 -1
  7. package/docs/classes/five.PBMGroup.html +1 -1
  8. package/docs/classes/five.PBMMesh.html +1 -1
  9. package/docs/classes/five.PBMMeshMaterial.html +1 -1
  10. package/docs/classes/five.PBMPointCloud.html +1 -1
  11. package/docs/classes/five.PBMPointCloudMaterial.html +1 -1
  12. package/docs/classes/five.PBMSkinnedMesh.html +1 -1
  13. package/docs/classes/five.Parameter.html +1 -1
  14. package/docs/classes/five.Tile3D.html +21 -21
  15. package/docs/classes/five.TileNode.html +1 -1
  16. package/docs/classes/five.TrajectoryNode.html +1 -1
  17. package/docs/classes/five.Work.html +16 -16
  18. package/docs/classes/five.WorkResolvedObserver.html +17 -17
  19. package/docs/classes/gltf-loader.DDSLoader.html +1 -1
  20. package/docs/classes/gltf-loader.DRACOLoader.html +1 -1
  21. package/docs/classes/gltf-loader.GLTFObject.html +1 -1
  22. package/docs/classes/gltf-loader.THREEGLTFLoader.html +1 -1
  23. package/docs/classes/line.LineGeometry.html +1 -1
  24. package/docs/classes/line.LineMaterial.html +1 -1
  25. package/docs/classes/line.LineSegmentsGeometry.html +1 -1
  26. package/docs/classes/line.THREE_Line2.html +1 -1
  27. package/docs/classes/line.THREE_LineSegments2.html +1 -1
  28. package/docs/classes/plugins.RoundedBoxGeometry.html +1 -1
  29. package/docs/classes/vfx.Airflow.html +1 -1
  30. package/docs/classes/vfx.Flame.html +1 -1
  31. package/docs/classes/vfx.Particle.html +1 -1
  32. package/docs/classes/vfx.ParticleGPU.html +1 -1
  33. package/docs/classes/vfx.SpotLight.html +1 -1
  34. package/docs/functions/five.parseWork.html +1 -1
  35. package/docs/functions/vue.useFiveWorks.html +2 -2
  36. package/docs/hierarchy.html +1 -1
  37. package/docs/interfaces/five.AddableObject.html +1 -1
  38. package/docs/interfaces/five.EventCallback.html +1 -1
  39. package/docs/interfaces/five.IntersectMeshInterface.html +1 -1
  40. package/docs/interfaces/five.Intersection.html +1 -1
  41. package/docs/interfaces/five.LoosePanoWork.html +2 -2
  42. package/docs/interfaces/five.LooseWork.html +2 -2
  43. package/docs/interfaces/five.LooseWorkInitial.html +2 -2
  44. package/docs/interfaces/five.LooseWorkModel.html +3 -2
  45. package/docs/interfaces/five.LooseWorkObserver.html +2 -2
  46. package/docs/interfaces/five.LooseWorkPanorama.html +2 -2
  47. package/docs/interfaces/five.LooseWorkVideo.html +2 -2
  48. package/docs/interfaces/five.LooseWorkWithExtrinsics.html +7 -7
  49. package/docs/interfaces/five.ModelControllerCustomInitArgs.html +1 -1
  50. package/docs/interfaces/five.ModelLike.html +1 -1
  51. package/docs/interfaces/five.MovePanoOptions.html +9 -7
  52. package/docs/interfaces/five.PBMMaterial.html +1 -1
  53. package/docs/interfaces/five.PBMMeshMaterialParameters.html +1 -1
  54. package/docs/interfaces/five.PBMPointCloudMaterialParameters.html +1 -1
  55. package/docs/interfaces/five.PanoCircleMeshInterface.html +1 -1
  56. package/docs/interfaces/five.PanoramaControllerCustomInitArgs.html +9 -9
  57. package/docs/interfaces/five.PanoramaLikeControllerCustomInitArgs.html +1 -1
  58. package/docs/interfaces/five.ParameterMaterialValue.html +1 -1
  59. package/docs/interfaces/five.ParameterTilesetValue.html +1 -1
  60. package/docs/interfaces/five.ParameterValue.html +1 -1
  61. package/docs/interfaces/five.Pose.html +1 -1
  62. package/docs/interfaces/five.ResolvedParameterValue.html +1 -1
  63. package/docs/interfaces/five.State.html +1 -1
  64. package/docs/interfaces/five.TopviewControllerCustomInitArgs.html +1 -1
  65. package/docs/interfaces/five.VRPanoramaControllerCustomInitArgs.html +9 -9
  66. package/docs/interfaces/five.ViewLayer.html +21 -21
  67. package/docs/interfaces/five.WorkCubeImage.html +2 -2
  68. package/docs/interfaces/five.WorkImage.html +3 -3
  69. package/docs/interfaces/five.WorkInitial.html +8 -8
  70. package/docs/interfaces/five.WorkModel.html +9 -7
  71. package/docs/interfaces/five.WorkModelLayer.html +2 -2
  72. package/docs/interfaces/five.WorkObserver.html +18 -18
  73. package/docs/interfaces/five.WorkTile.html +4 -4
  74. package/docs/interfaces/five.WorkVideo.html +4 -4
  75. package/docs/interfaces/five.XRPanoramaControllerCustomInitArgs.html +9 -9
  76. package/docs/interfaces/plugins.BackgroundPluginController.html +1 -1
  77. package/docs/interfaces/plugins.BackgroundPluginType.EventMap.html +1 -1
  78. package/docs/interfaces/plugins.ItemMaskController.html +1 -1
  79. package/docs/interfaces/plugins.ItemMaskPluginType.EventMap.html +1 -1
  80. package/docs/interfaces/plugins.ItemMaskPluginType.State.html +1 -1
  81. package/docs/interfaces/plugins.OrientationPluginController.html +1 -1
  82. package/docs/interfaces/plugins.OrientationPluginType.EventMap.html +1 -1
  83. package/docs/interfaces/plugins.OrientationPluginType.State.html +1 -1
  84. package/docs/interfaces/plugins.PanoAnimeController.html +1 -1
  85. package/docs/interfaces/plugins.PanoAnimePluginType.EventMap.html +1 -1
  86. package/docs/interfaces/plugins.PanoAnimePluginType.State.html +1 -1
  87. package/docs/interfaces/plugins.PluginTemplateType.EventMap.html +1 -1
  88. package/docs/interfaces/plugins.PluginTemplateType.State.html +1 -1
  89. package/docs/interfaces/plugins.TrajectoryController.html +1 -1
  90. package/docs/interfaces/react.FiveInjectionTypes.html +1 -1
  91. package/docs/types/five.MovePanoEffect.html +3 -2
  92. package/docs/types/five.ParseOptions.html +6 -6
  93. package/five/index.d.ts +8 -2
  94. package/five/index.js +36 -36
  95. package/five/index.mjs +1725 -1706
  96. package/gltf-loader/index.js +3 -3
  97. package/gltf-loader/index.mjs +3 -3
  98. package/line/index.js +3 -3
  99. package/line/index.mjs +3 -3
  100. package/package.json +1 -1
  101. package/plugins/index.js +2 -2
  102. package/plugins/index.mjs +2 -2
  103. package/react/index.js +2 -2
  104. package/react/index.mjs +2 -2
  105. package/shader-lib/index.js +2 -2
  106. package/shader-lib/index.mjs +2 -2
  107. package/sticker/index.js +3 -3
  108. package/sticker/index.mjs +3 -3
  109. package/umd/five-gltf-loader.js +3 -3
  110. package/umd/five-line.js +3 -3
  111. package/umd/five-plugins.js +2 -2
  112. package/umd/five-react.js +2 -2
  113. package/umd/five-shader-lib.js +2 -2
  114. package/umd/five-sticker.js +3 -3
  115. package/umd/five-vfx.js +2 -2
  116. package/umd/five-vue.js +2 -2
  117. package/umd/five.js +36 -36
  118. package/vfx/index.js +2 -2
  119. package/vfx/index.mjs +2 -2
  120. package/vue/index.js +2 -2
  121. package/vue/index.mjs +2 -2
  122. package/work-downloader/index.js +3 -3
  123. package/work-downloader/index.mjs +33 -33
package/vfx/index.js CHANGED
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * @license
3
3
  * @realsee/five
4
- * Generated: 2025/10/15
5
- * Version: 6.7.0-alpha.5
4
+ * Generated: 10/16/2025
5
+ * Version: 6.7.0-alpha.6
6
6
  * Terms:
7
7
  * Realsee SDK License Agreement
8
8
  * Update: July 28, 2021
package/vfx/index.mjs CHANGED
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * @license
3
3
  * @realsee/five
4
- * Generated: 2025/10/15
5
- * Version: 6.7.0-alpha.5
4
+ * Generated: 10/16/2025
5
+ * Version: 6.7.0-alpha.6
6
6
  * Terms:
7
7
  * Realsee SDK License Agreement
8
8
  * Update: July 28, 2021
package/vue/index.js CHANGED
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * @license
3
3
  * @realsee/five
4
- * Generated: 2025/10/15
5
- * Version: 6.7.0-alpha.5
4
+ * Generated: 10/16/2025
5
+ * Version: 6.7.0-alpha.6
6
6
  * Terms:
7
7
  * Realsee SDK License Agreement
8
8
  * Update: July 28, 2021
package/vue/index.mjs CHANGED
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * @license
3
3
  * @realsee/five
4
- * Generated: 2025/10/15
5
- * Version: 6.7.0-alpha.5
4
+ * Generated: 10/16/2025
5
+ * Version: 6.7.0-alpha.6
6
6
  * Terms:
7
7
  * Realsee SDK License Agreement
8
8
  * Update: July 28, 2021
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * @license
3
3
  * @realsee/five
4
- * Generated: 2025/10/15
5
- * Version: 6.7.0-alpha.5
4
+ * Generated: 10/16/2025
5
+ * Version: 6.7.0-alpha.6
6
6
  * Terms:
7
7
  * Realsee SDK License Agreement
8
8
  * Update: July 28, 2021
@@ -252,4 +252,4 @@
252
252
  * No amendment to or modification of this Agreement will be binding unless in
253
253
  * writing and signed by Realsee. You and Realsee hereto confirm that this
254
254
  * Agreement and all related documents shall be drafted in English.
255
- */"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const q=require("node:fs"),B=require("node:fs/promises"),L=require("node:path"),K=require("node:stream"),Q=require("sharp");function S(n,r,e,i){function a(t){return t instanceof e?t:new e(function(u){u(t)})}return new(e||(e=Promise))(function(t,u){function o(c){try{s(i.next(c))}catch(f){u(f)}}function l(c){try{s(i.throw(c))}catch(f){u(f)}}function s(c){c.done?t(c.value):a(c.value).then(o,l)}s((i=i.apply(n,r||[])).next())})}function F(n,r){var e={label:0,sent:function(){if(t[0]&1)throw t[1];return t[1]},trys:[],ops:[]},i,a,t,u=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return u.next=o(0),u.throw=o(1),u.return=o(2),typeof Symbol=="function"&&(u[Symbol.iterator]=function(){return this}),u;function o(s){return function(c){return l([s,c])}}function l(s){if(i)throw new TypeError("Generator is already executing.");for(;u&&(u=0,s[0]&&(e=0)),e;)try{if(i=1,a&&(t=s[0]&2?a.return:s[0]?a.throw||((t=a.return)&&t.call(a),0):a.next)&&!(t=t.call(a,s[1])).done)return t;switch(a=0,t&&(s=[s[0]&2,t.value]),s[0]){case 0:case 1:t=s;break;case 4:return e.label++,{value:s[1],done:!1};case 5:e.label++,a=s[1],s=[0];continue;case 7:s=e.ops.pop(),e.trys.pop();continue;default:if(t=e.trys,!(t=t.length>0&&t[t.length-1])&&(s[0]===6||s[0]===2)){e=0;continue}if(s[0]===3&&(!t||s[1]>t[0]&&s[1]<t[3])){e.label=s[1];break}if(s[0]===6&&e.label<t[1]){e.label=t[1],t=s;break}if(t&&e.label<t[2]){e.label=t[2],e.ops.push(s);break}t[2]&&e.ops.pop(),e.trys.pop();continue}s=r.call(n,e)}catch(c){s=[6,c],a=0}finally{i=t=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}}function O(n,r){if(r&&r[r.length-1]!=="/"&&(r+="/"),n.length>r.length&&n.startsWith(r))return n.slice(r.length);throw new Error("".concat(n," is not starting with ").concat(r))}function V(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];var e=[];n=n.map(function(o){return(o!=null?o:"").trim()}).filter(function(o){return o.length>0&&!/^\/+$/.test(o)});for(var i=0;i<n.length;i++){var a=i===0,t=i===n.length-1,u=n[i];a||(u=u.replace(/^\.\//,"").replace(/^\/+/,"")),t||(u=u.replace(/\/+$/,"")),e.push(u)}return e.join("/")}var Y=1024*1024*5;function T(n,r,e){return S(this,void 0,void 0,function(){var i,a,t,u;return F(this,function(o){switch(o.label){case 0:return q.existsSync(r)?[2,r]:[4,e(n)];case 1:return i=o.sent(),i.ok&&i.body?[4,B.mkdir(L.dirname(r),{recursive:!0})]:[3,6];case 2:return o.sent(),a=Number((u=i.headers.get("content-length"))!==null&&u!==void 0?u:"Infinity"),a>Y?[2,new Promise(function(l,s){var c=K.Readable.fromWeb(i.body),f=q.createWriteStream(r);c.pipe(f),c.on("error",s),f.on("finish",function(){return l(r)})})]:[3,3];case 3:return[4,i.arrayBuffer()];case 4:return t=o.sent(),[4,B.writeFile(r,Buffer.from(t))];case 5:return o.sent(),[2,r];case 6:throw new Error("url: ".concat(n,"(").concat(i.statusText,")"))}})})}var Z=["jpg","png"];function G(n,r){var e=L.extname(n).slice(1)||"jpg",i=r.cut,a=r.size,t=r.format,u=t===void 0?e:t,o="";if(r.toFilename)o=r.toFilename(n,{cut:r.cut,size:r.size,format:r.format});else{var l="",s="",c=u;i&&(l=i.join("x")),a&&(s="".concat(a,"x")),c===e&&!s&&!l&&(c=""),o=[n,l,s,c].filter(function(f){return f.length>0}).join(".")}return o}function C(n,r){return S(this,void 0,void 0,function(){var e,i,a,t,u,o,l,s,c;return F(this,function(f){return e=L.extname(n).slice(1)||"jpg",i=r.cut,a=r.size,t=r.format,u=t===void 0?e:t,o=n,(i||a)&&u!==e&&Z.includes(u)&&(l=G(n,{format:u,toFilename:r.toFilename}),l!==o&&q.existsSync(l)&&(o=l)),s=Q(o),i&&(s=s.extract({left:i[0],top:i[1],width:i[2],height:i[3]})),a&&(s=s.resize(a)),u&&(s=s.toFormat(u)),c=G(n,r),c!==n&&!q.existsSync(c)?[2,s.toFile(c).then(function(){return c})]:[2,c]})})}function X(n){var r=[];if(n.content&&(n.content.uri?r.push(n.content.uri):n.content.url&&r.push(n.content.url)),n.children)for(var e=0,i=n.children;e<i.length;e++){var a=i[e],t=X(a);t.length>0&&r.push.apply(r,t)}return r}function x(n,r,e){return S(this,void 0,void 0,function(){var i,a,t;return F(this,function(u){switch(u.label){case 0:return i=new URL(n,r).href,a=L.join(e.distPath,O(i,e.baseURL)),t=T(i,a,e.fetch),e.log(function(o){return"download: ".concat(i," -> ").concat(o)},t),[4,t];case 1:return u.sent(),/\.json$/.test(n)?[4,H(i,e)]:[3,3];case 2:u.sent(),u.label=3;case 3:return[2]}})})}function H(n,r){return S(this,void 0,void 0,function(){var e,i,a,t,u,o,l,s,c,f,v,m,p,b,w,h,d,y,k;return F(this,function(g){switch(g.label){case 0:return e=L.join(r.distPath,O(n,r.baseURL)),i=T(n,e,r.fetch),r.log(function(z){return"download: ".concat(n," -> ").concat(z)},i),[4,i];case 1:return g.sent(),u=(t=JSON).parse,[4,B.readFile(e,"utf8")];case 2:return a=u.apply(t,[g.sent()]),a.asset.overview?(o=new URL(a.asset.overview.imageFile,n).href,l=L.join(r.distPath,O(o,r.baseURL)),s=T(o,l,r.fetch),r.log(function(z){return"download: ".concat(o," -> ").concat(z)},s),[4,s]):[3,4];case 3:g.sent(),g.label=4;case 4:if(!a.asset.trajectories)return[3,8];c=function(z){var j,P,R;return F(this,function(U){switch(U.label){case 0:return j=new URL(z.file,n).href,P=L.join(r.distPath,O(j,r.baseURL)),R=T(j,P,r.fetch),r.log(function(_){return"download: ".concat(j," -> ").concat(_)},R),[4,R];case 1:return U.sent(),[2]}})},f=0,v=a.asset.trajectories.list,g.label=5;case 5:return f<v.length?(m=v[f],[5,c(m)]):[3,8];case 6:g.sent(),g.label=7;case 7:return f++,[3,5];case 8:p=X(a.root),b=6,w=0,g.label=9;case 9:if(!(w<p.length))return[3,12];for(h=[],d=0;d<b;d++)y=p[w+d],y&&(k=x(y,n,r),h.push(k));return[4,Promise.all(h)];case 10:g.sent(),g.label=11;case 11:return w+=b,[3,9];case 12:return[2]}})})}function ee(n,r){return S(this,void 0,void 0,function(){var e,i,a,t,u,h,o,l,s,c,f,v,m,p,b,w,h;return F(this,function(d){switch(d.label){case 0:return r.log("process model"),n.model?(e=n.model,i=e.textures,a=e.layers,t=e.file,u=e.textureBase,t?(r.log("process model file"),h=n.getURL(t),o=L.join(r.distPath,O(h,r.baseURL)),l=T(h,o,r.fetch),r.log(function(y){return"download: ".concat(t," -> ").concat(y)},l),[4,l]):[3,5]):[3,9];case 1:if(d.sent(),!i)return[3,5];s=function(y){var k,g,z,j,P,R,U,_,E,$,J,A,D;return F(this,function(M){switch(M.label){case 0:return k=V(n.getURL(u!=null?u:""),y),g=L.join(r.distPath,O(k,r.baseURL)),z=T(k,g,r.fetch),r.log(function(W){return"download: ".concat(k," -> ").concat(W)},z),[4,z];case 1:for(M.sent(),j=r.imageOptions.format,j.length===0&&j.push(void 0),P=r.imageOptions.size,P.length===0&&P.push(void 0),R=[],U=0,_=j;U<_.length;U++)for(E=_[U],$=0,J=P;$<J.length;$++)A=J[$],D=C(g,{format:E,size:A,toFilename:r.imageProcessingFilename}),r.log(function(W){return"imageProcessing: ".concat(g," -> ").concat(W)},D),R.push(D);return[4,Promise.all(R)];case 2:return M.sent(),[2]}})},c=0,f=i,d.label=2;case 2:return c<f.length?(v=f[c],[5,s(v)]):[3,5];case 3:d.sent(),d.label=4;case 4:return c++,[3,2];case 5:if(!a)return[3,9];m=0,p=a,d.label=6;case 6:return m<p.length?(b=p[m],w=b.tileset,r.log("process model layer"),h=n.getURL(w),[4,H(h,r)]):[3,9];case 7:d.sent(),d.label=8;case 8:return m++,[3,6];case 9:return[2]}})})}function N(n,r,e){return S(this,void 0,void 0,function(){var i,a,t,u,o,l,s,c,f,v,m,p,b,w;return F(this,function(h){switch(h.label){case 0:return i=L.join(e.distPath,O(n,e.baseURL)),a=T(n,i,e.fetch),e.log(function(d){return"download: ".concat(n," -> ").concat(d)},a),[4,a];case 1:if(h.sent(),t=Math.pow(2,r.level),u=e.imageOptions.format,u.length===0&&u.push(void 0),o=[],t>1)for(l=0;l<t;l++)for(s=0;s<t;s++)for(c=0,f=u;c<f.length;c++)v=f[c],m=[r.size/t*s,r.size/t*l,r.size/t,r.size/t],p=r.scale>=1?void 0:r.scale*r.size/t,b=C(i,{format:v,size:p,cut:m,toFilename:e.imageProcessingFilename}),e.log(function(d){return"imageProcessing: ".concat(i," -> ").concat(d)},b),o.push(b),r.level===1&&r.scale>=.5&&(v==="jpg"||/\.jpg$/.test(i))&&(w=C(i,{format:v,size:void 0,cut:m,toFilename:e.imageProcessingFilename}),e.log(function(d){return"imageProcessing: ".concat(i," -> ").concat(d)},w),o.push(w));return[4,Promise.all(o)];case 2:return h.sent(),[2]}})})}function re(n,r){return S(this,void 0,void 0,function(){return F(this,function(e){switch(e.label){case 0:return[4,Promise.all([N(n.work.getURL(n.front),n,r),N(n.work.getURL(n.back),n,r),N(n.work.getURL(n.left),n,r),N(n.work.getURL(n.right),n,r),N(n.work.getURL(n.up),n,r),N(n.work.getURL(n.down),n,r)])];case 1:return e.sent(),[2]}})})}function I(n,r,e){return S(this,void 0,void 0,function(){var i,a,t,u,o,l,s,c,f,v,m,p,b,w,h,d;return F(this,function(y){switch(y.label){case 0:return i=L.join(e.distPath,O(n,e.baseURL)),a=T(n,i,e.fetch),e.log(function(k){return"download: ".concat(n," -> ").concat(k)},a),[4,a];case 1:y.sent(),t=e.imageOptions.format,t.length===0&&t.push(void 0),u=e.imageOptions.size,u.length===0&&u.push(void 0),o=function(k){var g,z,j,P,R,U,_;return F(this,function(E){switch(E.label){case 0:return g=n.replace(/cube\_\d+/,"cube_".concat(k)),z=L.join(e.distPath,O(g,e.baseURL)),j=T(g,z,e.fetch),e.log(function($){return"download ".concat(g," -> ").concat(z)},j),[4,j];case 1:E.sent(),P=0,R=t,E.label=2;case 2:return P<R.length?(U=R[P],_=C(z,{format:U,toFilename:e.imageProcessingFilename}),e.log(function($){return"imageProcessing: ".concat(z," -> ").concat($)},_),[4,_]):[3,5];case 3:E.sent(),E.label=4;case 4:return P++,[3,2];case 5:return[2]}})},l=0,s=r,y.label=2;case 2:return l<s.length?(c=s[l],[5,o(c)]):[3,5];case 3:y.sent(),y.label=4;case 4:return l++,[3,2];case 5:for(f=[],v=0,m=t;v<m.length;v++)for(p=m[v],b=0,w=u;b<w.length;b++)h=w[b],d=C(i,{format:p,size:h,toFilename:e.imageProcessingFilename}),e.log(function(k){return"imageProcessing: ".concat(i," -> ").concat(k)},d),f.push(d);return[4,Promise.all(f)];case 6:return y.sent(),[2]}})})}function ne(n,r){return S(this,void 0,void 0,function(){var e;return F(this,function(i){switch(i.label){case 0:return e=n.images,[4,Promise.all([I(e.work.getURL(e.front),e.sizeList,r),I(e.work.getURL(e.back),e.sizeList,r),I(e.work.getURL(e.left),e.sizeList,r),I(e.work.getURL(e.right),e.sizeList,r),I(e.work.getURL(e.up),e.sizeList,r),I(e.work.getURL(e.down),e.sizeList,r)])];case 1:return i.sent(),e.tiles?[4,Promise.all(e.tiles.map(function(a){return re(a,r)}))]:[3,3];case 2:i.sent(),i.label=3;case 3:return[2]}})})}function te(n,r){return S(this,void 0,void 0,function(){var e,i,a,t,u;return F(this,function(o){switch(o.label){case 0:e=n.observers,i=0,a=e,o.label=1;case 1:return i<a.length?(t=a[i],u=ne(t,r),r.log("process observer #".concat(t.index," derived: ").concat(t.derivedIdStr),u),[4,u]):[3,4];case 2:o.sent(),o.label=3;case 3:return i++,[3,1];case 4:return[2]}})})}function ie(n,r){if(r){var e=Date.now();r.then(function(a){var t=Date.now()-e,u=typeof n=="function"?n(a):n;console.log(u+"(".concat(t,"ms)"))}).catch(function(){})}else{var i=typeof n=="function"?n(null):n;console.log(i)}}function ae(n){return S(this,arguments,void 0,function(r,e){var i,a,t,u,o,l,s,c,f,v,m,p,b,w,h;return e===void 0&&(e={}),F(this,function(d){switch(d.label){case 0:if(i=r.baseURL,a="",e.distPath)a=L.resolve(process.cwd(),e.distPath);else for(a=L.resolve(process.cwd(),(l=r.workCode)!==null&&l!==void 0?l:"work-".concat(Date.now()));q.existsSync(a);)/.-(\d+)$/.test(a)?a=a.replace(/.-(\d+)$/,function(y,k){return"-"+(Number(k)+1)}):a=a+"-1";return t={baseURL:i,distPath:a,fetch:(s=e.fetch)!==null&&s!==void 0?s:fetch,imageOptions:{size:(f=(c=e.imageOptions)===null||c===void 0?void 0:c.size)!==null&&f!==void 0?f:[],format:(m=(v=e.imageOptions)===null||v===void 0?void 0:v.format)!==null&&m!==void 0?m:[]},textureOptions:{size:(b=(p=e.textureOptions)===null||p===void 0?void 0:p.size)!==null&&b!==void 0?b:[],format:(h=(w=e.textureOptions)===null||w===void 0?void 0:w.format)!==null&&h!==void 0?h:[]},log:e.log?ie:(function(){return Promise.resolve()}),imageProcessingFilename:e.imageProcessingFilename},t.log(JSON.stringify(t,null," ")),[4,B.mkdir(a,{recursive:!0})];case 1:return d.sent(),u="work.json",o=L.resolve(a,u),[4,B.writeFile(o,JSON.stringify(r.toJSON(),null," "))];case 2:return d.sent(),[4,te(r,t)];case 3:return d.sent(),[4,ee(r,t)];case 4:return d.sent(),[2]}})})}exports.download=ae;
255
+ */"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const I=require("node:fs"),B=require("node:fs/promises"),L=require("node:path"),K=require("node:stream"),Q=require("sharp");function S(n,r,e,i){function a(t){return t instanceof e?t:new e(function(u){u(t)})}return new(e||(e=Promise))(function(t,u){function o(c){try{s(i.next(c))}catch(f){u(f)}}function l(c){try{s(i.throw(c))}catch(f){u(f)}}function s(c){c.done?t(c.value):a(c.value).then(o,l)}s((i=i.apply(n,r||[])).next())})}function F(n,r){var e={label:0,sent:function(){if(t[0]&1)throw t[1];return t[1]},trys:[],ops:[]},i,a,t,u=Object.create((typeof Iterator=="function"?Iterator:Object).prototype);return u.next=o(0),u.throw=o(1),u.return=o(2),typeof Symbol=="function"&&(u[Symbol.iterator]=function(){return this}),u;function o(s){return function(c){return l([s,c])}}function l(s){if(i)throw new TypeError("Generator is already executing.");for(;u&&(u=0,s[0]&&(e=0)),e;)try{if(i=1,a&&(t=s[0]&2?a.return:s[0]?a.throw||((t=a.return)&&t.call(a),0):a.next)&&!(t=t.call(a,s[1])).done)return t;switch(a=0,t&&(s=[s[0]&2,t.value]),s[0]){case 0:case 1:t=s;break;case 4:return e.label++,{value:s[1],done:!1};case 5:e.label++,a=s[1],s=[0];continue;case 7:s=e.ops.pop(),e.trys.pop();continue;default:if(t=e.trys,!(t=t.length>0&&t[t.length-1])&&(s[0]===6||s[0]===2)){e=0;continue}if(s[0]===3&&(!t||s[1]>t[0]&&s[1]<t[3])){e.label=s[1];break}if(s[0]===6&&e.label<t[1]){e.label=t[1],t=s;break}if(t&&e.label<t[2]){e.label=t[2],e.ops.push(s);break}t[2]&&e.ops.pop(),e.trys.pop();continue}s=r.call(n,e)}catch(c){s=[6,c],a=0}finally{i=t=0}if(s[0]&5)throw s[1];return{value:s[0]?s[1]:void 0,done:!0}}}function O(n,r){if(r&&r[r.length-1]!=="/"&&(r+="/"),n.length>r.length&&n.startsWith(r))return n.slice(r.length);throw new Error("".concat(n," is not starting with ").concat(r))}function V(){for(var n=[],r=0;r<arguments.length;r++)n[r]=arguments[r];var e=[];n=n.map(function(o){return(o!=null?o:"").trim()}).filter(function(o){return o.length>0&&!/^\/+$/.test(o)});for(var i=0;i<n.length;i++){var a=i===0,t=i===n.length-1,u=n[i];a||(u=u.replace(/^\.\//,"").replace(/^\/+/,"")),t||(u=u.replace(/\/+$/,"")),e.push(u)}return e.join("/")}var Y=1024*1024*5;function T(n,r,e){return S(this,void 0,void 0,function(){var i,a,t,u;return F(this,function(o){switch(o.label){case 0:return I.existsSync(r)?[2,r]:[4,e(n)];case 1:return i=o.sent(),i.ok&&i.body?[4,B.mkdir(L.dirname(r),{recursive:!0})]:[3,6];case 2:return o.sent(),a=Number((u=i.headers.get("content-length"))!==null&&u!==void 0?u:"Infinity"),a>Y?[2,new Promise(function(l,s){var c=K.Readable.fromWeb(i.body),f=I.createWriteStream(r);c.pipe(f),c.on("error",s),f.on("finish",function(){return l(r)})})]:[3,3];case 3:return[4,i.arrayBuffer()];case 4:return t=o.sent(),[4,B.writeFile(r,Buffer.from(t))];case 5:return o.sent(),[2,r];case 6:throw new Error("url: ".concat(n,"(").concat(i.statusText,")"))}})})}var Z=["jpg","png"],x=95;function G(n,r){var e=L.extname(n).slice(1)||"jpg",i=r.cut,a=r.size,t=r.format,u=t===void 0?e:t,o="";if(r.toFilename)o=r.toFilename(n,{cut:r.cut,size:r.size,format:r.format});else{var l="",s="",c=u;i&&(l=i.join("x")),a&&(s="".concat(a,"x")),c===e&&!s&&!l&&(c=""),o=[n,l,s,c].filter(function(f){return f.length>0}).join(".")}return o}function C(n,r){return S(this,void 0,void 0,function(){var e,i,a,t,u,o,l,s,c;return F(this,function(f){return e=L.extname(n).slice(1)||"jpg",i=r.cut,a=r.size,t=r.format,u=t===void 0?e:t,o=n,(i||a)&&u!==e&&Z.includes(u)&&(l=G(n,{format:u,toFilename:r.toFilename}),l!==o&&I.existsSync(l)&&(o=l)),s=Q(o),i&&(s=s.extract({left:i[0],top:i[1],width:i[2],height:i[3]})),a&&(s=s.resize(a)),s=s.toFormat(u,{quality:x}),c=G(n,r),c!==n&&!I.existsSync(c)?[2,s.toFile(c).then(function(){return c})]:[2,c]})})}function X(n){var r=[];if(n.content&&(n.content.uri?r.push(n.content.uri):n.content.url&&r.push(n.content.url)),n.children)for(var e=0,i=n.children;e<i.length;e++){var a=i[e],t=X(a);t.length>0&&r.push.apply(r,t)}return r}function ee(n,r,e){return S(this,void 0,void 0,function(){var i,a,t;return F(this,function(u){switch(u.label){case 0:return i=new URL(n,r).href,a=L.join(e.distPath,O(i,e.baseURL)),t=T(i,a,e.fetch),e.log(function(o){return"download: ".concat(i," -> ").concat(o)},t),[4,t];case 1:return u.sent(),/\.json$/.test(n)?[4,H(i,e)]:[3,3];case 2:u.sent(),u.label=3;case 3:return[2]}})})}function H(n,r){return S(this,void 0,void 0,function(){var e,i,a,t,u,o,l,s,c,f,v,m,p,b,w,h,d,y,k;return F(this,function(g){switch(g.label){case 0:return e=L.join(r.distPath,O(n,r.baseURL)),i=T(n,e,r.fetch),r.log(function(z){return"download: ".concat(n," -> ").concat(z)},i),[4,i];case 1:return g.sent(),u=(t=JSON).parse,[4,B.readFile(e,"utf8")];case 2:return a=u.apply(t,[g.sent()]),a.asset.overview?(o=new URL(a.asset.overview.imageFile,n).href,l=L.join(r.distPath,O(o,r.baseURL)),s=T(o,l,r.fetch),r.log(function(z){return"download: ".concat(o," -> ").concat(z)},s),[4,s]):[3,4];case 3:g.sent(),g.label=4;case 4:if(!a.asset.trajectories)return[3,8];c=function(z){var j,P,R;return F(this,function(U){switch(U.label){case 0:return j=new URL(z.file,n).href,P=L.join(r.distPath,O(j,r.baseURL)),R=T(j,P,r.fetch),r.log(function(_){return"download: ".concat(j," -> ").concat(_)},R),[4,R];case 1:return U.sent(),[2]}})},f=0,v=a.asset.trajectories.list,g.label=5;case 5:return f<v.length?(m=v[f],[5,c(m)]):[3,8];case 6:g.sent(),g.label=7;case 7:return f++,[3,5];case 8:p=X(a.root),b=6,w=0,g.label=9;case 9:if(!(w<p.length))return[3,12];for(h=[],d=0;d<b;d++)y=p[w+d],y&&(k=ee(y,n,r),h.push(k));return[4,Promise.all(h)];case 10:g.sent(),g.label=11;case 11:return w+=b,[3,9];case 12:return[2]}})})}function re(n,r){return S(this,void 0,void 0,function(){var e,i,a,t,u,h,o,l,s,c,f,v,m,p,b,w,h;return F(this,function(d){switch(d.label){case 0:return r.log("process model"),n.model?(e=n.model,i=e.textures,a=e.layers,t=e.file,u=e.textureBase,t?(r.log("process model file"),h=n.getURL(t),o=L.join(r.distPath,O(h,r.baseURL)),l=T(h,o,r.fetch),r.log(function(y){return"download: ".concat(t," -> ").concat(y)},l),[4,l]):[3,5]):[3,9];case 1:if(d.sent(),!i)return[3,5];s=function(y){var k,g,z,j,P,R,U,_,E,$,J,A,D;return F(this,function(M){switch(M.label){case 0:return k=V(n.getURL(u!=null?u:""),y),g=L.join(r.distPath,O(k,r.baseURL)),z=T(k,g,r.fetch),r.log(function(W){return"download: ".concat(k," -> ").concat(W)},z),[4,z];case 1:for(M.sent(),j=r.imageOptions.format,j.length===0&&j.push(void 0),P=r.imageOptions.size,P.length===0&&P.push(void 0),R=[],U=0,_=j;U<_.length;U++)for(E=_[U],$=0,J=P;$<J.length;$++)A=J[$],D=C(g,{format:E,size:A,toFilename:r.imageProcessingFilename}),r.log(function(W){return"imageProcessing: ".concat(g," -> ").concat(W)},D),R.push(D);return[4,Promise.all(R)];case 2:return M.sent(),[2]}})},c=0,f=i,d.label=2;case 2:return c<f.length?(v=f[c],[5,s(v)]):[3,5];case 3:d.sent(),d.label=4;case 4:return c++,[3,2];case 5:if(!a)return[3,9];m=0,p=a,d.label=6;case 6:return m<p.length?(b=p[m],w=b.tileset,r.log("process model layer"),h=n.getURL(w),[4,H(h,r)]):[3,9];case 7:d.sent(),d.label=8;case 8:return m++,[3,6];case 9:return[2]}})})}function q(n,r,e){return S(this,void 0,void 0,function(){var i,a,t,u,o,l,s,c,f,v,m,p,b,w;return F(this,function(h){switch(h.label){case 0:return i=L.join(e.distPath,O(n,e.baseURL)),a=T(n,i,e.fetch),e.log(function(d){return"download: ".concat(n," -> ").concat(d)},a),[4,a];case 1:if(h.sent(),t=Math.pow(2,r.level),u=e.imageOptions.format,u.length===0&&u.push(void 0),o=[],t>1)for(l=0;l<t;l++)for(s=0;s<t;s++)for(c=0,f=u;c<f.length;c++)v=f[c],m=[r.size/t*s,r.size/t*l,r.size/t,r.size/t],p=r.scale>=1?void 0:r.scale*r.size/t,b=C(i,{format:v,size:p,cut:m,toFilename:e.imageProcessingFilename}),e.log(function(d){return"imageProcessing: ".concat(i," -> ").concat(d)},b),o.push(b),r.level===1&&r.scale>=.5&&(v==="jpg"||/\.jpg$/.test(i))&&(w=C(i,{format:v,size:void 0,cut:m,toFilename:e.imageProcessingFilename}),e.log(function(d){return"imageProcessing: ".concat(i," -> ").concat(d)},w),o.push(w));return[4,Promise.all(o)];case 2:return h.sent(),[2]}})})}function ne(n,r){return S(this,void 0,void 0,function(){return F(this,function(e){switch(e.label){case 0:return[4,Promise.all([q(n.work.getURL(n.front),n,r),q(n.work.getURL(n.back),n,r),q(n.work.getURL(n.left),n,r),q(n.work.getURL(n.right),n,r),q(n.work.getURL(n.up),n,r),q(n.work.getURL(n.down),n,r)])];case 1:return e.sent(),[2]}})})}function N(n,r,e){return S(this,void 0,void 0,function(){var i,a,t,u,o,l,s,c,f,v,m,p,b,w,h,d;return F(this,function(y){switch(y.label){case 0:return i=L.join(e.distPath,O(n,e.baseURL)),a=T(n,i,e.fetch),e.log(function(k){return"download: ".concat(n," -> ").concat(k)},a),[4,a];case 1:y.sent(),t=e.imageOptions.format,t.length===0&&t.push(void 0),u=e.imageOptions.size,u.length===0&&u.push(void 0),o=function(k){var g,z,j,P,R,U,_;return F(this,function(E){switch(E.label){case 0:return g=n.replace(/cube\_\d+/,"cube_".concat(k)),z=L.join(e.distPath,O(g,e.baseURL)),j=T(g,z,e.fetch),e.log(function($){return"download ".concat(g," -> ").concat(z)},j),[4,j];case 1:E.sent(),P=0,R=t,E.label=2;case 2:return P<R.length?(U=R[P],_=C(z,{format:U,toFilename:e.imageProcessingFilename}),e.log(function($){return"imageProcessing: ".concat(z," -> ").concat($)},_),[4,_]):[3,5];case 3:E.sent(),E.label=4;case 4:return P++,[3,2];case 5:return[2]}})},l=0,s=r,y.label=2;case 2:return l<s.length?(c=s[l],[5,o(c)]):[3,5];case 3:y.sent(),y.label=4;case 4:return l++,[3,2];case 5:for(f=[],v=0,m=t;v<m.length;v++)for(p=m[v],b=0,w=u;b<w.length;b++)h=w[b],d=C(i,{format:p,size:h,toFilename:e.imageProcessingFilename}),e.log(function(k){return"imageProcessing: ".concat(i," -> ").concat(k)},d),f.push(d);return[4,Promise.all(f)];case 6:return y.sent(),[2]}})})}function te(n,r){return S(this,void 0,void 0,function(){var e;return F(this,function(i){switch(i.label){case 0:return e=n.images,[4,Promise.all([N(e.work.getURL(e.front),e.sizeList,r),N(e.work.getURL(e.back),e.sizeList,r),N(e.work.getURL(e.left),e.sizeList,r),N(e.work.getURL(e.right),e.sizeList,r),N(e.work.getURL(e.up),e.sizeList,r),N(e.work.getURL(e.down),e.sizeList,r)])];case 1:return i.sent(),e.tiles?[4,Promise.all(e.tiles.map(function(a){return ne(a,r)}))]:[3,3];case 2:i.sent(),i.label=3;case 3:return[2]}})})}function ie(n,r){return S(this,void 0,void 0,function(){var e,i,a,t,u;return F(this,function(o){switch(o.label){case 0:e=n.observers,i=0,a=e,o.label=1;case 1:return i<a.length?(t=a[i],u=te(t,r),r.log("process observer #".concat(t.index," derived: ").concat(t.derivedIdStr),u),[4,u]):[3,4];case 2:o.sent(),o.label=3;case 3:return i++,[3,1];case 4:return[2]}})})}function ae(n,r){if(r){var e=Date.now();r.then(function(a){var t=Date.now()-e,u=typeof n=="function"?n(a):n;console.log(u+"(".concat(t,"ms)"))}).catch(function(){})}else{var i=typeof n=="function"?n(null):n;console.log(i)}}function se(n){return S(this,arguments,void 0,function(r,e){var i,a,t,u,o,l,s,c,f,v,m,p,b,w,h;return e===void 0&&(e={}),F(this,function(d){switch(d.label){case 0:if(i=r.baseURL,a="",e.distPath)a=L.resolve(process.cwd(),e.distPath);else for(a=L.resolve(process.cwd(),(l=r.workCode)!==null&&l!==void 0?l:"work-".concat(Date.now()));I.existsSync(a);)/.-(\d+)$/.test(a)?a=a.replace(/.-(\d+)$/,function(y,k){return"-"+(Number(k)+1)}):a=a+"-1";return t={baseURL:i,distPath:a,fetch:(s=e.fetch)!==null&&s!==void 0?s:fetch,imageOptions:{size:(f=(c=e.imageOptions)===null||c===void 0?void 0:c.size)!==null&&f!==void 0?f:[],format:(m=(v=e.imageOptions)===null||v===void 0?void 0:v.format)!==null&&m!==void 0?m:[]},textureOptions:{size:(b=(p=e.textureOptions)===null||p===void 0?void 0:p.size)!==null&&b!==void 0?b:[],format:(h=(w=e.textureOptions)===null||w===void 0?void 0:w.format)!==null&&h!==void 0?h:[]},log:e.log?ae:(function(){return Promise.resolve()}),imageProcessingFilename:e.imageProcessingFilename},t.log(JSON.stringify(t,null," ")),[4,B.mkdir(a,{recursive:!0})];case 1:return d.sent(),u="work.json",o=L.resolve(a,u),[4,B.writeFile(o,JSON.stringify(r.toJSON(),null," "))];case 2:return d.sent(),[4,ie(r,t)];case 3:return d.sent(),[4,re(r,t)];case 4:return d.sent(),[2]}})})}exports.download=se;
@@ -1,8 +1,8 @@
1
1
  /**
2
2
  * @license
3
3
  * @realsee/five
4
- * Generated: 2025/10/15
5
- * Version: 6.7.0-alpha.5
4
+ * Generated: 10/16/2025
5
+ * Version: 6.7.0-alpha.6
6
6
  * Terms:
7
7
  * Realsee SDK License Agreement
8
8
  * Update: July 28, 2021
@@ -253,8 +253,8 @@
253
253
  * writing and signed by Realsee. You and Realsee hereto confirm that this
254
254
  * Agreement and all related documents shall be drafted in English.
255
255
  */import { createWriteStream as Y, existsSync as C } from "node:fs";
256
- import { writeFile as q, mkdir as H, readFile as Z } from "node:fs/promises";
257
- import { dirname as x, extname as K, join as _, resolve as A } from "node:path";
256
+ import { writeFile as X, mkdir as H, readFile as Z } from "node:fs/promises";
257
+ import { dirname as x, extname as K, join as _, resolve as M } from "node:path";
258
258
  import { Readable as ee } from "node:stream";
259
259
  import re from "sharp";
260
260
  function U(n, r, e, a) {
@@ -384,7 +384,7 @@ function E(n, r, e) {
384
384
  case 3:
385
385
  return [4, a.arrayBuffer()];
386
386
  case 4:
387
- return t = o.sent(), [4, q(r, Buffer.from(t))];
387
+ return t = o.sent(), [4, X(r, Buffer.from(t))];
388
388
  case 5:
389
389
  return o.sent(), [2, r];
390
390
  case 6:
@@ -393,8 +393,8 @@ function E(n, r, e) {
393
393
  });
394
394
  });
395
395
  }
396
- var ae = ["jpg", "png"];
397
- function X(n, r) {
396
+ var ae = ["jpg", "png"], ie = 95;
397
+ function G(n, r) {
398
398
  var e = K(n).slice(1) || "jpg", a = r.cut, i = r.size, t = r.format, u = t === void 0 ? e : t, o = "";
399
399
  if (r.toFilename)
400
400
  o = r.toFilename(n, { cut: r.cut, size: r.size, format: r.format });
@@ -410,7 +410,7 @@ function B(n, r) {
410
410
  return U(this, void 0, void 0, function() {
411
411
  var e, a, i, t, u, o, l, s, c;
412
412
  return L(this, function(f) {
413
- return e = K(n).slice(1) || "jpg", a = r.cut, i = r.size, t = r.format, u = t === void 0 ? e : t, o = n, (a || i) && u !== e && ae.includes(u) && (l = X(n, {
413
+ return e = K(n).slice(1) || "jpg", a = r.cut, i = r.size, t = r.format, u = t === void 0 ? e : t, o = n, (a || i) && u !== e && ae.includes(u) && (l = G(n, {
414
414
  format: u,
415
415
  toFilename: r.toFilename
416
416
  }), l !== o && C(l) && (o = l)), s = re(o), a && (s = s.extract({
@@ -418,7 +418,7 @@ function B(n, r) {
418
418
  top: a[1],
419
419
  width: a[2],
420
420
  height: a[3]
421
- })), i && (s = s.resize(i)), u && (s = s.toFormat(u)), c = X(n, r), c !== n && !C(c) ? [2, s.toFile(c).then(function() {
421
+ })), i && (s = s.resize(i)), s = s.toFormat(u, { quality: ie }), c = G(n, r), c !== n && !C(c) ? [2, s.toFile(c).then(function() {
422
422
  return c;
423
423
  })] : [2, c];
424
424
  });
@@ -433,7 +433,7 @@ function Q(n) {
433
433
  }
434
434
  return r;
435
435
  }
436
- function ie(n, r, e) {
436
+ function se(n, r, e) {
437
437
  return U(this, void 0, void 0, function() {
438
438
  var a, i, t;
439
439
  return L(this, function(u) {
@@ -501,7 +501,7 @@ function V(n, r) {
501
501
  case 9:
502
502
  if (!(w < p.length)) return [3, 12];
503
503
  for (d = [], h = 0; h < b; h++)
504
- y = p[w + h], y && (k = ie(y, n, r), d.push(k));
504
+ y = p[w + h], y && (k = se(y, n, r), d.push(k));
505
505
  return [4, Promise.all(d)];
506
506
  case 10:
507
507
  g.sent(), g.label = 11;
@@ -516,7 +516,7 @@ function V(n, r) {
516
516
  });
517
517
  });
518
518
  }
519
- function se(n, r) {
519
+ function ue(n, r) {
520
520
  return U(this, void 0, void 0, function() {
521
521
  var e, a, i, t, u, d, o, l, s, c, f, m, v, p, b, w, d;
522
522
  return L(this, function(h) {
@@ -528,22 +528,22 @@ function se(n, r) {
528
528
  case 1:
529
529
  if (h.sent(), !a) return [3, 5];
530
530
  s = function(y) {
531
- var k, g, z, F, P, R, j, O, T, $, J, G, D;
531
+ var k, g, z, F, P, R, j, O, T, $, J, A, D;
532
532
  return L(this, function(W) {
533
533
  switch (W.label) {
534
534
  case 0:
535
- return k = ne(n.getURL(u != null ? u : ""), y), g = _(r.distPath, S(k, r.baseURL)), z = E(k, g, r.fetch), r.log(function(M) {
536
- return "download: ".concat(k, " -> ").concat(M);
535
+ return k = ne(n.getURL(u != null ? u : ""), y), g = _(r.distPath, S(k, r.baseURL)), z = E(k, g, r.fetch), r.log(function(q) {
536
+ return "download: ".concat(k, " -> ").concat(q);
537
537
  }, z), [4, z];
538
538
  case 1:
539
539
  for (W.sent(), F = r.imageOptions.format, F.length === 0 && F.push(void 0), P = r.imageOptions.size, P.length === 0 && P.push(void 0), R = [], j = 0, O = F; j < O.length; j++)
540
540
  for (T = O[j], $ = 0, J = P; $ < J.length; $++)
541
- G = J[$], D = B(g, {
541
+ A = J[$], D = B(g, {
542
542
  format: T,
543
- size: G,
543
+ size: A,
544
544
  toFilename: r.imageProcessingFilename
545
- }), r.log(function(M) {
546
- return "imageProcessing: ".concat(g, " -> ").concat(M);
545
+ }), r.log(function(q) {
546
+ return "imageProcessing: ".concat(g, " -> ").concat(q);
547
547
  }, D), R.push(D);
548
548
  return [4, Promise.all(R)];
549
549
  case 2:
@@ -622,7 +622,7 @@ function N(n, r, e) {
622
622
  });
623
623
  });
624
624
  }
625
- function ue(n, r) {
625
+ function oe(n, r) {
626
626
  return U(this, void 0, void 0, function() {
627
627
  return L(this, function(e) {
628
628
  switch (e.label) {
@@ -709,7 +709,7 @@ function I(n, r, e) {
709
709
  });
710
710
  });
711
711
  }
712
- function oe(n, r) {
712
+ function ce(n, r) {
713
713
  return U(this, void 0, void 0, function() {
714
714
  var e;
715
715
  return L(this, function(a) {
@@ -725,7 +725,7 @@ function oe(n, r) {
725
725
  ])];
726
726
  case 1:
727
727
  return a.sent(), e.tiles ? [4, Promise.all(e.tiles.map(function(i) {
728
- return ue(i, r);
728
+ return oe(i, r);
729
729
  }))] : [3, 3];
730
730
  case 2:
731
731
  a.sent(), a.label = 3;
@@ -738,7 +738,7 @@ function oe(n, r) {
738
738
  });
739
739
  });
740
740
  }
741
- function ce(n, r) {
741
+ function le(n, r) {
742
742
  return U(this, void 0, void 0, function() {
743
743
  var e, a, i, t, u;
744
744
  return L(this, function(o) {
@@ -746,7 +746,7 @@ function ce(n, r) {
746
746
  case 0:
747
747
  e = n.observers, a = 0, i = e, o.label = 1;
748
748
  case 1:
749
- return a < i.length ? (t = i[a], u = oe(t, r), r.log("process observer #".concat(t.index, " derived: ").concat(t.derivedIdStr), u), [4, u]) : [3, 4];
749
+ return a < i.length ? (t = i[a], u = ce(t, r), r.log("process observer #".concat(t.index, " derived: ").concat(t.derivedIdStr), u), [4, u]) : [3, 4];
750
750
  case 2:
751
751
  o.sent(), o.label = 3;
752
752
  case 3:
@@ -760,7 +760,7 @@ function ce(n, r) {
760
760
  });
761
761
  });
762
762
  }
763
- function le(n, r) {
763
+ function fe(n, r) {
764
764
  if (r) {
765
765
  var e = Date.now();
766
766
  r.then(function(i) {
@@ -773,16 +773,16 @@ function le(n, r) {
773
773
  console.log(a);
774
774
  }
775
775
  }
776
- function ve(n) {
776
+ function be(n) {
777
777
  return U(this, arguments, void 0, function(r, e) {
778
778
  var a, i, t, u, o, l, s, c, f, m, v, p, b, w, d;
779
779
  return e === void 0 && (e = {}), L(this, function(h) {
780
780
  switch (h.label) {
781
781
  case 0:
782
782
  if (a = r.baseURL, i = "", e.distPath)
783
- i = A(process.cwd(), e.distPath);
783
+ i = M(process.cwd(), e.distPath);
784
784
  else
785
- for (i = A(process.cwd(), (l = r.workCode) !== null && l !== void 0 ? l : "work-".concat(Date.now())); C(i); )
785
+ for (i = M(process.cwd(), (l = r.workCode) !== null && l !== void 0 ? l : "work-".concat(Date.now())); C(i); )
786
786
  /.-(\d+)$/.test(i) ? i = i.replace(/.-(\d+)$/, function(y, k) {
787
787
  return "-" + (Number(k) + 1);
788
788
  }) : i = i + "-1";
@@ -798,17 +798,17 @@ function ve(n) {
798
798
  size: (b = (p = e.textureOptions) === null || p === void 0 ? void 0 : p.size) !== null && b !== void 0 ? b : [],
799
799
  format: (d = (w = e.textureOptions) === null || w === void 0 ? void 0 : w.format) !== null && d !== void 0 ? d : []
800
800
  },
801
- log: e.log ? le : (function() {
801
+ log: e.log ? fe : (function() {
802
802
  return Promise.resolve();
803
803
  }),
804
804
  imageProcessingFilename: e.imageProcessingFilename
805
805
  }, t.log(JSON.stringify(t, null, " ")), [4, H(i, { recursive: !0 })];
806
806
  case 1:
807
- return h.sent(), u = "work.json", o = A(i, u), [4, q(o, JSON.stringify(r.toJSON(), null, " "))];
807
+ return h.sent(), u = "work.json", o = M(i, u), [4, X(o, JSON.stringify(r.toJSON(), null, " "))];
808
808
  case 2:
809
- return h.sent(), [4, ce(r, t)];
809
+ return h.sent(), [4, le(r, t)];
810
810
  case 3:
811
- return h.sent(), [4, se(r, t)];
811
+ return h.sent(), [4, ue(r, t)];
812
812
  case 4:
813
813
  return h.sent(), [
814
814
  2
@@ -819,5 +819,5 @@ function ve(n) {
819
819
  });
820
820
  }
821
821
  export {
822
- ve as download
822
+ be as download
823
823
  };