All Downloads are FREE. Search and download functionalities are using the official Maven repository.

view.lib.player.js Maven / Gradle / Ivy

!function(t){function e(e){for(var r,i,o=e[0],s=e[1],a=0,l=[];a 

0/0
0/0
 
'},"/8Fb":function(t,e,r){var n=r("XKFU"),i=r("UExd")(!0);n(n.S,"Object",{entries:function(t){return i(t)}})},"/KAi":function(t,e,r){var n=r("XKFU"),i=r("dyZX").isFinite;n(n.S,"Number",{isFinite:function(t){return"number"==typeof t&&i(t)}})},"/SS/":function(t,e,r){var n=r("XKFU");n(n.S,"Object",{setPrototypeOf:r("i5dc").set})},"/Vpf":function(t,e,r){r("0Mri"),t.exports=r("g3g5").RegExp.escape},"/XPn":function(t){t.exports={cgPlayer:{gameInformation:"Informations sur la partie :",outputStream:"Sortie standard :",errorStream:"Sortie d'erreur :",gameParameters:"Paramètres de la partie :",speed:"VITESSE",quality:"QUALITÉ",ToolTipIcons:{options:"Options",replay:"Revoir et partager",fullscreen:"Plein écran",extract:"Extraire"},share:"Partager ce replay"}}},"/e88":function(t,e){t.exports="\t\n\v\f\r   ᠎              \u2028\u2029\ufeff"},"/uf1":function(t,e,r){"use strict";var n=r("XKFU"),i=r("S/j/"),o=r("2OiF"),s=r("hswa");r("nh4g")&&n(n.P+r("xbSm"),"Object",{__defineSetter__:function(t,e){s.f(i(this),t,{set:o(e),enumerable:!0,configurable:!0})}})},"0/R4":function(t,e){t.exports=function(t){return"object"==typeof t?null!==t:"function"==typeof t}},"0E+W":function(t,e,r){r("elZq")("Array")},"0LDn":function(t,e,r){"use strict";r("OGtf")("italics",function(t){return function(){return t(this,"i","","")}})},"0Mri":function(t,e,r){var n=r("XKFU"),i=r("q9eg")(/[\\^$*+?.()|[\]{}]/g,"\\$&");n(n.S,"RegExp",{escape:function(t){return i(t)}})},"0YWM":function(t,e,r){var n=r("EemH"),i=r("OP3Y"),o=r("aagx"),s=r("XKFU"),a=r("0/R4"),u=r("y3w9");s(s.S,"Reflect",{get:function t(e,r){var s,l,h=arguments.length<3?e:arguments[2];return u(e)===h?e[r]:(s=n.f(e,r))?o(s,"value")?s.value:void 0!==s.get?s.get.call(h):void 0:a(l=i(e))?t(l,r,h):void 0}})},"0l/t":function(t,e,r){"use strict";var n=r("XKFU"),i=r("CkkT")(2);n(n.P+n.F*!r("LyE8")([].filter,!0),"Array",{filter:function(t){return i(this,t,arguments[1])}})},"0mN4":function(t,e,r){"use strict";r("OGtf")("fixed",function(t){return function(){return t(this,"tt","","")}})},"0sh+":function(t,e,r){var n=r("quPj"),i=r("vhPU");t.exports=function(t,e,r){if(n(e))throw TypeError("String#"+r+" doesn't accept regex!");return String(i(t))}},"11IZ":function(t,e,r){var n=r("dyZX").parseFloat,i=r("qncB").trim;t.exports=1/n(r("/e88")+"-0")!=-1/0?function(t){var e=i(String(t),3),r=n(e);return 0===r&&"-"==e.charAt(0)?-0:r}:n},"14Xm":function(t,e,r){t.exports=r("u938")},"14ch":function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAA0AAAAMCAYAAAC5tzfZAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMDY3IDc5LjE1Nzc0NywgMjAxNS8wMy8zMC0yMzo0MDo0MiAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTUgKFdpbmRvd3MpIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOjc5M0FFRjVDNUQxNTExRTVBMzEwQkFBQjJGMEUyM0RGIiB4bXBNTTpEb2N1bWVudElEPSJ4bXAuZGlkOjc5M0FFRjVENUQxNTExRTVBMzEwQkFBQjJGMEUyM0RGIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6NzkzQUVGNUE1RDE1MTFFNUEzMTBCQUFCMkYwRTIzREYiIHN0UmVmOmRvY3VtZW50SUQ9InhtcC5kaWQ6NzkzQUVGNUI1RDE1MTFFNUEzMTBCQUFCMkYwRTIzREYiLz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz4P5XNmAAAAe0lEQVR42mL8//8/AxowAOIiIGZkwA56WbAIXgDitUBcg0MjDxMO0zYCcQsQ/8cmiUsTTOM+UjXFArEzlP2fGE0gDflQ9kQMp4JCDw3HAvEZKI5FEvcH4tNAbEOsBmSN1qRogGEmUjWAMYjwI0UDTJMQEK8iVgMIAwQYANRiBg5b26e2AAAAAElFTkSuQmCC"},"1MBn":function(t,e,r){var n=r("DVgA"),i=r("JiEa"),o=r("UqcF");t.exports=function(t){var e=n(t),r=i.f;if(r)for(var s,a=r(t),u=o.f,l=0;a.length>l;)u.call(t,s=a[l++])&&e.push(s);return e}},"1TEc":function(t,e){(function(t,e){function r(t,e,n,i){r._super_.call(this),this.reset(t,e,n,i)}function n(t,e,r,i){n._super_.call(this),this.x=t,this.y=e,this.width=r,this.height=i}function i(t,e){i._super_.call(this),this.x=t,this.y=e}function o(t,e,r){o._super_.call(this),this.x=t,this.y=e,this.radius=r,this.angle=0,this.center={x:this.x,y:this.y}}function s(t,e,r,n,i){s._super_.call(this),r-t>=0?(this.x1=t,this.y1=e,this.x2=r,this.y2=n):(this.x1=r,this.y1=n,this.x2=t,this.y2=e),this.dx=this.x2-this.x1,this.dy=this.y2-this.y1,this.minx=Math.min(this.x1,this.x2),this.miny=Math.min(this.y1,this.y2),this.maxx=Math.max(this.x1,this.x2),this.maxy=Math.max(this.y1,this.y2),this.dot=this.x2*this.y1-this.x1*this.y2,this.xxyy=this.dx*this.dx+this.dy*this.dy,this.gradient=this.getGradient(),this.length=this.getLength(),this.direction=z.Util.initValue(i,">")}function a(){this.vector=new z.Vector2D(0,0),this.random=0,this.crossType="dead",this.alert=!0}function u(t,e){u._super_.call(this,t,e),this.gl=this.element.getContext("experimental-webgl",{antialias:!0,stencil:!1,depth:!1}),this.gl||alert("Sorry your browser do not suppest WebGL!"),this.initVar(),this.setMaxRadius(),this.initShaders(),this.initBuffers(),this.gl.blendEquation(this.gl.FUNC_ADD),this.gl.blendFunc(this.gl.SRC_ALPHA,this.gl.ONE_MINUS_SRC_ALPHA),this.gl.enable(this.gl.BLEND)}function l(t,e,r){l._super_.call(this,t,e),this.context=this.element.getContext("2d"),this.imageData=null,this.rectangle=null,this.rectangle=r,this.createImageData(r)}function h(t,e){h._super_.call(this,t,e),this.stroke=null,this.context=this.element.getContext("2d"),this.bufferCache={}}function c(t,e,r){c._super_.call(this,t,e),this.stroke=r}function f(t,e){f._super_.call(this,t,e),this.stroke=null}function p(t,e,r){this.proton=t,this.element=e,this.stroke=r}function d(t,e,r){this.element=r,this.type=z.Util.initValue(t,"canvas"),this.proton=e,this.renderer=this.getRenderer()}function g(e,r,n){this.mouseTarget=z.Util.initValue(e,t),this.ease=z.Util.initValue(r,.7),this._allowEmitting=!1,this.initEventHandler(),g._super_.call(this,n)}function v(t){this.selfBehaviours=[],v._super_.call(this,t)}function m(t){this.initializes=[],this.particles=[],this.behaviours=[],this.emitTime=0,this.emitTotalTimes=-1,this.damping=.006,this.bindEmitter=!0,this.rate=new z.Rate(1,.1),m._super_.call(this,t),this.id="emitter_"+m.ID++}function y(t,e,r,n){y._super_.call(this,r,n),this.distanceVec=new z.Vector2D,this.centerPoint=z.Util.initValue(t,new z.Vector2D),this.force=z.Util.initValue(this.normalizeValue(e),100),this.name="GravityWell"}function x(t,e,r,n){x._super_.call(this,r,n),this.reset(t,e),this.name="Color"}function b(t,e,r,n,i){b._super_.call(this,n,i),this.reset(t,e,r),this.name="Rotate"}function _(t,e,r,n){_._super_.call(this,r,n),this.reset(t,e),this.name="Scale"}function w(t,e,r,n){w._super_.call(this,r,n),this.reset(t,e),this.name="Alpha"}function T(t,e,r,n){T._super_.call(this,r,n),this.reset(t,e),this.name="CrossZone"}function E(t,e,r,n,i){E._super_.call(this,n,i),this.reset(t,e,r),this.name="Collision"}function S(t,e,r){S._super_.call(this,0,t,e,r),this.name="Gravity"}function A(t,e,r,n,i){A._super_.call(this,t,e,r,n,i),this.force*=-1,this.name="Repulsion"}function C(t,e,r,n,i){C._super_.call(this,n,i),this.reset(t,e,r),this.time=0,this.name="RandomDrift"}function M(t,e,r,n,i){M._super_.call(this,n,i),this.targetPosition=z.Util.initValue(t,new z.Vector2D),this.radius=z.Util.initValue(r,1e3),this.force=z.Util.initValue(this.normalizeValue(e),100),this.radiusSq=this.radius*this.radius,this.attractionForce=new z.Vector2D,this.lengthSq=0,this.name="Attraction"}function R(t,e,r,n){R._super_.call(this,r,n),this.force=this.normalizeForce(new z.Vector2D(t,e)),this.name="Force"}function O(t,e,r){O._super_.call(this),this.image=this.setSpanValue(t),this.w=z.Util.initValue(e,20),this.h=z.Util.initValue(r,this.w)}function P(t,e,r){P._super_.call(this),this.radius=z.Util.setSpanValue(t,e,r)}function D(t,e,r){D._super_.call(this),this.massPan=z.Util.setSpanValue(t,e,r)}function I(t,e,r){I._super_.call(this),this.rPan=z.Util.setSpanValue(t),this.thaPan=z.Util.setSpanValue(e),this.type=z.Util.initValue(r,"vector")}function L(t){L._super_.call(this),this.zone=z.Util.initValue(t,new z.PointZone)}function F(t,e,r){F._super_.call(this),this.lifePan=z.Util.setSpanValue(t,e,r)}function k(){}function B(t,e){this.numPan=z.Util.initValue(t,1),this.timePan=z.Util.initValue(e,1),this.numPan=z.Util.setSpanValue(this.numPan),this.timePan=z.Util.setSpanValue(this.timePan),this.startTime=0,this.nextTime=0,this.init()}function N(t,e){this.id="Behaviour_"+N.id++,this.life=z.Util.initValue(t,1/0),this.easing=z.ease.setEasingByName(e),this.age=0,this.energy=1,this.dead=!1,this.parents=[],this.name="Behaviour"}function U(t,e,r,n){this.x=t,this.y=e,this.width=r,this.height=n,this.bottom=this.y+this.height,this.right=this.x+this.width}function $(t){z.Util.isArray(t)?this.colorArr=t:this.colorArr=[t]}function j(t,e,r){this.isArray=!1,z.Util.isArray(t)?(this.isArray=!0,this.a=t):(this.a=z.Util.initValue(t,1),this.b=z.Util.initValue(e,this.a),this.center=z.Util.initValue(r,!1))}function G(t,e){this.proParticleCount=z.Util.initValue(t,0),this.releaseTime=z.Util.initValue(e,-1),this.poolList=[],this.timeoutID=0;for(var r=0;r0&&(this.timeoutID=setTimeout(this.release,this.releaseTime/1e3))}function W(t){this.id="particle_"+W.ID++,this.reset(!0),z.Util.setPrototypeByObject(this,t)}function V(){this.mats=[],this.size=0;for(var t=0;t<20;t++)this.mats.push(z.Mat3.create([0,0,0,0,0,0,0,0,0]))}function X(){this.initialize()}function z(t,e){this.proParticleCount=z.Util.initValue(t,z.POOL_MAX),this.integrationType=z.Util.initValue(e,z.EULER),this.emitters=[],this.renderers=[],this.time=0,this.oldTime=0,z.pool=new z.ParticlePool(this.proParticleCount),z.integrator=new z.NumericalIntegration(this.integrationType)}z.POOL_MAX=1e3,z.TIME_STEP=60,z.MEASURE=100,z.EULER="euler",z.RK2="runge-kutta2",z.RK4="runge-kutta4",z.VERLET="verlet",z.PARTICLE_CREATED="partilcleCreated",z.PARTICLE_UPDATE="partilcleUpdate",z.PARTICLE_SLEEP="particleSleep",z.PARTICLE_DEAD="partilcleDead",z.PROTON_UPDATE="protonUpdate",z.PROTON_UPDATE_AFTER="protonUpdateAfter",z.EMITTER_ADDED="emitterAdded",z.EMITTER_REMOVED="emitterRemoved",z.amendChangeTabsBug=!0,z.TextureBuffer={},z.TextureCanvasBuffer={},z.prototype={addRender:function(t){t.proton=this,this.renderers.push(t.proton)},addEmitter:function(t){this.emitters.push(t),t.parent=this,this.dispatchEvent(new z.Event({type:z.EMITTER_ADDED,emitter:t}))},removeEmitter:function(t){var e=this.emitters.indexOf(t);this.emitters.splice(e,1),t.parent=null,this.dispatchEvent(new z.Event({type:z.EMITTER_REMOVED,emitter:t}))},update:function(){this.dispatchEvent(new z.Event({type:z.PROTON_UPDATE})),this.oldTime||(this.oldTime=(new Date).getTime());var t=(new Date).getTime();if(this.elapsed=(t-this.oldTime)/1e3,z.amendChangeTabsBug&&this.amendChangeTabsBug(),this.oldTime=t,this.elapsed>0)for(var e=0;e.5&&(this.oldTime=(new Date).getTime(),this.elapsed=0)},getCount:function(){for(var t=0,e=this.emitters.length,r=0;r>e;return t+1},makeTranslation:function(t,e){return[1,0,0,0,1,0,t,e,1]},makeRotation:function(t){var e=Math.cos(t),r=Math.sin(t);return[e,-r,0,r,e,0,0,0,1]},makeScale:function(t,e){return[t,0,0,0,e,0,0,0,1]},matrixMultiply:function(t,e){var r=t[0],n=t[1],i=t[2],o=t[3],s=t[4],a=t[5],u=t[6],l=t[7],h=t[8],c=e[0],f=e[1],p=e[2],d=e[3],g=e[4],v=e[5],m=e[6],y=e[7],x=e[8];return[r*c+n*d+i*m,r*f+n*g+i*y,r*p+n*v+i*x,o*c+s*d+a*m,o*f+s*g+a*y,o*p+s*v+a*x,u*c+l*d+h*m,u*f+l*g+h*y,u*p+l*v+h*x]}};z.WebGLUtil=q;var Z=Z||{createCanvas:function(t,e,r,n){var i=document.createElement("canvas"),o=n||"absolute";return i.id=t,i.width=e,i.height=r,i.style.position=o,i.style.opacity=0,this.transformDom(i,-500,-500,0,0),i},transformDom:function(t,e,r,n,i){t.style.WebkitTransform="translate("+e+"px, "+r+"px) scale("+n+") rotate("+i+"deg)",t.style.MozTransform="translate("+e+"px, "+r+"px) scale("+n+") rotate("+i+"deg)",t.style.OTransform="translate("+e+"px, "+r+"px) scale("+n+") rotate("+i+"deg)",t.style.msTransform="translate("+e+"px, "+r+"px) scale("+n+") rotate("+i+"deg)",t.style.transform="translate("+e+"px, "+r+"px) scale("+n+") rotate("+i+"deg)"}};z.DomUtil=Z,V.prototype.set=function(t,e){0==e?z.Mat3.set(t,this.mats[0]):z.Mat3.multiply(this.mats[e-1],t,this.mats[e]),this.size=Math.max(this.size,e+1)},V.prototype.push=function(t){0==this.size?z.Mat3.set(t,this.mats[0]):z.Mat3.multiply(this.mats[this.size-1],t,this.mats[this.size]),this.size++},V.prototype.pop=function(){this.size>0&&this.size--},V.prototype.top=function(){return this.mats[this.size-1]},z.MStack=V,W.ID=0,W.prototype={getDirection:function(){return Math.atan2(this.v.x,-this.v.y)*(180/Math.PI)},reset:function(t){return this.life=1/0,this.age=0,this.energy=1,this.dead=!1,this.sleep=!1,this.target=null,this.sprite=null,this.parent=null,this.mass=1,this.radius=10,this.alpha=1,this.scale=1,this.rotation=0,this.color=null,this.easing=z.ease.setEasingByName(z.easeLinear),t?(this.transform={},this.p=new z.Vector2D,this.v=new z.Vector2D,this.a=new z.Vector2D,this.old={p:new z.Vector2D,v:new z.Vector2D,a:new z.Vector2D},this.behaviours=[]):(z.Util.destroyObject(this.transform),this.p.set(0,0),this.v.set(0,0),this.a.set(0,0),this.old.p.set(0,0),this.old.v.set(0,0),this.old.a.set(0,0),this.removeAllBehaviours()),this.transform.rgb={r:255,g:255,b:255},this},update:function(t,e){if(!this.sleep){this.age+=t;var r,n=this.behaviours.length;for(r=0;r=this.life)this.destory();else{var i=this.easing(this.age/this.life);this.energy=Math.max(1-i,0)}},addBehaviour:function(t){this.behaviours.push(t),t.hasOwnProperty("parents")&&t.parents.push(this),t.initialize(this)},addBehaviours:function(t){var e,r=t.length;for(e=0;e-1&&((t=this.behaviours.splice(e,1)).parents=null)},removeAllBehaviours:function(){z.Util.destroyArray(this.behaviours)},destory:function(){this.removeAllBehaviours(),this.energy=0,this.dead=!0,this.parent=null}},z.Particle=W,G.prototype={create:function(t){return t?new newTypeParticle:new z.Particle},getCount:function(){return this.poolList.length},add:function(){return this.poolList.push(this.create())},get:function(){return 0===this.poolList.length?this.create():this.poolList.pop().reset()},set:function(t){if(this.poolList.length0?Math.PI/2:this.y<0?-Math.PI/2:void 0},getComponent:function(t){switch(t){case 0:return this.x;case 1:return this.y;default:throw new Error("index is out of range: "+t)}},copy:function(t){return this.x=t.x,this.y=t.y,this},add:function(t,r){return r!==e?this.addVectors(t,r):(this.x+=t.x,this.y+=t.y,this)},addXY:function(t,e){return this.x+=t,this.y+=e,this},addVectors:function(t,e){return this.x=t.x+e.x,this.y=t.y+e.y,this},addScalar:function(t){return this.x+=t,this.y+=t,this},sub:function(t,r){return r!==e?this.subVectors(t,r):(this.x-=t.x,this.y-=t.y,this)},subVectors:function(t,e){return this.x=t.x-e.x,this.y=t.y-e.y,this},multiplyScalar:function(t){return this.x*=t,this.y*=t,this},divideScalar:function(t){return 0!==t?(this.x/=t,this.y/=t):this.set(0,0),this},min:function(t){return this.x>t.x&&(this.x=t.x),this.y>t.y&&(this.y=t.y),this},max:function(t){return this.xe.x&&(this.x=e.x),this.ye.y&&(this.y=e.y),this},negate:function(){return this.multiplyScalar(-1)},dot:function(t){return this.x*t.x+this.y*t.y},lengthSq:function(){return this.x*this.x+this.y*this.y},length:function(){return Math.sqrt(this.x*this.x+this.y*this.y)},normalize:function(){return this.divideScalar(this.length())},distanceTo:function(t){return Math.sqrt(this.distanceToSquared(t))},rotate:function(t){var e=this.x,r=this.y;return this.x=e*Math.cos(t)+r*Math.sin(t),this.y=-e*Math.sin(t)+r*Math.cos(t),this},distanceToSquared:function(t){var e=this.x-t.x,r=this.y-t.y;return e*e+r*r},setLength:function(t){var e=this.length();return 0!==e&&t!==e&&this.multiplyScalar(t/e),this},lerp:function(t,e){return this.x+=(t.x-this.x)*e,this.y+=(t.y-this.y)*e,this},equals:function(t){return t.x===this.x&&t.y===this.y},toArray:function(){return[this.x,this.y]},clear:function(){return this.x=0,this.y=0,this},clone:function(){return new z.Vector2D(this.x,this.y)}},z.Vector2D=Q;var tt=function(t,e){this.r=Math.abs(t)||0,this.tha=e||0};tt.prototype={set:function(t,e){return this.r=t,this.tha=e,this},setR:function(t){return this.r=t,this},setTha:function(t){return this.tha=t,this},copy:function(t){return this.r=t.r,this.tha=t.tha,this},toVector:function(){return new z.Vector2D(this.getX(),this.getY())},getX:function(){return this.r*Math.sin(this.tha)},getY:function(){return-this.r*Math.cos(this.tha)},normalize:function(){return this.r=1,this},equals:function(t){return t.r===this.r&&t.tha===this.tha},toArray:function(){return[this.r,this.tha]},clear:function(){return this.r=0,this.tha=0,this},clone:function(){return new z.Polar2D(this.r,this.tha)}},z.Polar2D=tt,j.prototype={getValue:function(t){return this.isArray?this.a[Math.floor(this.a.length*Math.random())]:this.center?z.MathUtils.randomFloating(this.a,this.b,t):z.MathUtils.randomAToB(this.a,this.b,t)}},z.Span=j,z.getSpan=function(t,e,r){return new z.Span(t,e,r)},z.Util.inherits($,z.Span),$.prototype.getValue=function(){var t=this.colorArr[Math.floor(this.colorArr.length*Math.random())];return"random"==t||"Random"==t?z.MathUtils.randomColor():t},z.ColorSpan=$,U.prototype={contains:function(t,e){return t<=this.right&&t>=this.x&&e<=this.bottom&&e>=this.y}},z.Rectangle=U;var et=et||{create:function(t){var e=new Float32Array(9);return t&&this.set(t,e),e},set:function(t,e){for(var r=0;r<9;r++)e[r]=t[r];return e},multiply:function(t,e,r){var n=t[0],i=t[1],o=t[2],s=t[3],a=t[4],u=t[6],l=t[7],h=e[0],c=e[1],f=e[2],p=e[3],d=e[4],g=e[6],v=e[7];return r[0]=h*n+c*s,r[1]=h*i+c*a,r[2]=o*f,r[3]=p*n+d*s,r[4]=p*i+d*a,r[6]=g*n+v*s+u,r[7]=g*i+v*a+l,r},inverse:function(t,e){var r,n=t[0],i=t[1],o=t[3],s=t[4],a=t[6],u=t[7],l=s,h=-o,c=u*o-s*a;return r=1/(n*l+i*h),e[0]=l*r,e[1]=-i*r,e[3]=h*r,e[4]=n*r,e[6]=c*r,e[7]=(-u*n+i*a)*r,e},multiplyVec2:function(t,e,r){var n=e[0],i=e[1];return r[0]=n*t[0]+i*t[3]+t[6],r[1]=n*t[1]+i*t[4]+t[7],r}};z.Mat3=et,N.id=0,N.prototype={reset:function(t,e){this.life=z.Util.initValue(t,1/0),this.easing=z.Util.initValue(e,z.ease.setEasingByName(z.easeLinear))},normalizeForce:function(t){return t.multiplyScalar(z.MEASURE)},normalizeValue:function(t){return t*z.MEASURE},initialize:function(t){},applyBehaviour:function(t,e,r){if(this.age+=e,this.age>=this.life||this.dead)this.energy=0,this.dead=!0,this.destory();else{var n=this.easing(t.age/t.life);this.energy=Math.max(1-n,0)}},destory:function(){var t,e=this.parents.length;for(t=0;t=this.nextTime?(this.startTime=0,this.nextTime=this.timePan.getValue(),1==this.numPan.b?this.numPan.getValue(!1)>.5?1:0:this.numPan.getValue(!0)):0}},z.Rate=B,k.prototype.reset=function(){},k.prototype.init=function(t,e){e?this.initialize(e):this.initialize(t)},k.prototype.initialize=function(t){},z.Initialize=k;var rt={initialize:function(t,e,r){var n,i=r.length;for(n=0;n4e-6&&this.lengthSq=this.delay&&(t.a.addXY(z.MathUtils.randomAToB(-this.panFoce.x,this.panFoce.x),z.MathUtils.randomAToB(-this.panFoce.y,this.panFoce.y)),this.time=0)},z.RandomDrift=C,z.Util.inherits(A,z.Attraction),A.prototype.reset=function(t,e,r,n,i){A._super_.prototype.reset.call(this,t,e,r,n,i),this.force*=-1},z.Repulsion=A,z.Util.inherits(S,z.Force),S.prototype.reset=function(t,e,r){S._super_.prototype.reset.call(this,0,t,e,r)},z.Gravity=S,z.G=S,z.Util.inherits(E,z.Behaviour),E.prototype.reset=function(t,e,r,n,i){this.emitter=z.Util.initValue(t,null),this.mass=z.Util.initValue(e,!0),this.callback=z.Util.initValue(r,null),this.collisionPool=[],this.delta=new z.Vector2D,n&&E._super_.prototype.reset.call(this,n,i)},E.prototype.applyBehaviour=function(t,e,r){for(var n,i,o,s,a,u=this.emitter?this.emitter.particles.slice(r):this.pool.slice(r),l=u.length,h=0;h-1&&this.initializes.splice(e,1)},m.prototype.removeInitializers=function(){z.Util.destroyArray(this.initializes)},m.prototype.addBehaviour=function(){var t,e=arguments.length;for(t=0;t-1&&this.behaviours.splice(e,1)},m.prototype.removeAllBehaviours=function(){z.Util.destroyArray(this.behaviours)},m.prototype.integrate=function(t){var e=1-this.damping;z.integrator.integrate(this,t,e);var r,n=this.particles.length;for(r=0;r=this.life||this.dead)&&this.destroy(),this.emitting(t),this.integrate(t),r=this.particles.length-1;r>=0;r--)(e=this.particles[r]).dead&&(z.pool.set(e),this.particles.splice(r,1),this.dispatchEvent(new z.Event({type:z.PARTICLE_DEAD,particle:e})))},m.prototype.setupParticle=function(t,e,r){var n=this.initializes,i=this.behaviours;e&&(n=e instanceof Array?e:[e]),r&&(i=r instanceof Array?r:[r]),z.InitializeUtil.initialize(this,t,n),t.addBehaviours(i),t.parent=this,this.particles.push(t)},m.prototype.destroy=function(){this.dead=!0,this.emitTotalTimes=-1,0==this.particles.length&&(this.removeInitializers(),this.removeAllBehaviours(),this.parent&&this.parent.removeEmitter(this))},z.Emitter=m,z.Util.inherits(v,z.Emitter),v.prototype.addSelfBehaviour=function(){var t,e=arguments.length;for(t=0;t-1&&this.selfBehaviours.splice(e,1)},v.prototype.update=function(t){if(v._super_.prototype.update.call(this,t),!this.sleep){var e,r=this.selfBehaviours.length;for(e=0;ethis.element.width||r<0||r>this.elementwidth)){var o=4*((r>>0)*t.width+(e>>0));t.data[o]=i.r,t.data[o+1]=i.g,t.data[o+2]=i.b,t.data[o+3]=255*n.alpha}},l.prototype.onParticleDead=function(t){},z.PixelRender=l,z.Util.inherits(u,z.BaseRender),u.prototype.resize=function(t,e){this.umat[4]=-2,this.umat[7]=1,this.smat[0]=1/t,this.smat[4]=1/e,this.mstack.set(this.umat,0),this.mstack.set(this.smat,1),this.gl.viewport(0,0,t,e),this.element.width=t,this.element.height=e},u.prototype.setMaxRadius=function(t){this.circleCanvasURL=this.createCircle(t)},u.prototype.getVertexShader=function(){return["uniform vec2 viewport;","attribute vec2 aVertexPosition;","attribute vec2 aTextureCoord;","uniform mat3 tMat;","varying vec2 vTextureCoord;","varying float alpha;","void main() {","vec3 v = tMat * vec3(aVertexPosition, 1.0);","gl_Position = vec4(v.x, v.y, 0, 1);","vTextureCoord = aTextureCoord;","alpha = tMat[0][2];","}"].join("\n")},u.prototype.getFragmentShader=function(){return["precision mediump float;","varying vec2 vTextureCoord;","varying float alpha;","uniform sampler2D uSampler;","uniform vec4 color;","uniform bool useTexture;","uniform vec3 uColor;","void main() {","vec4 textureColor = texture2D(uSampler, vTextureCoord);","gl_FragColor = textureColor * vec4(uColor, 1.0);","gl_FragColor.w *= alpha;","}"].join("\n")},u.prototype.initVar=function(){this.mstack=new z.MStack,this.umat=z.Mat3.create([2,0,1,0,-2,0,-1,1,1]),this.smat=z.Mat3.create([.01,0,1,0,.01,0,0,0,1]),this.texturebuffers={}},u.prototype.start=function(){u._super_.prototype.start.call(this),this.resize(this.element.width,this.element.height)},u.prototype.blendEquation=function(t){this.gl.blendEquation(this.gl[t])},u.prototype.blendFunc=function(t,e){this.gl.blendFunc(this.gl[t],this.gl[e])},u.prototype.getShader=function(t,e,r){var n;return n=r?t.createShader(t.FRAGMENT_SHADER):t.createShader(t.VERTEX_SHADER),t.shaderSource(n,e),t.compileShader(n),t.getShaderParameter(n,t.COMPILE_STATUS)?n:(alert(t.getShaderInfoLog(n)),null)},u.prototype.initShaders=function(){var t=this.getShader(this.gl,this.getFragmentShader(),!0),e=this.getShader(this.gl,this.getVertexShader(),!1);this.sprogram=this.gl.createProgram(),this.gl.attachShader(this.sprogram,e),this.gl.attachShader(this.sprogram,t),this.gl.linkProgram(this.sprogram),this.gl.getProgramParameter(this.sprogram,this.gl.LINK_STATUS)||alert("Could not initialise shaders"),this.gl.useProgram(this.sprogram),this.sprogram.vpa=this.gl.getAttribLocation(this.sprogram,"aVertexPosition"),this.sprogram.tca=this.gl.getAttribLocation(this.sprogram,"aTextureCoord"),this.gl.enableVertexAttribArray(this.sprogram.tca),this.gl.enableVertexAttribArray(this.sprogram.vpa),this.sprogram.tMatUniform=this.gl.getUniformLocation(this.sprogram,"tMat"),this.sprogram.samplerUniform=this.gl.getUniformLocation(this.sprogram,"uSampler"),this.sprogram.useTex=this.gl.getUniformLocation(this.sprogram,"useTexture"),this.sprogram.color=this.gl.getUniformLocation(this.sprogram,"uColor"),this.gl.uniform1i(this.sprogram.useTex,1)},u.prototype.initBuffers=function(){this.unitIBuffer=this.gl.createBuffer(),this.gl.bindBuffer(this.gl.ELEMENT_ARRAY_BUFFER,this.unitIBuffer);this.gl.bufferData(this.gl.ELEMENT_ARRAY_BUFFER,new Uint16Array([0,3,1,0,2,3]),this.gl.STATIC_DRAW);for(var t=[],e=0;e<100;e++)t.push(e);for(idx=new Uint16Array(t),this.unitI33=this.gl.createBuffer(),this.gl.bindBuffer(this.gl.ELEMENT_ARRAY_BUFFER,this.unitI33),this.gl.bufferData(this.gl.ELEMENT_ARRAY_BUFFER,idx,this.gl.STATIC_DRAW),t=[],e=0;e<100;e++)t.push(e,e+1,e+2);idx=new Uint16Array(t),this.stripBuffer=this.gl.createBuffer(),this.gl.bindBuffer(this.gl.ELEMENT_ARRAY_BUFFER,this.stripBuffer),this.gl.bufferData(this.gl.ELEMENT_ARRAY_BUFFER,idx,this.gl.STATIC_DRAW)},u.prototype.createCircle=function(t){this.circleCanvasRadius=z.WebGLUtil.nhpot(z.Util.initValue(t,32));var e=z.DomUtil.createCanvas("circle_canvas",2*this.circleCanvasRadius,2*this.circleCanvasRadius),r=e.getContext("2d");return r.beginPath(),r.arc(this.circleCanvasRadius,this.circleCanvasRadius,this.circleCanvasRadius,0,2*Math.PI,!0),r.closePath(),r.fillStyle="#FFF",r.fill(),e.toDataURL()},u.prototype.setImgInCanvas=function(t){var e=t.target.width,r=t.target.height,n=z.WebGLUtil.nhpot(t.target.width),i=z.WebGLUtil.nhpot(t.target.height),o=t.target.width/n,s=t.target.height/i;this.texturebuffers[t.transform.src]||(this.texturebuffers[t.transform.src]=[this.gl.createTexture(),this.gl.createBuffer(),this.gl.createBuffer()]),t.transform.texture=this.texturebuffers[t.transform.src][0],t.transform.vcBuffer=this.texturebuffers[t.transform.src][1],t.transform.tcBuffer=this.texturebuffers[t.transform.src][2],this.gl.bindBuffer(this.gl.ARRAY_BUFFER,t.transform.tcBuffer),this.gl.bufferData(this.gl.ARRAY_BUFFER,new Float32Array([0,0,o,0,0,s,s,s]),this.gl.STATIC_DRAW),this.gl.bindBuffer(this.gl.ARRAY_BUFFER,t.transform.vcBuffer),this.gl.bufferData(this.gl.ARRAY_BUFFER,new Float32Array([0,0,e,0,0,r,e,r]),this.gl.STATIC_DRAW);var a=t.transform.canvas.getContext("2d").getImageData(0,0,n,i);this.gl.bindTexture(this.gl.TEXTURE_2D,t.transform.texture),this.gl.texImage2D(this.gl.TEXTURE_2D,0,this.gl.RGBA,this.gl.RGBA,this.gl.UNSIGNED_BYTE,a),this.gl.texParameteri(this.gl.TEXTURE_2D,this.gl.TEXTURE_MAG_FILTER,this.gl.LINEAR),this.gl.texParameteri(this.gl.TEXTURE_2D,this.gl.TEXTURE_MIN_FILTER,this.gl.LINEAR_MIPMAP_NEAREST),this.gl.generateMipmap(this.gl.TEXTURE_2D),t.transform.textureLoaded=!0,t.transform.textureWidth=e,t.transform.textureHeight=r},u.prototype.setStroke=function(t,e){},u.prototype.onProtonUpdate=function(){},u.prototype.onParticleCreated=function(t){var e=this;t.transform.textureLoaded=!1,t.transform.tmat=z.Mat3.create(),t.transform.tmat[8]=1,t.transform.imat=z.Mat3.create(),t.transform.imat[8]=1,t.target?z.Util.getImage(t.target,t,!0,function(t){e.setImgInCanvas.call(e,t),t.transform.oldScale=1}):z.Util.getImage(this.circleCanvasURL,t,!0,function(t){e.setImgInCanvas.call(e,t),t.transform.oldScale=t.radius/e.circleCanvasRadius})},u.prototype.onParticleUpdate=function(t){t.transform.textureLoaded&&(this.updateMatrix(t),this.gl.uniform3f(this.sprogram.color,t.transform.rgb.r/255,t.transform.rgb.g/255,t.transform.rgb.b/255),this.gl.uniformMatrix3fv(this.sprogram.tMatUniform,!1,this.mstack.top()),this.gl.bindBuffer(this.gl.ARRAY_BUFFER,t.transform.vcBuffer),this.gl.vertexAttribPointer(this.sprogram.vpa,2,this.gl.FLOAT,!1,0,0),this.gl.bindBuffer(this.gl.ARRAY_BUFFER,t.transform.tcBuffer),this.gl.vertexAttribPointer(this.sprogram.tca,2,this.gl.FLOAT,!1,0,0),this.gl.bindTexture(this.gl.TEXTURE_2D,t.transform.texture),this.gl.uniform1i(this.sprogram.samplerUniform,0),this.gl.bindBuffer(this.gl.ELEMENT_ARRAY_BUFFER,this.unitIBuffer),this.gl.drawElements(this.gl.TRIANGLES,6,this.gl.UNSIGNED_SHORT,0),this.mstack.pop())},u.prototype.onParticleDead=function(t){},u.prototype.updateMatrix=function(t){var e=z.WebGLUtil.makeTranslation(-t.transform.textureWidth/2,-t.transform.textureHeight/2),r=z.WebGLUtil.makeTranslation(t.p.x,t.p.y),n=t.rotation*(Math.PI/180),i=z.WebGLUtil.makeRotation(n),o=t.scale*t.transform.oldScale,s=z.WebGLUtil.makeScale(o,o),a=z.WebGLUtil.matrixMultiply(e,s);a=z.WebGLUtil.matrixMultiply(a,i),a=z.WebGLUtil.matrixMultiply(a,r),z.Mat3.inverse(a,t.transform.imat),a[2]=t.alpha,this.mstack.push(a)},z.WebGLRender=u,a.prototype={getPosition:function(){},crossing:function(t){}},z.Zone=a,z.Util.inherits(s,z.Zone),s.prototype.getPosition=function(){return this.random=Math.random(),this.vector.x=this.x1+this.random*this.length*Math.cos(this.gradient),this.vector.y=this.y1+this.random*this.length*Math.sin(this.gradient),this.vector},s.prototype.getDirection=function(t,e){var r=this.dy,n=-this.dx;return(r*t+n*e+this.dot)*(0==n?1:n)>0},s.prototype.getDistance=function(t,e){return(this.dy*t+-this.dx*e+this.dot)/Math.sqrt(this.xxyy)},s.prototype.getSymmetric=function(t){var e=t.getGradient(),r=2*(this.getGradient()-e),n=t.x,i=t.y;return t.x=n*Math.cos(r)-i*Math.sin(r),t.y=n*Math.sin(r)+i*Math.cos(r),t},s.prototype.getGradient=function(){return Math.atan2(this.dy,this.dx)},s.prototype.getRange=function(t,e){Math.abs(this.getGradient())<=Math.PI/4?t.p.xthis.minx&&e():t.p.ythis.miny&&e()},s.prototype.getLength=function(){return Math.sqrt(this.dx*this.dx+this.dy*this.dy)},s.prototype.crossing=function(t){var e=this;"dead"==this.crossType?">"==this.direction||"R"==this.direction||"right"==this.direction||"down"==this.direction?this.getRange(t,function(){e.getDirection(t.p.x,t.p.y)&&(t.dead=!0)}):this.getRange(t,function(){e.getDirection(t.p.x,t.p.y)||(t.dead=!0)}):"bound"==this.crossType?this.getRange(t,function(){e.getDistance(t.p.x,t.p.y)<=t.radius&&(0==e.dx?t.v.x*=-1:0==e.dy?t.v.y*=-1:e.getSymmetric(t.v))}):"cross"==this.crossType&&this.alert&&(alert("Sorry lineZone does not support cross method"),this.alert=!1)},z.LineZone=s,z.Util.inherits(o,z.Zone),o.prototype.getPosition=function(){return this.random=Math.random(),this.angle=2*Math.PI*Math.random(),this.vector.x=this.x+this.random*this.radius*Math.cos(this.angle),this.vector.y=this.y+this.random*this.radius*Math.sin(this.angle),this.vector},o.prototype.setCenter=function(t,e){this.center.x=t,this.center.y=e},o.prototype.crossing=function(t){var e=t.p.distanceTo(this.center);"dead"==this.crossType?e-t.radius>this.radius&&(t.dead=!0):"bound"==this.crossType?e+t.radius>=this.radius&&this.getSymmetric(t):"cross"==this.crossType&&this.alert&&(alert("Sorry CircleZone does not support cross method"),this.alert=!1)},o.prototype.getSymmetric=function(t){var e=t.v.getGradient(),r=2*(this.getGradient(t)-e),n=t.v.x,i=t.v.y;t.v.x=n*Math.cos(r)-i*Math.sin(r),t.v.y=n*Math.sin(r)+i*Math.cos(r)},o.prototype.getGradient=function(t){return-Math.PI/2+Math.atan2(t.p.y-this.center.y,t.p.x-this.center.x)},z.CircleZone=o,z.Util.inherits(i,z.Zone),i.prototype.getPosition=function(){return this.vector.x=this.x,this.vector.y=this.y,this.vector},i.prototype.crossing=function(t){this.alert&&(alert("Sorry PointZone does not support crossing method"),this.alert=!1)},z.PointZone=i,z.Util.inherits(n,z.Zone),n.prototype.getPosition=function(){return this.vector.x=this.x+Math.random()*this.width,this.vector.y=this.y+Math.random()*this.height,this.vector},n.prototype.crossing=function(t){"dead"==this.crossType?(t.p.x+t.radiusthis.x+this.width&&(t.dead=!0),t.p.y+t.radiusthis.y+this.height&&(t.dead=!0)):"bound"==this.crossType?(t.p.x-t.radiusthis.x+this.width&&(t.p.x=this.x+this.width-t.radius,t.v.x*=-1),t.p.y-t.radiusthis.y+this.height&&(t.p.y=this.y+this.height-t.radius,t.v.y*=-1)):"cross"==this.crossType&&(t.p.x+t.radiusthis.x+this.width&&t.v.x>=0&&(t.p.x=this.x-t.radius),t.p.y+t.radiusthis.y+this.height&&t.v.y>=0&&(t.p.y=this.y-t.radius))},z.RectZone=n,z.Util.inherits(r,z.Zone),r.prototype.reset=function(t,e,r,n){this.imageData=t,this.x=z.Util.initValue(e,0),this.y=z.Util.initValue(r,0),this.d=z.Util.initValue(n,2),this.vectors=[],this.setVectors()},r.prototype.setVectors=function(){var t,e,r=this.imageData.width,n=this.imageData.height;for(t=0;t>0)*r+(t>>0));this.imageData.data[i+3]>0&&this.vectors.push({x:t+this.x,y:e+this.y})}return this.vector},r.prototype.getBound=function(t,e){var r=4*((e>>0)*this.imageData.width+(t>>0));return this.imageData.data[r+3]>0},r.prototype.getPosition=function(){return this.vector.copy(this.vectors[Math.floor(Math.random()*this.vectors.length)])},r.prototype.getColor=function(t,e){t-=this.x;var r=4*(((e-=this.y)>>0)*this.imageData.width+(t>>0));return{r:this.imageData.data[r],g:this.imageData.data[r+1],b:this.imageData.data[r+2],a:this.imageData.data[r+3]}},r.prototype.crossing=function(t){"dead"==this.crossType?this.getBound(t.p.x-this.x,t.p.y-this.y)?t.dead=!0:t.dead=!1:"bound"==this.crossType&&(this.getBound(t.p.x-this.x,t.p.y-this.y)||t.v.negate())},z.ImageZone=r;var it=function(){if(t.console&&t.console.log){var e=arguments;if("string"==typeof arguments[0])if(0==arguments[0].indexOf("+")){var r=parseInt(arguments[0]);it.once-1e-8&&t<1e-8?t-t*t/2:Math.log(1+t)}},"201c":function(t,e,r){"use strict";(function(t){if(r("Zvmr"),r("86LW"),r("/Vpf"),t._babelPolyfill)throw new Error("only one instance of babel-polyfill is allowed");t._babelPolyfill=!0;var e="defineProperty";function n(t,r,n){t[r]||Object[e](t,r,{writable:!0,configurable:!0,value:n})}n(String.prototype,"padLeft","".padStart),n(String.prototype,"padRight","".padEnd),"pop,reverse,shift,keys,values,entries,indexOf,every,some,forEach,map,filter,find,findIndex,includes,join,slice,concat,push,splice,unshift,sort,lastIndexOf,reduce,reduceRight,copyWithin,fill".split(",").forEach(function(t){[][t]&&n(Array,t,Function.call.bind([][t]))})}).call(this,r("yLpj"))},"25dN":function(t,e,r){var n=r("XKFU");n(n.S,"Object",{is:r("g6HL")})},"25qn":function(t,e,r){var n=r("XKFU");n(n.P+n.R,"Set",{toJSON:r("RLh9")("Set")})},"29s/":function(t,e,r){var n=r("5T2Y"),i=n["__core-js_shared__"]||(n["__core-js_shared__"]={});t.exports=function(t){return i[t]||(i[t]={})}},"2GTP":function(t,e,r){var n=r("eaoh");t.exports=function(t,e,r){if(n(t),void 0===e)return t;switch(r){case 1:return function(r){return t.call(e,r)};case 2:return function(r,n){return t.call(e,r,n)};case 3:return function(r,n,i){return t.call(e,r,n,i)}}return function(){return t.apply(e,arguments)}}},"2OiF":function(t,e){t.exports=function(t){if("function"!=typeof t)throw TypeError(t+" is not a function!");return t}},"2Spj":function(t,e,r){var n=r("XKFU");n(n.P,"Function",{bind:r("8MEG")})},"2atp":function(t,e,r){var n=r("XKFU"),i=Math.atanh;n(n.S+n.F*!(i&&1/i(-0)<0),"Math",{atanh:function(t){return 0==(t=+t)?t:Math.log((1+t)/(1-t))/2}})},"2faE":function(t,e,r){var n=r("5K7Z"),i=r("eUtF"),o=r("G8Mo"),s=Object.defineProperty;e.f=r("jmDH")?Object.defineProperty:function(t,e,r){if(n(t),e=o(e,!0),n(r),i)try{return s(t,e,r)}catch(t){}if("get"in r||"set"in r)throw TypeError("Accessors not supported!");return"value"in r&&(t[e]=r.value),t}},"3GJH":function(t,e,r){r("lCc8");var n=r("WEpk").Object;t.exports=function(t,e){return n.create(t,e)}},"3Lyj":function(t,e,r){var n=r("KroJ");t.exports=function(t,e,r){for(var i in e)n(t,i,e[i],r);return t}},"3YpW":function(t,e,r){r("KOQb")("Set")},"3xty":function(t,e,r){var n=r("XKFU"),i=r("2OiF"),o=r("y3w9"),s=(r("dyZX").Reflect||{}).apply,a=Function.apply;n(n.S+n.F*!r("eeVq")(function(){s(function(){})}),"Reflect",{apply:function(t,e,r){var n=i(t),u=o(r);return s?s(n,e,u):a.call(n,e,u)}})},"45Tv":function(t,e,r){var n=r("N6cJ"),i=r("y3w9"),o=r("OP3Y"),s=n.has,a=n.get,u=n.key,l=function(t,e,r){if(s(t,e,r))return a(t,e,r);var n=o(e);return null!==n?l(t,n,r):void 0};n.exp({getMetadata:function(t,e){return l(t,i(e),arguments.length<3?void 0:u(arguments[2]))}})},"49D4":function(t,e,r){var n=r("N6cJ"),i=r("y3w9"),o=n.key,s=n.set;n.exp({defineMetadata:function(t,e,r,n){s(t,e,i(r),o(n))}})},"4LiD":function(t,e,r){"use strict";var n=r("dyZX"),i=r("XKFU"),o=r("KroJ"),s=r("3Lyj"),a=r("Z6vF"),u=r("SlkY"),l=r("9gX7"),h=r("0/R4"),c=r("eeVq"),f=r("XMVh"),p=r("fyDq"),d=r("Xbzi");t.exports=function(t,e,r,g,v,m){var y=n[t],x=y,b=v?"set":"add",_=x&&x.prototype,w={},T=function(t){var e=_[t];o(_,t,"delete"==t?function(t){return!(m&&!h(t))&&e.call(this,0===t?0:t)}:"has"==t?function(t){return!(m&&!h(t))&&e.call(this,0===t?0:t)}:"get"==t?function(t){return m&&!h(t)?void 0:e.call(this,0===t?0:t)}:"add"==t?function(t){return e.call(this,0===t?0:t),this}:function(t,r){return e.call(this,0===t?0:t,r),this})};if("function"==typeof x&&(m||_.forEach&&!c(function(){(new x).entries().next()}))){var E=new x,S=E[b](m?{}:-0,1)!=E,A=c(function(){E.has(1)}),C=f(function(t){new x(t)}),M=!m&&c(function(){for(var t=new x,e=5;e--;)t[b](e,e);return!t.has(-0)});C||((x=e(function(e,r){l(e,x,t);var n=d(new y,e,x);return void 0!=r&&u(r,v,n[b],n),n})).prototype=_,_.constructor=x),(A||M)&&(T("delete"),T("has"),v&&T("get")),(M||S)&&T(b),m&&_.clear&&delete _.clear}else x=g.getConstructor(e,t,v,b),s(x.prototype,r),a.NEED=!0;return p(x,t),w[t]=x,i(i.G+i.W+i.F*(x!=y),w),m||g.setStrong(x,t,v),x}},"4R4u":function(t,e){t.exports="constructor,hasOwnProperty,isPrototypeOf,propertyIsEnumerable,toLocaleString,toString,valueOf".split(",")},"4d7F":function(t,e,r){t.exports={default:r("aW7e"),__esModule:!0}},"5K7Z":function(t,e,r){var n=r("93I4");t.exports=function(t){if(!n(t))throw TypeError(t+" is not an object!");return t}},"5Pf0":function(t,e,r){var n=r("S/j/"),i=r("OP3Y");r("Xtr8")("getPrototypeOf",function(){return function(t){return i(n(t))}})},"5T2Y":function(t,e){var r=t.exports="undefined"!=typeof window&&window.Math==Math?window:"undefined"!=typeof self&&self.Math==Math?self:Function("return this")();"number"==typeof __g&&(__g=r)},"5vMV":function(t,e,r){var n=r("B+OT"),i=r("NsO/"),o=r("W070")(!1),s=r("VVlx")("IE_PROTO");t.exports=function(t,e){var r,a=i(t),u=0,l=[];for(r in a)r!=s&&n(a,r)&&l.push(r);for(;e.length>u;)n(a,r=e[u++])&&(~o(l,r)||l.push(r));return l}},"694e":function(t,e,r){var n=r("EemH"),i=r("XKFU"),o=r("y3w9");i(i.S,"Reflect",{getOwnPropertyDescriptor:function(t,e){return n.f(o(t),e)}})},"69bn":function(t,e,r){var n=r("y3w9"),i=r("2OiF"),o=r("K0xU")("species");t.exports=function(t,e){var r,s=n(t).constructor;return void 0===s||void 0==(r=n(s)[o])?e:i(r)}},"6AQ9":function(t,e,r){"use strict";var n=r("XKFU"),i=r("8a7r");n(n.S+n.F*r("eeVq")(function(){function t(){}return!(Array.of.call(t)instanceof t)}),"Array",{of:function(){for(var t=0,e=arguments.length,r=new("function"==typeof this?this:Array)(e);e>t;)i(r,t,arguments[t++]);return r.length=e,r}})},"6FAO":function(t,e,r){(function(e){var r;(function(){ /*! * pixi.js - v4.4.3 * Compiled Thu, 23 Mar 2017 12:34:27 UTC * * pixi.js is licensed under the MIT License. * http://www.opensource.org/licenses/mit-license */ t.exports=function t(e,n,i){function o(a,u){if(!n[a]){if(!e[a]){var l="function"==typeof r&&r;if(!u&&l)return r(a,!0);if(s)return s(a,!0);var h=new Error("Cannot find module '"+a+"'");throw h.code="MODULE_NOT_FOUND",h}var c=n[a]={exports:{}};e[a][0].call(c.exports,function(t){var r=e[a][1][t];return o(r||t)},c,c.exports,t,e,n,i)}return n[a].exports}for(var s="function"==typeof r&&r,a=0;a0)-(t<0)},r.abs=function(t){var e=t>>31;return(t^e)-e},r.min=function(t,e){return e^(t^e)&-(t65535)<<4,e|=r=((t>>>=e)>255)<<3,e|=r=((t>>>=r)>15)<<2,(e|=r=((t>>>=r)>3)<<1)|(t>>>=r)>>1},r.log10=function(t){return t>=1e9?9:t>=1e8?8:t>=1e7?7:t>=1e6?6:t>=1e5?5:t>=1e4?4:t>=1e3?3:t>=100?2:t>=10?1:0},r.popCount=function(t){return 16843009*((t=(858993459&(t-=t>>>1&1431655765))+(t>>>2&858993459))+(t>>>4)&252645135)>>>24},r.countTrailingZeros=n,r.nextPow2=function(t){return t+=0===t,--t,t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,1+(t|=t>>>16)},r.prevPow2=function(t){return t|=t>>>1,t|=t>>>2,t|=t>>>4,t|=t>>>8,(t|=t>>>16)-(t>>>1)},r.parity=function(t){return t^=t>>>16,t^=t>>>8,t^=t>>>4,27030>>>(t&=15)&1};var i=new Array(256);!function(t){for(var e=0;e<256;++e){var r=e,n=e,i=7;for(r>>>=1;r;r>>>=1)n<<=1,n|=1&r,--i;t[e]=n<>>8&255]<<16|i[t>>>16&255]<<8|i[t>>>24&255]},r.interleave2=function(t,e){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t&=65535)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e&=65535)|e<<8))|e<<4))|e<<2))|e<<1))<<1},r.deinterleave2=function(t,e){return(t=65535&((t=16711935&((t=252645135&((t=858993459&((t=t>>>e&1431655765)|t>>>1))|t>>>2))|t>>>4))|t>>>16))<<16>>16},r.interleave3=function(t,e,r){return t=1227133513&((t=3272356035&((t=251719695&((t=4278190335&((t&=1023)|t<<16))|t<<8))|t<<4))|t<<2),(t|=(e=1227133513&((e=3272356035&((e=251719695&((e=4278190335&((e&=1023)|e<<16))|e<<8))|e<<4))|e<<2))<<1)|(r=1227133513&((r=3272356035&((r=251719695&((r=4278190335&((r&=1023)|r<<16))|r<<8))|r<<4))|r<<2))<<2},r.deinterleave3=function(t,e){return(t=1023&((t=4278190335&((t=251719695&((t=3272356035&((t=t>>>e&1227133513)|t>>>2))|t>>>4))|t>>>8))|t>>>16))<<22>>22},r.nextCombination=function(t){var e=t|t-1;return e+1|(~e&-~e)-1>>>n(t)+1}},{}],2:[function(t,e,r){"use strict";function n(t,e,r){r=r||2;var n,o,a,u,l,h,f,p=e&&e.length,d=p?e[0]*r:t.length,g=i(t,0,d,r,!0),v=[];if(!g)return v;if(p&&(g=c(t,e,g,r)),t.length>80*r){n=a=t[0],o=u=t[1];for(var m=r;ma&&(a=l),h>u&&(u=h);f=Math.max(a-n,u-o)}return s(g,v,r,n,o,f),v}function i(t,e,r,n,i){var o,s;if(i===A(t,e,r,n)>0)for(o=e;o=e;o-=n)s=T(o,t[o],t[o+1],s);return s&&x(s,s.next)&&(E(s),s=s.next),s}function o(t,e){if(!t)return t;e||(e=t);var r,n=t;do{if(r=!1,n.steiner||!x(n,n.next)&&0!==y(n.prev,n,n.next))n=n.next;else{if(E(n),(n=e=n.prev)===n.next)return null;r=!0}}while(r||n!==e);return e}function s(t,e,r,n,i,c,f){if(t){!f&&c&&function(t,e,r,n){var i=t;do{null===i.z&&(i.z=d(i.x,i.y,e,r,n)),i.prevZ=i.prev,i.nextZ=i.next,i=i.next}while(i!==t);i.prevZ.nextZ=null,i.prevZ=null,function(t){var e,r,n,i,o,s,a,u,l=1;do{for(r=t,t=null,o=null,s=0;r;){for(s++,n=r,a=0,e=0;e0||u>0&&n;)0===a?(i=n,n=n.nextZ,u--):0!==u&&n?r.z<=n.z?(i=r,r=r.nextZ,a--):(i=n,n=n.nextZ,u--):(i=r,r=r.nextZ,a--),o?o.nextZ=i:t=i,i.prevZ=o,o=i;r=n}o.nextZ=null,l*=2}while(s>1)}(i)}(t,n,i,c);for(var p,g,v=t;t.prev!==t.next;)if(p=t.prev,g=t.next,c?u(t,n,i,c):a(t))e.push(p.i/r),e.push(t.i/r),e.push(g.i/r),E(t),t=g.next,v=g.next;else if((t=g)===v){f?1===f?s(t=l(t,e,r),e,r,n,i,c,2):2===f&&h(t,e,r,n,i,c):s(o(t),e,r,n,i,c,1);break}}}function a(t){var e=t.prev,r=t,n=t.next;if(y(e,r,n)>=0)return!1;for(var i=t.next.next;i!==t.prev;){if(v(e.x,e.y,r.x,r.y,n.x,n.y,i.x,i.y)&&y(i.prev,i,i.next)>=0)return!1;i=i.next}return!0}function u(t,e,r,n){var i=t.prev,o=t,s=t.next;if(y(i,o,s)>=0)return!1;for(var a=i.xo.x?i.x>s.x?i.x:s.x:o.x>s.x?o.x:s.x,h=i.y>o.y?i.y>s.y?i.y:s.y:o.y>s.y?o.y:s.y,c=d(a,u,e,r,n),f=d(l,h,e,r,n),p=t.nextZ;p&&p.z<=f;){if(p!==t.prev&&p!==t.next&&v(i.x,i.y,o.x,o.y,s.x,s.y,p.x,p.y)&&y(p.prev,p,p.next)>=0)return!1;p=p.nextZ}for(p=t.prevZ;p&&p.z>=c;){if(p!==t.prev&&p!==t.next&&v(i.x,i.y,o.x,o.y,s.x,s.y,p.x,p.y)&&y(p.prev,p,p.next)>=0)return!1;p=p.prevZ}return!0}function l(t,e,r){var n=t;do{var i=n.prev,o=n.next.next;!x(i,o)&&b(i,n,n.next,o)&&_(i,o)&&_(o,i)&&(e.push(i.i/r),e.push(n.i/r),e.push(o.i/r),E(n),E(n.next),n=t=o),n=n.next}while(n!==t);return n}function h(t,e,r,n,i,a){var u=t;do{for(var l=u.next.next;l!==u.prev;){if(u.i!==l.i&&m(u,l)){var h=w(u,l);return u=o(u,u.next),h=o(h,h.next),s(u,e,r,n,i,a),void s(h,e,r,n,i,a)}l=l.next}u=u.next}while(u!==t)}function c(t,e,r,n){var s,a,u,l,h,c=[];for(s=0,a=e.length;s=n.next.y){var a=n.x+(o-n.y)*(n.next.x-n.x)/(n.next.y-n.y);if(a<=i&&a>s){if(s=a,a===i){if(o===n.y)return n;if(o===n.next.y)return n.next}r=n.x=n.x&&n.x>=h&&v(or.x)&&_(n,t)&&(r=n,f=u),n=n.next;return r}(t,e)){var r=w(e,t);o(r,r.next)}}function d(t,e,r,n,i){return(t=1431655765&((t=858993459&((t=252645135&((t=16711935&((t=32767*(t-r)/i)|t<<8))|t<<4))|t<<2))|t<<1))|(e=1431655765&((e=858993459&((e=252645135&((e=16711935&((e=32767*(e-n)/i)|e<<8))|e<<4))|e<<2))|e<<1))<<1}function g(t){var e=t,r=t;do{e.x=0&&(t-s)*(n-a)-(r-s)*(e-a)>=0&&(r-s)*(o-a)-(i-s)*(n-a)>=0}function m(t,e){return t.next.i!==e.i&&t.prev.i!==e.i&&!function(t,e){var r=t;do{if(r.i!==t.i&&r.next.i!==t.i&&r.i!==e.i&&r.next.i!==e.i&&b(r,r.next,t,e))return!0;r=r.next}while(r!==t);return!1}(t,e)&&_(t,e)&&_(e,t)&&function(t,e){var r=t,n=!1,i=(t.x+e.x)/2,o=(t.y+e.y)/2;do{r.y>o!=r.next.y>o&&i<(r.next.x-r.x)*(o-r.y)/(r.next.y-r.y)+r.x&&(n=!n),r=r.next}while(r!==t);return n}(t,e)}function y(t,e,r){return(e.y-t.y)*(r.x-e.x)-(e.x-t.x)*(r.y-e.y)}function x(t,e){return t.x===e.x&&t.y===e.y}function b(t,e,r,n){return!!(x(t,e)&&x(r,n)||x(t,n)&&x(r,e))||y(t,e,r)>0!=y(t,e,n)>0&&y(r,n,t)>0!=y(r,n,e)>0}function _(t,e){return y(t.prev,t,t.next)<0?y(t,e,t.next)>=0&&y(t,t.prev,e)>=0:y(t,e,t.prev)<0||y(t,t.next,e)<0}function w(t,e){var r=new S(t.i,t.x,t.y),n=new S(e.i,e.x,e.y),i=t.next,o=e.prev;return t.next=e,e.prev=t,r.next=i,i.prev=r,n.next=r,r.prev=n,o.next=n,n.prev=o,n}function T(t,e,r,n){var i=new S(t,e,r);return n?(i.next=n.next,i.prev=n,n.next.prev=i,n.next=i):(i.prev=i,i.next=i),i}function E(t){t.next.prev=t.prev,t.prev.next=t.next,t.prevZ&&(t.prevZ.nextZ=t.nextZ),t.nextZ&&(t.nextZ.prevZ=t.prevZ)}function S(t,e,r){this.i=t,this.x=e,this.y=r,this.prev=null,this.next=null,this.z=null,this.prevZ=null,this.nextZ=null,this.steiner=!1}function A(t,e,r,n){for(var i=0,o=e,s=r-n;o0&&(n+=t[i-1].length,r.holes.push(n))}return r}},{}],3:[function(t,e,r){"use strict";function n(){}function i(t,e,r){this.fn=t,this.context=e,this.once=r||!1}function o(){this._events=new n,this._eventsCount=0}var s=Object.prototype.hasOwnProperty,a="~";Object.create&&(n.prototype=Object.create(null),(new n).__proto__||(a=!1)),o.prototype.eventNames=function(){var t,e,r=[];if(0===this._eventsCount)return r;for(e in t=this._events)s.call(t,e)&&r.push(a?e.slice(1):e);return Object.getOwnPropertySymbols?r.concat(Object.getOwnPropertySymbols(t)):r},o.prototype.listeners=function(t,e){var r=a?a+t:t,n=this._events[r];if(e)return!!n;if(!n)return[];if(n.fn)return[n.fn];for(var i=0,o=n.length,s=new Array(o);i=t.byteLength?n.bufferSubData(this.type,e,t):n.bufferData(this.type,t,this.drawType),this.data=t},i.prototype.bind=function(){var t=this.gl;t.bindBuffer(this.type,this.buffer)},i.createVertexBuffer=function(t,e,r){return new i(t,t.ARRAY_BUFFER,e,r)},i.createIndexBuffer=function(t,e,r){return new i(t,t.ELEMENT_ARRAY_BUFFER,e,r)},i.create=function(t,e,r,n){return new i(t,e,r,n)},i.prototype.destroy=function(){this.gl.deleteBuffer(this.buffer)},e.exports=i},{}],7:[function(t,e,r){var n=t("./GLTexture"),i=function(t,e,r){this.gl=t,this.framebuffer=t.createFramebuffer(),this.stencil=null,this.texture=null,this.width=e||100,this.height=r||100};i.prototype.enableTexture=function(t){var e=this.gl;this.texture=t||new n(e),this.texture.bind(),this.bind(),e.framebufferTexture2D(e.FRAMEBUFFER,e.COLOR_ATTACHMENT0,e.TEXTURE_2D,this.texture.texture,0)},i.prototype.enableStencil=function(){if(!this.stencil){var t=this.gl;this.stencil=t.createRenderbuffer(),t.bindRenderbuffer(t.RENDERBUFFER,this.stencil),t.framebufferRenderbuffer(t.FRAMEBUFFER,t.DEPTH_STENCIL_ATTACHMENT,t.RENDERBUFFER,this.stencil),t.renderbufferStorage(t.RENDERBUFFER,t.DEPTH_STENCIL,this.width,this.height)}},i.prototype.clear=function(t,e,r,n){this.bind();var i=this.gl;i.clearColor(t,e,r,n),i.clear(i.COLOR_BUFFER_BIT)},i.prototype.bind=function(){var t=this.gl;t.bindFramebuffer(t.FRAMEBUFFER,this.framebuffer)},i.prototype.unbind=function(){var t=this.gl;t.bindFramebuffer(t.FRAMEBUFFER,null)},i.prototype.resize=function(t,e){var r=this.gl;this.width=t,this.height=e,this.texture&&this.texture.uploadData(null,t,e),this.stencil&&(r.bindRenderbuffer(r.RENDERBUFFER,this.stencil),r.renderbufferStorage(r.RENDERBUFFER,r.DEPTH_STENCIL,t,e))},i.prototype.destroy=function(){var t=this.gl;this.texture&&this.texture.destroy(),t.deleteFramebuffer(this.framebuffer),this.gl=null,this.stencil=null,this.texture=null},i.createRGBA=function(t,e,r,o){var s=n.fromData(t,null,e,r);s.enableNearestScaling(),s.enableWrapClamp();var a=new i(t,e,r);return a.enableTexture(s),a.unbind(),a},i.createFloat32=function(t,e,r,o){var s=new n.fromData(t,o,e,r);s.enableNearestScaling(),s.enableWrapClamp();var a=new i(t,e,r);return a.enableTexture(s),a.unbind(),a},e.exports=i},{"./GLTexture":9}],8:[function(t,e,r){var n=t("./shader/compileProgram"),i=t("./shader/extractAttributes"),o=t("./shader/extractUniforms"),s=t("./shader/generateUniformAccessObject"),a=function(t,e,r){this.gl=t,this.program=n(t,e,r),this.attributes=i(t,this.program);var a=o(t,this.program);this.uniforms=s(t,a)};a.prototype.bind=function(){this.gl.useProgram(this.program)},a.prototype.destroy=function(){},e.exports=a},{"./shader/compileProgram":14,"./shader/extractAttributes":16,"./shader/extractUniforms":17,"./shader/generateUniformAccessObject":18}],9:[function(t,e,r){var n=function(t,e,r,n,i){this.gl=t,this.texture=t.createTexture(),this.mipmap=!1,this.premultiplyAlpha=!1,this.width=e||-1,this.height=r||-1,this.format=n||t.RGBA,this.type=i||t.UNSIGNED_BYTE};n.prototype.upload=function(t){this.bind();var e=this.gl;e.pixelStorei(e.UNPACK_PREMULTIPLY_ALPHA_WEBGL,this.premultiplyAlpha);var r=t.videoWidth||t.width,n=t.videoHeight||t.height;n!==this.height||r!==this.width?e.texImage2D(e.TEXTURE_2D,0,this.format,this.format,this.type,t):e.texSubImage2D(e.TEXTURE_2D,0,0,0,this.format,this.type,t),this.width=r,this.height=n};var i=!1;n.prototype.uploadData=function(t,e,r){this.bind();var n=this.gl;if(t instanceof Float32Array){if(!i){var o=n.getExtension("OES_texture_float");if(!o)throw new Error("floating point textures not available");i=!0}this.type=n.FLOAT}else this.type=n.UNSIGNED_BYTE;n.pixelStorei(n.UNPACK_PREMULTIPLY_ALPHA_WEBGL,this.premultiplyAlpha),e!==this.width||r!==this.height?n.texImage2D(n.TEXTURE_2D,0,this.format,e,r,0,this.format,this.type,t||null):n.texSubImage2D(n.TEXTURE_2D,0,0,0,e,r,this.format,this.type,t||null),this.width=e,this.height=r},n.prototype.bind=function(t){var e=this.gl;void 0!==t&&e.activeTexture(e.TEXTURE0+t),e.bindTexture(e.TEXTURE_2D,this.texture)},n.prototype.unbind=function(){var t=this.gl;t.bindTexture(t.TEXTURE_2D,null)},n.prototype.minFilter=function(t){var e=this.gl;this.bind(),this.mipmap?e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,t?e.LINEAR_MIPMAP_LINEAR:e.NEAREST_MIPMAP_NEAREST):e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,t?e.LINEAR:e.NEAREST)},n.prototype.magFilter=function(t){var e=this.gl;this.bind(),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,t?e.LINEAR:e.NEAREST)},n.prototype.enableMipmap=function(){var t=this.gl;this.bind(),this.mipmap=!0,t.generateMipmap(t.TEXTURE_2D)},n.prototype.enableLinearScaling=function(){this.minFilter(!0),this.magFilter(!0)},n.prototype.enableNearestScaling=function(){this.minFilter(!1),this.magFilter(!1)},n.prototype.enableWrapClamp=function(){var t=this.gl;this.bind(),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.CLAMP_TO_EDGE),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.CLAMP_TO_EDGE)},n.prototype.enableWrapRepeat=function(){var t=this.gl;this.bind(),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.REPEAT),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.REPEAT)},n.prototype.enableWrapMirrorRepeat=function(){var t=this.gl;this.bind(),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_S,t.MIRRORED_REPEAT),t.texParameteri(t.TEXTURE_2D,t.TEXTURE_WRAP_T,t.MIRRORED_REPEAT)},n.prototype.destroy=function(){var t=this.gl;t.deleteTexture(this.texture)},n.fromSource=function(t,e,r){var i=new n(t);return i.premultiplyAlpha=r||!1,i.upload(e),i},n.fromData=function(t,e,r,i){var o=new n(t);return o.uploadData(e,r,i),o},e.exports=n},{}],10:[function(t,e,r){function n(t,e){if(this.nativeVaoExtension=null,n.FORCE_NATIVE||(this.nativeVaoExtension=t.getExtension("OES_vertex_array_object")||t.getExtension("MOZ_OES_vertex_array_object")||t.getExtension("WEBKIT_OES_vertex_array_object")),this.nativeState=e,this.nativeVaoExtension){this.nativeVao=this.nativeVaoExtension.createVertexArrayOES();var r=t.getParameter(t.MAX_VERTEX_ATTRIBS);this.nativeState={tempAttribState:new Array(r),attribState:new Array(r)}}this.gl=t,this.attributes=[],this.indexBuffer=null,this.dirty=!1}var i=t("./setVertexAttribArrays");n.prototype.constructor=n,e.exports=n,n.FORCE_NATIVE=!1,n.prototype.bind=function(){return this.nativeVao?(this.nativeVaoExtension.bindVertexArrayOES(this.nativeVao),this.dirty&&(this.dirty=!1,this.activate())):this.activate(),this},n.prototype.unbind=function(){return this.nativeVao&&this.nativeVaoExtension.bindVertexArrayOES(null),this},n.prototype.activate=function(){for(var t=this.gl,e=null,r=0;r=0;n--){var i=t[n];"."===i?t.splice(n,1):".."===i?(t.splice(n,1),r++):r&&(t.splice(n,1),r--)}if(e)for(;r--;r)t.unshift("..");return t}function n(t,e){if(t.filter)return t.filter(e);for(var r=[],n=0;n=-1&&!i;o--){var s=o>=0?arguments[o]:t.cwd();if("string"!=typeof s)throw new TypeError("Arguments to path.resolve must be strings");s&&(r=s+"/"+r,i="/"===s.charAt(0))}return r=e(n(r.split("/"),function(t){return!!t}),!i).join("/"),(i?"/":"")+r||"."},r.normalize=function(t){var i=r.isAbsolute(t),o="/"===s(t,-1);return(t=e(n(t.split("/"),function(t){return!!t}),!i).join("/"))||i||(t="."),t&&o&&(t+="/"),(i?"/":"")+t},r.isAbsolute=function(t){return"/"===t.charAt(0)},r.join=function(){var t=Array.prototype.slice.call(arguments,0);return r.normalize(n(t,function(t,e){if("string"!=typeof t)throw new TypeError("Arguments to path.join must be strings");return t}).join("/"))},r.relative=function(t,e){function n(t){for(var e=0;e=0&&""===t[r];r--);return e>r?[]:t.slice(e,r-e+1)}t=r.resolve(t).substr(1),e=r.resolve(e).substr(1);for(var i=n(t.split("/")),o=n(e.split("/")),s=Math.min(i.length,o.length),a=s,u=0;u1)for(var r=1;r1&&(n=r[0]+"@",t=r[1]);var i=(t=t.replace(O,".")).split("."),s=o(i,e).join(".");return n+s}function a(t){for(var e,r,n=[],i=0,o=t.length;i=55296&&e<=56319&&i65535&&(e+=L((t-=65536)>>>10&1023|55296),t=56320|1023&t),e+=L(t)}).join("")}function l(t){return t-48<10?t-22:t-65<26?t-65:t-97<26?t-97:b}function h(t,e){return t+22+75*(t<26)-((0!=e)<<5)}function c(t,e,r){var n=0;for(t=r?I(t/E):t>>1,t+=I(t/e);t>D*w>>1;n+=b)t=I(t/D);return I(n+(D+1)*t/(t+T))}function f(t){var e,r,n,o,s,a,h,f,p,d,g=[],v=t.length,m=0,y=A,T=S;for((r=t.lastIndexOf(C))<0&&(r=0),n=0;n=128&&i("not-basic"),g.push(t.charCodeAt(n));for(o=r>0?r+1:0;o=v&&i("invalid-input"),((f=l(t.charCodeAt(o++)))>=b||f>I((x-m)/a))&&i("overflow"),m+=f*a,!(f<(p=h<=T?_:h>=T+w?w:h-T));h+=b)a>I(x/(d=b-p))&&i("overflow"),a*=d;e=g.length+1,T=c(m-s,e,0==s),I(m/e)>x-y&&i("overflow"),y+=I(m/e),m%=e,g.splice(m++,0,y)}return u(g)}function p(t){var e,r,n,o,s,u,l,f,p,d,g,v,m,y,T,E=[];for(t=a(t),v=t.length,e=A,r=0,s=S,u=0;u=e&&gI((x-r)/(m=n+1))&&i("overflow"),r+=(l-e)*m,e=l,u=0;ux&&i("overflow"),g==e){for(f=r,p=b;!(f<(d=p<=s?_:p>=s+w?w:p-s));p+=b)T=f-d,y=b-d,E.push(L(h(d+T%y,0))),f=I(T/y);E.push(L(h(f,0))),s=c(r,m,n==o),r=0,++n}++r,++e}return E.join("")}var d="object"==typeof n&&n&&!n.nodeType&&n,g="object"==typeof r&&r&&!r.nodeType&&r,v="object"==typeof t&&t;v.global!==v&&v.window!==v&&v.self!==v||(e=v);var m,y,x=2147483647,b=36,_=1,w=26,T=38,E=700,S=72,A=128,C="-",M=/^xn--/,R=/[^\x20-\x7E]/,O=/[\x2E\u3002\uFF0E\uFF61]/g,P={overflow:"Overflow: input needs wider integers to process","not-basic":"Illegal input >= 0x80 (not a basic code point)","invalid-input":"Invalid input"},D=b-_,I=Math.floor,L=String.fromCharCode;if(m={version:"1.4.1",ucs2:{decode:a,encode:u},decode:f,encode:p,toASCII:function(t){return s(t,function(t){return R.test(t)?"xn--"+p(t):t})},toUnicode:function(t){return s(t,function(t){return M.test(t)?f(t.slice(4).toLowerCase()):t})}},d&&g)if(r.exports==d)g.exports=m;else for(y in m)m.hasOwnProperty(y)&&(d[y]=m[y]);else e.punycode=m}(this)}).call(this,void 0!==e?e:"undefined"!=typeof self?self:"undefined"!=typeof window?window:{})},{}],25:[function(t,e,r){"use strict";function n(t,e){return Object.prototype.hasOwnProperty.call(t,e)}e.exports=function(t,e,r,o){e=e||"&",r=r||"=";var s={};if("string"!=typeof t||0===t.length)return s;var a=/\+/g;t=t.split(e);var u=1e3;o&&"number"==typeof o.maxKeys&&(u=o.maxKeys);var l=t.length;u>0&&l>u&&(l=u);for(var h=0;h=0?(c=g.substr(0,v),f=g.substr(v+1)):(c=g,f=""),p=decodeURIComponent(c),d=decodeURIComponent(f),n(s,p)?i(s[p])?s[p].push(d):s[p]=[s[p],d]:s[p]=d}return s};var i=Array.isArray||function(t){return"[object Array]"===Object.prototype.toString.call(t)}},{}],26:[function(t,e,r){"use strict";function n(t,e){if(t.map)return t.map(e);for(var r=[],n=0;n",'"',"`"," ","\r","\n","\t"]),c=["'"].concat(h),f=["%","/","?",";","#"].concat(c),p=["/","?","#"],d=/^[+a-z0-9A-Z_-]{0,63}$/,g=/^([+a-z0-9A-Z_-]{0,63})(.*)$/,v={javascript:!0,"javascript:":!0},m={javascript:!0,"javascript:":!0},y={http:!0,https:!0,ftp:!0,gopher:!0,file:!0,"http:":!0,"https:":!0,"ftp:":!0,"gopher:":!0,"file:":!0},x=t("querystring");n.prototype.parse=function(t,e,r){if(!s.isString(t))throw new TypeError("Parameter 'url' must be a string, not "+typeof t);var n=t.indexOf("?"),i=-1!==n&&n127?"x":D[L];if(!I.match(d)){var k=O.slice(0,S),B=O.slice(S+1),N=D.match(g);N&&(k.push(N[1]),B.unshift(N[2])),B.length&&(h="/"+B.join(".")+h),this.hostname=k.join(".");break}}}this.hostname.length>255?this.hostname="":this.hostname=this.hostname.toLowerCase(),R||(this.hostname=o.toASCII(this.hostname));var U=this.port?":"+this.port:"",$=this.hostname||"";this.host=$+U,this.href+=this.host,R&&(this.hostname=this.hostname.substr(1,this.hostname.length-2),"/"!==h[0]&&(h="/"+h))}if(!v[w])for(var S=0,P=c.length;S0)&&r.host.split("@");S&&(r.auth=S.shift(),r.host=r.hostname=S.shift())}return r.search=t.search,r.query=t.query,s.isNull(r.pathname)&&s.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.href=r.format(),r}if(!T.length)return r.pathname=null,r.search?r.path="/"+r.search:r.path=null,r.href=r.format(),r;for(var A=T.slice(-1)[0],C=(r.host||t.host||T.length>1)&&("."===A||".."===A)||""===A,M=0,R=T.length;R>=0;R--)"."===(A=T[R])?T.splice(R,1):".."===A?(T.splice(R,1),M++):M&&(T.splice(R,1),M--);if(!_&&!w)for(;M--;M)T.unshift("..");!_||""===T[0]||T[0]&&"/"===T[0].charAt(0)||T.unshift(""),C&&"/"!==T.join("/").substr(-1)&&T.push("");var O=""===T[0]||T[0]&&"/"===T[0].charAt(0);if(E){r.hostname=r.host=O?"":T.length?T.shift():"";var S=!!(r.host&&r.host.indexOf("@")>0)&&r.host.split("@");S&&(r.auth=S.shift(),r.host=r.hostname=S.shift())}return(_=_||r.host&&T.length)&&!O&&T.unshift(""),T.length?r.pathname=T.join("/"):(r.pathname=null,r.path=null),s.isNull(r.pathname)&&s.isNull(r.search)||(r.path=(r.pathname?r.pathname:"")+(r.search?r.search:"")),r.auth=t.auth||r.auth,r.slashes=r.slashes||t.slashes,r.href=r.format(),r},n.prototype.parseHost=function(){var t=this.host,e=u.exec(t);e&&(":"!==(e=e[0])&&(this.port=e.substr(1)),t=t.substr(0,t.length-e.length)),t&&(this.hostname=t)}},{"./util":29,punycode:24,querystring:27}],29:[function(t,e,r){"use strict";e.exports={isString:function(t){return"string"==typeof t},isObject:function(t){return"object"==typeof t&&null!==t},isNull:function(t){return null===t},isNullOrUndefined:function(t){return null==t}}},{}],30:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0;var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},o=t("mini-signals"),s=n(o),a=t("parse-uri"),u=n(a),l=t("./async"),h=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}(l),c=t("./Resource"),f=n(c),p=/(#[\w-]+)?$/,d=function(){function t(){var e=this,r=arguments.length>0&&void 0!==arguments[0]?arguments[0]:"",n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:10;(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.baseUrl=r,this.progress=0,this.loading=!1,this.defaultQueryString="",this._beforeMiddleware=[],this._afterMiddleware=[],this._resourcesParsing=[],this._boundLoadResource=function(t,r){return e._loadResource(t,r)},this._queue=h.queue(this._boundLoadResource,n),this._queue.pause(),this.resources={},this.onProgress=new s.default,this.onError=new s.default,this.onLoad=new s.default,this.onStart=new s.default,this.onComplete=new s.default}return t.prototype.add=function(t,e,r,n){if(Array.isArray(t)){for(var o=0;o0){if(this.xhrType===t.XHR_RESPONSE_TYPE.TEXT)this.data=e.responseText,this.type=t.TYPE.TEXT;else if(this.xhrType===t.XHR_RESPONSE_TYPE.JSON)try{this.data=JSON.parse(e.responseText),this.type=t.TYPE.JSON}catch(t){return void this.abort("Error trying to parse loaded json: "+t)}else if(this.xhrType===t.XHR_RESPONSE_TYPE.DOCUMENT)try{if(window.DOMParser){var n=new DOMParser;this.data=n.parseFromString(e.responseText,"text/xml")}else{var i=document.createElement("div");i.innerHTML=e.responseText,this.data=i}this.type=t.TYPE.XML}catch(t){return void this.abort("Error trying to parse loaded xml: "+t)}else this.data=e.response||e.responseText;this.complete()}else this.abort("["+e.status+"] "+e.statusText+": "+e.responseURL)},t.prototype._determineCrossOrigin=function(t,e){if(0===t.indexOf("data:"))return"";e=e||window.location,p||(p=document.createElement("a")),p.href=t;var r=!(t=(0,l.default)(p.href,{strictMode:!0})).port&&""===e.port||t.port===e.port,n=t.protocol?t.protocol+":":"";return t.host===e.hostname&&r&&n===e.protocol?"":"anonymous"},t.prototype._determineXhrType=function(){return t._xhrTypeMap[this.extension]||t.XHR_RESPONSE_TYPE.TEXT},t.prototype._determineLoadType=function(){return t._loadTypeMap[this.extension]||t.LOAD_TYPE.XHR},t.prototype._getExtension=function(){var t=this.url,e="";if(this.isDataUrl){var r=t.indexOf("/");e=t.substring(r+1,t.indexOf(";",r))}else{var n=t.indexOf("?");-1!==n&&(t=t.substring(0,n)),e=t.substring(t.lastIndexOf(".")+1)}return e.toLowerCase()},t.prototype._getMimeFromXhrType=function(e){switch(e){case t.XHR_RESPONSE_TYPE.BUFFER:return"application/octet-binary";case t.XHR_RESPONSE_TYPE.BLOB:return"application/blob";case t.XHR_RESPONSE_TYPE.DOCUMENT:return"application/xml";case t.XHR_RESPONSE_TYPE.JSON:return"application/json";case t.XHR_RESPONSE_TYPE.DEFAULT:case t.XHR_RESPONSE_TYPE.TEXT:default:return"text/plain"}},a(t,[{key:"isDataUrl",get:function(){return this._hasFlag(t.STATUS_FLAGS.DATA_URL)}},{key:"isComplete",get:function(){return this._hasFlag(t.STATUS_FLAGS.COMPLETE)}},{key:"isLoading",get:function(){return this._hasFlag(t.STATUS_FLAGS.LOADING)}}]),t}();r.default=d,d.STATUS_FLAGS={NONE:0,DATA_URL:1,COMPLETE:2,LOADING:4},d.TYPE={UNKNOWN:0,JSON:1,XML:2,IMAGE:3,AUDIO:4,VIDEO:5,TEXT:6},d.LOAD_TYPE={XHR:1,IMAGE:2,AUDIO:3,VIDEO:4},d.XHR_RESPONSE_TYPE={DEFAULT:"text",BUFFER:"arraybuffer",BLOB:"blob",DOCUMENT:"document",JSON:"json",TEXT:"text"},d._loadTypeMap={gif:d.LOAD_TYPE.IMAGE,png:d.LOAD_TYPE.IMAGE,bmp:d.LOAD_TYPE.IMAGE,jpg:d.LOAD_TYPE.IMAGE,jpeg:d.LOAD_TYPE.IMAGE,tif:d.LOAD_TYPE.IMAGE,tiff:d.LOAD_TYPE.IMAGE,webp:d.LOAD_TYPE.IMAGE,tga:d.LOAD_TYPE.IMAGE,svg:d.LOAD_TYPE.IMAGE,"svg+xml":d.LOAD_TYPE.IMAGE,mp3:d.LOAD_TYPE.AUDIO,ogg:d.LOAD_TYPE.AUDIO,wav:d.LOAD_TYPE.AUDIO,mp4:d.LOAD_TYPE.VIDEO,webm:d.LOAD_TYPE.VIDEO},d._xhrTypeMap={xhtml:d.XHR_RESPONSE_TYPE.DOCUMENT,html:d.XHR_RESPONSE_TYPE.DOCUMENT,htm:d.XHR_RESPONSE_TYPE.DOCUMENT,xml:d.XHR_RESPONSE_TYPE.DOCUMENT,tmx:d.XHR_RESPONSE_TYPE.DOCUMENT,svg:d.XHR_RESPONSE_TYPE.DOCUMENT,tsx:d.XHR_RESPONSE_TYPE.DOCUMENT,gif:d.XHR_RESPONSE_TYPE.BLOB,png:d.XHR_RESPONSE_TYPE.BLOB,bmp:d.XHR_RESPONSE_TYPE.BLOB,jpg:d.XHR_RESPONSE_TYPE.BLOB,jpeg:d.XHR_RESPONSE_TYPE.BLOB,tif:d.XHR_RESPONSE_TYPE.BLOB,tiff:d.XHR_RESPONSE_TYPE.BLOB,webp:d.XHR_RESPONSE_TYPE.BLOB,tga:d.XHR_RESPONSE_TYPE.BLOB,json:d.XHR_RESPONSE_TYPE.JSON,text:d.XHR_RESPONSE_TYPE.TEXT,txt:d.XHR_RESPONSE_TYPE.TEXT,ttf:d.XHR_RESPONSE_TYPE.BUFFER,otf:d.XHR_RESPONSE_TYPE.BUFFER},d.EMPTY_GIF="data:image/gif;base64,R0lGODlhAQABAIAAAP///wAAACH5BAEAAAAALAAAAAABAAEAAAICRAEAOw=="},{"mini-signals":36,"parse-uri":37}],32:[function(t,e,r){"use strict";function n(){}function i(t){return function(){if(null===t)throw new Error("Callback was already called.");var e=t;t=null,e.apply(this,arguments)}}r.__esModule=!0,r.eachSeries=function(t,e,r){var n=0,i=t.length;!function o(s){return s||n===i?void(r&&r(s)):void e(t[n++],o)}()},r.queue=function(t,e){function r(t,e,r){if(null!=r&&"function"!=typeof r)throw new Error("task callback must be a function");if(a.started=!0,null==t&&a.idle())setTimeout(function(){return a.drain()},1);else{var i={data:t,callback:"function"==typeof r?r:n};e?a._tasks.unshift(i):a._tasks.push(i),setTimeout(function(){return a.process()},1)}}function o(t){return function(){s-=1,t.callback.apply(t,arguments),null!=arguments[0]&&a.error(arguments[0],t.data),s<=a.concurrency-a.buffer&&a.unsaturated(),a.idle()&&a.drain(),a.process()}}if(null==e)e=1;else if(0===e)throw new Error("Concurrency must not be zero");var s=0,a={_tasks:[],concurrency:e,saturated:n,unsaturated:n,buffer:e/4,empty:n,drain:n,error:n,started:!1,paused:!1,push:function(t,e){r(t,!1,e)},kill:function(){s=0,a.drain=n,a.started=!1,a._tasks=[]},unshift:function(t,e){r(t,!0,e)},process:function(){for(;!a.paused&&s>2,o[1]=(3&i[0])<<4|i[1]>>4,o[2]=(15&i[1])<<2|i[2]>>6,o[3]=63&i[2];var a=r-(t.length-1);switch(a){case 2:o[3]=64,o[2]=64;break;case 1:o[3]=64}for(var u=0;u=0;r--)this.updateAccessibleObjects(e[r])}},t.prototype.update=function(){if(this.renderer.renderingToScreen){this.updateAccessibleObjects(this.renderer._lastObjectRendered);var t=this.renderer.view.getBoundingClientRect(),e=t.width/this.renderer.width,r=t.height/this.renderer.height,n=this.div;n.style.left=t.left+"px",n.style.top=t.top+"px",n.style.width=this.renderer.width+"px",n.style.height=this.renderer.height+"px";for(var i=0;ithis.renderer.width&&(t.width=this.renderer.width-t.x),t.y+t.height>this.renderer.height&&(t.height=this.renderer.height-t.y)},t.prototype.addChild=function(t){var e=this.pool.pop();e||((e=document.createElement("button")).style.width=h+"px",e.style.height=h+"px",e.style.backgroundColor=this.debug?"rgba(255,0,0,0.5)":"transparent",e.style.position="absolute",e.style.zIndex=p,e.style.borderStyle="none",e.addEventListener("click",this._onClick.bind(this)),e.addEventListener("focus",this._onFocus.bind(this)),e.addEventListener("focusout",this._onFocusOut.bind(this))),t.accessibleTitle?e.title=t.accessibleTitle:t.accessibleTitle||t.accessibleHint||(e.title="displayObject "+this.tabIndex),t.accessibleHint&&e.setAttribute("aria-label",t.accessibleHint),t._accessibleActive=!0,t._accessibleDiv=e,e.displayObject=t,this.children.push(t),this.div.appendChild(t._accessibleDiv),t._accessibleDiv.tabIndex=t.tabIndex},t.prototype._onClick=function(t){var e=this.renderer.plugins.interaction;e.dispatchEvent(t.target.displayObject,"click",e.eventData)},t.prototype._onFocus=function(t){var e=this.renderer.plugins.interaction;e.dispatchEvent(t.target.displayObject,"mouseover",e.eventData)},t.prototype._onFocusOut=function(t){var e=this.renderer.plugins.interaction;e.dispatchEvent(t.target.displayObject,"mouseout",e.eventData)},t.prototype._onKeyDown=function(t){9===t.keyCode&&this.activate()},t.prototype._onMouseMove=function(){this.deactivate()},t.prototype.destroy=function(){this.div=null;for(var t=0;t4&&void 0!==arguments[4]&&arguments[4];(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.renderer=(0,i.autoDetectRenderer)(e,r,n,o),this.stage=new s.default,this._ticker=null,this.ticker=u?a.shared:new a.Ticker,this.start()}return t.prototype.render=function(){this.renderer.render(this.stage)},t.prototype.stop=function(){this._ticker.stop()},t.prototype.start=function(){this._ticker.start()},t.prototype.destroy=function(t){this.stop(),this.ticker=null,this.stage.destroy(),this.stage=null,this.renderer.destroy(t),this.renderer=null},n(t,[{key:"ticker",set:function(t){this._ticker&&this._ticker.remove(this.render,this),this._ticker=t,t&&t.add(this.render,this)},get:function(){return this._ticker}},{key:"view",get:function(){return this.renderer.view}},{key:"screen",get:function(){return this.renderer.screen}}]),t}();r.default=u},{"./autoDetectRenderer":43,"./display/Container":46,"./ticker":116}],42:[function(t,e,r){"use strict";function n(t,e){if(t instanceof Array){if("precision"!==t[0].substring(0,9)){var r=t.slice(0);return r.unshift("precision "+e+" float;"),r}}else if("precision"!==t.substring(0,9))return"precision "+e+" float;\n"+t;return t}r.__esModule=!0;var i=t("pixi-gl-core"),o=t("./settings"),s=function(t){return t&&t.__esModule?t:{default:t}}(o),a=function(t){function e(r,i,o){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,r,n(i,s.default.PRECISION_VERTEX),n(o,s.default.PRECISION_FRAGMENT)))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e}(i.GLShader);r.default=a},{"./settings":99,"pixi-gl-core":12}],43:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0,r.autoDetectRenderer=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:800,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:600,r=arguments[2];return!arguments[3]&&o.isWebGLSupported()?new l.default(t,e,r):new a.default(t,e,r)};var i=t("./utils"),o=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}(i),s=t("./renderers/canvas/CanvasRenderer"),a=n(s),u=t("./renderers/webgl/WebGLRenderer"),l=n(u)},{"./renderers/canvas/CanvasRenderer":75,"./renderers/webgl/WebGLRenderer":82,"./utils":120}],44:[function(t,e,r){"use strict";r.__esModule=!0,r.VERSION="4.4.3",r.PI_2=2*Math.PI,r.RAD_TO_DEG=180/Math.PI,r.DEG_TO_RAD=Math.PI/180,r.RENDERER_TYPE={UNKNOWN:0,WEBGL:1,CANVAS:2},r.BLEND_MODES={NORMAL:0,ADD:1,MULTIPLY:2,SCREEN:3,OVERLAY:4,DARKEN:5,LIGHTEN:6,COLOR_DODGE:7,COLOR_BURN:8,HARD_LIGHT:9,SOFT_LIGHT:10,DIFFERENCE:11,EXCLUSION:12,HUE:13,SATURATION:14,COLOR:15,LUMINOSITY:16},r.DRAW_MODES={POINTS:0,LINES:1,LINE_LOOP:2,LINE_STRIP:3,TRIANGLES:4,TRIANGLE_STRIP:5,TRIANGLE_FAN:6},r.SCALE_MODES={LINEAR:0,NEAREST:1},r.WRAP_MODES={CLAMP:0,REPEAT:1,MIRRORED_REPEAT:2},r.GC_MODES={AUTO:0,MANUAL:1},r.URL_FILE_EXTENSION=/\.(\w{3,4})(?:$|\?|#)/i,r.DATA_URI=/^\s*data:(?:([\w-]+)\/([\w+.-]+))?(?:;(charset=[\w-]+|base64))?,(.*)/i,r.SVG_SIZE=/]*(?:\s(width|height)=('|")(\d*(?:\.\d+)?)(?:px)?('|"))[^>]*(?:\s(width|height)=('|")(\d*(?:\.\d+)?)(?:px)?('|"))[^>]*>/i,r.SHAPES={POLY:0,RECT:1,CIRC:2,ELIP:3,RREC:4},r.PRECISION={LOW:"lowp",MEDIUM:"mediump",HIGH:"highp"},r.TRANSFORM_MODE={STATIC:0,DYNAMIC:1},r.TEXT_GRADIENT={LINEAR_VERTICAL:0,LINEAR_HORIZONTAL:1}},{}],45:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("../math"),i=function(){function t(){(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0,this.rect=null}return t.prototype.isEmpty=function(){return this.minX>this.maxX||this.minY>this.maxY},t.prototype.clear=function(){this.updateID++,this.minX=1/0,this.minY=1/0,this.maxX=-1/0,this.maxY=-1/0},t.prototype.getRectangle=function(t){return this.minX>this.maxX||this.minY>this.maxY?n.Rectangle.EMPTY:((t=t||new n.Rectangle(0,0,1,1)).x=this.minX,t.y=this.minY,t.width=this.maxX-this.minX,t.height=this.maxY-this.minY,t)},t.prototype.addPoint=function(t){this.minX=Math.min(this.minX,t.x),this.maxX=Math.max(this.maxX,t.x),this.minY=Math.min(this.minY,t.y),this.maxY=Math.max(this.maxY,t.y)},t.prototype.addQuad=function(t){var e=this.minX,r=this.minY,n=this.maxX,i=this.maxY,o=t[0],s=t[1];e=on?o:n,i=s>i?s:i,o=t[2],s=t[3],e=on?o:n,i=s>i?s:i,o=t[4],s=t[5],e=on?o:n,i=s>i?s:i,o=t[6],s=t[7],e=on?o:n,i=s>i?s:i,this.minX=e,this.minY=r,this.maxX=n,this.maxY=i},t.prototype.addFrame=function(t,e,r,n,i){var o=t.worldTransform,s=o.a,a=o.b,u=o.c,l=o.d,h=o.tx,c=o.ty,f=this.minX,p=this.minY,d=this.maxX,g=this.maxY,v=s*e+u*r+h,m=a*e+l*r+c;f=vd?v:d,g=m>g?m:g,m=a*n+l*r+c,f=(v=s*n+u*r+h)d?v:d,g=m>g?m:g,m=a*e+l*i+c,f=(v=s*e+u*i+h)d?v:d,g=m>g?m:g,m=a*n+l*i+c,f=(v=s*n+u*i+h)d?v:d,g=m>g?m:g,this.minX=f,this.minY=p,this.maxX=d,this.maxY=g},t.prototype.addVertices=function(t,e,r,n){for(var i=t.worldTransform,o=i.a,s=i.b,a=i.c,u=i.d,l=i.tx,h=i.ty,c=this.minX,f=this.minY,p=this.maxX,d=this.maxY,g=r;gp?y:p,d=x>d?x:d}this.minX=c,this.minY=f,this.maxX=p,this.maxY=d},t.prototype.addBounds=function(t){var e=this.minX,r=this.minY,n=this.maxX,i=this.maxY;this.minX=t.minXn?t.maxX:n,this.maxY=t.maxY>i?t.maxY:i},t.prototype.addBoundsMask=function(t,e){var r=t.minX>e.minX?t.minX:e.minX,n=t.minY>e.minY?t.minY:e.minY,i=t.maxXu?i:u,this.maxY=o>l?o:l}},t.prototype.addBoundsArea=function(t,e){var r=t.minX>e.x?t.minX:e.x,n=t.minY>e.y?t.minY:e.y,i=t.maxXu?i:u,this.maxY=o>l?o:l}},t}();r.default=i},{"../math":68}],46:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(t,e){for(var r=0;r1)for(var r=0;rthis.children.length)throw new Error(t+"addChildAt: The index "+e+" supplied is out of bounds "+this.children.length);return t.parent&&t.parent.removeChild(t),t.parent=this,t.transform._parentID=-1,this.children.splice(e,0,t),this._boundsID++,this.onChildrenChange(e),t.emit("added",this),t},e.prototype.swapChildren=function(t,e){if(t!==e){var r=this.getChildIndex(t),n=this.getChildIndex(e);this.children[r]=e,this.children[n]=t,this.onChildrenChange(r=this.children.length)throw new Error("The supplied index is out of bounds");var r=this.getChildIndex(t);(0,i.removeItems)(this.children,r,1),this.children.splice(e,0,t),this.onChildrenChange(e)},e.prototype.getChildAt=function(t){if(t<0||t>=this.children.length)throw new Error("getChildAt: Index ("+t+") does not exist.");return this.children[t]},e.prototype.removeChild=function(t){var e=arguments.length;if(e>1)for(var r=0;r0&&void 0!==arguments[0]?arguments[0]:0,e=arguments[1],r=t,n="number"==typeof e?e:this.children.length,i=n-r,o=void 0;if(i>0&&i<=n){o=this.children.splice(r,i);for(var s=0;s2&&void 0!==arguments[2]&&arguments[2];return r||(this._recursivePostUpdateTransform(),this.parent?this.displayObjectUpdateTransform():(this.parent=this._tempDisplayObjectParent,this.displayObjectUpdateTransform(),this.parent=null)),this.worldTransform.apply(t,e)},e.prototype.toLocal=function(t,e,r,n){return e&&(t=e.toGlobal(t,r,n)),n||(this._recursivePostUpdateTransform(),this.parent?this.displayObjectUpdateTransform():(this.parent=this._tempDisplayObjectParent,this.displayObjectUpdateTransform(),this.parent=null)),this.worldTransform.applyInverse(t,r)},e.prototype.renderWebGL=function(t){},e.prototype.renderCanvas=function(t){},e.prototype.setParent=function(t){if(!t||!t.addChild)throw new Error("setParent: Argument must be a Container");return t.addChild(this),t},e.prototype.setTransform=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,i=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,o=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0,s=arguments.length>6&&void 0!==arguments[6]?arguments[6]:0,a=arguments.length>7&&void 0!==arguments[7]?arguments[7]:0,u=arguments.length>8&&void 0!==arguments[8]?arguments[8]:0;return this.position.x=t,this.position.y=e,this.scale.x=r||1,this.scale.y=n||1,this.rotation=i,this.skew.x=o,this.skew.y=s,this.pivot.x=a,this.pivot.y=u,this},e.prototype.destroy=function(){this.removeAllListeners(),this.parent&&this.parent.removeChild(this),this.transform=null,this.parent=null,this._bounds=null,this._currentBounds=null,this._mask=null,this.filterArea=null,this.interactive=!1,this.interactiveChildren=!1,this._destroyed=!0},i(e,[{key:"_tempDisplayObjectParent",get:function(){return null===this.tempDisplayObjectParent&&(this.tempDisplayObjectParent=new e),this.tempDisplayObjectParent}},{key:"x",get:function(){return this.position.x},set:function(t){this.transform.position.x=t}},{key:"y",get:function(){return this.position.y},set:function(t){this.transform.position.y=t}},{key:"worldTransform",get:function(){return this.transform.worldTransform}},{key:"localTransform",get:function(){return this.transform.localTransform}},{key:"position",get:function(){return this.transform.position},set:function(t){this.transform.position.copy(t)}},{key:"scale",get:function(){return this.transform.scale},set:function(t){this.transform.scale.copy(t)}},{key:"pivot",get:function(){return this.transform.pivot},set:function(t){this.transform.pivot.copy(t)}},{key:"skew",get:function(){return this.transform.skew},set:function(t){this.transform.skew.copy(t)}},{key:"rotation",get:function(){return this.transform.rotation},set:function(t){this.transform.rotation=t}},{key:"worldVisible",get:function(){var t=this;do{if(!t.visible)return!1;t=t.parent}while(t);return!0}},{key:"mask",get:function(){return this._mask},set:function(t){this._mask&&(this._mask.renderable=!0),this._mask=t,this._mask&&(this._mask.renderable=!1)}},{key:"filters",get:function(){return this._filters&&this._filters.slice()},set:function(t){this._filters=t&&t.slice()}}]),e}(s.default);r.default=m,m.prototype.displayObjectUpdateTransform=m.prototype.updateTransform},{"../const":44,"../math":68,"../settings":99,"./Bounds":45,"./Transform":48,"./TransformStatic":50,eventemitter3:3}],48:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(t,e){for(var r=0;r0&&void 0!==arguments[0]&&arguments[0];!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this));return n.fillAlpha=1,n.lineWidth=0,n.nativeLines=r,n.lineColor=0,n.graphicsData=[],n.tint=16777215,n._prevTint=16777215,n.blendMode=v.BLEND_MODES.NORMAL,n.currentPath=null,n._webGL={},n.isMask=!1,n.boundsPadding=0,n._localBounds=new y.default,n.dirty=0,n.fastRectDirty=-1,n.clearDirty=0,n.boundsDirty=-1,n.cachedSpriteDirty=!1,n._spriteRect=null,n._fastRect=!1,n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.clone=function(){var t=new e;t.renderable=this.renderable,t.fillAlpha=this.fillAlpha,t.lineWidth=this.lineWidth,t.lineColor=this.lineColor,t.tint=this.tint,t.blendMode=this.blendMode,t.isMask=this.isMask,t.boundsPadding=this.boundsPadding,t.dirty=0,t.cachedSpriteDirty=this.cachedSpriteDirty;for(var r=0;r0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:1;if(this.lineWidth=t,this.lineColor=e,this.lineAlpha=r,this.currentPath)if(this.currentPath.shape.points.length){var n=new d.Polygon(this.currentPath.shape.points.slice(-2));n.closed=!1,this.drawShape(n)}else this.currentPath.lineWidth=this.lineWidth,this.currentPath.lineColor=this.lineColor,this.currentPath.lineAlpha=this.lineAlpha;return this},e.prototype.moveTo=function(t,e){var r=new d.Polygon([t,e]);return r.closed=!1,this.drawShape(r),this},e.prototype.lineTo=function(t,e){return this.currentPath.shape.points.push(t,e),this.dirty++,this},e.prototype.quadraticCurveTo=function(t,e,r,n){this.currentPath?0===this.currentPath.shape.points.length&&(this.currentPath.shape.points=[0,0]):this.moveTo(0,0);var i=this.currentPath.shape.points,o=0,s=0;0===i.length&&this.moveTo(0,0);for(var a=i[i.length-2],u=i[i.length-1],l=1;l<=20;++l){var h=l/20;o=a+(t-a)*h,s=u+(e-u)*h,i.push(o+(t+(r-t)*h-o)*h,s+(e+(n-e)*h-s)*h)}return this.dirty++,this},e.prototype.bezierCurveTo=function(t,e,r,n,i,o){this.currentPath?0===this.currentPath.shape.points.length&&(this.currentPath.shape.points=[0,0]):this.moveTo(0,0);var s=this.currentPath.shape.points,a=s[s.length-2],u=s[s.length-1];return s.length-=2,(0,b.default)(a,u,t,e,r,n,i,o,s),this.dirty++,this},e.prototype.arcTo=function(t,e,r,n,i){this.currentPath?0===this.currentPath.shape.points.length&&this.currentPath.shape.points.push(t,e):this.moveTo(t,e);var o=this.currentPath.shape.points,s=o[o.length-2],a=o[o.length-1],u=a-e,l=s-t,h=n-e,c=r-t,f=Math.abs(u*c-l*h);if(f<1e-8||0===i)o[o.length-2]===t&&o[o.length-1]===e||o.push(t,e);else{var p=u*u+l*l,d=h*h+c*c,g=u*h+l*c,v=i*Math.sqrt(p)/f,m=i*Math.sqrt(d)/f,y=v*g/p,x=m*g/d,b=v*c+m*l,_=v*h+m*u,w=l*(m+y),T=u*(m+y),E=c*(v+x),S=h*(v+x),A=Math.atan2(T-_,w-b),C=Math.atan2(S-_,E-b);this.arc(b+t,_+e,i,A,C,l*h>c*u)}return this.dirty++,this},e.prototype.arc=function(t,e,r,n,i){var o=arguments.length>5&&void 0!==arguments[5]&&arguments[5];if(n===i)return this;!o&&i<=n?i+=2*Math.PI:o&&n<=i&&(n+=2*Math.PI);var s=i-n,a=40*Math.ceil(Math.abs(s)/(2*Math.PI));if(0===s)return this;var u=t+Math.cos(n)*r,l=e+Math.sin(n)*r,h=this.currentPath?this.currentPath.shape.points:null;h?h[h.length-2]===u&&h[h.length-1]===l||h.push(u,l):(this.moveTo(u,l),h=this.currentPath.shape.points);for(var c=s/(2*a),f=2*c,p=Math.cos(c),d=Math.sin(c),g=a-1,v=g%1/g,m=0;m<=g;++m){var y=m+v*m,x=c+n+f*y,b=Math.cos(x),_=-Math.sin(x);h.push((p*b+d*_)*r+t,(p*-_+d*b)*r+e)}return this.dirty++,this},e.prototype.beginFill=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1;return this.filling=!0,this.fillColor=t,this.fillAlpha=e,this.currentPath&&this.currentPath.shape.points.length<=2&&(this.currentPath.fill=this.filling,this.currentPath.fillColor=this.fillColor,this.currentPath.fillAlpha=this.fillAlpha),this},e.prototype.endFill=function(){return this.filling=!1,this.fillColor=null,this.fillAlpha=1,this},e.prototype.drawRect=function(t,e,r,n){return this.drawShape(new d.Rectangle(t,e,r,n)),this},e.prototype.drawRoundedRect=function(t,e,r,n,i){return this.drawShape(new d.RoundedRectangle(t,e,r,n,i)),this},e.prototype.drawCircle=function(t,e,r){return this.drawShape(new d.Circle(t,e,r)),this},e.prototype.drawEllipse=function(t,e,r,n){return this.drawShape(new d.Ellipse(t,e,r,n)),this},e.prototype.drawPolygon=function(t){var e=t,r=!0;if(e instanceof d.Polygon&&(r=e.closed,e=e.points),!Array.isArray(e)){e=new Array(arguments.length);for(var n=0;n0)&&(this.lineWidth=0,this.filling=!1,this.boundsDirty=-1,this.dirty++,this.clearDirty++,this.graphicsData.length=0),this.currentPath=null,this._spriteRect=null,this},e.prototype.isFastRect=function(){return 1===this.graphicsData.length&&this.graphicsData[0].shape.type===v.SHAPES.RECT&&!this.graphicsData[0].lineWidth},e.prototype._renderWebGL=function(t){this.dirty!==this.fastRectDirty&&(this.fastRectDirty=this.dirty,this._fastRect=this.isFastRect()),this._fastRect?this._renderSpriteRect(t):(t.setObjectRenderer(t.plugins.graphics),t.plugins.graphics.render(this))},e.prototype._renderSpriteRect=function(t){var e=this.graphicsData[0].shape;this._spriteRect||(this._spriteRect=new p.default(new l.default(l.default.WHITE)));var r=this._spriteRect;if(16777215===this.tint)r.tint=this.graphicsData[0].fillColor;else{var n=A,i=C;(0,g.hex2rgb)(this.graphicsData[0].fillColor,n),(0,g.hex2rgb)(this.tint,i),n[0]*=i[0],n[1]*=i[1],n[2]*=i[2],r.tint=(0,g.rgb2hex)(n)}r.alpha=this.graphicsData[0].fillAlpha,r.worldAlpha=this.worldAlpha*r.alpha,r.blendMode=this.blendMode,r.texture._frame.width=e.width,r.texture._frame.height=e.height,r.transform.worldTransform=this.transform.worldTransform,r.anchor.set(-e.x/e.width,-e.y/e.height),r._onAnchorUpdate(),r._renderWebGL(t)},e.prototype._renderCanvas=function(t){!0!==this.isMask&&t.plugins.graphics.render(this)},e.prototype._calculateBounds=function(){this.boundsDirty!==this.dirty&&(this.boundsDirty=this.dirty,this.updateLocalBounds(),this.cachedSpriteDirty=!0);var t=this._localBounds;this._bounds.addFrame(this.transform,t.minX,t.minY,t.maxX,t.maxY)},e.prototype.containsPoint=function(t){this.worldTransform.applyInverse(t,S);for(var e=this.graphicsData,r=0;re?o+a:e,r=sn?s+u:n;else if(c===v.SHAPES.CIRC)o=i.x,s=i.y,a=i.radius+f/2,u=i.radius+f/2,t=o-ae?o+a:e,r=s-un?s+u:n;else if(c===v.SHAPES.ELIP)o=i.x,s=i.y,a=i.width+f/2,u=i.height+f/2,t=o-ae?o+a:e,r=s-un?s+u:n;else for(var p=i.points,d=0,g=0,m=0,y=0,x=0,b=0,_=0,w=0,T=0;T+2e?_+x:e,r=w-bn?w+b:n)}else t=0,e=0,r=0,n=0;var E=this.boundsPadding;this._localBounds.minX=t-E,this._localBounds.maxX=e+2*E,this._localBounds.minY=r-E,this._localBounds.maxY=n+2*E},e.prototype.drawShape=function(t){this.currentPath&&this.currentPath.shape.points.length<=2&&this.graphicsData.pop(),this.currentPath=null;var e=new c.default(this.lineWidth,this.lineColor,this.lineAlpha,this.fillColor,this.fillAlpha,this.filling,this.nativeLines,t);return this.graphicsData.push(e),e.type===v.SHAPES.POLY&&(e.shape.closed=e.shape.closed||this.filling,this.currentPath=e),this.dirty++,e},e.prototype.generateCanvasTexture=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:1,r=this.getLocalBounds(),n=a.default.create(r.width,r.height,t,e);T||(T=new w.default),this.transform.updateLocalTransform(),this.transform.localTransform.copy(E),E.invert(),E.tx-=r.x,E.ty-=r.y,T.render(this,n,!0,E);var i=l.default.fromCanvas(n.baseTexture._canvasRenderTarget.canvas,t);return i.baseTexture.resolution=e,i.baseTexture.update(),i},e.prototype.closePath=function(){var t=this.currentPath;return t&&t.shape&&t.shape.close(),this},e.prototype.addHole=function(){var t=this.graphicsData.pop();return this.currentPath=this.graphicsData[this.graphicsData.length-1],this.currentPath.addHole(t.shape),this.currentPath=null,this},e.prototype.destroy=function(e){t.prototype.destroy.call(this,e);for(var r=0;rR?R:M,r.beginPath(),r.moveTo(E,S+M),r.lineTo(E,S+C-M),r.quadraticCurveTo(E,S+C,E+M,S+C),r.lineTo(E+A-M,S+C),r.quadraticCurveTo(E+A,S+C,E+A,S+C-M),r.lineTo(E+A,S+M),r.quadraticCurveTo(E+A,S,E+A-M,S),r.lineTo(E+M,S),r.quadraticCurveTo(E,S,E,S+M),r.closePath(),(u.fillColor||0===u.fillColor)&&(r.globalAlpha=u.fillAlpha*n,r.fillStyle="#"+("00000"+(0|h).toString(16)).substr(-6),r.fill()),u.lineWidth&&(r.globalAlpha=u.lineAlpha*n,r.strokeStyle="#"+("00000"+(0|c).toString(16)).substr(-6),r.stroke())}}},t.prototype.updateGraphicsTint=function(t){t._prevTint=t.tint;for(var e=(t.tint>>16&255)/255,r=(t.tint>>8&255)/255,n=(255&t.tint)/255,i=0;i>16&255)/255*e*255<<16)+((s>>8&255)/255*r*255<<8)+(255&s)/255*n*255,o._lineTint=((a>>16&255)/255*e*255<<16)+((a>>8&255)/255*r*255<<8)+(255&a)/255*n*255}},t.prototype.renderPolygon=function(t,e,r){r.moveTo(t[0],t[1]);for(var n=1;n8&&void 0!==arguments[8]?arguments[8]:[],l=0,h=0,c=0,f=0,p=0;u.push(t,e);for(var d=1,g=0;d<=20;++d)c=(h=(l=1-(g=d/20))*l)*l,p=(f=g*g)*g,u.push(c*t+3*h*g*r+3*l*f*i+p*s,c*e+3*h*g*n+3*l*f*o+p*a);return u}},{}],55:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0;var i=t("../../utils"),o=t("../../const"),s=t("../../renderers/webgl/utils/ObjectRenderer"),a=n(s),u=t("../../renderers/webgl/WebGLRenderer"),l=n(u),h=t("./WebGLGraphicsData"),c=n(h),f=t("./shaders/PrimitiveShader"),p=n(f),d=t("./utils/buildPoly"),g=n(d),v=t("./utils/buildRectangle"),m=n(v),y=t("./utils/buildRoundedRectangle"),x=n(y),b=t("./utils/buildCircle"),_=n(b),w=function(t){function e(r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,r));return n.graphicsDataPool=[],n.primitiveShader=null,n.gl=r.gl,n.CONTEXT_UID=0,n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.onContextChange=function(){this.gl=this.renderer.gl,this.CONTEXT_UID=this.renderer.CONTEXT_UID,this.primitiveShader=new p.default(this.gl)},e.prototype.destroy=function(){a.default.prototype.destroy.call(this);for(var t=0;t32e4)&&((r=this.graphicsDataPool.pop()||new c.default(this.renderer.gl,this.primitiveShader,this.renderer.state.attribsState)).reset(e),t.data.push(r)),r.dirty=!0,r},e}(a.default);r.default=w,l.default.registerPlugin("graphics",w)},{"../../const":44,"../../renderers/webgl/WebGLRenderer":82,"../../renderers/webgl/utils/ObjectRenderer":92,"../../utils":120,"./WebGLGraphicsData":56,"./shaders/PrimitiveShader":57,"./utils/buildCircle":58,"./utils/buildPoly":60,"./utils/buildRectangle":61,"./utils/buildRoundedRectangle":62}],56:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("pixi-gl-core"),i=function(t){return t&&t.__esModule?t:{default:t}}(n),o=function(){function t(e,r,n){(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.gl=e,this.color=[0,0,0],this.points=[],this.indices=[],this.buffer=i.default.GLBuffer.createVertexBuffer(e),this.indexBuffer=i.default.GLBuffer.createIndexBuffer(e),this.dirty=!0,this.glPoints=null,this.glIndices=null,this.shader=r,this.vao=new i.default.VertexArrayObject(e,n).addIndex(this.indexBuffer).addAttribute(this.buffer,r.attributes.aVertexPosition,e.FLOAT,!1,24,0).addAttribute(this.buffer,r.attributes.aColor,e.FLOAT,!1,24,8)}return t.prototype.reset=function(){this.points.length=0,this.indices.length=0},t.prototype.upload=function(){this.glPoints=new Float32Array(this.points),this.buffer.upload(this.glPoints),this.glIndices=new Uint16Array(this.indices),this.indexBuffer.upload(this.glIndices),this.dirty=!1},t.prototype.destroy=function(){this.color=null,this.points=null,this.indices=null,this.vao.destroy(),this.buffer.destroy(),this.indexBuffer.destroy(),this.gl=null,this.buffer=null,this.indexBuffer=null,this.glPoints=null,this.glIndices=null},t}();r.default=o},{"pixi-gl-core":12}],57:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("../../../Shader"),i=function(t){return t&&t.__esModule?t:{default:t}}(n),o=function(t){function e(r){return function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e),function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,r,["attribute vec2 aVertexPosition;","attribute vec4 aColor;","uniform mat3 translationMatrix;","uniform mat3 projectionMatrix;","uniform float alpha;","uniform vec3 tint;","varying vec4 vColor;","void main(void){"," gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);"," vColor = aColor * vec4(tint * alpha, alpha);","}"].join("\n"),["varying vec4 vColor;","void main(void){"," gl_FragColor = vColor;","}"].join("\n")))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e}(i.default);r.default=o},{"../../../Shader":42}],58:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e){var r=t.shape,n=r.x,a=r.y,u=void 0,l=void 0;if(t.type===o.SHAPES.CIRC?(u=r.radius,l=r.radius):(u=r.width,l=r.height),0!==u&&0!==l){var h=Math.floor(30*Math.sqrt(r.radius))||Math.floor(15*Math.sqrt(r.width+r.height)),c=2*Math.PI/h;if(t.fill){var f=(0,s.hex2rgb)(t.fillColor),p=t.fillAlpha,d=f[0]*p,g=f[1]*p,v=f[2]*p,m=e.points,y=e.indices,x=m.length/6;y.push(x);for(var b=0;b196*d*d?(O=A-M,P=C-R,D=Math.sqrt(O*O+P*P),O/=D,P/=D,O*=d,P*=d,l.push(w-O,T-P),l.push(m,y,x,v),l.push(w+O,T+P),l.push(m,y,x,v),l.push(w-O,T-P),l.push(m,y,x,v),f++):(l.push(j,G),l.push(m,y,x,v),l.push(w-(j-w),T-(G-T)),l.push(m,y,x,v))}}b=r[2*(c-2)],_=r[2*(c-2)+1],w=r[2*(c-1)],T=r[2*(c-1)+1],A=-(_-T),C=b-w,D=Math.sqrt(A*A+C*C),A/=D,C/=D,A*=d,C*=d,l.push(w-A,T-C),l.push(m,y,x,v),l.push(w+A,T+C),l.push(m,y,x,v),h.push(p);for(var V=0;V=6){for(var n=[],i=t.holes,a=0;a0&&(0,o.default)(t,e)};var i=t("./buildLine"),o=n(i),s=t("../../../utils"),a=t("earcut"),u=n(a)},{"../../../utils":120,"./buildLine":59,earcut:2}],61:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e){var r=t.shape,n=r.x,s=r.y,a=r.width,u=r.height;if(t.fill){var l=(0,o.hex2rgb)(t.fillColor),h=t.fillAlpha,c=l[0]*h,f=l[1]*h,p=l[2]*h,d=e.points,g=e.indices,v=d.length/6;d.push(n,s),d.push(c,f,p,h),d.push(n+a,s),d.push(c,f,p,h),d.push(n,s+u),d.push(c,f,p,h),d.push(n+a,s+u),d.push(c,f,p,h),g.push(v,v,v+1,v+2,v+3,v+3)}if(t.lineWidth){var m=t.points;t.points=[n,s,n+a,s,n+a,s+u,n,s+u,n,s],(0,i.default)(t,e),t.points=m}};var n=t("./buildLine"),i=function(t){return t&&t.__esModule?t:{default:t}}(n),o=t("../../../utils")},{"../../../utils":120,"./buildLine":59}],62:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}function i(t,e,r){var n=e-t;return t+n*r}function o(t,e,r,n,o,s){for(var a=arguments.length>6&&void 0!==arguments[6]?arguments[6]:[],u=a,l=0,h=0,c=0,f=0,p=0,d=0,g=0,v=0;g<=20;++g)l=i(t,r,v=g/20),h=i(e,n,v),c=i(r,o,v),f=i(n,s,v),p=i(l,c,v),d=i(h,f,v),u.push(p,d);return u}r.__esModule=!0,r.default=function(t,e){var r=t.shape,n=r.x,i=r.y,s=r.width,u=r.height,c=r.radius,f=[];if(f.push(n,i+c),o(n,i+u-c,n,i+u,n+c,i+u,f),o(n+s-c,i+u,n+s,i+u,n+s,i+u-c,f),o(n+s,i+c,n+s,i,n+s-c,i,f),o(n+c,i,n,i,n,i+c+1e-10,f),t.fill){for(var p=(0,h.hex2rgb)(t.fillColor),d=t.fillAlpha,g=p[0]*d,v=p[1]*d,m=p[2]*d,y=e.points,x=e.indices,b=y.length/6,_=(0,a.default)(f,null,2),w=0,T=_.length;w0?1:0}r.__esModule=!0;var i=t("./Matrix"),o=function(t){return t&&t.__esModule?t:{default:t}}(i),s=[1,1,0,-1,-1,-1,0,1,1,1,0,-1,-1,-1,0,1],a=[0,1,1,1,0,-1,-1,-1,0,1,1,1,0,-1,-1,-1],u=[0,-1,-1,-1,0,1,1,1,0,1,1,1,0,-1,-1,-1],l=[1,1,0,-1,-1,-1,0,1,-1,-1,0,1,1,1,0,-1],h=[],c=[];!function(){for(var t=0;t<16;t++){var e=[];c.push(e);for(var r=0;r<16;r++)for(var i=n(s[t]*s[r]+u[t]*a[r]),f=n(a[t]*s[r]+l[t]*a[r]),p=n(s[t]*u[r]+u[t]*l[r]),d=n(a[t]*u[r]+l[t]*l[r]),g=0;g<16;g++)if(s[g]===i&&a[g]===f&&u[g]===p&&l[g]===d){e.push(g);break}}for(var v=0;v<16;v++){var m=new o.default;m.set(s[v],a[v],u[v],l[v],0,0),h.push(m)}}();var f={E:0,SE:1,S:2,SW:3,W:4,NW:5,N:6,NE:7,MIRROR_VERTICAL:8,MIRROR_HORIZONTAL:12,uX:function(t){return s[t]},uY:function(t){return a[t]},vX:function(t){return u[t]},vY:function(t){return l[t]},inv:function(t){return 8&t?15&t:7&-t},add:function(t,e){return c[t][e]},sub:function(t,e){return c[t][f.inv(e)]},rotate180:function(t){return 4^t},isSwapWidthHeight:function(t){return 2==(3&t)},byDirection:function(t,e){return 2*Math.abs(t)<=Math.abs(e)?e>=0?f.S:f.N:2*Math.abs(e)<=Math.abs(t)?t>0?f.E:f.W:e>0?t>0?f.SE:f.SW:t>0?f.NE:f.NW},matrixAppendRotationInv:function(t,e){var r=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,n=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,i=h[f.inv(e)];i.tx=r,i.ty=n,t.append(i)}};r.default=f},{"./Matrix":65}],65:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(t,e){for(var r=0;r0&&void 0!==arguments[0]?arguments[0]:1,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:1,o=arguments.length>4&&void 0!==arguments[4]?arguments[4]:0,s=arguments.length>5&&void 0!==arguments[5]?arguments[5]:0;(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.a=e,this.b=r,this.c=n,this.d=i,this.tx=o,this.ty=s,this.array=null}return t.prototype.fromArray=function(t){this.a=t[0],this.b=t[1],this.c=t[3],this.d=t[4],this.tx=t[2],this.ty=t[5]},t.prototype.set=function(t,e,r,n,i,o){return this.a=t,this.b=e,this.c=r,this.d=n,this.tx=i,this.ty=o,this},t.prototype.toArray=function(t,e){this.array||(this.array=new Float32Array(9));var r=e||this.array;return t?(r[0]=this.a,r[1]=this.b,r[2]=0,r[3]=this.c,r[4]=this.d,r[5]=0,r[6]=this.tx,r[7]=this.ty,r[8]=1):(r[0]=this.a,r[1]=this.c,r[2]=this.tx,r[3]=this.b,r[4]=this.d,r[5]=this.ty,r[6]=0,r[7]=0,r[8]=1),r},t.prototype.apply=function(t,e){e=e||new o.default;var r=t.x,n=t.y;return e.x=this.a*r+this.c*n+this.tx,e.y=this.b*r+this.d*n+this.ty,e},t.prototype.applyInverse=function(t,e){e=e||new o.default;var r=1/(this.a*this.d+this.c*-this.b),n=t.x,i=t.y;return e.x=this.d*r*n+-this.c*r*i+(this.ty*this.c-this.tx*this.d)*r,e.y=this.a*r*i+-this.b*r*n+(-this.ty*this.a+this.tx*this.b)*r,e},t.prototype.translate=function(t,e){return this.tx+=t,this.ty+=e,this},t.prototype.scale=function(t,e){return this.a*=t,this.d*=e,this.c*=t,this.b*=e,this.tx*=t,this.ty*=e,this},t.prototype.rotate=function(t){var e=Math.cos(t),r=Math.sin(t),n=this.a,i=this.c,o=this.tx;return this.a=n*e-this.b*r,this.b=n*r+this.b*e,this.c=i*e-this.d*r,this.d=i*r+this.d*e,this.tx=o*e-this.ty*r,this.ty=o*r+this.ty*e,this},t.prototype.append=function(t){var e=this.a,r=this.b,n=this.c,i=this.d;return this.a=t.a*e+t.b*n,this.b=t.a*r+t.b*i,this.c=t.c*e+t.d*n,this.d=t.c*r+t.d*i,this.tx=t.tx*e+t.ty*n+this.tx,this.ty=t.tx*r+t.ty*i+this.ty,this},t.prototype.setTransform=function(t,e,r,n,i,o,s,a,u){var l=Math.sin(s),h=Math.cos(s),c=Math.cos(u),f=Math.sin(u),p=-Math.sin(a),d=Math.cos(a),g=h*i,v=l*i,m=-l*o,y=h*o;return this.a=c*g+f*m,this.b=c*v+f*y,this.c=p*g+d*m,this.d=p*v+d*y,this.tx=t+(r*g+n*m),this.ty=e+(r*v+n*y),this},t.prototype.prepend=function(t){var e=this.tx;if(1!==t.a||0!==t.b||0!==t.c||1!==t.d){var r=this.a,n=this.c;this.a=r*t.a+this.b*t.c,this.b=r*t.b+this.b*t.d,this.c=n*t.a+this.d*t.c,this.d=n*t.b+this.d*t.d}return this.tx=e*t.a+this.ty*t.c+t.tx,this.ty=e*t.b+this.ty*t.d+t.ty,this},t.prototype.decompose=function(t){var e=this.a,r=this.b,n=this.c,i=this.d,o=-Math.atan2(-n,i),s=Math.atan2(r,e),a=Math.abs(o+s);return a<1e-5?(t.rotation=s,e<0&&i>=0&&(t.rotation+=t.rotation<=0?Math.PI:-Math.PI),t.skew.x=t.skew.y=0):(t.skew.x=o,t.skew.y=s),t.scale.x=Math.sqrt(e*e+r*r),t.scale.y=Math.sqrt(n*n+i*i),t.position.x=this.tx,t.position.y=this.ty,t},t.prototype.invert=function(){var t=this.a,e=this.b,r=this.c,n=this.d,i=this.tx,o=t*n-e*r;return this.a=n/o,this.b=-e/o,this.c=-r/o,this.d=t/o,this.tx=(r*this.ty-n*i)/o,this.ty=-(t*this.ty-e*i)/o,this},t.prototype.identity=function(){return this.a=1,this.b=0,this.c=0,this.d=1,this.tx=0,this.ty=0,this},t.prototype.clone=function(){var e=new t;return e.a=this.a,e.b=this.b,e.c=this.c,e.d=this.d,e.tx=this.tx,e.ty=this.ty,e},t.prototype.copy=function(t){return t.a=this.a,t.b=this.b,t.c=this.c,t.d=this.d,t.tx=this.tx,t.ty=this.ty,t},n(t,null,[{key:"IDENTITY",get:function(){return new t}},{key:"TEMP_MATRIX",get:function(){return new t}}]),t}();r.default=s},{"./Point":67}],66:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(t,e){for(var r=0;r2&&void 0!==arguments[2]?arguments[2]:0,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this._x=n,this._y=i,this.cb=e,this.scope=r}return t.prototype.set=function(t,e){var r=t||0,n=e||(0!==e?r:0);this._x===r&&this._y===n||(this._x=r,this._y=n,this.cb.call(this.scope))},t.prototype.copy=function(t){this._x===t.x&&this._y===t.y||(this._x=t.x,this._y=t.y,this.cb.call(this.scope))},n(t,[{key:"x",get:function(){return this._x},set:function(t){this._x!==t&&(this._x=t,this.cb.call(this.scope))}},{key:"y",get:function(){return this._y},set:function(t){this._y!==t&&(this._y=t,this.cb.call(this.scope))}}]),t}();r.default=i},{}],67:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0;(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.x=e,this.y=r}return t.prototype.clone=function(){return new t(this.x,this.y)},t.prototype.copy=function(t){this.set(t.x,t.y)},t.prototype.equals=function(t){return t.x===this.x&&t.y===this.y},t.prototype.set=function(t,e){this.x=t||0,this.y=e||(0!==e?this.x:0)},t}();r.default=n},{}],68:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0;var i=t("./Point");Object.defineProperty(r,"Point",{enumerable:!0,get:function(){return n(i).default}});var o=t("./ObservablePoint");Object.defineProperty(r,"ObservablePoint",{enumerable:!0,get:function(){return n(o).default}});var s=t("./Matrix");Object.defineProperty(r,"Matrix",{enumerable:!0,get:function(){return n(s).default}});var a=t("./GroupD8");Object.defineProperty(r,"GroupD8",{enumerable:!0,get:function(){return n(a).default}});var u=t("./shapes/Circle");Object.defineProperty(r,"Circle",{enumerable:!0,get:function(){return n(u).default}});var l=t("./shapes/Ellipse");Object.defineProperty(r,"Ellipse",{enumerable:!0,get:function(){return n(l).default}});var h=t("./shapes/Polygon");Object.defineProperty(r,"Polygon",{enumerable:!0,get:function(){return n(h).default}});var c=t("./shapes/Rectangle");Object.defineProperty(r,"Rectangle",{enumerable:!0,get:function(){return n(c).default}});var f=t("./shapes/RoundedRectangle");Object.defineProperty(r,"RoundedRectangle",{enumerable:!0,get:function(){return n(f).default}})},{"./GroupD8":64,"./Matrix":65,"./ObservablePoint":66,"./Point":67,"./shapes/Circle":69,"./shapes/Ellipse":70,"./shapes/Polygon":71,"./shapes/Rectangle":72,"./shapes/RoundedRectangle":73}],69:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("./Rectangle"),i=function(t){return t&&t.__esModule?t:{default:t}}(n),o=t("../../const"),s=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0;(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.x=e,this.y=r,this.radius=n,this.type=o.SHAPES.CIRC}return t.prototype.clone=function(){return new t(this.x,this.y,this.radius)},t.prototype.contains=function(t,e){if(this.radius<=0)return!1;var r=this.radius*this.radius,n=this.x-t,i=this.y-e;return(n*=n)+(i*=i)<=r},t.prototype.getBounds=function(){return new i.default(this.x-this.radius,this.y-this.radius,2*this.radius,2*this.radius)},t}();r.default=s},{"../../const":44,"./Rectangle":72}],70:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("./Rectangle"),i=function(t){return t&&t.__esModule?t:{default:t}}(n),o=t("../../const"),s=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,i=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.x=e,this.y=r,this.width=n,this.height=i,this.type=o.SHAPES.ELIP}return t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height)},t.prototype.contains=function(t,e){if(this.width<=0||this.height<=0)return!1;var r=(t-this.x)/this.width,n=(e-this.y)/this.height;return(r*=r)+(n*=n)<=1},t.prototype.getBounds=function(){return new i.default(this.x-this.width,this.y-this.height,this.width,this.height)},t}();r.default=s},{"../../const":44,"./Rectangle":72}],71:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("../Point"),i=function(t){return t&&t.__esModule?t:{default:t}}(n),o=t("../../const"),s=function(){function t(){for(var e=arguments.length,r=Array(e),n=0;ne!=l>e&&t<(e-a)/(l-a)*(u-s)+s;h&&(r=!r)}return r},t}();r.default=s},{"../../const":44,"../Point":67}],72:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(t,e){for(var r=0;r0&&void 0!==arguments[0]?arguments[0]:0,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,n=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0;(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.x=e,this.y=r,this.width=n,this.height=o,this.type=i.SHAPES.RECT}return t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height)},t.prototype.copy=function(t){return this.x=t.x,this.y=t.y,this.width=t.width,this.height=t.height,this},t.prototype.contains=function(t,e){return!(this.width<=0||this.height<=0)&&t>=this.x&&t=this.y&&et.x+t.width&&(this.width=t.width-this.x,this.width<0&&(this.width=0)),this.y+this.height>t.y+t.height&&(this.height=t.height-this.y,this.height<0&&(this.height=0))},t.prototype.enlarge=function(t){var e=Math.min(this.x,t.x),r=Math.max(this.x+this.width,t.x+t.width),n=Math.min(this.y,t.y),i=Math.max(this.y+this.height,t.y+t.height);this.x=e,this.width=r-e,this.y=n,this.height=i-n},n(t,[{key:"left",get:function(){return this.x}},{key:"right",get:function(){return this.x+this.width}},{key:"top",get:function(){return this.y}},{key:"bottom",get:function(){return this.y+this.height}}],[{key:"EMPTY",get:function(){return new t(0,0,0,0)}}]),t}();r.default=o},{"../../const":44}],73:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("../../const"),i=function(){function t(){var e=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,r=arguments.length>1&&void 0!==arguments[1]?arguments[1]:0,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:0,o=arguments.length>3&&void 0!==arguments[3]?arguments[3]:0,s=arguments.length>4&&void 0!==arguments[4]?arguments[4]:20;(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.x=e,this.y=r,this.width=i,this.height=o,this.radius=s,this.type=n.SHAPES.RREC}return t.prototype.clone=function(){return new t(this.x,this.y,this.width,this.height,this.radius)},t.prototype.contains=function(t,e){if(this.width<=0||this.height<=0)return!1;if(t>=this.x&&t<=this.x+this.width&&e>=this.y&&e<=this.y+this.height){if(e>=this.y+this.radius&&e<=this.y+this.height-this.radius||t>=this.x+this.radius&&t<=this.x+this.width-this.radius)return!0;var r=t-(this.x+this.radius),n=e-(this.y+this.radius),i=this.radius*this.radius;if(r*r+n*n<=i)return!0;if((r=t-(this.x+this.width-this.radius))*r+n*n<=i)return!0;if(n=e-(this.y+this.height-this.radius),r*r+n*n<=i)return!0;if((r=t-(this.x+this.radius))*r+n*n<=i)return!0}return!1},t}();r.default=i},{"../../const":44}],74:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0;var i=function(){function t(t,e){for(var r=0;r2&&void 0!==arguments[2]?arguments[2]:{};!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var o=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,"Canvas",r,n,i));return o.type=p.RENDERER_TYPE.CANVAS,o.rootContext=o.view.getContext("2d",{alpha:o.transparent}),o.refresh=!0,o.maskManager=new a.default(o),o.smoothProperty="imageSmoothingEnabled",o.rootContext.imageSmoothingEnabled||(o.rootContext.webkitImageSmoothingEnabled?o.smoothProperty="webkitImageSmoothingEnabled":o.rootContext.mozImageSmoothingEnabled?o.smoothProperty="mozImageSmoothingEnabled":o.rootContext.oImageSmoothingEnabled?o.smoothProperty="oImageSmoothingEnabled":o.rootContext.msImageSmoothingEnabled&&(o.smoothProperty="msImageSmoothingEnabled")),o.initPlugins(),o.blendModes=(0,c.default)(),o._activeBlendMode=null,o.context=null,o.renderingToScreen=!1,o.resize(r,n),o}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.render=function(t,e,r,n,i){if(this.view){this.renderingToScreen=!e,this.emit("prerender");var o=this.resolution;e?((e=e.baseTexture||e)._canvasRenderTarget||(e._canvasRenderTarget=new l.default(e.width,e.height,e.resolution),e.source=e._canvasRenderTarget.canvas,e.valid=!0),this.context=e._canvasRenderTarget.context,this.resolution=e._canvasRenderTarget.resolution):this.context=this.rootContext;var s=this.context;if(e||(this._lastObjectRendered=t),!i){var a=t.parent,u=this._tempDisplayObjectParent.transform.worldTransform;n?(n.copy(u),this._tempDisplayObjectParent.transform._worldID=-1):u.identity(),t.parent=this._tempDisplayObjectParent,t.updateTransform(),t.parent=a}s.setTransform(1,0,0,1,0,0),s.globalAlpha=1,s.globalCompositeOperation=this.blendModes[p.BLEND_MODES.NORMAL],navigator.isCocoonJS&&this.view.screencanvas&&(s.fillStyle="black",s.clear()),(void 0!==r?r:this.clearBeforeRender)&&this.renderingToScreen&&(this.transparent?s.clearRect(0,0,this.width,this.height):(s.fillStyle=this._backgroundColorString,s.fillRect(0,0,this.width,this.height)));var h=this.context;this.context=s,t.renderCanvas(this),this.context=h,this.resolution=o,this.emit("postrender")}},e.prototype.clear=function(t){var e=this.context;t=t||this._backgroundColorString,!this.transparent&&t?(e.fillStyle=t,e.fillRect(0,0,this.width,this.height)):e.clearRect(0,0,this.width,this.height)},e.prototype.setBlendMode=function(t){this._activeBlendMode!==t&&(this._activeBlendMode=t,this.context.globalCompositeOperation=this.blendModes[t])},e.prototype.destroy=function(e){this.destroyPlugins(),t.prototype.destroy.call(this,e),this.context=null,this.refresh=!0,this.maskManager.destroy(),this.maskManager=null,this.smoothProperty=null},e.prototype.resize=function(e,r){t.prototype.resize.call(this,e,r),this.smoothProperty&&(this.rootContext[this.smoothProperty]=g.default.SCALE_MODE===p.SCALE_MODES.LINEAR)},e}(o.default);r.default=v,f.pluginTarget.mixin(v)},{"../../const":44,"../../settings":99,"../../utils":120,"../SystemRenderer":74,"./utils/CanvasMaskManager":76,"./utils/CanvasRenderTarget":77,"./utils/mapCanvasBlendModesToPixi":79}],76:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("../../../const"),i=function(){function t(e){(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.renderer=e}return t.prototype.pushMask=function(t){var e=this.renderer;e.context.save();var r=t.alpha,n=t.transform.worldTransform,i=e.resolution;e.context.setTransform(n.a*i,n.b*i,n.c*i,n.d*i,n.tx*i,n.ty*i),t._texture||(this.renderGraphicsShape(t),e.context.clip()),t.worldAlpha=r},t.prototype.renderGraphicsShape=function(t){var e=this.renderer.context,r=t.graphicsData.length;if(0!==r){e.beginPath();for(var i=0;iS?S:E,e.moveTo(b,_+E),e.lineTo(b,_+T-E),e.quadraticCurveTo(b,_+T,b+E,_+T),e.lineTo(b+w-E,_+T),e.quadraticCurveTo(b+w,_+T,b+w,_+T-E),e.lineTo(b+w,_+E),e.quadraticCurveTo(b+w,_,b+w-E,_),e.lineTo(b+E,_),e.quadraticCurveTo(b,_,b,_+E),e.closePath()}}}},t.prototype.popMask=function(t){t.context.restore()},t.prototype.destroy=function(){},t}();r.default=i},{"../../../const":44}],77:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(t,e){for(var r=0;r0&&void 0!==arguments[0]?arguments[0]:[];return(0,o.default)()?(t[n.BLEND_MODES.NORMAL]="source-over",t[n.BLEND_MODES.ADD]="lighter",t[n.BLEND_MODES.MULTIPLY]="multiply",t[n.BLEND_MODES.SCREEN]="screen",t[n.BLEND_MODES.OVERLAY]="overlay",t[n.BLEND_MODES.DARKEN]="darken",t[n.BLEND_MODES.LIGHTEN]="lighten",t[n.BLEND_MODES.COLOR_DODGE]="color-dodge",t[n.BLEND_MODES.COLOR_BURN]="color-burn",t[n.BLEND_MODES.HARD_LIGHT]="hard-light",t[n.BLEND_MODES.SOFT_LIGHT]="soft-light",t[n.BLEND_MODES.DIFFERENCE]="difference",t[n.BLEND_MODES.EXCLUSION]="exclusion",t[n.BLEND_MODES.HUE]="hue",t[n.BLEND_MODES.SATURATION]="saturate",t[n.BLEND_MODES.COLOR]="color",t[n.BLEND_MODES.LUMINOSITY]="luminosity"):(t[n.BLEND_MODES.NORMAL]="source-over",t[n.BLEND_MODES.ADD]="lighter",t[n.BLEND_MODES.MULTIPLY]="source-over",t[n.BLEND_MODES.SCREEN]="source-over",t[n.BLEND_MODES.OVERLAY]="source-over",t[n.BLEND_MODES.DARKEN]="source-over",t[n.BLEND_MODES.LIGHTEN]="source-over",t[n.BLEND_MODES.COLOR_DODGE]="source-over",t[n.BLEND_MODES.COLOR_BURN]="source-over",t[n.BLEND_MODES.HARD_LIGHT]="source-over",t[n.BLEND_MODES.SOFT_LIGHT]="source-over",t[n.BLEND_MODES.DIFFERENCE]="source-over",t[n.BLEND_MODES.EXCLUSION]="source-over",t[n.BLEND_MODES.HUE]="source-over",t[n.BLEND_MODES.SATURATION]="source-over",t[n.BLEND_MODES.COLOR]="source-over",t[n.BLEND_MODES.LUMINOSITY]="source-over"),t};var n=t("../../../const"),i=t("./canUseNewCanvasBlendModes"),o=function(t){return t&&t.__esModule?t:{default:t}}(i)},{"../../../const":44,"./canUseNewCanvasBlendModes":78}],80:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("../../const"),i=t("../../settings"),o=function(t){return t&&t.__esModule?t:{default:t}}(i),s=function(){function t(e){(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.renderer=e,this.count=0,this.checkCount=0,this.maxIdle=o.default.GC_MAX_IDLE,this.checkCountMax=o.default.GC_MAX_CHECK_COUNT,this.mode=o.default.GC_MODE}return t.prototype.update=function(){this.count++,this.mode!==n.GC_MODES.MANUAL&&(this.checkCount++,this.checkCount>this.checkCountMax&&(this.checkCount=0,this.run()))},t.prototype.run=function(){for(var t=this.renderer.textureManager,e=t._managedTextures,r=!1,n=0;nthis.maxIdle&&(t.destroyTexture(i,!0),e[n]=null,r=!0)}if(r){for(var o=0,s=0;s=0;r--)this.unload(t.children[r])},t}();r.default=s},{"../../const":44,"../../settings":99}],81:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("pixi-gl-core"),i=t("../../const"),o=t("./utils/RenderTarget"),s=function(t){return t&&t.__esModule?t:{default:t}}(o),a=t("../../utils"),u=function(){function t(e){(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.renderer=e,this.gl=e.gl,this._managedTextures=[]}return t.prototype.bindTexture=function(){},t.prototype.getTexture=function(){},t.prototype.updateTexture=function(t,e){var r=this.gl,o=!!t._glRenderTargets;if(!t.hasLoaded)return null;var a=this.renderer.boundTextures;if(void 0===e){e=0;for(var u=0;u2&&void 0!==arguments[2]?arguments[2]:{};!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var o=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,"WebGL",r,n,i));return o.legacy=!!i.legacy,o.legacy&&(O.default.VertexArrayObject.FORCE_NATIVE=!0),o.type=P.RENDERER_TYPE.WEBGL,o.handleContextLost=o.handleContextLost.bind(o),o.handleContextRestored=o.handleContextRestored.bind(o),o.view.addEventListener("webglcontextlost",o.handleContextLost,!1),o.view.addEventListener("webglcontextrestored",o.handleContextRestored,!1),o._contextOptions={alpha:o.transparent,antialias:i.antialias,premultipliedAlpha:o.transparent&&"notMultiplied"!==o.transparent,stencil:!0,preserveDrawingBuffer:i.preserveDrawingBuffer},o._backgroundColorRgba[3]=o.transparent?0:1,o.maskManager=new a.default(o),o.stencilManager=new l.default(o),o.emptyRenderer=new g.default(o),o.currentRenderer=o.emptyRenderer,o.initPlugins(),i.context&&(0,C.default)(i.context),o.gl=i.context||O.default.createContext(o.view,o._contextOptions),o.CONTEXT_UID=D++,o.state=new T.default(o.gl),o.renderingToScreen=!0,o.boundTextures=null,o._activeShader=null,o._activeVao=null,o._activeRenderTarget=null,o._initContext(),o.filterManager=new c.default(o),o.drawModes=(0,S.default)(o.gl),o._nextTextureLocation=0,o.setBlendMode(0),o}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype._initContext=function(){var t=this.gl;t.isContextLost()&&t.getExtension("WEBGL_lose_context")&&t.getExtension("WEBGL_lose_context").restoreContext();var e=t.getParameter(t.MAX_TEXTURE_IMAGE_UNITS);this.boundTextures=new Array(e),this.emptyTextures=new Array(e),this.textureManager=new m.default(this),this.textureGC=new _.default(this),this.state.resetToDefault(),this.rootRenderTarget=new p.default(t,this.width,this.height,null,this.resolution,!0),this.rootRenderTarget.clearColor=this._backgroundColorRgba,this.bindRenderTarget(this.rootRenderTarget);var r=new O.default.GLTexture.fromData(t,null,1,1),n={_glTextures:{}};n._glTextures[this.CONTEXT_UID]={};for(var i=0;i 0.5)"," {"," color = vec4(1.0, 0.0, 0.0, 1.0);"," }"," else"," {"," color = vec4(0.0, 1.0, 0.0, 1.0);"," }"," gl_FragColor = mix(sample, masky, 0.5);"," gl_FragColor *= sample.a;","}"].join("\n")}}]),t}();r.default=f},{"../../../const":44,"../../../settings":99,"../../../utils":120,"./extractUniformsFromSrc":85}],85:[function(t,e,r){"use strict";function n(t){for(var e=new RegExp("^(projectionMatrix|uSampler|filterArea|filterClamp)$"),r={},n=void 0,i=t.replace(/\s+/g," ").split(/\s*;\s*/),o=0;o-1){var u=a.split(" "),l=u[1],h=u[2],c=1;h.indexOf("[")>-1&&(n=h.split(/\[|]/),h=n[0],c*=Number(n[1])),h.match(e)||(r[h]={value:s(l,c),name:h,type:l})}}return r}r.__esModule=!0,r.default=function(t,e,r){var i=n(t),o=n(e);return Object.assign(i,o)};var i=t("pixi-gl-core"),o=function(t){return t&&t.__esModule?t:{default:t}}(i),s=o.default.shader.defaultValue},{"pixi-gl-core":12}],86:[function(t,e,r){"use strict";r.__esModule=!0,r.calculateScreenSpaceMatrix=function(t,e,r){var n=t.identity();return n.translate(e.x/r.width,e.y/r.height),n.scale(r.width,r.height),n},r.calculateNormalizedScreenSpaceMatrix=function(t,e,r){var n=t.identity();n.translate(e.x/r.width,e.y/r.height);var i=r.width/e.width,o=r.height/e.height;return n.scale(i,o),n},r.calculateSpriteMatrix=function(t,e,r,i){var o=i.worldTransform.copy(n.Matrix.TEMP_MATRIX),s=i._texture.baseTexture,a=t.identity(),u=r.height/r.width;a.translate(e.x/r.width,e.y/r.height),a.scale(1,u);var l=r.width/s.width,h=r.height/s.height;return o.tx/=s.width*l,o.ty/=s.width*l,o.invert(),a.prepend(o),a.scale(1,1/u),a.scale(l,h),a.translate(i.anchor.x,i.anchor.y),a};var n=t("../../../math")},{"../../../math":68}],87:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("../Filter"),i=function(t){return t&&t.__esModule?t:{default:t}}(n),o=t("../../../../math"),s=(t("path"),function(t){function e(r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var n=new o.Matrix,i=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,"attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 otherMatrix;\n\nvarying vec2 vMaskCoord;\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = aTextureCoord;\n vMaskCoord = ( otherMatrix * vec3( aTextureCoord, 1.0) ).xy;\n}\n","varying vec2 vMaskCoord;\nvarying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform float alpha;\nuniform sampler2D mask;\n\nvoid main(void)\n{\n // check clip! this will stop the mask bleeding out from the edges\n vec2 text = abs( vMaskCoord - 0.5 );\n text = step(0.5, text);\n\n float clip = 1.0 - max(text.y, text.x);\n vec4 original = texture2D(uSampler, vTextureCoord);\n vec4 masky = texture2D(mask, vMaskCoord);\n\n original *= (masky.r * masky.a * alpha * clip);\n\n gl_FragColor = original;\n}\n"));return r.renderable=!1,i.maskSprite=r,i.maskMatrix=n,i}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.apply=function(t,e,r){var n=this.maskSprite;this.uniforms.mask=n._texture,this.uniforms.otherMatrix=t.calculateSpriteMatrix(this.maskMatrix,n),this.uniforms.alpha=n.worldAlpha,t.applyFilter(this,e,r)},e}(i.default));r.default=s},{"../../../../math":68,"../Filter":84,path:22}],88:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}function i(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}r.__esModule=!0;var o=t("./WebGLManager"),s=n(o),a=t("../utils/RenderTarget"),u=n(a),l=t("../utils/Quad"),h=n(l),c=t("../../../math"),f=t("../../../Shader"),p=n(f),d=t("../filters/filterTransforms"),g=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}(d),v=t("bit-twiddle"),m=n(v),y=function t(){i(this,t),this.renderTarget=null,this.sourceFrame=new c.Rectangle,this.destinationFrame=new c.Rectangle,this.filters=[],this.target=null,this.resolution=1},x=function(t){function e(r){i(this,e);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,r));return n.gl=n.renderer.gl,n.quad=new h.default(n.gl,r.state.attribState),n.shaderCache={},n.pool={},n.filterData=null,n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.pushFilter=function(t,e){var r=this.renderer,n=this.filterData;if(!n){n=this.renderer._activeRenderTarget.filterStack;var i=new y;i.sourceFrame=i.destinationFrame=this.renderer._activeRenderTarget.size,i.renderTarget=r._activeRenderTarget,this.renderer._activeRenderTarget.filterData=n={index:0,stack:[i]},this.filterData=n}var o=n.stack[++n.index];o||(o=n.stack[n.index]=new y);var s=e[0].resolution,a=0|e[0].padding,u=t.filterArea||t.getBounds(!0),l=o.sourceFrame,h=o.destinationFrame;l.x=(u.x*s|0)/s,l.y=(u.y*s|0)/s,l.width=(u.width*s|0)/s,l.height=(u.height*s|0)/s,n.stack[0].renderTarget.transform||l.fit(n.stack[0].destinationFrame),l.pad(a),h.width=l.width,h.height=l.height;var c=this.getPotRenderTarget(r.gl,l.width,l.height,s);o.target=t,o.filters=e,o.resolution=s,o.renderTarget=c,c.setFrame(h,l),r.bindRenderTarget(c),c.clear()},e.prototype.popFilter=function(){var t=this.filterData,e=t.stack[t.index-1],r=t.stack[t.index];this.quad.map(r.renderTarget.size,r.sourceFrame).upload();var n=r.filters;if(1===n.length)n[0].apply(this,r.renderTarget,e.renderTarget,!1,r),this.freePotRenderTarget(r.renderTarget);else{var i=r.renderTarget,o=this.getPotRenderTarget(this.renderer.gl,r.sourceFrame.width,r.sourceFrame.height,r.resolution);o.setFrame(r.destinationFrame,r.sourceFrame),o.clear();var s=0;for(s=0;s0&&(e+="\nelse "),r1&&void 0!==arguments[1]?arguments[1]:[];return e[n.BLEND_MODES.NORMAL]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.ADD]=[t.ONE,t.DST_ALPHA],e[n.BLEND_MODES.MULTIPLY]=[t.DST_COLOR,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.SCREEN]=[t.ONE,t.ONE_MINUS_SRC_COLOR],e[n.BLEND_MODES.OVERLAY]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.DARKEN]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.LIGHTEN]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.COLOR_DODGE]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.COLOR_BURN]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.HARD_LIGHT]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.SOFT_LIGHT]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.DIFFERENCE]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.EXCLUSION]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.HUE]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.SATURATION]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.COLOR]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e[n.BLEND_MODES.LUMINOSITY]=[t.ONE,t.ONE_MINUS_SRC_ALPHA],e};var n=t("../../../const")},{"../../../const":44}],97:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t){var e=arguments.length>1&&void 0!==arguments[1]?arguments[1]:{};return e[n.DRAW_MODES.POINTS]=t.POINTS,e[n.DRAW_MODES.LINES]=t.LINES,e[n.DRAW_MODES.LINE_LOOP]=t.LINE_LOOP,e[n.DRAW_MODES.LINE_STRIP]=t.LINE_STRIP,e[n.DRAW_MODES.TRIANGLES]=t.TRIANGLES,e[n.DRAW_MODES.TRIANGLE_STRIP]=t.TRIANGLE_STRIP,e[n.DRAW_MODES.TRIANGLE_FAN]=t.TRIANGLE_FAN,e};var n=t("../../../const")},{"../../../const":44}],98:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t){t.getContextAttributes().stencil||console.warn("Provided WebGL context does not have a stencil buffer, masks may not render correctly")}},{}],99:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0;var i=t("./utils/maxRecommendedTextures"),o=n(i),s=t("./utils/canUploadSameBuffer"),a=n(s);r.default={TARGET_FPMS:.06,MIPMAP_TEXTURES:!0,RESOLUTION:1,FILTER_RESOLUTION:1,SPRITE_MAX_TEXTURES:(0,o.default)(32),SPRITE_BATCH_SIZE:4096,RETINA_PREFIX:/@([0-9\.]+)x/,RENDER_OPTIONS:{view:null,antialias:!1,forceFXAA:!1,autoResize:!1,transparent:!1,backgroundColor:0,clearBeforeRender:!0,preserveDrawingBuffer:!1,roundPixels:!1},TRANSFORM_MODE:0,GC_MODE:0,GC_MAX_IDLE:3600,GC_MAX_CHECK_COUNT:600,WRAP_MODE:0,SCALE_MODE:0,PRECISION_VERTEX:"highp",PRECISION_FRAGMENT:"mediump",CAN_UPLOAD_SAME_BUFFER:(0,a.default)()}},{"./utils/canUploadSameBuffer":117,"./utils/maxRecommendedTextures":121}],100:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0;var i=function(){function t(t,e){for(var r=0;rn&&f.xi&&f.y>16)+(65280&t)+((255&t)<<16)}},{key:"texture",get:function(){return this._texture},set:function(t){this._texture!==t&&(this._texture=t,this.cachedTint=16777215,this._textureID=-1,this._textureTrimmedID=-1,t&&(t.baseTexture.hasLoaded?this._onTextureUpdate():t.once("update",this._onTextureUpdate,this)))}}]),e}(c.default);r.default=p},{"../const":44,"../display/Container":46,"../math":68,"../textures/Texture":112,"../utils":120}],101:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0;var i=t("../../renderers/canvas/CanvasRenderer"),o=n(i),s=t("../../const"),a=t("../../math"),u=t("./CanvasTinter"),l=n(u),h=new a.Matrix,c=function(){function t(e){(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.renderer=e}return t.prototype.render=function(t){var e=t._texture,r=this.renderer,n=e._frame.width,i=e._frame.height,o=t.transform.worldTransform,u=0,c=0;if(!(e.orig.width<=0||e.orig.height<=0)&&e.baseTexture.source&&(r.setBlendMode(t.blendMode),e.valid)){r.context.globalAlpha=t.worldAlpha;var f=e.baseTexture.scaleMode===s.SCALE_MODES.LINEAR;r.smoothProperty&&r.context[r.smoothProperty]!==f&&(r.context[r.smoothProperty]=f),e.trim?(u=e.trim.width/2+e.trim.x-t.anchor.x*e.orig.width,c=e.trim.height/2+e.trim.y-t.anchor.y*e.orig.height):(u=(.5-t.anchor.x)*e.orig.width,c=(.5-t.anchor.y)*e.orig.height),e.rotate&&(o.copy(h),o=h,a.GroupD8.matrixAppendRotationInv(o,e.rotate,u,c),u=0,c=0),u-=n/2,c-=i/2,r.roundPixels?(r.context.setTransform(o.a,o.b,o.c,o.d,o.tx*r.resolution|0,o.ty*r.resolution|0),u|=0,c|=0):r.context.setTransform(o.a,o.b,o.c,o.d,o.tx*r.resolution,o.ty*r.resolution);var p=e.baseTexture.resolution;16777215!==t.tint?(t.cachedTint!==t.tint&&(t.cachedTint=t.tint,t.tintedTexture=l.default.getTintedTexture(t,t.tint)),r.context.drawImage(t.tintedTexture,0,0,n*p,i*p,u*r.resolution,c*r.resolution,n*r.resolution,i*r.resolution)):r.context.drawImage(e.baseTexture.source,e._frame.x*p,e._frame.y*p,n*p,i*p,u*r.resolution,c*r.resolution,n*r.resolution,i*r.resolution)}},t.prototype.destroy=function(){this.renderer=null},t}();r.default=c,o.default.registerPlugin("sprite",c)},{"../../const":44,"../../math":68,"../../renderers/canvas/CanvasRenderer":75,"./CanvasTinter":102}],102:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("../../utils"),i=t("../../renderers/canvas/utils/canUseNewCanvasBlendModes"),o=function(t){return t&&t.__esModule?t:{default:t}}(i),s={getTintedTexture:function(t,e){var r=t.texture,n="#"+("00000"+(0|(e=s.roundColor(e))).toString(16)).substr(-6);if(r.tintCache=r.tintCache||{},r.tintCache[n])return r.tintCache[n];var i=s.canvas||document.createElement("canvas");if(s.tintMethod(r,e,i),s.convertTintToImage){var o=new Image;o.src=i.toDataURL(),r.tintCache[n]=o}else r.tintCache[n]=i,s.canvas=null;return i},tintWithMultiply:function(t,e,r){var n=r.getContext("2d"),i=t._frame.clone(),o=t.baseTexture.resolution;i.x*=o,i.y*=o,i.width*=o,i.height*=o,r.width=Math.ceil(i.width),r.height=Math.ceil(i.height),n.fillStyle="#"+("00000"+(0|e).toString(16)).substr(-6),n.fillRect(0,0,i.width,i.height),n.globalCompositeOperation="multiply",n.drawImage(t.baseTexture.source,i.x,i.y,i.width,i.height,0,0,i.width,i.height),n.globalCompositeOperation="destination-atop",n.drawImage(t.baseTexture.source,i.x,i.y,i.width,i.height,0,0,i.width,i.height)},tintWithOverlay:function(t,e,r){var n=r.getContext("2d"),i=t._frame.clone(),o=t.baseTexture.resolution;i.x*=o,i.y*=o,i.width*=o,i.height*=o,r.width=Math.ceil(i.width),r.height=Math.ceil(i.height),n.globalCompositeOperation="copy",n.fillStyle="#"+("00000"+(0|e).toString(16)).substr(-6),n.fillRect(0,0,i.width,i.height),n.globalCompositeOperation="destination-atop",n.drawImage(t.baseTexture.source,i.x,i.y,i.width,i.height,0,0,i.width,i.height)},tintWithPerPixel:function(t,e,r){var i=r.getContext("2d"),o=t._frame.clone(),s=t.baseTexture.resolution;o.x*=s,o.y*=s,o.width*=s,o.height*=s,r.width=Math.ceil(o.width),r.height=Math.ceil(o.height),i.globalCompositeOperation="copy",i.drawImage(t.baseTexture.source,o.x,o.y,o.width,o.height,0,0,o.width,o.height);for(var a=(0,n.hex2rgb)(e),u=a[0],l=a[1],h=a[2],c=i.getImageData(0,0,o.width,o.height),f=c.data,p=0;p=this.size&&this.flush(),t._texture._uvs&&(this.sprites[this.currentIndex++]=t)},e.prototype.flush=function(){if(0!==this.currentIndex){var t=this.renderer.gl,e=this.MAX_TEXTURES,r=_.default.nextPow2(this.currentIndex),n=_.default.log2(r),i=this.buffers[n],o=this.sprites,s=this.groups,a=i.float32View,u=i.uint32View,l=this.boundTextures,h=this.renderer.boundTextures,c=this.renderer.textureGC.count,f=0,p=void 0,d=void 0,g=1,v=0,y=s[0],b=void 0,E=void 0,S=o[0].blendMode;y.textureCount=0,y.start=0,y.blend=S,w++;var A=void 0;for(A=0;A0&&(e+="\nelse "),r0?this.context.shadowColor=r.dropShadowColor:this.context.fillStyle=r.dropShadowColor;for(var g=Math.cos(r.dropShadowAngle)*r.dropShadowDistance,v=Math.sin(r.dropShadowAngle)*r.dropShadowDistance,m=0;m3&&void 0!==arguments[3]&&arguments[3],i=this._style,o=i.letterSpacing;if(0!==o)for(var s=String.prototype.split.call(t,""),a=e,u=0,l="";ui)for(var h=a[u].split(""),c=0;cs?(e+="\n"+h[c],s=i-f):(0===c&&(e+=" "),e+=h[c],s-=f)}else{var p=l+this.context.measureText(" ").width;0===u||p>s?(u>0&&(e+="\n"),e+=a[u],s=i-l):(s-=p,e+=" "+a[u])}}o=0;n--){var i=r[n].trim();/([\"\'])[^\'\"]+\1/.test(i)||(i='"'+i+'"'),r[n]=i}return t.fontStyle+" "+t.fontVariant+" "+t.fontWeight+" "+e+" "+r.join(",")},e.calculateFontProperties=function(t){if(e.fontPropertiesCache[t])return e.fontPropertiesCache[t];var r={},n=e.fontPropertiesCanvas,i=e.fontPropertiesContext;i.font=t;var o=Math.ceil(i.measureText("|MÉq").width),s=Math.ceil(i.measureText("M").width),a=2*s;s=1.4*s|0,n.width=o,n.height=a,i.fillStyle="#f00",i.fillRect(0,0,o,a),i.font=t,i.textBaseline="alphabetic",i.fillStyle="#000",i.fillText("|MÉq",0,s);var u=i.getImageData(0,0,o,a).data,l=u.length,h=4*o,c=0,f=0,p=!1;for(c=0;cs;--c){for(var g=0;g0&&void 0!==arguments[0]?arguments[0]:100,n=arguments.length>1&&void 0!==arguments[1]?arguments[1]:100,i=arguments[2],o=arguments[3];!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var s=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,null,i));return s.resolution=o||a.default.RESOLUTION,s.width=r,s.height=n,s.realWidth=s.width*s.resolution,s.realHeight=s.height*s.resolution,s.scaleMode=void 0!==i?i:a.default.SCALE_MODE,s.hasLoaded=!0,s._glRenderTargets={},s._canvasRenderTarget=null,s.valid=!1,s}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.resize=function(t,e){t===this.width&&e===this.height||(this.valid=t>0&&e>0,this.width=t,this.height=e,this.realWidth=this.width*this.resolution,this.realHeight=this.height*this.resolution,this.valid&&this.emit("update",this))},e.prototype.destroy=function(){t.prototype.destroy.call(this,!0),this.renderer=null},e}(o.default);r.default=u},{"../settings":99,"./BaseTexture":109}],109:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0;var i="function"==typeof Symbol&&"symbol"==typeof Symbol.iterator?function(t){return typeof t}:function(t){return t&&"function"==typeof Symbol&&t.constructor===Symbol&&t!==Symbol.prototype?"symbol":typeof t},o=t("../utils"),s=t("../settings"),a=n(s),u=t("eventemitter3"),l=n(u),h=t("../utils/determineCrossOrigin"),c=n(h),f=t("bit-twiddle"),p=n(f),d=function(t){function e(r,n,i){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var s=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this));return s.uid=(0,o.uid)(),s.touched=0,s.resolution=i||a.default.RESOLUTION,s.width=100,s.height=100,s.realWidth=100,s.realHeight=100,s.scaleMode=void 0!==n?n:a.default.SCALE_MODE,s.hasLoaded=!1,s.isLoading=!1,s.source=null,s.origSource=null,s.imageType=null,s.sourceScale=1,s.premultipliedAlpha=!0,s.imageUrl=null,s.isPowerOfTwo=!1,s.mipmap=a.default.MIPMAP_TEXTURES,s.wrapMode=a.default.WRAP_MODE,s._glTextures={},s._enabled=0,s._virtalBoundId=-1,r&&s.loadSource(r),s._destroyed=!1,s}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.update=function(){"svg"!==this.imageType&&(this.realWidth=this.source.naturalWidth||this.source.videoWidth||this.source.width,this.realHeight=this.source.naturalHeight||this.source.videoHeight||this.source.height,this._updateDimensions()),this.emit("update",this)},e.prototype._updateDimensions=function(){this.width=this.realWidth/this.resolution,this.height=this.realHeight/this.resolution,this.isPowerOfTwo=p.default.isPow2(this.realWidth)&&p.default.isPow2(this.realHeight)},e.prototype.loadSource=function(t){var e=this,r=this.isLoading;this.hasLoaded=!1,this.isLoading=!1,r&&this.source&&(this.source.onload=null,this.source.onerror=null);var n=!this.source;if(this.source=t,(t.src&&t.complete||t.getContext)&&t.width&&t.height)this._updateImageType(),"svg"===this.imageType?this._loadSvgSource():this._sourceLoaded(),n&&this.emit("loaded",this);else if(!t.getContext){var o=function(){e.isLoading=!0;var n=e;if(t.onload=function(){if(n._updateImageType(),t.onload=null,t.onerror=null,n.isLoading)return n.isLoading=!1,n._sourceLoaded(),"svg"===n.imageType?void n._loadSvgSource():void n.emit("loaded",n)},t.onerror=function(){t.onload=null,t.onerror=null,n.isLoading&&(n.isLoading=!1,n.emit("error",n))},t.complete&&t.src){if(t.onload=null,t.onerror=null,"svg"===n.imageType)return n._loadSvgSource(),{v:void 0};e.isLoading=!1,t.width&&t.height?(e._sourceLoaded(),r&&e.emit("loaded",e)):r&&e.emit("error",e)}}();if("object"===(void 0===o?"undefined":i(o)))return o.v}},e.prototype._updateImageType=function(){if(this.imageUrl){var t=(0,o.decomposeDataUri)(this.imageUrl),e=void 0;if(t&&"image"===t.mediaType){var r=t.subType.split("+")[0];if(!(e=(0,o.getUrlFileExtension)("."+r)))throw new Error("Invalid image type in data URI.")}else(e=(0,o.getUrlFileExtension)(this.imageUrl))||(e="png");this.imageType=e}},e.prototype._loadSvgSource=function(){if("svg"===this.imageType){var t=(0,o.decomposeDataUri)(this.imageUrl);t?this._loadSvgSourceUsingDataUri(t):this._loadSvgSourceUsingXhr()}},e.prototype._loadSvgSourceUsingDataUri=function(t){var e=void 0;if("base64"===t.encoding){if(!atob)throw new Error("Your browser doesn't support base64 conversions.");e=atob(t.data)}else e=t.data;this._loadSvgSourceUsingString(e)},e.prototype._loadSvgSourceUsingXhr=function(){var t=this,e=new XMLHttpRequest;e.onload=function(){if(e.readyState!==e.DONE||200!==e.status)throw new Error("Failed to load SVG using XHR.");t._loadSvgSourceUsingString(e.response)},e.onerror=function(){return t.emit("error",t)},e.open("GET",this.imageUrl,!0),e.send()},e.prototype._loadSvgSourceUsingString=function(t){var e=(0,o.getSvgSize)(t),r=e.width,n=e.height;if(!r||!n)throw new Error("The SVG image must have width and height defined (in pixels), canvas API needs them.");this.realWidth=Math.round(r*this.sourceScale),this.realHeight=Math.round(n*this.sourceScale),this._updateDimensions();var i=document.createElement("canvas");i.width=this.realWidth,i.height=this.realHeight,i._pixiId="canvas_"+(0,o.uid)(),i.getContext("2d").drawImage(this.source,0,0,r,n,0,0,this.realWidth,this.realHeight),this.origSource=this.source,this.source=i,o.BaseTextureCache[i._pixiId]=this,this.isLoading=!1,this._sourceLoaded(),this.emit("loaded",this)},e.prototype._sourceLoaded=function(){this.hasLoaded=!0,this.update()},e.prototype.destroy=function(){this.imageUrl&&(delete o.BaseTextureCache[this.imageUrl],delete o.TextureCache[this.imageUrl],this.imageUrl=null,navigator.isCocoonJS||(this.source.src="")),this.source&&this.source._pixiId&&delete o.BaseTextureCache[this.source._pixiId],this.source=null,this.dispose(),this._destroyed=!0},e.prototype.dispose=function(){this.emit("dispose",this)},e.prototype.updateSourceImage=function(t){this.source.src=t,this.loadSource(this.source)},e.fromImage=function(t,r,n,i){var s=o.BaseTextureCache[t];if(!s){var a=new Image;void 0===r&&0!==t.indexOf("data:")&&(a.crossOrigin=(0,c.default)(t)),(s=new e(a,n)).imageUrl=t,i&&(s.sourceScale=i),s.resolution=(0,o.getResolutionOfUrl)(t),a.src=t,o.BaseTextureCache[t]=s}return s},e.fromCanvas=function(t,r){t._pixiId||(t._pixiId="canvas_"+(0,o.uid)());var n=o.BaseTextureCache[t._pixiId];return n||(n=new e(t,r),o.BaseTextureCache[t._pixiId]=n),n},e.from=function(t,r,n){if("string"==typeof t)return e.fromImage(t,void 0,r,n);if(t instanceof HTMLImageElement){var i=t.src,s=o.BaseTextureCache[i];return s||((s=new e(t,r)).imageUrl=i,n&&(s.sourceScale=n),s.resolution=(0,o.getResolutionOfUrl)(i),o.BaseTextureCache[i]=s),s}return t instanceof HTMLCanvasElement?e.fromCanvas(t,r):t},e}(l.default);r.default=d},{"../settings":99,"../utils":120,"../utils/determineCrossOrigin":119,"bit-twiddle":1,eventemitter3:3}],110:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0;var i=t("./BaseRenderTexture"),o=n(i),s=t("./Texture"),a=n(s),u=function(t){function e(r,n){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var i=null;if(!(r instanceof o.default)){var s=arguments[1],a=arguments[2],u=arguments[3],l=arguments[4];console.warn("Please use RenderTexture.create("+s+", "+a+") instead of the ctor directly."),i=arguments[0],n=null,r=new o.default(s,a,u,l)}var h=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,r,n));return h.legacyRenderer=i,h.valid=!0,h._updateUvs(),h}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.resize=function(t,e,r){this.valid=t>0&&e>0,this._frame.width=this.orig.width=t,this._frame.height=this.orig.height=e,r||this.baseTexture.resize(t,e),this._updateUvs()},e.create=function(t,r,n,i){return new e(new o.default(t,r,n,i))},e}(a.default);r.default=u},{"./BaseRenderTexture":108,"./Texture":112}],111:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(t,e){for(var r=0;r2&&void 0!==arguments[2]?arguments[2]:null;(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.baseTexture=e,this.textures={},this.data=r,this.resolution=this._updateResolution(n||this.baseTexture.imageUrl),this._frames=this.data.frames,this._frameKeys=Object.keys(this._frames),this._batchIndex=0,this._callback=null}return n(t,null,[{key:"BATCH_SIZE",get:function(){return 1e3}}]),t.prototype._updateResolution=function(t){var e=this.data.meta.scale,r=(0,o.getResolutionOfUrl)(t,null);return null===r&&(r=void 0!==e?parseFloat(e):1),1!==r&&(this.baseTexture.resolution=r,this.baseTexture.update()),r},t.prototype.parse=function(e){this._batchIndex=0,this._callback=e,this._frameKeys.length<=t.BATCH_SIZE?(this._processFrames(0),this._parseComplete()):this._nextBatch()},t.prototype._processFrames=function(e){for(var r=e,n=t.BATCH_SIZE;r-e0&&void 0!==arguments[0]&&arguments[0];for(var e in this.textures)this.textures[e].destroy();this._frames=null,this._frameKeys=null,this.data=null,this.textures=null,t&&this.baseTexture.destroy(),this.baseTexture=null},t}();r.default=s},{"../":63,"../utils":120}],112:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}function i(t){t.destroy=function(){},t.on=function(){},t.once=function(){},t.emit=function(){}}r.__esModule=!0;var o=function(){function t(t,e){for(var r=0;rthis.baseTexture.width||t.y+t.height>this.baseTexture.height)throw new Error("Texture Error: frame does not fit inside the base Texture dimensions: X: "+t.x+" + "+t.width+" > "+this.baseTexture.width+" Y: "+t.y+" + "+t.height+" > "+this.baseTexture.height);this.valid=t&&t.width&&t.height&&this.baseTexture.hasLoaded,this.trim||this.rotate||(this.orig=t),this.valid&&this._updateUvs()}},{key:"rotate",get:function(){return this._rotate},set:function(t){this._rotate=t,this.valid&&this._updateUvs()}},{key:"width",get:function(){return this.orig.width}},{key:"height",get:function(){return this.orig.height}}]),e}(p.default);r.default=v,v.EMPTY=new v(new a.default),i(v.EMPTY),v.WHITE=function(){var t=document.createElement("canvas");t.width=10,t.height=10;var e=t.getContext("2d");return e.fillStyle="white",e.fillRect(0,0,10,10),new v(new a.default(t))}(),i(v.WHITE)},{"../math":68,"../utils":120,"./BaseTexture":109,"./TextureUvs":113,"./VideoBaseTexture":114,eventemitter3:3}],113:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("../math/GroupD8"),i=function(t){return t&&t.__esModule?t:{default:t}}(n),o=function(){function t(){(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.x0=0,this.y0=0,this.x1=1,this.y1=0,this.x2=1,this.y2=1,this.x3=0,this.y3=1,this.uvsUint32=new Uint32Array(4)}return t.prototype.set=function(t,e,r){var n=e.width,o=e.height;if(r){var s=t.width/2/n,a=t.height/2/o,u=t.x/n+s,l=t.y/o+a;r=i.default.add(r,i.default.NW),this.x0=u+s*i.default.uX(r),this.y0=l+a*i.default.uY(r),r=i.default.add(r,2),this.x1=u+s*i.default.uX(r),this.y1=l+a*i.default.uY(r),r=i.default.add(r,2),this.x2=u+s*i.default.uX(r),this.y2=l+a*i.default.uY(r),r=i.default.add(r,2),this.x3=u+s*i.default.uX(r),this.y3=l+a*i.default.uY(r)}else this.x0=t.x/n,this.y0=t.y/o,this.x1=(t.x+t.width)/n,this.y1=t.y/o,this.x2=(t.x+t.width)/n,this.y2=(t.y+t.height)/o,this.x3=t.x/n,this.y3=(t.y+t.height)/o;this.uvsUint32[0]=(65535*this.y0&65535)<<16|65535*this.x0&65535,this.uvsUint32[1]=(65535*this.y1&65535)<<16|65535*this.x1&65535,this.uvsUint32[2]=(65535*this.y2&65535)<<16|65535*this.x2&65535,this.uvsUint32[3]=(65535*this.y3&65535)<<16|65535*this.x3&65535},t}();r.default=o},{"../math/GroupD8":64}],114:[function(t,e,r){"use strict";function n(t,e){e||(e="video/"+t.substr(t.lastIndexOf(".")+1));var r=document.createElement("source");return r.src=t,r.type=e,r}r.__esModule=!0;var i=function(){function t(t,e){for(var r=0;r0&&!1===t.paused&&!1===t.ended&&t.readyState>2},e.prototype._isSourceReady=function(){return 3===this.source.readyState||4===this.source.readyState},e.prototype._onPlayStart=function(){this.hasLoaded||this._onCanPlay(),!this._isAutoUpdating&&this.autoUpdate&&(l.shared.add(this.update,this),this._isAutoUpdating=!0)},e.prototype._onPlayStop=function(){this._isAutoUpdating&&(l.shared.remove(this.update,this),this._isAutoUpdating=!1)},e.prototype._onCanPlay=function(){this.hasLoaded=!0,this.source&&(this.source.removeEventListener("canplay",this._onCanPlay),this.source.removeEventListener("canplaythrough",this._onCanPlay),this.width=this.source.videoWidth,this.height=this.source.videoHeight,this.__loaded||(this.__loaded=!0,this.emit("loaded",this)),this._isSourcePlaying()?this._onPlayStart():this.autoPlay&&this.source.play())},e.prototype.destroy=function(){this._isAutoUpdating&&l.shared.remove(this.update,this),this.source&&this.source._pixiId&&(delete a.BaseTextureCache[this.source._pixiId],delete this.source._pixiId),t.prototype.destroy.call(this)},e.fromVideo=function(t,r){t._pixiId||(t._pixiId="video_"+(0,a.uid)());var n=a.BaseTextureCache[t._pixiId];return n||(n=new e(t,r),a.BaseTextureCache[t._pixiId]=n),n},e.fromUrl=function(t,r){var i=document.createElement("video");if(i.setAttribute("webkit-playsinline",""),i.setAttribute("playsinline",""),Array.isArray(t))for(var o=0;o0&&void 0!==arguments[0]?arguments[0]:performance.now(),e=void 0;t>this.lastTime?((e=this.elapsedMS=t-this.lastTime)>this._maxElapsedMS&&(e=this._maxElapsedMS),this.deltaTime=e*s.default.TARGET_FPMS*this.speed,this._emitter.emit(l,this.deltaTime)):this.deltaTime=this.elapsedMS=0,this.lastTime=t},i(t,[{key:"FPS",get:function(){return 1e3/this.elapsedMS}},{key:"minFPS",get:function(){return 1e3/this._maxElapsedMS},set:function(t){var e=Math.min(Math.max(0,t)/1e3,s.default.TARGET_FPMS);this._maxElapsedMS=1/e}}]),t}();r.default=h},{"../settings":99,eventemitter3:3}],116:[function(t,e,r){"use strict";r.__esModule=!0,r.Ticker=r.shared=void 0;var n=t("./Ticker"),i=function(t){return t&&t.__esModule?t:{default:t}}(n),o=new i.default;o.autoStart=!0,r.shared=o,r.Ticker=i.default},{"./Ticker":115}],117:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(){return!(navigator.platform&&/iPad|iPhone|iPod/.test(navigator.platform))}},{}],118:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t){for(var e=6*t,r=new Uint16Array(e),n=0,i=0;n1&&void 0!==arguments[1]?arguments[1]:window.location;if(0===t.indexOf("data:"))return"";e=e||window.location,o||(o=document.createElement("a")),o.href=t;var r=!(t=i.default.parse(o.href)).port&&""===e.port||t.port===e.port;return t.hostname===e.hostname&&r&&t.protocol===e.protocol?"":"anonymous"};var n=t("url"),i=function(t){return t&&t.__esModule?t:{default:t}}(n),o=void 0},{url:28}],120:[function(t,e,r){"use strict";function n(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}function i(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0,r.BaseTextureCache=r.TextureCache=r.mixins=r.pluginTarget=r.EventEmitter=r.isMobile=void 0,r.uid=function(){return++v},r.hex2rgb=function(t,e){return(e=e||[])[0]=(t>>16&255)/255,e[1]=(t>>8&255)/255,e[2]=(255&t)/255,e},r.hex2string=function(t){return t=t.toString(16),"#"+(t="000000".substr(0,6-t.length)+t)},r.rgb2hex=function(t){return(255*t[0]<<16)+(255*t[1]<<8)+(255*t[2]|0)},r.getResolutionOfUrl=function(t,e){var r=a.default.RETINA_PREFIX.exec(t);return r?parseFloat(r[1]):void 0!==e?e:1},r.decomposeDataUri=function(t){var e=o.DATA_URI.exec(t);if(e)return{mediaType:e[1]?e[1].toLowerCase():void 0,subType:e[2]?e[2].toLowerCase():void 0,encoding:e[3]?e[3].toLowerCase():void 0,data:e[4]}},r.getUrlFileExtension=function(t){var e=o.URL_FILE_EXTENSION.exec(t);if(e)return e[1].toLowerCase()},r.getSvgSize=function(t){var e=o.SVG_SIZE.exec(t),r={};return e&&(r[e[1]]=Math.round(parseFloat(e[3])),r[e[5]]=Math.round(parseFloat(e[7]))),r},r.skipHello=function(){m=!0},r.sayHello=function(t){if(!m){if(navigator.userAgent.toLowerCase().indexOf("chrome")>-1){var e=["\n %c %c %c Pixi.js "+o.VERSION+" - ✰ "+t+" ✰ %c %c http://www.pixijs.com/ %c %c ♥%c♥%c♥ \n\n","background: #ff66a5; padding:5px 0;","background: #ff66a5; padding:5px 0;","color: #ff66a5; background: #030307; padding:5px 0;","background: #ff66a5; padding:5px 0;","background: #ffc3dc; padding:5px 0;","background: #ff66a5; padding:5px 0;","color: #ff2424; background: #fff; padding:5px 0;","color: #ff2424; background: #fff; padding:5px 0;","color: #ff2424; background: #fff; padding:5px 0;"];window.console.log.apply(console,e)}else window.console&&window.console.log("Pixi.js "+o.VERSION+" - "+t+" - http://www.pixijs.com/");m=!0}},r.isWebGLSupported=function(){var t={stencil:!0,failIfMajorPerformanceCaveat:!0};try{if(!window.WebGLRenderingContext)return!1;var e=document.createElement("canvas"),r=e.getContext("webgl",t)||e.getContext("experimental-webgl",t),n=!(!r||!r.getContextAttributes().stencil);if(r){var i=r.getExtension("WEBGL_lose_context");i&&i.loseContext()}return r=null,n}catch(t){return!1}},r.sign=function(t){return 0===t?0:t<0?-1:1},r.removeItems=function(t,e,r){var n=t.length;if(!(e>=n||0===r)){for(var i=n-(r=e+r>n?n-e:r),o=e;o1?this._fontStyle="italic":t.indexOf("oblique")>-1?this._fontStyle="oblique":this._fontStyle="normal",t.indexOf("small-caps")>-1?this._fontVariant="small-caps":this._fontVariant="normal";var e=t.split(" "),r=-1;this._fontSize=26;for(var n=0;n-1&&r=this._durations[this.currentFrame];)n-=this._durations[this.currentFrame]*i,this._currentTime+=i;this._currentTime+=n/this._durations[this.currentFrame]}else this._currentTime+=e;this._currentTime<0&&!this.loop?(this.gotoAndStop(0),this.onComplete&&this.onComplete()):this._currentTime>=this._textures.length&&!this.loop?(this.gotoAndStop(this._textures.length-1),this.onComplete&&this.onComplete()):r!==this.currentFrame&&this.updateTexture()},e.prototype.updateTexture=function(){this._texture=this._textures[this.currentFrame],this._textureID=-1,this.onFrameChange&&this.onFrameChange(this.currentFrame)},e.prototype.destroy=function(){this.stop(),t.prototype.destroy.call(this)},e.fromFrames=function(t){for(var r=[],n=0;n1&&void 0!==arguments[1]?arguments[1]:{};!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var i=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this));return i._textWidth=0,i._textHeight=0,i._glyphs=[],i._font={tint:void 0!==n.tint?n.tint:16777215,align:n.align||"left",name:null,size:0},i.font=n.font,i._text=r,i.maxWidth=0,i.maxLineHeight=0,i._anchor=new a.default(function(){i.dirty=!0},i,0,0),i.dirty=!1,i.updateText(),i}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.updateText=function(){for(var t=e.fonts[this._font.name],r=this._font.size/t.size,n=new o.Point,i=[],s=[],a=null,u=0,l=0,h=0,c=-1,f=0,p=0,d=0;d0&&n.x*r>this.maxWidth)o.utils.removeItems(i,c,d-c),d=c,c=-1,s.push(f),l=Math.max(l,f),h++,n.x=0,n.y+=t.lineHeight,a=null;else{var v=t.chars[g];v&&(a&&v.kerning[a]&&(n.x+=v.kerning[a]),i.push({texture:v.texture,line:h,charCode:g,position:new o.Point(n.x+v.xOffset,n.y+v.yOffset)}),u=n.x+(v.texture.width+v.xOffset),n.x+=v.xAdvance,p=Math.max(p,v.yOffset+v.texture.height),a=g)}}s.push(u),l=Math.max(l,u);for(var m=[],y=0;y<=h;y++){var x=0;"right"===this._font.align?x=l-s[y]:"center"===this._font.align&&(x=(l-s[y])/2),m.push(x)}for(var b=i.length,_=this.tint,w=0;w=0?t:16777215,this.dirty=!0}},{key:"align",get:function(){return this._font.align},set:function(t){this._font.align=t||"left",this.dirty=!0}},{key:"anchor",get:function(){return this._anchor},set:function(t){"number"==typeof t?this._anchor.set(t):this._anchor.copy(t)}},{key:"font",get:function(){return this._font},set:function(t){t&&("string"==typeof t?(t=t.split(" "),this._font.name=1===t.length?t[0]:t.slice(1).join(" "),this._font.size=t.length>=2?parseInt(t[0],10):e.fonts[this._font.name].size):(this._font.name=t.name,this._font.size="number"==typeof t.size?t.size:parseInt(t.size,10)),this.dirty=!0)}},{key:"text",get:function(){return this._text},set:function(t){t=t.toString()||" ",this._text!==t&&(this._text=t,this.dirty=!0)}},{key:"textWidth",get:function(){return this.validate(),this._textWidth}},{key:"textHeight",get:function(){return this.validate(),this._textHeight}}]),e}(o.Container);r.default=u,u.fonts={}},{"../core":63,"../core/math/ObservablePoint":66}],131:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(t,e){for(var r=0;r1&&void 0!==arguments[1]?arguments[1]:100,i=arguments.length>2&&void 0!==arguments[2]?arguments[2]:100;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var o=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,r));return o.tileTransform=new s.TransformStatic,o._width=n,o._height=i,o._canvasPattern=null,o.uvTransform=r.transform||new h.default(r),o.pluginName="tilingSprite",o.uvRespectAnchor=!1,o}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype._onTextureUpdate=function(){this.uvTransform&&(this.uvTransform.texture=this._texture)},e.prototype._renderWebGL=function(t){var e=this._texture;e&&e.valid&&(this.tileTransform.updateLocalTransform(),this.uvTransform.update(),t.setObjectRenderer(t.plugins[this.pluginName]),t.plugins[this.pluginName].render(this))},e.prototype._renderCanvas=function(t){var e=this._texture;if(e.baseTexture.hasLoaded){var r=t.context,n=this.worldTransform,i=t.resolution,o=e.baseTexture,a=e.baseTexture.resolution,l=this.tilePosition.x/this.tileScale.x%e._frame.width,h=this.tilePosition.y/this.tileScale.y%e._frame.height;if(!this._canvasPattern){var c=new s.CanvasRenderTarget(e._frame.width,e._frame.height,a);16777215!==this.tint?(this.cachedTint!==this.tint&&(this.cachedTint=this.tint,this.tintedTexture=u.default.getTintedTexture(this,this.tint)),c.context.drawImage(this.tintedTexture,0,0)):c.context.drawImage(o.source,-e._frame.x,-e._frame.y),this._canvasPattern=c.context.createPattern(c.canvas,"repeat")}r.globalAlpha=this.worldAlpha,r.setTransform(n.a*i,n.b*i,n.c*i,n.d*i,n.tx*i,n.ty*i),t.setBlendMode(this.blendMode),r.fillStyle=this._canvasPattern,r.scale(this.tileScale.x/a,this.tileScale.y/a);var f=this.anchor.x*-this._width,p=this.anchor.y*-this._height;this.uvRespectAnchor?(r.translate(l,h),r.fillRect(-l+f,-h+p,this._width/this.tileScale.x*a,this._height/this.tileScale.y*a)):(r.translate(l+f,h+p),r.fillRect(-l,-h,this._width/this.tileScale.x*a,this._height/this.tileScale.y*a))}},e.prototype._calculateBounds=function(){var t=this._width*-this._anchor._x,e=this._height*-this._anchor._y,r=this._width*(1-this._anchor._x),n=this._height*(1-this._anchor._y);this._bounds.addFrame(this.transform,t,e,r,n)},e.prototype.getLocalBounds=function(e){return 0===this.children.length?(this._bounds.minX=this._width*-this._anchor._x,this._bounds.minY=this._height*-this._anchor._y,this._bounds.maxX=this._width*(1-this._anchor._x),this._bounds.maxY=this._height*(1-this._anchor._x),e||(this._localBoundsRect||(this._localBoundsRect=new s.Rectangle),e=this._localBoundsRect),this._bounds.getRectangle(e)):t.prototype.getLocalBounds.call(this,e)},e.prototype.containsPoint=function(t){this.worldTransform.applyInverse(t,c);var e=this._width,r=this._height,n=-e*this.anchor._x;if(c.x>n&&c.xi&&c.y0&&void 0!==arguments[0]?arguments[0]:new i.Point,e=arguments.length>1&&void 0!==arguments[1]&&arguments[1];return this.parent?this.parent.toGlobal(this.position,t,e):(t.x=this.position.x,t.y=this.position.y),t}},{"../core":63}],136:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0,r.BitmapText=r.TilingSpriteRenderer=r.TilingSprite=r.AnimatedSprite=r.TextureTransform=void 0;var i=t("./TextureTransform");Object.defineProperty(r,"TextureTransform",{enumerable:!0,get:function(){return n(i).default}});var o=t("./AnimatedSprite");Object.defineProperty(r,"AnimatedSprite",{enumerable:!0,get:function(){return n(o).default}});var s=t("./TilingSprite");Object.defineProperty(r,"TilingSprite",{enumerable:!0,get:function(){return n(s).default}});var a=t("./webgl/TilingSpriteRenderer");Object.defineProperty(r,"TilingSpriteRenderer",{enumerable:!0,get:function(){return n(a).default}});var u=t("./BitmapText");Object.defineProperty(r,"BitmapText",{enumerable:!0,get:function(){return n(u).default}}),t("./cacheAsBitmap"),t("./getChildByName"),t("./getGlobalPosition")},{"./AnimatedSprite":129,"./BitmapText":130,"./TextureTransform":131,"./TilingSprite":132,"./cacheAsBitmap":133,"./getChildByName":134,"./getGlobalPosition":135,"./webgl/TilingSpriteRenderer":137}],137:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("../../core"),i=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}(n),o=t("../../core/const"),s=(t("path"),new i.Matrix),a=new Float32Array(4),u=function(t){function e(r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var n=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,r));return n.shader=null,n.simpleShader=null,n.quad=null,n}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.onContextChange=function(){var t=this.renderer.gl;this.shader=new i.Shader(t,"attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform mat3 uTransform;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\n}\n","varying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform vec4 uColor;\nuniform mat3 uMapCoord;\nuniform vec4 uClampFrame;\nuniform vec2 uClampOffset;\n\nvoid main(void)\n{\n vec2 coord = mod(vTextureCoord - uClampOffset, vec2(1.0, 1.0)) + uClampOffset;\n coord = (uMapCoord * vec3(coord, 1.0)).xy;\n coord = clamp(coord, uClampFrame.xy, uClampFrame.zw);\n\n vec4 sample = texture2D(uSampler, coord);\n vec4 color = vec4(uColor.rgb * uColor.a, uColor.a);\n\n gl_FragColor = sample * color ;\n}\n"),this.simpleShader=new i.Shader(t,"attribute vec2 aVertexPosition;\nattribute vec2 aTextureCoord;\n\nuniform mat3 projectionMatrix;\nuniform mat3 translationMatrix;\nuniform mat3 uTransform;\n\nvarying vec2 vTextureCoord;\n\nvoid main(void)\n{\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n\n vTextureCoord = (uTransform * vec3(aTextureCoord, 1.0)).xy;\n}\n","varying vec2 vTextureCoord;\n\nuniform sampler2D uSampler;\nuniform vec4 uColor;\n\nvoid main(void)\n{\n vec4 sample = texture2D(uSampler, vTextureCoord);\n vec4 color = vec4(uColor.rgb * uColor.a, uColor.a);\n gl_FragColor = sample * color;\n}\n"),this.renderer.bindVao(null),this.quad=new i.Quad(t,this.renderer.state.attribState),this.quad.initVao(this.shader)},e.prototype.render=function(t){var e=this.renderer,r=this.quad;e.bindVao(r.vao);var n=r.vertices;n[0]=n[6]=t._width*-t.anchor.x,n[1]=n[3]=t._height*-t.anchor.y,n[2]=n[4]=t._width*(1-t.anchor.x),n[5]=n[7]=t._height*(1-t.anchor.y),t.uvRespectAnchor&&((n=r.uvs)[0]=n[6]=-t.anchor.x,n[1]=n[3]=-t.anchor.y,n[2]=n[4]=1-t.anchor.x,n[5]=n[7]=1-t.anchor.y),r.upload();var u=t._texture,l=u.baseTexture,h=t.tileTransform.localTransform,c=t.uvTransform,f=l.isPowerOfTwo&&u.frame.width===l.width&&u.frame.height===l.height;f&&(l._glTextures[e.CONTEXT_UID]?f=l.wrapMode!==o.WRAP_MODES.CLAMP:l.wrapMode===o.WRAP_MODES.CLAMP&&(l.wrapMode=o.WRAP_MODES.REPEAT));var p=f?this.simpleShader:this.shader;e.bindShader(p);var d=u.width,g=u.height,v=t._width,m=t._height;s.set(h.a*d/v,h.b*d/m,h.c*g/v,h.d*g/m,h.tx/v,h.ty/m),s.invert(),f?s.append(c.mapCoord):(p.uniforms.uMapCoord=c.mapCoord.toArray(!0),p.uniforms.uClampFrame=c.uClampFrame,p.uniforms.uClampOffset=c.uClampOffset),p.uniforms.uTransform=s.toArray(!0);var y=a;i.utils.hex2rgb(t.tint,y),y[3]=t.worldAlpha,p.uniforms.uColor=y,p.uniforms.translationMatrix=t.transform.worldTransform.toArray(!0),p.uniforms.uSampler=e.bindTexture(u),e.setBlendMode(t.blendMode),r.vao.draw(this.renderer.gl.TRIANGLES,6,0)},e}(i.ObjectRenderer);r.default=u,i.WebGLRenderer.registerPlugin("tilingSprite",u)},{"../../core":63,"../../core/const":44,path:22}],138:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0;var i=function(){function t(t,e){for(var r=0;r=r&&(a=t-u-1),l=l.replace("%value%",e[a]),s+=l,s+="\n"}return o=(o=o.replace("%blur%",s)).replace("%size%",t)};var n={5:[.153388,.221461,.250301],7:[.071303,.131514,.189879,.214607],9:[.028532,.067234,.124009,.179044,.20236],11:[.0093,.028002,.065984,.121703,.175713,.198596],13:[.002406,.009255,.027867,.065666,.121117,.174868,.197641],15:[489e-6,.002403,.009246,.02784,.065602,.120999,.174697,.197448]},i=["varying vec2 vBlurTexCoords[%size%];","uniform sampler2D uSampler;","void main(void)","{"," gl_FragColor = vec4(0.0);"," %blur%","}"].join("\n")},{}],142:[function(t,e,r){"use strict";r.__esModule=!0,r.default=function(t,e){var r=Math.ceil(t/2),i=n,o="",s=void 0;s=e?"vBlurTexCoords[%index%] = aTextureCoord + vec2(%sampleIndex% * strength, 0.0);":"vBlurTexCoords[%index%] = aTextureCoord + vec2(0.0, %sampleIndex% * strength);";for(var a=0;ae;)r-=2;return r}},{}],144:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(t,e){for(var r=0;r 0.0) {\n c.rgb /= c.a;\n }\n vec4 result;\n result.r = (m[0] * c.r);\n result.r += (m[1] * c.g);\n result.r += (m[2] * c.b);\n result.r += (m[3] * c.a);\n result.r += m[4];\n\n result.g = (m[5] * c.r);\n result.g += (m[6] * c.g);\n result.g += (m[7] * c.b);\n result.g += (m[8] * c.a);\n result.g += m[9];\n\n result.b = (m[10] * c.r);\n result.b += (m[11] * c.g);\n result.b += (m[12] * c.b);\n result.b += (m[13] * c.a);\n result.b += m[14];\n\n result.a = (m[15] * c.r);\n result.a += (m[16] * c.g);\n result.a += (m[17] * c.b);\n result.a += (m[18] * c.a);\n result.a += m[19];\n\n // Premultiply alpha again.\n result.rgb *= result.a;\n\n gl_FragColor = result;\n}\n"));return r.uniforms.m=[1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0],r}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype._loadMatrix=function(t){var e=arguments.length>1&&void 0!==arguments[1]&&arguments[1],r=t;e&&(this._multiply(r,this.uniforms.m,t),r=this._colorMatrix(r)),this.uniforms.m=r},e.prototype._multiply=function(t,e,r){return t[0]=e[0]*r[0]+e[1]*r[5]+e[2]*r[10]+e[3]*r[15],t[1]=e[0]*r[1]+e[1]*r[6]+e[2]*r[11]+e[3]*r[16],t[2]=e[0]*r[2]+e[1]*r[7]+e[2]*r[12]+e[3]*r[17],t[3]=e[0]*r[3]+e[1]*r[8]+e[2]*r[13]+e[3]*r[18],t[4]=e[0]*r[4]+e[1]*r[9]+e[2]*r[14]+e[3]*r[19]+e[4],t[5]=e[5]*r[0]+e[6]*r[5]+e[7]*r[10]+e[8]*r[15],t[6]=e[5]*r[1]+e[6]*r[6]+e[7]*r[11]+e[8]*r[16],t[7]=e[5]*r[2]+e[6]*r[7]+e[7]*r[12]+e[8]*r[17],t[8]=e[5]*r[3]+e[6]*r[8]+e[7]*r[13]+e[8]*r[18],t[9]=e[5]*r[4]+e[6]*r[9]+e[7]*r[14]+e[8]*r[19]+e[9],t[10]=e[10]*r[0]+e[11]*r[5]+e[12]*r[10]+e[13]*r[15],t[11]=e[10]*r[1]+e[11]*r[6]+e[12]*r[11]+e[13]*r[16],t[12]=e[10]*r[2]+e[11]*r[7]+e[12]*r[12]+e[13]*r[17],t[13]=e[10]*r[3]+e[11]*r[8]+e[12]*r[13]+e[13]*r[18],t[14]=e[10]*r[4]+e[11]*r[9]+e[12]*r[14]+e[13]*r[19]+e[14],t[15]=e[15]*r[0]+e[16]*r[5]+e[17]*r[10]+e[18]*r[15],t[16]=e[15]*r[1]+e[16]*r[6]+e[17]*r[11]+e[18]*r[16],t[17]=e[15]*r[2]+e[16]*r[7]+e[17]*r[12]+e[18]*r[17],t[18]=e[15]*r[3]+e[16]*r[8]+e[17]*r[13]+e[18]*r[18],t[19]=e[15]*r[4]+e[16]*r[9]+e[17]*r[14]+e[18]*r[19]+e[19],t},e.prototype._colorMatrix=function(t){var e=new Float32Array(t);return e[4]/=255,e[9]/=255,e[14]/=255,e[19]/=255,e},e.prototype.brightness=function(t,e){var r=[t,0,0,0,0,0,t,0,0,0,0,0,t,0,0,0,0,0,1,0];this._loadMatrix(r,e)},e.prototype.greyscale=function(t,e){var r=[t,t,t,0,0,t,t,t,0,0,t,t,t,0,0,0,0,0,1,0];this._loadMatrix(r,e)},e.prototype.blackAndWhite=function(t){this._loadMatrix([.3,.6,.1,0,0,.3,.6,.1,0,0,.3,.6,.1,0,0,0,0,0,1,0],t)},e.prototype.hue=function(t,e){t=(t||0)/180*Math.PI;var r=Math.cos(t),n=Math.sin(t),i=Math.sqrt,o=1/3,s=i(o),a=r+(1-r)*o,u=o*(1-r)-s*n,l=o*(1-r)+s*n,h=o*(1-r)+s*n,c=r+o*(1-r),f=o*(1-r)-s*n,p=o*(1-r)-s*n,d=o*(1-r)+s*n,g=r+o*(1-r),v=[a,u,l,0,0,h,c,f,0,0,p,d,g,0,0,0,0,0,1,0];this._loadMatrix(v,e)},e.prototype.contrast=function(t,e){var r=(t||0)+1,n=-128*(r-1),i=[r,0,0,0,n,0,r,0,0,n,0,0,r,0,n,0,0,0,1,0];this._loadMatrix(i,e)},e.prototype.saturate=function(){var t=arguments.length>0&&void 0!==arguments[0]?arguments[0]:0,e=arguments[1],r=2*t/3+1,n=-.5*(r-1),i=[r,n,n,0,0,n,r,n,0,0,n,n,r,0,0,0,0,0,1,0];this._loadMatrix(i,e)},e.prototype.desaturate=function(){this.saturate(-1)},e.prototype.negative=function(t){this._loadMatrix([0,1,1,0,0,1,0,1,0,0,1,1,0,0,0,0,0,0,1,0],t)},e.prototype.sepia=function(t){this._loadMatrix([.393,.7689999,.18899999,0,0,.349,.6859999,.16799999,0,0,.272,.5339999,.13099999,0,0,0,0,0,1,0],t)},e.prototype.technicolor=function(t){this._loadMatrix([1.9125277891456083,-.8545344976951645,-.09155508482755585,0,11.793603434377337,-.3087833385928097,1.7658908555458428,-.10601743074722245,0,-70.35205161461398,-.231103377548616,-.7501899197440212,1.847597816108189,0,30.950940869491138,0,0,0,1,0],t)},e.prototype.polaroid=function(t){this._loadMatrix([1.438,-.062,-.062,0,0,-.122,1.378,-.122,0,0,-.016,-.016,1.483,0,0,0,0,0,1,0],t)},e.prototype.toBGR=function(t){this._loadMatrix([0,0,1,0,0,0,1,0,0,0,1,0,0,0,0,0,0,0,1,0],t)},e.prototype.kodachrome=function(t){this._loadMatrix([1.1285582396593525,-.3967382283601348,-.03992559172921793,0,63.72958762196502,-.16404339962244616,1.0835251566291304,-.05498805115633132,0,24.732407896706203,-.16786010706155763,-.5603416277695248,1.6014850761964943,0,35.62982807460946,0,0,0,1,0],t)},e.prototype.browni=function(t){this._loadMatrix([.5997023498159715,.34553243048391263,-.2708298674538042,0,47.43192855600873,-.037703249837783157,.8609577587992641,.15059552388459913,0,-36.96841498319127,.24113635128153335,-.07441037908422492,.44972182064877153,0,-7.562075277591283,0,0,0,1,0],t)},e.prototype.vintage=function(t){this._loadMatrix([.6279345635605994,.3202183420819367,-.03965408211312453,0,9.651285835294123,.02578397704808868,.6441188644374771,.03259127616149294,0,7.462829176470591,.0466055556782719,-.0851232987247891,.5241648018700465,0,5.159190588235296,0,0,0,1,0],t)},e.prototype.colorTone=function(t,e,r,n,i){t=t||.2,e=e||.15;var o=((r=r||16770432)>>16&255)/255,s=(r>>8&255)/255,a=(255&r)/255,u=((n=n||3375104)>>16&255)/255,l=(n>>8&255)/255,h=(255&n)/255,c=[.3,.59,.11,0,0,o,s,a,t,0,u,l,h,e,0,o-u,s-l,a-h,0,0];this._loadMatrix(c,i)},e.prototype.night=function(t,e){var r=[-2*(t=t||.1),-t,0,0,0,-t,0,t,0,0,0,t,2*t,0,0,0,0,0,1,0];this._loadMatrix(r,e)},e.prototype.predator=function(t,e){var r=[11.224130630493164*t,-4.794486999511719*t,-2.8746118545532227*t,0*t,.40342438220977783*t,-3.6330697536468506*t,9.193157196044922*t,-2.951810836791992*t,0*t,-1.316135048866272*t,-3.2184197902679443*t,-4.2375030517578125*t,7.476448059082031*t,0*t,.8044459223747253*t,0,0,0,1,0];this._loadMatrix(r,e)},e.prototype.lsd=function(t){this._loadMatrix([2,-.4,.5,0,0,-.5,2,-.4,0,0,-.4,-.5,3,0,0,0,0,0,1,0],t)},e.prototype.reset=function(){this._loadMatrix([1,0,0,0,0,0,1,0,0,0,0,0,1,0,0,0,0,0,1,0],!1)},n(e,[{key:"matrix",get:function(){return this.uniforms.m},set:function(t){this.uniforms.m=t}}]),e}(o.Filter));r.default=s,s.prototype.grayscale=s.prototype.greyscale},{"../../core":63,path:22}],145:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(t,e){for(var r=0;r lumaMax))\n color = vec4(rgbA, texColor.a);\n else\n color = vec4(rgbB, texColor.a);\n return color;\n}\n\nvoid main() {\n\n vec2 fragCoord = vTextureCoord * filterArea.xy;\n\n vec4 color;\n\n color = fxaa(uSampler, fragCoord, filterArea.xy, v_rgbNW, v_rgbNE, v_rgbSW, v_rgbSE, v_rgbM);\n\n gl_FragColor = color;\n}\n'))}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e}(i.Filter));r.default=o},{"../../core":63,path:22}],147:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0;var i=t("./fxaa/FXAAFilter");Object.defineProperty(r,"FXAAFilter",{enumerable:!0,get:function(){return n(i).default}});var o=t("./noise/NoiseFilter");Object.defineProperty(r,"NoiseFilter",{enumerable:!0,get:function(){return n(o).default}});var s=t("./displacement/DisplacementFilter");Object.defineProperty(r,"DisplacementFilter",{enumerable:!0,get:function(){return n(s).default}});var a=t("./blur/BlurFilter");Object.defineProperty(r,"BlurFilter",{enumerable:!0,get:function(){return n(a).default}});var u=t("./blur/BlurXFilter");Object.defineProperty(r,"BlurXFilter",{enumerable:!0,get:function(){return n(u).default}});var l=t("./blur/BlurYFilter");Object.defineProperty(r,"BlurYFilter",{enumerable:!0,get:function(){return n(l).default}});var h=t("./colormatrix/ColorMatrixFilter");Object.defineProperty(r,"ColorMatrixFilter",{enumerable:!0,get:function(){return n(h).default}});var c=t("./void/VoidFilter");Object.defineProperty(r,"VoidFilter",{enumerable:!0,get:function(){return n(c).default}})},{"./blur/BlurFilter":138,"./blur/BlurXFilter":139,"./blur/BlurYFilter":140,"./colormatrix/ColorMatrixFilter":144,"./displacement/DisplacementFilter":145,"./fxaa/FXAAFilter":146,"./noise/NoiseFilter":148,"./void/VoidFilter":149}],148:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(t,e){for(var r=0;r1&&void 0!==arguments[1]?arguments[1]:1;this.removeEvents(),this.interactionDOMElement=t,this.resolution=e,this.addEvents()},e.prototype.addEvents=function(){this.interactionDOMElement&&(s.ticker.shared.add(this.update,this),window.navigator.msPointerEnabled?(this.interactionDOMElement.style["-ms-content-zooming"]="none",this.interactionDOMElement.style["-ms-touch-action"]="none"):this.supportsPointerEvents&&(this.interactionDOMElement.style["touch-action"]="none"),this.supportsPointerEvents?(window.document.addEventListener("pointermove",this.onPointerMove,!0),this.interactionDOMElement.addEventListener("pointerdown",this.onPointerDown,!0),this.interactionDOMElement.addEventListener("pointerleave",this.onPointerOut,!0),this.interactionDOMElement.addEventListener("pointerover",this.onPointerOver,!0),window.addEventListener("pointercancel",this.onPointerCancel,!0),window.addEventListener("pointerup",this.onPointerUp,!0)):(window.document.addEventListener("mousemove",this.onPointerMove,!0),this.interactionDOMElement.addEventListener("mousedown",this.onPointerDown,!0),this.interactionDOMElement.addEventListener("mouseout",this.onPointerOut,!0),this.interactionDOMElement.addEventListener("mouseover",this.onPointerOver,!0),window.addEventListener("mouseup",this.onPointerUp,!0),this.supportsTouchEvents&&(this.interactionDOMElement.addEventListener("touchstart",this.onPointerDown,!0),this.interactionDOMElement.addEventListener("touchcancel",this.onPointerCancel,!0),this.interactionDOMElement.addEventListener("touchend",this.onPointerUp,!0),this.interactionDOMElement.addEventListener("touchmove",this.onPointerMove,!0))),this.eventsAdded=!0)},e.prototype.removeEvents=function(){this.interactionDOMElement&&(s.ticker.shared.remove(this.update,this),window.navigator.msPointerEnabled?(this.interactionDOMElement.style["-ms-content-zooming"]="",this.interactionDOMElement.style["-ms-touch-action"]=""):this.supportsPointerEvents&&(this.interactionDOMElement.style["touch-action"]=""),this.supportsPointerEvents?(window.document.removeEventListener("pointermove",this.onPointerMove,!0),this.interactionDOMElement.removeEventListener("pointerdown",this.onPointerDown,!0),this.interactionDOMElement.removeEventListener("pointerleave",this.onPointerOut,!0),this.interactionDOMElement.removeEventListener("pointerover",this.onPointerOver,!0),window.removeEventListener("pointercancel",this.onPointerCancel,!0),window.removeEventListener("pointerup",this.onPointerUp,!0)):(window.document.removeEventListener("mousemove",this.onPointerMove,!0),this.interactionDOMElement.removeEventListener("mousedown",this.onPointerDown,!0),this.interactionDOMElement.removeEventListener("mouseout",this.onPointerOut,!0),this.interactionDOMElement.removeEventListener("mouseover",this.onPointerOver,!0),window.removeEventListener("mouseup",this.onPointerUp,!0),this.supportsTouchEvents&&(this.interactionDOMElement.removeEventListener("touchstart",this.onPointerDown,!0),this.interactionDOMElement.removeEventListener("touchcancel",this.onPointerCancel,!0),this.interactionDOMElement.removeEventListener("touchend",this.onPointerUp,!0),this.interactionDOMElement.removeEventListener("touchmove",this.onPointerMove,!0))),this.interactionDOMElement=null,this.eventsAdded=!1)},e.prototype.update=function(t){if(this._deltaTime+=t,!(this._deltaTime=0;l--){var h=u[l],c=this.processInteractive(t,h,r,n,a);if(c){if(!h.parent)continue;a=!1,2===c?(n=!1,s=2):0===s&&(s=1)}}return i&&(n&&2!==s&&(e.hitArea?(e.worldTransform.applyInverse(o,this._tempPoint),e.hitArea.contains(this._tempPoint.x,this._tempPoint.y)&&(s=e.interactive?2:1)):e.containsPoint&&e.containsPoint(o)&&(s=e.interactive?2:1)),e.interactive&&(s&&!t.target&&(t.target=e),r(t,e,!!s))),s},e.prototype.onPointerDown=function(t){var e=this.normalizeToPointerData(t);this.autoPreventDefault&&e[0].isNormalized&&t.preventDefault();for(var r=e.length,n=0;n1&&(h=1);var c=Math.sqrt(n*n+i*i),f=this._texture.height/2;n/=c,i/=c,n*=f,i*=f,o[l]=u.x+n,o[l+1]=u.y+i,o[l+2]=u.x-n,o[l+3]=u.y-i,e=u}this.containerUpdateTransform()}},e}(i.default);r.default=a},{"../core":63,"./Mesh":161}],165:[function(t,e,r){"use strict";r.__esModule=!0;var n=t("../../core"),i=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}(n),o=t("../Mesh"),s=function(t){return t&&t.__esModule?t:{default:t}}(o),a=function(){function t(e){(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.renderer=e}return t.prototype.render=function(t){var e=this.renderer,r=e.context,n=t.worldTransform,i=e.resolution;e.roundPixels?r.setTransform(n.a*i,n.b*i,n.c*i,n.d*i,n.tx*i|0,n.ty*i|0):r.setTransform(n.a*i,n.b*i,n.c*i,n.d*i,n.tx*i,n.ty*i),e.setBlendMode(t.blendMode),t.drawMode===s.default.DRAW_MODES.TRIANGLE_MESH?this._renderTriangleMesh(t):this._renderTriangles(t)},t.prototype._renderTriangleMesh=function(t){for(var e=t.vertices.length/2,r=0;r0){var E=t.canvasPadding/t.worldTransform.a,S=t.canvasPadding/t.worldTransform.d,A=(y+x+b)/3,C=(_+w+T)/3,M=y-A,R=_-C,O=Math.sqrt(M*M+R*R);y=A+M/O*(O+E),_=C+R/O*(O+S),M=x-A,R=w-C,O=Math.sqrt(M*M+R*R),x=A+M/O*(O+E),w=C+R/O*(O+S),M=b-A,R=T-C,O=Math.sqrt(M*M+R*R),b=A+M/O*(O+E),T=C+R/O*(O+S)}i.save(),i.beginPath(),i.moveTo(y,_),i.lineTo(x,w),i.lineTo(b,T),i.closePath(),i.clip();var P=f*v+g*d+p*m-v*d-g*p-f*m,D=y*v+g*b+x*m-v*b-g*x-y*m,I=f*x+y*d+p*b-x*d-y*p-f*b,L=f*v*b+g*x*d+y*p*m-y*v*d-g*p*b-f*x*m,F=_*v+g*T+w*m-v*T-g*w-_*m,k=f*w+_*d+p*T-w*d-_*p-f*T,B=f*v*T+g*w*d+_*p*m-_*v*d-g*p*T-f*w*m;i.transform(D/P,F/P,I/P,k/P,L/P,B/P),i.drawImage(l,0,0,h*u.resolution,c*u.resolution,0,0,h,c),i.restore()}},t.prototype.renderMeshFlat=function(t){var e=this.renderer.context,r=t.vertices,n=r.length/2;e.beginPath();for(var i=1;i0&&void 0!==arguments[0]?arguments[0]:1500,n=arguments[1],o=arguments.length>2&&void 0!==arguments[2]?arguments[2]:16384;!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var s=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this));return o>16384&&(o=16384),o>r&&(o=r),s._properties=[!1,!0,!1,!1,!1],s._maxSize=r,s._batchSize=o,s._glBuffers={},s._bufferToUpdate=0,s.interactiveChildren=!1,s.blendMode=i.BLEND_MODES.NORMAL,s.roundPixels=!0,s.baseTexture=null,s.setProperties(n),s}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.setProperties=function(t){t&&(this._properties[0]="scale"in t?!!t.scale:this._properties[0],this._properties[1]="position"in t?!!t.position:this._properties[1],this._properties[2]="rotation"in t?!!t.rotation:this._properties[2],this._properties[3]="uvs"in t?!!t.uvs:this._properties[3],this._properties[4]="alpha"in t?!!t.alpha:this._properties[4])},e.prototype.updateTransform=function(){this.displayObjectUpdateTransform()},e.prototype.renderWebGL=function(t){var e=this;this.visible&&!(this.worldAlpha<=0)&&this.children.length&&this.renderable&&(this.baseTexture||(this.baseTexture=this.children[0]._texture.baseTexture,this.baseTexture.hasLoaded||this.baseTexture.once("update",function(){return e.onChildrenChange(0)})),t.setObjectRenderer(t.plugins.particle),t.plugins.particle.render(this))},e.prototype.onChildrenChange=function(t){var e=Math.floor(t/this._batchSize);er&&(o=r);var s=t._glBuffers[i.CONTEXT_UID];s||(s=t._glBuffers[i.CONTEXT_UID]=this.generateBuffers(t)),this.renderer.setBlendMode(t.blendMode);var a=i.gl,u=t.worldTransform.copy(this.tempMatrix);u.prepend(i._activeRenderTarget.projectionMatrix),this.shader.uniforms.projectionMatrix=u.toArray(!0),this.shader.uniforms.uAlpha=t.worldAlpha;var l=e[0]._texture.baseTexture;this.shader.uniforms.uSampler=i.bindTexture(l);for(var h=0,c=0;hn&&(f=n);var p=s[c];p.uploadDynamic(e,h,f),t._bufferToUpdate===c&&(p.uploadStatic(e,h,f),t._bufferToUpdate=c+1),i.bindVao(p.vao),p.vao.draw(a.TRIANGLES,6*f)}}},e.prototype.generateBuffers=function(t){for(var e=this.renderer.gl,r=[],n=t._maxSize,i=t._batchSize,o=t._properties,s=0;s0?1:-1})},{}],174:[function(t,e,r){"use strict";var n=t("object-assign"),i=function(t){return t&&t.__esModule?t:{default:t}}(n);Object.assign||(Object.assign=i.default)},{"object-assign":5}],175:[function(t,e,r){"use strict";t("./Object.assign"),t("./requestAnimationFrame"),t("./Math.sign"),window.ArrayBuffer||(window.ArrayBuffer=Array),window.Float32Array||(window.Float32Array=Array),window.Uint32Array||(window.Uint32Array=Array),window.Uint16Array||(window.Uint16Array=Array)},{"./Math.sign":173,"./Object.assign":174,"./requestAnimationFrame":176}],176:[function(t,r,n){(function(t){"use strict";Date.now&&Date.prototype.getTime||(Date.now=function(){return(new Date).getTime()}),t.performance&&t.performance.now||function(){var e=Date.now();t.performance||(t.performance={}),t.performance.now=function(){return Date.now()-e}}();for(var e=Date.now(),r=["ms","moz","webkit","o"],n=0;n=0;n--)this.add(t.children[n]);return this},t.prototype.destroy=function(){this.ticking&&c.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},t}();r.default=f},{"../core":63,"./limiters/CountLimiter":180}],178:[function(t,e,r){"use strict";function n(t,e){if(e instanceof s.BaseTexture){var r=e.source,n=0===r.width?t.canvas.width:Math.min(t.canvas.width,r.width),i=0===r.height?t.canvas.height:Math.min(t.canvas.height,r.height);return t.ctx.drawImage(r,0,0,n,i,0,0,t.canvas.width,t.canvas.height),!0}return!1}function i(t,e){if(t instanceof s.BaseTexture)return-1===e.indexOf(t)&&e.push(t),!0;if(t._texture&&t._texture instanceof s.Texture){var r=t._texture.baseTexture;return-1===e.indexOf(r)&&e.push(r),!0}return!1}r.__esModule=!0;var o=t("../../core"),s=function(t){if(t&&t.__esModule)return t;var e={};if(null!=t)for(var r in t)Object.prototype.hasOwnProperty.call(t,r)&&(e[r]=t[r]);return e.default=t,e}(o),a=t("../BasePrepare"),u=function(t){return t&&t.__esModule?t:{default:t}}(a),l=16,h=function(t){function e(r){!function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")}(this,e);var o=function(t,e){if(!t)throw new ReferenceError("this hasn't been initialised - super() hasn't been called");return!e||"object"!=typeof e&&"function"!=typeof e?t:e}(this,t.call(this,r));return o.uploadHookHelper=o,o.canvas=document.createElement("canvas"),o.canvas.width=l,o.canvas.height=l,o.ctx=o.canvas.getContext("2d"),o.register(i,n),o}return function(t,e){if("function"!=typeof e&&null!==e)throw new TypeError("Super expression must either be null or a function, not "+typeof e);t.prototype=Object.create(e&&e.prototype,{constructor:{value:t,enumerable:!1,writable:!0,configurable:!0}}),e&&(Object.setPrototypeOf?Object.setPrototypeOf(t,e):t.__proto__=e)}(e,t),e.prototype.destroy=function(){t.prototype.destroy.call(this),this.ctx=null,this.canvas=null},e}(u.default);r.default=h,s.CanvasRenderer.registerPlugin("prepare",h)},{"../../core":63,"../BasePrepare":177}],179:[function(t,e,r){"use strict";function n(t){return t&&t.__esModule?t:{default:t}}r.__esModule=!0;var i=t("./webgl/WebGLPrepare");Object.defineProperty(r,"webgl",{enumerable:!0,get:function(){return n(i).default}});var o=t("./canvas/CanvasPrepare");Object.defineProperty(r,"canvas",{enumerable:!0,get:function(){return n(o).default}});var s=t("./BasePrepare");Object.defineProperty(r,"BasePrepare",{enumerable:!0,get:function(){return n(s).default}});var a=t("./limiters/CountLimiter");Object.defineProperty(r,"CountLimiter",{enumerable:!0,get:function(){return n(a).default}});var u=t("./limiters/TimeLimiter");Object.defineProperty(r,"TimeLimiter",{enumerable:!0,get:function(){return n(u).default}})},{"./BasePrepare":177,"./canvas/CanvasPrepare":178,"./limiters/CountLimiter":180,"./limiters/TimeLimiter":181,"./webgl/WebGLPrepare":182}],180:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(e){(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.maxItemsPerFrame=e,this.itemsLeft=0}return t.prototype.beginFrame=function(){this.itemsLeft=this.maxItemsPerFrame},t.prototype.allowedToUpload=function(){return this.itemsLeft-- >0},t}();r.default=n},{}],181:[function(t,e,r){"use strict";r.__esModule=!0;var n=function(){function t(e){(function(t,e){if(!(t instanceof e))throw new TypeError("Cannot call a class as a function")})(this,t),this.maxMilliseconds=e,this.frameStart=0}return t.prototype.beginFrame=function(){this.frameStart=Date.now()},t.prototype.allowedToUpload=function(){return Date.now()-this.frameStartr;)i[r]=e[r++];return i},Rt=function(t,e,r){j(t,e,{get:function(){return this._d[r]}})},Ot=function(t){var e,r,n,i,o,s,a=w(t),u=arguments.length,h=u>1?arguments[1]:void 0,c=void 0!==h,f=C(a);if(void 0!=f&&!T(f)){for(s=f.call(a),n=[],e=0;!(o=s.next()).done;e++)n.push(o.value);a=n}for(c&&u>2&&(h=l(h,arguments[2],2)),e=0,r=g(a.length),i=At(this,r);r>e;e++)i[e]=c?h(a[e],e):a[e];return i},Pt=function(){for(var t=0,e=arguments.length,r=At(this,e);e>t;)r[t]=arguments[t++];return r},Dt=!!X&&o(function(){pt.call(new X(1))}),It=function(){return pt.apply(Dt?ct.call(St(this)):St(this),arguments)},Lt={copyWithin:function(t,e){return N.call(St(this),t,e,arguments.length>2?arguments[2]:void 0)},every:function(t){return J(St(this),t,arguments.length>1?arguments[1]:void 0)},fill:function(t){return B.apply(St(this),arguments)},filter:function(t){return Ct(this,Z(St(this),t,arguments.length>1?arguments[1]:void 0))},find:function(t){return Q(St(this),t,arguments.length>1?arguments[1]:void 0)},findIndex:function(t){return tt(St(this),t,arguments.length>1?arguments[1]:void 0)},forEach:function(t){q(St(this),t,arguments.length>1?arguments[1]:void 0)},indexOf:function(t){return rt(St(this),t,arguments.length>1?arguments[1]:void 0)},includes:function(t){return et(St(this),t,arguments.length>1?arguments[1]:void 0)},join:function(t){return lt.apply(St(this),arguments)},lastIndexOf:function(t){return st.apply(St(this),arguments)},map:function(t){return _t(St(this),t,arguments.length>1?arguments[1]:void 0)},reduce:function(t){return at.apply(St(this),arguments)},reduceRight:function(t){return ut.apply(St(this),arguments)},reverse:function(){for(var t,e=St(this).length,r=Math.floor(e/2),n=0;n1?arguments[1]:void 0)},sort:function(t){return ht.call(St(this),t)},subarray:function(t,e){var r=St(this),n=r.length,i=m(t,n);return new(D(r,r[mt]))(r.buffer,r.byteOffset+i*r.BYTES_PER_ELEMENT,g((void 0===e?n:m(e,n))-i))}},Ft=function(t,e){return Ct(this,ct.call(St(this),t,e))},kt=function(t){St(this);var e=Et(arguments[1],1),r=this.length,n=w(t),i=g(n.length),o=0;if(i+e>r)throw W("Wrong length!");for(;o255?255:255&n),i.v[p](r*e+i.o,n,wt)}(this,r,t)},enumerable:!0})};x?(d=r(function(t,r,n,i){h(t,d,l,"_d");var o,s,a,u,c=0,p=0;if(_(r)){if(!(r instanceof Y||"ArrayBuffer"==(u=b(r))||"SharedArrayBuffer"==u))return xt in r?Mt(d,r):Ot.call(d,r);o=r,p=Et(n,e);var m=r.byteLength;if(void 0===i){if(m%e)throw W("Wrong length!");if((s=m-p)<0)throw W("Wrong length!")}else if((s=g(i)*e)+p>m)throw W("Wrong length!");a=s/e}else a=v(r),o=new Y(s=a*e);for(f(t,"_d",{b:o,o:p,l:s,e:a,v:new H(o)});c>1,h=23===e?C(2,-24)-C(2,-77):0,c=0,f=t<0||0===t&&1/t<0?1:0;for((t=A(t))!=t||t===E?(i=t!=t?1:0,n=u):(n=M(R(t)/O),t*(o=C(2,-n))<1&&(n--,o*=2),(t+=n+l>=1?h/o:h*C(2,1-l))*o>=2&&(n++,o/=2),n+l>=u?(i=0,n=u):n+l>=1?(i=(t*o-1)*C(2,e),n+=l):(i=t*C(2,l-1)*C(2,e),n=0));e>=8;s[c++]=255&i,i/=256,e-=8);for(n=n<0;s[c++]=255&n,n/=256,a-=8);return s[--c]|=128*f,s}function F(t,e,r){var n,i=8*r-e-1,o=(1<>1,a=i-7,u=r-1,l=t[u--],h=127&l;for(l>>=7;a>0;h=256*h+t[u],u--,a-=8);for(n=h&(1<<-a)-1,h>>=-a,a+=e;a>0;n=256*n+t[u],u--,a-=8);if(0===h)h=1-s;else{if(h===o)return n?NaN:l?-E:E;n+=C(2,e),h-=s}return(l?-1:1)*n*C(2,h-e)}function k(t){return t[3]<<24|t[2]<<16|t[1]<<8|t[0]}function B(t){return[255&t]}function N(t){return[255&t,t>>8&255]}function U(t){return[255&t,t>>8&255,t>>16&255,t>>24&255]}function $(t){return L(t,52,8)}function j(t){return L(t,23,4)}function G(t,e,r){g(t[y],e,{get:function(){return this[r]}})}function W(t,e,r,n){var i=p(+r);if(i+e>t[D])throw T(x);var o=t[P]._b,s=i+t[I],a=o.slice(s,s+e);return n?a:a.reverse()}function V(t,e,r,n,i,o){var s=p(+r);if(s+e>t[D])throw T(x);for(var a=t[P]._b,u=s+t[I],l=n(+i),h=0;hH;)(X=Y[H++])in b||a(b,X,S[X]);o||(z.constructor=b)}var q=new _(new b(2)),Z=_[y].setInt8;q.setInt8(0,2147483648),q.setInt8(1,2147483649),!q.getInt8(0)&&q.getInt8(1)||u(_[y],{setInt8:function(t,e){Z.call(this,t,e<<24>>24)},setUint8:function(t,e){Z.call(this,t,e<<24>>24)}},!0)}else b=function(t){h(this,b,"ArrayBuffer");var e=p(t);this._b=v.call(new Array(e),0),this[D]=e},_=function(t,e,r){h(this,_,"DataView"),h(t,b,"DataView");var n=t[D],i=c(e);if(i<0||i>n)throw T("Wrong offset!");if(i+(r=void 0===r?n-i:f(r))>n)throw T("Wrong length!");this[P]=t,this[I]=i,this[D]=r},i&&(G(b,"byteLength","_l"),G(_,"buffer","_b"),G(_,"byteLength","_l"),G(_,"byteOffset","_o")),u(_[y],{getInt8:function(t){return W(this,1,t)[0]<<24>>24},getUint8:function(t){return W(this,1,t)[0]},getInt16:function(t){var e=W(this,2,t,arguments[1]);return(e[1]<<8|e[0])<<16>>16},getUint16:function(t){var e=W(this,2,t,arguments[1]);return e[1]<<8|e[0]},getInt32:function(t){return k(W(this,4,t,arguments[1]))},getUint32:function(t){return k(W(this,4,t,arguments[1]))>>>0},getFloat32:function(t){return F(W(this,4,t,arguments[1]),23,4)},getFloat64:function(t){return F(W(this,8,t,arguments[1]),52,8)},setInt8:function(t,e){V(this,1,t,B,e)},setUint8:function(t,e){V(this,1,t,B,e)},setInt16:function(t,e){V(this,2,t,N,e,arguments[2])},setUint16:function(t,e){V(this,2,t,N,e,arguments[2])},setInt32:function(t,e){V(this,4,t,U,e,arguments[2])},setUint32:function(t,e){V(this,4,t,U,e,arguments[2])},setFloat32:function(t,e){V(this,4,t,j,e,arguments[2])},setFloat64:function(t,e){V(this,8,t,$,e,arguments[2])}});m(b,"ArrayBuffer"),m(_,"DataView"),a(_[y],s.VIEW,!0),e.ArrayBuffer=b,e.DataView=_},"7VC1":function(t,e,r){"use strict";var n=r("XKFU"),i=r("Lgjv"),o=r("ol8x");n(n.P+n.F*/Version\/10\.\d+(\.\d+)? Safari\//.test(o),"String",{padEnd:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0,!1)}})},"7X58":function(t,e,r){var n=r("XKFU");n(n.S,"Math",{signbit:function(t){return(t=+t)!=t?t:0==t?1/t==1/0:t>0}})},"7h0T":function(t,e,r){var n=r("XKFU");n(n.S,"Number",{isNaN:function(t){return t!=t}})},"8+KV":function(t,e,r){"use strict";var n=r("XKFU"),i=r("CkkT")(0),o=r("LyE8")([].forEach,!0);n(n.P+n.F*!o,"Array",{forEach:function(t){return i(this,t,arguments[1])}})},"84bF":function(t,e,r){"use strict";r("OGtf")("small",function(t){return function(){return t(this,"small","","")}})},"86LW":function(t,e,r){(function(e){!function(e){"use strict";var r,n=Object.prototype,i=n.hasOwnProperty,o="function"==typeof Symbol?Symbol:{},s=o.iterator||"@@iterator",a=o.asyncIterator||"@@asyncIterator",u=o.toStringTag||"@@toStringTag",l="object"==typeof t,h=e.regeneratorRuntime;if(h)l&&(t.exports=h);else{(h=e.regeneratorRuntime=l?t.exports:{}).wrap=b;var c="suspendedStart",f="suspendedYield",p="executing",d="completed",g={},v={};v[s]=function(){return this};var m=Object.getPrototypeOf,y=m&&m(m(P([])));y&&y!==n&&i.call(y,s)&&(v=y);var x=E.prototype=w.prototype=Object.create(v);T.prototype=x.constructor=E,E.constructor=T,E[u]=T.displayName="GeneratorFunction",h.isGeneratorFunction=function(t){var e="function"==typeof t&&t.constructor;return!!e&&(e===T||"GeneratorFunction"===(e.displayName||e.name))},h.mark=function(t){return Object.setPrototypeOf?Object.setPrototypeOf(t,E):(t.__proto__=E,u in t||(t[u]="GeneratorFunction")),t.prototype=Object.create(x),t},h.awrap=function(t){return{__await:t}},S(A.prototype),A.prototype[a]=function(){return this},h.AsyncIterator=A,h.async=function(t,e,r,n){var i=new A(b(t,e,r,n));return h.isGeneratorFunction(e)?i:i.next().then(function(t){return t.done?t.value:i.next()})},S(x),x[u]="Generator",x[s]=function(){return this},x.toString=function(){return"[object Generator]"},h.keys=function(t){var e=[];for(var r in t)e.push(r);return e.reverse(),function r(){for(;e.length;){var n=e.pop();if(n in t)return r.value=n,r.done=!1,r}return r.done=!0,r}},h.values=P,O.prototype={constructor:O,reset:function(t){if(this.prev=0,this.next=0,this.sent=this._sent=r,this.done=!1,this.delegate=null,this.method="next",this.arg=r,this.tryEntries.forEach(R),!t)for(var e in this)"t"===e.charAt(0)&&i.call(this,e)&&!isNaN(+e.slice(1))&&(this[e]=r)},stop:function(){this.done=!0;var t=this.tryEntries[0].completion;if("throw"===t.type)throw t.arg;return this.rval},dispatchException:function(t){if(this.done)throw t;var e=this;function n(n,i){return a.type="throw",a.arg=t,e.next=n,i&&(e.method="next",e.arg=r),!!i}for(var o=this.tryEntries.length-1;o>=0;--o){var s=this.tryEntries[o],a=s.completion;if("root"===s.tryLoc)return n("end");if(s.tryLoc<=this.prev){var u=i.call(s,"catchLoc"),l=i.call(s,"finallyLoc");if(u&&l){if(this.prev=0;--r){var n=this.tryEntries[r];if(n.tryLoc<=this.prev&&i.call(n,"finallyLoc")&&this.prev=0;--e){var r=this.tryEntries[e];if(r.finallyLoc===t)return this.complete(r.completion,r.afterLoc),R(r),g}},catch:function(t){for(var e=this.tryEntries.length-1;e>=0;--e){var r=this.tryEntries[e];if(r.tryLoc===t){var n=r.completion;if("throw"===n.type){var i=n.arg;R(r)}return i}}throw new Error("illegal catch attempt")},delegateYield:function(t,e,n){return this.delegate={iterator:P(t),resultName:e,nextLoc:n},"next"===this.method&&(this.arg=r),g}}}function b(t,e,r,n){var i=e&&e.prototype instanceof w?e:w,o=Object.create(i.prototype),s=new O(n||[]);return o._invoke=function(t,e,r){var n=c;return function(i,o){if(n===p)throw new Error("Generator is already running");if(n===d){if("throw"===i)throw o;return D()}for(r.method=i,r.arg=o;;){var s=r.delegate;if(s){var a=C(s,r);if(a){if(a===g)continue;return a}}if("next"===r.method)r.sent=r._sent=r.arg;else if("throw"===r.method){if(n===c)throw n=d,r.arg;r.dispatchException(r.arg)}else"return"===r.method&&r.abrupt("return",r.arg);n=p;var u=_(t,e,r);if("normal"===u.type){if(n=r.done?d:f,u.arg===g)continue;return{value:u.arg,done:r.done}}"throw"===u.type&&(n=d,r.method="throw",r.arg=u.arg)}}}(t,r,s),o}function _(t,e,r){try{return{type:"normal",arg:t.call(e,r)}}catch(t){return{type:"throw",arg:t}}}function w(){}function T(){}function E(){}function S(t){["next","throw","return"].forEach(function(e){t[e]=function(t){return this._invoke(e,t)}})}function A(t){function r(e,n,o,s){var a=_(t[e],t,n);if("throw"!==a.type){var u=a.arg,l=u.value;return l&&"object"==typeof l&&i.call(l,"__await")?Promise.resolve(l.__await).then(function(t){r("next",t,o,s)},function(t){r("throw",t,o,s)}):Promise.resolve(l).then(function(t){u.value=t,o(u)},s)}s(a.arg)}var n;"object"==typeof e.process&&e.process.domain&&(r=e.process.domain.bind(r)),this._invoke=function(t,e){function i(){return new Promise(function(n,i){r(t,e,n,i)})}return n=n?n.then(i,i):i()}}function C(t,e){var n=t.iterator[e.method];if(n===r){if(e.delegate=null,"throw"===e.method){if(t.iterator.return&&(e.method="return",e.arg=r,C(t,e),"throw"===e.method))return g;e.method="throw",e.arg=new TypeError("The iterator does not provide a 'throw' method")}return g}var i=_(n,t.iterator,e.arg);if("throw"===i.type)return e.method="throw",e.arg=i.arg,e.delegate=null,g;var o=i.arg;return o?o.done?(e[t.resultName]=o.value,e.next=t.nextLoc,"return"!==e.method&&(e.method="next",e.arg=r),e.delegate=null,g):o:(e.method="throw",e.arg=new TypeError("iterator result is not an object"),e.delegate=null,g)}function M(t){var e={tryLoc:t[0]};1 in t&&(e.catchLoc=t[1]),2 in t&&(e.finallyLoc=t[2],e.afterLoc=t[3]),this.tryEntries.push(e)}function R(t){var e=t.completion||{};e.type="normal",delete e.arg,t.completion=e}function O(t){this.tryEntries=[{tryLoc:"root"}],t.forEach(M,this),this.reset(!0)}function P(t){if(t){var e=t[s];if(e)return e.call(t);if("function"==typeof t.next)return t;if(!isNaN(t.length)){var n=-1,o=function e(){for(;++n1)for(var r=1;r0?arguments[0]:void 0)}},{get:function(t){var e=n.getEntry(i(this,"Map"),t);return e&&e.v},set:function(t,e){return n.def(i(this,"Map"),0===t?0:t,e)}},n,!0)},"9P93":function(t,e,r){var n=r("XKFU"),i=Math.imul;n(n.S+n.F*r("eeVq")(function(){return-5!=i(4294967295,5)||2!=i.length}),"Math",{imul:function(t,e){var r=+t,n=+e,i=65535&r,o=65535&n;return 0|i*o+((65535&r>>>16)*o+i*(65535&n>>>16)<<16>>>0)}})},"9VmF":function(t,e,r){"use strict";var n=r("XKFU"),i=r("ne8i"),o=r("0sh+"),s="".startsWith;n(n.P+n.F*r("UUeW")("startsWith"),"String",{startsWith:function(t){var e=o(this,t,"startsWith"),r=i(Math.min(arguments.length>1?arguments[1]:void 0,e.length)),n=String(t);return s?s.call(e,n,r):e.slice(r,r+n.length)===n}})},"9XZr":function(t,e,r){"use strict";var n=r("XKFU"),i=r("Lgjv"),o=r("ol8x");n(n.P+n.F*/Version\/10\.\d+(\.\d+)? Safari\//.test(o),"String",{padStart:function(t){return i(this,t,arguments.length>1?arguments[1]:void 0,!0)}})},"9gX7":function(t,e){t.exports=function(t,e,r,n){if(!(t instanceof e)||void 0!==n&&n in t)throw TypeError(r+": incorrect invocation!");return t}},"9rMk":function(t,e,r){var n=r("XKFU");n(n.S,"Reflect",{has:function(t,e){return e in t}})},"9tPo":function(t,e){t.exports=function(t){var e="undefined"!=typeof window&&window.location;if(!e)throw new Error("fixUrls requires window.location");if(!t||"string"!=typeof t)return t;var r=e.protocol+"//"+e.host,n=r+e.pathname.replace(/\/[^\/]*$/,"/");return t.replace(/url\s*\(((?:[^)(]|\((?:[^)(]+|\([^)(]*\))*\))*)\)/gi,function(t,e){var i,o=e.trim().replace(/^"(.*)"$/,function(t,e){return e}).replace(/^'(.*)'$/,function(t,e){return e});return/^(#|data:|http:\/\/|https:\/\/|file:\/\/\/|\s*$)/i.test(o)?t:(i=0===o.indexOf("//")?o:0===o.indexOf("/")?r+o:n+o.replace(/^\.\//,""),"url("+JSON.stringify(i)+")")})}},A2zW:function(t,e,r){"use strict";var n=r("XKFU"),i=r("RYi7"),o=r("vvmO"),s=r("l0Rn"),a=1..toFixed,u=Math.floor,l=[0,0,0,0,0,0],h="Number.toFixed: incorrect invocation!",c=function(t,e){for(var r=-1,n=e;++r<6;)n+=t*l[r],l[r]=n%1e7,n=u(n/1e7)},f=function(t){for(var e=6,r=0;--e>=0;)r+=l[e],l[e]=u(r/t),r=r%t*1e7},p=function(){for(var t=6,e="";--t>=0;)if(""!==e||0===t||0!==l[t]){var r=String(l[t]);e=""===e?r:e+s.call("0",7-r.length)+r}return e},d=function(t,e,r){return 0===e?r:e%2==1?d(t,e-1,r*t):d(t*t,e/2,r)};n(n.P+n.F*(!!a&&("0.000"!==8e-5.toFixed(3)||"1"!==.9.toFixed(0)||"1.25"!==1.255.toFixed(2)||"1000000000000000128"!==(0xde0b6b3a7640080).toFixed(0))||!r("eeVq")(function(){a.call({})})),"Number",{toFixed:function(t){var e,r,n,a,u=o(this,h),l=i(t),g="",v="0";if(l<0||l>20)throw RangeError(h);if(u!=u)return"NaN";if(u<=-1e21||u>=1e21)return String(u);if(u<0&&(g="-",u=-u),u>1e-21)if(r=(e=function(t){for(var e=0,r=t;r>=4096;)e+=12,r/=4096;for(;r>=2;)e+=1,r/=2;return e}(u*d(2,69,1))-69)<0?u*d(2,-e,1):u/d(2,e,1),r*=4503599627370496,(e=52-e)>0){for(c(0,r),n=l;n>=7;)c(1e7,0),n-=7;for(c(d(10,n,1),0),n=e-1;n>=23;)f(1<<23),n-=23;f(1<0?g+((a=v.length)<=l?"0."+s.call("0",l-a)+v:v.slice(0,a-l)+"."+v.slice(a-l)):g+v}})},Afnz:function(t,e,r){"use strict";var n=r("LQAc"),i=r("XKFU"),o=r("KroJ"),s=r("Mukb"),a=r("aagx"),u=r("hPIQ"),l=r("QaDb"),h=r("fyDq"),c=r("OP3Y"),f=r("K0xU")("iterator"),p=!([].keys&&"next"in[].keys()),d=function(){return this};t.exports=function(t,e,r,g,v,m,y){l(r,e,g);var x,b,_,w=function(t){if(!p&&t in A)return A[t];switch(t){case"keys":case"values":return function(){return new r(this,t)}}return function(){return new r(this,t)}},T=e+" Iterator",E="values"==v,S=!1,A=t.prototype,C=A[f]||A["@@iterator"]||v&&A[v],M=!p&&C||w(v),R=v?E?w("entries"):M:void 0,O="Array"==e&&A.entries||C;if(O&&(_=c(O.call(new t)))!==Object.prototype&&_.next&&(h(_,T,!0),n||a(_,f)||s(_,f,d)),E&&C&&"values"!==C.name&&(S=!0,M=function(){return C.call(this)}),n&&!y||!p&&!S&&A[f]||s(A,f,M),u[e]=M,u[T]=d,v)if(x={values:E?M:w("values"),keys:m?M:w("keys"),entries:R},y)for(b in x)b in A||o(A,b,x[b]);else i(i.P+i.F*(p||S),e,x);return x}},AhwK:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAgAAAAMCAYAAABfnvydAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyZpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNi1jMDY3IDc5LjE1Nzc0NywgMjAxNS8wMy8zMC0yMzo0MDo0MiAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIDIwMTUgKFdpbmRvd3MpIiB4bXBNTTpJbnN0YW5jZUlEPSJ4bXAuaWlkOkI3QjQ5NEY1NUQxNTExRTU4MTRBRUMxOTgyQjAzQTRDIiB4bXBNTTpEb2N1bWVudElEPSJ4bXAuZGlkOkI3QjQ5NEY2NUQxNTExRTU4MTRBRUMxOTgyQjAzQTRDIj4gPHhtcE1NOkRlcml2ZWRGcm9tIHN0UmVmOmluc3RhbmNlSUQ9InhtcC5paWQ6QjdCNDk0RjM1RDE1MTFFNTgxNEFFQzE5ODJCMDNBNEMiIHN0UmVmOmRvY3VtZW50SUQ9InhtcC5kaWQ6QjdCNDk0RjQ1RDE1MTFFNTgxNEFFQzE5ODJCMDNBNEMiLz4gPC9yZGY6RGVzY3JpcHRpb24+IDwvcmRmOlJERj4gPC94OnhtcG1ldGE+IDw/eHBhY2tldCBlbmQ9InIiPz4OvBgYAAAAV0lEQVR42mL4////fCDmAmIGbBhEgMBlINbBpwAEvgJxAjYFCVBJGECxEqZSB2oNDFyHWYlsHBdUN4qVTAz4ASNMtxY+K7A5kockb4LAFXwBhTeoAQIMANSqJvRPPg1/AAAAAElFTkSuQmCC"},AphP:function(t,e,r){"use strict";var n=r("XKFU"),i=r("S/j/"),o=r("apmT");n(n.P+n.F*r("eeVq")(function(){return null!==new Date(NaN).toJSON()||1!==Date.prototype.toJSON.call({toISOString:function(){return 1}})}),"Date",{toJSON:function(t){var e=i(this),r=o(e);return"number"!=typeof r||isFinite(r)?e.toISOString():null}})},AvRE:function(t,e,r){var n=r("RYi7"),i=r("vhPU");t.exports=function(t){return function(e,r){var o,s,a=String(i(e)),u=n(r),l=a.length;return u<0||u>=l?t?"":void 0:(o=a.charCodeAt(u))<55296||o>56319||u+1===l||(s=a.charCodeAt(u+1))<56320||s>57343?t?a.charAt(u):o:t?a.slice(u,u+2):s-56320+(o-55296<<10)+65536}}},AyUB:function(t,e,r){t.exports={default:r("3GJH"),__esModule:!0}},"B+OT":function(t,e){var r={}.hasOwnProperty;t.exports=function(t,e){return r.call(t,e)}},BC7C:function(t,e,r){var n=r("XKFU");n(n.S,"Math",{fround:r("kcoS")})},"BJ/l":function(t,e,r){var n=r("XKFU");n(n.S,"Math",{log1p:r("1sa7")})},BP8U:function(t,e,r){var n=r("XKFU"),i=r("PKUr");n(n.S+n.F*(Number.parseInt!=i),"Number",{parseInt:i})},BqfV:function(t,e,r){var n=r("N6cJ"),i=r("y3w9"),o=n.get,s=n.key;n.exp({getOwnMetadata:function(t,e){return o(t,i(e),arguments.length<3?void 0:s(arguments[2]))}})},Btvt:function(t,e,r){"use strict";var n=r("I8a+"),i={};i[r("K0xU")("toStringTag")]="z",i+""!="[object z]"&&r("KroJ")(Object.prototype,"toString",function(){return"[object "+n(this)+"]"},!0)},"Bzw/":function(t){t.exports={cgPlayer:{gameInformation:"Game information:",outputStream:"Standard output stream:",errorStream:"Standard error stream:",gameParameters:"Game parameters:",speed:"SPEED",quality:"QUALITY",ToolTipIcons:{options:"Settings",replay:"Replay and share",fullscreen:"Fullscreen",extract:"Extract"},share:"Share this replay"}}},"C/va":function(t,e,r){"use strict";var n=r("y3w9");t.exports=function(){var t=n(this),e="";return t.global&&(e+="g"),t.ignoreCase&&(e+="i"),t.multiline&&(e+="m"),t.unicode&&(e+="u"),t.sticky&&(e+="y"),e}},CFt4:function(t,e){t.exports="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAAwAAAAMCAYAAABWdVznAAAAGXRFWHRTb2Z0d2FyZQBBZG9iZSBJbWFnZVJlYWR5ccllPAAAAyFpVFh0WE1MOmNvbS5hZG9iZS54bXAAAAAAADw/eHBhY2tldCBiZWdpbj0i77u/IiBpZD0iVzVNME1wQ2VoaUh6cmVTek5UY3prYzlkIj8+IDx4OnhtcG1ldGEgeG1sbnM6eD0iYWRvYmU6bnM6bWV0YS8iIHg6eG1wdGs9IkFkb2JlIFhNUCBDb3JlIDUuNS1jMDIxIDc5LjE1NDkxMSwgMjAxMy8xMC8yOS0xMTo0NzoxNiAgICAgICAgIj4gPHJkZjpSREYgeG1sbnM6cmRmPSJodHRwOi8vd3d3LnczLm9yZy8xOTk5LzAyLzIyLXJkZi1zeW50YXgtbnMjIj4gPHJkZjpEZXNjcmlwdGlvbiByZGY6YWJvdXQ9IiIgeG1sbnM6eG1wPSJodHRwOi8vbnMuYWRvYmUuY29tL3hhcC8xLjAvIiB4bWxuczp4bXBNTT0iaHR0cDovL25zLmFkb2JlLmNvbS94YXAvMS4wL21tLyIgeG1sbnM6c3RSZWY9Imh0dHA6Ly9ucy5hZG9iZS5jb20veGFwLzEuMC9zVHlwZS9SZXNvdXJjZVJlZiMiIHhtcDpDcmVhdG9yVG9vbD0iQWRvYmUgUGhvdG9zaG9wIENDIChXaW5kb3dzKSIgeG1wTU06SW5zdGFuY2VJRD0ieG1wLmlpZDoyNzU2MDMwOTBEOEYxMUU0ODJBREEyNjQ3QjA4QUIwNiIgeG1wTU06RG9jdW1lbnRJRD0ieG1wLmRpZDoyNzU2MDMwQTBEOEYxMUU0ODJBREEyNjQ3QjA4QUIwNiI+IDx4bXBNTTpEZXJpdmVkRnJvbSBzdFJlZjppbnN0YW5jZUlEPSJ4bXAuaWlkOjI3NTYwMzA3MEQ4RjExRTQ4MkFEQTI2NDdCMDhBQjA2IiBzdFJlZjpkb2N1bWVudElEPSJ4bXAuZGlkOjI3NTYwMzA4MEQ4RjExRTQ4MkFEQTI2NDdCMDhBQjA2Ii8+IDwvcmRmOkRlc2NyaXB0aW9uPiA8L3JkZjpSREY+IDwveDp4bXBtZXRhPiA8P3hwYWNrZXQgZW5kPSJyIj8+Btk+lAAAAIpJREFUeNqEUosKgCAMnEH9c/bQoD46CmyrG8hQOzhx3t1U1KWUIhENTE9tHMy74+Fkjlhomf3r5R2EY/pwoM65Q5ukzgUPYa+ZbYAgaEjNc+6hwhE0JFis3hUu2FfmH0yHiM4rugu22pFys66tNqRCgBAKd9JQ1EDLbBtGJ4+Gr7H9fI3AvB4BBgCy5Uy3Msd8OAAAAABJRU5ErkJggg=="},CX2u:function(t,e,r){"use strict";var n=r("XKFU"),i=r("g3g5"),o=r("dyZX"),s=r("69bn"),a=r("vKrd");n(n.P+n.R,"Promise",{finally:function(t){var e=s(this,i.Promise||o.Promise),r="function"==typeof t;return this.then(r?function(r){return a(e,t()).then(function(){return r})}:t,r?function(r){return a(e,t()).then(function(){throw r})}:t)}})},CeCd:function(t,e,r){var n=r("XKFU");n(n.S,"Math",{clamp:function(t,e,r){return Math.min(r,Math.max(e,t))}})},Cfrj:function(t,e,r){var n=r("RYi7"),i=r("ne8i");t.exports=function(t){if(void 0===t)return 0;var e=n(t),r=i(e);if(e!==r)throw RangeError("Wrong length!");return r}},CfyG:function(t,e,r){(function(t){var n=Function.prototype.apply;function i(t,e){this._id=t,this._clearFn=e}e.setTimeout=function(){return new i(n.call(setTimeout,window,arguments),clearTimeout)},e.setInterval=function(){return new i(n.call(setInterval,window,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(window,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))},r("YBdB"),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,r("yLpj"))},CkkT:function(t,e,r){var n=r("m0Pp"),i=r("Ymqv"),o=r("S/j/"),s=r("ne8i"),a=r("zRwo");t.exports=function(t,e){var r=1==t,u=2==t,l=3==t,h=4==t,c=6==t,f=5==t||c,p=e||a;return function(e,a,d){for(var g,v,m=o(e),y=i(m),x=n(a,d,3),b=s(y.length),_=0,w=r?p(e,b):u?p(e,0):void 0;b>_;_++)if((f||_ in y)&&(v=x(g=y[_],_,m),t))if(r)w[_]=v;else if(v)switch(t){case 3:return!0;case 5:return g;case 6:return _;case 2:w.push(g)}else if(h)return!1;return c?-1:l||h?h:w}}},CyHz:function(t,e,r){var n=r("XKFU");n(n.S,"Math",{sign:r("lvtm")})},D3Ub:function(t,e,r){"use strict";e.__esModule=!0;var n,i=r("4d7F"),o=(n=i)&&n.__esModule?n:{default:n};e.default=function(t){return function(){var e=t.apply(this,arguments);return new o.default(function(t,r){return function n(i,s){try{var a=e[i](s),u=a.value}catch(t){return void r(t)}if(!a.done)return o.default.resolve(u).then(function(t){n("next",t)},function(t){n("throw",t)});t(u)}("next")})}}},D4iV:function(t,e,r){for(var n,i=r("dyZX"),o=r("Mukb"),s=r("ylqs"),a=s("typed_array"),u=s("view"),l=!(!i.ArrayBuffer||!i.DataView),h=l,c=0,f="Int8Array,Uint8Array,Uint8ClampedArray,Int16Array,Uint16Array,Int32Array,Uint32Array,Float32Array,Float64Array".split(",");c<9;)(n=i[f[c++]])?(o(n.prototype,a,!0),o(n.prototype,u,!0)):h=!1;t.exports={ABV:l,CONSTR:h,TYPED:a,VIEW:u}},D8kY:function(t,e,r){var n=r("Ojgd"),i=Math.max,o=Math.min;t.exports=function(t,e){return(t=n(t))<0?i(t+e,0):o(t,e)}},DACs:function(t,e,r){var n=r("XKFU");n(n.S,"Math",{DEG_PER_RAD:Math.PI/180})},DDYI:function(t,e,r){var n=r("XKFU");n(n.G,{global:r("dyZX")})},DNiP:function(t,e,r){"use strict";var n=r("XKFU"),i=r("eyMr");n(n.P+n.F*!r("LyE8")([].reduce,!0),"Array",{reduce:function(t){return i(this,t,arguments.length,arguments[1],!1)}})},DSV3:function(t,e,r){var n=r("XKFU"),i=r("gHnn")(),o=r("dyZX").process,s="process"==r("LZWt")(o);n(n.G,{asap:function(t){var e=s&&o.domain;i(e?e.bind(t):t)}})},DVgA:function(t,e,r){var n=r("zhAb"),i=r("4R4u");t.exports=Object.keys||function(t){return n(t,i)}},DW2E:function(t,e,r){var n=r("0/R4"),i=r("Z6vF").onFreeze;r("Xtr8")("freeze",function(t){return function(e){return t&&n(e)?t(i(e)):e}})},EK0E:function(t,e,r){"use strict";var n,i=r("CkkT")(0),o=r("KroJ"),s=r("Z6vF"),a=r("czNK"),u=r("ZD67"),l=r("0/R4"),h=r("eeVq"),c=r("s5qY"),f=s.getWeak,p=Object.isExtensible,d=u.ufstore,g={},v=function(t){return function(){return t(this,arguments.length>0?arguments[0]:void 0)}},m={get:function(t){if(l(t)){var e=f(t);return!0===e?d(c(this,"WeakMap")).get(t):e?e[this._i]:void 0}},set:function(t,e){return u.def(c(this,"WeakMap"),t,e)}},y=t.exports=r("4LiD")("WeakMap",v,m,u,!0,!0);h(function(){return 7!=(new y).set((Object.freeze||Object)(g),7).get(g)})&&(a((n=u.getConstructor(v,"WeakMap")).prototype,m),s.NEED=!0,i(["delete","has","get","set"],function(t){var e=y.prototype,r=e[t];o(e,t,function(e,i){if(l(e)&&!p(e)){this._f||(this._f=new n);var o=this._f[t](e,i);return"set"==t?this:o}return r.call(this,e,i)})}))},EVdn:function(t,e,r){var n; /*! * jQuery JavaScript Library v3.3.1 * https://jquery.com/ * * Includes Sizzle.js * https://sizzlejs.com/ * * Copyright JS Foundation and other contributors * Released under the MIT license * https://jquery.org/license * * Date: 2018-01-20T17:24Z */ /*! * jQuery JavaScript Library v3.3.1 * https://jquery.com/ * * Includes Sizzle.js * https://sizzlejs.com/ * * Copyright JS Foundation and other contributors * Released under the MIT license * https://jquery.org/license * * Date: 2018-01-20T17:24Z */ !function(e,r){"use strict";"object"==typeof t&&"object"==typeof t.exports?t.exports=e.document?r(e,!0):function(t){if(!t.document)throw new Error("jQuery requires a window with a document");return r(t)}:r(e)}("undefined"!=typeof window?window:this,function(r,i){"use strict";var o=[],s=r.document,a=Object.getPrototypeOf,u=o.slice,l=o.concat,h=o.push,c=o.indexOf,f={},p=f.toString,d=f.hasOwnProperty,g=d.toString,v=g.call(Object),m={},y=function(t){return"function"==typeof t&&"number"!=typeof t.nodeType},x=function(t){return null!=t&&t===t.window},b={type:!0,src:!0,noModule:!0};function _(t,e,r){var n,i=(e=e||s).createElement("script");if(i.text=t,r)for(n in b)r[n]&&(i[n]=r[n]);e.head.appendChild(i).parentNode.removeChild(i)}function w(t){return null==t?t+"":"object"==typeof t||"function"==typeof t?f[p.call(t)]||"object":typeof t}var T=function(t,e){return new T.fn.init(t,e)},E=/^[\s\uFEFF\xA0]+|[\s\uFEFF\xA0]+$/g;function S(t){var e=!!t&&"length"in t&&t.length,r=w(t);return!y(t)&&!x(t)&&("array"===r||0===e||"number"==typeof e&&e>0&&e-1 in t)}T.fn=T.prototype={jquery:"3.3.1",constructor:T,length:0,toArray:function(){return u.call(this)},get:function(t){return null==t?u.call(this):t<0?this[t+this.length]:this[t]},pushStack:function(t){var e=T.merge(this.constructor(),t);return e.prevObject=this,e},each:function(t){return T.each(this,t)},map:function(t){return this.pushStack(T.map(this,function(e,r){return t.call(e,r,e)}))},slice:function(){return this.pushStack(u.apply(this,arguments))},first:function(){return this.eq(0)},last:function(){return this.eq(-1)},eq:function(t){var e=this.length,r=+t+(t<0?e:0);return this.pushStack(r>=0&&r+~]|"+k+")"+k+"*"),V=new RegExp("="+k+"*([^\\]'\"]*?)"+k+"*\\]","g"),X=new RegExp(U),z=new RegExp("^"+B+"$"),Y={ID:new RegExp("^#("+B+")"),CLASS:new RegExp("^\\.("+B+")"),TAG:new RegExp("^("+B+"|[*])"),ATTR:new RegExp("^"+N),PSEUDO:new RegExp("^"+U),CHILD:new RegExp("^:(only|first|last|nth|nth-last)-(child|of-type)(?:\\("+k+"*(even|odd|(([+-]|)(\\d*)n|)"+k+"*(?:([+-]|)"+k+"*(\\d+)|))"+k+"*\\)|)","i"),bool:new RegExp("^(?:"+F+")$","i"),needsContext:new RegExp("^"+k+"*[>+~]|:(even|odd|eq|gt|lt|nth|first|last)(?:\\("+k+"*((?:-\\d)?\\d*)"+k+"*\\)|)(?=[^-]|$)","i")},H=/^(?:input|select|textarea|button)$/i,q=/^h\d$/i,Z=/^[^{]+\{\s*\[native \w/,K=/^(?:#([\w-]+)|(\w+)|\.([\w-]+))$/,J=/[+~]/,Q=new RegExp("\\\\([\\da-f]{1,6}"+k+"?|("+k+")|.)","ig"),tt=function(t,e,r){var n="0x"+e-65536;return n!=n||r?e:n<0?String.fromCharCode(n+65536):String.fromCharCode(n>>10|55296,1023&n|56320)},et=/([\0-\x1f\x7f]|^-?\d)|^-$|[^\0-\x1f\x7f-\uFFFF\w-]/g,rt=function(t,e){return e?"\0"===t?"�":t.slice(0,-1)+"\\"+t.charCodeAt(t.length-1).toString(16)+" ":"\\"+t},nt=function(){f()},it=yt(function(t){return!0===t.disabled&&("form"in t||"label"in t)},{dir:"parentNode",next:"legend"});try{D.apply(R=I.call(_.childNodes),_.childNodes),R[_.childNodes.length].nodeType}catch(t){D={apply:R.length?function(t,e){P.apply(t,I.call(e))}:function(t,e){for(var r=t.length,n=0;t[r++]=e[n++];);t.length=r-1}}}function ot(t,e,n,i){var o,a,l,h,c,d,m,y=e&&e.ownerDocument,w=e?e.nodeType:9;if(n=n||[],"string"!=typeof t||!t||1!==w&&9!==w&&11!==w)return n;if(!i&&((e?e.ownerDocument||e:_)!==p&&f(e),e=e||p,g)){if(11!==w&&(c=K.exec(t)))if(o=c[1]){if(9===w){if(!(l=e.getElementById(o)))return n;if(l.id===o)return n.push(l),n}else if(y&&(l=y.getElementById(o))&&x(e,l)&&l.id===o)return n.push(l),n}else{if(c[2])return D.apply(n,e.getElementsByTagName(t)),n;if((o=c[3])&&r.getElementsByClassName&&e.getElementsByClassName)return D.apply(n,e.getElementsByClassName(o)),n}if(r.qsa&&!A[t+" "]&&(!v||!v.test(t))){if(1!==w)y=e,m=t;else if("object"!==e.nodeName.toLowerCase()){for((h=e.getAttribute("id"))?h=h.replace(et,rt):e.setAttribute("id",h=b),a=(d=s(t)).length;a--;)d[a]="#"+h+" "+mt(d[a]);m=d.join(","),y=J.test(t)&>(e.parentNode)||e}if(m)try{return D.apply(n,y.querySelectorAll(m)),n}catch(t){}finally{h===b&&e.removeAttribute("id")}}}return u(t.replace(j,"$1"),e,n,i)}function st(){var t=[];return function e(r,i){return t.push(r+" ")>n.cacheLength&&delete e[t.shift()],e[r+" "]=i}}function at(t){return t[b]=!0,t}function ut(t){var e=p.createElement("fieldset");try{return!!t(e)}catch(t){return!1}finally{e.parentNode&&e.parentNode.removeChild(e),e=null}}function lt(t,e){for(var r=t.split("|"),i=r.length;i--;)n.attrHandle[r[i]]=e}function ht(t,e){var r=e&&t,n=r&&1===t.nodeType&&1===e.nodeType&&t.sourceIndex-e.sourceIndex;if(n)return n;if(r)for(;r=r.nextSibling;)if(r===e)return-1;return t?1:-1}function ct(t){return function(e){return"input"===e.nodeName.toLowerCase()&&e.type===t}}function ft(t){return function(e){var r=e.nodeName.toLowerCase();return("input"===r||"button"===r)&&e.type===t}}function pt(t){return function(e){return"form"in e?e.parentNode&&!1===e.disabled?"label"in e?"label"in e.parentNode?e.parentNode.disabled===t:e.disabled===t:e.isDisabled===t||e.isDisabled!==!t&&it(e)===t:e.disabled===t:"label"in e&&e.disabled===t}}function dt(t){return at(function(e){return e=+e,at(function(r,n){for(var i,o=t([],r.length,e),s=o.length;s--;)r[i=o[s]]&&(r[i]=!(n[i]=r[i]))})})}function gt(t){return t&&void 0!==t.getElementsByTagName&&t}for(e in r=ot.support={},o=ot.isXML=function(t){var e=t&&(t.ownerDocument||t).documentElement;return!!e&&"HTML"!==e.nodeName},f=ot.setDocument=function(t){var e,i,s=t?t.ownerDocument||t:_;return s!==p&&9===s.nodeType&&s.documentElement?(d=(p=s).documentElement,g=!o(p),_!==p&&(i=p.defaultView)&&i.top!==i&&(i.addEventListener?i.addEventListener("unload",nt,!1):i.attachEvent&&i.attachEvent("onunload",nt)),r.attributes=ut(function(t){return t.className="i",!t.getAttribute("className")}),r.getElementsByTagName=ut(function(t){return t.appendChild(p.createComment("")),!t.getElementsByTagName("*").length}),r.getElementsByClassName=Z.test(p.getElementsByClassName),r.getById=ut(function(t){return d.appendChild(t).id=b,!p.getElementsByName||!p.getElementsByName(b).length}),r.getById?(n.filter.ID=function(t){var e=t.replace(Q,tt);return function(t){return t.getAttribute("id")===e}},n.find.ID=function(t,e){if(void 0!==e.getElementById&&g){var r=e.getElementById(t);return r?[r]:[]}}):(n.filter.ID=function(t){var e=t.replace(Q,tt);return function(t){var r=void 0!==t.getAttributeNode&&t.getAttributeNode("id");return r&&r.value===e}},n.find.ID=function(t,e){if(void 0!==e.getElementById&&g){var r,n,i,o=e.getElementById(t);if(o){if((r=o.getAttributeNode("id"))&&r.value===t)return[o];for(i=e.getElementsByName(t),n=0;o=i[n++];)if((r=o.getAttributeNode("id"))&&r.value===t)return[o]}return[]}}),n.find.TAG=r.getElementsByTagName?function(t,e){return void 0!==e.getElementsByTagName?e.getElementsByTagName(t):r.qsa?e.querySelectorAll(t):void 0}:function(t,e){var r,n=[],i=0,o=e.getElementsByTagName(t);if("*"===t){for(;r=o[i++];)1===r.nodeType&&n.push(r);return n}return o},n.find.CLASS=r.getElementsByClassName&&function(t,e){if(void 0!==e.getElementsByClassName&&g)return e.getElementsByClassName(t)},m=[],v=[],(r.qsa=Z.test(p.querySelectorAll))&&(ut(function(t){d.appendChild(t).innerHTML="",t.querySelectorAll("[msallowcapture^='']").length&&v.push("[*^$]="+k+"*(?:''|\"\")"),t.querySelectorAll("[selected]").length||v.push("\\["+k+"*(?:value|"+F+")"),t.querySelectorAll("[id~="+b+"-]").length||v.push("~="),t.querySelectorAll(":checked").length||v.push(":checked"),t.querySelectorAll("a#"+b+"+*").length||v.push(".#.+[+~]")}),ut(function(t){t.innerHTML="";var e=p.createElement("input");e.setAttribute("type","hidden"),t.appendChild(e).setAttribute("name","D"),t.querySelectorAll("[name=d]").length&&v.push("name"+k+"*[*^$|!~]?="),2!==t.querySelectorAll(":enabled").length&&v.push(":enabled",":disabled"),d.appendChild(t).disabled=!0,2!==t.querySelectorAll(":disabled").length&&v.push(":enabled",":disabled"),t.querySelectorAll("*,:x"),v.push(",.*:")})),(r.matchesSelector=Z.test(y=d.matches||d.webkitMatchesSelector||d.mozMatchesSelector||d.oMatchesSelector||d.msMatchesSelector))&&ut(function(t){r.disconnectedMatch=y.call(t,"*"),y.call(t,"[s!='']:x"),m.push("!=",U)}),v=v.length&&new RegExp(v.join("|")),m=m.length&&new RegExp(m.join("|")),e=Z.test(d.compareDocumentPosition),x=e||Z.test(d.contains)?function(t,e){var r=9===t.nodeType?t.documentElement:t,n=e&&e.parentNode;return t===n||!(!n||1!==n.nodeType||!(r.contains?r.contains(n):t.compareDocumentPosition&&16&t.compareDocumentPosition(n)))}:function(t,e){if(e)for(;e=e.parentNode;)if(e===t)return!0;return!1},C=e?function(t,e){if(t===e)return c=!0,0;var n=!t.compareDocumentPosition-!e.compareDocumentPosition;return n||(1&(n=(t.ownerDocument||t)===(e.ownerDocument||e)?t.compareDocumentPosition(e):1)||!r.sortDetached&&e.compareDocumentPosition(t)===n?t===p||t.ownerDocument===_&&x(_,t)?-1:e===p||e.ownerDocument===_&&x(_,e)?1:h?L(h,t)-L(h,e):0:4&n?-1:1)}:function(t,e){if(t===e)return c=!0,0;var r,n=0,i=t.parentNode,o=e.parentNode,s=[t],a=[e];if(!i||!o)return t===p?-1:e===p?1:i?-1:o?1:h?L(h,t)-L(h,e):0;if(i===o)return ht(t,e);for(r=t;r=r.parentNode;)s.unshift(r);for(r=e;r=r.parentNode;)a.unshift(r);for(;s[n]===a[n];)n++;return n?ht(s[n],a[n]):s[n]===_?-1:a[n]===_?1:0},p):p},ot.matches=function(t,e){return ot(t,null,null,e)},ot.matchesSelector=function(t,e){if((t.ownerDocument||t)!==p&&f(t),e=e.replace(V,"='$1']"),r.matchesSelector&&g&&!A[e+" "]&&(!m||!m.test(e))&&(!v||!v.test(e)))try{var n=y.call(t,e);if(n||r.disconnectedMatch||t.document&&11!==t.document.nodeType)return n}catch(t){}return ot(e,p,null,[t]).length>0},ot.contains=function(t,e){return(t.ownerDocument||t)!==p&&f(t),x(t,e)},ot.attr=function(t,e){(t.ownerDocument||t)!==p&&f(t);var i=n.attrHandle[e.toLowerCase()],o=i&&M.call(n.attrHandle,e.toLowerCase())?i(t,e,!g):void 0;return void 0!==o?o:r.attributes||!g?t.getAttribute(e):(o=t.getAttributeNode(e))&&o.specified?o.value:null},ot.escape=function(t){return(t+"").replace(et,rt)},ot.error=function(t){throw new Error("Syntax error, unrecognized expression: "+t)},ot.uniqueSort=function(t){var e,n=[],i=0,o=0;if(c=!r.detectDuplicates,h=!r.sortStable&&t.slice(0),t.sort(C),c){for(;e=t[o++];)e===t[o]&&(i=n.push(o));for(;i--;)t.splice(n[i],1)}return h=null,t},i=ot.getText=function(t){var e,r="",n=0,o=t.nodeType;if(o){if(1===o||9===o||11===o){if("string"==typeof t.textContent)return t.textContent;for(t=t.firstChild;t;t=t.nextSibling)r+=i(t)}else if(3===o||4===o)return t.nodeValue}else for(;e=t[n++];)r+=i(e);return r},(n=ot.selectors={cacheLength:50,createPseudo:at,match:Y,attrHandle:{},find:{},relative:{">":{dir:"parentNode",first:!0}," ":{dir:"parentNode"},"+":{dir:"previousSibling",first:!0},"~":{dir:"previousSibling"}},preFilter:{ATTR:function(t){return t[1]=t[1].replace(Q,tt),t[3]=(t[3]||t[4]||t[5]||"").replace(Q,tt),"~="===t[2]&&(t[3]=" "+t[3]+" "),t.slice(0,4)},CHILD:function(t){return t[1]=t[1].toLowerCase(),"nth"===t[1].slice(0,3)?(t[3]||ot.error(t[0]),t[4]=+(t[4]?t[5]+(t[6]||1):2*("even"===t[3]||"odd"===t[3])),t[5]=+(t[7]+t[8]||"odd"===t[3])):t[3]&&ot.error(t[0]),t},PSEUDO:function(t){var e,r=!t[6]&&t[2];return Y.CHILD.test(t[0])?null:(t[3]?t[2]=t[4]||t[5]||"":r&&X.test(r)&&(e=s(r,!0))&&(e=r.indexOf(")",r.length-e)-r.length)&&(t[0]=t[0].slice(0,e),t[2]=r.slice(0,e)),t.slice(0,3))}},filter:{TAG:function(t){var e=t.replace(Q,tt).toLowerCase();return"*"===t?function(){return!0}:function(t){return t.nodeName&&t.nodeName.toLowerCase()===e}},CLASS:function(t){var e=E[t+" "];return e||(e=new RegExp("(^|"+k+")"+t+"("+k+"|$)"))&&E(t,function(t){return e.test("string"==typeof t.className&&t.className||void 0!==t.getAttribute&&t.getAttribute("class")||"")})},ATTR:function(t,e,r){return function(n){var i=ot.attr(n,t);return null==i?"!="===e:!e||(i+="","="===e?i===r:"!="===e?i!==r:"^="===e?r&&0===i.indexOf(r):"*="===e?r&&i.indexOf(r)>-1:"$="===e?r&&i.slice(-r.length)===r:"~="===e?(" "+i.replace($," ")+" ").indexOf(r)>-1:"|="===e&&(i===r||i.slice(0,r.length+1)===r+"-"))}},CHILD:function(t,e,r,n,i){var o="nth"!==t.slice(0,3),s="last"!==t.slice(-4),a="of-type"===e;return 1===n&&0===i?function(t){return!!t.parentNode}:function(e,r,u){var l,h,c,f,p,d,g=o!==s?"nextSibling":"previousSibling",v=e.parentNode,m=a&&e.nodeName.toLowerCase(),y=!u&&!a,x=!1;if(v){if(o){for(;g;){for(f=e;f=f[g];)if(a?f.nodeName.toLowerCase()===m:1===f.nodeType)return!1;d=g="only"===t&&!d&&"nextSibling"}return!0}if(d=[s?v.firstChild:v.lastChild],s&&y){for(x=(p=(l=(h=(c=(f=v)[b]||(f[b]={}))[f.uniqueID]||(c[f.uniqueID]={}))[t]||[])[0]===w&&l[1])&&l[2],f=p&&v.childNodes[p];f=++p&&f&&f[g]||(x=p=0)||d.pop();)if(1===f.nodeType&&++x&&f===e){h[t]=[w,p,x];break}}else if(y&&(x=p=(l=(h=(c=(f=e)[b]||(f[b]={}))[f.uniqueID]||(c[f.uniqueID]={}))[t]||[])[0]===w&&l[1]),!1===x)for(;(f=++p&&f&&f[g]||(x=p=0)||d.pop())&&((a?f.nodeName.toLowerCase()!==m:1!==f.nodeType)||!++x||(y&&((h=(c=f[b]||(f[b]={}))[f.uniqueID]||(c[f.uniqueID]={}))[t]=[w,x]),f!==e)););return(x-=i)===n||x%n==0&&x/n>=0}}},PSEUDO:function(t,e){var r,i=n.pseudos[t]||n.setFilters[t.toLowerCase()]||ot.error("unsupported pseudo: "+t);return i[b]?i(e):i.length>1?(r=[t,t,"",e],n.setFilters.hasOwnProperty(t.toLowerCase())?at(function(t,r){for(var n,o=i(t,e),s=o.length;s--;)t[n=L(t,o[s])]=!(r[n]=o[s])}):function(t){return i(t,0,r)}):i}},pseudos:{not:at(function(t){var e=[],r=[],n=a(t.replace(j,"$1"));return n[b]?at(function(t,e,r,i){for(var o,s=n(t,null,i,[]),a=t.length;a--;)(o=s[a])&&(t[a]=!(e[a]=o))}):function(t,i,o){return e[0]=t,n(e,null,o,r),e[0]=null,!r.pop()}}),has:at(function(t){return function(e){return ot(t,e).length>0}}),contains:at(function(t){return t=t.replace(Q,tt),function(e){return(e.textContent||e.innerText||i(e)).indexOf(t)>-1}}),lang:at(function(t){return z.test(t||"")||ot.error("unsupported lang: "+t),t=t.replace(Q,tt).toLowerCase(),function(e){var r;do{if(r=g?e.lang:e.getAttribute("xml:lang")||e.getAttribute("lang"))return(r=r.toLowerCase())===t||0===r.indexOf(t+"-")}while((e=e.parentNode)&&1===e.nodeType);return!1}}),target:function(e){var r=t.location&&t.location.hash;return r&&r.slice(1)===e.id},root:function(t){return t===d},focus:function(t){return t===p.activeElement&&(!p.hasFocus||p.hasFocus())&&!!(t.type||t.href||~t.tabIndex)},enabled:pt(!1),disabled:pt(!0),checked:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&!!t.checked||"option"===e&&!!t.selected},selected:function(t){return t.parentNode&&t.parentNode.selectedIndex,!0===t.selected},empty:function(t){for(t=t.firstChild;t;t=t.nextSibling)if(t.nodeType<6)return!1;return!0},parent:function(t){return!n.pseudos.empty(t)},header:function(t){return q.test(t.nodeName)},input:function(t){return H.test(t.nodeName)},button:function(t){var e=t.nodeName.toLowerCase();return"input"===e&&"button"===t.type||"button"===e},text:function(t){var e;return"input"===t.nodeName.toLowerCase()&&"text"===t.type&&(null==(e=t.getAttribute("type"))||"text"===e.toLowerCase())},first:dt(function(){return[0]}),last:dt(function(t,e){return[e-1]}),eq:dt(function(t,e,r){return[r<0?r+e:r]}),even:dt(function(t,e){for(var r=0;r=0;)t.push(n);return t}),gt:dt(function(t,e,r){for(var n=r<0?r+e:r;++n1?function(e,r,n){for(var i=t.length;i--;)if(!t[i](e,r,n))return!1;return!0}:t[0]}function bt(t,e,r,n,i){for(var o,s=[],a=0,u=t.length,l=null!=e;a-1&&(o[l]=!(s[l]=c))}}else m=bt(m===s?m.splice(d,m.length):m),i?i(null,s,m,u):D.apply(s,m)})}function wt(t){for(var e,r,i,o=t.length,s=n.relative[t[0].type],a=s||n.relative[" "],u=s?1:0,h=yt(function(t){return t===e},a,!0),c=yt(function(t){return L(e,t)>-1},a,!0),f=[function(t,r,n){var i=!s&&(n||r!==l)||((e=r).nodeType?h(t,r,n):c(t,r,n));return e=null,i}];u1&&xt(f),u>1&&mt(t.slice(0,u-1).concat({value:" "===t[u-2].type?"*":""})).replace(j,"$1"),r,u0,i=t.length>0,o=function(o,s,a,u,h){var c,d,v,m=0,y="0",x=o&&[],b=[],_=l,T=o||i&&n.find.TAG("*",h),E=w+=null==_?1:Math.random()||.1,S=T.length;for(h&&(l=s===p||s||h);y!==S&&null!=(c=T[y]);y++){if(i&&c){for(d=0,s||c.ownerDocument===p||(f(c),a=!g);v=t[d++];)if(v(c,s||p,a)){u.push(c);break}h&&(w=E)}r&&((c=!v&&c)&&m--,o&&x.push(c))}if(m+=y,r&&y!==m){for(d=0;v=e[d++];)v(x,b,s,a);if(o){if(m>0)for(;y--;)x[y]||b[y]||(b[y]=O.call(u));b=bt(b)}D.apply(u,b),h&&!o&&b.length>0&&m+e.length>1&&ot.uniqueSort(u)}return h&&(w=E,l=_),x};return r?at(o):o}(o,i))).selector=t}return a},u=ot.select=function(t,e,r,i){var o,u,l,h,c,f="function"==typeof t&&t,p=!i&&s(t=f.selector||t);if(r=r||[],1===p.length){if((u=p[0]=p[0].slice(0)).length>2&&"ID"===(l=u[0]).type&&9===e.nodeType&&g&&n.relative[u[1].type]){if(!(e=(n.find.ID(l.matches[0].replace(Q,tt),e)||[])[0]))return r;f&&(e=e.parentNode),t=t.slice(u.shift().value.length)}for(o=Y.needsContext.test(t)?0:u.length;o--&&(l=u[o],!n.relative[h=l.type]);)if((c=n.find[h])&&(i=c(l.matches[0].replace(Q,tt),J.test(u[0].type)&>(e.parentNode)||e))){if(u.splice(o,1),!(t=i.length&&mt(u)))return D.apply(r,i),r;break}}return(f||a(t,p))(i,e,!g,r,!e||J.test(t)&>(e.parentNode)||e),r},r.sortStable=b.split("").sort(C).join("")===b,r.detectDuplicates=!!c,f(),r.sortDetached=ut(function(t){return 1&t.compareDocumentPosition(p.createElement("fieldset"))}),ut(function(t){return t.innerHTML="","#"===t.firstChild.getAttribute("href")})||lt("type|href|height|width",function(t,e,r){if(!r)return t.getAttribute(e,"type"===e.toLowerCase()?1:2)}),r.attributes&&ut(function(t){return t.innerHTML="",t.firstChild.setAttribute("value",""),""===t.firstChild.getAttribute("value")})||lt("value",function(t,e,r){if(!r&&"input"===t.nodeName.toLowerCase())return t.defaultValue}),ut(function(t){return null==t.getAttribute("disabled")})||lt(F,function(t,e,r){var n;if(!r)return!0===t[e]?e.toLowerCase():(n=t.getAttributeNode(e))&&n.specified?n.value:null}),ot}(r);T.find=A,T.expr=A.selectors,T.expr[":"]=T.expr.pseudos,T.uniqueSort=T.unique=A.uniqueSort,T.text=A.getText,T.isXMLDoc=A.isXML,T.contains=A.contains,T.escapeSelector=A.escape;var C=function(t,e,r){for(var n=[],i=void 0!==r;(t=t[e])&&9!==t.nodeType;)if(1===t.nodeType){if(i&&T(t).is(r))break;n.push(t)}return n},M=function(t,e){for(var r=[];t;t=t.nextSibling)1===t.nodeType&&t!==e&&r.push(t);return r},R=T.expr.match.needsContext;function O(t,e){return t.nodeName&&t.nodeName.toLowerCase()===e.toLowerCase()}var P=/^<([a-z][^\/\0>:\x20\t\r\n\f]*)[\x20\t\r\n\f]*\/?>(?:<\/\1>|)$/i;function D(t,e,r){return y(e)?T.grep(t,function(t,n){return!!e.call(t,n,t)!==r}):e.nodeType?T.grep(t,function(t){return t===e!==r}):"string"!=typeof e?T.grep(t,function(t){return c.call(e,t)>-1!==r}):T.filter(e,t,r)}T.filter=function(t,e,r){var n=e[0];return r&&(t=":not("+t+")"),1===e.length&&1===n.nodeType?T.find.matchesSelector(n,t)?[n]:[]:T.find.matches(t,T.grep(e,function(t){return 1===t.nodeType}))},T.fn.extend({find:function(t){var e,r,n=this.length,i=this;if("string"!=typeof t)return this.pushStack(T(t).filter(function(){for(e=0;e1?T.uniqueSort(r):r},filter:function(t){return this.pushStack(D(this,t||[],!1))},not:function(t){return this.pushStack(D(this,t||[],!0))},is:function(t){return!!D(this,"string"==typeof t&&R.test(t)?T(t):t||[],!1).length}});var I,L=/^(?:\s*(<[\w\W]+>)[^>]*|#([\w-]+))$/;(T.fn.init=function(t,e,r){var n,i;if(!t)return this;if(r=r||I,"string"==typeof t){if(!(n="<"===t[0]&&">"===t[t.length-1]&&t.length>=3?[null,t,null]:L.exec(t))||!n[1]&&e)return!e||e.jquery?(e||r).find(t):this.constructor(e).find(t);if(n[1]){if(e=e instanceof T?e[0]:e,T.merge(this,T.parseHTML(n[1],e&&e.nodeType?e.ownerDocument||e:s,!0)),P.test(n[1])&&T.isPlainObject(e))for(n in e)y(this[n])?this[n](e[n]):this.attr(n,e[n]);return this}return(i=s.getElementById(n[2]))&&(this[0]=i,this.length=1),this}return t.nodeType?(this[0]=t,this.length=1,this):y(t)?void 0!==r.ready?r.ready(t):t(T):T.makeArray(t,this)}).prototype=T.fn,I=T(s);var F=/^(?:parents|prev(?:Until|All))/,k={children:!0,contents:!0,next:!0,prev:!0};function B(t,e){for(;(t=t[e])&&1!==t.nodeType;);return t}T.fn.extend({has:function(t){var e=T(t,this),r=e.length;return this.filter(function(){for(var t=0;t-1:1===r.nodeType&&T.find.matchesSelector(r,t))){o.push(r);break}return this.pushStack(o.length>1?T.uniqueSort(o):o)},index:function(t){return t?"string"==typeof t?c.call(T(t),this[0]):c.call(this,t.jquery?t[0]:t):this[0]&&this[0].parentNode?this.first().prevAll().length:-1},add:function(t,e){return this.pushStack(T.uniqueSort(T.merge(this.get(),T(t,e))))},addBack:function(t){return this.add(null==t?this.prevObject:this.prevObject.filter(t))}}),T.each({parent:function(t){var e=t.parentNode;return e&&11!==e.nodeType?e:null},parents:function(t){return C(t,"parentNode")},parentsUntil:function(t,e,r){return C(t,"parentNode",r)},next:function(t){return B(t,"nextSibling")},prev:function(t){return B(t,"previousSibling")},nextAll:function(t){return C(t,"nextSibling")},prevAll:function(t){return C(t,"previousSibling")},nextUntil:function(t,e,r){return C(t,"nextSibling",r)},prevUntil:function(t,e,r){return C(t,"previousSibling",r)},siblings:function(t){return M((t.parentNode||{}).firstChild,t)},children:function(t){return M(t.firstChild)},contents:function(t){return O(t,"iframe")?t.contentDocument:(O(t,"template")&&(t=t.content||t),T.merge([],t.childNodes))}},function(t,e){T.fn[t]=function(r,n){var i=T.map(this,e,r);return"Until"!==t.slice(-5)&&(n=r),n&&"string"==typeof n&&(i=T.filter(n,i)),this.length>1&&(k[t]||T.uniqueSort(i),F.test(t)&&i.reverse()),this.pushStack(i)}});var N=/[^\x20\t\r\n\f]+/g;function U(t){return t}function $(t){throw t}function j(t,e,r,n){var i;try{t&&y(i=t.promise)?i.call(t).done(e).fail(r):t&&y(i=t.then)?i.call(t,e,r):e.apply(void 0,[t].slice(n))}catch(t){r.apply(void 0,[t])}}T.Callbacks=function(t){t="string"==typeof t?function(t){var e={};return T.each(t.match(N)||[],function(t,r){e[r]=!0}),e}(t):T.extend({},t);var e,r,n,i,o=[],s=[],a=-1,u=function(){for(i=i||t.once,n=e=!0;s.length;a=-1)for(r=s.shift();++a-1;)o.splice(r,1),r<=a&&a--}),this},has:function(t){return t?T.inArray(t,o)>-1:o.length>0},empty:function(){return o&&(o=[]),this},disable:function(){return i=s=[],o=r="",this},disabled:function(){return!o},lock:function(){return i=s=[],r||e||(o=r=""),this},locked:function(){return!!i},fireWith:function(t,r){return i||(r=[t,(r=r||[]).slice?r.slice():r],s.push(r),e||u()),this},fire:function(){return l.fireWith(this,arguments),this},fired:function(){return!!n}};return l},T.extend({Deferred:function(t){var e=[["notify","progress",T.Callbacks("memory"),T.Callbacks("memory"),2],["resolve","done",T.Callbacks("once memory"),T.Callbacks("once memory"),0,"resolved"],["reject","fail",T.Callbacks("once memory"),T.Callbacks("once memory"),1,"rejected"]],n="pending",i={state:function(){return n},always:function(){return o.done(arguments).fail(arguments),this},catch:function(t){return i.then(null,t)},pipe:function(){var t=arguments;return T.Deferred(function(r){T.each(e,function(e,n){var i=y(t[n[4]])&&t[n[4]];o[n[1]](function(){var t=i&&i.apply(this,arguments);t&&y(t.promise)?t.promise().progress(r.notify).done(r.resolve).fail(r.reject):r[n[0]+"With"](this,i?[t]:arguments)})}),t=null}).promise()},then:function(t,n,i){var o=0;function s(t,e,n,i){return function(){var a=this,u=arguments,l=function(){var r,l;if(!(t=o&&(n!==$&&(a=void 0,u=[r]),e.rejectWith(a,u))}};t?h():(T.Deferred.getStackHook&&(h.stackTrace=T.Deferred.getStackHook()),r.setTimeout(h))}}return T.Deferred(function(r){e[0][3].add(s(0,r,y(i)?i:U,r.notifyWith)),e[1][3].add(s(0,r,y(t)?t:U)),e[2][3].add(s(0,r,y(n)?n:$))}).promise()},promise:function(t){return null!=t?T.extend(t,i):i}},o={};return T.each(e,function(t,r){var s=r[2],a=r[5];i[r[1]]=s.add,a&&s.add(function(){n=a},e[3-t][2].disable,e[3-t][3].disable,e[0][2].lock,e[0][3].lock),s.add(r[3].fire),o[r[0]]=function(){return o[r[0]+"With"](this===o?void 0:this,arguments),this},o[r[0]+"With"]=s.fireWith}),i.promise(o),t&&t.call(o,o),o},when:function(t){var e=arguments.length,r=e,n=Array(r),i=u.call(arguments),o=T.Deferred(),s=function(t){return function(r){n[t]=this,i[t]=arguments.length>1?u.call(arguments):r,--e||o.resolveWith(n,i)}};if(e<=1&&(j(t,o.done(s(r)).resolve,o.reject,!e),"pending"===o.state()||y(i[r]&&i[r].then)))return o.then();for(;r--;)j(i[r],s(r),o.reject);return o.promise()}});var G=/^(Eval|Internal|Range|Reference|Syntax|Type|URI)Error$/;T.Deferred.exceptionHook=function(t,e){r.console&&r.console.warn&&t&&G.test(t.name)&&r.console.warn("jQuery.Deferred exception: "+t.message,t.stack,e)},T.readyException=function(t){r.setTimeout(function(){throw t})};var W=T.Deferred();function V(){s.removeEventListener("DOMContentLoaded",V),r.removeEventListener("load",V),T.ready()}T.fn.ready=function(t){return W.then(t).catch(function(t){T.readyException(t)}),this},T.extend({isReady:!1,readyWait:1,ready:function(t){(!0===t?--T.readyWait:T.isReady)||(T.isReady=!0,!0!==t&&--T.readyWait>0||W.resolveWith(s,[T]))}}),T.ready.then=W.then,"complete"===s.readyState||"loading"!==s.readyState&&!s.documentElement.doScroll?r.setTimeout(T.ready):(s.addEventListener("DOMContentLoaded",V),r.addEventListener("load",V));var X=function(t,e,r,n,i,o,s){var a=0,u=t.length,l=null==r;if("object"===w(r))for(a in i=!0,r)X(t,e,a,r[a],!0,o,s);else if(void 0!==n&&(i=!0,y(n)||(s=!0),l&&(s?(e.call(t,n),e=null):(l=e,e=function(t,e,r){return l.call(T(t),r)})),e))for(;a1,null,!0)},removeData:function(t){return this.each(function(){Q.remove(this,t)})}}),T.extend({queue:function(t,e,r){var n;if(t)return e=(e||"fx")+"queue",n=J.get(t,e),r&&(!n||Array.isArray(r)?n=J.access(t,e,T.makeArray(r)):n.push(r)),n||[]},dequeue:function(t,e){e=e||"fx";var r=T.queue(t,e),n=r.length,i=r.shift(),o=T._queueHooks(t,e);"inprogress"===i&&(i=r.shift(),n--),i&&("fx"===e&&r.unshift("inprogress"),delete o.stop,i.call(t,function(){T.dequeue(t,e)},o)),!n&&o&&o.empty.fire()},_queueHooks:function(t,e){var r=e+"queueHooks";return J.get(t,r)||J.access(t,r,{empty:T.Callbacks("once memory").add(function(){J.remove(t,[e+"queue",r])})})}}),T.fn.extend({queue:function(t,e){var r=2;return"string"!=typeof t&&(e=t,t="fx",r--),arguments.length\x20\t\r\n\f]+)/i,dt=/^$|^module$|\/(?:java|ecma)script/i,gt={option:[1,""],thead:[1,"","
"],col:[2,"","
"],tr:[2,"","
"],td:[3,"","
"],_default:[0,"",""]};function vt(t,e){var r;return r=void 0!==t.getElementsByTagName?t.getElementsByTagName(e||"*"):void 0!==t.querySelectorAll?t.querySelectorAll(e||"*"):[],void 0===e||e&&O(t,e)?T.merge([t],r):r}function mt(t,e){for(var r=0,n=t.length;r-1)i&&i.push(o);else if(l=T.contains(o.ownerDocument,o),s=vt(c.appendChild(o),"script"),l&&mt(s),r)for(h=0;o=s[h++];)dt.test(o.type||"")&&r.push(o);return c}yt=s.createDocumentFragment().appendChild(s.createElement("div")),(xt=s.createElement("input")).setAttribute("type","radio"),xt.setAttribute("checked","checked"),xt.setAttribute("name","t"),yt.appendChild(xt),m.checkClone=yt.cloneNode(!0).cloneNode(!0).lastChild.checked,yt.innerHTML="",m.noCloneChecked=!!yt.cloneNode(!0).lastChild.defaultValue;var wt=s.documentElement,Tt=/^key/,Et=/^(?:mouse|pointer|contextmenu|drag|drop)|click/,St=/^([^.]*)(?:\.(.+)|)/;function At(){return!0}function Ct(){return!1}function Mt(){try{return s.activeElement}catch(t){}}function Rt(t,e,r,n,i,o){var s,a;if("object"==typeof e){for(a in"string"!=typeof r&&(n=n||r,r=void 0),e)Rt(t,a,r,n,e[a],o);return t}if(null==n&&null==i?(i=r,n=r=void 0):null==i&&("string"==typeof r?(i=n,n=void 0):(i=n,n=r,r=void 0)),!1===i)i=Ct;else if(!i)return t;return 1===o&&(s=i,(i=function(t){return T().off(t),s.apply(this,arguments)}).guid=s.guid||(s.guid=T.guid++)),t.each(function(){T.event.add(this,e,i,n,r)})}T.event={global:{},add:function(t,e,r,n,i){var o,s,a,u,l,h,c,f,p,d,g,v=J.get(t);if(v)for(r.handler&&(r=(o=r).handler,i=o.selector),i&&T.find.matchesSelector(wt,i),r.guid||(r.guid=T.guid++),(u=v.events)||(u=v.events={}),(s=v.handle)||(s=v.handle=function(e){return void 0!==T&&T.event.triggered!==e.type?T.event.dispatch.apply(t,arguments):void 0}),l=(e=(e||"").match(N)||[""]).length;l--;)p=g=(a=St.exec(e[l])||[])[1],d=(a[2]||"").split(".").sort(),p&&(c=T.event.special[p]||{},p=(i?c.delegateType:c.bindType)||p,c=T.event.special[p]||{},h=T.extend({type:p,origType:g,data:n,handler:r,guid:r.guid,selector:i,needsContext:i&&T.expr.match.needsContext.test(i),namespace:d.join(".")},o),(f=u[p])||((f=u[p]=[]).delegateCount=0,c.setup&&!1!==c.setup.call(t,n,d,s)||t.addEventListener&&t.addEventListener(p,s)),c.add&&(c.add.call(t,h),h.handler.guid||(h.handler.guid=r.guid)),i?f.splice(f.delegateCount++,0,h):f.push(h),T.event.global[p]=!0)},remove:function(t,e,r,n,i){var o,s,a,u,l,h,c,f,p,d,g,v=J.hasData(t)&&J.get(t);if(v&&(u=v.events)){for(l=(e=(e||"").match(N)||[""]).length;l--;)if(p=g=(a=St.exec(e[l])||[])[1],d=(a[2]||"").split(".").sort(),p){for(c=T.event.special[p]||{},f=u[p=(n?c.delegateType:c.bindType)||p]||[],a=a[2]&&new RegExp("(^|\\.)"+d.join("\\.(?:.*\\.|)")+"(\\.|$)"),s=o=f.length;o--;)h=f[o],!i&&g!==h.origType||r&&r.guid!==h.guid||a&&!a.test(h.namespace)||n&&n!==h.selector&&("**"!==n||!h.selector)||(f.splice(o,1),h.selector&&f.delegateCount--,c.remove&&c.remove.call(t,h));s&&!f.length&&(c.teardown&&!1!==c.teardown.call(t,d,v.handle)||T.removeEvent(t,p,v.handle),delete u[p])}else for(p in u)T.event.remove(t,p+e[l],r,n,!0);T.isEmptyObject(u)&&J.remove(t,"handle events")}},dispatch:function(t){var e,r,n,i,o,s,a=T.event.fix(t),u=new Array(arguments.length),l=(J.get(this,"events")||{})[a.type]||[],h=T.event.special[a.type]||{};for(u[0]=a,e=1;e=1))for(;l!==this;l=l.parentNode||this)if(1===l.nodeType&&("click"!==t.type||!0!==l.disabled)){for(o=[],s={},r=0;r-1:T.find(i,this,null,[l]).length),s[i]&&o.push(n);o.length&&a.push({elem:l,handlers:o})}return l=this,u\x20\t\r\n\f]*)[^>]*)\/>/gi,Pt=/\s*$/g;function Lt(t,e){return O(t,"table")&&O(11!==e.nodeType?e:e.firstChild,"tr")&&T(t).children("tbody")[0]||t}function Ft(t){return t.type=(null!==t.getAttribute("type"))+"/"+t.type,t}function kt(t){return"true/"===(t.type||"").slice(0,5)?t.type=t.type.slice(5):t.removeAttribute("type"),t}function Bt(t,e){var r,n,i,o,s,a,u,l;if(1===e.nodeType){if(J.hasData(t)&&(o=J.access(t),s=J.set(e,o),l=o.events))for(i in delete s.handle,s.events={},l)for(r=0,n=l[i].length;r1&&"string"==typeof d&&!m.checkClone&&Dt.test(d))return t.each(function(i){var o=t.eq(i);g&&(e[0]=d.call(this,i,o.html())),Nt(o,e,r,n)});if(f&&(o=(i=_t(e,t[0].ownerDocument,!1,t,n)).firstChild,1===i.childNodes.length&&(i=o),o||n)){for(a=(s=T.map(vt(i,"script"),Ft)).length;c")},clone:function(t,e,r){var n,i,o,s,a,u,l,h=t.cloneNode(!0),c=T.contains(t.ownerDocument,t);if(!(m.noCloneChecked||1!==t.nodeType&&11!==t.nodeType||T.isXMLDoc(t)))for(s=vt(h),n=0,i=(o=vt(t)).length;n0&&mt(s,!c&&vt(t,"script")),h},cleanData:function(t){for(var e,r,n,i=T.event.special,o=0;void 0!==(r=t[o]);o++)if(Z(r)){if(e=r[J.expando]){if(e.events)for(n in e.events)i[n]?T.event.remove(r,n):T.removeEvent(r,n,e.handle);r[J.expando]=void 0}r[Q.expando]&&(r[Q.expando]=void 0)}}}),T.fn.extend({detach:function(t){return Ut(this,t,!0)},remove:function(t){return Ut(this,t)},text:function(t){return X(this,function(t){return void 0===t?T.text(this):this.empty().each(function(){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||(this.textContent=t)})},null,t,arguments.length)},append:function(){return Nt(this,arguments,function(t){1!==this.nodeType&&11!==this.nodeType&&9!==this.nodeType||Lt(this,t).appendChild(t)})},prepend:function(){return Nt(this,arguments,function(t){if(1===this.nodeType||11===this.nodeType||9===this.nodeType){var e=Lt(this,t);e.insertBefore(t,e.firstChild)}})},before:function(){return Nt(this,arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this)})},after:function(){return Nt(this,arguments,function(t){this.parentNode&&this.parentNode.insertBefore(t,this.nextSibling)})},empty:function(){for(var t,e=0;null!=(t=this[e]);e++)1===t.nodeType&&(T.cleanData(vt(t,!1)),t.textContent="");return this},clone:function(t,e){return t=null!=t&&t,e=null==e?t:e,this.map(function(){return T.clone(this,t,e)})},html:function(t){return X(this,function(t){var e=this[0]||{},r=0,n=this.length;if(void 0===t&&1===e.nodeType)return e.innerHTML;if("string"==typeof t&&!Pt.test(t)&&!gt[(pt.exec(t)||["",""])[1].toLowerCase()]){t=T.htmlPrefilter(t);try{for(;r=0&&(u+=Math.max(0,Math.ceil(t["offset"+e[0].toUpperCase()+e.slice(1)]-o-u-a-.5))),u}function te(t,e,r){var n=jt(t),i=Wt(t,e,n),o="border-box"===T.css(t,"boxSizing",!1,n),s=o;if($t.test(i)){if(!r)return i;i="auto"}return s=s&&(m.boxSizingReliable()||i===t.style[e]),("auto"===i||!parseFloat(i)&&"inline"===T.css(t,"display",!1,n))&&(i=t["offset"+e[0].toUpperCase()+e.slice(1)],s=!0),(i=parseFloat(i)||0)+Qt(t,e,r||(o?"border":"content"),s,n,i)+"px"}function ee(t,e,r,n,i){return new ee.prototype.init(t,e,r,n,i)}T.extend({cssHooks:{opacity:{get:function(t,e){if(e){var r=Wt(t,"opacity");return""===r?"1":r}}}},cssNumber:{animationIterationCount:!0,columnCount:!0,fillOpacity:!0,flexGrow:!0,flexShrink:!0,fontWeight:!0,lineHeight:!0,opacity:!0,order:!0,orphans:!0,widows:!0,zIndex:!0,zoom:!0},cssProps:{},style:function(t,e,r,n){if(t&&3!==t.nodeType&&8!==t.nodeType&&t.style){var i,o,s,a=q(e),u=zt.test(e),l=t.style;if(u||(e=Kt(a)),s=T.cssHooks[e]||T.cssHooks[a],void 0===r)return s&&"get"in s&&void 0!==(i=s.get(t,!1,n))?i:l[e];"string"===(o=typeof r)&&(i=it.exec(r))&&i[1]&&(r=ut(t,e,i),o="number"),null!=r&&r==r&&("number"===o&&(r+=i&&i[3]||(T.cssNumber[a]?"":"px")),m.clearCloneStyle||""!==r||0!==e.indexOf("background")||(l[e]="inherit"),s&&"set"in s&&void 0===(r=s.set(t,r,n))||(u?l.setProperty(e,r):l[e]=r))}},css:function(t,e,r,n){var i,o,s,a=q(e);return zt.test(e)||(e=Kt(a)),(s=T.cssHooks[e]||T.cssHooks[a])&&"get"in s&&(i=s.get(t,!0,r)),void 0===i&&(i=Wt(t,e,n)),"normal"===i&&e in Ht&&(i=Ht[e]),""===r||r?(o=parseFloat(i),!0===r||isFinite(o)?o||0:i):i}}),T.each(["height","width"],function(t,e){T.cssHooks[e]={get:function(t,r,n){if(r)return!Xt.test(T.css(t,"display"))||t.getClientRects().length&&t.getBoundingClientRect().width?te(t,e,n):at(t,Yt,function(){return te(t,e,n)})},set:function(t,r,n){var i,o=jt(t),s="border-box"===T.css(t,"boxSizing",!1,o),a=n&&Qt(t,e,n,s,o);return s&&m.scrollboxSize()===o.position&&(a-=Math.ceil(t["offset"+e[0].toUpperCase()+e.slice(1)]-parseFloat(o[e])-Qt(t,e,"border",!1,o)-.5)),a&&(i=it.exec(r))&&"px"!==(i[3]||"px")&&(t.style[e]=r,r=T.css(t,e)),Jt(0,r,a)}}}),T.cssHooks.marginLeft=Vt(m.reliableMarginLeft,function(t,e){if(e)return(parseFloat(Wt(t,"marginLeft"))||t.getBoundingClientRect().left-at(t,{marginLeft:0},function(){return t.getBoundingClientRect().left}))+"px"}),T.each({margin:"",padding:"",border:"Width"},function(t,e){T.cssHooks[t+e]={expand:function(r){for(var n=0,i={},o="string"==typeof r?r.split(" "):[r];n<4;n++)i[t+ot[n]+e]=o[n]||o[n-2]||o[0];return i}},"margin"!==t&&(T.cssHooks[t+e].set=Jt)}),T.fn.extend({css:function(t,e){return X(this,function(t,e,r){var n,i,o={},s=0;if(Array.isArray(e)){for(n=jt(t),i=e.length;s1)}}),T.Tween=ee,ee.prototype={constructor:ee,init:function(t,e,r,n,i,o){this.elem=t,this.prop=r,this.easing=i||T.easing._default,this.options=e,this.start=this.now=this.cur(),this.end=n,this.unit=o||(T.cssNumber[r]?"":"px")},cur:function(){var t=ee.propHooks[this.prop];return t&&t.get?t.get(this):ee.propHooks._default.get(this)},run:function(t){var e,r=ee.propHooks[this.prop];return this.options.duration?this.pos=e=T.easing[this.easing](t,this.options.duration*t,0,1,this.options.duration):this.pos=e=t,this.now=(this.end-this.start)*e+this.start,this.options.step&&this.options.step.call(this.elem,this.now,this),r&&r.set?r.set(this):ee.propHooks._default.set(this),this}},ee.prototype.init.prototype=ee.prototype,ee.propHooks={_default:{get:function(t){var e;return 1!==t.elem.nodeType||null!=t.elem[t.prop]&&null==t.elem.style[t.prop]?t.elem[t.prop]:(e=T.css(t.elem,t.prop,""))&&"auto"!==e?e:0},set:function(t){T.fx.step[t.prop]?T.fx.step[t.prop](t):1!==t.elem.nodeType||null==t.elem.style[T.cssProps[t.prop]]&&!T.cssHooks[t.prop]?t.elem[t.prop]=t.now:T.style(t.elem,t.prop,t.now+t.unit)}}},ee.propHooks.scrollTop=ee.propHooks.scrollLeft={set:function(t){t.elem.nodeType&&t.elem.parentNode&&(t.elem[t.prop]=t.now)}},T.easing={linear:function(t){return t},swing:function(t){return.5-Math.cos(t*Math.PI)/2},_default:"swing"},T.fx=ee.prototype.init,T.fx.step={};var re,ne,ie=/^(?:toggle|show|hide)$/,oe=/queueHooks$/;function se(){ne&&(!1===s.hidden&&r.requestAnimationFrame?r.requestAnimationFrame(se):r.setTimeout(se,T.fx.interval),T.fx.tick())}function ae(){return r.setTimeout(function(){re=void 0}),re=Date.now()}function ue(t,e){var r,n=0,i={height:t};for(e=e?1:0;n<4;n+=2-e)i["margin"+(r=ot[n])]=i["padding"+r]=t;return e&&(i.opacity=i.width=t),i}function le(t,e,r){for(var n,i=(he.tweeners[e]||[]).concat(he.tweeners["*"]),o=0,s=i.length;o1)},removeAttr:function(t){return this.each(function(){T.removeAttr(this,t)})}}),T.extend({attr:function(t,e,r){var n,i,o=t.nodeType;if(3!==o&&8!==o&&2!==o)return void 0===t.getAttribute?T.prop(t,e,r):(1===o&&T.isXMLDoc(t)||(i=T.attrHooks[e.toLowerCase()]||(T.expr.match.bool.test(e)?ce:void 0)),void 0!==r?null===r?void T.removeAttr(t,e):i&&"set"in i&&void 0!==(n=i.set(t,r,e))?n:(t.setAttribute(e,r+""),r):i&&"get"in i&&null!==(n=i.get(t,e))?n:null==(n=T.find.attr(t,e))?void 0:n)},attrHooks:{type:{set:function(t,e){if(!m.radioValue&&"radio"===e&&O(t,"input")){var r=t.value;return t.setAttribute("type",e),r&&(t.value=r),e}}}},removeAttr:function(t,e){var r,n=0,i=e&&e.match(N);if(i&&1===t.nodeType)for(;r=i[n++];)t.removeAttribute(r)}}),ce={set:function(t,e,r){return!1===e?T.removeAttr(t,r):t.setAttribute(r,r),r}},T.each(T.expr.match.bool.source.match(/\w+/g),function(t,e){var r=fe[e]||T.find.attr;fe[e]=function(t,e,n){var i,o,s=e.toLowerCase();return n||(o=fe[s],fe[s]=i,i=null!=r(t,e,n)?s:null,fe[s]=o),i}});var pe=/^(?:input|select|textarea|button)$/i,de=/^(?:a|area)$/i;function ge(t){return(t.match(N)||[]).join(" ")}function ve(t){return t.getAttribute&&t.getAttribute("class")||""}function me(t){return Array.isArray(t)?t:"string"==typeof t&&t.match(N)||[]}T.fn.extend({prop:function(t,e){return X(this,T.prop,t,e,arguments.length>1)},removeProp:function(t){return this.each(function(){delete this[T.propFix[t]||t]})}}),T.extend({prop:function(t,e,r){var n,i,o=t.nodeType;if(3!==o&&8!==o&&2!==o)return 1===o&&T.isXMLDoc(t)||(e=T.propFix[e]||e,i=T.propHooks[e]),void 0!==r?i&&"set"in i&&void 0!==(n=i.set(t,r,e))?n:t[e]=r:i&&"get"in i&&null!==(n=i.get(t,e))?n:t[e]},propHooks:{tabIndex:{get:function(t){var e=T.find.attr(t,"tabindex");return e?parseInt(e,10):pe.test(t.nodeName)||de.test(t.nodeName)&&t.href?0:-1}}},propFix:{for:"htmlFor",class:"className"}}),m.optSelected||(T.propHooks.selected={get:function(t){var e=t.parentNode;return e&&e.parentNode&&e.parentNode.selectedIndex,null},set:function(t){var e=t.parentNode;e&&(e.selectedIndex,e.parentNode&&e.parentNode.selectedIndex)}}),T.each(["tabIndex","readOnly","maxLength","cellSpacing","cellPadding","rowSpan","colSpan","useMap","frameBorder","contentEditable"],function(){T.propFix[this.toLowerCase()]=this}),T.fn.extend({addClass:function(t){var e,r,n,i,o,s,a,u=0;if(y(t))return this.each(function(e){T(this).addClass(t.call(this,e,ve(this)))});if((e=me(t)).length)for(;r=this[u++];)if(i=ve(r),n=1===r.nodeType&&" "+ge(i)+" "){for(s=0;o=e[s++];)n.indexOf(" "+o+" ")<0&&(n+=o+" ");i!==(a=ge(n))&&r.setAttribute("class",a)}return this},removeClass:function(t){var e,r,n,i,o,s,a,u=0;if(y(t))return this.each(function(e){T(this).removeClass(t.call(this,e,ve(this)))});if(!arguments.length)return this.attr("class","");if((e=me(t)).length)for(;r=this[u++];)if(i=ve(r),n=1===r.nodeType&&" "+ge(i)+" "){for(s=0;o=e[s++];)for(;n.indexOf(" "+o+" ")>-1;)n=n.replace(" "+o+" "," ");i!==(a=ge(n))&&r.setAttribute("class",a)}return this},toggleClass:function(t,e){var r=typeof t,n="string"===r||Array.isArray(t);return"boolean"==typeof e&&n?e?this.addClass(t):this.removeClass(t):y(t)?this.each(function(r){T(this).toggleClass(t.call(this,r,ve(this),e),e)}):this.each(function(){var e,i,o,s;if(n)for(i=0,o=T(this),s=me(t);e=s[i++];)o.hasClass(e)?o.removeClass(e):o.addClass(e);else void 0!==t&&"boolean"!==r||((e=ve(this))&&J.set(this,"__className__",e),this.setAttribute&&this.setAttribute("class",e||!1===t?"":J.get(this,"__className__")||""))})},hasClass:function(t){var e,r,n=0;for(e=" "+t+" ";r=this[n++];)if(1===r.nodeType&&(" "+ge(ve(r))+" ").indexOf(e)>-1)return!0;return!1}});var ye=/\r/g;T.fn.extend({val:function(t){var e,r,n,i=this[0];return arguments.length?(n=y(t),this.each(function(r){var i;1===this.nodeType&&(null==(i=n?t.call(this,r,T(this).val()):t)?i="":"number"==typeof i?i+="":Array.isArray(i)&&(i=T.map(i,function(t){return null==t?"":t+""})),(e=T.valHooks[this.type]||T.valHooks[this.nodeName.toLowerCase()])&&"set"in e&&void 0!==e.set(this,i,"value")||(this.value=i))})):i?(e=T.valHooks[i.type]||T.valHooks[i.nodeName.toLowerCase()])&&"get"in e&&void 0!==(r=e.get(i,"value"))?r:"string"==typeof(r=i.value)?r.replace(ye,""):null==r?"":r:void 0}}),T.extend({valHooks:{option:{get:function(t){var e=T.find.attr(t,"value");return null!=e?e:ge(T.text(t))}},select:{get:function(t){var e,r,n,i=t.options,o=t.selectedIndex,s="select-one"===t.type,a=s?null:[],u=s?o+1:i.length;for(n=o<0?u:s?o:0;n-1)&&(r=!0);return r||(t.selectedIndex=-1),o}}}}),T.each(["radio","checkbox"],function(){T.valHooks[this]={set:function(t,e){if(Array.isArray(e))return t.checked=T.inArray(T(t).val(),e)>-1}},m.checkOn||(T.valHooks[this].get=function(t){return null===t.getAttribute("value")?"on":t.value})}),m.focusin="onfocusin"in r;var xe=/^(?:focusinfocus|focusoutblur)$/,be=function(t){t.stopPropagation()};T.extend(T.event,{trigger:function(t,e,n,i){var o,a,u,l,h,c,f,p,g=[n||s],v=d.call(t,"type")?t.type:t,m=d.call(t,"namespace")?t.namespace.split("."):[];if(a=p=u=n=n||s,3!==n.nodeType&&8!==n.nodeType&&!xe.test(v+T.event.triggered)&&(v.indexOf(".")>-1&&(v=(m=v.split(".")).shift(),m.sort()),h=v.indexOf(":")<0&&"on"+v,(t=t[T.expando]?t:new T.Event(v,"object"==typeof t&&t)).isTrigger=i?2:3,t.namespace=m.join("."),t.rnamespace=t.namespace?new RegExp("(^|\\.)"+m.join("\\.(?:.*\\.|)")+"(\\.|$)"):null,t.result=void 0,t.target||(t.target=n),e=null==e?[t]:T.makeArray(e,[t]),f=T.event.special[v]||{},i||!f.trigger||!1!==f.trigger.apply(n,e))){if(!i&&!f.noBubble&&!x(n)){for(l=f.delegateType||v,xe.test(l+v)||(a=a.parentNode);a;a=a.parentNode)g.push(a),u=a;u===(n.ownerDocument||s)&&g.push(u.defaultView||u.parentWindow||r)}for(o=0;(a=g[o++])&&!t.isPropagationStopped();)p=a,t.type=o>1?l:f.bindType||v,(c=(J.get(a,"events")||{})[t.type]&&J.get(a,"handle"))&&c.apply(a,e),(c=h&&a[h])&&c.apply&&Z(a)&&(t.result=c.apply(a,e),!1===t.result&&t.preventDefault());return t.type=v,i||t.isDefaultPrevented()||f._default&&!1!==f._default.apply(g.pop(),e)||!Z(n)||h&&y(n[v])&&!x(n)&&((u=n[h])&&(n[h]=null),T.event.triggered=v,t.isPropagationStopped()&&p.addEventListener(v,be),n[v](),t.isPropagationStopped()&&p.removeEventListener(v,be),T.event.triggered=void 0,u&&(n[h]=u)),t.result}},simulate:function(t,e,r){var n=T.extend(new T.Event,r,{type:t,isSimulated:!0});T.event.trigger(n,null,e)}}),T.fn.extend({trigger:function(t,e){return this.each(function(){T.event.trigger(t,e,this)})},triggerHandler:function(t,e){var r=this[0];if(r)return T.event.trigger(t,e,r,!0)}}),m.focusin||T.each({focus:"focusin",blur:"focusout"},function(t,e){var r=function(t){T.event.simulate(e,t.target,T.event.fix(t))};T.event.special[e]={setup:function(){var n=this.ownerDocument||this,i=J.access(n,e);i||n.addEventListener(t,r,!0),J.access(n,e,(i||0)+1)},teardown:function(){var n=this.ownerDocument||this,i=J.access(n,e)-1;i?J.access(n,e,i):(n.removeEventListener(t,r,!0),J.remove(n,e))}}});var _e=r.location,we=Date.now(),Te=/\?/;T.parseXML=function(t){var e;if(!t||"string"!=typeof t)return null;try{e=(new r.DOMParser).parseFromString(t,"text/xml")}catch(t){e=void 0}return e&&!e.getElementsByTagName("parsererror").length||T.error("Invalid XML: "+t),e};var Ee=/\[\]$/,Se=/\r?\n/g,Ae=/^(?:submit|button|image|reset|file)$/i,Ce=/^(?:input|select|textarea|keygen)/i;function Me(t,e,r,n){var i;if(Array.isArray(e))T.each(e,function(e,i){r||Ee.test(t)?n(t,i):Me(t+"["+("object"==typeof i&&null!=i?e:"")+"]",i,r,n)});else if(r||"object"!==w(e))n(t,e);else for(i in e)Me(t+"["+i+"]",e[i],r,n)}T.param=function(t,e){var r,n=[],i=function(t,e){var r=y(e)?e():e;n[n.length]=encodeURIComponent(t)+"="+encodeURIComponent(null==r?"":r)};if(Array.isArray(t)||t.jquery&&!T.isPlainObject(t))T.each(t,function(){i(this.name,this.value)});else for(r in t)Me(r,t[r],e,i);return n.join("&")},T.fn.extend({serialize:function(){return T.param(this.serializeArray())},serializeArray:function(){return this.map(function(){var t=T.prop(this,"elements");return t?T.makeArray(t):this}).filter(function(){var t=this.type;return this.name&&!T(this).is(":disabled")&&Ce.test(this.nodeName)&&!Ae.test(t)&&(this.checked||!ft.test(t))}).map(function(t,e){var r=T(this).val();return null==r?null:Array.isArray(r)?T.map(r,function(t){return{name:e.name,value:t.replace(Se,"\r\n")}}):{name:e.name,value:r.replace(Se,"\r\n")}}).get()}});var Re=/%20/g,Oe=/#.*$/,Pe=/([?&])_=[^&]*/,De=/^(.*?):[ \t]*([^\r\n]*)$/gm,Ie=/^(?:GET|HEAD)$/,Le=/^\/\//,Fe={},ke={},Be="*/".concat("*"),Ne=s.createElement("a");function Ue(t){return function(e,r){"string"!=typeof e&&(r=e,e="*");var n,i=0,o=e.toLowerCase().match(N)||[];if(y(r))for(;n=o[i++];)"+"===n[0]?(n=n.slice(1)||"*",(t[n]=t[n]||[]).unshift(r)):(t[n]=t[n]||[]).push(r)}}function $e(t,e,r,n){var i={},o=t===ke;function s(a){var u;return i[a]=!0,T.each(t[a]||[],function(t,a){var l=a(e,r,n);return"string"!=typeof l||o||i[l]?o?!(u=l):void 0:(e.dataTypes.unshift(l),s(l),!1)}),u}return s(e.dataTypes[0])||!i["*"]&&s("*")}function je(t,e){var r,n,i=T.ajaxSettings.flatOptions||{};for(r in e)void 0!==e[r]&&((i[r]?t:n||(n={}))[r]=e[r]);return n&&T.extend(!0,t,n),t}Ne.href=_e.href,T.extend({active:0,lastModified:{},etag:{},ajaxSettings:{url:_e.href,type:"GET",isLocal:/^(?:about|app|app-storage|.+-extension|file|res|widget):$/.test(_e.protocol),global:!0,processData:!0,async:!0,contentType:"application/x-www-form-urlencoded; charset=UTF-8",accepts:{"*":Be,text:"text/plain",html:"text/html",xml:"application/xml, text/xml",json:"application/json, text/javascript"},contents:{xml:/\bxml\b/,html:/\bhtml/,json:/\bjson\b/},responseFields:{xml:"responseXML",text:"responseText",json:"responseJSON"},converters:{"* text":String,"text html":!0,"text json":JSON.parse,"text xml":T.parseXML},flatOptions:{url:!0,context:!0}},ajaxSetup:function(t,e){return e?je(je(t,T.ajaxSettings),e):je(T.ajaxSettings,t)},ajaxPrefilter:Ue(Fe),ajaxTransport:Ue(ke),ajax:function(t,e){"object"==typeof t&&(e=t,t=void 0),e=e||{};var n,i,o,a,u,l,h,c,f,p,d=T.ajaxSetup({},e),g=d.context||d,v=d.context&&(g.nodeType||g.jquery)?T(g):T.event,m=T.Deferred(),y=T.Callbacks("once memory"),x=d.statusCode||{},b={},_={},w="canceled",E={readyState:0,getResponseHeader:function(t){var e;if(h){if(!a)for(a={};e=De.exec(o);)a[e[1].toLowerCase()]=e[2];e=a[t.toLowerCase()]}return null==e?null:e},getAllResponseHeaders:function(){return h?o:null},setRequestHeader:function(t,e){return null==h&&(t=_[t.toLowerCase()]=_[t.toLowerCase()]||t,b[t]=e),this},overrideMimeType:function(t){return null==h&&(d.mimeType=t),this},statusCode:function(t){var e;if(t)if(h)E.always(t[E.status]);else for(e in t)x[e]=[x[e],t[e]];return this},abort:function(t){var e=t||w;return n&&n.abort(e),S(0,e),this}};if(m.promise(E),d.url=((t||d.url||_e.href)+"").replace(Le,_e.protocol+"//"),d.type=e.method||e.type||d.method||d.type,d.dataTypes=(d.dataType||"*").toLowerCase().match(N)||[""],null==d.crossDomain){l=s.createElement("a");try{l.href=d.url,l.href=l.href,d.crossDomain=Ne.protocol+"//"+Ne.host!=l.protocol+"//"+l.host}catch(t){d.crossDomain=!0}}if(d.data&&d.processData&&"string"!=typeof d.data&&(d.data=T.param(d.data,d.traditional)),$e(Fe,d,e,E),h)return E;for(f in(c=T.event&&d.global)&&0==T.active++&&T.event.trigger("ajaxStart"),d.type=d.type.toUpperCase(),d.hasContent=!Ie.test(d.type),i=d.url.replace(Oe,""),d.hasContent?d.data&&d.processData&&0===(d.contentType||"").indexOf("application/x-www-form-urlencoded")&&(d.data=d.data.replace(Re,"+")):(p=d.url.slice(i.length),d.data&&(d.processData||"string"==typeof d.data)&&(i+=(Te.test(i)?"&":"?")+d.data,delete d.data),!1===d.cache&&(i=i.replace(Pe,"$1"),p=(Te.test(i)?"&":"?")+"_="+we+++p),d.url=i+p),d.ifModified&&(T.lastModified[i]&&E.setRequestHeader("If-Modified-Since",T.lastModified[i]),T.etag[i]&&E.setRequestHeader("If-None-Match",T.etag[i])),(d.data&&d.hasContent&&!1!==d.contentType||e.contentType)&&E.setRequestHeader("Content-Type",d.contentType),E.setRequestHeader("Accept",d.dataTypes[0]&&d.accepts[d.dataTypes[0]]?d.accepts[d.dataTypes[0]]+("*"!==d.dataTypes[0]?", "+Be+"; q=0.01":""):d.accepts["*"]),d.headers)E.setRequestHeader(f,d.headers[f]);if(d.beforeSend&&(!1===d.beforeSend.call(g,E,d)||h))return E.abort();if(w="abort",y.add(d.complete),E.done(d.success),E.fail(d.error),n=$e(ke,d,e,E)){if(E.readyState=1,c&&v.trigger("ajaxSend",[E,d]),h)return E;d.async&&d.timeout>0&&(u=r.setTimeout(function(){E.abort("timeout")},d.timeout));try{h=!1,n.send(b,S)}catch(t){if(h)throw t;S(-1,t)}}else S(-1,"No Transport");function S(t,e,s,a){var l,f,p,b,_,w=e;h||(h=!0,u&&r.clearTimeout(u),n=void 0,o=a||"",E.readyState=t>0?4:0,l=t>=200&&t<300||304===t,s&&(b=function(t,e,r){for(var n,i,o,s,a=t.contents,u=t.dataTypes;"*"===u[0];)u.shift(),void 0===n&&(n=t.mimeType||e.getResponseHeader("Content-Type"));if(n)for(i in a)if(a[i]&&a[i].test(n)){u.unshift(i);break}if(u[0]in r)o=u[0];else{for(i in r){if(!u[0]||t.converters[i+" "+u[0]]){o=i;break}s||(s=i)}o=o||s}if(o)return o!==u[0]&&u.unshift(o),r[o]}(d,E,s)),b=function(t,e,r,n){var i,o,s,a,u,l={},h=t.dataTypes.slice();if(h[1])for(s in t.converters)l[s.toLowerCase()]=t.converters[s];for(o=h.shift();o;)if(t.responseFields[o]&&(r[t.responseFields[o]]=e),!u&&n&&t.dataFilter&&(e=t.dataFilter(e,t.dataType)),u=o,o=h.shift())if("*"===o)o=u;else if("*"!==u&&u!==o){if(!(s=l[u+" "+o]||l["* "+o]))for(i in l)if((a=i.split(" "))[1]===o&&(s=l[u+" "+a[0]]||l["* "+a[0]])){!0===s?s=l[i]:!0!==l[i]&&(o=a[0],h.unshift(a[1]));break}if(!0!==s)if(s&&t.throws)e=s(e);else try{e=s(e)}catch(t){return{state:"parsererror",error:s?t:"No conversion from "+u+" to "+o}}}return{state:"success",data:e}}(d,b,E,l),l?(d.ifModified&&((_=E.getResponseHeader("Last-Modified"))&&(T.lastModified[i]=_),(_=E.getResponseHeader("etag"))&&(T.etag[i]=_)),204===t||"HEAD"===d.type?w="nocontent":304===t?w="notmodified":(w=b.state,f=b.data,l=!(p=b.error))):(p=w,!t&&w||(w="error",t<0&&(t=0))),E.status=t,E.statusText=(e||w)+"",l?m.resolveWith(g,[f,w,E]):m.rejectWith(g,[E,w,p]),E.statusCode(x),x=void 0,c&&v.trigger(l?"ajaxSuccess":"ajaxError",[E,d,l?f:p]),y.fireWith(g,[E,w]),c&&(v.trigger("ajaxComplete",[E,d]),--T.active||T.event.trigger("ajaxStop")))}return E},getJSON:function(t,e,r){return T.get(t,e,r,"json")},getScript:function(t,e){return T.get(t,void 0,e,"script")}}),T.each(["get","post"],function(t,e){T[e]=function(t,r,n,i){return y(r)&&(i=i||n,n=r,r=void 0),T.ajax(T.extend({url:t,type:e,dataType:i,data:r,success:n},T.isPlainObject(t)&&t))}}),T._evalUrl=function(t){return T.ajax({url:t,type:"GET",dataType:"script",cache:!0,async:!1,global:!1,throws:!0})},T.fn.extend({wrapAll:function(t){var e;return this[0]&&(y(t)&&(t=t.call(this[0])),e=T(t,this[0].ownerDocument).eq(0).clone(!0),this[0].parentNode&&e.insertBefore(this[0]),e.map(function(){for(var t=this;t.firstElementChild;)t=t.firstElementChild;return t}).append(this)),this},wrapInner:function(t){return y(t)?this.each(function(e){T(this).wrapInner(t.call(this,e))}):this.each(function(){var e=T(this),r=e.contents();r.length?r.wrapAll(t):e.append(t)})},wrap:function(t){var e=y(t);return this.each(function(r){T(this).wrapAll(e?t.call(this,r):t)})},unwrap:function(t){return this.parent(t).not("body").each(function(){T(this).replaceWith(this.childNodes)}),this}}),T.expr.pseudos.hidden=function(t){return!T.expr.pseudos.visible(t)},T.expr.pseudos.visible=function(t){return!!(t.offsetWidth||t.offsetHeight||t.getClientRects().length)},T.ajaxSettings.xhr=function(){try{return new r.XMLHttpRequest}catch(t){}};var Ge={0:200,1223:204},We=T.ajaxSettings.xhr();m.cors=!!We&&"withCredentials"in We,m.ajax=We=!!We,T.ajaxTransport(function(t){var e,n;if(m.cors||We&&!t.crossDomain)return{send:function(i,o){var s,a=t.xhr();if(a.open(t.type,t.url,t.async,t.username,t.password),t.xhrFields)for(s in t.xhrFields)a[s]=t.xhrFields[s];for(s in t.mimeType&&a.overrideMimeType&&a.overrideMimeType(t.mimeType),t.crossDomain||i["X-Requested-With"]||(i["X-Requested-With"]="XMLHttpRequest"),i)a.setRequestHeader(s,i[s]);e=function(t){return function(){e&&(e=n=a.onload=a.onerror=a.onabort=a.ontimeout=a.onreadystatechange=null,"abort"===t?a.abort():"error"===t?"number"!=typeof a.status?o(0,"error"):o(a.status,a.statusText):o(Ge[a.status]||a.status,a.statusText,"text"!==(a.responseType||"text")||"string"!=typeof a.responseText?{binary:a.response}:{text:a.responseText},a.getAllResponseHeaders()))}},a.onload=e(),n=a.onerror=a.ontimeout=e("error"),void 0!==a.onabort?a.onabort=n:a.onreadystatechange=function(){4===a.readyState&&r.setTimeout(function(){e&&n()})},e=e("abort");try{a.send(t.hasContent&&t.data||null)}catch(t){if(e)throw t}},abort:function(){e&&e()}}}),T.ajaxPrefilter(function(t){t.crossDomain&&(t.contents.script=!1)}),T.ajaxSetup({accepts:{script:"text/javascript, application/javascript, application/ecmascript, application/x-ecmascript"},contents:{script:/\b(?:java|ecma)script\b/},converters:{"text script":function(t){return T.globalEval(t),t}}}),T.ajaxPrefilter("script",function(t){void 0===t.cache&&(t.cache=!1),t.crossDomain&&(t.type="GET")}),T.ajaxTransport("script",function(t){var e,r;if(t.crossDomain)return{send:function(n,i){e=T("