tencentcloud-webar 1.0.23-3 → 1.0.23-30
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/auth.ts +1 -32
- package/build-esm/450.js +1 -0
- package/build-esm/682.js +1 -0
- package/build-esm/avatar.js +1 -1
- package/build-esm/hand3d.js +1 -0
- package/build-esm/index.js +1 -1
- package/build-esm/lib-3d.js +2 -2
- package/build-esm/sticker3d.js +1 -1
- package/build-umd/avatar.umd.js +3 -3
- package/build-umd/hand-3d.umd.92f8b08bf33aa7415973.js +11 -0
- package/build-umd/stickers-3d.umd.js +4 -4
- package/build-umd/webar-sdk.umd.js +2 -2
- package/miniprogram_dist/0.wasm.br +0 -0
- package/miniprogram_dist/core.js +1 -1
- package/miniprogram_dist/index.js +1 -1
- package/miniprogram_dist/lib.js +1 -1
- package/miniprogram_dist/plugin-3d.js +1 -1
- package/miniprogram_dist/webar.js +1 -1
- package/miniprogram_dist/worker/tick.worker.js +1 -1
- package/package.json +3 -1
- package/readme.md +9 -9
- package/webpack/esm/hand.dev.js +150 -0
- package/webpack/wx/hand.wx.dev.js +165 -0
- package/build-esm/542.js +0 -1
- package/build-esm/avatar.worker.js +0 -6
- package/build-esm/sticker3d.worker.js +0 -6
- package/miniprogram_dist/0.wasm +0 -0
- package/miniprogram_dist/auth.js +0 -1
- package/miniprogram_dist/lib-3d.js +0 -7
|
Binary file
|
package/miniprogram_dist/core.js
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
var self = wx;function a4b(a,b){var c=a4a();return a4b=function(d,e){d=d-0x13a;var f=c[d];return f;},a4b(a,b);}function a4a(){var fE=['warn','_name','image','setup','_sticker','read\x20texture\x20cache','destroyForConosle','mirrorChange','landmarks','Canvas','create','height','debugDraw','imageOffset','setAvatar','__proto__','destroy','hideLoading','_jsonIntensity','require\x203d\x20lib','loadLib3d','SCALE_MODES','loadSticker3d','864964SuGiFS','_json','Renderer','beginFill','_landmarks','value','\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vec4\x20color','\x0a\x20\x20\x20\x20\x20\x20precision\x20mediump\x20float;\x0a\x20\x20\x20\x20\x20\x20attribute\x20vec2\x20aVertexPosition;\x0a\x20\x20\x20\x20\x20\x20attribute\x20vec2\x20aUvs;\x0a\x20\x20\x20\x20\x20\x20uniform\x20mat3\x20translationMatrix;\x0a\x20\x20\x20\x20\x20\x20uniform\x20mat3\x20projectionMatrix;\x0a\x20\x20\x20\x20\x20\x20varying\x20vec2\x20vUvs;\x0a\x0a\x0a\x20\x20\x20\x20\x20\x20void\x20main()\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20vUvs\x20=\x20aUvs;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20gl_Position\x20=\x20vec4((projectionMatrix\x20*\x20translationMatrix\x20*\x20vec3(aVertexPosition,\x201.0)).xy,\x200.0,\x201.0);\x0a\x20\x20\x20\x20\x20\x20}','_maskGraphics','concat','baseImage','Shader','moveTo','animationSpeed','\x20*\x20parentIntensity;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20makeupColor\x20=\x20texture2D(uSamplerMakeup','exclusiveFilter','set','latestEffectUrls','initThreeApp','localSpriteSheets','url','_effects','initRenderContext','undefined','_loadImages','resource','_renderer\x20waiting\x20for\x20renderer','jsonIntensity','blend','是否闭嘴的','preload','objectSrc','Texture','checkAnimated','25975kuqevN','mask','uniforms','ReuseableLipMask','destroyAvatar','shader','getBaseTexture','getDataConfig','preloadEffects','removeFromCache','_drawMaskGraphics','_loadLipImage','getCanvas','renderer','_getIris','parse','readPixels','getUrl','yaw','\x20time:','_makeupContainer','prototype','baseTexture','LEFT_IRIS','_applyMakeup','irisBlendMode','resources','number','clear','texture','_filters','removeForConsole','\x0a\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x0a\x0a\x20\x20\x20\x20\x20\x20//\x20输出\x0a\x20\x20\x20\x20\x20\x20gl_FragColor\x20=\x20baseColor;\x0a\x20\x20\x20\x20}','done','getCircle2','play','metadata','src','setStickerProps','textures','loadingIconOptions','loadStickers','getTexture','_renderer','_maskSprite','anchor','then','points','clone','ArRenderer','_removeFilter','_parentIntensity','_applyFilter','render','_url','RIGHT_IRIS','utils','_finalContainer','getIndeLoader','getPixels','hasFilter','_irises','maskSprite','_renderer\x20waiting\x20for\x20stage','_debug','time','createOffscreenCanvas','loadImage','WHITE','_stickers','mipmap','_stage','Class\x20extends\x20value\x20','content.json','uSamplerIris','_makeupRenderTexture','map','3248580OcKRJQ','POINTS_MAP','eyes','6609848xeBcPf','intensity','right_eye_center','_lipMaskTexture','_src','IrisLayer','update','aUvs','length','_removeMakeup','Sticker','closePath','apply','setEffect','showLoading','Geometry','drawMeshBatch','\x0a\x20\x20\x20\x20precision\x20mediump\x20float;\x0a\x20\x20\x20\x20attribute\x20vec2\x20aVertexPosition;\x0a\x20\x20\x20\x20attribute\x20vec2\x20aUvs;\x0a\x0a\x20\x20\x20\x20uniform\x20mat3\x20translationMatrix;\x0a\x20\x20\x20\x20uniform\x20mat3\x20projectionMatrix;\x0a\x20\x20\x20\x20uniform\x20vec2\x20size;\x0a\x20\x20\x20\x20varying\x20vec2\x20vUvs;\x0a\x20\x20\x20\x20varying\x20vec2\x20bUvs;\x0a\x0a\x20\x20\x0a\x20\x20\x20\x20void\x20main()\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20vUvs\x20=\x20aUvs;\x0a\x20\x20\x20\x20\x20\x20\x20\x20bUvs\x20=\x20aVertexPosition.xy\x20/size;\x0a\x20\x20\x20\x20\x20\x20\x20\x20//\x20lipUvs\x20=\x20lipAuvs;\x0a\x20\x20\x20\x20\x20\x20\x20\x20gl_Position\x20=\x20vec4((projectionMatrix\x20*\x20translationMatrix\x20*\x20vec3(aVertexPosition,\x201.0)).xy,\x200.0,\x201.0);\x0a\x20\x20\x20\x20}','setOptions','_lipMaskMesh','ops','_faceLandmarks','MakeupLayer','throw','constructor','hasOwnProperty','getConfigByKeys','reCorrectAvatar','decorate','logTime','mouthShut','disableEffects','keys','reset','iterator','next','blendshapes','left_eye_center','setPrototypeOf','lib3dLoaded','UNSIGNED_BYTE','_lipMaskIns','renderTexture','_options','_target','_avatar3d','trigger','Generator\x20is\x20already\x20executing.','_renderer\x20waiting\x20for\x20setup','RGBA','Mesh','_leftIris','Container','enableEffects','call','from','function','filter','resize','2599470XiBpHL','parentIntensity','splice','_lipMask','_createFilterSync','_destroyed','_rightIris','0015','key','OFF','remove','needDetection','disableEffect','debug\x20draw\x202','_meshVertex','Graphics','fromBuffer','_maskRenderTexture','_angles','defineProperty','_initLipMask','Effect','setMakeup','sticker\x20blend','addToCache','floor','enable','euler','_makeupMeshes','facelandmarks','_mode3d','232WCGxzE','_baseSprite','init','lips','_filterIntensity','_setEffect','_filtersActived','reject','angles','meshVertex','default','Spritesheet','design:returntype','lipVertex','uniform\x20sampler2D\x20uSamplerMakeup','filterActivedEffect','uniform\x20float\x20intensity','segmentation','object','addChild','MIPMAP_MODES','\x20=\x20intensity','initAvatarApp','clearTexture','_stickerTarget','getCircle','instance','loading','pitch','setExclusiveFilter','add','_getPixelPosition','download','LINEAR','lipmesh','removeChild','setIrisProps','pop','_camera','lineStyle','scale','sticker','push','lut','debounceTimer','getBuffer','\x20is\x20not\x20a\x20constructor\x20or\x20null','wxAnchorArea','_getMeshLayerByBlendMode','plugin3d','convertTo3d','avatar3d','design:type','trys','renderMesh','6358056uhuTWS','resolve','data','updateGeometry','_getLoader','renderer\x20resize','(baseColor.rgb,\x20irisColor.rgb/irisColor.a\x20,\x20irisColor.a);\x0a\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20','max','window','waiting\x20for\x20AI\x20init...','_baseRenderTexture','_getMask','loadFilter','width','487986gxZNxS','_mesh','TextureCache','LEFT_EYE_ORDER','load3d','maxRConSize','visible','drawCircle','scaleMode','renderer\x20apply\x20effect','lipMask','RenderTexture','_filterTarget','find','effect\x20load\x20error','join','webgl','removeBackground','_setup','background','includes','_maskRenderTexure','tick','\x20=\x20texture2D(uSamplerMakeup','\x0a\x20\x20\x20\x20\x0a\x20\x20\x20\x20void\x20main()\x20{\x0a\x20\x20\x20\x20\x20\x20if\x20(enable\x20==\x200)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20gl_FragColor\x20=\x20vec4(0.0,0.0,0.0,0.0);\x0a\x20\x20\x20\x20\x20\x20\x20\x20return;\x0a\x20\x20\x20\x20\x20\x20}\x0a\x0a\x20\x20\x20\x20\x20\x20//\x20todo:适配镜像与非镜像\x0a\x20\x20\x20\x20\x20\x20vec2\x20baseCoord\x20=\x20bUvs;\x0a\x20\x20\x20\x20\x20\x20baseCoord\x20+=\x20imageOffset;\x0a\x20\x20\x20\x20\x20\x20//\x20if\x20(mirror\x20==\x201)\x20{\x0a\x20\x20\x20\x20\x20\x20//\x20\x20\x20baseCoord\x20=\x20vec2(1.0\x20-\x20bUvs.x,\x20bUvs.y);\x0a\x20\x20\x20\x20\x20\x20//\x20}\x0a\x20\x20\x20\x20\x20\x20vec4\x20baseColor\x20=\x20texture2D(baseImage,\x20\x20baseCoord);\x0a\x0a\x20\x20\x20\x20\x20\x20vec4\x20makeupColor\x20=\x20vec4(0.0);\x0a\x0a\x20\x20\x20\x20\x20\x20','timeEnd','checkSpriteSheetJSON',',\x20vUvs)\x20*\x20realIntensity','aVertexPosition','app3d','_getConfig','label','uSamplerMakeup','maxLConSize','tickMesh','catch','design:paramtypes','fragmentSrc','_dir','_isVR','load','Object\x20is\x20not\x20iterable.','_meshVertexTimer','_container','registerAvatar','forEach','iris','renderer\x20parse\x20effect','\x0a\x20\x20\x20\x20\x20\x20precision\x20mediump\x20float;\x0a\x20\x20\x20\x20\x20\x20varying\x20vec2\x20vUvs;\x0a\x20\x20\x20\x20\x20\x20uniform\x20sampler2D\x20uSamplerMakeup;\x0a\x0a\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20void\x20main()\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20gl_FragColor\x20=\x20texture2D(uSamplerMakeup,\x20vUvs);\x0a\x20\x20\x20\x20\x20\x20}','\x0a\x20\x20\x20\x20\x20\x20\x20\x20//\x20混合美瞳\x0a\x20\x20\x20\x20\x20\x20\x20\x20vec4\x20irisColor\x20=\x20texture2D(uSamplerIris,\x20bUvs);\x0a\x20\x20\x20\x20\x20\x20\x20\x20if\x20(irisColor.a\x20>\x200.)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20baseColor.rgb\x20=\x20blend','Sprite','_canvas','geometry','setEffectJSON','output','Loader','already\x20loaded\x20file','enableExclusiveFilter','sticker3d','makeupLayersByBlendMode','_lipVertex','alpha','handleLoading','_visible','return','_key','getOwnPropertyDescriptor','continue','_config','split',',\x20vUvs);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20float\x20a','error','setPlanes','_makeup','log','all','type','wxWeights','\x0a\x0a\x20\x20\x20\x20\x20\x20','_backgroundVR','addAttribute','filterCallback','faceLandMarks','endFill','RIGHT_EYE_ORDER','\x0a\x20\x20\x20\x20','Makeup','webpackChunktencentcloud_webar','backgroundType','mount','options','info','findIndex','makeup','filterIntensity','sent','filters','apply3d','beautify','mirror','isLivePusher','filterTarget','\x0a\x20\x20\x20\x20uniform\x20float\x20parentIntensity;\x0a\x20\x20\x20\x20uniform\x20int\x20enable;\x0a\x20\x20\x20\x20uniform\x20sampler2D\x20baseImage;\x0a\x20\x20\x20\x20\x0a\x20\x20\x20\x20uniform\x20sampler2D\x20uSamplerIris;\x0a\x0a\x20\x20\x20\x20//\x20uniform\x20int\x20mirror;\x0a\x20\x20\x20\x20uniform\x20vec2\x20imageOffset;\x0a\x20\x20\x20\x20\x0a\x20\x20\x20\x20','_app3d','filterActived','_baseContainer','meta','removeExclusiveFilter','_data','_intensity','blob:','_loader','_applyed','indexOf','destroyed','_cacheMask','_mirrorFilter','disableExclusiveFilter','isPureFilter','.json','currentTime','Symbol.iterator\x20is\x20not\x20defined.','waiting\x20for\x20AI\x20init...done','position','reduce','zIndex','mesh','irisRenderTexture','wxAnchorOffset'];a4a=function(){return fE;};return a4a();}var a4bs=a4b;(function(a,b){var br=a4b,c=a();while(!![]){try{var d=parseInt(br(0x269))/0x1+-parseInt(br(0x158))/0x2+parseInt(br(0x1c7))/0x3+-parseInt(br(0x224))/0x4*(parseInt(br(0x17a))/0x5)+-parseInt(br(0x205))/0x6+parseInt(br(0x1ca))/0x7+-parseInt(br(0x25b))/0x8;if(d===b)break;else c['push'](c['shift']());}catch(e){c['push'](c['shift']());}}}(a4a,0x87164),(self[a4bs(0x2c0)]=self[a4bs(0x2c0)]||[])['push']([[0x141],{0x1419:(a0,a1,a2)=>{var eA=a4bs;a2['d'](a1,{'g':()=>aT,'b':()=>aS});var a3,a4=a2(0x4b6),a5=a2(0x1f15),a6=a2(0xbe4),a7=a2(0x15a0),a8=a2(0x24f3),a9=a2(0x2558),aa=a2(0x543),ab=a2(0x43c),ac=a2(0xf09),ad=(a3=function(aU,aV){var bt=a4b;return a3=Object[bt(0x1f0)]||{'__proto__':[]}instanceof Array&&function(aW,aX){var bu=bt;aW[bu(0x150)]=aX;}||function(aW,aX){var bv=bt;for(var aY in aX)Object[bv(0x18f)]['hasOwnProperty'][bv(0x200)](aX,aY)&&(aW[aY]=aX[aY]);},a3(aU,aV);},function(aU,aV){var bw=a4b;if(bw(0x202)!=typeof aV&&null!==aV)throw new TypeError(bw(0x1c2)+String(aV)+bw(0x252));function aW(){this['constructor']=aU;}a3(aU,aV),aU[bw(0x18f)]=null===aV?Object[bw(0x14b)](aV):(aW[bw(0x18f)]=aV[bw(0x18f)],new aW());}),ae=function(aU,aV,aW,aX){var bx=a4b,aY,aZ=arguments[bx(0x1d2)],b0=aZ<0x3?aV:null===aX?aX=Object[bx(0x2ab)](aV,aW):aX;if(bx(0x236)==typeof Reflect&&'function'==typeof Reflect[bx(0x1e6)])b0=Reflect[bx(0x1e6)](aU,aV,aW,aX);else{for(var b1=aU[bx(0x1d2)]-0x1;b1>=0x0;b1--)(aY=aU[b1])&&(b0=(aZ<0x3?aY(b0):aZ>0x3?aY(aV,aW,b0):aY(aV,aW))||b0);}return aZ>0x3&&b0&&Object[bx(0x218)](aV,aW,b0),b0;},af=function(aU,aV){var by=a4b;if(by(0x236)==typeof Reflect&&by(0x202)==typeof Reflect['metadata'])return Reflect[by(0x19e)](aU,aV);},ag=(function(){var bA=a4b;function aU(aV,aW,aX,aY,aZ,b0){var bz=a4b;this['_destroyed']=!0x1,this[bz(0x2b5)]=bz(0x2c6),this[bz(0x1ad)]=0x1,this[bz(0x153)]=0x1,this[bz(0x1a1)]=[],this[bz(0x28f)]=aW,this[bz(0x1f5)]=aV,this[bz(0x294)]=aX,this[bz(0x1cd)]=b0,this['renderer']=aY,this[bz(0x2b5)]=aZ||bz(0x2c6);}return Object[bA(0x218)](aU[bA(0x18f)],bA(0x206),{'get':function(){var bB=bA;return this[bB(0x1ad)];},'set':function(aV){var bC=bA;this['shader']&&(this[bC(0x17f)][bC(0x17c)]['parentIntensity']=aV),this[bC(0x1ad)]=aV;},'enumerable':!0x1,'configurable':!0x0}),Object[bA(0x218)](aU['prototype'],bA(0x273),{'set':function(aV){var bD=bA;null===aV?(this['_mesh']['removeChild'](this[bD(0x2dc)]),this[bD(0x26a)][bD(0x17b)]=aV):(this[bD(0x26a)]['addChild'](aV),this[bD(0x26a)][bD(0x17b)]=aV,this[bD(0x2dc)]=aV);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](aU[bA(0x18f)],bA(0x26f),{'set':function(aV){var bE=bA;this[bE(0x17f)]&&(this[bE(0x17f)][bE(0x17c)][bE(0x21f)]=aV?0x1:0x0);},'enumerable':!0x1,'configurable':!0x0}),aU[bA(0x18f)][bA(0x25e)]=function(aV){var bF=bA;this[bF(0x20a)];},aU[bA(0x18f)][bA(0x25a)]=function(){},aU[bA(0x18f)][bA(0x1da)]=function(aV,aW){var bG=bA,aX=this;if(!this['_destroyed']){var aY=Array[bG(0x201)](aV[bG(0x13c)](function(b6,b7){var bH=bG;return b6[bH(0x242)](b7['blend']),b6;},new Set()));this['irisRenderTexture']&&!aY[bG(0x27d)](this[bG(0x193)])&&aY[bG(0x24e)](this['irisBlendMode']);var aZ='\x0a\x20\x20\x20\x20precision\x20mediump\x20float;\x0a\x20\x20\x20\x20varying\x20vec2\x20vUvs;\x0a\x20\x20\x20\x20varying\x20vec2\x20bUvs;\x0a\x20\x20\x20\x20\x0a\x0a\x20\x20\x20\x20'[bG(0x161)](aV[bG(0x1c6)](function(b6,b7){var bI=bG;return bI(0x232)[bI(0x161)](b7,';');})[bG(0x278)]('\x0a'),bG(0x2be))[bG(0x161)](aV[bG(0x1c6)](function(b6,b7){var bJ=bG;return bJ(0x234)[bJ(0x161)](b7,';');})[bG(0x278)]('\x0a'),bG(0x2cf))[bG(0x161)](aY[bG(0x1c6)](function(b6){var bK=bG;return a9['Lc'][b6][bK(0x17f)];})[bG(0x278)]('\x0a'),bG(0x281))[bG(0x161)](aV['map'](function(b6,b7){var bL=bG;return bL(0x15e)[bL(0x161)](b7,bL(0x280))[bL(0x161)](b7,bL(0x2af))['concat'](b7,'\x20=\x20color')[bL(0x161)](b7,'.a;\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20float\x20realIntensity')[bL(0x161)](b7,bL(0x239))[bL(0x161)](b7,bL(0x166))[bL(0x161)](b7,bL(0x284))[bL(0x161)](b7,';\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20if\x20(makeupColor.a>0.)\x20{\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20//\x20混合\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20baseColor.rgb\x20=\x20blend')[bL(0x161)](a9['Lc'][b6[bL(0x174)]][bL(0x20d)],'(baseColor.rgb,\x20makeupColor.rgb/makeupColor.a\x20,\x20makeupColor.a);\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20}\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20\x0a\x0a\x20\x20\x20\x20\x20\x20\x20\x20\x20\x20');})[bG(0x278)]('\x0a'),bG(0x2b7))['concat'](this[bG(0x13f)]?bG(0x29a)[bG(0x161)](a9['Lc'][this[bG(0x193)]][bG(0x20d)],bG(0x261)):'',bG(0x19a));console[bG(0x2b3)](bG(0x28e),aZ);var b0={'enable':0x1};b0[bG(0x206)]=this[bG(0x206)];var b1=this[bG(0x1f5)],b2=b1['width'],b3=b1[bG(0x14c)];aV[bG(0x296)](function(b6,b7){var bM=bG,b8=bM(0x22e)===aX['_dir']?b6['src']:''[bM(0x161)](aX['_dir'],'|')[bM(0x161)](b6[bM(0x19f)]),b9=a4[bM(0x1b2)][bM(0x26b)][b8];b0[bM(0x289)[bM(0x161)](b7)]=b9,b0['intensity'[bM(0x161)](b7)]=b6['intensity'],b0[bM(0x162)]=aS[bM(0x190)],b0['size']=[b2*b3/aS['baseTexture'][bM(0x14c)],b3];var ba=aS[bM(0x190)]['width']*b3/aS[bM(0x190)][bM(0x14c)];b0[bM(0x14e)]=[(ba-b2)/0x2/ba,0x0],aX[bM(0x13f)]&&(b0[bM(0x1c4)]=aX['irisRenderTexture']),aX[bM(0x1a1)][bM(0x24e)](b9);});var b4=a4['Shader'][bG(0x201)](bG(0x1db),aZ,b0);this[bG(0x17f)]=b4,ac['t'][bG(0x23e)]['on'](bG(0x148),function(b6){});var b5=new a9['Kj'](aW,b4);return this[bG(0x26a)]=b5,this[bG(0x294)][bG(0x237)](b5),b5;}},aU[bA(0x18f)][bA(0x151)]=function(){var bN=bA;this[bN(0x20a)]=!0x0,this['_mesh']&&(this[bN(0x26a)][bN(0x151)]({'children':!0x0,'texture':!0x1,'baseTexture':!0x1}),this['_mesh'][bN(0x17b)]=null,this[bN(0x26a)]=null),this[bN(0x27e)]&&this[bN(0x27e)][bN(0x151)](!0x1);},ae([(0x0,ab['M'])(bA(0x1e0)),af(bA(0x258),Function),af('design:paramtypes',[Array]),af(bA(0x230),void 0x0)],aU[bA(0x18f)],bA(0x25e),null),ae([(0x0,ab['M'])(bA(0x1e0)),af(bA(0x258),Function),af(bA(0x28d),[]),af(bA(0x230),void 0x0)],aU[bA(0x18f)],'destroy',null),aU;}()),ah=function(aU){var bP=a4b;function aV(aY,aZ,b0,b1,b2,b3,b4){var bO=a4b,b5=aU[bO(0x200)](this,aY,aZ,b4)||this;return b5[bO(0x160)]=new a4[(bO(0x214))](),b5[bO(0x28a)]=0x0,b5[bO(0x26e)]=0x0,b5[bO(0x1ad)]=0x1,b5['jsonIntensity']=b2,b5[bO(0x1a4)](b0,b1),b5[bO(0x2ad)]=b3,b5['renderTexture']=a4[bO(0x274)][bO(0x14b)]({'width':aY[bO(0x268)],'height':aY[bO(0x14c)]}),b5;}var aW,aX;return ad(aV,aU),Object[bP(0x218)](aV[bP(0x18f)],bP(0x206),{'get':function(){var bQ=bP;return this[bQ(0x1ad)];},'set':function(aY){var bR=bP;this[bR(0x294)]&&(this[bR(0x294)][bR(0x2a6)]=this['jsonIntensity']*aY),this[bR(0x1ad)]=aY;},'enumerable':!0x1,'configurable':!0x0}),Object[bP(0x218)](aV[bP(0x18f)],bP(0x26f),{'set':function(aY){var bS=bP;this[bS(0x294)]['visible']=aY;},'enumerable':!0x1,'configurable':!0x0}),aV[bP(0x18f)][bP(0x1a4)]=function(aY,aZ){var bT=bP,b0=bT(0x22e)===this[bT(0x28f)]?aY:''[bT(0x161)](this[bT(0x28f)],'|')['concat'](aY),b1=a4[bT(0x1b2)][bT(0x26b)][b0],b2=new a9['jy'](b1),b3=new a9['jy'](b1[bT(0x1aa)]());b2[bT(0x1a7)][bT(0x168)](0.5),b3[bT(0x1a7)][bT(0x168)](0.5),this['_leftIris']=b2,this[bT(0x20b)]=b3;var b4=new a4[(bT(0x1fe))]();this[bT(0x160)]||(this['_maskGraphics']=new a4[(bT(0x214))]()),b4['addChild'](this[bT(0x160)]),b4['addChild'](b2),b4['addChild'](b3),b4['alpha']=this['parentIntensity']*this[bT(0x173)],b4['mask']=this['_maskGraphics'],this[bT(0x294)]=b4;},aV[bP(0x18f)][bP(0x248)]=function(aY,aZ){var bU=bP;if(aY[bU(0x1d2)]){var b0=this[bU(0x2ad)][bU(0x1e4)]([bU(0x1c8),bU(0x191),bU(0x1b1),'LEFT_EYE_ORDER',bU(0x2bd)]),b1=b0[bU(0x1c8)],b2=(b0[bU(0x191)],b0[bU(0x1b1)],b0[bU(0x26c)]),b3=b0[bU(0x2bd)],b4=(b1[bU(0x1ef)],b1[bU(0x1cc)],(0x0,aa['Sp'])(aY[0x34],aY[0x37])),b5=(0x0,aa['Sp'])(aY[0x3a],aY[0x3d]),b6=Math['max'](this[bU(0x28a)],(0x0,aa['Sp'])(aY[0x48],aY[0x49])/b4),b7=Math['max'](this['maxRConSize'],(0x0,aa['Sp'])(aY[0x4b],aY[0x4c])/b5),b8=b4*b6,b9=b4*b6,ba=b5*b7,bb=b5*b7;this['maxLConSize']=Math[bU(0x262)](Math['min'](b6,0.7),0.4),this[bU(0x26e)]=Math[bU(0x262)](Math['min'](b7,0.7),0.4);var bc=aS[bU(0x190)][bU(0x268)]*this[bU(0x1f5)][bU(0x14c)]/aS['baseTexture'][bU(0x14c)],bd=(0x0,aa['qg'])(aY[0x4a],aY[0x68]),be=(0x0,aa['qg'])(aY[0x4d],aY[0x69]);console[bU(0x2b3)]('offset',(bc-this[bU(0x1f5)][bU(0x268)])/0x2),bd['x']-=(bc-this[bU(0x1f5)][bU(0x268)])/0x2,be['x']-=(bc-this[bU(0x1f5)][bU(0x268)])/0x2;var bf=this[bU(0x1fd)],bg=this[bU(0x20b)];bf[bU(0x268)]=b8,bf[bU(0x14c)]=b9,bf['x']=bd['x'],bf['y']=bd['y'],bg['width']=ba,bg[bU(0x14c)]=bb,bg['x']=be['x'],bg['y']=be['y'],this[bU(0x160)][bU(0x196)](),this['_drawMaskGraphics'](b2,aY),this['_drawMaskGraphics'](b3,aY),aZ[bU(0x1af)](this[bU(0x294)],{'renderTexture':this[bU(0x1f4)]});}},aV['prototype'][bP(0x184)]=function(aY,aZ){var bV=bP,b0=this,b1=this[bV(0x160)];b1[bV(0x15b)](0xff3300),b1[bV(0x24b)](0x1,0xffd900,0x1);var b2=[];aY[bV(0x296)](function(b3,b4){var bW=bV,b5=aZ[b3],b6=b0[bW(0x243)](b5['x'],b5['y']),b7=b6['x'],b8=b6['y'];b2[bW(0x24e)]({'x':b7,'y':b8}),0x0===b4?b1[bW(0x164)](b7,b8):b4===aY[bW(0x1d2)]-0x1?(b1[bW(0x1d5)](),b1[bW(0x2bc)]()):b1['lineTo'](b7,b8);});},aV[bP(0x18f)][bP(0x243)]=function(aY,aZ){return{'x':aY,'y':aZ};},aV['prototype'][bP(0x151)]=function(){var bX=bP;this[bX(0x1fd)]&&this['_leftIris'][bX(0x151)]({'children':!0x0,'texture':!0x1,'baseTexture':!0x1}),this[bX(0x20b)]&&this[bX(0x20b)]['destroy']({'children':!0x0,'texture':!0x1,'baseTexture':!0x1}),this[bX(0x160)]&&this['_maskGraphics'][bX(0x151)]({'children':!0x0,'texture':!0x1,'baseTexture':!0x1});},ae([(0x0,ab['M'])(bP(0x1cf)),af(bP(0x258),Function),af(bP(0x28d),[bP(0x202)==typeof(aW=bP(0x16f)!=typeof Array&&Array)?aW:Object,bP(0x202)==typeof(aX=void 0x0!==a4[bP(0x15a)]&&a4[bP(0x15a)])?aX:Object]),af(bP(0x230),void 0x0)],aV[bP(0x18f)],bP(0x248),null),aV;}(ag),ai=a2(0xc30),aj=function(aU,aV,aW,aX){var bY=a4b,aY,aZ=arguments[bY(0x1d2)],b0=aZ<0x3?aV:null===aX?aX=Object[bY(0x2ab)](aV,aW):aX;if(bY(0x236)==typeof Reflect&&bY(0x202)==typeof Reflect['decorate'])b0=Reflect[bY(0x1e6)](aU,aV,aW,aX);else{for(var b1=aU[bY(0x1d2)]-0x1;b1>=0x0;b1--)(aY=aU[b1])&&(b0=(aZ<0x3?aY(b0):aZ>0x3?aY(aV,aW,b0):aY(aV,aW))||b0);}return aZ>0x3&&b0&&Object[bY(0x218)](aV,aW,b0),b0;},ak=function(aU,aV){var bZ=a4b;if('object'==typeof Reflect&&bZ(0x202)==typeof Reflect[bZ(0x19e)])return Reflect[bZ(0x19e)](aU,aV);},al=function(aU,aV,aW,aX){return new(aW||(aW=Promise))(function(aY,aZ){var c2=a4b;function b0(b3){var c0=a4b;try{b2(aX[c0(0x1ed)](b3));}catch(b4){aZ(b4);}}function b1(b3){try{b2(aX['throw'](b3));}catch(b4){aZ(b4);}}function b2(b3){var c1=a4b,b4;b3[c1(0x19b)]?aY(b3[c1(0x15d)]):(b4=b3[c1(0x15d)],b4 instanceof aW?b4:new aW(function(b5){b5(b4);}))[c1(0x1a8)](b0,b1);}b2((aX=aX['apply'](aU,aV||[]))[c2(0x1ed)]());});},am=function(aU,aV){var c3=a4b,aW,aX,aY,aZ,b0={'label':0x0,'sent':function(){if(0x1&aY[0x0])throw aY[0x1];return aY[0x1];},'trys':[],'ops':[]};return aZ={'next':b1(0x0),'throw':b1(0x1),'return':b1(0x2)},c3(0x202)==typeof Symbol&&(aZ[Symbol[c3(0x1ec)]]=function(){return this;}),aZ;function b1(b2){return function(b3){return function(b4){var c4=a4b;if(aW)throw new TypeError(c4(0x1f9));for(;b0;)try{if(aW=0x1,aX&&(aY=0x2&b4[0x0]?aX[c4(0x2a9)]:b4[0x0]?aX[c4(0x1e1)]||((aY=aX[c4(0x2a9)])&&aY[c4(0x200)](aX),0x0):aX['next'])&&!(aY=aY['call'](aX,b4[0x1]))[c4(0x19b)])return aY;switch(aX=0x0,aY&&(b4=[0x2&b4[0x0],aY[c4(0x15d)]]),b4[0x0]){case 0x0:case 0x1:aY=b4;break;case 0x4:return b0['label']++,{'value':b4[0x1],'done':!0x1};case 0x5:b0[c4(0x288)]++,aX=b4[0x1],b4=[0x0];continue;case 0x7:b4=b0['ops']['pop'](),b0[c4(0x259)][c4(0x249)]();continue;default:if(!(aY=b0[c4(0x259)],(aY=aY['length']>0x0&&aY[aY[c4(0x1d2)]-0x1])||0x6!==b4[0x0]&&0x2!==b4[0x0])){b0=0x0;continue;}if(0x3===b4[0x0]&&(!aY||b4[0x1]>aY[0x0]&&b4[0x1]<aY[0x3])){b0['label']=b4[0x1];break;}if(0x6===b4[0x0]&&b0[c4(0x288)]<aY[0x1]){b0[c4(0x288)]=aY[0x1],aY=b4;break;}if(aY&&b0[c4(0x288)]<aY[0x2]){b0[c4(0x288)]=aY[0x2],b0[c4(0x1de)][c4(0x24e)](b4);break;}aY[0x2]&&b0[c4(0x1de)][c4(0x249)](),b0[c4(0x259)][c4(0x249)]();continue;}b4=aV[c4(0x200)](aU,b0);}catch(b5){b4=[0x6,b5],aX=0x0;}finally{aW=aY=0x0;}if(0x5&b4[0x0])throw b4[0x1];return{'value':b4[0x0]?b4[0x1]:void 0x0,'done':!0x0};}([b2,b3]);};}},an=function(aU){var c5=a4b,aV=c5(0x202)==typeof Symbol&&Symbol['iterator'],aW=aV&&aU[aV],aX=0x0;if(aW)return aW[c5(0x200)](aU);if(aU&&c5(0x195)==typeof aU['length'])return{'next':function(){var c6=c5;return aU&&aX>=aU[c6(0x1d2)]&&(aU=void 0x0),{'value':aU&&aU[aX++],'done':!aU};}};throw new TypeError(aV?c5(0x292):c5(0x2e2));},ao=(function(){var c8=a4b;function aU(aV,aW,aX){var c7=a4b;aV&&(this[c7(0x1f5)]=aV),aW&&(this['_lipVertex']=aW),aX&&(this['renderer']=aX);}return aU[c8(0x18f)][c8(0x151)]=function(){var c9=c8,aV=this[c9(0x208)];this[c9(0x208)]=null;try{aV[c9(0x151)](!0x0);}catch(aW){}try{this[c9(0x1dd)][c9(0x151)](!0x0),this[c9(0x1dd)]=null;}catch(aX){}try{this['_maskRenderTexture'][c9(0x151)](!0x0),this[c9(0x216)]=null;}catch(aY){}this['_config']=null;try{this[c9(0x1a6)][c9(0x151)](!0x0),this['_maskSprite']=null;}catch(aZ){}},aU[c8(0x18f)]['load']=function(){return al(this,void 0x0,void 0x0,function(){var aV,aW,aX,aY,aZ;return am(this,function(b0){var ca=a4b;switch(b0[ca(0x288)]){case 0x0:return this['_config']?[0x3,0x2]:(this['_config']=new a8['M'](),[0x4,this[ca(0x2ad)][ca(0x291)]()]);case 0x1:b0[ca(0x2c8)](),b0[ca(0x288)]=0x2;case 0x2:return this[ca(0x208)]?[0x3,0x4]:[0x4,this['_getMask']()];case 0x3:b0['sent'](),b0[ca(0x288)]=0x4;case 0x4:return this['_maskSprite']&&!this[ca(0x1a6)][ca(0x2db)]||(aV=this[ca(0x1f5)],aW=aV['width'],aX=aV['height'],aY=new a4['BaseRenderTexture']({'width':aW,'height':aX}),this[ca(0x216)]=new a4[(ca(0x274))](aY),aZ=new a4[(ca(0x29b))](this[ca(0x216)]),this[ca(0x1a6)]=aZ),[0x2,{'maskSprite':this['_maskSprite'],'lipmask':this[ca(0x208)],'lipmaskmesh':this[ca(0x1dd)]}];}});});},aU[c8(0x18f)][c8(0x1d0)]=function(aV){var cb=c8;this[cb(0x1dd)]&&(this[cb(0x1dd)][cb(0x29d)][cb(0x251)]('aVertexPosition')['update'](aV),this['render']());},aU[c8(0x18f)][c8(0x1af)]=function(){var cc=c8;this[cc(0x187)]&&this['_lipMask']&&this['renderer']['render'](this[cc(0x208)],{'renderTexture':this[cc(0x216)]});},aU['prototype'][c8(0x266)]=function(){return al(this,void 0x0,void 0x0,function(){var aV,aW,aX,aY,aZ,b0,b1,b2,b3;return am(this,function(b4){var cd=a4b;switch(b4[cd(0x288)]){case 0x0:return this[cd(0x208)]?[0x2,this['_lipMask']]:(aV=new a4[(cd(0x1fe))](),(aW=new a4['Sprite'](a4['Texture'][cd(0x1be)]))[cd(0x268)]=this[cd(0x1f5)][cd(0x268)],aW['height']=this[cd(0x1f5)]['height'],aV['addChild'](aW),aX=this[cd(0x2a5)],aY=this['_config'][cd(0x181)](0x1d),[0x4,this[cd(0x185)]()]);case 0x1:return aZ=b4[cd(0x2c8)](),b0=new a4[(cd(0x1d9))]()[cd(0x2b9)]('aVertexPosition',aX)[cd(0x2b9)]('aUvs',aY),cd(0x15f),cd(0x299),b1={'uSamplerMakeup':aZ},b2=a4[cd(0x163)][cd(0x201)](cd(0x15f),cd(0x299),b1),b3=new a4[(cd(0x1fc))](b0,b2),this[cd(0x1dd)]=b3,aV[cd(0x237)](b3),this[cd(0x208)]=aV,[0x2,aV];}});});},aU[c8(0x18f)][c8(0x185)]=function(){return al(this,void 0x0,Promise,function(){var aV=this;return am(this,function(aW){return[0x2,new Promise(function(aX,aY){return al(aV,void 0x0,void 0x0,function(){var aZ,b0,b1;return am(this,function(b2){var ce=a4b;switch(b2['label']){case 0x0:return[0x4,(aZ=new ai['KI']())[ce(0x226)]()];case 0x1:return b0=b2[ce(0x2c8)](),[0x4,aZ[ce(0x1bd)](b0)];case 0x2:return b1=b2[ce(0x2c8)](),aX(b1[ai['X_']]),[0x2];}});});})];});});},aj([(0x0,ab['M'])(c8(0x17d)),ak('design:type',Function),ak(c8(0x28d),[]),ak(c8(0x230),void 0x0)],aU[c8(0x18f)],'destroy',null),aj([(0x0,ab['o'])('ReuseableLipMask'),ak(c8(0x258),Function),ak(c8(0x28d),[]),ak(c8(0x230),Promise)],aU[c8(0x18f)],c8(0x266),null),aU;}()),ap=(function(){var cg=a4b;function aU(aW,aX,aY,aZ,b0,b1,b2,b3){var cf=a4b;void 0x0===b3&&(b3=0x1),this[cf(0x294)]=new a4['Container'](),this[cf(0x221)]=[],this['_visible']=!0x0,this[cf(0x1e8)]=!0x0,this['_applyed']=!0x1,this['_key']=aW,this[cf(0x2d5)]=aX,this[cf(0x1f5)]=aY,this[cf(0x13e)]=aZ,this[cf(0x246)]=b1,this['faceLandMarks']=b0,this[cf(0x187)]=b2,this['parentIntensity']=b3;var b4=new a4['Sprite'](a4[cf(0x178)]['WHITE']);b4['alpha']=0x0,b4[cf(0x268)]=aY['width'],b4[cf(0x14c)]=aY[cf(0x14c)],this['_container']['addChild'](b4);}var aV;return Object['defineProperty'](aU[cg(0x18f)],cg(0x26f),{'get':function(){var ch=cg;return this[ch(0x2a8)];},'set':function(aW){var ci=cg,aX=this;this['_target']&&aW!==this[ci(0x2a8)]&&(this[ci(0x2a8)]=aW,this[ci(0x221)]['forEach'](function(aY){var cj=ci;aW?aX['apply'](aX[cj(0x1f6)]):aX['remove']();}));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](aU[cg(0x18f)],cg(0x13e),{'set':function(aW){var ck=cg;(this[ck(0x213)]=aW,this[ck(0x29d)])&&(this['geometry'][ck(0x251)](ck(0x285))[ck(0x1d0)](aW),this[ck(0x221)][ck(0x296)](function(aX){var cl=ck;aX[cl(0x25e)](aW);}));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](aU['prototype'],'lipmesh',{'set':function(aW){var cm=cg;this['_lipVertex']=aW,this[cm(0x1f3)]&&this[cm(0x1f3)][cm(0x1d0)](aW);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](aU[cg(0x18f)],cg(0x2bb),{'set':function(aW){var cn=cg,aX=this;aW&&aW['length']&&(this['_irises']&&this[cn(0x1b7)][cn(0x248)](aW,this[cn(0x187)]),(0x0,aa['Sp'])(aW[0x62],aW[0x66])<0.03*(0x0,aa['Sp'])(aW[0x0],aW[0x20])?this[cn(0x1e8)]||(this['_makeupMeshes'][cn(0x296)](function(aY){var co=cn;'lips'===aY[co(0x2b5)]&&(aY[co(0x273)]=null);}),this[cn(0x1e8)]=!0x0):this[cn(0x1e8)]&&(this[cn(0x221)][cn(0x296)](function(aY){var cp=cn;cp(0x227)===aY[cp(0x2b5)]&&aX[cp(0x1f3)]&&(aY[cp(0x273)]=aX[cp(0x1f3)]['_maskSprite']);}),this[cn(0x1e8)]=!0x1));},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](aU[cg(0x18f)],cg(0x206),{'get':function(){var cq=cg;return this[cq(0x2d6)];},'set':function(aW){var cr=cg;this[cr(0x1b7)]&&(this[cr(0x1b7)][cr(0x206)]=aW),this[cr(0x221)][cr(0x296)](function(aX){var cs=cr;aX[cs(0x206)]=aW;}),this[cr(0x2d6)]=aW;},'enumerable':!0x1,'configurable':!0x0}),aU[cg(0x18f)][cg(0x25a)]=function(){var ct=cg;this[ct(0x1f3)]&&this['_lipMaskIns'][ct(0x1af)](),this['_makeupMeshes'][ct(0x296)](function(aW){var cu=ct;aW[cu(0x25a)]();});},aU[cg(0x18f)][cg(0x291)]=function(){return al(this,void 0x0,void 0x0,function(){var aW,aX,aY,aZ,b0,b1,b2,b3;return am(this,function(b4){var cv=a4b;switch(b4[cv(0x288)]){case 0x0:return this[cv(0x2ad)]=new a8['M'](),[0x4,this[cv(0x2ad)][cv(0x291)]()];case 0x1:if(b4['sent'](),aW=this['_data'],aX=[],aW&&aW[cv(0x1d2)]){try{for(aY=an(aW),aZ=aY[cv(0x1ed)]();!aZ[cv(0x19b)];aZ=aY['next']())cv(0x297)===(b0=aZ[cv(0x15d)])[cv(0x2b5)]?(this[cv(0x1b7)]=this[cv(0x188)](b0['src'],b0['blend'],b0['intensity']),this['irisBlendMode']=b0['blend']):(b0[cv(0x174)]+'',aX[cv(0x24e)]({'src':b0[cv(0x19f)],'intensity':b0['intensity'],'type':b0[cv(0x2b5)],'blend':b0[cv(0x174)]}));}catch(b5){b2={'error':b5};}finally{try{aZ&&!aZ[cv(0x19b)]&&(b3=aY[cv(0x2a9)])&&b3[cv(0x200)](aY);}finally{if(b2)throw b2[cv(0x2b0)];}}console[cv(0x2b3)](cv(0x2a4),aX),b1=this['_getMeshLayerByBlendMode'](aX),this[cv(0x221)]['push'](b1);}return[0x4,this['_initLipMask']()];case 0x2:return b4['sent'](),[0x2];}});});},aU[cg(0x18f)][cg(0x188)]=function(aW,aX,aY){var cw=cg;return new ah(this[cw(0x1f5)],this[cw(0x2aa)],aW,aX,aY,this['_config'],this[cw(0x294)]);},aU[cg(0x18f)][cg(0x254)]=function(aW){var cy=cg,aX=aW['some'](function(b1){var cx=a4b;return cx(0x227)===b1[cx(0x2b5)];})?'lips':cy(0x2c6),aY=new ag(this['_options'],this[cy(0x2aa)],this[cy(0x294)],this[cy(0x187)],aX);aY['parentIntensity']=this[cy(0x206)],this['_irises']&&(aY[cy(0x13f)]=this[cy(0x1b7)][cy(0x1f4)]['baseTexture'],aY[cy(0x193)]=this[cy(0x193)]);var aZ=this[cy(0x2ad)][cy(0x181)](0x1a);if(!this[cy(0x29d)]){var b0=new a4[(cy(0x1d9))]()[cy(0x2b9)](cy(0x285),this['_meshVertex'])['addAttribute'](cy(0x1d1),aZ);this[cy(0x29d)]=b0;}return aY[cy(0x1da)](aW,this[cy(0x29d)]),aY;},aU[cg(0x18f)][cg(0x1d6)]=function(aW){var cz=cg;this[cz(0x1f6)]=aW,this[cz(0x192)](aW);},aU[cg(0x18f)][cg(0x20f)]=function(){var cA=cg;this[cA(0x1d3)](this[cA(0x1f6)]);},aU[cg(0x18f)][cg(0x192)]=function(aW){var cB=cg;this['_applyed']||(this[cB(0x2d9)]=!0x0,aW[cB(0x2c9)]||(aW[cB(0x2c9)]=[]),aW['addChild'](this[cB(0x294)]));},aU[cg(0x18f)]['_removeMakeup']=function(aW){var cC=cg;this['_applyed']&&(this['_applyed']=!0x1,aW['filters']&&aW[cC(0x247)](this[cC(0x294)]));},aU['prototype'][cg(0x219)]=function(){return al(this,void 0x0,void 0x0,function(){var aW,aX,aY=this;return am(this,function(aZ){var cD=a4b;switch(aZ[cD(0x288)]){case 0x0:return(aW=new ao(this[cD(0x1f5)],this[cD(0x2a5)],this[cD(0x187)]))[cD(0x1f5)]=this[cD(0x1f5)],aW[cD(0x2a5)]=this[cD(0x2a5)],aW['renderer']=this[cD(0x187)],this['_lipMaskIns']=aW,[0x4,aW[cD(0x291)]()];case 0x1:return aX=aZ[cD(0x2c8)]()[cD(0x1b8)],this[cD(0x221)][cD(0x296)](function(b0){var cE=cD;console['log'](cE(0x175),aY[cE(0x1e8)]),cE(0x227)!==b0[cE(0x2b5)]||aY[cE(0x1e8)]||(b0[cE(0x273)]=aX);}),[0x2];}});});},aU[cg(0x18f)][cg(0x151)]=function(){var cF=cg;this['remove'](),this[cF(0x221)][cF(0x296)](function(aW){var cG=cF;return aW[cG(0x151)]();}),this['_makeupMeshes']=[],this[cF(0x1b7)]&&this[cF(0x1b7)][cF(0x151)](),this[cF(0x1b7)]=null,this['_container'][cF(0x151)](),this[cF(0x1f6)]=null,this['_lipMaskIns']&&this[cF(0x1f3)][cF(0x151)]();},aj([(0x0,ab['M'])(cg(0x2bf)),ak(cg(0x258),Function),ak(cg(0x28d),['function'==typeof(aV=void 0x0!==a4['Container']&&a4['Container'])?aV:Object]),ak('design:returntype',void 0x0)],aU[cg(0x18f)],cg(0x1d3),null),aj([(0x0,ab['M'])('Makeup'),ak(cg(0x258),Function),ak(cg(0x28d),[]),ak(cg(0x230),void 0x0)],aU[cg(0x18f)],cg(0x151),null),aU;}()),aq=a2(0xc35),ar=a2(0x191),as=function(aU,aV,aW,aX){var cH=a4b,aY,aZ=arguments[cH(0x1d2)],b0=aZ<0x3?aV:null===aX?aX=Object['getOwnPropertyDescriptor'](aV,aW):aX;if(cH(0x236)==typeof Reflect&&cH(0x202)==typeof Reflect['decorate'])b0=Reflect[cH(0x1e6)](aU,aV,aW,aX);else{for(var b1=aU['length']-0x1;b1>=0x0;b1--)(aY=aU[b1])&&(b0=(aZ<0x3?aY(b0):aZ>0x3?aY(aV,aW,b0):aY(aV,aW))||b0);}return aZ>0x3&&b0&&Object[cH(0x218)](aV,aW,b0),b0;},at=function(aU,aV){var cI=a4b;if(cI(0x236)==typeof Reflect&&'function'==typeof Reflect[cI(0x19e)])return Reflect[cI(0x19e)](aU,aV);},au=(function(){var cK=a4b;function aU(aV,aW,aX,aY,aZ,b0,b1,b2){var cJ=a4b;this['_container']=new a4[(cJ(0x1fe))](),this[cJ(0x142)]=aV,this[cJ(0x1ce)]=aW,this[cJ(0x1f6)]=aY,this[cJ(0x2ad)]=aX,this[cJ(0x153)]=aX['intensity'],this[cJ(0x15c)]=aZ,this[cJ(0x1f5)]=b0,this[cJ(0x2aa)]=b1,this[cJ(0x217)]=b2;}return Object[cK(0x218)](aU[cK(0x18f)],cK(0x206),{'get':function(){var cL=cK;return this[cL(0x1ad)];},'set':function(aV){var cM=cK;this['_parentIntensity']=aV,this['_sticker']&&(this['_sticker'][cM(0x2a6)]=this[cM(0x153)]*aV);},'enumerable':!0x1,'configurable':!0x0}),Object[cK(0x218)](aU[cK(0x18f)],cK(0x2bb),{'set':function(aV){var cN=cK;this['_landmarks']=aV,this[cN(0x145)]&&this['setStickerProps']();},'enumerable':!0x1,'configurable':!0x0}),Object[cK(0x218)](aU[cK(0x18f)],cK(0x22c),{'set':function(aV){var cO=cK;this[cO(0x217)]=aV,this[cO(0x145)]&&this['setStickerProps']();},'enumerable':!0x1,'configurable':!0x0}),aU[cK(0x18f)][cK(0x23d)]=function(aV){var cP=cK;void 0x0===aV&&(aV=0x5);var aW=new a4[(cP(0x214))]();return aW[cP(0x15b)](0xff0000),aW['drawCircle'](0x0,0x0,aV),aW[cP(0x2bc)](),aW;},aU[cK(0x18f)][cK(0x19c)]=function(aV){var cQ=cK;void 0x0===aV&&(aV=0x5);var aW=new a4[(cQ(0x214))]();return aW[cQ(0x15b)](0xff),aW[cQ(0x270)](0x0,0x0,aV),aW[cQ(0x2bc)](),aW;},aU['prototype']['getDisplay']=function(){var cR=cK;return this[cR(0x294)];},aU[cK(0x18f)][cK(0x291)]=function(){var cS=cK,aV,aW=this;if(this[cS(0x179)]()){var aX=[];this[cS(0x1ce)]['forEach'](function(b1){var cT=cS,b2;b2=b1[cT(0x2da)](cT(0x2e0))>-0x1?b1:''[cT(0x161)](aW[cT(0x2aa)],'|')[cT(0x161)](JSON[cT(0x189)](b1)[cT(0x2d3)][cT(0x143)]);var b3=a6['iV'][b2][cT(0x1a1)],b4=Object[cT(0x1ea)](b3)[cT(0x1c6)](function(b5){return b3[b5];});aX=aX[cT(0x161)](b4);}),(aV=new a9['Kg'](aX))[cS(0x165)]=(this[cS(0x2ad)]['fps']||0x1e)/0x3c,aV[cS(0x19d)]();}else{var aY=this[cS(0x1ce)][0x0],aZ=a4[cS(0x1b2)][cS(0x26b)][aY];aV=new a9['jy'](aZ);}this[cS(0x2ad)][cS(0x174)]&&(console[cS(0x2b3)](cS(0x21c),this[cS(0x2ad)]['blend']),aV['blendMode_1']=this[cS(0x2ad)]['blend']),this[cS(0x2ad)][cS(0x140)],(aV[cS(0x268)]=this['_config']['width'],aV[cS(0x14c)]=this[cS(0x2ad)][cS(0x14c)]);var b0=[0.5,0.5];this[cS(0x2ad)]['anchor']&&(b0=this[cS(0x2ad)]['anchor']),aV[cS(0x1a7)][cS(0x168)](b0[0x0],b0[0x1]),aV[cS(0x2a6)]=this[cS(0x153)]*this[cS(0x206)],this['_sticker']=aV,this[cS(0x294)][cS(0x237)](this['_sticker']),this[cS(0x294)][cS(0x256)](),this[cS(0x1a0)]();},aU[cK(0x18f)][cK(0x1a0)]=function(){var cU=cK,aV=this['_config'],aW=this[cU(0x15c)],aX=ar['Jp']['map'](function(b4){return aW[b4];}),aY=(0x0,aa['Sp'])(aX[0x0],aX[0x1]),aZ=aV[cU(0x253)],b0=(aV['wxAnchorOffset'],aV[cU(0x2b6)]),b1=aY/ar['jw'],b2=aZ[cU(0x1c6)](function(b4){var b5=aW[b4];return{'x':b5['x'],'y':b5['y'],'z':0x0};});this[cU(0x294)]['scale'][cU(0x168)](b1);var b3={'x':b2[0x0]['x']*b0[0x0]+b2[0x1]['x']*b0[0x1]+b2[0x2]['x']*b0[0x2],'y':b2[0x0]['y']*b0[0x0]+b2[0x1]['y']*b0[0x1]+b2[0x2]['y']*b0[0x2]};this['_container']['position']['x']=b3['x'],this[cU(0x294)]['position']['y']=b3['y'],this[cU(0x217)]&&(this['_container']['euler']['z']=this[cU(0x217)]['roll'],this[cU(0x294)][cU(0x220)]['y']=this[cU(0x217)][cU(0x18c)],this[cU(0x294)][cU(0x220)]['x']=this[cU(0x217)][cU(0x240)]);},aU[cK(0x18f)][cK(0x179)]=function(){var cV=cK;if(this[cV(0x1ce)]instanceof Array&&this[cV(0x1ce)][cV(0x1d2)]>0x1)return!0x0;try{return JSON[cV(0x189)](this[cV(0x1ce)][0x0]),!0x0;}catch(aV){return'json'===this[cV(0x1ce)][0x0][cV(0x2ae)]('.')['pop']();}},aU[cK(0x18f)][cK(0x27f)]=function(){},aU[cK(0x18f)]['apply']=function(){},aU['prototype'][cK(0x20f)]=function(){},aU[cK(0x18f)][cK(0x151)]=function(){var cW=cK;this[cW(0x145)][cW(0x151)](),this[cW(0x294)][cW(0x151)](),this[cW(0x145)]=null,this[cW(0x1f6)]=null;},as([(0x0,ab['M'])('StickerLayer'),at(cK(0x258),Function),at(cK(0x28d),[]),at(cK(0x230),Boolean)],aU[cK(0x18f)],cK(0x179),null),as([(0x0,ab['M'])('StickerLayer'),at(cK(0x258),Function),at(cK(0x28d),[]),at(cK(0x230),void 0x0)],aU['prototype'],cK(0x151),null),aU;}()),av=(function(){var cZ=a4b;function aU(aV,aW,aX,aY,aZ,b0,b1){var cX=a4b;void 0x0===b1&&(b1=0x1);var b2=this;this['_stickers']=[],this[cX(0x2a8)]=!0x0,this[cX(0x1ad)]=0x1,this['_target']=aX,this['_options']=aZ,this['_landmarks']=aY;var b3=new aq['LE']();b3[cX(0x2b1)](0x190,0xa,0x2710,!0x0),this[cX(0x24a)]=b3,this['_stickers']=aW[cX(0x1c6)](function(b4){var cY=cX,b5=new au(b4['name'],b4[cY(0x19f)],b4,aX,aY,aZ,aV,b0);return b5['parentIntensity']=b2[cY(0x206)],b5['load'](),b2['_camera'][cY(0x237)](b5['getDisplay']()),b5;});}return Object['defineProperty'](aU[cZ(0x18f)],cZ(0x206),{'get':function(){var d0=cZ;return this[d0(0x1ad)];},'set':function(aV){var d1=cZ;this[d1(0x1bf)][d1(0x296)](function(aW){var d2=d1;aW[d2(0x206)]=aV;}),this['_parentIntensity']=aV;},'enumerable':!0x1,'configurable':!0x0}),Object[cZ(0x218)](aU[cZ(0x18f)],'faceLandMarks',{'set':function(aV){var d3=cZ;this[d3(0x1bf)]['forEach'](function(aW){var d4=d3;aW[d4(0x2bb)]=aV;});},'enumerable':!0x1,'configurable':!0x0}),Object[cZ(0x218)](aU['prototype'],cZ(0x22c),{'set':function(aV){var d5=cZ;this[d5(0x1bf)][d5(0x296)](function(aW){var d6=d5;aW[d6(0x22c)]=aV;});},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](aU['prototype'],cZ(0x26f),{'get':function(){var d7=cZ;return this[d7(0x2a8)];},'set':function(aV){var d8=cZ;this[d8(0x1f6)]&&aV!==this[d8(0x2a8)]&&(this['_visible']=aV,aV?this[d8(0x1d6)]():this[d8(0x20f)]());},'enumerable':!0x1,'configurable':!0x0}),aU[cZ(0x18f)][cZ(0x27f)]=function(){var d9=cZ;this[d9(0x1bf)]['forEach'](function(aV){var da=d9;return aV[da(0x27f)]();});},aU['prototype'][cZ(0x1d6)]=function(){var db=cZ;this[db(0x1f6)][db(0x237)](this[db(0x24a)]);},aU[cZ(0x18f)][cZ(0x20f)]=function(){var dc=cZ;this[dc(0x1f6)][dc(0x247)](this[dc(0x24a)]);},aU['prototype'][cZ(0x151)]=function(){var dd=cZ;this['remove'](),this[dd(0x1bf)][dd(0x296)](function(aV){return aV['destroy']();}),this['_camera']['destroy'](),this[dd(0x1bf)]=[];},aU;}()),aw=a2(0x1ade),ax=a2(0x1adf),ay=a2(0x17dd),az=(function(){var aU=function(aV,aW){var de=a4b;return aU=Object[de(0x1f0)]||{'__proto__':[]}instanceof Array&&function(aX,aY){var df=de;aX[df(0x150)]=aY;}||function(aX,aY){var dg=de;for(var aZ in aY)Object[dg(0x18f)][dg(0x1e3)][dg(0x200)](aY,aZ)&&(aX[aZ]=aY[aZ]);},aU(aV,aW);};return function(aV,aW){var dh=a4b;if(dh(0x202)!=typeof aW&&null!==aW)throw new TypeError(dh(0x1c2)+String(aW)+dh(0x252));function aX(){var di=dh;this[di(0x1e2)]=aV;}aU(aV,aW),aV[dh(0x18f)]=null===aW?Object[dh(0x14b)](aW):(aX['prototype']=aW[dh(0x18f)],new aX());};}()),aA=function(aU,aV,aW,aX){var dj=a4b,aY,aZ=arguments[dj(0x1d2)],b0=aZ<0x3?aV:null===aX?aX=Object['getOwnPropertyDescriptor'](aV,aW):aX;if('object'==typeof Reflect&&dj(0x202)==typeof Reflect[dj(0x1e6)])b0=Reflect[dj(0x1e6)](aU,aV,aW,aX);else{for(var b1=aU[dj(0x1d2)]-0x1;b1>=0x0;b1--)(aY=aU[b1])&&(b0=(aZ<0x3?aY(b0):aZ>0x3?aY(aV,aW,b0):aY(aV,aW))||b0);}return aZ>0x3&&b0&&Object[dj(0x218)](aV,aW,b0),b0;},aB=function(aU,aV){var dk=a4b;if(dk(0x236)==typeof Reflect&&dk(0x202)==typeof Reflect[dk(0x19e)])return Reflect[dk(0x19e)](aU,aV);},aC=function(aU,aV,aW,aX){return new(aW||(aW=Promise))(function(aY,aZ){var dn=a4b;function b0(b3){try{b2(aX['next'](b3));}catch(b4){aZ(b4);}}function b1(b3){var dl=a4b;try{b2(aX[dl(0x1e1)](b3));}catch(b4){aZ(b4);}}function b2(b3){var dm=a4b,b4;b3['done']?aY(b3['value']):(b4=b3['value'],b4 instanceof aW?b4:new aW(function(b5){b5(b4);}))[dm(0x1a8)](b0,b1);}b2((aX=aX[dn(0x1d6)](aU,aV||[]))[dn(0x1ed)]());});},aD=function(aU,aV){var dp=a4b,aW,aX,aY,aZ,b0={'label':0x0,'sent':function(){if(0x1&aY[0x0])throw aY[0x1];return aY[0x1];},'trys':[],'ops':[]};return aZ={'next':b1(0x0),'throw':b1(0x1),'return':b1(0x2)},dp(0x202)==typeof Symbol&&(aZ[Symbol[dp(0x1ec)]]=function(){return this;}),aZ;function b1(b2){return function(b3){return function(b4){var dq=a4b;if(aW)throw new TypeError('Generator\x20is\x20already\x20executing.');for(;b0;)try{if(aW=0x1,aX&&(aY=0x2&b4[0x0]?aX[dq(0x2a9)]:b4[0x0]?aX[dq(0x1e1)]||((aY=aX[dq(0x2a9)])&&aY[dq(0x200)](aX),0x0):aX[dq(0x1ed)])&&!(aY=aY[dq(0x200)](aX,b4[0x1]))['done'])return aY;switch(aX=0x0,aY&&(b4=[0x2&b4[0x0],aY[dq(0x15d)]]),b4[0x0]){case 0x0:case 0x1:aY=b4;break;case 0x4:return b0[dq(0x288)]++,{'value':b4[0x1],'done':!0x1};case 0x5:b0['label']++,aX=b4[0x1],b4=[0x0];continue;case 0x7:b4=b0[dq(0x1de)][dq(0x249)](),b0[dq(0x259)][dq(0x249)]();continue;default:if(!(aY=b0[dq(0x259)],(aY=aY['length']>0x0&&aY[aY[dq(0x1d2)]-0x1])||0x6!==b4[0x0]&&0x2!==b4[0x0])){b0=0x0;continue;}if(0x3===b4[0x0]&&(!aY||b4[0x1]>aY[0x0]&&b4[0x1]<aY[0x3])){b0[dq(0x288)]=b4[0x1];break;}if(0x6===b4[0x0]&&b0[dq(0x288)]<aY[0x1]){b0[dq(0x288)]=aY[0x1],aY=b4;break;}if(aY&&b0['label']<aY[0x2]){b0[dq(0x288)]=aY[0x2],b0[dq(0x1de)][dq(0x24e)](b4);break;}aY[0x2]&&b0[dq(0x1de)][dq(0x249)](),b0[dq(0x259)]['pop']();continue;}b4=aV[dq(0x200)](aU,b0);}catch(b5){b4=[0x6,b5],aX=0x0;}finally{aW=aY=0x0;}if(0x5&b4[0x0])throw b4[0x1];return{'value':b4[0x0]?b4[0x1]:void 0x0,'done':!0x0};}([b2,b3]);};}},aE=function(aU){var dr=a4b,aV=dr(0x202)==typeof Symbol&&Symbol[dr(0x1ec)],aW=aV&&aU[aV],aX=0x0;if(aW)return aW[dr(0x200)](aU);if(aU&&dr(0x195)==typeof aU['length'])return{'next':function(){return aU&&aX>=aU['length']&&(aU=void 0x0),{'value':aU&&aU[aX++],'done':!aU};}};throw new TypeError(aV?dr(0x292):dr(0x2e2));},aF=(0x0,ay['jl'])('Effect'),aG=(function(){var dt=a4b;function aU(aW,aX,aY,aZ,b0,b1,b2,b3,b4,b5,b6){var ds=a4b;this[ds(0x198)]=[],this['_destroyed']=!0x1,this[ds(0x2a8)]=!0x0,this['_intensity']=0x1,this[ds(0x228)]=0x1,this['localSpriteSheets']={},this[ds(0x22a)]=!0x0,this[ds(0x1f6)]=aX,this[ds(0x23c)]=aY,this[ds(0x1b0)]=aW,this[ds(0x2aa)]=aW,this['_options']=b0,this[ds(0x13e)]=b1,this[ds(0x246)]=b3,this[ds(0x2bb)]=b2,b4&&(this[ds(0x22c)]=b4),void 0x0!==b5&&(this[ds(0x1cb)]=b5),this['_app3d']=aZ,this[ds(0x29c)]=b6;}var aV;return Object[dt(0x218)](aU['prototype'],dt(0x2df),{'get':function(){var du=dt,aW=this[du(0x2ad)];return!!aW&&((!aW[du(0x2c6)]||!aW[du(0x2c6)][du(0x1d2)])&&((!aW['sticker']||!aW[du(0x24d)][du(0x1d2)])&&((!aW['sticker3d']||!aW[du(0x2a3)][du(0x1d2)])&&(!aW['beautify']||!Object['keys'](aW[du(0x2cb)])[du(0x276)](function(aX){return!!aW['beautify'][aX];})))));},'enumerable':!0x1,'configurable':!0x0}),Object[dt(0x218)](aU[dt(0x18f)],dt(0x2d1),{'get':function(){var dv=dt;return this[dv(0x22a)];},'set':function(aW){var dw=dt;aW!==this['_filtersActived']&&(this['_filterTarget']&&(aW?this[dw(0x1ae)](this['_filterTarget']):this[dw(0x1ac)](this[dw(0x275)])),this[dw(0x22a)]=aW);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](aU[dt(0x18f)],dt(0x16c),{'get':function(){var dx=dt;return this[dx(0x1b0)];},'enumerable':!0x1,'configurable':!0x0}),Object[dt(0x218)](aU['prototype'],'app3d',{'get':function(){var dy=dt;return this[dy(0x2d0)];},'set':function(aW){var dz=dt;this[dz(0x2d0)]=aW;},'enumerable':!0x1,'configurable':!0x0}),Object[dt(0x218)](aU[dt(0x18f)],dt(0x1cb),{'get':function(){var dA=dt;return this[dA(0x2d6)];},'set':function(aW){var dB=dt;aW>0x1&&(aw['N'][dB(0x1f8)](dB(0x2b0),{'message':a5['Z']['t'](dB(0x20c)),'code':ax['U']['SET_INTENSITY_ERROR']}),aW=0x1),null!=aW&&(this[dB(0x2b2)]&&(this[dB(0x2b2)][dB(0x206)]=aW),this['_sticker']&&(this[dB(0x145)]['parentIntensity']=aW),this[dB(0x2d6)]=aW);},'enumerable':!0x1,'configurable':!0x0}),Object[dt(0x218)](aU[dt(0x18f)],dt(0x2c7),{'get':function(){var dC=dt;return this[dC(0x228)];},'set':function(aW){var dD=dt;null!=aW&&(this[dD(0x198)]&&this[dD(0x198)]['forEach'](function(aX){var dE=dD;aX['uniforms'][dE(0x206)]=aW;}),this[dD(0x228)]=aW);},'enumerable':!0x1,'configurable':!0x0}),Object['defineProperty'](aU[dt(0x18f)],'visible',{'get':function(){var dF=dt;return this[dF(0x2a8)];},'set':function(aW){var dG=dt;this['_destroyed']||(this[dG(0x2a8)]=aW,this[dG(0x2b2)]&&(this['_makeup'][dG(0x26f)]=aW),this[dG(0x145)]&&(this['_sticker'][dG(0x26f)]=aW));},'enumerable':!0x1,'configurable':!0x0}),Object[dt(0x218)](aU[dt(0x18f)],dt(0x13e),{'set':function(aW){var dH=dt;this['_destroyed']||(this[dH(0x213)]=aW,this[dH(0x2b2)]&&(this[dH(0x2b2)][dH(0x13e)]=aW));},'enumerable':!0x1,'configurable':!0x0}),Object[dt(0x218)](aU[dt(0x18f)],dt(0x246),{'set':function(aW){var dI=dt;this[dI(0x20a)]||(this[dI(0x2a5)]=aW,this[dI(0x2b2)]&&(this[dI(0x2b2)][dI(0x246)]=aW));},'enumerable':!0x1,'configurable':!0x0}),Object[dt(0x218)](aU[dt(0x18f)],dt(0x2bb),{'get':function(){return this['_faceLandMarks'];},'set':function(aW){var dJ=dt;this[dJ(0x20a)]||(this['_faceLandMarks']=aW,this['_makeup']&&(this[dJ(0x2b2)][dJ(0x2bb)]=aW),this[dJ(0x145)]&&(this[dJ(0x145)][dJ(0x2bb)]=aW));},'enumerable':!0x1,'configurable':!0x0}),Object[dt(0x218)](aU[dt(0x18f)],dt(0x22c),{'set':function(aW){var dK=dt;this[dK(0x217)]=aW,this[dK(0x145)]&&(this[dK(0x145)][dK(0x22c)]=aW);},'enumerable':!0x1,'configurable':!0x0}),aU[dt(0x18f)][dt(0x244)]=function(){return aC(this,void 0x0,Promise,function(){return aD(this,function(aW){var dL=a4b;switch(aW[dL(0x288)]){case 0x0:return ay['D4'][dL(0x2c4)]('download:',this[dL(0x1b0)]),[0x4,this[dL(0x25f)]()];case 0x1:return[0x4,aW[dL(0x2c8)]()[dL(0x176)](this[dL(0x1b0)])];case 0x2:return aW[dL(0x2c8)](),[0x4,this['_getConfig']()];case 0x3:return[0x2,aW['sent']()];}});});},aU[dt(0x18f)][dt(0x291)]=function(){return aC(this,void 0x0,Promise,function(){var aW,aX,aY,aZ,b0,b1;return aD(this,function(b2){var dM=a4b;switch(b2[dM(0x288)]){case 0x0:return[0x4,this['download']()];case 0x1:return aW=b2[dM(0x2c8)](),aX=aW[dM(0x203)],aY=aW[dM(0x2c6)],aZ=aW[dM(0x2cb)],b0=aW['sticker'],b1=aW['sticker3d'],[0x4,this[dM(0x170)](aW)];case 0x2:return b2[dM(0x2c8)](),this[dM(0x267)](aX),[0x4,this[dM(0x21b)](aY)];case 0x3:return b2[dM(0x2c8)](),b0?[0x4,this[dM(0x1a3)](b0)]:[0x3,0x5];case 0x4:b2[dM(0x2c8)](),b2[dM(0x288)]=0x5;case 0x5:return[0x4,this[dM(0x26d)](b1)];case 0x6:return b2[dM(0x2c8)](),this[dM(0x2a3)]=b1,[0x4,this[dM(0x25f)]()];case 0x7:return b2[dM(0x2c8)]()[dM(0x183)](this[dM(0x1b0)]),[0x2,aZ];}});});},aU[dt(0x18f)][dt(0x25f)]=function(){return aC(this,void 0x0,void 0x0,function(){return aD(this,function(aW){var dN=a4b;switch(aW['label']){case 0x0:return this['_loader']?[0x3,0x2]:(this['_loader']=new a6['pF'](),[0x4,this['_loader'][dN(0x226)]()]);case 0x1:aW[dN(0x2c8)](),aW[dN(0x288)]=0x2;case 0x2:return[0x2,this['_loader']];}});});},aU['prototype'][dt(0x287)]=function(){return aC(this,void 0x0,void 0x0,function(){var aW;return aD(this,function(aX){var dO=a4b;switch(aX['label']){case 0x0:return this[dO(0x2ad)]?[0x3,0x3]:[0x4,this['_getLoader']()];case 0x1:return[0x4,(aW=aX[dO(0x2c8)]())[dO(0x176)](this[dO(0x1b0)])];case 0x2:aX['sent'](),this[dO(0x2ad)]=aW['readJSON'](dO(0x1c3),this[dO(0x2aa)]),aX[dO(0x288)]=0x3;case 0x3:return[0x2,this['_config']];}});});},aU[dt(0x18f)]['hasEyeMakeup']=function(){return aC(this,void 0x0,Promise,function(){var aW,aX,aY,aZ,b0,b1,b2,b3;return aD(this,function(b4){var dP=a4b;switch(b4[dP(0x288)]){case 0x0:return[0x4,this[dP(0x287)]()];case 0x1:aW=b4['sent'](),aX=aW[dP(0x2c6)],aY=!0x1;try{for(aZ=aE(aX),b0=aZ[dP(0x1ed)]();!b0[dP(0x19b)];b0=aZ[dP(0x1ed)]())if(dP(0x297)===(b1=b0[dP(0x15d)])[dP(0x2b5)]||dP(0x1c9)===b1['type']){aY=!0x0;break;}}catch(b5){b2={'error':b5};}finally{try{b0&&!b0[dP(0x19b)]&&(b3=aZ['return'])&&b3[dP(0x200)](aZ);}finally{if(b2)throw b2['error'];}}return[0x2,aY];}});});},aU[dt(0x18f)][dt(0x210)]=function(){return aC(this,void 0x0,Promise,function(){var aW,aX,aY,aZ;return aD(this,function(b0){var dQ=a4b;switch(b0[dQ(0x288)]){case 0x0:return[0x4,this['_getConfig']()];case 0x1:return aW=b0[dQ(0x2c8)](),aX=aW[dQ(0x2c6)],aY=aW[dQ(0x24d)],aZ=aW[dQ(0x2a3)],[0x2,aX&&aX['length']||aY&&aY[dQ(0x1d2)]||aZ&&aZ[dQ(0x1d2)]];}});});},aU[dt(0x18f)][dt(0x1b6)]=function(){return aC(this,void 0x0,Promise,function(){var aW,aX;return aD(this,function(aY){var dR=a4b;switch(aY[dR(0x288)]){case 0x0:return[0x4,this[dR(0x287)]()];case 0x1:return aW=aY[dR(0x2c8)](),[0x2,!(!(aX=aW[dR(0x203)])||!aX[dR(0x1d2)])];}});});},aU[dt(0x18f)][dt(0x1a3)]=function(aW){return aC(this,void 0x0,Promise,function(){var aX;return aD(this,function(aY){var dS=a4b;return aW['length']?((aX=new av(this[dS(0x2aa)],aW,this[dS(0x23c)],this['faceLandMarks'],this[dS(0x1f5)],this['_angles']))[dS(0x206)]=this[dS(0x1cb)],this[dS(0x145)]=aX,[0x2]):[0x2,Promise['resolve']()];});});},aU[dt(0x18f)][dt(0x157)]=function(aW){return void 0x0===aW&&(aW=[]),aC(this,void 0x0,Promise,function(){return aD(this,function(aX){return[0x2];});});},aU[dt(0x18f)][dt(0x26d)]=function(aW){return aC(this,void 0x0,void 0x0,function(){return aD(this,function(aX){return[0x2];});});},aU['prototype'][dt(0x16a)]=function(){return aC(this,void 0x0,void 0x0,function(){return aD(this,function(aW){return[0x2];});});},aU[dt(0x18f)][dt(0x2ca)]=function(){},aU[dt(0x18f)]['removeForConsole']=function(){},aU[dt(0x18f)][dt(0x147)]=function(){},aU['prototype']['setMakeup']=function(aW){var dT=dt;return aW['length']?(this[dT(0x2b2)]=new ap(this[dT(0x2aa)],aW,this[dT(0x1f5)],this[dT(0x213)],this[dT(0x2bb)],this['_lipVertex'],this[dT(0x187)],this[dT(0x1cb)]),this['_makeup'][dT(0x291)]()):Promise[dT(0x25c)]();},aU['prototype'][dt(0x1d6)]=function(aW){var dU=dt;this['_destroyed']||this[dU(0x2d9)]||(this[dU(0x2d1)]&&this['_applyFilter'](aW[dU(0x2ce)]),this[dU(0x198)]['length']&&aW[dU(0x2ba)]&&aW[dU(0x2ba)](),this[dU(0x275)]=aW[dU(0x2ce)],this['_makeup']&&this['_makeup'][dU(0x1d6)](this[dU(0x1f6)]),this[dU(0x145)]&&this['_sticker'][dU(0x1d6)](),this[dU(0x2ca)](),this[dU(0x2d9)]=!0x0);},aU['prototype'][dt(0x18b)]=function(){var dV=dt;return this[dV(0x1b0)];},aU[dt(0x18f)][dt(0x20f)]=function(){var dW=dt;aF[dW(0x2c4)](dW(0x20f),this[dW(0x1b0)],this[dW(0x18b)]()),this['_makeup']&&this['_makeup'][dW(0x20f)](),this['_sticker']&&this[dW(0x145)][dW(0x20f)](),this[dW(0x199)](),this[dW(0x1ac)](this[dW(0x275)]),this['_applyed']=!0x1;},aU[dt(0x18f)][dt(0x27f)]=function(){var dX=dt;this[dX(0x145)]&&this[dX(0x145)]['tick']();},aU['prototype'][dt(0x28b)]=function(){var dY=dt;this[dY(0x2b2)]&&this[dY(0x2b2)][dY(0x25a)]();},aU[dt(0x18f)][dt(0x151)]=function(){var dZ=dt;this[dZ(0x20a)]=!0x0,this[dZ(0x20f)](),this[dZ(0x2b2)]&&(this[dZ(0x2b2)][dZ(0x151)](),this['_makeup']=null),this['_sticker']&&(this[dZ(0x145)][dZ(0x151)](),this[dZ(0x145)]=null),this[dZ(0x147)](),this['_filters']=[],this['clearTexture']();},aU[dt(0x18f)]['loadFilter']=function(aW){var e0=dt,aX=this;this[e0(0x20a)]||aW&&aW[e0(0x1d2)]&&aW['forEach'](function(aY){var e1=e0,aZ=aX[e1(0x209)](aY['src'],aY[e1(0x1cb)],aX[e1(0x2c7)]);aX[e1(0x198)]['push'](aZ);});},aU['prototype'][dt(0x1ae)]=function(aW){var e2=dt;aW[e2(0x2c9)]||(aW['filters']=[]),aW[e2(0x2c9)]=this[e2(0x198)]['concat'](aW[e2(0x2c9)]);},aU[dt(0x18f)]['_removeFilter']=function(aW){var e3=dt;aW&&aW[e3(0x2c9)]&&aW[e3(0x2c9)]['length']&&this[e3(0x198)][e3(0x296)](function(aX){var e4=e3,aY=aW[e4(0x2c9)][e4(0x2c5)](function(aZ){return aZ===aX;});aY>-0x1&&aW['filters']['splice'](aY,0x1);});},aU[dt(0x18f)][dt(0x209)]=function(aW,aX,aY){var e5=dt,aZ=e5(0x22e)===this[e5(0x2aa)]?aW:''['concat'](this['_key'],'|')[e5(0x161)](aW),b0=a4['utils']['TextureCache'][aZ];return b0[e5(0x190)][e5(0x271)]=a4[e5(0x156)][e5(0x245)],b0[e5(0x190)][e5(0x1c0)]=a4[e5(0x238)][e5(0x20e)],new a7['f'](e5(0x24f),this[e5(0x1f5)],{'uniforms':{'lut':b0,'intensity':aX,'parentIntensity':aY}});},aU[dt(0x18f)][dt(0x23b)]=function(){var e6=dt;for(var aW in a4['utils'][e6(0x26b)])if(aW['indexOf'](this[e6(0x2aa)])>-0x1){var aX=a4[e6(0x1b2)][e6(0x26b)][aW];a4[e6(0x178)][e6(0x183)](aX),aX[e6(0x151)](!0x0);}for(var aW in this[e6(0x16b)])a6['iV'][aW]&&a6['iV'][aW]instanceof a4[e6(0x22f)]&&(a6['iV'][aW]['destroy'](),delete a6['iV'][aW]);},aU[dt(0x18f)][dt(0x170)]=function(aW){var e7=dt,aX,aY,aZ=this,b0=(aW[e7(0x203)]||[])[e7(0x161)](aW['makeup']||[])[e7(0x161)](aW['sticker']||[]),b1=this[e7(0x2d8)][e7(0x1b4)](),b2={};this[e7(0x16b)]=b2;try{for(var b3=aE(b0),b4=b3[e7(0x1ed)]();!b4[e7(0x19b)];b4=b3['next']()){var b5=b4[e7(0x15d)];if(b5['src']instanceof Array)b5['src'][e7(0x296)](function(b8,b9){var e8=e7,ba=aZ[e8(0x283)](b8);if(ba){var bb=ba[e8(0x2d3)][e8(0x143)],bc=''[e8(0x161)](aZ[e8(0x2aa)],'|')[e8(0x161)](bb);if(a4[e8(0x1b2)]['TextureCache'][bc])return;if(0x0===bb[e8(0x2da)](e8(0x2d7))){var bd=a4[e8(0x178)][e8(0x201)](bb);a4[e8(0x178)][e8(0x21d)](bd,bc);}else b1['add'](bc,bb);ba[e8(0x2d3)][e8(0x143)]='',b2[bc]=ba;}else{if(a4[e8(0x1b2)][e8(0x26b)][b8])return;if(b1[e8(0x194)][b8])return;b1[e8(0x242)](b8,b8);}});else{var b6=''['concat'](this[e7(0x2aa)],'|')['concat'](b5['src']);if(a4[e7(0x1b2)][e7(0x26b)][b6])continue;if(0x0===b5[e7(0x19f)][e7(0x2da)]('blob:')){var b7=a4['Texture']['from'](b5['src']);a4[e7(0x178)][e7(0x21d)](b7,b6);}else b1[e7(0x242)](b6,b5['src']);}}}catch(b8){aX={'error':b8};}finally{try{b4&&!b4['done']&&(aY=b3[e7(0x2a9)])&&aY['call'](b3);}finally{if(aX)throw aX['error'];}}return new Promise(function(b9){var e9=e7;b1[e9(0x291)](function(ba,bb){return aC(aZ,void 0x0,void 0x0,function(){var bc,bd,be,bf,bg;return aD(this,function(bh){var ea=a4b;switch(bh[ea(0x288)]){case 0x0:for(be in(bc=function(bi){var bj;return aD(this,function(bk){var eb=a4b;switch(bk[eb(0x288)]){case 0x0:return a6['iV'][bi]?[0x2,'continue']:b2[bi]?(bj=new a4['Spritesheet'](a4[eb(0x1b2)]['TextureCache'][bi],b2[bi]),[0x4,new Promise(function(bl){var ec=eb;bj[ec(0x189)](function(){a6['iV'][bi]=bj,bl();});})]):[0x3,0x2];case 0x1:bk[eb(0x2c8)](),bk[eb(0x288)]=0x2;case 0x2:return[0x2];}});},bd=[],a4[ea(0x1b2)][ea(0x26b)]))bd[ea(0x24e)](be);bf=0x0,bh[ea(0x288)]=0x1;case 0x1:return bf<bd[ea(0x1d2)]?(bg=bd[bf],[0x5,bc(bg)]):[0x3,0x4];case 0x2:bh[ea(0x2c8)](),bh[ea(0x288)]=0x3;case 0x3:return bf++,[0x3,0x1];case 0x4:for(bg in bb)a6['iV'][bg]||b2[bg]||(a6['iV'][bg]=bb[bg]);return b9(),[0x2];}});});});});},aU[dt(0x18f)][dt(0x283)]=function(aW){try{return JSON['parse'](aW);}catch(aX){return null;}},aA([(0x0,ab['M'])('Effect'),aB(dt(0x258),Function),aB(dt(0x28d),[]),aB(dt(0x230),void 0x0)],aU[dt(0x18f)],dt(0x20f),null),aA([(0x0,ab['M'])(dt(0x21a)),aB('design:type',Function),aB(dt(0x28d),[]),aB('design:returntype',void 0x0)],aU['prototype'],dt(0x151),null),aA([(0x0,ab['M'])('Effect'),aB(dt(0x258),Function),aB(dt(0x28d),[dt(0x202)==typeof(aV=void 0x0!==a4[dt(0x1fe)]&&a4[dt(0x1fe)])?aV:Object]),aB(dt(0x230),void 0x0)],aU['prototype'],'_removeFilter',null),aU;}()),aH=function(aU){var ee=a4b;function aV(aW,aX,aY,aZ,b0,b1,b2,b3){var ed=a4b,b4=aU['call'](this,'default',aX,aY,aZ,b0,b1,b2,b3)||this;return b4[ed(0x159)]=aW,b4[ed(0x2d0)]=aZ,b4;}return az(aV,aU),aV['prototype'][ee(0x291)]=function(){return aC(this,void 0x0,Promise,function(){var aW,aX,aY,aZ,b0,b1;return aD(this,function(b2){var ef=a4b;switch(b2[ef(0x288)]){case 0x0:return aW=this[ef(0x159)],aX=aW[ef(0x203)],aY=aW[ef(0x2c6)],aZ=aW[ef(0x2cb)],b0=aW['sticker'],b1=aW[ef(0x2a3)],[0x4,this[ef(0x170)](aW)];case 0x1:return b2['sent'](),this[ef(0x267)](aX),[0x4,this['setMakeup'](aY)];case 0x2:return b2[ef(0x2c8)](),b0?[0x4,this[ef(0x1a3)](b0)]:[0x3,0x4];case 0x3:b2[ef(0x2c8)](),b2['label']=0x4;case 0x4:return b1?this['_app3d']?[0x3,0x6]:[0x4,this['initThreeApp']()]:[0x3,0x8];case 0x5:b2['sent'](),b2[ef(0x288)]=0x6;case 0x6:return[0x4,this[ef(0x157)](b1)];case 0x7:b2[ef(0x2c8)](),b2[ef(0x288)]=0x8;case 0x8:return[0x2,aZ];}});});},aV['prototype'][ee(0x1bd)]=function(){return aC(this,void 0x0,void 0x0,function(){return aD(this,function(aW){return[0x2];});});},aV['prototype'][ee(0x170)]=function(aW){var eg=ee,aX,aY,aZ=this,b0=new a4[(eg(0x2a0))](),b1=(aW[eg(0x203)]||[])[eg(0x161)](aW[eg(0x2c6)]||[])[eg(0x161)](aW[eg(0x24d)]||[]),b2={},b3=function(b6){var eh=eg;if(b6['src']instanceof Array)b6['src'][eh(0x296)](function(b8,b9){var ei=eh,ba=aZ['checkSpriteSheetJSON'](b8);if(ba){var bb=ba[ei(0x2d3)][ei(0x143)],bc=''[ei(0x161)](aZ[ei(0x2aa)],'|')['concat'](bb);if(a4[ei(0x1b2)][ei(0x26b)][bc])return;if(b6[ei(0x177)]&&b6['objectSrc'][ei(0x1d2)]){var bd=a4[ei(0x178)][ei(0x201)](b6[ei(0x177)][b9]);a4[ei(0x178)]['addToCache'](bd,bc);}else{if(0x0===bb[ei(0x2da)](ei(0x2d7)))bd=a4[ei(0x178)][ei(0x201)](bb),a4['Texture']['addToCache'](bd,bc);else b0[ei(0x242)](bc,bb);}ba[ei(0x2d3)]['image']='',b2[bc]=ba;}else{if(a4[ei(0x1b2)][ei(0x26b)][b8])return;if(b0['resources'][b8])return;if(b6['objectSrc']&&b6[ei(0x177)][ei(0x1d2)])bd=a4['Texture'][ei(0x201)](b6[ei(0x177)][b9]),a4['Texture'][ei(0x21d)](bd,b8);else b0[ei(0x242)](b8,b8);}});else{if(a4[eh(0x1b2)]['TextureCache'][b6[eh(0x19f)]])return console[eh(0x2b3)](eh(0x146)),eh(0x2ac);if(b0[eh(0x194)][b6[eh(0x19f)]])return console['log'](eh(0x2a1),b6[eh(0x19f)]),eh(0x2ac);if(b6['objectSrc']){console['log']('use\x20imagebitmap\x20to\x20create\x20texture');var b7=a4[eh(0x178)][eh(0x201)](b6[eh(0x177)]);a4[eh(0x178)]['addToCache'](b7,b6[eh(0x19f)]);}else{if(0x0===b6[eh(0x19f)][eh(0x2da)](eh(0x2d7)))b7=a4['Texture']['from'](b6[eh(0x19f)]),(console[eh(0x2b3)]('JSONEffect\x20blob\x20texture',b7),a4[eh(0x178)]['addToCache'](b7,b6[eh(0x19f)]));else b0[eh(0x242)](b6[eh(0x19f)]);}}};try{for(var b4=aE(b1),b5=b4['next']();!b5[eg(0x19b)];b5=b4[eg(0x1ed)]()){b3(b5[eg(0x15d)]);}}catch(b6){aX={'error':b6};}finally{try{b5&&!b5[eg(0x19b)]&&(aY=b4[eg(0x2a9)])&&aY[eg(0x200)](b4);}finally{if(aX)throw aX[eg(0x2b0)];}}return new Promise(function(b7){return aC(aZ,void 0x0,void 0x0,function(){var b8=this;return aD(this,function(b9){var ej=a4b;return b0[ej(0x291)](function(ba,bb){return aC(b8,void 0x0,void 0x0,function(){var bc,bd,be,bf,bg;return aD(this,function(bh){var ek=a4b;switch(bh[ek(0x288)]){case 0x0:for(be in(bc=function(bi){var bj;return aD(this,function(bk){var el=a4b;switch(bk[el(0x288)]){case 0x0:return a6['iV'][bi]?[0x2,el(0x2ac)]:b2[bi]?(bj=new a4[(el(0x22f))](a4[el(0x1b2)]['TextureCache'][bi],b2[bi]),[0x4,new Promise(function(bl){var em=el;bj[em(0x189)](function(){a6['iV'][bi]=bj,bl();});})]):[0x3,0x2];case 0x1:bk[el(0x2c8)](),bk[el(0x288)]=0x2;case 0x2:return[0x2];}});},bd=[],a4[ek(0x1b2)]['TextureCache']))bd[ek(0x24e)](be);bf=0x0,bh[ek(0x288)]=0x1;case 0x1:return bf<bd[ek(0x1d2)]?(bg=bd[bf],[0x5,bc(bg)]):[0x3,0x4];case 0x2:bh[ek(0x2c8)](),bh[ek(0x288)]=0x3;case 0x3:return bf++,[0x3,0x1];case 0x4:for(bg in bb)a6['iV'][bg]||b2[bg]||(a6['iV'][bg]=bb[bg]);return b7(),[0x2];}});});}),[0x2];});});});},aV['prototype'][ee(0x157)]=function(aW){return aC(this,void 0x0,Promise,function(){return aD(this,function(aX){return[0x2];});});},aV;}(aG),aI=a2(0x1424),aJ=a2(0x18a5),aK=a2(0x435),aL=(function(){var aU=function(aV,aW){var en=a4b;return aU=Object[en(0x1f0)]||{'__proto__':[]}instanceof Array&&function(aX,aY){var eo=en;aX[eo(0x150)]=aY;}||function(aX,aY){var ep=en;for(var aZ in aY)Object[ep(0x18f)]['hasOwnProperty'][ep(0x200)](aY,aZ)&&(aX[aZ]=aY[aZ]);},aU(aV,aW);};return function(aV,aW){var eq=a4b;if(eq(0x202)!=typeof aW&&null!==aW)throw new TypeError(eq(0x1c2)+String(aW)+eq(0x252));function aX(){var er=eq;this[er(0x1e2)]=aV;}aU(aV,aW),aV['prototype']=null===aW?Object[eq(0x14b)](aW):(aX[eq(0x18f)]=aW[eq(0x18f)],new aX());};}()),aM=function(aU,aV,aW,aX){var es=a4b,aY,aZ=arguments[es(0x1d2)],b0=aZ<0x3?aV:null===aX?aX=Object[es(0x2ab)](aV,aW):aX;if(es(0x236)==typeof Reflect&&es(0x202)==typeof Reflect['decorate'])b0=Reflect[es(0x1e6)](aU,aV,aW,aX);else{for(var b1=aU[es(0x1d2)]-0x1;b1>=0x0;b1--)(aY=aU[b1])&&(b0=(aZ<0x3?aY(b0):aZ>0x3?aY(aV,aW,b0):aY(aV,aW))||b0);}return aZ>0x3&&b0&&Object['defineProperty'](aV,aW,b0),b0;},aN=function(aU,aV){var et=a4b;if('object'==typeof Reflect&&'function'==typeof Reflect[et(0x19e)])return Reflect[et(0x19e)](aU,aV);},aO=function(aU,aV,aW,aX){return new(aW||(aW=Promise))(function(aY,aZ){var ev=a4b;function b0(b3){try{b2(aX['next'](b3));}catch(b4){aZ(b4);}}function b1(b3){try{b2(aX['throw'](b3));}catch(b4){aZ(b4);}}function b2(b3){var eu=a4b,b4;b3[eu(0x19b)]?aY(b3[eu(0x15d)]):(b4=b3['value'],b4 instanceof aW?b4:new aW(function(b5){b5(b4);}))['then'](b0,b1);}b2((aX=aX['apply'](aU,aV||[]))[ev(0x1ed)]());});},aP=function(aU,aV){var ew=a4b,aW,aX,aY,aZ,b0={'label':0x0,'sent':function(){if(0x1&aY[0x0])throw aY[0x1];return aY[0x1];},'trys':[],'ops':[]};return aZ={'next':b1(0x0),'throw':b1(0x1),'return':b1(0x2)},ew(0x202)==typeof Symbol&&(aZ[Symbol[ew(0x1ec)]]=function(){return this;}),aZ;function b1(b2){return function(b3){return function(b4){var ex=a4b;if(aW)throw new TypeError(ex(0x1f9));for(;b0;)try{if(aW=0x1,aX&&(aY=0x2&b4[0x0]?aX['return']:b4[0x0]?aX[ex(0x1e1)]||((aY=aX['return'])&&aY[ex(0x200)](aX),0x0):aX['next'])&&!(aY=aY[ex(0x200)](aX,b4[0x1]))[ex(0x19b)])return aY;switch(aX=0x0,aY&&(b4=[0x2&b4[0x0],aY[ex(0x15d)]]),b4[0x0]){case 0x0:case 0x1:aY=b4;break;case 0x4:return b0[ex(0x288)]++,{'value':b4[0x1],'done':!0x1};case 0x5:b0['label']++,aX=b4[0x1],b4=[0x0];continue;case 0x7:b4=b0[ex(0x1de)][ex(0x249)](),b0[ex(0x259)][ex(0x249)]();continue;default:if(!(aY=b0[ex(0x259)],(aY=aY[ex(0x1d2)]>0x0&&aY[aY['length']-0x1])||0x6!==b4[0x0]&&0x2!==b4[0x0])){b0=0x0;continue;}if(0x3===b4[0x0]&&(!aY||b4[0x1]>aY[0x0]&&b4[0x1]<aY[0x3])){b0[ex(0x288)]=b4[0x1];break;}if(0x6===b4[0x0]&&b0[ex(0x288)]<aY[0x1]){b0[ex(0x288)]=aY[0x1],aY=b4;break;}if(aY&&b0[ex(0x288)]<aY[0x2]){b0[ex(0x288)]=aY[0x2],b0[ex(0x1de)][ex(0x24e)](b4);break;}aY[0x2]&&b0['ops'][ex(0x249)](),b0[ex(0x259)][ex(0x249)]();continue;}b4=aV[ex(0x200)](aU,b0);}catch(b5){b4=[0x6,b5],aX=0x0;}finally{aW=aY=0x0;}if(0x5&b4[0x0])throw b4[0x1];return{'value':b4[0x0]?b4[0x1]:void 0x0,'done':!0x0};}([b2,b3]);};}},aQ=function(aU){var ey=a4b,aV=ey(0x202)==typeof Symbol&&Symbol[ey(0x1ec)],aW=aV&&aU[aV],aX=0x0;if(aW)return aW[ey(0x200)](aU);if(aU&&ey(0x195)==typeof aU['length'])return{'next':function(){var ez=ey;return aU&&aX>=aU[ez(0x1d2)]&&(aU=void 0x0),{'value':aU&&aU[aX++],'done':!aU};}};throw new TypeError(aV?ey(0x292):ey(0x2e2));},aR=(0x0,ay['jl'])(eA(0x15a)),aS=function(){},aT=function(aU){var eC=eA;function aV(aW){var eB=a4b,aX=aU[eB(0x200)](this,aW)||this;return aX[eB(0x27b)]=!0x1,aX[eB(0x16d)]=[],aX[eB(0x1ba)]=!0x0,aX[eB(0x20a)]=!0x1,aX['_isVR']=!0x1,aX[eB(0x293)]=0x0,console['log']('[@#$]\x20AR\x20Renderer\x20Constructed',location),aX[eB(0x1ba)]=!0x1,aW[eB(0x29f)]?aX['_canvas']=new wx[(eB(0x263))][(eB(0x14a))](aW['output']):aX[eB(0x29c)]=new wx[(eB(0x263))][(eB(0x14a))](wx[eB(0x1bc)]({'type':eB(0x279),'width':aW[eB(0x268)],'height':aW[eB(0x14c)]})),aX[eB(0x1c1)]=new a4[(eB(0x1fe))](),aX[eB(0x1f5)]=aW,aX[eB(0x1a5)]=new a4[(eB(0x15a))]({'view':aX[eB(0x29c)],'width':aW[eB(0x268)],'height':aW[eB(0x14c)],'preserveDrawingBuffer':!0x1,'antialias':!0x1}),aX[eB(0x16e)](aW),aX[eB(0x2a7)](),aX['setup'](),aX;}return aL(aV,aU),Object[eC(0x218)](aV[eC(0x18f)],eC(0x2cc),{'set':function(aW){},'enumerable':!0x1,'configurable':!0x0}),Object[eC(0x218)](aV[eC(0x18f)],'backGroundVR',{'set':function(aW){var eD=eC;if(aW){this[eD(0x2b8)]=new a4[(eD(0x29b))](a4[eD(0x178)][eD(0x201)](aW));var aX=this[eD(0x2b8)],aY=aX['width'],aZ=aX[eD(0x14c)],b0=Math[eD(0x262)](this['_options']['width']/aY,this[eD(0x1f5)][eD(0x14c)]/aZ);this[eD(0x2b8)][eD(0x268)]*=b0,this[eD(0x2b8)]['height']*=b0;}else this[eD(0x2b8)]=null;},'enumerable':!0x1,'configurable':!0x0}),Object[eC(0x218)](aV[eC(0x18f)],'options',{'set':function(aW){var eE=eC,aX=aW[eE(0x268)],aY=aW[eE(0x14c)];this[eE(0x1a5)]&&this[eE(0x1a5)]['resize'](aX,aY),this['_baseSprite']&&(this['_baseSprite'][eE(0x268)]=aX,this[eE(0x225)][eE(0x14c)]=aY,this['_baseSprite'][eE(0x197)][eE(0x1d0)]()),this[eE(0x1f5)]=aW;},'enumerable':!0x1,'configurable':!0x0}),Object[eC(0x218)](aV['prototype'],'app3d',{'get':function(){var eF=eC;return this[eF(0x2d0)];},'enumerable':!0x1,'configurable':!0x0}),Object[eC(0x218)](aV[eC(0x18f)],eC(0x257),{'get':function(){var eG=eC;return this[eG(0x1f7)];},'enumerable':!0x1,'configurable':!0x0}),aV[eC(0x18f)]['initRenderContext']=function(aW){var eH=eC;this[eH(0x2d2)]=new a4[(eH(0x1fe))](),this[eH(0x18e)]=new a4[(eH(0x1fe))](),this[eH(0x1b3)]=new a4[(eH(0x1fe))](),this[eH(0x265)]=a4['RenderTexture'][eH(0x14b)]({'width':aW[eH(0x268)],'height':aW[eH(0x14c)]}),this[eH(0x1c5)]=a4['RenderTexture'][eH(0x14b)]({'width':aW['width'],'height':aW[eH(0x14c)]}),this[eH(0x18e)]['addChild'](new a4['Sprite'](this[eH(0x265)])),aS[eH(0x190)]=this[eH(0x265)],this[eH(0x1b3)][eH(0x237)](new a4['Sprite'](this['_makeupRenderTexture'])),this[eH(0x1c1)][eH(0x237)](this[eH(0x1b3)]),this['_target']=this['_finalContainer'];},aV[eC(0x18f)][eC(0x155)]=function(){return aO(this,void 0x0,Promise,function(){var aW;return aP(this,function(aX){var eI=a4b;switch(aX[eI(0x288)]){case 0x0:return[0x4,(aW=new aJ['e']({}))[eI(0x226)]()];case 0x1:return aX[eI(0x2c8)](),this[eI(0x1f5)][eI(0x255)]&&this[eI(0x1f5)][eI(0x255)](aG,aH,aW),[0x2];}});});},aV[eC(0x18f)][eC(0x144)]=function(){return aO(this,void 0x0,void 0x0,function(){return aP(this,function(aW){var eJ=a4b;switch(aW[eJ(0x288)]){case 0x0:return this[eJ(0x27b)]?[0x2]:(this[eJ(0x2ad)]=new a8['M'](),[0x4,this[eJ(0x2ad)][eJ(0x291)]()]);case 0x1:return aW[eJ(0x2c8)](),this[eJ(0x27b)]=!0x0,[0x2];}});});},Object[eC(0x218)](aV['prototype'],eC(0x22d),{'get':function(){var eK=eC;return this[eK(0x213)];},'set':function(aW){var eL=eC;this[eL(0x213)]=aW;},'enumerable':!0x1,'configurable':!0x0}),Object[eC(0x218)](aV[eC(0x18f)],'mirrorFilter',{'get':function(){var eM=eC;return this['_mirrorFilter']||(this['_mirrorFilter']=new a7['f'](eM(0x2cc),{'width':ac['t'][eM(0x23e)]['options'][eM(0x268)],'height':ac['t']['instance'][eM(0x2c3)][eM(0x14c)]})),this[eM(0x2dd)];},'enumerable':!0x1,'configurable':!0x0}),aV[eC(0x18f)]['switchMode']=function(aW){var eN=eC;aW!==this[eN(0x223)]&&('Sticker'===aW&&this[eN(0x14f)](null),this[eN(0x223)]=aW);},aV['prototype'][eC(0x1e7)]=function(aW){var eO=eC,aX=+new Date();console['log'](''[eO(0x161)](aW,eO(0x18d))[eO(0x161)](aX-this[eO(0x2e1)])),this['currentTime']=aX;},aV[eC(0x18f)]['tick']=function(aW){var eP=eC,aX=aW[eP(0x149)],aY=aW[eP(0x22d)],aZ=aW['lipVertex'],b0=aW[eP(0x143)],b1=aW[eP(0x22c)],b2=(aW[eP(0x2c1)],aW[eP(0x27c)],aW[eP(0x235)],aW[eP(0x1ee)],aW[eP(0x2cd)]);if(!this[eP(0x20a)]){if(this[eP(0x1a5)]){if(this['_stage']){if(this[eP(0x27b)]){this[eP(0x2e1)]=+new Date();try{this['_renderer'][eP(0x1eb)]();}catch(b9){}if(this[eP(0x290)])try{this[eP(0x1a5)][eP(0x1af)](this['_backgroundVR']);}catch(ba){}else{if(b2){if(this[eP(0x225)])this[eP(0x225)][eP(0x197)]['update']();else b7=a4[eP(0x178)][eP(0x201)](b0),(this[eP(0x225)]=new a4[(eP(0x29b))](b7),this[eP(0x225)]['anchor'][eP(0x168)](0.5,0.5),this[eP(0x225)]['position'][eP(0x168)](this[eP(0x1f5)]['width']/0x2,this[eP(0x1f5)]['height']/0x2),this[eP(0x225)][eP(0x24c)][eP(0x168)](0x1,-0x1),this[eP(0x2d2)][eP(0x237)](this['_baseSprite']));}else{var b3=b0,b4=b3['width'],b5=b3[eP(0x14c)],b6=b3[eP(0x25d)];if(this[eP(0x225)])this[eP(0x225)]['texture'][eP(0x190)][eP(0x171)][eP(0x25d)]=new Uint8Array(b6),this[eP(0x225)][eP(0x197)][eP(0x1d0)]();else{var b7=a4[eP(0x178)][eP(0x215)](new Uint8Array(b6),b4,b5);this['_baseSprite']=new a4[(eP(0x29b))](b7),this[eP(0x225)][eP(0x1a7)][eP(0x168)](0.5,0.5),this[eP(0x225)][eP(0x13b)][eP(0x168)](this[eP(0x1f5)][eP(0x268)]/0x2,this[eP(0x1f5)]['height']/0x2);var b8=Math[eP(0x262)](this[eP(0x1f5)][eP(0x268)]/b4,this['_options']['height']/b5);this[eP(0x225)][eP(0x24c)][eP(0x168)](b8),this[eP(0x2d2)][eP(0x237)](this['_baseSprite']);}}if(!aX||!aX[eP(0x1d2)])return this[eP(0x16d)][eP(0x296)](function(bb){var eQ=eP;return bb[eQ(0x26f)]=!0x1;}),this[eP(0x16d)]['forEach'](function(bb){bb['tickMesh']();}),new Date(),(this[eP(0x1a5)]['render'](this['_baseContainer'],{'renderTexture':this['_baseRenderTexture']}),this[eP(0x1a5)][eP(0x1af)](this[eP(0x18e)],{'renderTexture':this[eP(0x1c5)]}),void this[eP(0x1a5)]['render'](this[eP(0x1c1)]));this[eP(0x1df)]=aX,this[eP(0x217)]=b1,this[eP(0x22d)]=aY,this[eP(0x231)]=aZ,this['_effects'][eP(0x296)](function(bb){var eR=eP;bb['visible']||(bb['visible']=!0x0),bb[eR(0x246)]=aZ,bb[eR(0x13e)]=aY,bb[eR(0x22c)]=b1,bb[eR(0x2bb)]=aX,bb[eR(0x27f)]();}),this['_renderer'][eP(0x1af)](this[eP(0x2d2)],{'renderTexture':this['_baseRenderTexture']}),this[eP(0x1a5)][eP(0x1af)](this[eP(0x18e)],{'renderTexture':this[eP(0x1c5)]}),this[eP(0x1a5)][eP(0x1af)](this[eP(0x1c1)]),eP(0x1d4)===this[eP(0x223)]&&this[eP(0x2d0)]&&this[eP(0x2d0)]['loaded']&&(this[eP(0x2d0)][eP(0x222)]=aX,this[eP(0x2d0)][eP(0x22c)]=b1,this[eP(0x2d0)]['render']());}}else ay['b_'][eP(0x2c4)](eP(0x1fa));}else ay['b_'][eP(0x2c4)](eP(0x1b9));}else ay['b_'][eP(0x2c4)](eP(0x172));}},aV[eC(0x18f)][eC(0x180)]=function(){var eS=eC;return this[eS(0x225)][eS(0x197)];},aV[eC(0x18f)][eC(0x27a)]=function(){var eT=eC;this[eT(0x27c)]&&(this[eT(0x27c)][eT(0x20f)](),this[eT(0x27c)]=null);},aV[eC(0x18f)]['applyBackground']=function(aW){var eU=eC;this[eU(0x27c)];},aV[eC(0x18f)][eC(0x14d)]=function(aW){var eV=eC;if(!this['points']){for(var aX=[],aY=0x0;0x2*aY<aW[eV(0x1d2)];aY++){var aZ=this['getCircle'](0x2);aX[eV(0x24e)](aZ),this[eV(0x2d2)]['addChild'](aZ);}this[eV(0x1a9)]=aX;}for(aY=0x0;0x2*aY<aW[eV(0x1d2)];aY++)this[eV(0x1a9)][aY]['x']=aW[0x2*aY],this[eV(0x1a9)][aY]['y']=aW[0x2*aY+0x1];},aV[eC(0x18f)]['debugDraw2']=function(aW){var eW=eC;if(console[eW(0x2b3)](eW(0x212),aW[eW(0x1d2)]),!this[eW(0x1a9)]){for(var aX=[],aY=0x0;aY<aW['length'];aY++){var aZ=this[eW(0x23d)](0x2);aX[eW(0x24e)](aZ),this[eW(0x2d2)][eW(0x237)](aZ);}this[eW(0x1a9)]=aX;}for(aY=0x0;aY<aW[eW(0x1d2)];aY++)this['points'][aY]['x']=0x21c*aW[aY]['x'],this['points'][aY]['y']=0x21c*aW[aY]['y'];},aV['prototype'][eC(0x1b5)]=function(){var eX=eC,aW=this[eX(0x1f5)],aX=aW['width'],aY=aW['height'],aZ=new Uint8Array(aX*aY*0x4),b0=this[eX(0x1a5)]['gl'];return b0[eX(0x18a)](0x0,0x0,aX,aY,b0[eX(0x1fb)],b0[eX(0x1f2)],aZ),{'data':aZ,'width':aX,'height':aY};},aV[eC(0x18f)][eC(0x1d7)]=function(aW,aX,aY,aZ){return aO(this,void 0x0,Promise,function(){var b0,b1=this;return aP(this,function(b2){var eY=a4b;return b0=!0x0,this[eY(0x169)]&&this[eY(0x169)][eY(0x1d2)]===aW[eY(0x1d2)]&&aW['every'](function(b3){var eZ=eY;return b1[eZ(0x169)][eZ(0x2da)](b3)>-0x1;})&&(b0=!0x1,this[eY(0x250)]&&(clearTimeout(this['debounceTimer']),this[eY(0x250)]=null)),this[eY(0x169)]=aW,[0x2,new Promise(function(b3,b4){var f0=eY;b0?(b1[f0(0x250)]&&(clearTimeout(b1[f0(0x250)]),b1[f0(0x250)]=null),b1[f0(0x250)]=setTimeout(function(){var f1=f0;return b1[f1(0x229)](aW,aX,aY,aZ)[f1(0x1a8)](function(b5){var f2=f1;clearTimeout(b1['debounceTimer']),b1[f2(0x250)]=null,b3(b5);});},0x64)):b1['_setEffect'](aW,aX,aY)[f0(0x1a8)](function(b5){b3(b5);});})];});});},aV[eC(0x18f)][eC(0x229)]=function(aW,aX,aY,aZ){return aO(this,void 0x0,Promise,function(){var b0,b1=this;return aP(this,function(b2){var f3=a4b;return ay['b_'][f3(0x1bb)](f3(0x264)),this[f3(0x213)]?(ay['b_']['timeEnd'](f3(0x264)),b0='uid_'+Math[f3(0x21e)](0x5f5e100*Math['random']()),[0x2,new Promise(function(b3,b4){return aO(b1,void 0x0,void 0x0,function(){var b5,b6,b7,b8,b9,ba,bb,bc,bd,be,bf,bg,bh,bi,bj=this;return aP(this,function(bk){var f4=a4b;switch(bk[f4(0x288)]){case 0x0:for(b5=[][f4(0x161)](this[f4(0x16d)]),b6=[],b7=[],b8=[],b9=[],ba=[],bb=[],aW[f4(0x1d2)]||(this[f4(0x233)]=null),bc=function(bl){var f5=f4,bm=b5['findIndex'](function(bp){return bp['url']===aW[bl];}),bn=void 0x0;if(bm>-0x1)b6[f5(0x24e)](b5[bm]),bn=b5[bm],b7[f5(0x24e)](aX[bl]),b8[f5(0x24e)](aY[bl]),b5[f5(0x207)](bm,0x1);else{var bo=aW[bl];(bn=new aG(bo,bd[f5(0x18e)],bd['_finalContainer'],bd[f5(0x2d0)],bd[f5(0x1f5)],bd['_meshVertex'],bd['_faceLandmarks'],bd[f5(0x231)],bd[f5(0x217)],aX[bl],bd[f5(0x29c)]))['filterIntensity']=aY[bl],bn[f5(0x187)]=bd[f5(0x1a5)],b9['push'](bn),bb['push'](bn['download']());}},bd=this,be=0x0;be<aW['length'];be++)bc(be);return[0x4,Promise[f4(0x2b4)](bb)];case 0x1:if(bf=bk[f4(0x2c8)](),ay['b_'][f4(0x1bb)](f4(0x154)),this['lib3dLoaded'])return[0x3,0x5];bg=0x0,bk['label']=0x2;case 0x2:return bg<bf[f4(0x1d2)]?(bh=bf[bg],(bi=bh[f4(0x2a3)])&&bi[f4(0x1d2)]?aZ&&!aZ()?[0x2]:(console['log']('require\x203d\x20lib'),[0x4,this[f4(0x155)]()]):[0x3,0x4]):[0x3,0x5];case 0x3:bk['sent'](),this[f4(0x1f1)]=!0x0,bk[f4(0x288)]=0x4;case 0x4:return bg++,[0x3,0x2];case 0x5:return ay['b_'][f4(0x282)](f4(0x154)),b9['forEach'](function(bl){var f6=f4;ba[f6(0x24e)](bl['load']()[f6(0x1a8)](function(){var f7=f6;return bj[f7(0x2d0)]||(bj['_app3d']=bl['app3d']),bl;})[f6(0x28c)](function(bm){var f8=f6;aR[f8(0x141)](f8(0x277),bm);}));}),ay['b_'][f4(0x1bb)](f4(0x298)),Promise[f4(0x2b4)](ba)['then'](function(bl){var f9=f4;ay['b_'][f9(0x282)]('renderer\x20parse\x20effect'),ay['b_'][f9(0x1bb)](f9(0x272));for(var bm=!0x1,bn=0x0;bn<b9[f9(0x1d2)];bn++){var bo=b9[bn];bj[f9(0x169)]&&-0x1===bj[f9(0x169)][f9(0x2da)](bo[f9(0x18b)]())&&(bo['destroy'](),bm=!0x0);}if(bm)aR[f9(0x2c4)](b0+'end');else{b5['forEach'](function(bp){var fa=f9;bp[fa(0x20f)]();}),bj[f9(0x16d)]=b6,b6[f9(0x296)](function(bp,bq){var fb=f9;bp['intensity']=b7[bq],bp[fb(0x2c7)]=b8[bq];});for(bn=0x0;bn<b9['length'];bn++){bo=b9[bn],(bj[f9(0x16d)]['push'](bo),bo[f9(0x1d6)]({'filterTarget':bj[f9(0x225)],'filterCallback':function(){}}));}b5[f9(0x296)](function(bp){var fc=f9;bp[fc(0x151)]();}),ay['b_'][f9(0x282)](f9(0x272)),b3(bj['_effects']);}}),[0x2];}});});})]):[0x2,new Promise(function(b3){clearTimeout(b1['_meshVertexTimer']),b1['_meshVertexTimer']=setInterval(function(){var fd=a4b;ay['b_'][fd(0x2c4)](fd(0x264)),b1[fd(0x213)]&&(ay['b_'][fd(0x2c4)](fd(0x13a)),clearTimeout(b1[fd(0x293)]),b1[fd(0x229)](aW,aX,aY,aZ)[fd(0x1a8)](function(){var fe=fd;b3(b1[fe(0x16d)]);}));},0xc8);})];});});},aV[eC(0x18f)][eC(0x29e)]=function(aW){return aO(this,void 0x0,void 0x0,function(){var aX,aY,aZ,b0=this;return aP(this,function(b1){var ff=a4b;switch(b1[ff(0x288)]){case 0x0:return this[ff(0x1f1)]?[0x3,0x2]:(aY=aW['sticker3d'])&&aY[ff(0x1d2)]?(console[ff(0x2b3)]('require\x203d\x20lib'),[0x4,this['loadLib3d']()]):[0x3,0x2];case 0x1:b1[ff(0x2c8)](),this[ff(0x1f1)]=!0x0,b1[ff(0x288)]=0x2;case 0x2:return(aZ=function(){var fg=ff;if(b0[fg(0x213)]){aX&&clearTimeout(aX);var b2=new aH(aW,b0['_makeupContainer'],b0[fg(0x1b3)],b0[fg(0x2d0)],b0['_options'],b0[fg(0x213)],b0['_faceLandmarks'],b0[fg(0x231)]);b2[fg(0x187)]=b0['_renderer'],b2[fg(0x291)]()['then'](function(){var fh=fg;b0['_app3d']||(b0[fh(0x2d0)]=b2[fh(0x286)]);var b3=[][fh(0x161)](b0['_effects']);b0[fh(0x16d)]=[b2],b2['apply']({'filterTarget':b0[fh(0x225)]}),b3[fh(0x296)](function(b4){var fi=fh;b4[fi(0x151)]();});});}else aX=setTimeout(aZ,0x14);})(),[0x2];}});});},aV[eC(0x18f)][eC(0x241)]=function(aW,aX){var aY=this;return void 0x0===aX&&(aX=0x1),new Promise(function(aZ,b0){!(function(){var fj=a4b;if(aY['exclusiveFilter']&&aY[fj(0x167)]['getUrl']()===aW)aY['exclusiveFilter']['intensity']=aX,aY[fj(0x167)][fj(0x2c7)]=aX;else{var b1=new aG(aW,aY[fj(0x18e)],aY[fj(0x1b3)],aY[fj(0x2d0)],aY[fj(0x1f5)],aY['_meshVertex'],aY['_faceLandmarks'],aY[fj(0x231)],aY[fj(0x217)],aX);b1[fj(0x2c7)]=aX,b1[fj(0x291)]()[fj(0x1a8)](function(){var fk=fj;aY[fk(0x167)]&&aY[fk(0x167)][fk(0x151)](),aY[fk(0x167)]=b1,b1[fk(0x187)]=aY[fk(0x1a5)],b1[fk(0x1d6)]({'filterTarget':aY[fk(0x225)]}),aZ();});}}());});},aV[eC(0x18f)]['resize']=function(aW,aX){var fl=eC;aU[fl(0x18f)][fl(0x204)][fl(0x200)](this,aW,aX),console[fl(0x2b3)](fl(0x260),aW,aX),this[fl(0x1f5)][fl(0x268)]=aW,this[fl(0x1f5)][fl(0x14c)]=aX,this[fl(0x1a5)]['resize'](aW,aX),this[fl(0x27c)]&&this[fl(0x27c)][fl(0x204)](aW,aX),this['_app3d']?this['_app3d'][fl(0x204)](aW,aX):this[fl(0x1f7)]&&this[fl(0x1f7)][fl(0x204)](aW,aX),this[fl(0x265)]&&this[fl(0x265)][fl(0x204)](aW,aX),this['_makeupRenderTexture']&&this[fl(0x1c5)][fl(0x204)](aW,aX);},aV[eC(0x18f)][eC(0x2de)]=function(){var fm=eC;this[fm(0x167)]&&this[fm(0x167)][fm(0x20f)]();},aV[eC(0x18f)][eC(0x2a2)]=function(){var fn=eC;this[fn(0x167)]&&this[fn(0x167)][fn(0x1d6)]({'filterTarget':this['_baseSprite'],'filterCallback':function(){}});},aV['prototype'][eC(0x1e9)]=function(){var fo=eC;this[fo(0x16d)][fo(0x296)](function(aW){var fp=fo;console[fp(0x2b3)](fp(0x211),aW),aW[fp(0x2df)]||aW[fp(0x20f)]();});},aV[eC(0x18f)][eC(0x1ff)]=function(){var fq=eC,aW=this;this[fq(0x16d)][fq(0x296)](function(aX){var fr=fq;aX[fr(0x1d6)]({'filterTarget':aW[fr(0x225)],'filterCallback':function(){}});});},aV[eC(0x18f)][eC(0x2d4)]=function(){var fs=eC;this[fs(0x167)]&&(this[fs(0x167)][fs(0x151)](),this[fs(0x167)]=null);},aV[eC(0x18f)][eC(0x23a)]=function(aW,aX){return aO(this,void 0x0,void 0x0,function(){return aP(this,function(aY){return[0x2];});});},aV['prototype'][eC(0x14f)]=function(aW,aX){return aO(this,void 0x0,void 0x0,function(){return aP(this,function(aY){return[0x2];});});},aV[eC(0x18f)][eC(0x295)]=function(aW){},aV[eC(0x18f)][eC(0x1e5)]=function(){return aO(this,void 0x0,void 0x0,function(){return aP(this,function(aW){return[0x2];});});},aV[eC(0x18f)][eC(0x186)]=function(){var ft=eC;return this[ft(0x29c)];},aV['prototype'][eC(0x1dc)]=function(aW){},aV[eC(0x18f)][eC(0x2c2)]=function(aW){var fu=eC;this['_canvas']&&aW['appendChild'](this[fu(0x29c)]);},aV['prototype'][eC(0x23d)]=function(aW){var fv=eC;void 0x0===aW&&(aW=0x5);var aX=new a4[(fv(0x214))]();return aX[fv(0x15b)](0xff0000),aX[fv(0x270)](0x0,0x0,aW),aX[fv(0x2bc)](),aX;},aV[eC(0x182)]=function(aW){return aO(this,void 0x0,Promise,function(){var aX,aY,aZ,b0,b1,b2,b3;return aP(this,function(b4){var fw=a4b;switch(b4[fw(0x288)]){case 0x0:return aW[fw(0x1d2)]?[0x4,(aX=new a6['pF']())[fw(0x226)]()]:[0x2];case 0x1:b4['sent'](),aY=[];try{for(aZ=aQ(aW),b0=aZ[fw(0x1ed)]();!b0[fw(0x19b)];b0=aZ[fw(0x1ed)]())(b1=b0[fw(0x15d)])&&aY['push'](aX[fw(0x176)](b1));}catch(b5){b2={'error':b5};}finally{try{b0&&!b0[fw(0x19b)]&&(b3=aZ['return'])&&b3[fw(0x200)](aZ);}finally{if(b2)throw b2['error'];}}return[0x2,Promise[fw(0x2b4)](aY)[fw(0x1a8)](function(){var fx=fw;return Promise[fx(0x25c)]();})[fw(0x28c)](function(b6){var fy=fw;return Promise[fy(0x22b)](b6);})];}});});},aV[eC(0x18f)][eC(0x2a7)]=function(){var fz=eC,aW=this['_options'],aX=aW['enableLoadingIcon'],aY=aW[fz(0x1a2)],aZ=void 0x0===aY?{}:aY;if(aX){var b0=aV[fz(0x23f)]=new aI['Z'](aZ);b0[fz(0x13d)]=0x14;var b1=this[fz(0x1f5)],b2=b1['width'],b3=b1['height'];b0['x']=b2/0x2,b0['y']=b3/0x2,this['_stage'][fz(0x237)](b0);}},aV[eC(0x18f)][eC(0x1d8)]=function(){var fA=eC;aV[fA(0x23f)]&&aV[fA(0x23f)]['show']();},aV[eC(0x18f)][eC(0x152)]=function(){var fB=eC;aV[fB(0x23f)]&&aV['loading']['hide']();},aV[eC(0x18f)][eC(0x151)]=function(){var fC=eC;this[fC(0x152)](),aV[fC(0x23f)]&&aV[fC(0x23f)]['destroy'](),aS[fC(0x190)][fC(0x151)](!0x0),aS['baseTexture']=null,this[fC(0x20a)]=!0x0,this[fC(0x16d)][fC(0x296)](function(aW){aW['destroy']();}),this[fC(0x167)]&&this[fC(0x167)]['destroy'](),this['_stage']&&this['_stage'][fC(0x151)](!0x0),this[fC(0x1a5)]&&this[fC(0x1a5)][fC(0x151)](!0x0),this[fC(0x27c)]&&this[fC(0x27c)]['destroy'](),this[fC(0x2d0)]&&this[fC(0x2d0)][fC(0x151)](),this[fC(0x293)]&&clearTimeout(this['_meshVertexTimer']),this['destroyAvatar']();},aV[eC(0x18f)][eC(0x17e)]=function(){var fD=eC;this[fD(0x1f7)]&&(this[fD(0x1f7)][fD(0x151)](),this[fD(0x1f7)]=null);},aM([(0x0,ab['M'])(eC(0x1ab)),aN(eC(0x258),Function),aN(eC(0x28d),[]),aN(eC(0x230),void 0x0)],aV[eC(0x18f)],eC(0x151),null),aV;}(aK['F']);}}]));
|
|
1
|
+
var self = wx;(self.webpackChunktencentcloud_webar=self.webpackChunktencentcloud_webar||[]).push([[321],{6237:(e,t,n)=>{n.d(t,{g:()=>le,b:()=>he});var i,r=n(337),o=n(3044),s=n(5536),a=n(1206),c=n(617),u=n(9560),h=n(1084),l=n(3849),p=(i=function(e,t){return i=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},i(e,t)},function(e,t){if("function"!=typeof t&&null!==t)throw new TypeError("Class extends value "+String(t)+" is not a constructor or null");function n(){this.constructor=e}i(e,t),e.prototype=null===t?Object.create(t):(n.prototype=t.prototype,new n)}),f=function(e,t,n,i){var r,o=arguments.length,s=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,i);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(s=(o<3?r(s):o>3?r(t,n,s):r(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},d=function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},y=function(){function e(e,t,n,i,r,o){this._destroyed=!1,this.type="makeup",this._parentIntensity=1,this._jsonIntensity=1,this.textures=[],this._dir=t,this._options=e,this._container=n,this._lipMaskTexture=o,this.renderer=i,this.type=r||"makeup"}return Object.defineProperty(e.prototype,"parentIntensity",{get:function(){return this._parentIntensity},set:function(e){this.shader&&(this.shader.uniforms.parentIntensity=e);this._parentIntensity=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lipMask",{set:function(e){null===e?(this._mesh.removeChild(this._cacheMask),this._mesh.mask=e):(this._mesh.addChild(e),this._mesh.mask=e,this._cacheMask=e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"visible",{set:function(e){this.shader&&(this.shader.uniforms.enable=e?1:0)},enumerable:!1,configurable:!0}),e.prototype.updateGeometry=function(e){this._destroyed},e.prototype.renderMesh=function(){},e.prototype.drawMeshBatch=function(e,t){var n=this;if(!this._destroyed){var i=Array.from(e.reduce((function(e,t){return e.add(t.blend),e}),new Set));this.irisRenderTexture&&!i.includes(this.irisBlendMode)&&i.push(this.irisBlendMode);var r="\n precision mediump float;\n varying vec2 vUvs;\n varying vec2 bUvs;\n \n\n ".concat(e.map((function(e,t){return"uniform sampler2D uSamplerMakeup".concat(t,";")})).join("\n"),"\n ").concat(e.map((function(e,t){return"uniform float intensity".concat(t,";")})).join("\n"),"\n uniform float parentIntensity;\n uniform int enable;\n uniform sampler2D baseImage;\n \n uniform sampler2D uSamplerIris;\n\n // uniform int mirror;\n uniform vec2 imageOffset;\n \n ").concat(i.map((function(e){return u.Lc[e].shader})).join("\n"),"\n \n void main() {\n if (enable == 0) {\n gl_FragColor = vec4(0.0,0.0,0.0,0.0);\n return;\n }\n\n // todo:适配镜像与非镜像\n vec2 baseCoord = bUvs;\n baseCoord += imageOffset;\n // if (mirror == 1) {\n // baseCoord = vec2(1.0 - bUvs.x, bUvs.y);\n // }\n vec4 baseColor = texture2D(baseImage, baseCoord);\n\n vec4 makeupColor = vec4(0.0);\n\n ").concat(e.map((function(e,t){return"\n \n vec4 color".concat(t," = texture2D(uSamplerMakeup").concat(t,", vUvs);\n float a").concat(t," = color").concat(t,".a;\n float realIntensity").concat(t," = intensity").concat(t," * parentIntensity;\n makeupColor = texture2D(uSamplerMakeup").concat(t,", vUvs) * realIntensity").concat(t,";\n if (makeupColor.a>0.) {\n // 混合\n baseColor.rgb = blend").concat(u.Lc[e.blend].key,"(baseColor.rgb, makeupColor.rgb/makeupColor.a , makeupColor.a);\n }\n \n \n \n\n ")})).join("\n"),"\n\n ").concat(this.irisRenderTexture?"\n // 混合美瞳\n vec4 irisColor = texture2D(uSamplerIris, bUvs);\n if (irisColor.a > 0.) {\n baseColor.rgb = blend".concat(u.Lc[this.irisBlendMode].key,"(baseColor.rgb, irisColor.rgb/irisColor.a , irisColor.a);\n }\n "):"","\n \n \n\n // 输出\n gl_FragColor = baseColor;\n }"),o={enable:1};o.parentIntensity=this.parentIntensity;var s=this._options,c=s.width,h=s.height;o.baseImage=he.baseTexture,o.size=[c*h/he.baseTexture.height,h];var p=he.baseTexture.width*h/he.baseTexture.height;o.imageOffset=[(p-c)/2/p,0],e.forEach((function(e,t){var i="default"===n._dir?e.src:"".concat(n._dir,"|").concat(e.src),r=a.P6.kN[i];o["uSamplerMakeup".concat(t)]=r,o["intensity".concat(t)]=e.intensity,n.textures.push(r)})),this.irisRenderTexture&&(o.uSamplerIris=this.irisRenderTexture);var f=a.ex.from("\n precision mediump float;\n attribute vec2 aVertexPosition;\n attribute vec2 aUvs;\n\n uniform mat3 translationMatrix;\n uniform mat3 projectionMatrix;\n uniform vec2 size;\n varying vec2 vUvs;\n varying vec2 bUvs;\n\n \n void main() {\n vUvs = aUvs;\n bUvs = aVertexPosition.xy /size;\n // lipUvs = lipAuvs;\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n }",r,o);this.shader=f,l.t.instance.on("mirrorChange",(function(e){}));var d=new a.Kj(t,f);return this._mesh=d,this._container.addChild(d),d}},e.prototype.destroy=function(){this._destroyed=!0,this._mesh&&(this._mesh.destroy({children:!0,texture:!1,baseTexture:!1}),this._mesh.mask=null,this._mesh=null),this._maskRenderTexure&&this._maskRenderTexure.destroy(!1)},f([(0,h.M)("MakeupLayer"),d("design:type",Function),d("design:paramtypes",[Array]),d("design:returntype",void 0)],e.prototype,"updateGeometry",null),f([(0,h.M)("MakeupLayer"),d("design:type",Function),d("design:paramtypes",[]),d("design:returntype",void 0)],e.prototype,"destroy",null),e}(),_=function(e){function t(t,n,i,r,o,s,c){var u=e.call(this,t,n,c)||this;return u._maskGraphics=new a.TC,u.maxLConSize=0,u.maxRConSize=0,u._parentIntensity=1,u.jsonIntensity=o,u.getTexture(i,r),u._config=s,u.renderTexture=a.TI.create({width:t.width,height:t.height}),u}var n,i;return p(t,e),Object.defineProperty(t.prototype,"parentIntensity",{get:function(){return this._parentIntensity},set:function(e){this._container&&(this._container.alpha=this.jsonIntensity*e),this._parentIntensity=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"visible",{set:function(e){this._container.visible=e},enumerable:!1,configurable:!0}),t.prototype.getTexture=function(e,t){var n="default"===this._dir?e:"".concat(this._dir,"|").concat(e),i=a.P6.kN[n],r=new a.jy(i),o=new a.jy(i.clone());r.anchor.set(.5),o.anchor.set(.5),this._leftIris=r,this._rightIris=o;var s=new a.W2;this._maskGraphics||(this._maskGraphics=new a.TC),s.addChild(this._maskGraphics),s.addChild(r),s.addChild(o),s.alpha=this.parentIntensity*this.jsonIntensity,s.mask=this._maskGraphics,this._container=s},t.prototype.setIrisProps=function(e,t){if(e.length){var n=this._config.getConfigByKeys(["POINTS_MAP","LEFT_IRIS","RIGHT_IRIS","LEFT_EYE_ORDER","RIGHT_EYE_ORDER"]),i=n.POINTS_MAP,r=(n.LEFT_IRIS,n.RIGHT_IRIS,n.LEFT_EYE_ORDER),o=n.RIGHT_EYE_ORDER,s=(i.left_eye_center,i.right_eye_center,getDistance(e[52],e[55])),a=getDistance(e[58],e[61]),c=Math.max(this.maxLConSize,getDistance(e[72],e[73])/s),u=Math.max(this.maxRConSize,getDistance(e[75],e[76])/a),h=s*c,l=s*c,p=a*u,f=a*u;this.maxLConSize=Math.max(Math.min(c,.7),.4),this.maxRConSize=Math.max(Math.min(u,.7),.4);var d=he.baseTexture.width*this._options.height/he.baseTexture.height,y=getCenter(e[74],e[104]),_=getCenter(e[77],e[105]);console.log("offset",(d-this._options.width)/2),y.x-=(d-this._options.width)/2,_.x-=(d-this._options.width)/2;var b=this._leftIris,m=this._rightIris;b.width=h,b.height=l,b.x=y.x,b.y=y.y,m.width=p,m.height=f,m.x=_.x,m.y=_.y,this._maskGraphics.clear(),this._drawMaskGraphics(r,e),this._drawMaskGraphics(o,e),t.render(this._container,{renderTexture:this.renderTexture})}},t.prototype._drawMaskGraphics=function(e,t){var n=this,i=this._maskGraphics;i.beginFill(16724736),i.lineStyle(1,16767232,1);var r=[];e.forEach((function(o,s){var a=t[o],c=n._getPixelPosition(a.x,a.y),u=c.x,h=c.y;r.push({x:u,y:h}),0===s?i.moveTo(u,h):s===e.length-1?(i.closePath(),i.endFill()):i.lineTo(u,h)}))},t.prototype._getPixelPosition=function(e,t){return{x:e,y:t}},t.prototype.destroy=function(){this._leftIris&&this._leftIris.destroy({children:!0,texture:!1,baseTexture:!1}),this._rightIris&&this._rightIris.destroy({children:!0,texture:!1,baseTexture:!1}),this._maskGraphics&&this._maskGraphics.destroy({children:!0,texture:!1,baseTexture:!1})},f([(0,h.M)("IrisLayer"),d("design:type",Function),d("design:paramtypes",["function"==typeof(n="undefined"!=typeof Array&&Array)?n:Object,"function"==typeof(i=void 0!==a.Th&&a.Th)?i:Object]),d("design:returntype",void 0)],t.prototype,"setIrisProps",null),t}(y),b=n(3120),m=n(1347),g=n(6109),v=function(e,t,n,i){var r,o=arguments.length,s=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,i);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(s=(o<3?r(s):o>3?r(t,n,s):r(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},k=function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},x=function(e,t,n,i){return new(n||(n=Promise))((function(r,o){function s(e){try{c(i.next(e))}catch(e){o(e)}}function a(e){try{c(i.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,a)}c((i=i.apply(e,t||[])).next())}))},w=function(e,t){var n,i,r,o,s={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,i&&(r=2&o[0]?i.return:o[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[2&o[0],r.value]),o[0]){case 0:case 1:r=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,i=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(r=s.trys,(r=r.length>0&&r[r.length-1])||6!==o[0]&&2!==o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]<r[3])){s.label=o[1];break}if(6===o[0]&&s.label<r[1]){s.label=r[1],r=o;break}if(r&&s.label<r[2]){s.label=r[2],s.ops.push(o);break}r[2]&&s.ops.pop(),s.trys.pop();continue}o=t.call(e,s)}catch(e){o=[6,e],i=0}finally{n=r=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,a])}}},S=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],i=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&i>=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},M=(0,g.jl)("makeup"),T=function(){function e(e,t,n){e&&(this._options=e),t&&(this._lipVertex=t),n&&(this.renderer=n)}return e.prototype.destroy=function(){var e=this._lipMask;this._lipMask=null;try{e.destroy(!0)}catch(e){}try{this._lipMaskMesh.destroy(!0),this._lipMaskMesh=null}catch(e){}try{this._maskRenderTexture.destroy(!0),this._maskRenderTexture=null}catch(e){}this._config=null;try{this._maskSprite.destroy(!0),this._maskSprite=null}catch(e){}},e.prototype.load=function(){return x(this,void 0,void 0,(function(){var e,t,n,i,r;return w(this,(function(o){switch(o.label){case 0:return this._config?[3,2]:(this._config=new c.M,[4,this._config.load()]);case 1:o.sent(),o.label=2;case 2:return this._lipMask?[3,4]:[4,this._getMask()];case 3:o.sent(),o.label=4;case 4:return this._maskSprite&&!this._maskSprite.destroyed||(e=this._options,t=e.width,n=e.height,i=new a.jd({width:t,height:n}),this._maskRenderTexture=new a.TI(i),r=new a.jy(this._maskRenderTexture),this._maskSprite=r),[2,{maskSprite:this._maskSprite,lipmask:this._lipMask,lipmaskmesh:this._lipMaskMesh}]}}))}))},e.prototype.update=function(e){this._lipMaskMesh&&(this._lipMaskMesh.geometry.getBuffer("aVertexPosition").update(e),this.render())},e.prototype.render=function(){this.renderer&&this._lipMask&&this.renderer.render(this._lipMask,{renderTexture:this._maskRenderTexture})},e.prototype._getMask=function(){return x(this,void 0,void 0,(function(){var e,t,n,i,r,o,s,c,u;return w(this,(function(h){switch(h.label){case 0:return this._lipMask?[2,this._lipMask]:(e=new a.W2,(t=new a.jy(a.xE.WHITE)).width=this._options.width,t.height=this._options.height,e.addChild(t),n=this._lipVertex,i=this._config.getDataConfig(29),[4,this._loadLipImage()]);case 1:return r=h.sent(),o=(new a.wG).addAttribute("aVertexPosition",n).addAttribute("aUvs",i),"\n precision mediump float;\n attribute vec2 aVertexPosition;\n attribute vec2 aUvs;\n uniform mat3 translationMatrix;\n uniform mat3 projectionMatrix;\n varying vec2 vUvs;\n\n\n void main() {\n vUvs = aUvs;\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n }","\n precision mediump float;\n varying vec2 vUvs;\n uniform sampler2D uSamplerMakeup;\n\n \n void main() {\n gl_FragColor = texture2D(uSamplerMakeup, vUvs);\n }",s={uSamplerMakeup:r},c=a.ex.from("\n precision mediump float;\n attribute vec2 aVertexPosition;\n attribute vec2 aUvs;\n uniform mat3 translationMatrix;\n uniform mat3 projectionMatrix;\n varying vec2 vUvs;\n\n\n void main() {\n vUvs = aUvs;\n gl_Position = vec4((projectionMatrix * translationMatrix * vec3(aVertexPosition, 1.0)).xy, 0.0, 1.0);\n }","\n precision mediump float;\n varying vec2 vUvs;\n uniform sampler2D uSamplerMakeup;\n\n \n void main() {\n gl_FragColor = texture2D(uSamplerMakeup, vUvs);\n }",s),u=new a.Kj(o,c),this._lipMaskMesh=u,e.addChild(u),this._lipMask=e,[2,e]}}))}))},e.prototype._loadLipImage=function(){return x(this,void 0,Promise,(function(){var e=this;return w(this,(function(t){return[2,new Promise((function(t,n){return x(e,void 0,void 0,(function(){var e,n,i;return w(this,(function(r){switch(r.label){case 0:return[4,(e=new b.KI).init()];case 1:return n=r.sent(),[4,e.loadImage(n)];case 2:return i=r.sent(),t(i[b.X_]),[2]}}))}))}))]}))}))},v([(0,h.M)("ReuseableLipMask"),k("design:type",Function),k("design:paramtypes",[]),k("design:returntype",void 0)],e.prototype,"destroy",null),v([(0,h.o)("ReuseableLipMask"),k("design:type",Function),k("design:paramtypes",[]),k("design:returntype",Promise)],e.prototype,"_getMask",null),e}(),P=function(){function e(e,t,n,i,r,o,s,c){void 0===c&&(c=1),this._container=new a.W2,this._makeupMeshes=[],this._visible=!0,this.mouthShut=!0,this._applyed=!1,this._key=e,this._data=t,this._options=n,this.mesh=i,this.lipmesh=o,this.faceLandMarks=r,this.renderer=s,this.parentIntensity=c;var u=new a.jy(a.xE.WHITE);u.alpha=0,u.width=n.width,u.height=n.height,this._container.addChild(u)}var t;return Object.defineProperty(e.prototype,"visible",{get:function(){return this._visible},set:function(e){var t=this;this._target&&e!==this._visible&&(this._visible=e,this._makeupMeshes.forEach((function(n){e?t.apply(t._target):t.remove()})))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"mesh",{set:function(e){(this._meshVertex=e,this.geometry)&&(this.geometry.getBuffer("aVertexPosition").update(e),this._makeupMeshes.forEach((function(t){t.updateGeometry(e)})))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lipmesh",{set:function(e){this._lipVertex=e,this._lipMaskIns&&this._lipMaskIns.update(e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"faceLandMarks",{set:function(e){var t=this;e&&e.length&&(this._irises&&this._irises.setIrisProps(e,this.renderer),(0,m.Sp)(e[98],e[102])<.03*(0,m.Sp)(e[0],e[32])?this.mouthShut||(this._makeupMeshes.forEach((function(e){"lips"===e.type&&(e.lipMask=null)})),this.mouthShut=!0):this.mouthShut&&(this._makeupMeshes.forEach((function(e){"lips"===e.type&&t._lipMaskIns&&(e.lipMask=t._lipMaskIns._maskSprite)})),this.mouthShut=!1))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"parentIntensity",{get:function(){return this._intensity},set:function(e){M.info("set parentIntensity",e),this._irises&&(this._irises.parentIntensity=e),this._makeupMeshes.forEach((function(t){t.parentIntensity=e})),this._intensity=e},enumerable:!1,configurable:!0}),e.prototype.renderMesh=function(){this._lipMaskIns&&this._lipMaskIns.render(),this._makeupMeshes.forEach((function(e){e.renderMesh()}))},e.prototype.load=function(){return x(this,void 0,void 0,(function(){var e,t,n,i,r,o,s,a;return w(this,(function(u){switch(u.label){case 0:return this._config=new c.M,[4,this._config.load()];case 1:if(u.sent(),e=this._data,M.info("makeup info",this._data),t=[],e&&e.length){try{for(n=S(e),i=n.next();!i.done;i=n.next())"iris"===(r=i.value).type?(this._irises=this._getIris(r.src,r.blend,r.intensity),this.irisBlendMode=r.blend):(r.blend+"",t.push({src:r.src,intensity:r.intensity,type:r.type,blend:r.blend}))}catch(e){s={error:e}}finally{try{i&&!i.done&&(a=n.return)&&a.call(n)}finally{if(s)throw s.error}}M.info("makeupLayersByBlendMode",t),o=this._getMeshLayerByBlendMode(t),this._makeupMeshes.push(o)}return[4,this._initLipMask()];case 2:return u.sent(),[2]}}))}))},e.prototype._getIris=function(e,t,n){return new _(this._options,this._key,e,t,n,this._config,this._container)},e.prototype._getMeshLayerByBlendMode=function(e){var t=e.some((function(e){return"lips"===e.type}))?"lips":"makeup",n=new y(this._options,this._key,this._container,this.renderer,t);n.parentIntensity=this.parentIntensity,this._irises&&(n.irisRenderTexture=this._irises.renderTexture.baseTexture,n.irisBlendMode=this.irisBlendMode);var i=this._config.getDataConfig(26);if(!this.geometry){var r=(new a.wG).addAttribute("aVertexPosition",this._meshVertex).addAttribute("aUvs",i);this.geometry=r}return n.drawMeshBatch(e,this.geometry),n},e.prototype.apply=function(e){this._target=e,this._applyMakeup(e)},e.prototype.remove=function(){this._removeMakeup(this._target)},e.prototype._applyMakeup=function(e){this._applyed||(this._applyed=!0,e.filters||(e.filters=[]),e.addChild(this._container))},e.prototype._removeMakeup=function(e){this._applyed&&(this._applyed=!1,e.filters&&e.removeChild(this._container))},e.prototype._initLipMask=function(){return x(this,void 0,void 0,(function(){var e,t,n=this;return w(this,(function(i){switch(i.label){case 0:return(e=new T(this._options,this._lipVertex,this.renderer))._options=this._options,e._lipVertex=this._lipVertex,e.renderer=this.renderer,this._lipMaskIns=e,[4,e.load()];case 1:return t=i.sent().maskSprite,this._makeupMeshes.forEach((function(e){"lips"!==e.type||n.mouthShut||(e.lipMask=t)})),[2]}}))}))},e.prototype.destroy=function(){this.remove(),this._makeupMeshes.forEach((function(e){return e.destroy()})),this._makeupMeshes=[],this._irises&&this._irises.destroy(),this._irises=null,this._container.destroy(),this._target=null,this._lipMaskIns&&this._lipMaskIns.destroy()},v([(0,h.M)("Makeup"),k("design:type",Function),k("design:paramtypes",["function"==typeof(t=void 0!==a.W2&&a.W2)?t:Object]),k("design:returntype",void 0)],e.prototype,"_removeMakeup",null),v([(0,h.M)("Makeup"),k("design:type",Function),k("design:paramtypes",[]),k("design:returntype",void 0)],e.prototype,"destroy",null),e}(),C=n(3125),E=n(401),j=function(e,t,n,i){var r,o=arguments.length,s=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,i);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(s=(o<3?r(s):o>3?r(t,n,s):r(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},I=function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},O=function(){function e(e,t,n,i,r,o,s,c){this._container=new a.W2,this._name=e,this._src=t,this._target=i,this._config=n,this._jsonIntensity=n.intensity,this._landmarks=r,this._options=o,this._key=s,this._angles=c}return Object.defineProperty(e.prototype,"parentIntensity",{get:function(){return this._parentIntensity},set:function(e){this._parentIntensity=e,this._sticker&&(this._sticker.alpha=this._jsonIntensity*e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"faceLandMarks",{set:function(e){this._landmarks=e,this._sticker&&this.setStickerProps()},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"angles",{set:function(e){this._angles=e,this._sticker&&this.setStickerProps()},enumerable:!1,configurable:!0}),e.prototype.getCircle=function(e){void 0===e&&(e=5);var t=new a.TC;return t.beginFill(16711680),t.drawCircle(0,0,e),t.endFill(),t},e.prototype.getCircle2=function(e){void 0===e&&(e=5);var t=new a.TC;return t.beginFill(255),t.drawCircle(0,0,e),t.endFill(),t},e.prototype.getDisplay=function(){return this._container},e.prototype.load=function(){var e,t=this;if(this.checkAnimated()){var n=[];this._src.forEach((function(e){var i;i=e.indexOf(".json")>-1?e:"".concat(t._key,"|").concat(JSON.parse(e).meta.image);var r=o.iV[i].textures,s=Object.keys(r).map((function(e){return r[e]}));n=n.concat(s)})),(e=new u.Kg(n)).animationSpeed=(this._config.fps||30)/60,e.play()}else{var i=this._src[0],r=a.P6.kN[i];e=new u.jy(r)}this._config.blend&&(e.blendMode_1=this._config.blend);this._config.wxAnchorOffset;e.width=this._config.width,e.height=this._config.height;var s=[.5,.5];this._config.anchor&&(s=this._config.anchor),e.anchor.set(s[0],s[1]),e.alpha=this._jsonIntensity*this.parentIntensity,this._sticker=e,this._container.addChild(this._sticker),this._container.convertTo3d(),this.setStickerProps()},e.prototype.setStickerProps=function(){var e=this._config,t=this._landmarks,n=E.Jp.map((function(e){return t[e]})),i=(0,m.Sp)(n[0],n[1]),r=e.wxAnchorArea,o=(e.wxAnchorOffset,e.wxWeights),s=i/E.jw,a=r.map((function(e){var n=t[e];return{x:n.x,y:n.y,z:0}}));this._container.scale.set(s);var c={x:a[0].x*o[0]+a[1].x*o[1]+a[2].x*o[2],y:a[0].y*o[0]+a[1].y*o[1]+a[2].y*o[2]};this._container.position.x=c.x,this._container.position.y=c.y,this._angles&&(this._container.euler.z=this._angles.roll,this._container.euler.y=this._angles.yaw,this._container.euler.x=this._angles.pitch)},e.prototype.checkAnimated=function(){if(this._src instanceof Array&&this._src.length>1)return!0;try{return JSON.parse(this._src[0]),!0}catch(e){return"json"===this._src[0].split(".").pop()}},e.prototype.tick=function(){},e.prototype.apply=function(){},e.prototype.remove=function(){},e.prototype.destroy=function(){this._sticker.destroy(),this._container.destroy(),this._sticker=null,this._target=null},j([(0,h.M)("StickerLayer"),I("design:type",Function),I("design:paramtypes",[]),I("design:returntype",Boolean)],e.prototype,"checkAnimated",null),j([(0,h.M)("StickerLayer"),I("design:type",Function),I("design:paramtypes",[]),I("design:returntype",void 0)],e.prototype,"destroy",null),e}(),R=function(){function e(e,t,n,i,r,o,s){void 0===s&&(s=1);var a=this;this._stickers=[],this._visible=!0,this._parentIntensity=1,this._target=n,this._options=r,this._landmarks=i;var c=new C.LE;c.setPlanes(400,10,1e4,!0),this._camera=c,this._stickers=t.map((function(t){var s=new O(t.name,t.src,t,n,i,r,e,o);return s.parentIntensity=a.parentIntensity,s.load(),a._camera.addChild(s.getDisplay()),s}))}return Object.defineProperty(e.prototype,"parentIntensity",{get:function(){return this._parentIntensity},set:function(e){this._stickers.forEach((function(t){t.parentIntensity=e})),this._parentIntensity=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"faceLandMarks",{set:function(e){this._stickers.forEach((function(t){t.faceLandMarks=e}))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"angles",{set:function(e){this._stickers.forEach((function(t){t.angles=e}))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"visible",{get:function(){return this._visible},set:function(e){this._target&&e!==this._visible&&(this._visible=e,e?this.apply():this.remove())},enumerable:!1,configurable:!0}),e.prototype.tick=function(){this._stickers.forEach((function(e){return e.tick()}))},e.prototype.apply=function(){this._target.addChild(this._camera)},e.prototype.remove=function(){this._target.removeChild(this._camera)},e.prototype.destroy=function(){this.remove(),this._stickers.forEach((function(e){return e.destroy()})),this._camera.destroy(),this._stickers=[]},e}(),F=n(6878),L=n(6879),V=n(201),A=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}(),N=function(e,t,n,i){var r,o=arguments.length,s=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,i);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(s=(o<3?r(s):o>3?r(t,n,s):r(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},U=function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},D=function(e,t,n,i){return new(n||(n=Promise))((function(r,o){function s(e){try{c(i.next(e))}catch(e){o(e)}}function a(e){try{c(i.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,a)}c((i=i.apply(e,t||[])).next())}))},G=function(e,t){var n,i,r,o,s={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,i&&(r=2&o[0]?i.return:o[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[2&o[0],r.value]),o[0]){case 0:case 1:r=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,i=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(r=s.trys,(r=r.length>0&&r[r.length-1])||6!==o[0]&&2!==o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]<r[3])){s.label=o[1];break}if(6===o[0]&&s.label<r[1]){s.label=r[1],r=o;break}if(r&&s.label<r[2]){s.label=r[2],s.ops.push(o);break}r[2]&&s.ops.pop(),s.trys.pop();continue}o=t.call(e,s)}catch(e){o=[6,e],i=0}finally{n=r=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,a])}}},H=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],i=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&i>=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},B=(0,g.jl)("Effect"),z=function(){function e(e,t,n,i,r,o,s,a,c,u,h){this.type="face",this._filters=[],this._destroyed=!1,this._visible=!0,this._intensity=1,this._filterIntensity=1,this.localSpriteSheets={},this._filtersActived=!0,this._target=t,this._stickerTarget=n,this._url=e,this._key=e,this._options=r,this.mesh=o,this.lipmesh=a,this.faceLandMarks=s,c&&(this.angles=c),void 0!==u&&(this.intensity=u),this._app3d=i,this._canvas=h}var t;return Object.defineProperty(e.prototype,"isPureFilter",{get:function(){var e=this._config;return!!e&&((!e.makeup||!e.makeup.length)&&((!e.sticker||!e.sticker.length)&&((!e.sticker3d||!e.sticker3d.length)&&(!e.beautify||!Object.keys(e.beautify).find((function(t){return!!e.beautify[t]}))))))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"filterActived",{get:function(){return this._filtersActived},set:function(e){e!==this._filtersActived&&(this._filterTarget&&(e?this._applyFilter(this._filterTarget):this._removeFilter(this._filterTarget)),this._filtersActived=e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"url",{get:function(){return this._url},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"app3d",{get:function(){return this._app3d},set:function(e){this._app3d=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"intensity",{get:function(){return this._intensity},set:function(e){e>1&&(F.Nd.trigger("error",{message:r.Z.t("0015"),code:L.U.SET_INTENSITY_ERROR}),e=1),null!=e&&(this._makeup&&(this._makeup.parentIntensity=e),this._sticker&&(this._sticker.parentIntensity=e),this._intensity=e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"filterIntensity",{get:function(){return this._filterIntensity},set:function(e){null!=e&&(this._filters&&this._filters.forEach((function(t){t.uniforms.parentIntensity=e})),this._filterIntensity=e)},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"visible",{get:function(){return this._visible},set:function(e){this._destroyed||(this._visible=e,this._makeup&&(this._makeup.visible=e),this._sticker&&(this._sticker.visible=e))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"mesh",{set:function(e){this._destroyed||(this._meshVertex=e,this._makeup&&(this._makeup.mesh=e))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"lipmesh",{set:function(e){this._destroyed||(this._lipVertex=e,this._makeup&&(this._makeup.lipmesh=e))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"faceLandMarks",{get:function(){return this._faceLandMarks},set:function(e){this._destroyed||(this._faceLandMarks=e,this._makeup&&(this._makeup.faceLandMarks=e),this._sticker&&(this._sticker.faceLandMarks=e))},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"angles",{set:function(e){this._angles=e,this._sticker&&(this._sticker.angles=e)},enumerable:!1,configurable:!0}),e.prototype.download=function(){return D(this,void 0,Promise,(function(){var e;return G(this,(function(t){switch(t.label){case 0:return[4,this._getLoader()];case 1:return[4,t.sent().preload(this._url)];case 2:return t.sent(),[4,this._getConfig()];case 3:return e=t.sent(),g.D4.info("download:",this._url,e),[2,e]}}))}))},e.prototype.load=function(){return D(this,void 0,Promise,(function(){var e,t,n,i,r,o;return G(this,(function(s){switch(s.label){case 0:return[4,this.download()];case 1:return e=s.sent(),t=e.filter,n=e.makeup,i=e.beautify,r=e.sticker,o=e.sticker3d,[4,this._loadImages(e)];case 2:return s.sent(),this.loadFilter(t),[4,this.setMakeup(n)];case 3:return s.sent(),r?[4,this.loadStickers(r)]:[3,5];case 4:s.sent(),s.label=5;case 5:return[4,this.load3d(o)];case 6:return s.sent(),this.sticker3d=o,[4,this._getLoader()];case 7:return s.sent().removeFromCache(this._url),[2,i]}}))}))},e.prototype._getLoader=function(){return D(this,void 0,void 0,(function(){return G(this,(function(e){switch(e.label){case 0:return this._loader?[3,2]:(this._loader=new o.pF,[4,this._loader.init()]);case 1:e.sent(),e.label=2;case 2:return[2,this._loader]}}))}))},e.prototype._getConfig=function(){return D(this,void 0,void 0,(function(){var e;return G(this,(function(t){switch(t.label){case 0:return this._config?[3,3]:[4,this._getLoader()];case 1:return[4,(e=t.sent()).preload(this._url)];case 2:t.sent(),this._config=e.readJSON("content.json",this._key),t.label=3;case 3:return[2,this._config]}}))}))},e.prototype.hasEyeMakeup=function(){return D(this,void 0,Promise,(function(){var e,t,n,i,r,o,s,a;return G(this,(function(c){switch(c.label){case 0:return[4,this._getConfig()];case 1:e=c.sent(),t=e.makeup,n=!1;try{for(i=H(t),r=i.next();!r.done;r=i.next())if("iris"===(o=r.value).type||"eyes"===o.type){n=!0;break}}catch(e){s={error:e}}finally{try{r&&!r.done&&(a=i.return)&&a.call(i)}finally{if(s)throw s.error}}return[2,n]}}))}))},e.prototype.needDetection=function(){return D(this,void 0,Promise,(function(){var e,t,n,i;return G(this,(function(r){switch(r.label){case 0:return[4,this._getConfig()];case 1:return e=r.sent(),t=e.makeup,n=e.sticker,i=e.sticker3d,[2,t&&t.length||n&&n.length||i&&i.length]}}))}))},e.prototype.hasFilter=function(){return D(this,void 0,Promise,(function(){var e,t;return G(this,(function(n){switch(n.label){case 0:return[4,this._getConfig()];case 1:return e=n.sent(),[2,!(!(t=e.filter)||!t.length)]}}))}))},e.prototype.loadStickers=function(e){return D(this,void 0,Promise,(function(){var t;return G(this,(function(n){return e.length?((t=new R(this._key,e,this._stickerTarget,this.faceLandMarks,this._options,this._angles)).parentIntensity=this.intensity,this._sticker=t,[2]):[2,Promise.resolve()]}))}))},e.prototype.loadSticker3d=function(e){return void 0===e&&(e=[]),D(this,void 0,Promise,(function(){return G(this,(function(e){return[2]}))}))},e.prototype.load3d=function(e){return D(this,void 0,void 0,(function(){return G(this,(function(e){return[2]}))}))},e.prototype.initThreeApp=function(){return D(this,void 0,void 0,(function(){return G(this,(function(e){return[2]}))}))},e.prototype.apply3d=function(){},e.prototype.removeForConsole=function(){},e.prototype.destroyForConosle=function(){},e.prototype.setMakeup=function(e){return e.length?(this._makeup=new P(this._key,e,this._options,this._meshVertex,this.faceLandMarks,this._lipVertex,this.renderer,this.intensity),this._makeup.load()):Promise.resolve()},e.prototype.apply=function(e){this._destroyed||this._applyed||(this.filterActived&&this._applyFilter(e.filterTarget),this._filters.length&&e.filterCallback&&e.filterCallback(),this._filterTarget=e.filterTarget,this._makeup&&this._makeup.apply(this._target),this._sticker&&this._sticker.apply(),this.apply3d(),this._applyed=!0)},e.prototype.getUrl=function(){return this._url},e.prototype.remove=function(){this._makeup&&this._makeup.remove(),this._sticker&&this._sticker.remove(),this.removeForConsole(),this._removeFilter(this._filterTarget),this._applyed=!1},e.prototype.tick=function(){this._sticker&&this._sticker.tick()},e.prototype.tickMesh=function(){this._makeup&&this._makeup.renderMesh()},e.prototype.destroy=function(){this._destroyed=!0,this.remove(),this._makeup&&(this._makeup.destroy(),this._makeup=null),this._sticker&&(this._sticker.destroy(),this._sticker=null),this.destroyForConosle(),this._filters=[],this.clearTexture()},e.prototype.loadFilter=function(e){var t=this;this._destroyed||e&&e.length&&e.forEach((function(e){var n=t._createFilterSync(e.src,e.intensity,t.filterIntensity);t._filters.push(n)}))},e.prototype._applyFilter=function(e){e.filters||(e.filters=[]),e.filters=this._filters.concat(e.filters)},e.prototype._removeFilter=function(e){e&&e.filters&&e.filters.length&&this._filters.forEach((function(t){var n=e.filters.findIndex((function(e){return e===t}));n>-1&&e.filters.splice(n,1)}))},e.prototype._createFilterSync=function(e,t,n){var i="default"===this._key?e:"".concat(this._key,"|").concat(e),r=a.P6.kN[i];return r.baseTexture.scaleMode=a.aH.LINEAR,r.baseTexture.mipmap=a.KI.OFF,new s.f("lut",this._options,{uniforms:{lut:r,intensity:t,parentIntensity:n}})},e.prototype.clearTexture=function(){for(var e in a.P6.kN)if(e.indexOf(this._key)>-1){var t=a.P6.kN[e];a.xE.removeFromCache(t),t.destroy(!0)}for(var e in this.localSpriteSheets)o.iV[e]&&o.iV[e]instanceof a.c2&&(o.iV[e].destroy(),delete o.iV[e])},e.prototype._loadImages=function(e){var t,n,i=this,r=(e.filter||[]).concat(e.makeup||[]).concat(e.sticker||[]),s=this._loader.getIndeLoader(),c={};this.localSpriteSheets=c;try{for(var u=H(r),h=u.next();!h.done;h=u.next()){var l=h.value;if(l.src instanceof Array)l.src.forEach((function(e,t){var n=i.checkSpriteSheetJSON(e);if(n){var r=n.meta.image,o="".concat(i._key,"|").concat(r);if(a.P6.kN[o])return;if(0===r.indexOf("blob:")){var u=a.xE.from(r);a.xE.addToCache(u,o)}else s.add(o,r);n.meta.image="",c[o]=n}else{if(a.P6.kN[e])return;if(s.resources[e])return;s.add(e,e)}}));else{var p="".concat(this._key,"|").concat(l.src);if(a.P6.kN[p])continue;if(0===l.src.indexOf("blob:")){var f=a.xE.from(l.src);a.xE.addToCache(f,p)}else s.add(p,l.src)}}}catch(e){t={error:e}}finally{try{h&&!h.done&&(n=u.return)&&n.call(u)}finally{if(t)throw t.error}}return new Promise((function(e){s.load((function(t,n){return D(i,void 0,void 0,(function(){var t,i,r,s,u;return G(this,(function(h){switch(h.label){case 0:for(r in t=function(e){var t;return G(this,(function(n){switch(n.label){case 0:return o.iV[e]?[2,"continue"]:c[e]?(t=new a.c2(a.P6.kN[e],c[e],"@".concat((0,V.u)(),"x")),[4,new Promise((function(n){t.parse((function(){o.iV[e]=t,n()}))}))]):[3,2];case 1:n.sent(),n.label=2;case 2:return[2]}}))},i=[],a.P6.kN)i.push(r);s=0,h.label=1;case 1:return s<i.length?(u=i[s],[5,t(u)]):[3,4];case 2:h.sent(),h.label=3;case 3:return s++,[3,1];case 4:for(u in n)o.iV[u]||c[u]||(o.iV[u]=n[u]);return e(),[2]}}))}))}))}))},e.prototype.checkSpriteSheetJSON=function(e){try{return JSON.parse(e)}catch(e){return null}},N([(0,h.M)("Effect"),U("design:type",Function),U("design:paramtypes",[]),U("design:returntype",void 0)],e.prototype,"remove",null),N([(0,h.M)("Effect"),U("design:type",Function),U("design:paramtypes",[]),U("design:returntype",void 0)],e.prototype,"destroy",null),N([(0,h.M)("Effect"),U("design:type",Function),U("design:paramtypes",["function"==typeof(t=void 0!==a.W2&&a.W2)?t:Object]),U("design:returntype",void 0)],e.prototype,"_removeFilter",null),e}(),J=function(e){function t(t,n,i,r,o,s,a,c){var u=e.call(this,"default",n,i,r,o,s,a,c)||this;return u._json=t,u._app3d=r,u}return A(t,e),t.prototype.load=function(){return D(this,void 0,Promise,(function(){var e,t,n,i,r,o;return G(this,(function(s){switch(s.label){case 0:return e=this._json,t=e.filter,n=e.makeup,i=e.beautify,r=e.sticker,o=e.sticker3d,[4,this._loadImages(e)];case 1:return s.sent(),this.loadFilter(t),[4,this.setMakeup(n)];case 2:return s.sent(),r?[4,this.loadStickers(r)]:[3,4];case 3:s.sent(),s.label=4;case 4:return o?this._app3d?[3,6]:[4,this.initThreeApp()]:[3,8];case 5:s.sent(),s.label=6;case 6:return[4,this.loadSticker3d(o||[])];case 7:s.sent(),s.label=8;case 8:return[2,i]}}))}))},t.prototype.loadImage=function(){return D(this,void 0,void 0,(function(){return G(this,(function(e){return[2]}))}))},t.prototype._loadImages=function(e){var t,n,i=this,r=new a.aN,s=(e.filter||[]).concat(e.makeup||[]).concat(e.sticker||[]),c={},u=function(e){if(e.src instanceof Array)e.src.forEach((function(t,n){var o=i.checkSpriteSheetJSON(t);if(o){var s=o.meta.image,u="".concat(i._key,"|").concat(s);if(a.P6.kN[u])return;if(e.objectSrc&&e.objectSrc.length){var h=a.xE.from(e.objectSrc[n]);a.xE.addToCache(h,u)}else if(0===s.indexOf("blob:")){h=a.xE.from(s);a.xE.addToCache(h,u)}else r.add(u,s);o.meta.image="",c[u]=o}else{if(a.P6.kN[t])return;if(r.resources[t])return;if(e.objectSrc&&e.objectSrc.length){h=a.xE.from(e.objectSrc[n],{resolution:(0,V.u)()});a.xE.addToCache(h,t)}else r.add(t,t)}}));else{if(a.P6.kN[e.src])return"continue";if(r.resources[e.src])return B.info("already loaded file",e.src),"continue";if(e.objectSrc){B.info("use imagebitmap to create texture");var t=a.xE.from(e.objectSrc);a.xE.addToCache(t,e.src)}else if(0===e.src.indexOf("blob:")){t=a.xE.from(e.src);B.info("JSONEffect blob texture",t),a.xE.addToCache(t,e.src)}else r.add(e.src)}};try{for(var h=H(s),l=h.next();!l.done;l=h.next()){u(l.value)}}catch(e){t={error:e}}finally{try{l&&!l.done&&(n=h.return)&&n.call(h)}finally{if(t)throw t.error}}return new Promise((function(e){return D(i,void 0,void 0,(function(){var t=this;return G(this,(function(n){return r.load((function(n,i){return D(t,void 0,void 0,(function(){var t,n,r,s,u;return G(this,(function(h){switch(h.label){case 0:for(r in t=function(e){var t;return G(this,(function(n){switch(n.label){case 0:return o.iV[e]?[2,"continue"]:c[e]?(t=new a.c2(a.P6.kN[e],c[e],"@".concat((0,V.u)(),"x")),[4,new Promise((function(n){t.parse((function(){o.iV[e]=t,n()}))}))]):[3,2];case 1:n.sent(),n.label=2;case 2:return[2]}}))},n=[],a.P6.kN)n.push(r);s=0,h.label=1;case 1:return s<n.length?(u=n[s],[5,t(u)]):[3,4];case 2:h.sent(),h.label=3;case 3:return s++,[3,1];case 4:for(u in i)o.iV[u]||c[u]||(o.iV[u]=i[u]);return e(),[2]}}))}))})),[2]}))}))}))},t.prototype.loadSticker3d=function(e){return D(this,void 0,Promise,(function(){return G(this,(function(e){return[2]}))}))},t}(z),W=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}(),K=function(e,t,n,i){var r,o=arguments.length,s=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,i);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(s=(o<3?r(s):o>3?r(t,n,s):r(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},Y=function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},q=function(e,t,n,i){return new(n||(n=Promise))((function(r,o){function s(e){try{c(i.next(e))}catch(e){o(e)}}function a(e){try{c(i.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,a)}c((i=i.apply(e,t||[])).next())}))},X=function(e,t){var n,i,r,o,s={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,i&&(r=2&o[0]?i.return:o[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[2&o[0],r.value]),o[0]){case 0:case 1:r=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,i=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(r=s.trys,(r=r.length>0&&r[r.length-1])||6!==o[0]&&2!==o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]<r[3])){s.label=o[1];break}if(6===o[0]&&s.label<r[1]){s.label=r[1],r=o;break}if(r&&s.label<r[2]){s.label=r[2],s.ops.push(o);break}r[2]&&s.ops.pop(),s.trys.pop();continue}o=t.call(e,s)}catch(e){o=[6,e],i=0}finally{n=r=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,a])}}},Z=((0,g.jl)("Effect"),function(){function e(e,t,n,i){this.type="hand",this._destroyed=!1,this._visible=!0,this._intensity=1,this.localSpriteSheets={},this._url=e,this._key=e,this._app3d=t,this._canvas=i,this._options=n}return Object.defineProperty(e.prototype,"url",{get:function(){return this._url},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"app3d",{get:function(){return this._app3d},set:function(e){this._app3d=e},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"intensity",{get:function(){return this._intensity},enumerable:!1,configurable:!0}),Object.defineProperty(e.prototype,"visible",{get:function(){return this._visible},set:function(e){this._destroyed||(this._visible=e)},enumerable:!1,configurable:!0}),e.prototype.download=function(){return q(this,void 0,Promise,(function(){var e;return X(this,(function(t){switch(t.label){case 0:return[4,this._getLoader()];case 1:return[4,t.sent().preload(this._url)];case 2:return t.sent(),[4,this._getConfig()];case 3:return e=t.sent(),g.D4.info("download:",this._url,e),[2,e]}}))}))},e.prototype.load=function(){return q(this,void 0,Promise,(function(){var e,t;return X(this,(function(n){switch(n.label){case 0:return[4,this.download()];case 1:return e=n.sent(),t=e.hand,[4,this.load3d(t||[])];case 2:return n.sent(),[4,this._getLoader()];case 3:return n.sent().removeFromCache(this._url),[2,null]}}))}))},e.prototype._getLoader=function(){return q(this,void 0,void 0,(function(){return X(this,(function(e){switch(e.label){case 0:return this._loader?[3,2]:(this._loader=new o.pF,[4,this._loader.init()]);case 1:e.sent(),e.label=2;case 2:return[2,this._loader]}}))}))},e.prototype._getConfig=function(){return q(this,void 0,void 0,(function(){var e;return X(this,(function(t){switch(t.label){case 0:return this._config?[3,3]:[4,this._getLoader()];case 1:return[4,(e=t.sent()).preload(this._url)];case 2:t.sent(),this._config=e.readJSON("content.json",this._key),t.label=3;case 3:return[2,this._config]}}))}))},e.prototype.load3d=function(e){return q(this,void 0,void 0,(function(){return X(this,(function(e){return[2]}))}))},e.prototype.initThreeApp=function(){return q(this,void 0,void 0,(function(){return X(this,(function(e){return[2]}))}))},e.prototype.apply3d=function(){},e.prototype.removeForConsole=function(){},e.prototype.destroyForConosle=function(){},e.prototype.apply=function(){this._destroyed||this._applyed||(this.apply3d(),this._applyed=!0)},e.prototype.getUrl=function(){return this._url},e.prototype.remove=function(){this.removeForConsole(),this._applyed=!1},e.prototype.tick=function(){},e.prototype.tickMesh=function(){},e.prototype.destroy=function(){this._destroyed=!0,this.remove(),this.destroyForConosle(),this.clearTexture()},e.prototype.clearTexture=function(){for(var e in a.P6.kN)if(e.indexOf(this._key)>-1){var t=a.P6.kN[e];a.xE.removeFromCache(t),t.destroy(!0)}for(var e in this.localSpriteSheets)o.iV[e]&&o.iV[e]instanceof a.c2&&(o.iV[e].destroy(),delete o.iV[e])},e.prototype.checkSpriteSheetJSON=function(e){try{return JSON.parse(e)}catch(e){return null}},K([(0,h.M)("Effect"),Y("design:type",Function),Y("design:paramtypes",[]),Y("design:returntype",void 0)],e.prototype,"remove",null),K([(0,h.M)("Effect"),Y("design:type",Function),Y("design:paramtypes",[]),Y("design:returntype",void 0)],e.prototype,"destroy",null),e}()),$=function(e){function t(t,n,i,r){var o=e.call(this,"default",n,i,r)||this;return o._json=t,o._app3d=n,o}return W(t,e),t.prototype.load=function(){return q(this,void 0,Promise,(function(){var e,t;return X(this,(function(n){switch(n.label){case 0:return e=this._json,(t=e.hand)?this._app3d?[3,2]:[4,this.initThreeApp()]:[3,4];case 1:n.sent(),n.label=2;case 2:return[4,this.loadHand3d(t||[])];case 3:n.sent(),n.label=4;case 4:return[2,null]}}))}))},t.prototype.loadImage=function(){return q(this,void 0,void 0,(function(){return X(this,(function(e){return[2]}))}))},t.prototype.loadSticker3d=function(e){return q(this,void 0,Promise,(function(){return X(this,(function(e){return[2]}))}))},t.prototype.loadHand3d=function(e){return q(this,void 0,Promise,(function(){return X(this,(function(e){return[2]}))}))},t}(Z),Q=n(5156),ee=n(7959),te=n(6309),ne=n(1077),ie=function(){var e=function(t,n){return e=Object.setPrototypeOf||{__proto__:[]}instanceof Array&&function(e,t){e.__proto__=t}||function(e,t){for(var n in t)Object.prototype.hasOwnProperty.call(t,n)&&(e[n]=t[n])},e(t,n)};return function(t,n){if("function"!=typeof n&&null!==n)throw new TypeError("Class extends value "+String(n)+" is not a constructor or null");function i(){this.constructor=t}e(t,n),t.prototype=null===n?Object.create(n):(i.prototype=n.prototype,new i)}}(),re=function(e,t,n,i){var r,o=arguments.length,s=o<3?t:null===i?i=Object.getOwnPropertyDescriptor(t,n):i;if("object"==typeof Reflect&&"function"==typeof Reflect.decorate)s=Reflect.decorate(e,t,n,i);else for(var a=e.length-1;a>=0;a--)(r=e[a])&&(s=(o<3?r(s):o>3?r(t,n,s):r(t,n))||s);return o>3&&s&&Object.defineProperty(t,n,s),s},oe=function(e,t){if("object"==typeof Reflect&&"function"==typeof Reflect.metadata)return Reflect.metadata(e,t)},se=function(e,t,n,i){return new(n||(n=Promise))((function(r,o){function s(e){try{c(i.next(e))}catch(e){o(e)}}function a(e){try{c(i.throw(e))}catch(e){o(e)}}function c(e){var t;e.done?r(e.value):(t=e.value,t instanceof n?t:new n((function(e){e(t)}))).then(s,a)}c((i=i.apply(e,t||[])).next())}))},ae=function(e,t){var n,i,r,o,s={label:0,sent:function(){if(1&r[0])throw r[1];return r[1]},trys:[],ops:[]};return o={next:a(0),throw:a(1),return:a(2)},"function"==typeof Symbol&&(o[Symbol.iterator]=function(){return this}),o;function a(o){return function(a){return function(o){if(n)throw new TypeError("Generator is already executing.");for(;s;)try{if(n=1,i&&(r=2&o[0]?i.return:o[0]?i.throw||((r=i.return)&&r.call(i),0):i.next)&&!(r=r.call(i,o[1])).done)return r;switch(i=0,r&&(o=[2&o[0],r.value]),o[0]){case 0:case 1:r=o;break;case 4:return s.label++,{value:o[1],done:!1};case 5:s.label++,i=o[1],o=[0];continue;case 7:o=s.ops.pop(),s.trys.pop();continue;default:if(!(r=s.trys,(r=r.length>0&&r[r.length-1])||6!==o[0]&&2!==o[0])){s=0;continue}if(3===o[0]&&(!r||o[1]>r[0]&&o[1]<r[3])){s.label=o[1];break}if(6===o[0]&&s.label<r[1]){s.label=r[1],r=o;break}if(r&&s.label<r[2]){s.label=r[2],s.ops.push(o);break}r[2]&&s.ops.pop(),s.trys.pop();continue}o=t.call(e,s)}catch(e){o=[6,e],i=0}finally{n=r=0}if(5&o[0])throw o[1];return{value:o[0]?o[1]:void 0,done:!0}}([o,a])}}},ce=function(e){var t="function"==typeof Symbol&&Symbol.iterator,n=t&&e[t],i=0;if(n)return n.call(e);if(e&&"number"==typeof e.length)return{next:function(){return e&&i>=e.length&&(e=void 0),{value:e&&e[i++],done:!e}}};throw new TypeError(t?"Object is not iterable.":"Symbol.iterator is not defined.")},ue=(0,g.jl)("Renderer"),he=function(){};var le=function(e){function t(t){var n=e.call(this,t)||this;return n._setup=!1,n._effects=[],n._debug=!0,n._destroyed=!1,n._isVR=!1,n._meshVertexTimer=0,n.lib3dLoaded=!1,n.libHand3dLoaded=!1,ue.info("[@#$] AR Renderer Constructed",location),n._debug=!1,t.output?n._canvas=new wx.window.Canvas(t.output):n._canvas=new wx.window.Canvas(wx.createOffscreenCanvas({type:"webgl",width:t.width,height:t.height})),n._stage=new a.W2,n._options=t,a.Xd.RESOLUTION=(0,V.u)(),a.Xd.FILTER_RESOLUTION=(0,V.u)(),n._renderer=new a.Th({view:n._canvas,width:t.width,height:t.height,useContextAlpha:!1,preserveDrawingBuffer:!1,antialias:!1}),n.setRenderer(),n.initRenderContext(t),n.handleLoading(),n.setup(),n}return ie(t,e),Object.defineProperty(t.prototype,"mirror",{set:function(e){},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"backGroundVR",{set:function(e){if(e){this._backgroundVR=new a.jy(a.xE.from(e));var t=this._backgroundVR,n=t.width,i=t.height,r=Math.max(this._options.width/n,this._options.height/i);this._backgroundVR.width*=r,this._backgroundVR.height*=r}else this._backgroundVR=null},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"options",{set:function(e){var t=e.width,n=e.height;this._canvas.width=t,this._canvas.height=n,this._renderer&&this.resize(t,n),this._baseSprite&&(this._baseSprite.width=t,this._baseSprite.height=n,this._baseSprite.position.set(t/2,n/2),this._baseSprite.anchor.set(.5,.5)),this._baseRenderTexture.resize(t,n),this._makeupRenderTexture.resize(t,n),this._options=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"app3d",{get:function(){return this._app3d},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"avatar3d",{get:function(){return this._avatar3d},enumerable:!1,configurable:!0}),t.prototype.initRenderContext=function(e){this._baseContainer=new a.W2,this._makeupContainer=new a.W2,this._finalContainer=new a.W2,this._baseRenderTexture=a.TI.create({width:e.width,height:e.height}),this._makeupRenderTexture=a.TI.create({width:e.width,height:e.height}),this._makeupContainer.addChild(new a.jy(this._baseRenderTexture)),he.baseTexture=this._baseRenderTexture,this._finalContainer.addChild(new a.jy(this._makeupRenderTexture)),this._stage.addChild(this._finalContainer),this._target=this._finalContainer},t.prototype.loadLib3d=function(){return se(this,void 0,Promise,(function(){var e;return ae(this,(function(t){switch(t.label){case 0:return e=new te.e({}),ue.info("loader init"),[4,e.init()];case 1:return t.sent(),ue.info("loader init done"),this._options.plugin3d&&this._options.plugin3d(z,J,e,wx.window),[2]}}))}))},t.prototype.loadHand3d=function(){return se(this,void 0,Promise,(function(){var e;return ae(this,(function(t){switch(t.label){case 0:return e=new te.e({}),ue.info("+++++loader init"),[4,e.init()];case 1:return t.sent(),ue.info("+++++loader init done"),this._options.plugin3d&&this._options.pluginHand(Z,$,e,wx.window),[2]}}))}))},t.prototype.setup=function(){return se(this,void 0,void 0,(function(){return ae(this,(function(e){switch(e.label){case 0:return this._setup?[2]:(this._config=new c.M,[4,this._config.load()]);case 1:return e.sent(),this._setup=!0,[2]}}))}))},Object.defineProperty(t.prototype,"meshVertex",{get:function(){return this._meshVertex},set:function(e){this._meshVertex=e},enumerable:!1,configurable:!0}),Object.defineProperty(t.prototype,"mirrorFilter",{get:function(){return this._mirrorFilter||(this._mirrorFilter=new s.f("mirror",{width:l.t.instance.options.width,height:l.t.instance.options.height})),this._mirrorFilter},enumerable:!1,configurable:!0}),t.prototype.switchMode=function(e){e!==this._mode3d&&("Sticker"===e&&this.setAvatar(null),this._mode3d=e)},t.prototype.logTime=function(e){var t=+new Date;ue.info("".concat(e," time:").concat(t-this.currentTime)),this.currentTime=t},t.prototype.tick=function(t,n){var i=t.landmarks,r=t.meshVertex,o=t.lipVertex,s=t.image,c=t.angles,u=(t.backgroundType,t.background,t.segmentation,t.blendshapes,t.isLivePusher);t.hair;if(!this._destroyed)if(this._renderer)if(this._stage)if(this._setup){this.currentTime=+new Date;try{this._renderer.reset()}catch(e){}if(this._isVR)try{this._renderer.render(this._backgroundVR)}catch(e){}else{if(u)if(this._baseSprite)this._baseSprite.texture.update();else{d=a.xE.from(s);this._baseSprite=new a.jy(d),this._baseSprite.anchor.set(.5,.5),this._baseSprite.position.set(this._options.width/2,this._options.height/2),this._baseSprite.scale.set(1,-1),this._baseContainer.addChild(this._baseSprite)}else{var h=s,l=h.width,p=h.height,f=h.data;if(this._baseSprite){if(this._baseSprite.texture.width===l&&this._baseSprite.texture.height===p)this._baseSprite.texture.baseTexture.resource.data=new Uint8Array(f),this._baseSprite.texture.update();else this._baseSprite.texture.destroy(!0),this._baseSprite.texture=a.xE.fromBuffer(new Uint8Array(f),l,p)}else{var d=a.xE.fromBuffer(new Uint8Array(f),l,p);this._baseSprite=new a.jy(d),this._baseSprite.anchor.set(.5,.5),this._baseSprite.position.set(this._options.width/2,this._options.height/2);var y=Math.max(this._options.width/l,this._options.height/p);this._baseSprite.scale.set(y),this._baseContainer.addChild(this._baseSprite)}}(ee.s.checkEnabled("beautify")||ee.s.checkEnabled("segmentation")||ee.s.checkEnabled("hair"))&&(e.prototype.setMesh.call(this,r),e.prototype.setReshapeMarks.call(this,i),i&&i.length?(this._faceLandmarks=i,this._angles=c,this.meshVertex=r,this.lipVertex=o,this._effects.forEach((function(e){e.visible||(e.visible=!0),e.lipmesh=o,e.mesh=r,e.angles=c,e.faceLandMarks=i,e.tick()})),"Sticker"===this._mode3d&&this._app3d&&this._app3d.loaded&&(this._app3d.facelandmarks=i,this._app3d.angles=c)):this.handleNoFace()),this._render()}}else g.b_.info("_renderer waiting for setup");else g.b_.info("_renderer waiting for stage");else g.b_.info("_renderer waiting for renderer")},t.prototype.handleNoFace=function(){this._effects.forEach((function(e){return e.visible=!1})),this._effects.forEach((function(e){e.tickMesh()}));new Date;"AR"===this._mode3d||"Sticker"===this._mode3d&&this._app3d&&this._app3d.loaded&&(this._app3d.facelandmarks=[],this._app3d.angles={})},t.prototype._render=function(){this.renderLayers(),ee.s.checkEnabled("beautify")&&"Sticker"===this._mode3d&&this._app3d&&this._app3d.loaded&&this._app3d.render(),ee.s.checkEnabled("handLandmark")&&this._appHand3d&&this._appHand3d.render()},t.prototype.renderLayers=function(){this._renderer.render(this._baseContainer,{renderTexture:this._baseRenderTexture}),this._renderer.render(this._makeupContainer,{renderTexture:this._makeupRenderTexture}),this._renderer.render(this._stage)},t.prototype.getBaseTexture=function(){return this._baseSprite.texture},t.prototype.removeBackground=function(){this.background&&(this.background.remove(),this.background=null)},t.prototype.applyBackground=function(e){this.background},t.prototype.removeForeground=function(){this.foreground&&this.foreground.parent&&this.foreground.parent.removeChild(this.foreground)},t.prototype.addForeground=function(e,t){var n=l.t.instance.options,i=n.width,r=n.height;this.foreground=new u.jy(a.xE.from(e)),"video"===t&&(this.foreground.blendMode_1=6),this.foreground.width=i,this.foreground.height=r,this._finalContainer.addChild(this.foreground)},t.prototype.debugDraw=function(e){if(!this.points){for(var t=[],n=0;2*n<e.length;n++){var i=this.getCircle(2);t.push(i),this._baseContainer.addChild(i)}this.points=t}for(n=0;2*n<e.length;n++)this.points[n].x=e[2*n],this.points[n].y=e[2*n+1]},t.prototype.debugDraw2=function(e){if(ue.info("debug draw 2",e.length),!this.points){for(var t=[],n=0;n<e.length;n++){var i=this.getCircle(2);t.push(i),this._baseContainer.addChild(i)}this.points=t}for(n=0;n<e.length;n++)this.points[n].x=540*e[n].x,this.points[n].y=540*e[n].y},t.prototype.getPixels=function(){var e=this._options,t=e.width,n=e.height,i=new Uint8Array(t*n*4),r=this._renderer.gl;return r.readPixels(0,0,t,n,r.RGBA,r.UNSIGNED_BYTE,i),{data:i,width:t,height:n}},t.prototype.setEffect=function(e,t,n,i){return se(this,void 0,Promise,(function(){var r,o=this;return ae(this,(function(s){return r=!0,this.latestEffectUrls&&this.latestEffectUrls.length===e.length&&e.every((function(e){return o.latestEffectUrls.indexOf(e)>-1}))&&(r=!1,this.debounceTimer&&(clearTimeout(this.debounceTimer),this.debounceTimer=null)),this.latestEffectUrls=e,[2,new Promise((function(s,a){r?(o.debounceTimer&&(clearTimeout(o.debounceTimer),o.debounceTimer=null),o.debounceTimer=setTimeout((function(){return o._setEffect(e,t,n,i).then((function(e){clearTimeout(o.debounceTimer),o.debounceTimer=null,s(e)}))}),100)):o._setEffect(e,t,n).then((function(e){s(e)}))}))]}))}))},t.prototype._setEffect=function(e,t,n,i){return se(this,void 0,Promise,(function(){var r,s=this;return ae(this,(function(a){return g.b_.time("waiting for AI init..."),ee.s.checkEnabled("beautify")&&!this._meshVertex?[2,new Promise((function(r){clearTimeout(s._meshVertexTimer),s._meshVertexTimer=setInterval((function(){g.b_.info("waiting for AI init..."),s._meshVertex&&(g.b_.info("waiting for AI init...done"),clearTimeout(s._meshVertexTimer),s._setEffect(e,t,n,i).then((function(){r(s._effects)})))}),200)}))]:(g.b_.timeEnd("waiting for AI init..."),r="uid_"+Math.floor(1e8*Math.random()),[2,new Promise((function(a,c){return se(s,void 0,void 0,(function(){var s,c,u,h,l,p,f,d,y,_,b,m,v,k,x,w=this;return ae(this,(function(S){switch(S.label){case 0:for(s=[].concat(this._effects),c=[],u=[],h=[],l=[],p=[],f=[],e.length||(this.filterActivedEffect=null),d=[],y=function(i){var r=s.findIndex((function(t){return t.url===e[i]}));if(r>-1)c.push(s[r]),s[r],u.push(t[i]),h.push(n[i]),s.splice(r,1);else{var a=e[i];f.push(function(e){return se(this,void 0,Promise,(function(){var t,n;return ae(this,(function(i){switch(i.label){case 0:return[4,(t=new o.pF).init()];case 1:return i.sent(),[4,t.preload(e)];case 2:return i.sent(),n=t.readJSON("content.json",e),g.D4.info("download:",e,n),[2,n]}}))}))}(a)),d.push(a)}},_=0;_<e.length;_++)y(_);return[4,Promise.all(f)];case 1:for(b=S.sent(),!1,m=!1,v=0;v<b.length;v++)k=d[v],x=void 0,(x=new z(k,this._makeupContainer,this._finalContainer,this._app3d,this._options,this._meshVertex,this._faceLandmarks,this.lipVertex,this._angles,t[v],this._canvas)).filterIntensity=n[v],b[v].sticker3d&&b[v].sticker3d.length&&(m=!0),x.renderer=this._renderer,l.push(x);return g.b_.time("require 3d lib"),this.lib3dLoaded||!m?[3,3]:i&&!i()?[2]:(ue.info("require 3d lib"),[4,this.loadLib3d()]);case 2:S.sent(),this.lib3dLoaded=!0,S.label=3;case 3:return g.b_.timeEnd("require 3d lib"),g.b_.info("check all new Effects",l,s),l.forEach((function(e){p.push(e.load().then((function(){return w._app3d||"face"!==e.type||(w._app3d=e.app3d),w._appHand3d||"hand"!==e.type||(w._appHand3d=e.app3d),e})).catch((function(e){ue.warn("effect load error",e)})))})),g.b_.time("renderer parse effect"),Promise.all(p).then((function(e){g.b_.timeEnd("renderer parse effect"),g.b_.time("renderer apply effect");for(var t=!1,n=0;n<l.length;n++){var i=l[n];w.latestEffectUrls&&-1===w.latestEffectUrls.indexOf(i.getUrl())&&(i.destroy(),t=!0)}if(t)ue.info(r+"end");else{s.forEach((function(e){e.remove()})),w._effects=c,c.forEach((function(e,t){e.intensity=u[t],e.filterIntensity=h[t]}));for(n=0;n<l.length;n++){i=l[n];w._effects.push(i),i.apply({filterTarget:w._baseSprite,filterCallback:function(){}})}s.forEach((function(e){e.destroy()})),g.b_.timeEnd("renderer apply effect"),a(w._effects)}})),[2]}}))}))}))])}))}))},t.prototype.setEffectJSON=function(e){return se(this,void 0,void 0,(function(){var t,n,i,r,o,s=this;return ae(this,(function(a){switch(a.label){case 0:return n=e.sticker3d,i=e.hand,n&&n.length&&!this.lib3dLoaded?(ue.info("require 3d lib"),[4,this.loadLib3d()]):[3,2];case 1:a.sent(),this.lib3dLoaded=!0,a.label=2;case 2:return i&&i.length&&!this.libHand3dLoaded?(ue.info("require 3d hand lib"),[4,this.loadHand3d()]):[3,4];case 3:a.sent(),this.libHand3dLoaded=!0,a.label=4;case 4:return r=!1,(o=function(){ee.s.checkEnabled("beautify")&&s._meshVertex&&(t&&clearTimeout(t),r=!0,s.getJSONEffectForFace(e)),ee.s.checkEnabled("handLandmark")&&i&&i.length&&(r=!0,s.getJSONEffectForHand(e)),r||(t=setTimeout(o,20))})(),[2]}}))}))},t.prototype.getJSONEffectForHand=function(e){var t=this,n=new $(e,this._appHand3d,this._options,this._canvas);n.renderer=this._renderer,g.b_.info("getJSONEffectForHand"),n.load().then((function(){t._appHand3d||(t._appHand3d=n.app3d),n.apply()}))},t.prototype.getJSONEffectForFace=function(e){var t=this,n=new J(e,this._makeupContainer,this._finalContainer,this._app3d,this._options,this._meshVertex,this._faceLandmarks,this.lipVertex);return n.renderer=this._renderer,n.load().then((function(){t._app3d||(t._app3d=n.app3d);var e=[].concat(t._effects);t._effects=[n],n.apply({filterTarget:t._baseSprite}),e.forEach((function(e){e.destroy()}))})),n},t.prototype.setExclusiveFilter=function(e,t){var n=this;return void 0===t&&(t=1),new Promise((function(i,r){!function(){if(n.exclusiveFilter&&n.exclusiveFilter.getUrl()===e)n.exclusiveFilter.intensity=t,n.exclusiveFilter.filterIntensity=t;else{var r=new z(e,n._makeupContainer,n._finalContainer,n._app3d,n._options,n._meshVertex,n._faceLandmarks,n.lipVertex,n._angles,t);r.filterIntensity=t,r.load().then((function(){n.exclusiveFilter&&n.exclusiveFilter.destroy(),n.exclusiveFilter=r,r.renderer=n._renderer,r.apply({filterTarget:n._baseSprite}),i()}))}}()}))},t.prototype.resize=function(t,n){e.prototype.resize.call(this,t,n),ue.info("renderer resize",t,n),this._options.width=t,this._options.height=n,this._renderer.resize(t,n),this.background&&this.background.resize(t,n),this._app3d?this._app3d.resize(t,n):this._avatar3d&&this._avatar3d.resize(t,n),this._baseRenderTexture&&this._baseRenderTexture.resize(t,n),this._makeupRenderTexture&&this._makeupRenderTexture.resize(t,n)},t.prototype.disableExclusiveFilter=function(){this.exclusiveFilter&&this.exclusiveFilter.remove()},t.prototype.enableExclusiveFilter=function(){this.exclusiveFilter&&this.exclusiveFilter.apply({filterTarget:this._baseSprite,filterCallback:function(){}})},t.prototype.disableEffects=function(){this._effects.forEach((function(e){e.isPureFilter||"hand"===e.type||e.remove()}))},t.prototype.enableEffects=function(){var e=this;this._effects.forEach((function(t){t.apply({filterTarget:e._baseSprite,filterCallback:function(){}})}))},t.prototype.removeExclusiveFilter=function(){this.exclusiveFilter&&(this.exclusiveFilter.destroy(),this.exclusiveFilter=null)},t.prototype.initAvatarApp=function(e,t){return se(this,void 0,void 0,(function(){return ae(this,(function(e){return[2]}))}))},t.prototype.setAvatar=function(e,t){return se(this,void 0,void 0,(function(){return ae(this,(function(e){return[2]}))}))},t.prototype.registerAvatar=function(e){},t.prototype.reCorrectAvatar=function(){return se(this,void 0,void 0,(function(){return ae(this,(function(e){return[2]}))}))},t.prototype.getCanvas=function(){return this._canvas},t.prototype.setOptions=function(e){},t.prototype.mount=function(e){this._canvas&&e.appendChild(this._canvas)},t.prototype.getCircle=function(e){void 0===e&&(e=5);var t=new a.TC;return t.beginFill(16711680),t.drawCircle(0,0,e),t.endFill(),t},t.preloadEffects=function(e){return se(this,void 0,Promise,(function(){var t,n,i,r,s,a,c;return ae(this,(function(u){switch(u.label){case 0:return e.length?[4,(t=new o.pF).init()]:[2];case 1:u.sent(),n=[];try{for(i=ce(e),r=i.next();!r.done;r=i.next())(s=r.value)&&n.push(t.preload(s))}catch(e){a={error:e}}finally{try{r&&!r.done&&(c=i.return)&&c.call(i)}finally{if(a)throw a.error}}return[2,Promise.all(n).then((function(){return Promise.resolve()})).catch((function(e){return Promise.reject(e)}))]}}))}))},t.prototype.handleLoading=function(){var e=this._options,n=e.enableLoadingIcon,i=e.loadingIconOptions,r=void 0===i?{}:i;if(n){var o=t.loading=new Q.Z(r);o.zIndex=20;var s=this._options,a=s.width,c=s.height;o.x=a/2,o.y=c/2,this._stage.addChild(o)}},t.prototype.showLoading=function(){t.loading&&t.loading.show()},t.prototype.hideLoading=function(){t.loading&&t.loading.hide()},t.prototype.destroy=function(){this.hideLoading(),t.loading&&t.loading.destroy(),he.baseTexture&&(he.baseTexture.destroy(!0),he.baseTexture=null),this._destroyed=!0,this._effects.forEach((function(e){e.destroy()})),this.exclusiveFilter&&this.exclusiveFilter.destroy(),this._stage&&this._stage.destroy(!0),this._renderer&&this._renderer.destroy(!0),this.background&&this.background.destroy(),this._app3d&&this._app3d.destroy(),this._appHand3d&&this._appHand3d.destroy(),this._meshVertexTimer&&clearTimeout(this._meshVertexTimer),this.destroyAvatar()},t.prototype.destroyAvatar=function(){this._avatar3d&&(this._avatar3d.destroy(),this._avatar3d=null)},re([(0,h.M)("ArRenderer"),oe("design:type",Function),oe("design:paramtypes",[]),oe("design:returntype",void 0)],t.prototype,"destroy",null),t}(ne.F)}}]);
|