hilo3d 1.15.19 → 1.16.1

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.
package/build/polyfill.js CHANGED
@@ -1,6 +1,6 @@
1
- window.Hilo3d=function(t){var e={};function n(r){if(e[r])return e[r].exports;var o=e[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)n.d(r,o,function(e){return t[e]}.bind(null,o));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=111)}({100:function(t,e,n){"use strict";t.exports=function(t){return Object.keys(t).map((function(e){return t[e]}))}},101:function(t,e,n){"use strict";t.exports="function"==typeof Promise?Promise:n(105)},104:function(t,e,n){"use strict";n.r(e);var r=n(98),o=n.n(r),i=n(99),c=n.n(i),u=n(100),a=n.n(u),s=n(101),f=n.n(s);Object.assign||(Object.assign=o.a),Object.keys||(Object.keys=c.a),Object.values||(Object.values=a.a),"undefined"==typeof Promise&&(window.Promise=f.a),[Int8Array,Uint8Array,Int16Array,Uint16Array,Uint32Array,Float32Array].forEach((function(t){t.prototype.slice||Object.defineProperty(t.prototype,"slice",{value:function(e,n){return new t(Array.prototype.slice.call(this,e,n))}})}))},105:function(t,e,n){"use strict";(function(e,n){var r,o=function(){},i=void 0!==e&&void 0!==e.process&&"function"==typeof e.process.emit,c=void 0===n?setTimeout:n,u=[];function a(){for(var t=0;t<u.length;t++)u[t][0](u[t][1]);u=[],r=!1}function s(t,e){u.push([t,e]),r||(r=!0,c(a,0))}function f(t){var e=t.owner,n=e._state,r=e._data,o=t[n],i=t.then;if("function"==typeof o){n="fulfilled";try{r=o(r)}catch(t){h(i,t)}}l(i,r)||("fulfilled"===n&&d(i,r),"rejected"===n&&h(i,r))}function l(t,e){var n;try{if(t===e)throw new TypeError("A promises callback cannot return that same promise.");if(e&&("function"==typeof e||"object"==typeof e)){var r=e.then;if("function"==typeof r)return r.call(e,(function(r){n||(n=!0,e===r?p(t,r):d(t,r))}),(function(e){n||(n=!0,h(t,e))})),!0}}catch(e){return n||h(t,e),!0}return!1}function d(t,e){t!==e&&l(t,e)||p(t,e)}function p(t,e){"pending"===t._state&&(t._state="settled",t._data=e,s(y,t))}function h(t,e){"pending"===t._state&&(t._state="settled",t._data=e,s(v,t))}function m(t){t._then=t._then.forEach(f)}function y(t){t._state="fulfilled",m(t)}function v(t){t._state="rejected",m(t),!t._handled&&i&&e.process.emit("unhandledRejection",t._data,t)}function b(t){e.process.emit("rejectionHandled",t)}function g(t){if("function"!=typeof t)throw new TypeError("Promise resolver "+t+" is not a function");if(this instanceof g==!1)throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.");this._then=[],function(t,e){function n(t){h(e,t)}try{t((function(t){d(e,t)}),n)}catch(t){n(t)}}(t,this)}g.prototype={constructor:g,_state:"pending",_then:null,_data:void 0,_handled:!1,then:function(t,e){var n={owner:this,then:new this.constructor(o),fulfilled:t,rejected:e};return!e&&!t||this._handled||(this._handled=!0,"rejected"===this._state&&i&&s(b,this)),"fulfilled"===this._state||"rejected"===this._state?s(f,n):this._then.push(n),n.then},catch:function(t){return this.then(null,t)}},g.all=function(t){if(!Array.isArray(t))throw new TypeError("You must pass an array to Promise.all().");return new g((function(e,n){var r=[],o=0;function i(t){return o++,function(n){r[t]=n,--o||e(r)}}for(var c,u=0;u<t.length;u++)(c=t[u])&&"function"==typeof c.then?c.then(i(u),n):r[u]=c;o||e(r)}))},g.race=function(t){if(!Array.isArray(t))throw new TypeError("You must pass an array to Promise.race().");return new g((function(e,n){for(var r,o=0;o<t.length;o++)(r=t[o])&&"function"==typeof r.then?r.then(e,n):e(r)}))},g.resolve=function(t){return t&&"object"==typeof t&&t.constructor===g?t:new g((function(e){e(t)}))},g.reject=function(t){return new g((function(e,n){n(t)}))},t.exports=g}).call(this,n(36),n(106).setImmediate)},106:function(t,e,n){(function(t){var r=void 0!==t&&t||"undefined"!=typeof self&&self||window,o=Function.prototype.apply;function i(t,e){this._id=t,this._clearFn=e}e.setTimeout=function(){return new i(o.call(setTimeout,r,arguments),clearTimeout)},e.setInterval=function(){return new i(o.call(setInterval,r,arguments),clearInterval)},e.clearTimeout=e.clearInterval=function(t){t&&t.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(r,this._id)},e.enroll=function(t,e){clearTimeout(t._idleTimeoutId),t._idleTimeout=e},e.unenroll=function(t){clearTimeout(t._idleTimeoutId),t._idleTimeout=-1},e._unrefActive=e.active=function(t){clearTimeout(t._idleTimeoutId);var e=t._idleTimeout;e>=0&&(t._idleTimeoutId=setTimeout((function(){t._onTimeout&&t._onTimeout()}),e))},n(107),e.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==t&&t.setImmediate||this&&this.setImmediate,e.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==t&&t.clearImmediate||this&&this.clearImmediate}).call(this,n(36))},107:function(t,e,n){(function(t,e){!function(t,n){"use strict";if(!t.setImmediate){var r,o,i,c,u,a=1,s={},f=!1,l=t.document,d=Object.getPrototypeOf&&Object.getPrototypeOf(t);d=d&&d.setTimeout?d:t,"[object process]"==={}.toString.call(t.process)?r=function(t){e.nextTick((function(){h(t)}))}:!function(){if(t.postMessage&&!t.importScripts){var e=!0,n=t.onmessage;return t.onmessage=function(){e=!1},t.postMessage("","*"),t.onmessage=n,e}}()?t.MessageChannel?((i=new MessageChannel).port1.onmessage=function(t){h(t.data)},r=function(t){i.port2.postMessage(t)}):l&&"onreadystatechange"in l.createElement("script")?(o=l.documentElement,r=function(t){var e=l.createElement("script");e.onreadystatechange=function(){h(t),e.onreadystatechange=null,o.removeChild(e),e=null},o.appendChild(e)}):r=function(t){setTimeout(h,0,t)}:(c="setImmediate$"+Math.random()+"$",u=function(e){e.source===t&&"string"==typeof e.data&&0===e.data.indexOf(c)&&h(+e.data.slice(c.length))},t.addEventListener?t.addEventListener("message",u,!1):t.attachEvent("onmessage",u),r=function(e){t.postMessage(c+e,"*")}),d.setImmediate=function(t){"function"!=typeof t&&(t=new Function(""+t));for(var e=new Array(arguments.length-1),n=0;n<e.length;n++)e[n]=arguments[n+1];var o={callback:t,args:e};return s[a]=o,r(a),a++},d.clearImmediate=p}function p(t){delete s[t]}function h(t){if(f)setTimeout(h,0,t);else{var e=s[t];if(e){f=!0;try{!function(t){var e=t.callback,n=t.args;switch(n.length){case 0:e();break;case 1:e(n[0]);break;case 2:e(n[0],n[1]);break;case 3:e(n[0],n[1],n[2]);break;default:e.apply(void 0,n)}}(e)}finally{p(t),f=!1}}}}}("undefined"==typeof self?void 0===t?this:t:self)}).call(this,n(36),n(108))},108:function(t,e){var n,r,o=t.exports={};function i(){throw new Error("setTimeout has not been defined")}function c(){throw new Error("clearTimeout has not been defined")}function u(t){if(n===setTimeout)return setTimeout(t,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(t){n=i}try{r="function"==typeof clearTimeout?clearTimeout:c}catch(t){r=c}}();var a,s=[],f=!1,l=-1;function d(){f&&a&&(f=!1,a.length?s=a.concat(s):l=-1,s.length&&p())}function p(){if(!f){var t=u(d);f=!0;for(var e=s.length;e;){for(a=s,s=[];++l<e;)a&&a[l].run();l=-1,e=s.length}a=null,f=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===c||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(t)}}function h(t,e){this.fun=t,this.array=e}function m(){}o.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];s.push(new h(t,e)),1!==s.length||f||u(p)},h.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=m,o.addListener=m,o.once=m,o.off=m,o.removeListener=m,o.removeAllListeners=m,o.emit=m,o.prependListener=m,o.prependOnceListener=m,o.listeners=function(t){return[]},o.binding=function(t){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(t){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},111:function(t,e,n){t.exports=n(104)},36:function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(t){"object"==typeof window&&(n=window)}t.exports=n},98:function(t,e,n){"use strict";
1
+ window.Hilo3d=function(t){var e={};function n(r){if(e[r])return e[r].exports;var o=e[r]={i:r,l:!1,exports:{}};return t[r].call(o.exports,o,o.exports,n),o.l=!0,o.exports}return n.m=t,n.c=e,n.d=function(t,e,r){n.o(t,e)||Object.defineProperty(t,e,{enumerable:!0,get:r})},n.r=function(t){"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(t,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(t,"__esModule",{value:!0})},n.t=function(t,e){if(1&e&&(t=n(t)),8&e)return t;if(4&e&&"object"==typeof t&&t&&t.__esModule)return t;var r=Object.create(null);if(n.r(r),Object.defineProperty(r,"default",{enumerable:!0,value:t}),2&e&&"string"!=typeof t)for(var o in t)n.d(r,o,function(e){return t[e]}.bind(null,o));return r},n.n=function(t){var e=t&&t.__esModule?function(){return t.default}:function(){return t};return n.d(e,"a",e),e},n.o=function(t,e){return Object.prototype.hasOwnProperty.call(t,e)},n.p="",n(n.s=107)}({100:function(t,e,n){"use strict";n.r(e);var r=n(95),o=n.n(r),i=n(96),c=n.n(i),u=n(97),a=n.n(u),s=n(98),f=n.n(s);Object.assign||(Object.assign=o.a),Object.keys||(Object.keys=c.a),Object.values||(Object.values=a.a),"undefined"==typeof Promise&&(window.Promise=f.a),[Int8Array,Uint8Array,Int16Array,Uint16Array,Uint32Array,Float32Array].forEach((function(t){t.prototype.slice||Object.defineProperty(t.prototype,"slice",{value:function(e,n){return new t(Array.prototype.slice.call(this,e,n))}})}))},101:function(t,e,n){"use strict";(function(e,n){var r,o=function(){},i=void 0!==e&&void 0!==e.process&&"function"==typeof e.process.emit,c=void 0===n?setTimeout:n,u=[];function a(){for(var t=0;t<u.length;t++)u[t][0](u[t][1]);u=[],r=!1}function s(t,e){u.push([t,e]),r||(r=!0,c(a,0))}function f(t){var e=t.owner,n=e._state,r=e._data,o=t[n],i=t.then;if("function"==typeof o){n="fulfilled";try{r=o(r)}catch(t){h(i,t)}}l(i,r)||("fulfilled"===n&&d(i,r),"rejected"===n&&h(i,r))}function l(t,e){var n;try{if(t===e)throw new TypeError("A promises callback cannot return that same promise.");if(e&&("function"==typeof e||"object"==typeof e)){var r=e.then;if("function"==typeof r)return r.call(e,(function(r){n||(n=!0,e===r?p(t,r):d(t,r))}),(function(e){n||(n=!0,h(t,e))})),!0}}catch(e){return n||h(t,e),!0}return!1}function d(t,e){t!==e&&l(t,e)||p(t,e)}function p(t,e){"pending"===t._state&&(t._state="settled",t._data=e,s(y,t))}function h(t,e){"pending"===t._state&&(t._state="settled",t._data=e,s(v,t))}function m(t){t._then=t._then.forEach(f)}function y(t){t._state="fulfilled",m(t)}function v(t){t._state="rejected",m(t),!t._handled&&i&&e.process.emit("unhandledRejection",t._data,t)}function b(t){e.process.emit("rejectionHandled",t)}function g(t){if("function"!=typeof t)throw new TypeError("Promise resolver "+t+" is not a function");if(this instanceof g==!1)throw new TypeError("Failed to construct 'Promise': Please use the 'new' operator, this object constructor cannot be called as a function.");this._then=[],function(t,e){function n(t){h(e,t)}try{t((function(t){d(e,t)}),n)}catch(t){n(t)}}(t,this)}g.prototype={constructor:g,_state:"pending",_then:null,_data:void 0,_handled:!1,then:function(t,e){var n={owner:this,then:new this.constructor(o),fulfilled:t,rejected:e};return!e&&!t||this._handled||(this._handled=!0,"rejected"===this._state&&i&&s(b,this)),"fulfilled"===this._state||"rejected"===this._state?s(f,n):this._then.push(n),n.then},catch:function(t){return this.then(null,t)}},g.all=function(t){if(!Array.isArray(t))throw new TypeError("You must pass an array to Promise.all().");return new g((function(e,n){var r=[],o=0;function i(t){return o++,function(n){r[t]=n,--o||e(r)}}for(var c,u=0;u<t.length;u++)(c=t[u])&&"function"==typeof c.then?c.then(i(u),n):r[u]=c;o||e(r)}))},g.race=function(t){if(!Array.isArray(t))throw new TypeError("You must pass an array to Promise.race().");return new g((function(e,n){for(var r,o=0;o<t.length;o++)(r=t[o])&&"function"==typeof r.then?r.then(e,n):e(r)}))},g.resolve=function(t){return t&&"object"==typeof t&&t.constructor===g?t:new g((function(e){e(t)}))},g.reject=function(t){return new g((function(e,n){n(t)}))},t.exports=g}).call(this,n(35),n(102).setImmediate)},102:function(t,e,n){(function(t){var r=void 0!==t&&t||"undefined"!=typeof self&&self||window,o=Function.prototype.apply;function i(t,e){this._id=t,this._clearFn=e}e.setTimeout=function(){return new i(o.call(setTimeout,r,arguments),clearTimeout)},e.setInterval=function(){return new i(o.call(setInterval,r,arguments),clearInterval)},e.clearTimeout=e.clearInterval=function(t){t&&t.close()},i.prototype.unref=i.prototype.ref=function(){},i.prototype.close=function(){this._clearFn.call(r,this._id)},e.enroll=function(t,e){clearTimeout(t._idleTimeoutId),t._idleTimeout=e},e.unenroll=function(t){clearTimeout(t._idleTimeoutId),t._idleTimeout=-1},e._unrefActive=e.active=function(t){clearTimeout(t._idleTimeoutId);var e=t._idleTimeout;e>=0&&(t._idleTimeoutId=setTimeout((function(){t._onTimeout&&t._onTimeout()}),e))},n(103),e.setImmediate="undefined"!=typeof self&&self.setImmediate||void 0!==t&&t.setImmediate||this&&this.setImmediate,e.clearImmediate="undefined"!=typeof self&&self.clearImmediate||void 0!==t&&t.clearImmediate||this&&this.clearImmediate}).call(this,n(35))},103:function(t,e,n){(function(t,e){!function(t,n){"use strict";if(!t.setImmediate){var r,o,i,c,u,a=1,s={},f=!1,l=t.document,d=Object.getPrototypeOf&&Object.getPrototypeOf(t);d=d&&d.setTimeout?d:t,"[object process]"==={}.toString.call(t.process)?r=function(t){e.nextTick((function(){h(t)}))}:!function(){if(t.postMessage&&!t.importScripts){var e=!0,n=t.onmessage;return t.onmessage=function(){e=!1},t.postMessage("","*"),t.onmessage=n,e}}()?t.MessageChannel?((i=new MessageChannel).port1.onmessage=function(t){h(t.data)},r=function(t){i.port2.postMessage(t)}):l&&"onreadystatechange"in l.createElement("script")?(o=l.documentElement,r=function(t){var e=l.createElement("script");e.onreadystatechange=function(){h(t),e.onreadystatechange=null,o.removeChild(e),e=null},o.appendChild(e)}):r=function(t){setTimeout(h,0,t)}:(c="setImmediate$"+Math.random()+"$",u=function(e){e.source===t&&"string"==typeof e.data&&0===e.data.indexOf(c)&&h(+e.data.slice(c.length))},t.addEventListener?t.addEventListener("message",u,!1):t.attachEvent("onmessage",u),r=function(e){t.postMessage(c+e,"*")}),d.setImmediate=function(t){"function"!=typeof t&&(t=new Function(""+t));for(var e=new Array(arguments.length-1),n=0;n<e.length;n++)e[n]=arguments[n+1];var o={callback:t,args:e};return s[a]=o,r(a),a++},d.clearImmediate=p}function p(t){delete s[t]}function h(t){if(f)setTimeout(h,0,t);else{var e=s[t];if(e){f=!0;try{!function(t){var e=t.callback,n=t.args;switch(n.length){case 0:e();break;case 1:e(n[0]);break;case 2:e(n[0],n[1]);break;case 3:e(n[0],n[1],n[2]);break;default:e.apply(void 0,n)}}(e)}finally{p(t),f=!1}}}}}("undefined"==typeof self?void 0===t?this:t:self)}).call(this,n(35),n(104))},104:function(t,e){var n,r,o=t.exports={};function i(){throw new Error("setTimeout has not been defined")}function c(){throw new Error("clearTimeout has not been defined")}function u(t){if(n===setTimeout)return setTimeout(t,0);if((n===i||!n)&&setTimeout)return n=setTimeout,setTimeout(t,0);try{return n(t,0)}catch(e){try{return n.call(null,t,0)}catch(e){return n.call(this,t,0)}}}!function(){try{n="function"==typeof setTimeout?setTimeout:i}catch(t){n=i}try{r="function"==typeof clearTimeout?clearTimeout:c}catch(t){r=c}}();var a,s=[],f=!1,l=-1;function d(){f&&a&&(f=!1,a.length?s=a.concat(s):l=-1,s.length&&p())}function p(){if(!f){var t=u(d);f=!0;for(var e=s.length;e;){for(a=s,s=[];++l<e;)a&&a[l].run();l=-1,e=s.length}a=null,f=!1,function(t){if(r===clearTimeout)return clearTimeout(t);if((r===c||!r)&&clearTimeout)return r=clearTimeout,clearTimeout(t);try{r(t)}catch(e){try{return r.call(null,t)}catch(e){return r.call(this,t)}}}(t)}}function h(t,e){this.fun=t,this.array=e}function m(){}o.nextTick=function(t){var e=new Array(arguments.length-1);if(arguments.length>1)for(var n=1;n<arguments.length;n++)e[n-1]=arguments[n];s.push(new h(t,e)),1!==s.length||f||u(p)},h.prototype.run=function(){this.fun.apply(null,this.array)},o.title="browser",o.browser=!0,o.env={},o.argv=[],o.version="",o.versions={},o.on=m,o.addListener=m,o.once=m,o.off=m,o.removeListener=m,o.removeAllListeners=m,o.emit=m,o.prependListener=m,o.prependOnceListener=m,o.listeners=function(t){return[]},o.binding=function(t){throw new Error("process.binding is not supported")},o.cwd=function(){return"/"},o.chdir=function(t){throw new Error("process.chdir is not supported")},o.umask=function(){return 0}},107:function(t,e,n){t.exports=n(100)},35:function(t,e){var n;n=function(){return this}();try{n=n||new Function("return this")()}catch(t){"object"==typeof window&&(n=window)}t.exports=n},95:function(t,e,n){"use strict";
2
2
  /*
3
3
  object-assign
4
4
  (c) Sindre Sorhus
5
5
  @license MIT
6
- */var r=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;function c(t){if(null==t)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(t)}t.exports=function(){try{if(!Object.assign)return!1;var t=new String("abc");if(t[5]="de","5"===Object.getOwnPropertyNames(t)[0])return!1;for(var e={},n=0;n<10;n++)e["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(e).map((function(t){return e[t]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(t){r[t]=t})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(t){return!1}}()?Object.assign:function(t,e){for(var n,u,a=c(t),s=1;s<arguments.length;s++){for(var f in n=Object(arguments[s]))o.call(n,f)&&(a[f]=n[f]);if(r){u=r(n);for(var l=0;l<u.length;l++)i.call(n,u[l])&&(a[u[l]]=n[u[l]])}}return a}},99:function(t,e,n){"use strict";var r,o,i,c;Object.keys||(Object.keys=(r=Object.prototype.hasOwnProperty,o=!{toString:null}.propertyIsEnumerable("toString"),c=(i=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"]).length,function(t){if("object"!=typeof t&&("function"!=typeof t||null===t))throw new TypeError("Object.keys called on non-object");var e,n,u=[];for(e in t)r.call(t,e)&&u.push(e);if(o)for(n=0;n<c;n++)r.call(t,i[n])&&u.push(i[n]);return u}))}});
6
+ */var r=Object.getOwnPropertySymbols,o=Object.prototype.hasOwnProperty,i=Object.prototype.propertyIsEnumerable;function c(t){if(null==t)throw new TypeError("Object.assign cannot be called with null or undefined");return Object(t)}t.exports=function(){try{if(!Object.assign)return!1;var t=new String("abc");if(t[5]="de","5"===Object.getOwnPropertyNames(t)[0])return!1;for(var e={},n=0;n<10;n++)e["_"+String.fromCharCode(n)]=n;if("0123456789"!==Object.getOwnPropertyNames(e).map((function(t){return e[t]})).join(""))return!1;var r={};return"abcdefghijklmnopqrst".split("").forEach((function(t){r[t]=t})),"abcdefghijklmnopqrst"===Object.keys(Object.assign({},r)).join("")}catch(t){return!1}}()?Object.assign:function(t,e){for(var n,u,a=c(t),s=1;s<arguments.length;s++){for(var f in n=Object(arguments[s]))o.call(n,f)&&(a[f]=n[f]);if(r){u=r(n);for(var l=0;l<u.length;l++)i.call(n,u[l])&&(a[u[l]]=n[u[l]])}}return a}},96:function(t,e,n){"use strict";var r,o,i,c;Object.keys||(Object.keys=(r=Object.prototype.hasOwnProperty,o=!{toString:null}.propertyIsEnumerable("toString"),c=(i=["toString","toLocaleString","valueOf","hasOwnProperty","isPrototypeOf","propertyIsEnumerable","constructor"]).length,function(t){if("object"!=typeof t&&("function"!=typeof t||null===t))throw new TypeError("Object.keys called on non-object");var e,n,u=[];for(e in t)r.call(t,e)&&u.push(e);if(o)for(n=0;n<c;n++)r.call(t,i[n])&&u.push(i[n]);return u}))},97:function(t,e,n){"use strict";t.exports=function(t){return Object.keys(t).map((function(e){return t[e]}))}},98:function(t,e,n){"use strict";t.exports="function"==typeof Promise?Promise:n(101)}});
Binary file
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "hilo3d",
3
- "version": "1.15.19",
3
+ "version": "1.16.1",
4
4
  "description": "Hilo3d, a WebGL 3d engine.",
5
5
  "main": "build/Hilo3d.js",
6
6
  "types": "types/index.d.ts",
@@ -73,7 +73,6 @@
73
73
  "amc": "^1.0.6",
74
74
  "gl-matrix": "^2.4.0",
75
75
  "glsl-transpose": "^1.0.0",
76
- "hilojs": "^2.0.0",
77
76
  "object-assign": "^4.1.1",
78
77
  "object-values": "^2.0.0",
79
78
  "object.keys": "^0.1.0",
package/types/index.d.ts CHANGED
@@ -617,6 +617,13 @@ interface TweenEaseObject {
617
617
  EaseInOut: (...params: any[]) => any;
618
618
  }
619
619
 
620
+ /**
621
+ * @property EaseNone
622
+ */
623
+ interface TweenEaseNoneObject {
624
+ EaseNone: (...params: any[]) => any;
625
+ }
626
+
620
627
  /**
621
628
  * @param attribute
622
629
  * @param index
@@ -795,6 +802,8 @@ namespace semantic {
795
802
  var CAMERATYPE: semanticObject;
796
803
  var COLOR_0: semanticObject;
797
804
  var SKININDICES: semanticObject;
805
+ var JOINT: semanticObject;
806
+ var WEIGHT: semanticObject;
798
807
  var SKINWEIGHTS: semanticObject;
799
808
  var RENDERERSIZE: semanticObject;
800
809
  var LOCAL: semanticObject;
@@ -1353,9 +1362,9 @@ namespace util {
1353
1362
  function getRelativePath(basePath: string, path: string): string;
1354
1363
  /**
1355
1364
  * @param array
1356
- * @param isUTF8
1365
+ * @param [isUTF8 = false]
1357
1366
  */
1358
- function convertUint8ArrayToString(array: Uint8Array | number[], isUTF8: boolean): string;
1367
+ function convertUint8ArrayToString(array: Uint8Array | number[], isUTF8?: boolean): string;
1359
1368
  /**
1360
1369
  * @param url
1361
1370
  */
@@ -1442,11 +1451,14 @@ namespace util {
1442
1451
  */
1443
1452
  class Ticker {
1444
1453
  constructor(fps?: number);
1454
+ /**
1455
+ * 定时器的目标帧率
1456
+ */
1457
+ targetFPS: number;
1445
1458
  /**
1446
1459
  * 启动定时器。
1447
- * @param [userRAF = true] - 是否使用requestAnimationFrame,默认为true。
1448
1460
  */
1449
- start(userRAF?: boolean): void;
1461
+ start(): void;
1450
1462
  /**
1451
1463
  * 停止定时器。
1452
1464
  */
@@ -1763,6 +1775,9 @@ class Texture {
1763
1775
  clone(): Texture;
1764
1776
  }
1765
1777
 
1778
+ interface LazyTexture extends EventMixin {
1779
+ }
1780
+
1766
1781
  /**
1767
1782
  * 懒加载纹理
1768
1783
  * @example
@@ -1779,7 +1794,7 @@ class Texture {
1779
1794
  * @param [params.src] - 图片地址
1780
1795
  * @param params.[value:string] - 其它属性
1781
1796
  */
1782
- class LazyTexture extends Texture {
1797
+ class LazyTexture extends Texture implements EventMixin {
1783
1798
  constructor(params?: {
1784
1799
  crossOrigin?: boolean;
1785
1800
  placeHolder?: HTMLImageElement;
@@ -5264,7 +5279,7 @@ class PBRMaterial extends Material {
5264
5279
  /**
5265
5280
  * 光照类型,只能为 PBR 或 NONE
5266
5281
  */
5267
- readonly lightType: string;
5282
+ lightType: 'PBR' | 'NONE';
5268
5283
  /**
5269
5284
  * gammaCorrection
5270
5285
  */
@@ -5403,6 +5418,10 @@ class Material {
5403
5418
  * shader cache id
5404
5419
  */
5405
5420
  shaderCacheId: string;
5421
+ /**
5422
+ * shader name,会在 shader 中加个 SHADER_NAME 宏,不填用 className 代替。
5423
+ */
5424
+ shaderName: string;
5406
5425
  /**
5407
5426
  * 光照类型
5408
5427
  */
@@ -5670,7 +5689,7 @@ class GeometryMaterial extends BasicMaterial {
5670
5689
  /**
5671
5690
  * 光照类型,支持: NONE, PHONG, BLINN-PHONG, LAMBERT
5672
5691
  */
5673
- lightType: string;
5692
+ lightType: 'NONE' | 'PHONG' | 'BLINN-PHONG' | 'LAMBERT';
5674
5693
  }
5675
5694
 
5676
5695
  /**
@@ -5713,7 +5732,7 @@ class BasicMaterial extends Material {
5713
5732
  /**
5714
5733
  * 光照类型,支持: NONE, PHONG, BLINN-PHONG, LAMBERT
5715
5734
  */
5716
- lightType: string;
5735
+ lightType: 'NONE' | 'PHONG' | 'BLINN-PHONG' | 'LAMBERT';
5717
5736
  /**
5718
5737
  * 漫反射贴图,或颜色
5719
5738
  */
@@ -7268,19 +7287,24 @@ class Tween {
7268
7287
  * 更新所有Tween实例。
7269
7288
  * @returns Tween
7270
7289
  */
7271
- static tick(): any;
7290
+ static tick(): Tween;
7272
7291
  /**
7273
- * @returns Tween
7292
+ * 添加Tween实例。
7293
+ * @param tween - 要添加的Tween对象。
7294
+ * @returns Tween。
7274
7295
  */
7275
- static add(): any;
7296
+ static add(tween: Tween): Tween;
7276
7297
  /**
7277
- * @returns Tween
7298
+ * 删除Tween实例。
7299
+ * @param tweenOrTarget - 要删除的Tween对象或target对象或要删除的一组对象。
7300
+ * @returns Tween。
7278
7301
  */
7279
- static remove(): any;
7302
+ static remove(tweenOrTarget: Tween | any | any[]): Tween;
7280
7303
  /**
7281
- * @returns Tween
7304
+ * 删除所有Tween实例。
7305
+ * @returns Tween。
7282
7306
  */
7283
- static removeAll(): any;
7307
+ static removeAll(): Tween;
7284
7308
  /**
7285
7309
  * 创建一个缓动动画,让目标对象从开始属性变换到目标属性。
7286
7310
  * @param target - 缓动目标对象或缓动目标数组。
@@ -7308,30 +7332,63 @@ class Tween {
7308
7332
  static from(target: any | any[], fromProps: any, params: TweenParams): Tween | any[];
7309
7333
  /**
7310
7334
  * Ease类包含为Tween类提供各种缓动功能的函数。
7311
- * @property Back
7312
- * @property Bounce
7313
- * @property Circ
7314
- * @property Cubic
7315
- * @property Elastic
7316
- * @property Expo
7317
- * @property Linear
7318
- * @property Quad
7319
- * @property Quart
7320
- * @property Quint
7321
- * @property Sine
7335
+ * @property Linear - 线性匀速缓动函数
7336
+ * @property Quad - 二次缓动函数
7337
+ * @property Cubic - 三次缓动函数。
7338
+ * @property Quart - 四次缓动函数。
7339
+ * @property Quint - 五次缓动函数。
7340
+ * @property Sine - 正弦缓动函数。
7341
+ * @property Expo - 指数缓动函数。
7342
+ * @property Circ - 圆形缓动函数。
7343
+ * @property Elastic - 弹性缓动函数。
7344
+ * @property Back - 向后缓动函数。
7345
+ * @property Bounce - 弹跳缓动函数。
7322
7346
  */
7323
7347
  static Ease: {
7324
- Back: TweenEaseObject;
7325
- Bounce: TweenEaseObject;
7326
- Circ: TweenEaseObject;
7327
- Cubic: TweenEaseObject;
7328
- Elastic: TweenEaseObject;
7329
- Expo: TweenEaseObject;
7330
- Linear: TweenEaseObject;
7348
+ /**
7349
+ * 线性匀速缓动函数
7350
+ */
7351
+ Linear: TweenEaseNoneObject;
7352
+ /**
7353
+ * 二次缓动函数
7354
+ */
7331
7355
  Quad: TweenEaseObject;
7356
+ /**
7357
+ * 三次缓动函数。
7358
+ */
7359
+ Cubic: TweenEaseObject;
7360
+ /**
7361
+ * 四次缓动函数。
7362
+ */
7332
7363
  Quart: TweenEaseObject;
7364
+ /**
7365
+ * 五次缓动函数。
7366
+ */
7333
7367
  Quint: TweenEaseObject;
7368
+ /**
7369
+ * 正弦缓动函数。
7370
+ */
7334
7371
  Sine: TweenEaseObject;
7372
+ /**
7373
+ * 指数缓动函数。
7374
+ */
7375
+ Expo: TweenEaseObject;
7376
+ /**
7377
+ * 圆形缓动函数。
7378
+ */
7379
+ Circ: TweenEaseObject;
7380
+ /**
7381
+ * 弹性缓动函数。
7382
+ */
7383
+ Elastic: TweenEaseObject;
7384
+ /**
7385
+ * 向后缓动函数。
7386
+ */
7387
+ Back: TweenEaseObject;
7388
+ /**
7389
+ * 弹跳缓动函数。
7390
+ */
7391
+ Bounce: TweenEaseObject;
7335
7392
  };
7336
7393
  /**
7337
7394
  * 缓动目标。只读属性。
@@ -7603,7 +7660,7 @@ class Skeleton {
7603
7660
  */
7604
7661
  id: string;
7605
7662
  jointNodeList: Node[];
7606
- jointNames: String[];
7663
+ jointNames: string[];
7607
7664
  inverseBindMatrices: Matrix4[];
7608
7665
  /**
7609
7666
  * 关节数量