};EffectRenderer.displayName="EffectRenderer"},0x633177a3:(e,t,r)=>{"use strict";function compileShader(e,t,r){let i=e.createShader(r);if(!i)throw Error("GL: Failed to create shader");if(e.shaderSource(i,t),e.compileShader(i),!e.getShaderParameter(i,e.COMPILE_STATUS))throw Error(`GL: Failed to compile shader
${e.getShaderInfoLog(i)}`);return i}function createProgram(e,t,r){let i=e.createProgram();if(!i)throw Error("GL: Failed to create WebGL program");let o=compileShader(e,t,e.VERTEX_SHADER),a=compileShader(e,r,e.FRAGMENT_SHADER);if(e.attachShader(i,o),e.attachShader(i,a),e.linkProgram(i),!e.getProgramParameter(i,e.LINK_STATUS))throw Error(`GL: Failed to link program
${e.getProgramInfoLog(i)}`);return i}function createTexture(e,t=e.NEAREST){let r=e.createTexture();if(!r)throw Error("GL: Failed to create texture");return e.bindTexture(e.TEXTURE_2D,r),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_S,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_WRAP_T,e.CLAMP_TO_EDGE),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MIN_FILTER,t),e.texParameteri(e.TEXTURE_2D,e.TEXTURE_MAG_FILTER,t),r}function createEmptyTexture(e,t,r,i=e.NEAREST){let o=createTexture(e,i);return e.texImage2D(e.TEXTURE_2D,0,e.RGBA,t,r,0,e.RGBA,e.UNSIGNED_BYTE,null),o}function createFramebuffer(e){let t=e.createFramebuffer();if(!t)throw Error("GL: Failed to create framebuffer");return t}function bindVertexAttribBuffers(e,t){t.forEach(t=>{e.enableVertexAttribArray(t.location),e.bindBuffer(e.ARRAY_BUFFER,t.buffer),e.vertexAttribPointer(t.location,2,e.FLOAT,!1,0,0)})}r.d(t,{TD:()=>createEmptyTexture,f6:()=>bindVertexAttribBuffers,oN:()=>createFramebuffer,rC:()=>createProgram,sZ:()=>createTexture})},0xe4c0faec:(e,t,r)=>{"use strict";e.exports=r.p+"model32-2a8ae1f.tfjson"},0x49cd54a7:(e,t,r)=>{"use strict";e.exports=r.p+"weights32-0a2efa5.tfbin"},0x866fcb20:e=>{"use strict";e.exports=`precision mediump float;

uniform sampler2D u_video;
uniform sampler2D u_bg;
uniform sampler2D u_mask;
uniform sampler2D u_in;

uniform vec2 u_direction;
uniform bool u_out;

varying vec2 v_texCoord;

float weight(in float x) {
	return -(1.0 / pow(1.0-0.48, 2.0)) * pow(x-0.48, 2.0) + 1.0;
}

// http://rastergrid.com/blog/2010/09/efficient-gaussian-blur-with-linear-sampling/
vec4 blur() {
	vec4 color = vec4(0.0);
	vec2 u = u_direction * weight(texture2D(u_mask, v_texCoord).a);
	vec2 off1 = vec2(1.411764705882353) * u;
	vec2 off2 = vec2(3.2941176470588234) * u;
	vec2 off3 = vec2(5.176470588235294) * u;
	color += texture2D(u_in, v_texCoord) * 0.1964825501511404;
	color += texture2D(u_in, v_texCoord + off1) * 0.2969069646728344;
	color += texture2D(u_in, v_texCoord - off1) * 0.2969069646728344;
	color += texture2D(u_in, v_texCoord + off2) * 0.09447039785044732;
	color += texture2D(u_in, v_texCoord - off2) * 0.09447039785044732;
	color += texture2D(u_in, v_texCoord + off3) * 0.010381362401148057;
	color += texture2D(u_in, v_texCoord - off3) * 0.010381362401148057;
	return color;
}

void main() {
	vec4 blurred = blur();
	if (u_out) {
		float va = 1.0 - texture2D(u_mask, v_texCoord).a;
		float ba = 1.0 - va;
		float wa = max(blurred.a - ba, 0.0);

		vec4 mixed = vec4(texture2D(u_video, v_texCoord).rgb, 1.0) * va + vec4(texture2D(u_bg, v_texCoord).rgb, 1.0) * ba;
		vec4 wrap = vec4(texture2D(u_bg, v_texCoord).rgb * wa, 1.0);

		gl_FragColor = vec4(1.0) - (vec4(1.0) - mixed) * (vec4(1.0) - wrap);
	} else {
		gl_FragColor = blurred;
	}
}
`},0x12bb1ab53:e=>{"use strict";e.exports=`// Bilateral filter. Based on https://www.shadertoy.com/view/4dfGDH#

precision mediump float;

// Blur parameters (see https://en.wikipedia.org/wiki/Bilateral_filter#Parameters)
// Gaussian (spatial) parameter: amount of blur
#define SIGMA 4.0
// Bilateral (range) paramter: amount of edge retention
#define BSIGMA 1.0

#define MSIZE 15

uniform sampler2D u_mask;
uniform vec2 u_unit;
uniform bool u_flip;
uniform bool u_invert;
uniform bool u_ramp;

varying vec2 v_texCoord;

float normpdf(in float x, in float sigma) {
	return 0.39894*exp(-0.5*x*x/(sigma*sigma))/sigma;
}

float ramp(in float a, in float lower, in float upper) {
	return max(0.0, min(1.0, (a - lower) / (upper - lower)));
}

float sample(vec2 coord) {
	float a = texture2D(u_mask, coord).a;
	if (u_ramp) return ramp(a, 0.2, 0.6);
	else return a;
}

void main() {
	vec2 vt = v_texCoord;
	if (u_flip) vt = vec2(vt.x, 1.0 - vt.y);

	// Color of current pixel
	float c = sample(vt);

	// Initialize kernel
	const int kSize = (MSIZE - 1) / 2;
	float kernel[MSIZE];
	float bfinal_colour = 0.0;

	// Normalization sum
	float bZ = 0.0;

	// Create the 1-D kernel
	for (int j = 0; j <= kSize; ++j) {
		kernel[kSize+j] = kernel[kSize-j] = normpdf(float(j), SIGMA);
	}

	float cc;
	float gfactor;
	float bfactor;
	float bZnorm = 1.0 / normpdf(0.0, BSIGMA);
	// Iterate over neighbouring pixels
	for (int i = -kSize; i <= kSize; ++i)
	{
		for (int j = -kSize; j <= kSize; ++j)
		{
			// Color of neighbouring pixel
			vec2 coord = vt + vec2(float(i), float(j)) * u_unit;
			cc = sample(coord);

			// Compute Gaussian and bilateral weights
			gfactor = kernel[kSize+j] * kernel[kSize+i];
			bfactor = normpdf(cc-c, BSIGMA) * bZnorm * gfactor;
			bZ += bfactor;

			bfinal_colour += bfactor * cc;
		}
	}

	float normalized = bfinal_colour / bZ;
	float inverted = u_invert ? 1.0 - normalized : normalized;
	gl_FragColor = vec4(1.0, 0.0, 0.0, inverted);
}
`},0x2310d95fe:e=>{"use strict";e.exports=`precision mediump float;

uniform sampler2D u_video;
uniform sampler2D u_mask;

uniform vec2 u_direction;
uniform bool u_invert;

varying vec2 v_texCoord;

float sample(vec2 coord) {
	if (u_invert) return 1.0 - texture2D(u_mask, coord).a;
	return texture2D(u_mask, coord).a;
}

// http://rastergrid.com/blog/2010/09/efficient-gaussian-blur-with-linear-sampling/
// Weighted Gaussian blur with mask avoidance
vec4 blur() {
	vec4 color = vec4(0.0);
	vec2 u = u_direction * sample(v_texCoord);
	vec2 off1 = vec2(1.411764705882353) * u;
	vec2 off2 = vec2(3.2941176470588234) * u;
	vec2 off3 = vec2(5.176470588235294) * u;
	color += texture2D(u_video, v_texCoord) * 0.1964825501511404;
	color += texture2D(u_video, v_texCoord + off1) * texture2D(u_mask, v_texCoord + off1).a * 0.2969069646728344;
	color += texture2D(u_video, v_texCoord - off1) * texture2D(u_mask, v_texCoord - off1).a * 0.2969069646728344;
	color += texture2D(u_video, v_texCoord + off2) * texture2D(u_mask, v_texCoord + off2).a * 0.09447039785044732;
	color += texture2D(u_video, v_texCoord - off2) * texture2D(u_mask, v_texCoord - off2).a * 0.09447039785044732;
	color += texture2D(u_video, v_texCoord + off3) * texture2D(u_mask, v_texCoord + off3).a * 0.010381362401148057;
	color += texture2D(u_video, v_texCoord - off3) * texture2D(u_mask, v_texCoord - off3).a * 0.010381362401148057;
	return color / color.a;
}

void main() {
	vec4 blurred = blur();
	gl_FragColor = blurred;
}
`},0x1cab58f69:e=>{"use strict";e.exports=`// Draws a texture

precision mediump float;

uniform sampler2D u_in;

varying vec2 v_texCoord;

void main() {
	gl_FragColor = texture2D(u_in, v_texCoord);
}
`},0x170f28e85:e=>{"use strict";e.exports=`precision mediump float;

attribute vec2 a_position;
attribute vec2 a_texCoord;

varying vec2 v_texCoord;

void main() {
	gl_Position = vec4(a_position, 0.0, 1.0);
	v_texCoord = a_texCoord;
}
`},0x195a704a0:()=>{},0xc555ac2b:()=>{},0xca07503f:()=>{},0x63afd605:()=>{},0x5395223a:()=>{},0x2919665f:()=>{}}]);
//# sourceMappingURL=https://slack.com/source-maps/bv1-13/gantry-v2-async-effect-renderer.611cd2386a0c74a0cea7.min.js.mapØA
—Eoúô