@pixi/prepare
Advanced tools
Comparing version 5.2.1 to 5.2.2
/*! | ||
* @pixi/prepare - v5.2.1 | ||
* Compiled Tue, 28 Jan 2020 23:33:11 UTC | ||
* @pixi/prepare - v5.2.2 | ||
* Compiled Tue, 21 Apr 2020 03:53:51 UTC | ||
* | ||
@@ -664,3 +664,3 @@ * @pixi/prepare is licensed under the MIT License. | ||
{ | ||
renderer.geometry.bind(geometry, item._resolveDirectShader()); | ||
renderer.geometry.bind(geometry, item._resolveDirectShader(renderer)); | ||
} | ||
@@ -667,0 +667,0 @@ |
/*! | ||
* @pixi/prepare - v5.2.1 | ||
* Compiled Tue, 28 Jan 2020 23:33:11 UTC | ||
* @pixi/prepare - v5.2.2 | ||
* Compiled Tue, 21 Apr 2020 03:53:51 UTC | ||
* | ||
@@ -8,3 +8,3 @@ * @pixi/prepare is licensed under the MIT License. | ||
*/ | ||
this.PIXI=this.PIXI||{};var _pixi_prepare=function(t,e,i,r,s,o,n){"use strict";e.settings.UPLOADS_PER_FRAME=4;var u=function(t){this.maxItemsPerFrame=t,this.itemsLeft=0};u.prototype.beginFrame=function(){this.itemsLeft=this.maxItemsPerFrame},u.prototype.allowedToUpload=function(){return this.itemsLeft-- >0};var a=function(t){var i=this;this.limiter=new u(e.settings.UPLOADS_PER_FRAME),this.renderer=t,this.uploadHookHelper=null,this.queue=[],this.addHooks=[],this.uploadHooks=[],this.completes=[],this.ticking=!1,this.delayedTick=function(){i.queue&&i.prepareItems()},this.registerFindHook(d),this.registerFindHook(k),this.registerFindHook(h),this.registerFindHook(l),this.registerFindHook(p),this.registerUploadHook(c),this.registerUploadHook(f)};function h(t,e){var r=!1;if(t&&t._textures&&t._textures.length)for(var s=0;s<t._textures.length;s++)if(t._textures[s]instanceof i.Texture){var o=t._textures[s].baseTexture;-1===e.indexOf(o)&&(e.push(o),r=!0)}return r}function l(t,e){if(t.baseTexture instanceof i.BaseTexture){var r=t.baseTexture;return-1===e.indexOf(r)&&e.push(r),!0}return!1}function p(t,e){if(t._texture&&t._texture instanceof i.Texture){var r=t._texture.baseTexture;return-1===e.indexOf(r)&&e.push(r),!0}return!1}function c(t,e){return e instanceof n.Text&&(e.updateText(!0),!0)}function f(t,e){if(e instanceof n.TextStyle){var i=e.toFontString();return n.TextMetrics.measureFont(i),!0}return!1}function d(t,e){if(t instanceof n.Text){-1===e.indexOf(t.style)&&e.push(t.style),-1===e.indexOf(t)&&e.push(t);var i=t._texture.baseTexture;return-1===e.indexOf(i)&&e.push(i),!0}return!1}function k(t,e){return t instanceof n.TextStyle&&(-1===e.indexOf(t)&&e.push(t),!0)}a.prototype.upload=function(t,e){"function"==typeof t&&(e=t,t=null),t&&this.add(t),this.queue.length?(e&&this.completes.push(e),this.ticking||(this.ticking=!0,s.Ticker.system.addOnce(this.tick,this,s.UPDATE_PRIORITY.UTILITY))):e&&e()},a.prototype.tick=function(){setTimeout(this.delayedTick,0)},a.prototype.prepareItems=function(){for(this.limiter.beginFrame();this.queue.length&&this.limiter.allowedToUpload();){var t=this.queue[0],e=!1;if(t&&!t._destroyed)for(var i=0,r=this.uploadHooks.length;i<r;i++)if(this.uploadHooks[i](this.uploadHookHelper,t)){this.queue.shift(),e=!0;break}e||this.queue.shift()}if(this.queue.length)s.Ticker.system.addOnce(this.tick,this,s.UPDATE_PRIORITY.UTILITY);else{this.ticking=!1;var o=this.completes.slice(0);this.completes.length=0;for(var n=0,u=o.length;n<u;n++)o[n]()}},a.prototype.registerFindHook=function(t){return t&&this.addHooks.push(t),this},a.prototype.registerUploadHook=function(t){return t&&this.uploadHooks.push(t),this},a.prototype.add=function(t){for(var e=0,i=this.addHooks.length;e<i&&!this.addHooks[e](t,this.queue);e++);if(t instanceof o.Container)for(var r=t.children.length-1;r>=0;r--)this.add(t.children[r]);return this},a.prototype.destroy=function(){this.ticking&&s.Ticker.system.remove(this.tick,this),this.ticking=!1,this.addHooks=null,this.uploadHooks=null,this.renderer=null,this.completes=null,this.queue=null,this.limiter=null,this.uploadHookHelper=null};var x=function(t){function e(e){t.call(this,e),this.uploadHookHelper=this.renderer,this.registerFindHook(T),this.registerUploadHook(g),this.registerUploadHook(m)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e}(a);function g(t,e){return e instanceof i.BaseTexture&&(e._glTextures[t.CONTEXT_UID]||t.texture.bind(e),!0)}function m(t,e){if(!(e instanceof r.Graphics))return!1;var i=e.geometry;e.finishPoly(),i.updateBatches();for(var s=i.batches,o=0;o<s.length;o++){var n=s[o].style.texture;n&&g(t,n.baseTexture)}return i.batchable||t.geometry.bind(i,e._resolveDirectShader()),!0}function T(t,e){return t instanceof r.Graphics&&(e.push(t),!0)}var I=function(t){this.maxMilliseconds=t,this.frameStart=0};return I.prototype.beginFrame=function(){this.frameStart=Date.now()},I.prototype.allowedToUpload=function(){return Date.now()-this.frameStart<this.maxMilliseconds},t.BasePrepare=a,t.CountLimiter=u,t.Prepare=x,t.TimeLimiter=I,t}({},PIXI,PIXI,PIXI,PIXI,PIXI,PIXI);Object.assign(this.PIXI,_pixi_prepare); | ||
this.PIXI=this.PIXI||{};var _pixi_prepare=function(t,e,i,r,s,o,n){"use strict";e.settings.UPLOADS_PER_FRAME=4;var u=function(t){this.maxItemsPerFrame=t,this.itemsLeft=0};u.prototype.beginFrame=function(){this.itemsLeft=this.maxItemsPerFrame},u.prototype.allowedToUpload=function(){return this.itemsLeft-- >0};var a=function(t){var i=this;this.limiter=new u(e.settings.UPLOADS_PER_FRAME),this.renderer=t,this.uploadHookHelper=null,this.queue=[],this.addHooks=[],this.uploadHooks=[],this.completes=[],this.ticking=!1,this.delayedTick=function(){i.queue&&i.prepareItems()},this.registerFindHook(d),this.registerFindHook(k),this.registerFindHook(h),this.registerFindHook(l),this.registerFindHook(p),this.registerUploadHook(c),this.registerUploadHook(f)};function h(t,e){var r=!1;if(t&&t._textures&&t._textures.length)for(var s=0;s<t._textures.length;s++)if(t._textures[s]instanceof i.Texture){var o=t._textures[s].baseTexture;-1===e.indexOf(o)&&(e.push(o),r=!0)}return r}function l(t,e){if(t.baseTexture instanceof i.BaseTexture){var r=t.baseTexture;return-1===e.indexOf(r)&&e.push(r),!0}return!1}function p(t,e){if(t._texture&&t._texture instanceof i.Texture){var r=t._texture.baseTexture;return-1===e.indexOf(r)&&e.push(r),!0}return!1}function c(t,e){return e instanceof n.Text&&(e.updateText(!0),!0)}function f(t,e){if(e instanceof n.TextStyle){var i=e.toFontString();return n.TextMetrics.measureFont(i),!0}return!1}function d(t,e){if(t instanceof n.Text){-1===e.indexOf(t.style)&&e.push(t.style),-1===e.indexOf(t)&&e.push(t);var i=t._texture.baseTexture;return-1===e.indexOf(i)&&e.push(i),!0}return!1}function k(t,e){return t instanceof n.TextStyle&&(-1===e.indexOf(t)&&e.push(t),!0)}a.prototype.upload=function(t,e){"function"==typeof t&&(e=t,t=null),t&&this.add(t),this.queue.length?(e&&this.completes.push(e),this.ticking||(this.ticking=!0,s.Ticker.system.addOnce(this.tick,this,s.UPDATE_PRIORITY.UTILITY))):e&&e()},a.prototype.tick=function(){setTimeout(this.delayedTick,0)},a.prototype.prepareItems=function(){for(this.limiter.beginFrame();this.queue.length&&this.limiter.allowedToUpload();){var t=this.queue[0],e=!1;if(t&&!t._destroyed)for(var i=0,r=this.uploadHooks.length;i<r;i++)if(this.uploadHooks[i](this.uploadHookHelper,t)){this.queue.shift(),e=!0;break}e||this.queue.shift()}if(this.queue.length)s.Ticker.system.addOnce(this.tick,this,s.UPDATE_PRIORITY.UTILITY);else{this.ticking=!1;var o=this.completes.slice(0);this.completes.length=0;for(var n=0,u=o.length;n<u;n++)o[n]()}},a.prototype.registerFindHook=function(t){return t&&this.addHooks.push(t),this},a.prototype.registerUploadHook=function(t){return t&&this.uploadHooks.push(t),this},a.prototype.add=function(t){for(var e=0,i=this.addHooks.length;e<i&&!this.addHooks[e](t,this.queue);e++);if(t instanceof o.Container)for(var r=t.children.length-1;r>=0;r--)this.add(t.children[r]);return this},a.prototype.destroy=function(){this.ticking&&s.Ticker.system.remove(this.tick,this),this.ticking=!1,this.addHooks=null,this.uploadHooks=null,this.renderer=null,this.completes=null,this.queue=null,this.limiter=null,this.uploadHookHelper=null};var x=function(t){function e(e){t.call(this,e),this.uploadHookHelper=this.renderer,this.registerFindHook(T),this.registerUploadHook(g),this.registerUploadHook(m)}return t&&(e.__proto__=t),e.prototype=Object.create(t&&t.prototype),e.prototype.constructor=e,e}(a);function g(t,e){return e instanceof i.BaseTexture&&(e._glTextures[t.CONTEXT_UID]||t.texture.bind(e),!0)}function m(t,e){if(!(e instanceof r.Graphics))return!1;var i=e.geometry;e.finishPoly(),i.updateBatches();for(var s=i.batches,o=0;o<s.length;o++){var n=s[o].style.texture;n&&g(t,n.baseTexture)}return i.batchable||t.geometry.bind(i,e._resolveDirectShader(t)),!0}function T(t,e){return t instanceof r.Graphics&&(e.push(t),!0)}var I=function(t){this.maxMilliseconds=t,this.frameStart=0};return I.prototype.beginFrame=function(){this.frameStart=Date.now()},I.prototype.allowedToUpload=function(){return Date.now()-this.frameStart<this.maxMilliseconds},t.BasePrepare=a,t.CountLimiter=u,t.Prepare=x,t.TimeLimiter=I,t}({},PIXI,PIXI,PIXI,PIXI,PIXI,PIXI);Object.assign(this.PIXI,_pixi_prepare); | ||
//# sourceMappingURL=prepare.min.js.map |
/*! | ||
* @pixi/prepare - v5.2.1 | ||
* Compiled Tue, 28 Jan 2020 23:33:11 UTC | ||
* @pixi/prepare - v5.2.2 | ||
* Compiled Tue, 21 Apr 2020 03:53:51 UTC | ||
* | ||
@@ -667,3 +667,3 @@ * @pixi/prepare is licensed under the MIT License. | ||
{ | ||
renderer.geometry.bind(geometry, item._resolveDirectShader()); | ||
renderer.geometry.bind(geometry, item._resolveDirectShader(renderer)); | ||
} | ||
@@ -670,0 +670,0 @@ |
/*! | ||
* @pixi/prepare - v5.2.1 | ||
* Compiled Tue, 28 Jan 2020 23:33:11 UTC | ||
* @pixi/prepare - v5.2.2 | ||
* Compiled Tue, 21 Apr 2020 03:53:51 UTC | ||
* | ||
@@ -671,3 +671,3 @@ * @pixi/prepare is licensed under the MIT License. | ||
{ | ||
renderer.geometry.bind(geometry, item._resolveDirectShader()); | ||
renderer.geometry.bind(geometry, item._resolveDirectShader(renderer)); | ||
} | ||
@@ -674,0 +674,0 @@ |
{ | ||
"name": "@pixi/prepare", | ||
"version": "5.2.1", | ||
"version": "5.2.2", | ||
"main": "lib/prepare.js", | ||
@@ -27,10 +27,10 @@ "module": "lib/prepare.es.js", | ||
"dependencies": { | ||
"@pixi/core": "5.2.1", | ||
"@pixi/display": "5.2.1", | ||
"@pixi/graphics": "5.2.1", | ||
"@pixi/settings": "5.2.1", | ||
"@pixi/text": "5.2.1", | ||
"@pixi/ticker": "5.2.1" | ||
"@pixi/core": "5.2.2", | ||
"@pixi/display": "5.2.2", | ||
"@pixi/graphics": "5.2.2", | ||
"@pixi/settings": "5.2.2", | ||
"@pixi/text": "5.2.2", | ||
"@pixi/ticker": "5.2.2" | ||
}, | ||
"gitHead": "b56b4fca1c169f0e6d2a0472251ba1f7399bb4a3" | ||
"gitHead": "c163c466c20f2286b6e41ab90d68a03aad2051d4" | ||
} |
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
173538
+ Added@pixi/constants@5.2.2(transitive)
+ Added@pixi/core@5.2.2(transitive)
+ Added@pixi/display@5.2.2(transitive)
+ Added@pixi/graphics@5.2.2(transitive)
+ Added@pixi/math@5.2.2(transitive)
+ Added@pixi/runner@5.2.2(transitive)
+ Added@pixi/settings@5.2.2(transitive)
+ Added@pixi/sprite@5.2.2(transitive)
+ Added@pixi/text@5.2.2(transitive)
+ Added@pixi/ticker@5.2.2(transitive)
+ Added@pixi/utils@5.2.2(transitive)
- Removed@pixi/constants@5.2.1(transitive)
- Removed@pixi/core@5.2.1(transitive)
- Removed@pixi/display@5.2.1(transitive)
- Removed@pixi/graphics@5.2.1(transitive)
- Removed@pixi/math@5.2.1(transitive)
- Removed@pixi/runner@5.2.1(transitive)
- Removed@pixi/settings@5.2.1(transitive)
- Removed@pixi/sprite@5.2.1(transitive)
- Removed@pixi/text@5.2.1(transitive)
- Removed@pixi/ticker@5.2.1(transitive)
- Removed@pixi/utils@5.2.1(transitive)
Updated@pixi/core@5.2.2
Updated@pixi/display@5.2.2
Updated@pixi/graphics@5.2.2
Updated@pixi/settings@5.2.2
Updated@pixi/text@5.2.2
Updated@pixi/ticker@5.2.2