glslx 0.2.13 → 0.3.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/glslx +78 -77
  2. package/package.json +1 -1
package/glslx CHANGED
@@ -1,78 +1,79 @@
1
1
  #!/usr/bin/env node
2
- (function(){var ch=Object.create||function(a){return{__proto__:a}};function rh(a,b){a.prototype=ch(b.prototype),a.prototype.constructor=a}var sh=Math.imul||function(a,b){return (a*(b>>>16)<<16)+a*(b&65535)|0};var Ze;function th(a){return typeof a==='string'}function uh(a){return a===null?a:a+''}function We(c,a,b){return c.a=a,c.b=b,c.c=a.length,c}function Xe(c){if(c.b>=c.c)return-1;var a=c.a.charCodeAt((c.b=c.b+1|0)-1|0);if(a&64512^55296)return a;if(c.b>=c.c)return-1;var b=c.a.charCodeAt((c.b=c.b+1|0)-1|0);return ((a<<10)+b|0)-56613888|0}function tc(a){return a.c=a.c+1|0,a.c}function Sc(v,a){switch(a){case 0:var b={};return Array.from(v.b.keys()).forEach(function(c){b[c]=v.b.get(c)}),JSON.stringify({shaders:v.a?v.a.map(function(d){return{name:d.a,contents:d.b}}):null,renaming:b},null,2)+'\n';case 1:if(v.a){for(var e='',q=0,E=v.a,F=E.length;q<F;q=q+1|0){var f=E[q];e+='export const GLSLX_SOURCE_'+f.a.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+' = '+JSON.stringify(f.b)+'\n'}if(v.b&&Array.from(v.b.keys()).length){
3
- e+='\n';for(var H=0,O=Array.from(v.b.keys()),ha=O.length;H<ha;H=H+1|0){var h=O[H];e+='export const GLSLX_NAME_'+h.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+' = '+JSON.stringify(v.b.get(h))+'\n'}}return e}break;case 2:if(v.a){var m='';m+='#ifndef GLSLX_STRINGS_H\n',m+='#define GLSLX_STRINGS_H\n',m+='\n';for(var L=0,ia=v.a,Z=ia.length;L<Z;L=L+1|0){var l=ia[L];m+='static const char *GLSLX_SOURCE_'+l.a.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+' = '+JSON.stringify(l.b)+';\n'}if(m+='\n',v.b){for(var $=0,ca=Array.from(v.b.keys()),ua=ca.length;$<ua;$=$+1|0){var g=ca[$];m+='static const char *GLSLX_NAME_'+g.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+' = '+JSON.stringify(v.b.get(g))+';\n'}m+='\n'}return m+='#endif\n',m}break;case 3:if(v.a){for(var i='',aa=0,ka=v.a,va=ka.length;aa<va;aa=aa+1|0){var n=ka[aa];i+='const GLSLX_SOURCE_'+n.a.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+' = '+JSON.stringify(n.b)+'\n'}if(v.b&&Array.from(v.b.keys()).length){
4
- i+='\n';for(var Ua=0,la=Array.from(v.b.keys()),rb=la.length;Ua<rb;Ua=Ua+1|0){var k=la[Ua];i+='const GLSLX_NAME_'+k.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+' = '+JSON.stringify(v.b.get(k))+'\n'}}return i}break;case 4:if(v.a){for(var p='',La=0,Va=v.a,wa=Va.length;La<wa;La=La+1|0){var t=Va[La];p+='pub static GLSLX_SOURCE_'+t.a.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+': &str = '+JSON.stringify(t.b)+';\n'}if(v.b&&Array.from(v.b.keys()).length){p+='\n';for(var xa=0,eb=Array.from(v.b.keys()),Ia=eb.length;xa<Ia;xa=xa+1|0){var w=eb[xa];p+='pub static GLSLX_NAME_'+w.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+': &str = '+JSON.stringify(v.b.get(w))+';\n'}}return p}break}return null}function af(a,b,c){if(a.d)return null;b.unshift(new Zh('<api>',"\nimport {\n // The variable `gl_Position` is available only in the vertex language and is intended for writing the\n // homogeneous vertex position. This value will be used by primitive assembly, clipping, culling, and other\n // fixed functionality operations that operate on primitives after vertex processing has occurred.\n //\n // All executions of a well-formed vertex shader should write a value into this variable. It can be\n // written at any time during shader execution. It may also be read back by the shader after being written.\n // Compilers may generate a diagnostic message if they detect `gl_Position` is not written, or read before\n // being written, but not all such cases are detectable. The value of `gl_Position` is undefined if a vertex\n // shader is executed and does not write `gl_Position`.\n highp vec4 gl_Position;\n\n // The variable `gl_PointSize` is available only in the vertex language and is intended for\n // a vertex shader to write the size of the point to be rasterized. It is measured in pixels.\n mediump float gl_PointSize;\n\n const int gl_MaxVertexAttribs;\n const int gl_MaxVertexUniformVectors;\n const int gl_MaxVaryingVectors;\n const int gl_MaxVertexTextureImageUnits;\n const int gl_MaxCombinedTextureImageUnits;\n const int gl_MaxTextureImageUnits;\n const int gl_MaxFragmentUniformVectors;\n const int gl_MaxDrawBuffers;\n\n // The fragment shader has access to the read-only built-in variable `gl_FrontFacing` whose value is `true` if\n // the fragment belongs to a front-facing primitive. One use of this is to emulate two-sided lighting by\n // selecting one of two colors calculated by the vertex shader.\n const bool gl_FrontFacing;\n\n // The fragment shader has access to the read-only built-in variable `gl_PointCoord`. The values in\n // `gl_PointCoord` are two-dimensional coordinates indicating where within a point primitive the current\n // fragment is located. They range from 0.0 to 1.0 across the point. If the current primitive is not a\n // point, then the values read from `gl_PointCoord` are undefined.\n const mediump vec2 gl_PointCoord;\n\n // The variable `gl_FragCoord` is available as a read-only variable from within fragment shaders and it holds\n // the window relative coordinates `x`, `y`, `z`, and `1/w` values for the fragment. This value is the result\n // of the fixed functionality that interpolates primitives after vertex processing to generate fragments. The `z`\n // component is the depth value that will be used for the fragment's depth.\n const mediump vec4 gl_FragCoord;\n\n // Writing to `gl_FragColor` specifies the fragment color that will be used by the subsequent fixed\n // functionality pipeline.\n //\n // If subsequent fixed functionality consumes fragment color and an execution of a fragment shader\n // does not write a value to `gl_FragColor` then the fragment color consumed is undefined.\n mediump vec4 gl_FragColor;\n\n // The variable `gl_FragData` is an array. Writing to `gl_FragData[n]` specifies the fragment data that will be\n // used by the subsequent fixed functionality pipeline for data `n`.\n //\n // If subsequent fixed functionality consumes fragment data and an execution of a fragment shader does not write\n // a value to it, then the fragment data consumed is undefined.\n mediump vec4 gl_FragData[gl_MaxDrawBuffers];\n\n // Depth range in window coordinates\n struct gl_DepthRangeParameters {\n float near;\n float far;\n // Equal to `far - near`\n float diff;\n };\n\n uniform gl_DepthRangeParameters gl_DepthRange;\n\n ////////////////////////////////////////////////////////////////////////////////\n // Angle and Trigonometry Functions\n\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n float radians(float degrees);\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n vec2 radians(vec2 degrees);\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n vec3 radians(vec3 degrees);\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n vec4 radians(vec4 degrees);\n\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n float degrees(float radians);\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n vec2 degrees(vec2 radians);\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n vec3 degrees(vec3 radians);\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n vec4 degrees(vec4 radians);\n\n // The standard trigonometric sine function.\n float sin(float angle);\n // The standard trigonometric sine function.\n vec2 sin(vec2 angle);\n // The standard trigonometric sine function.\n vec3 sin(vec3 angle);\n // The standard trigonometric sine function.\n vec4 sin(vec4 angle);\n\n // The standard trigonometric cosine function.\n float cos(float angle);\n // The standard trigonometric cosine function.\n vec2 cos(vec2 angle);\n // The standard trigonometric cosine function.\n vec3 cos(vec3 angle);\n // The standard trigonometric cosine function.\n vec4 cos(vec4 angle);\n\n // The standard trigonometric tangent.\n float tan(float angle);\n // The standard trigonometric tangent.\n vec2 tan(vec2 angle);\n // The standard trigonometric tangent.\n vec3 tan(vec3 angle);\n // The standard trigonometric tangent.\n vec4 tan(vec4 angle);\n\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n float asin(float x);\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n vec2 asin(vec2 x);\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n vec3 asin(vec3 x);\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n vec4 asin(vec4 x);\n\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n float acos(float x);\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n vec2 acos(vec2 x);\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n vec3 acos(vec3 x);\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n vec4 acos(vec4 x);\n\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n float atan(float y, float x);\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n vec2 atan(vec2 y, vec2 x);\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n vec3 atan(vec3 y, vec3 x);\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n vec4 atan(vec4 y, vec4 x);\n\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n float atan(float y_over_x);\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n vec2 atan(vec2 y_over_x);\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n vec3 atan(vec3 y_over_x);\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n vec4 atan(vec4 y_over_x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Exponential Functions\n\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n float pow(float x, float y);\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n vec2 pow(vec2 x, vec2 y);\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n vec3 pow(vec3 x, vec3 y);\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n vec4 pow(vec4 x, vec4 y);\n\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n float exp(float x);\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n vec2 exp(vec2 x);\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n vec3 exp(vec3 x);\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n vec4 exp(vec4 x);\n\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n float log(float x);\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n vec2 log(vec2 x);\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n vec3 log(vec3 x);\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n vec4 log(vec4 x);\n\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n float exp2(float x);\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n vec2 exp2(vec2 x);\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n vec3 exp2(vec3 x);\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n vec4 exp2(vec4 x);\n\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n float log2(float x);\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n vec2 log2(vec2 x);\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n vec3 log2(vec3 x);\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n vec4 log2(vec4 x);\n\n // Returns `√x`. Results are undefined if `x < 0`.\n float sqrt(float x);\n // Returns `√x`. Results are undefined if `x < 0`.\n vec2 sqrt(vec2 x);\n // Returns `√x`. Results are undefined if `x < 0`.\n vec3 sqrt(vec3 x);\n // Returns `√x`. Results are undefined if `x < 0`.\n vec4 sqrt(vec4 x);\n\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n float inversesqrt(float x);\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n vec2 inversesqrt(vec2 x);\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n vec3 inversesqrt(vec3 x);\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n vec4 inversesqrt(vec4 x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Common Functions\n\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n float abs(float x);\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n vec2 abs(vec2 x);\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n vec3 abs(vec3 x);\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n vec4 abs(vec4 x);\n\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n float sign(float x);\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n vec2 sign(vec2 x);\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n vec3 sign(vec3 x);\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n vec4 sign(vec4 x);\n\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n float floor(float x);\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n vec2 floor(vec2 x);\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n vec3 floor(vec3 x);\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n vec4 floor(vec4 x);\n\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n float ceil(float x);\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n vec2 ceil(vec2 x);\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n vec3 ceil(vec3 x);\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n vec4 ceil(vec4 x);\n\n // Returns `x - floor(x)`\n float fract(float x);\n // Returns `x - floor(x)`\n vec2 fract(vec2 x);\n // Returns `x - floor(x)`\n vec3 fract(vec3 x);\n // Returns `x - floor(x)`\n vec4 fract(vec4 x);\n\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n float mod(float x, float y);\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n vec2 mod(vec2 x, float y);\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n vec3 mod(vec3 x, float y);\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n vec4 mod(vec4 x, float y);\n\n // Modulus. Returns `x - y * floor(x/y)`\n vec2 mod(vec2 x, vec2 y);\n // Modulus. Returns `x - y * floor(x/y)`\n vec3 mod(vec3 x, vec3 y);\n // Modulus. Returns `x - y * floor(x/y)`\n vec4 mod(vec4 x, vec4 y);\n\n // Returns `y` if `y < x`, otherwise it returns `x`\n float min(float x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec2 min(vec2 x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec2 min(vec2 x, vec2 y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec3 min(vec3 x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec3 min(vec3 x, vec3 y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec4 min(vec4 x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec4 min(vec4 x, vec4 y);\n\n // Returns `y` if `x < y`, otherwise it returns `x`\n float max(float x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec2 max(vec2 x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec2 max(vec2 x, vec2 y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec3 max(vec3 x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec3 max(vec3 x, vec3 y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec4 max(vec4 x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec4 max(vec4 x, vec4 y);\n\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n float clamp(float x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec2 clamp(vec2 x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec2 clamp(vec2 x, vec2 minVal, vec2 maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec3 clamp(vec3 x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec3 clamp(vec3 x, vec3 minVal, vec3 maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec4 clamp(vec4 x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec4 clamp(vec4 x, vec4 minVal, vec4 maxVal);\n\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n float mix(float x, float y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec2 mix(vec2 x, vec2 y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec2 mix(vec2 x, vec2 y, vec2 a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec3 mix(vec3 x, vec3 y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec3 mix(vec3 x, vec3 y, vec3 a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec4 mix(vec4 x, vec4 y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec4 mix(vec4 x, vec4 y, vec4 a);\n\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n float step(float edge, float x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec2 step(float edge, vec2 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec2 step(vec2 edge, vec2 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec3 step(float edge, vec3 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec3 step(vec3 edge, vec3 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec4 step(float edge, vec4 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec4 step(vec4 edge, vec4 x);\n\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // float t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n float smoothstep(float edge0, float edge1, float x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec2 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec2 smoothstep(float edge0, float edge1, vec2 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec2 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec2 smoothstep(vec2 edge0, vec2 edge1, vec2 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec3 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec3 smoothstep(float edge0, float edge1, vec3 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec3 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec3 smoothstep(vec3 edge0, vec3 edge1, vec3 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec4 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec4 smoothstep(float edge0, float edge1, vec4 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec4 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec4 smoothstep(vec4 edge0, vec4 edge1, vec4 x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Geometric Functions\n\n // Returns the length of vector `x`, i.e. `√x²`\n float length(float x);\n // Returns the length of vector `x`, i.e. `√x[0]² + x[1]²`\n float length(vec2 x);\n // Returns the length of vector `x`, i.e. `√x[0]² + x[1]² + x[2]²`\n float length(vec3 x);\n // Returns the length of vector `x`, i.e. `√x[0]² + x[1]² + x[2]² + x[3]²`\n float length(vec4 x);\n\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(float p0, float p1);\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(vec2 p0, vec2 p1);\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(vec3 p0, vec3 p1);\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(vec4 p0, vec4 p1);\n\n // Returns the dot product of `x` and `y`, i.e. `x*y`\n float dot(float x, float y);\n // Returns the dot product of `x` and `y`, i.e. `x[0]*y[0] + x[1]*y[1]`\n float dot(vec2 x, vec2 y);\n // Returns the dot product of `x` and `y`, i.e. `x[0]*y[0] + x[1]*y[1] + x[2]*y[2]`\n float dot(vec3 x, vec3 y);\n // Returns the dot product of `x` and `y`, i.e. `x[0]*y[0] + x[1]*y[1] + x[2]*y[2] + x[3]*y[3]`\n float dot(vec4 x, vec4 y);\n\n // Returns the cross product of `x` and `y`, i.e.\n //\n // ```glslx\n // vec3(\n // x[1]*y[2] - y[1]*x[2],\n // x[2]*y[0] - y[2]*x[0],\n // x[0]*y[1] - y[0]*x[1])\n // ```\n vec3 cross(vec3 x, vec3 y);\n\n // Returns a vector in the same direction as `x` but with a length of 1.\n float normalize(float x);\n // Returns a vector in the same direction as `x` but with a length of 1.\n vec2 normalize(vec2 x);\n // Returns a vector in the same direction as `x` but with a length of 1.\n vec3 normalize(vec3 x);\n // Returns a vector in the same direction as `x` but with a length of 1.\n vec4 normalize(vec4 x);\n\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n float faceforward(float N, float I, float Nref);\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n vec2 faceforward(vec2 N, vec2 I, vec2 Nref);\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n vec3 faceforward(vec3 N, vec3 I, vec3 Nref);\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n vec4 faceforward(vec4 N, vec4 I, vec4 Nref);\n\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n float reflect(float I, float N);\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n vec2 reflect(vec2 I, vec2 N);\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n vec3 reflect(vec3 I, vec3 N);\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n vec4 reflect(vec4 I, vec4 N);\n\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return float(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n float refract(float I, float N, float eta);\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return vec2(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n vec2 refract(vec2 I, vec2 N, float eta);\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return vec3(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n vec3 refract(vec3 I, vec3 N, float eta);\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return vec4(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n vec4 refract(vec4 I, vec4 N, float eta);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Matrix Functions\n\n // Multiply matrix `x` by matrix `y` component-wise, i.e., `result[i][j]` is the scalar product of `x[i][j]` and `y[i][j]`.\n // Note: to get linear algebraic matrix multiplication, use the multiply operator (`*`).\n mat2 matrixCompMult(mat2 x, mat2 y);\n // Multiply matrix `x` by matrix `y` component-wise, i.e., `result[i][j]` is the scalar product of `x[i][j]` and `y[i][j]`.\n // Note: to get linear algebraic matrix multiplication, use the multiply operator (`*`).\n mat3 matrixCompMult(mat3 x, mat3 y);\n // Multiply matrix `x` by matrix `y` component-wise, i.e., `result[i][j]` is the scalar product of `x[i][j]` and `y[i][j]`.\n // Note: to get linear algebraic matrix multiplication, use the multiply operator (`*`).\n mat4 matrixCompMult(mat4 x, mat4 y);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Vector Relational Functions\n\n // Returns the component-wise compare of `x < y`.\n bvec2 lessThan(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x < y`.\n bvec2 lessThan(vec2 x, vec2 y);\n // Returns the component-wise compare of `x < y`.\n bvec3 lessThan(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x < y`.\n bvec3 lessThan(vec3 x, vec3 y);\n // Returns the component-wise compare of `x < y`.\n bvec4 lessThan(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x < y`.\n bvec4 lessThan(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x <= y`.\n bvec2 lessThanEqual(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x <= y`.\n bvec2 lessThanEqual(vec2 x, vec2 y);\n // Returns the component-wise compare of `x <= y`.\n bvec3 lessThanEqual(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x <= y`.\n bvec3 lessThanEqual(vec3 x, vec3 y);\n // Returns the component-wise compare of `x <= y`.\n bvec4 lessThanEqual(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x <= y`.\n bvec4 lessThanEqual(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x > y`.\n bvec2 greaterThan(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x > y`.\n bvec2 greaterThan(vec2 x, vec2 y);\n // Returns the component-wise compare of `x > y`.\n bvec3 greaterThan(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x > y`.\n bvec3 greaterThan(vec3 x, vec3 y);\n // Returns the component-wise compare of `x > y`.\n bvec4 greaterThan(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x > y`.\n bvec4 greaterThan(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x >= y`.\n bvec2 greaterThanEqual(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x >= y`.\n bvec2 greaterThanEqual(vec2 x, vec2 y);\n // Returns the component-wise compare of `x >= y`.\n bvec3 greaterThanEqual(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x >= y`.\n bvec3 greaterThanEqual(vec3 x, vec3 y);\n // Returns the component-wise compare of `x >= y`.\n bvec4 greaterThanEqual(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x >= y`.\n bvec4 greaterThanEqual(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x == y`.\n bvec2 equal(bvec2 x, bvec2 y);\n // Returns the component-wise compare of `x == y`.\n bvec2 equal(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x == y`.\n bvec2 equal(vec2 x, vec2 y);\n // Returns the component-wise compare of `x == y`.\n bvec3 equal(bvec3 x, bvec3 y);\n // Returns the component-wise compare of `x == y`.\n bvec3 equal(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x == y`.\n bvec3 equal(vec3 x, vec3 y);\n // Returns the component-wise compare of `x == y`.\n bvec4 equal(bvec4 x, bvec4 y);\n // Returns the component-wise compare of `x == y`.\n bvec4 equal(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x == y`.\n bvec4 equal(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x != y`.\n bvec2 notEqual(bvec2 x, bvec2 y);\n // Returns the component-wise compare of `x != y`.\n bvec2 notEqual(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x != y`.\n bvec2 notEqual(vec2 x, vec2 y);\n // Returns the component-wise compare of `x != y`.\n bvec3 notEqual(bvec3 x, bvec3 y);\n // Returns the component-wise compare of `x != y`.\n bvec3 notEqual(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x != y`.\n bvec3 notEqual(vec3 x, vec3 y);\n // Returns the component-wise compare of `x != y`.\n bvec4 notEqual(bvec4 x, bvec4 y);\n // Returns the component-wise compare of `x != y`.\n bvec4 notEqual(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x != y`.\n bvec4 notEqual(vec4 x, vec4 y);\n\n // Returns true if any component of `x` is `true`.\n bool any(bvec2 x);\n // Returns true if any component of `x` is `true`.\n bool any(bvec3 x);\n // Returns true if any component of `x` is `true`.\n bool any(bvec4 x);\n\n // Returns true only if all components of `x` are `true`.\n bool all(bvec2 x);\n // Returns true only if all components of `x` are `true`.\n bool all(bvec3 x);\n // Returns true only if all components of `x` are `true`.\n bool all(bvec4 x);\n\n // Returns the component-wise logical complement of `x`.\n bvec2 not(bvec2 x);\n // Returns the component-wise logical complement of `x`.\n bvec3 not(bvec3 x);\n // Returns the component-wise logical complement of `x`.\n bvec4 not(bvec4 x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Texture Lookup Functions\n\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n vec4 texture2D(sampler2D sampler, vec2 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n vec4 texture2D(sampler2D sampler, vec2 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n vec4 texture2DLod(sampler2D sampler, vec2 coord, float lod);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`.\n vec4 texture2DProj(sampler2D sampler, vec3 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`.\n vec4 texture2DProj(sampler2D sampler, vec3 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`.\n vec4 texture2DProjLod(sampler2D sampler, vec3 coord, float lod);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`. The third component of `coord` is ignored.\n vec4 texture2DProj(sampler2D sampler, vec4 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`. The third component of `coord` is ignored.\n vec4 texture2DProj(sampler2D sampler, vec4 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`. The third component of `coord` is ignored.\n vec4 texture2DProjLod(sampler2D sampler, vec4 coord, float lod);\n\n // Use the texture coordinate `coord` to do a texture lookup in the cube map texture currently bound to `sampler`.\n // The direction of `coord` is used to select which face to do a 2-dimensional texture lookup in.\n vec4 textureCube(samplerCube sampler, vec3 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the cube map texture currently bound to `sampler`.\n // The direction of `coord` is used to select which face to do a 2-dimensional texture lookup in.\n vec4 textureCube(samplerCube sampler, vec3 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the cube map texture currently bound to `sampler`.\n // The direction of `coord` is used to select which face to do a 2-dimensional texture lookup in.\n vec4 textureCubeLod(samplerCube sampler, vec3 coord, float lod);\n\n #extension GL_OES_standard_derivatives {\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n float dFdx(float v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec2 dFdx(vec2 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec3 dFdx(vec3 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec4 dFdx(vec4 v);\n\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n float dFdy(float v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec2 dFdy(vec2 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec3 dFdy(vec3 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec4 dFdy(vec4 v);\n\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n float fwidth(float v);\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n vec2 fwidth(vec2 v);\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n vec3 fwidth(vec3 v);\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n vec4 fwidth(vec4 v);\n }\n\n #extension GL_EXT_frag_depth {\n // Available only in the fragment language, `gl_FragDepthEXT` is an output variable that is used to establish the depth value for the current fragment.\n // If depth buffering is enabled and no shader writes to `gl_FragDepthEXT`, then the fixed function value for depth will be used (this value is contained\n // in the `z` component of `gl_FragCoord`) otherwise, the value written to `gl_FragDepthEXT` is used.\n //\n // If a shader statically assigns to `gl_FragDepthEXT`, then the value of the fragment's depth may be undefined for executions of the shader that take\n // that path. That is, if the set of linked fragment shaders statically contain a write to `gl_FragDepthEXT`, then it is responsible for always writing it.\n float gl_FragDepthEXT;\n }\n\n #extension GL_EXT_shader_texture_lod {\n vec4 texture2DGradEXT(sampler2D sampler, vec2 P, vec2 dPdx, vec2 dPdy);\n vec4 texture2DLodEXT(sampler2D sampler, vec2 coord, float lod);\n vec4 texture2DProjGradEXT(sampler2D sampler, vec3 P, vec2 dPdx, vec2 dPdy);\n vec4 texture2DProjGradEXT(sampler2D sampler, vec4 P, vec2 dPdx, vec2 dPdy);\n vec4 texture2DProjLodEXT(sampler2D sampler, vec3 coord, float lod);\n vec4 texture2DProjLodEXT(sampler2D sampler, vec4 coord, float lod);\n vec4 textureCubeGradEXT(samplerCube sampler, vec3 P, vec3 dPdx, vec3 dPdy);\n vec4 textureCubeLodEXT(samplerCube sampler, vec3 coord, float lod);\n }\n}\n"));
5
- for(var n=0,k=b.length;n<k;n=n+1|0){var d=b[n];d.c=Kc(a,d,0)}for(var e=new Lh(0),f=new Xh(1,null),h=new wh(c.e),m=new Vh(a,h),l=[],p=0,t=b.length;p<t;p=p+1|0){var g=b[p],i=jd(a,g.c,e,h,f,m);$e(l,i.a)}return nd(m,e),new yh(e,l)}function Id(a,b,c){if(a.d)return null;b.unshift(new Zh('<api>',"\nimport {\n // The variable `gl_Position` is available only in the vertex language and is intended for writing the\n // homogeneous vertex position. This value will be used by primitive assembly, clipping, culling, and other\n // fixed functionality operations that operate on primitives after vertex processing has occurred.\n //\n // All executions of a well-formed vertex shader should write a value into this variable. It can be\n // written at any time during shader execution. It may also be read back by the shader after being written.\n // Compilers may generate a diagnostic message if they detect `gl_Position` is not written, or read before\n // being written, but not all such cases are detectable. The value of `gl_Position` is undefined if a vertex\n // shader is executed and does not write `gl_Position`.\n highp vec4 gl_Position;\n\n // The variable `gl_PointSize` is available only in the vertex language and is intended for\n // a vertex shader to write the size of the point to be rasterized. It is measured in pixels.\n mediump float gl_PointSize;\n\n const int gl_MaxVertexAttribs;\n const int gl_MaxVertexUniformVectors;\n const int gl_MaxVaryingVectors;\n const int gl_MaxVertexTextureImageUnits;\n const int gl_MaxCombinedTextureImageUnits;\n const int gl_MaxTextureImageUnits;\n const int gl_MaxFragmentUniformVectors;\n const int gl_MaxDrawBuffers;\n\n // The fragment shader has access to the read-only built-in variable `gl_FrontFacing` whose value is `true` if\n // the fragment belongs to a front-facing primitive. One use of this is to emulate two-sided lighting by\n // selecting one of two colors calculated by the vertex shader.\n const bool gl_FrontFacing;\n\n // The fragment shader has access to the read-only built-in variable `gl_PointCoord`. The values in\n // `gl_PointCoord` are two-dimensional coordinates indicating where within a point primitive the current\n // fragment is located. They range from 0.0 to 1.0 across the point. If the current primitive is not a\n // point, then the values read from `gl_PointCoord` are undefined.\n const mediump vec2 gl_PointCoord;\n\n // The variable `gl_FragCoord` is available as a read-only variable from within fragment shaders and it holds\n // the window relative coordinates `x`, `y`, `z`, and `1/w` values for the fragment. This value is the result\n // of the fixed functionality that interpolates primitives after vertex processing to generate fragments. The `z`\n // component is the depth value that will be used for the fragment's depth.\n const mediump vec4 gl_FragCoord;\n\n // Writing to `gl_FragColor` specifies the fragment color that will be used by the subsequent fixed\n // functionality pipeline.\n //\n // If subsequent fixed functionality consumes fragment color and an execution of a fragment shader\n // does not write a value to `gl_FragColor` then the fragment color consumed is undefined.\n mediump vec4 gl_FragColor;\n\n // The variable `gl_FragData` is an array. Writing to `gl_FragData[n]` specifies the fragment data that will be\n // used by the subsequent fixed functionality pipeline for data `n`.\n //\n // If subsequent fixed functionality consumes fragment data and an execution of a fragment shader does not write\n // a value to it, then the fragment data consumed is undefined.\n mediump vec4 gl_FragData[gl_MaxDrawBuffers];\n\n // Depth range in window coordinates\n struct gl_DepthRangeParameters {\n float near;\n float far;\n // Equal to `far - near`\n float diff;\n };\n\n uniform gl_DepthRangeParameters gl_DepthRange;\n\n ////////////////////////////////////////////////////////////////////////////////\n // Angle and Trigonometry Functions\n\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n float radians(float degrees);\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n vec2 radians(vec2 degrees);\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n vec3 radians(vec3 degrees);\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n vec4 radians(vec4 degrees);\n\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n float degrees(float radians);\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n vec2 degrees(vec2 radians);\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n vec3 degrees(vec3 radians);\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n vec4 degrees(vec4 radians);\n\n // The standard trigonometric sine function.\n float sin(float angle);\n // The standard trigonometric sine function.\n vec2 sin(vec2 angle);\n // The standard trigonometric sine function.\n vec3 sin(vec3 angle);\n // The standard trigonometric sine function.\n vec4 sin(vec4 angle);\n\n // The standard trigonometric cosine function.\n float cos(float angle);\n // The standard trigonometric cosine function.\n vec2 cos(vec2 angle);\n // The standard trigonometric cosine function.\n vec3 cos(vec3 angle);\n // The standard trigonometric cosine function.\n vec4 cos(vec4 angle);\n\n // The standard trigonometric tangent.\n float tan(float angle);\n // The standard trigonometric tangent.\n vec2 tan(vec2 angle);\n // The standard trigonometric tangent.\n vec3 tan(vec3 angle);\n // The standard trigonometric tangent.\n vec4 tan(vec4 angle);\n\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n float asin(float x);\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n vec2 asin(vec2 x);\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n vec3 asin(vec3 x);\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n vec4 asin(vec4 x);\n\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n float acos(float x);\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n vec2 acos(vec2 x);\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n vec3 acos(vec3 x);\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n vec4 acos(vec4 x);\n\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n float atan(float y, float x);\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n vec2 atan(vec2 y, vec2 x);\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n vec3 atan(vec3 y, vec3 x);\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n vec4 atan(vec4 y, vec4 x);\n\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n float atan(float y_over_x);\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n vec2 atan(vec2 y_over_x);\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n vec3 atan(vec3 y_over_x);\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n vec4 atan(vec4 y_over_x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Exponential Functions\n\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n float pow(float x, float y);\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n vec2 pow(vec2 x, vec2 y);\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n vec3 pow(vec3 x, vec3 y);\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n vec4 pow(vec4 x, vec4 y);\n\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n float exp(float x);\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n vec2 exp(vec2 x);\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n vec3 exp(vec3 x);\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n vec4 exp(vec4 x);\n\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n float log(float x);\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n vec2 log(vec2 x);\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n vec3 log(vec3 x);\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n vec4 log(vec4 x);\n\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n float exp2(float x);\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n vec2 exp2(vec2 x);\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n vec3 exp2(vec3 x);\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n vec4 exp2(vec4 x);\n\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n float log2(float x);\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n vec2 log2(vec2 x);\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n vec3 log2(vec3 x);\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n vec4 log2(vec4 x);\n\n // Returns `√x`. Results are undefined if `x < 0`.\n float sqrt(float x);\n // Returns `√x`. Results are undefined if `x < 0`.\n vec2 sqrt(vec2 x);\n // Returns `√x`. Results are undefined if `x < 0`.\n vec3 sqrt(vec3 x);\n // Returns `√x`. Results are undefined if `x < 0`.\n vec4 sqrt(vec4 x);\n\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n float inversesqrt(float x);\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n vec2 inversesqrt(vec2 x);\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n vec3 inversesqrt(vec3 x);\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n vec4 inversesqrt(vec4 x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Common Functions\n\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n float abs(float x);\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n vec2 abs(vec2 x);\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n vec3 abs(vec3 x);\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n vec4 abs(vec4 x);\n\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n float sign(float x);\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n vec2 sign(vec2 x);\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n vec3 sign(vec3 x);\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n vec4 sign(vec4 x);\n\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n float floor(float x);\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n vec2 floor(vec2 x);\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n vec3 floor(vec3 x);\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n vec4 floor(vec4 x);\n\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n float ceil(float x);\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n vec2 ceil(vec2 x);\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n vec3 ceil(vec3 x);\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n vec4 ceil(vec4 x);\n\n // Returns `x - floor(x)`\n float fract(float x);\n // Returns `x - floor(x)`\n vec2 fract(vec2 x);\n // Returns `x - floor(x)`\n vec3 fract(vec3 x);\n // Returns `x - floor(x)`\n vec4 fract(vec4 x);\n\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n float mod(float x, float y);\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n vec2 mod(vec2 x, float y);\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n vec3 mod(vec3 x, float y);\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n vec4 mod(vec4 x, float y);\n\n // Modulus. Returns `x - y * floor(x/y)`\n vec2 mod(vec2 x, vec2 y);\n // Modulus. Returns `x - y * floor(x/y)`\n vec3 mod(vec3 x, vec3 y);\n // Modulus. Returns `x - y * floor(x/y)`\n vec4 mod(vec4 x, vec4 y);\n\n // Returns `y` if `y < x`, otherwise it returns `x`\n float min(float x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec2 min(vec2 x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec2 min(vec2 x, vec2 y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec3 min(vec3 x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec3 min(vec3 x, vec3 y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec4 min(vec4 x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec4 min(vec4 x, vec4 y);\n\n // Returns `y` if `x < y`, otherwise it returns `x`\n float max(float x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec2 max(vec2 x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec2 max(vec2 x, vec2 y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec3 max(vec3 x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec3 max(vec3 x, vec3 y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec4 max(vec4 x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec4 max(vec4 x, vec4 y);\n\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n float clamp(float x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec2 clamp(vec2 x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec2 clamp(vec2 x, vec2 minVal, vec2 maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec3 clamp(vec3 x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec3 clamp(vec3 x, vec3 minVal, vec3 maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec4 clamp(vec4 x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec4 clamp(vec4 x, vec4 minVal, vec4 maxVal);\n\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n float mix(float x, float y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec2 mix(vec2 x, vec2 y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec2 mix(vec2 x, vec2 y, vec2 a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec3 mix(vec3 x, vec3 y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec3 mix(vec3 x, vec3 y, vec3 a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec4 mix(vec4 x, vec4 y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec4 mix(vec4 x, vec4 y, vec4 a);\n\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n float step(float edge, float x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec2 step(float edge, vec2 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec2 step(vec2 edge, vec2 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec3 step(float edge, vec3 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec3 step(vec3 edge, vec3 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec4 step(float edge, vec4 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec4 step(vec4 edge, vec4 x);\n\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // float t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n float smoothstep(float edge0, float edge1, float x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec2 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec2 smoothstep(float edge0, float edge1, vec2 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec2 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec2 smoothstep(vec2 edge0, vec2 edge1, vec2 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec3 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec3 smoothstep(float edge0, float edge1, vec3 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec3 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec3 smoothstep(vec3 edge0, vec3 edge1, vec3 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec4 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec4 smoothstep(float edge0, float edge1, vec4 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec4 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec4 smoothstep(vec4 edge0, vec4 edge1, vec4 x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Geometric Functions\n\n // Returns the length of vector `x`, i.e. `√x²`\n float length(float x);\n // Returns the length of vector `x`, i.e. `√x[0]² + x[1]²`\n float length(vec2 x);\n // Returns the length of vector `x`, i.e. `√x[0]² + x[1]² + x[2]²`\n float length(vec3 x);\n // Returns the length of vector `x`, i.e. `√x[0]² + x[1]² + x[2]² + x[3]²`\n float length(vec4 x);\n\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(float p0, float p1);\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(vec2 p0, vec2 p1);\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(vec3 p0, vec3 p1);\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(vec4 p0, vec4 p1);\n\n // Returns the dot product of `x` and `y`, i.e. `x*y`\n float dot(float x, float y);\n // Returns the dot product of `x` and `y`, i.e. `x[0]*y[0] + x[1]*y[1]`\n float dot(vec2 x, vec2 y);\n // Returns the dot product of `x` and `y`, i.e. `x[0]*y[0] + x[1]*y[1] + x[2]*y[2]`\n float dot(vec3 x, vec3 y);\n // Returns the dot product of `x` and `y`, i.e. `x[0]*y[0] + x[1]*y[1] + x[2]*y[2] + x[3]*y[3]`\n float dot(vec4 x, vec4 y);\n\n // Returns the cross product of `x` and `y`, i.e.\n //\n // ```glslx\n // vec3(\n // x[1]*y[2] - y[1]*x[2],\n // x[2]*y[0] - y[2]*x[0],\n // x[0]*y[1] - y[0]*x[1])\n // ```\n vec3 cross(vec3 x, vec3 y);\n\n // Returns a vector in the same direction as `x` but with a length of 1.\n float normalize(float x);\n // Returns a vector in the same direction as `x` but with a length of 1.\n vec2 normalize(vec2 x);\n // Returns a vector in the same direction as `x` but with a length of 1.\n vec3 normalize(vec3 x);\n // Returns a vector in the same direction as `x` but with a length of 1.\n vec4 normalize(vec4 x);\n\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n float faceforward(float N, float I, float Nref);\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n vec2 faceforward(vec2 N, vec2 I, vec2 Nref);\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n vec3 faceforward(vec3 N, vec3 I, vec3 Nref);\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n vec4 faceforward(vec4 N, vec4 I, vec4 Nref);\n\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n float reflect(float I, float N);\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n vec2 reflect(vec2 I, vec2 N);\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n vec3 reflect(vec3 I, vec3 N);\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n vec4 reflect(vec4 I, vec4 N);\n\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return float(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n float refract(float I, float N, float eta);\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return vec2(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n vec2 refract(vec2 I, vec2 N, float eta);\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return vec3(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n vec3 refract(vec3 I, vec3 N, float eta);\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return vec4(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n vec4 refract(vec4 I, vec4 N, float eta);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Matrix Functions\n\n // Multiply matrix `x` by matrix `y` component-wise, i.e., `result[i][j]` is the scalar product of `x[i][j]` and `y[i][j]`.\n // Note: to get linear algebraic matrix multiplication, use the multiply operator (`*`).\n mat2 matrixCompMult(mat2 x, mat2 y);\n // Multiply matrix `x` by matrix `y` component-wise, i.e., `result[i][j]` is the scalar product of `x[i][j]` and `y[i][j]`.\n // Note: to get linear algebraic matrix multiplication, use the multiply operator (`*`).\n mat3 matrixCompMult(mat3 x, mat3 y);\n // Multiply matrix `x` by matrix `y` component-wise, i.e., `result[i][j]` is the scalar product of `x[i][j]` and `y[i][j]`.\n // Note: to get linear algebraic matrix multiplication, use the multiply operator (`*`).\n mat4 matrixCompMult(mat4 x, mat4 y);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Vector Relational Functions\n\n // Returns the component-wise compare of `x < y`.\n bvec2 lessThan(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x < y`.\n bvec2 lessThan(vec2 x, vec2 y);\n // Returns the component-wise compare of `x < y`.\n bvec3 lessThan(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x < y`.\n bvec3 lessThan(vec3 x, vec3 y);\n // Returns the component-wise compare of `x < y`.\n bvec4 lessThan(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x < y`.\n bvec4 lessThan(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x <= y`.\n bvec2 lessThanEqual(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x <= y`.\n bvec2 lessThanEqual(vec2 x, vec2 y);\n // Returns the component-wise compare of `x <= y`.\n bvec3 lessThanEqual(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x <= y`.\n bvec3 lessThanEqual(vec3 x, vec3 y);\n // Returns the component-wise compare of `x <= y`.\n bvec4 lessThanEqual(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x <= y`.\n bvec4 lessThanEqual(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x > y`.\n bvec2 greaterThan(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x > y`.\n bvec2 greaterThan(vec2 x, vec2 y);\n // Returns the component-wise compare of `x > y`.\n bvec3 greaterThan(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x > y`.\n bvec3 greaterThan(vec3 x, vec3 y);\n // Returns the component-wise compare of `x > y`.\n bvec4 greaterThan(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x > y`.\n bvec4 greaterThan(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x >= y`.\n bvec2 greaterThanEqual(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x >= y`.\n bvec2 greaterThanEqual(vec2 x, vec2 y);\n // Returns the component-wise compare of `x >= y`.\n bvec3 greaterThanEqual(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x >= y`.\n bvec3 greaterThanEqual(vec3 x, vec3 y);\n // Returns the component-wise compare of `x >= y`.\n bvec4 greaterThanEqual(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x >= y`.\n bvec4 greaterThanEqual(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x == y`.\n bvec2 equal(bvec2 x, bvec2 y);\n // Returns the component-wise compare of `x == y`.\n bvec2 equal(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x == y`.\n bvec2 equal(vec2 x, vec2 y);\n // Returns the component-wise compare of `x == y`.\n bvec3 equal(bvec3 x, bvec3 y);\n // Returns the component-wise compare of `x == y`.\n bvec3 equal(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x == y`.\n bvec3 equal(vec3 x, vec3 y);\n // Returns the component-wise compare of `x == y`.\n bvec4 equal(bvec4 x, bvec4 y);\n // Returns the component-wise compare of `x == y`.\n bvec4 equal(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x == y`.\n bvec4 equal(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x != y`.\n bvec2 notEqual(bvec2 x, bvec2 y);\n // Returns the component-wise compare of `x != y`.\n bvec2 notEqual(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x != y`.\n bvec2 notEqual(vec2 x, vec2 y);\n // Returns the component-wise compare of `x != y`.\n bvec3 notEqual(bvec3 x, bvec3 y);\n // Returns the component-wise compare of `x != y`.\n bvec3 notEqual(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x != y`.\n bvec3 notEqual(vec3 x, vec3 y);\n // Returns the component-wise compare of `x != y`.\n bvec4 notEqual(bvec4 x, bvec4 y);\n // Returns the component-wise compare of `x != y`.\n bvec4 notEqual(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x != y`.\n bvec4 notEqual(vec4 x, vec4 y);\n\n // Returns true if any component of `x` is `true`.\n bool any(bvec2 x);\n // Returns true if any component of `x` is `true`.\n bool any(bvec3 x);\n // Returns true if any component of `x` is `true`.\n bool any(bvec4 x);\n\n // Returns true only if all components of `x` are `true`.\n bool all(bvec2 x);\n // Returns true only if all components of `x` are `true`.\n bool all(bvec3 x);\n // Returns true only if all components of `x` are `true`.\n bool all(bvec4 x);\n\n // Returns the component-wise logical complement of `x`.\n bvec2 not(bvec2 x);\n // Returns the component-wise logical complement of `x`.\n bvec3 not(bvec3 x);\n // Returns the component-wise logical complement of `x`.\n bvec4 not(bvec4 x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Texture Lookup Functions\n\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n vec4 texture2D(sampler2D sampler, vec2 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n vec4 texture2D(sampler2D sampler, vec2 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n vec4 texture2DLod(sampler2D sampler, vec2 coord, float lod);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`.\n vec4 texture2DProj(sampler2D sampler, vec3 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`.\n vec4 texture2DProj(sampler2D sampler, vec3 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`.\n vec4 texture2DProjLod(sampler2D sampler, vec3 coord, float lod);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`. The third component of `coord` is ignored.\n vec4 texture2DProj(sampler2D sampler, vec4 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`. The third component of `coord` is ignored.\n vec4 texture2DProj(sampler2D sampler, vec4 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`. The third component of `coord` is ignored.\n vec4 texture2DProjLod(sampler2D sampler, vec4 coord, float lod);\n\n // Use the texture coordinate `coord` to do a texture lookup in the cube map texture currently bound to `sampler`.\n // The direction of `coord` is used to select which face to do a 2-dimensional texture lookup in.\n vec4 textureCube(samplerCube sampler, vec3 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the cube map texture currently bound to `sampler`.\n // The direction of `coord` is used to select which face to do a 2-dimensional texture lookup in.\n vec4 textureCube(samplerCube sampler, vec3 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the cube map texture currently bound to `sampler`.\n // The direction of `coord` is used to select which face to do a 2-dimensional texture lookup in.\n vec4 textureCubeLod(samplerCube sampler, vec3 coord, float lod);\n\n #extension GL_OES_standard_derivatives {\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n float dFdx(float v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec2 dFdx(vec2 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec3 dFdx(vec3 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec4 dFdx(vec4 v);\n\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n float dFdy(float v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec2 dFdy(vec2 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec3 dFdy(vec3 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec4 dFdy(vec4 v);\n\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n float fwidth(float v);\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n vec2 fwidth(vec2 v);\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n vec3 fwidth(vec3 v);\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n vec4 fwidth(vec4 v);\n }\n\n #extension GL_EXT_frag_depth {\n // Available only in the fragment language, `gl_FragDepthEXT` is an output variable that is used to establish the depth value for the current fragment.\n // If depth buffering is enabled and no shader writes to `gl_FragDepthEXT`, then the fixed function value for depth will be used (this value is contained\n // in the `z` component of `gl_FragCoord`) otherwise, the value written to `gl_FragDepthEXT` is used.\n //\n // If a shader statically assigns to `gl_FragDepthEXT`, then the value of the fragment's depth may be undefined for executions of the shader that take\n // that path. That is, if the set of linked fragment shaders statically contain a write to `gl_FragDepthEXT`, then it is responsible for always writing it.\n float gl_FragDepthEXT;\n }\n\n #extension GL_EXT_shader_texture_lod {\n vec4 texture2DGradEXT(sampler2D sampler, vec2 P, vec2 dPdx, vec2 dPdy);\n vec4 texture2DLodEXT(sampler2D sampler, vec2 coord, float lod);\n vec4 texture2DProjGradEXT(sampler2D sampler, vec3 P, vec2 dPdx, vec2 dPdy);\n vec4 texture2DProjGradEXT(sampler2D sampler, vec4 P, vec2 dPdx, vec2 dPdy);\n vec4 texture2DProjLodEXT(sampler2D sampler, vec3 coord, float lod);\n vec4 texture2DProjLodEXT(sampler2D sampler, vec4 coord, float lod);\n vec4 textureCubeGradEXT(samplerCube sampler, vec3 P, vec3 dPdx, vec3 dPdy);\n vec4 textureCubeLodEXT(samplerCube sampler, vec3 coord, float lod);\n }\n}\n"));
6
- for(var O=0,ha=b.length;O<ha;O=O+1|0){var d=b[O];d.c=Kc(a,d,0)}for(var e=new Lh(0),f=new Xh(1,null),h=new wh(c.e),m=new Vh(a,h),L=0,ia=b.length;L<ia;L=L+1|0){var l=b[L];jd(a,l.c,e,h,f,m)}if(nd(m,e),a.d)return null;for(var g=[],i=[],ca=0,ua=bf(f),aa=ua.length;ca<aa;ca=ca+1|0){for(var n=ua[ca],k=new Lh(0),p=new Xh(1,null),t=new wh(c.e),w=new Kh,v=new Vh(w,t),Z=0,$=b.length;Z<$;Z=Z+1|0){var q=b[Z];jd(w,q.c,k,t,p,v)}nd(v,k),cf(p,n),Bg(k,t,c),i.push(k),g.push(n.c)}for(var E=[],F=qg(new Th(c.c),i),H=0,ka=g.length;H<ka;H=H+1|0)E.push(new Zh(g[H],new Ah(i[H],c).a));return new xh(E,F)}function bf(a){for(var b=[],d=0,e=Array.from(a.c.values()),f=e.length;d<f;d=d+1|0){var c=e[d];c instanceof oc&&c.e&1024&&b.push(c)}return b}function cf(a,b){for(var e=0,f=Array.from(a.c.values()),h=f.length;e<h;e=e+1|0){var c=f[e];if(c.a^b.a)c.e&=-1025;else{c.c='main';var d=c.w;d&&(d.c=c.c)}}}function df(c,a){var b=a.l;c.b.push(c.b.length==0||Rc(c.b)),b&&ee(b.b)&&c.a.push(!1)}function ef(d,a){var b=a.l,c=d.b.pop();c&&(a.p=!0),b&&ee(b.b)&&!d.a.pop()&&(b.b==19&&Ra(b.g)||b.b==7&&Ra(b.i)||b.b==10&&(!Ca(b)||Ra(Ca(b))))&&hb(d.b,
7
- !1)}function Jd(e,a){if(Rc(e.b))switch(a.b){case 4:e.a.length&&hb(e.a,!0),hb(e.b,!1);break;case 15:case 6:case 5:hb(e.b,!1);break;case 12:var b=a.g,c=a.g.k,d=a.g.k.k;Ra(b)?c.p||hb(e.b,!1):Cb(b)&&d?d.p||hb(e.b,!1):c&&d&&!c.p&&!d.p&&hb(e.b,!1);break}}function ff(a,b){return Kd(a)||Kd(b)||a.b!=b.b&&(a.b==14||b.b==14||a.b==9||b.b==9)}function Kd(a){return a.b==11&&a.e.p!=null}function Ld(a,b){var c=a.toString(),d=a.toExponential();d.length<c.length&&(c=d);var e=c.indexOf('e'),f='';return ~e&&(f=c.slice(e),c=c.slice(0,e)),c=(+(+c).toFixed(6)).toString(),f==''&&c.indexOf('.')==-1&&(c+=b^1?'.0':'.'),b==1&&c.startsWith('0.')&&c!='0.'&&(c=c.slice(1)),b==1&&c.startsWith('-0.')&&c!='-0.'&&(c='-'+c.slice(2)),c+f}function gf(b,a){switch(a.b){case 11:case 16:return (a.e.e&2048)!=0;case 17:return ((a.h|0)&2048)!=0}return!1}function Tc(a){a.e||(a.b+=' ')}function Uc(a){a.e||(a.b=a.b.slice(2))}function Xa(i,a){switch(a.b){case 3:if(!a.g&&a.l)i.a+=';';else{i.a+='{'+i.c,Tc(i);for(var b=a.g;b;b=b.k)i.a+=i.b,Xa(i,b),i.a+=i.c;Uc(i),
8
- i.a+=i.b+'}'}break;case 4:i.a+='break;';break;case 5:i.a+='continue;';break;case 6:i.a+='discard;';break;case 7:i.a+='do',Yb(i,a.g,0),i.a+=i.c+i.b+'while'+i.d+'(',J(i,a.i,0),i.a+=');';break;case 8:J(i,a.g,0),i.a+=';';break;case 9:Md(i),i.a+='#extension '+a.m+i.d+':'+i.d;switch(a.h|0){case 1:i.a+='disable';break;case 2:i.a+='enable';break;case 3:i.a+='require';break;case 4:i.a+='warn';break}Nd(i);break;case 10:i.a+='for'+i.d+'(',kb(a)?kb(a).b^17?(J(i,kb(a),0),i.a+=';'):Xa(i,kb(a)):i.a+=';',Ca(a)&&(i.a+=i.d,J(i,Ca(a),0)),i.a+=';',Fc(a)&&(i.a+=i.d,J(i,Fc(a),0)),i.a+=')',Yb(i,a.i,1);break;case 11:var c=a.e;i.a+=$a(c.e),J(i,c.k,0),i.a+=' ',i.a+=c.c,i.a+='(';for(var n=0,k=c.n,p=k.length;n<p;n=n+1|0){var d=k[n];d!=c.n[0]&&(i.a+=','+i.d),i.a+=$a(d.e),J(i,d.q,0),i.a+=' ',Vc(i,d)}i.a+=')',c.p?(i.a+=i.d,Xa(i,c.p)):i.a+=';';break;case 12:i.a+='if'+i.d+'(',J(i,a.g,0),i.a+=')',Yb(i,a.g.k,1),a.g.k.k&&(i.a+=i.c+i.b+'else',a.g.k.k.b^12?Yb(i,a.g.k.k,0):(i.a+=' ',Xa(i,a.g.k.k)));break;case 14:i.a+='precision ',i.a+=$a(a.h|0),J(i,
9
- a.g,0),i.a+=';';break;case 15:var e=a.g;i.a+='return',e&&(Tf(e.b)||(i.a+=' '),J(i,e,0)),i.a+=';';break;case 16:var f=a.e;i.a+=$a(f.e),i.a+='struct '+f.c+i.d+'{'+i.c,Tc(i);for(var h=a.g.g;h;h=h.k)i.a+=i.b,Xa(i,h),i.a+=i.c;if(Uc(i),i.a+=i.b+'}',a.g.k)for(var m=a.g.k.g.k;m;m=m.k)i.a+=m.n.n?','+i.d:i.d,Vc(i,m.e);i.a+=';';break;case 17:i.a+=$a(a.h|0),J(i,a.g,0);for(var l=a.g.k;l;l=l.k){var g=l.e;i.a+=l.n.n?','+i.d:' ',Vc(i,g)}i.a+=';';break;case 18:Md(i),i.a+='#version '+(a.h|0),Nd(i);break;case 19:i.a+='while'+i.d+'(',J(i,a.g,0),i.a+=')',Yb(i,a.i,1);break;default:i.a+=Ug[a.b];break}}function Md(a){a.a!=''&&!a.a.endsWith('\n')&&(a.a+='\n')}function Nd(a){a.e&&(a.a+='\n')}function Yb(c,a,b){a.b^3?(c.a+=c.e&&!b?' ':c.c,Tc(c),c.a+=c.b,Xa(c,a),Uc(c)):(c.a+=c.d,Xa(c,a))}function Od(c,a){for(var b=a;b;b=b.k)b!=a&&(c.a+=','+c.d),J(c,b,1)}function Vc(b,a){b.a+=a.c,a.F&&(b.a+='[',J(b,a.F,0),b.a+=']'),P(a)&&(b.a+=b.d+'='+b.d,J(b,P(a),1))}function J(c,a,b){switch(a.b){case 20:J(c,a.g,15),c.a+='(',Od(c,a.g.k),c.a+=')';break;case 21:
10
- J(c,a.g,16),c.a+='.',c.a+=a.e?a.e.c:a.m;break;case 22:2<b&&(c.a+='('),J(c,a.g,3),c.a+=c.d+'?'+c.d,J(c,a.g.k,2),c.a+=c.d+':'+c.d,J(c,a.i,2),2<b&&(c.a+=')');break;case 23:c.a+=a.e.c;break;case 25:0<b&&(c.a+='('),Od(c,a.g),0<b&&(c.a+=')');break;case 26:c.a+=Je(a.f).a.c;break;case 28:c.a+=(!!a.h).toString();break;case 29:c.a+=Ld(a.h,c.e?1:0);break;case 30:c.a+=(a.h|0).toString();break;case 43:J(c,a.g,16),c.a+='[',J(c,a.i,0),c.a+=']';break;case 31:Zb(c,'-',a,b);break;case 32:Zb(c,'!',a,b);break;case 33:Zb(c,'+',a,b);break;case 34:Zb(c,'--',a,b);break;case 35:Zb(c,'++',a,b);break;case 36:Pd(c,'--',a,b);break;case 37:Pd(c,'++',a,b);break;case 38:V(c,'+',a,b,12);break;case 39:V(c,'/',a,b,13);break;case 40:V(c,'==',a,b,10);break;case 41:V(c,'>',a,b,10);break;case 42:V(c,'>=',a,b,10);break;case 44:V(c,'<',a,b,10);break;case 45:V(c,'<=',a,b,10);break;case 46:V(c,'&&',a,b,5);break;case 47:V(c,'||',a,b,3);break;case 48:V(c,'^^',a,b,4);break;case 49:V(c,'*',a,b,13);break;case 50:V(c,'!=',a,b,10);break;case 51:V(c,'-',a,b,12);
11
- break;case 52:V(c,'=',a,b,2);break;case 53:V(c,'+=',a,b,2);break;case 54:V(c,'/=',a,b,2);break;case 55:V(c,'*=',a,b,2);break;case 56:V(c,'-=',a,b,2);break;default:c.a+=Ug[a.b];break}}function Zb(f,a,b,c){var d=b.g,e=d.b;f.a+=a,(a.charCodeAt(0)==45&&(e==31||e==34||Yf(d))||a.charCodeAt(0)==43&&(e==33||e==35))&&(f.a+=' '),J(f,d,14)}function Pd(d,a,b,c){J(d,b.g,15),d.a+=a}function V(f,a,b,c,d){var e=Cc(b.b);d<c&&(f.a+='('),J(f,b.g,d+(e|0)|0),f.a+=f.d+a+f.d,J(f,b.i,d+(!e|0)|0),d<c&&(f.a+=')')}function G(a){if(a.f==M)return null;switch(a.b){case 30:case 29:case 28:return Ya(a);case 23:return hf(a);case 25:return jf(a);case 22:return kf(a);case 21:return lf(a);case 43:return mf(a);case 20:return nf(a);case 31:return Vd(a,function(b){return-b},function(c){return -c|0});case 32:return uf(a,function(d){return!d});case 33:return Vd(a,function(e){return+e},function(f){return+f});case 38:return Xc(a,function(h,m){return h+m},function(l,g){return l+g|0});case 51:return Xc(a,function(i,n){return i-n},function(k,p){return k-p|0});
12
- case 49:return of(a);case 39:return Xc(a,function(t,w){return w!=0?t/w:0},function(v,q){return q?v/q|0:0});case 40:case 50:return rf(a);case 46:return Wc(a,function(E,F){return E&&F});case 47:return Wc(a,function(H,O){return H||O});case 48:return Wc(a,function(ha,L){return ha!=L});case 41:return uc(a,function(ia,Z){return ia>Z});case 42:return uc(a,function($,ca){return $>=ca});case 44:return uc(a,function(ua,aa){return ua<aa});case 45:return uc(a,function(ka,va){return ka<=va})}return null}function hf(a){var b=a.e;if(b&&b.e&2){if(b.h)return Ya(b.h);if(b.v)return s(new Lh(27),a.f)}return null}function jf(a){for(var b=a.g;b;b=b.k){var c=G(b);if(!c||b==a.i)return c}return null}function kf(a){var b=G(a.g),c=G(a.g.k),d=G(a.i);return b&&b.b==28&&c&&d?!b.h?d:c:null}function lf(a){var b=G(a.g);if(b&&b.b==20){var c=b.f,d=a.m;if(xd(c))for(var e=d.length,f=Ea(c),t=0,w=sd(f),v=w.length;t<v;t=t+1|0){var h=w[t];if(~h.indexOf(d[0])){if(e==1)return r(ac(b,1+h.indexOf(d)|0));for(var m=td(fa(c),e),l=sa(m),g=0;g<e;g=g+1|0)o(l,Ya(ac(b,
13
- 1+h.indexOf(d[g])|0)));return l}}else if(c.a&&c.a instanceof Tb)for(var i=c.a,n=i.i,k=0,q=n.length;k<q;k=k+1|0){var p=n[k];if(p.c==d)return r(ac(b,1+k|0))}}return null}function mf(a){var b=G(a.g),c=G(a.i);if(b&&b.b==20&&c&&c.b==30){var d=b.f;if(xd(d)){var e=Sa(d),f=c.h|0;if(-1<f&&f<e)return r(ac(b,f+1|0))}else if(ab(d)){var h=Sa(d),m=c.h|0;if(-1<m&&m<h){for(var l=wd(d),g=sa(l),i=ac(b,sh(m,h)),n=0;n<h;n=n+1|0)o(g,r(i.k));return g}}}return null}function nf(a){var b=a.g;if(b.b^26)return null;for(var c=b.f,d=fa(c),e=0,f=[],h=0,m=b.k;m;m=m.k){var l=G(m);if(!l)return null;if(l.b==20&&d&&fa(l.g.f))for(var g=l.g.k;g;g=g.k){var i=Qd(d,g);if(!i)return null;f.push(i)}else{if(d&&(l=Qd(d,l),!l))return null;f.push(l)}ab(l.f)&&(e=Sa(l.f)),h=h+1|0}return ab(c)&&e&&h^1?null:fa(c)?pf(f,c,ab(c)?e:0):c.a&&c.a instanceof Tb?qf(f,c):null}function Bb(a){for(var b=[],c=a.g.k;c;c=c.k)b.push(c.h);return b}function of(a){var va,b=G(a.g),c=G(a.i),d=b&&b.f,e=c&&c.f;if(b&&c){if(d==Fa&&e==ob||d==Ga&&e==pb||d==Ha&&e==qb){for(var f=Sa(d),h=sa(d),m=Bb(b),l=Bb(c),g=0;g<f;g=g+1|0){
14
- for(var i=0,n=0;n<f;n=n+1|0)i+=m[n]*l[n+sh(g,f)|0];o(h,s(ma(new Lh(29),i),da))}return h}if(d==ob&&e==Fa||d==pb&&e==Ga||d==qb&&e==Ha){for(var k=Sa(d),p=sa(e),t=Bb(b),w=Bb(c),v=0;v<k;v=v+1|0){for(var q=0,E=0;E<k;E=E+1|0)q+=t[v+sh(E,k)|0]*w[E];o(p,s(ma(new Lh(29),q),da))}return p}if(ab(d)&&e==d){for(var F=Sa(d),H=sa(d),O=Bb(b),ha=Bb(c),L=0;L<F;L=L+1|0)for(var ia=0;ia<F;ia=ia+1|0){for(var Z=0,$=0;$<F;$=$+1|0)Z+=O[ia+sh($,F)|0]*ha[$+sh(L,F)|0];o(H,s(ma(new Lh(29),Z),da))}return H}return (va=Td(b,c,function(ca,ua){return ca*ua}))||Ud(b,c,function(aa,ka){return sh(aa,ka)})}return null}function Qd(a,b){var c=0;switch(b.b){case 28:c=+!!b.h;break;case 30:c=b.h|0;break;case 29:c=b.h;break;default:return null}switch(a){case Y:return s(Ba(new Lh(28),!!c),Y);case ga:return s(_(new Lh(30),c|0),ga);case da:return s(ma(new Lh(29),c),da)}return null}function pf(a,b,c){var d=Ea(b),e=fa(b),f=sa(b);if(a.length^1){if(c){for(var n=Sa(b),k=0;k<n;k=k+1|0)for(var p=0;p<n;p=p+1|0)o(f,p<c&&k<c?a[p+sh(k,c)|0]:s(ma(new Lh(29),p^k?0:1),da))}
15
- else{if(a.length<d)return null;for(var t=0;t<d;t=t+1|0){var w=a[t];if(w.f!=e)return null;o(f,w)}}}else{var h=a[0];if(h.f!=e)return null;for(var m=ab(b),l=Sa(b),g=0;g<d;g=g+1|0){var i=m&&(g%(l+1|0)|0)!=0;o(f,i?s(ma(new Lh(29),0),da):Ya(h))}}return wd(b)?f:r(f.i)}function qf(a,b){var c=b.a.i,d=sa(b);if(a.length^c.length)return null;for(var e=0,f=a.length;e<f;e=e+1|0){if(a[e].f!=c[e].q.f)return null;o(d,a[e])}return d}function rf(a){var b=G(a.g),c=G(a.i);if(b&&c){var d=oa(b,c);return s(Ba(new Lh(28),a.b^40?!d:d),Y)}return null}function Rd(a,b,c,d){if(a.b==20&&a.g.b==26&&fa(a.g.f)==b){for(var e=sa(a.g.f),f=a.g.k;f;f=f.k){var h=G(f);if(!h||h.b^c)return null;o(e,d(h))}return e}return null}function sf(a,b){return a.b^29?Rd(a,da,29,function(c){return s(ma(new Lh(29),b(c.h)),da)}):s(ma(new Lh(29),b(a.h)),da)}function tf(a,b){return a.b^30?Rd(a,ga,30,function(c){return s(_(new Lh(30),b(c.h|0)),ga)}):s(_(new Lh(30),b(a.h|0)),ga)}function Sd(a,b,c,d,e){var f=a.b==20&&a.g.b==26&&fa(a.g.f)==c,h=b.b==20&&b.g.b==26&&fa(b.g.f)==c;
16
- if(f&&h&&b.f==a.f){for(var m=sa(a.f),l=a.g.k,g=b.g.k;l&&g;){var i=G(l),n=G(g);if(!i||i.b^d||!n||n.b^d)return null;o(m,e(i,n)),l=l.k,g=g.k}if(!l&&!g)return m}else if(f&&b.b==d){for(var k=sa(a.f),p=a.g.k;p;p=p.k){var t=G(p);if(!t||t.b^d)return null;o(k,e(t,b))}return k}else if(a.b==d&&h){for(var w=sa(b.f),v=b.g.k;v;v=v.k){var q=G(v);if(!q||q.b^d)return null;o(w,e(a,q))}return w}return null}function Td(a,b,c){return a.b==29&&b.b==29?s(ma(new Lh(29),c(a.h,b.h)),da):Sd(a,b,da,29,function(d,e){return s(ma(new Lh(29),c(d.h,e.h)),da)})}function Ud(a,b,c){return a.b==30&&b.b==30?s(_(new Lh(30),c(a.h|0,b.h|0)),ga):Sd(a,b,ga,30,function(d,e){return s(_(new Lh(30),c(d.h|0,e.h|0)),ga)})}function uf(a,b){var c=G(a.g);return c&&c.b==28?s(Ba(new Lh(28),b(!!c.h)),Y):null}function Vd(a,b,c){var e,d=G(a.g);return d&&((e=sf(d,b))||tf(d,c))}function Wc(a,b){var c=G(a.g),d=G(a.i);return c&&d&&c.b==28&&d.b==28?s(Ba(new Lh(28),b(!!c.h,!!d.h)),Y):null}function Xc(a,b,c){var f,d=G(a.g),e=G(a.i);return d&&e?(f=Td(d,e,b))||Ud(d,e,c):null}
17
- function uc(a,b){var c=G(a.g),d=G(a.i);if(c&&d){if(c.b==29&&d.b==29)return s(Ba(new Lh(28),b(c.h,d.h)),Y);if(c.b==30&&d.b==30)return s(Ba(new Lh(28),b(c.h|0,d.h|0)),Y)}return null}function Wd(a,b,c){for(var d=0,e=0,f=a.length;e<f;){var h=a.charCodeAt(e);e=e+1|0,vc(h)&&(d=d+1|0,h==13&&e<f&&a.charCodeAt(e)==10&&(e=e+1|0))}return d>2&&(d=2),Xb(c,d)}function vf(a,b,c){switch(c){case 48:switch(b){case 65:return!0;case 96:return!1}break;case 47:switch(b){case 62:return!0;case 96:return!1}break;case 65:if(b==65)return!0;break;case 62:if(b==62)return!0;break;case 85:if(vd(b)||b==88)return!1;break;case 84:if(vd(b)||b==88)return!1;break;case 81:case 90:case 89:case 88:case 82:return!1;case 87:if(b==83)return!1;break}switch(b){case 85:case 84:case 82:case 49:case 46:return!1;case 65:case 62:switch(a){case 99:case 85:case 84:case 81:case 80:case 90:case 49:case 46:case 32:case 12:return!1}if(Hg(a))return!1;break;case 48:case 47:if(c==96)return!1;break}return!0}function vc(a){return a==10||a==13}function wf(a){for(var b=0,c=a.length;b<c;b=b+1|0)if(vc(a.charCodeAt(b)))return!0;
18
- return!1}function Xd(a){return a==32||a==9}function wc(a){for(var b=0,c=a.length;b<c;b=b+1|0)if(!Xd(a.charCodeAt(b)))return!1;return!0}function xf(a){for(var b=a.length;Xd(a.charCodeAt(b-1|0));)b=b-1|0;return a.slice(0,b)}function yf(a,b,c,d){for(var e=[],f=0,h=0,m=a.length;h<m;h=h+1|0){var l=a.charCodeAt(h);vc(l)&&(e.push(a.slice(f,h)),l==13&&(h+1|0)<m&&a.charCodeAt(h+1|0)==10&&(h=h+1|0),f=h+1|0)}e.push(a.slice(f));for(var g=b.length;g>0&&!vc(b.charCodeAt(g-1|0));)g=g-1|0;for(var i=b.slice(g),n=i,q=0,E=e.slice(1),F=E.length;q<F;q=q+1|0){var k=E[q];if(!wc(k)){for(var p=0,t=k.length;p<t&&p<n.length&&k.charCodeAt(p)==n.charCodeAt(p);)p=p+1|0;n=n.slice(0,p)}}for(var w='',H=0,O=e.length;H<O;H=H+1|0){var v=e[H];w==''?(wc(i)&&(w+=i.slice(n.length)),w+=v):(w+=d,wc(v)||(w+=c+v.slice(n.length)))}return w}function zf(a,b,c,d){var e=new Kh,f=new Zh('<stdin>',a),h=Kc(e,f,1);if(e.d)return a;var m='',l=99,g=99,i=0,n=0,k=!0,p=0,t=null,w=function(v){return!wc(a.slice(h[v-1|0].a.c,h[v].a.b))},q=function(E,F){switch(E){case 90:case 87:
19
- return!0;case 4:case 9:case 10:case 11:case 12:case 15:case 17:case 32:case 43:return!F}return!1},H=null,O=function(){for(var ha=1,L=p;L<h.length;L=L+1|0){switch(h[L].b){case 0:case 1:continue;case 83:ha=0;break}break}n=n+ha|0,H(),n=n-ha|0},ia=function(){var Z=1;return h[p].b==85&&w(p+1|0)&&(Z=0),n=n+Z|0,t(function($){return $==85})?(n=n-Z|0,!0):(n=n-Z|0,!1)};H=function(){for(;t(function(ca){return ca==0||ca==1}););switch(h[p].b){case 99:case 87:return!1;case 45:case 44:t(function(ua){return!0});break;case 17:t(function(aa){return!0}),ia()&&O(),h[p].b^12||H();break;case 15:case 43:t(function(ka){return!0}),ia()&&O();break;case 11:t(function(va){return!0}),O(),t(function(Ua){return Ua==43})&&(ia(),t(function(la){return la==90}));break;case 12:if(t(function(rb){return!0}),h[p].b^17)O();else{var La=w(p);La&&(n=n+1|0),t(function(Va){return!0}),ia()&&O(),La&&(n=n-1|0)}break;case 83:case 90:t(function(wa){return!0});break;case 91:case 92:case 93:case 94:for(t(function(xa){return!0});t(function(eb){return!w(p)}););break;
20
- default:var Ia=vd(h[p].b);if(t(function(Ja){return!0}),Ia&&t(function(fb){return fb==96})&&t(function(sb){return sb==85}))t(function(tb){return tb==83})||t(function(bb){return bb==90});else{for(var cb=!1;!cb&&w(p)&&(cb=!0,n=n+1|0),t(function(Ub){return!q(Ub,!1)}););t(function(ub){return ub==90}),cb&&(n=n-1|0)}break}return!0};var ic=function(){for(var Ka=[],Wa=p;Wa<h.length;){var qc=h[Wa].b;switch(qc){case 83:case 84:case 85:Ka.push(qc);break;case 87:if(!Ka.length)return Wa;if(Ka.pop()^83)return-1;break;case 88:if(!Ka.length||Ka.pop()^84)return-1;break;case 89:if(!Ka.length||Ka.pop()^85)return-1;break}Wa=Wa+1|0}return-1},jc=-1,Oc=function(){var Ob=ic(),Pb=Ob!=-1&&wf(a.slice(h[p-1|0].a.c,h[Ob].a.b));for(Pb&&(jc=p),n=n+1|0;H(););n=n-1|0,Pb&&(jc=p),t(function(kc){return kc==87})},Qb=function(){for(n=n+1|0;t(function(Rb){return Rb!=89}););n=n-1|0,t(function(yb){return yb==89})},Sb=function(){for(n=n+1|0;t(function(Pc){return Pc!=88}););n=n-1|0,t(function(Vb){return Vb==88})};for(t=function(rc){var Ta=h[p];if(!rc(Ta.b)||Ta.b==99)return!1;
21
- var lc=jc^p?g^99?Wd(a.slice(i,Ta.a.b),b,c):'':'\n';p=p+1|0,m+=lc,lc!=''&&(k=!0),k?m+=Xb(b,n):vf(l,g,Ta.b)&&(m+=' ');var Ma=N(Ta.a);switch(Ta.b){case 0:Ma=xf(Ma);break;case 1:Ma=yf(Ma,a.slice(0,Ta.a.b),Xb(b,n),c);break}m+=Ma,l=g,g=Ta.b,i=Ta.a.c,k=!1;switch(Ta.b){case 83:Oc();break;case 85:Qb();break;case 84:Sb();break}return!0};H()||t(function(zb){return zb!=99}););var gb=Wd(a.slice(i),b,c);switch(d){case 0:gb!=''&&(m+=c);break;case 2:m!=''&&(m+=c);break}return m}function Af(a){return a.f!=null?new Bh(C(a.h)+' '+a.f+';',''):a.d&&new Bh(xc(a.d),yc(a.d.f))}function zc(b,a){return a.a==b.a&&fc(a,b.b)}function Yc(b,a){return zc(b,a.b)?(b.c=K(a),b.d=a,b.e=a.b,!0):!1}function Zc(b,a){return Yc(b,a)||Pa(b,a.q)||Pa(b,a.F)||Pa(b,P(a))}function Bf(c,a){for(var d=0,e=a.n,f=e.length;d<f;d=d+1|0){var b=e[d];if(Zc(c,b))return!0}return Yc(c,a)||Pa(c,a.k)||Pa(c,a.p)}function Cf(c,a){for(var d=0,e=a.i,f=e.length;d<f;d=d+1|0){var b=e[d];if(Zc(c,b))return!0}return Yc(c,a)}function Pa(c,a){var d;if(!a)return!1;for(var b=a.g;b;b=b.k)if(Pa(c,
22
- b))return!0;switch(a.b){case 23:if(zc(c,a.c))return c.c=a.f,c.d=a.e,c.e=a.c,!0;break;case 26:if(zc(c,a.c))return c.c=a.f,c.d=((d=c.c).b?d.b:c.c).a,c.e=a.c,!0;break;case 21:if(zc(c,a.d))return c.c=a.f,xd(a.g.f)?(c.f=a.m,c.h=a.f):c.d=a.e,c.e=a.d,!0;break;case 2:return Zc(c,a.e);case 11:return Bf(c,a.e);case 16:return Cf(c,a.e)}return!1}function Zd(d,a){switch(a.b){case 16:case 11:_d(d,a.e);break;case 17:for(var b=a.g.k;b;b=b.k)_d(d,b.e);break;case 0:for(var c=a.g;c;c=c.k)Zd(d,c);break}}function _d(b,a){a.b&&a.b.a==b.a&&b.b.push(a)}function Df(m,a){var b=new Ch(m.a,m.b);if(Pa(b,a),m.d=b.d,m.d){jb(m,a);var c=null;m.c.sort(function(d,e){return d.a==e.a?Qc(d.b,e.b):_e(d.a.a,e.a.a)}),Ab(m.c,function(f){var h=c;return c=f,h!=null&&ng(c,h)})}}function ib(c,a,b){b==c.d&&a&&N(a)==c.d.c&&c.c.push(a)}function _c(b,a){ib(b,a.b,a),jb(b,a.q),jb(b,a.F),jb(b,P(a))}function Ef(c,a){ib(c,a.b,a),ib(c,a.b,a.w),jb(c,a.k),jb(c,a.p);for(var d=0,e=a.n,f=e.length;d<f;d=d+1|0){var b=e[d];_c(c,b)}}function Ff(c,a){ib(c,a.b,a);for(var d=0,e=a.i,f=e.length;d<f;d=d+1|0){
23
- var b=e[d];_c(c,b)}}function jb(c,a){if(a){for(var b=a.g;b;b=b.k)jb(c,b);switch(a.b){case 23:ib(c,a.c,a.e);break;case 21:ib(c,a.d,a.e);break;case 26:ib(c,a.c,a.f.a);break;case 2:_c(c,a.e);break;case 11:Ef(c,a.e);break;case 16:Ff(c,a.e);break}}}function Gf(c,a){Aa(c,'keyword','false'),Aa(c,'keyword','true'),Aa(c,'keyword','void');for(var d=0,e=Pg.length;d<e;d=d+1|0){var b=Pg[d];Aa(c,'struct',b.a.c).c=xc(b.a)}$c(c,a,!0)}function $d(b,a){return a!=null&&a.a==b.a&&fc(a,b.b)}function Aa(d,a,b){var c=null;return d.c.has(b)?c=d.c.get(b):(c=new Fh(a,b),d.d.push(c),Na(d.c,b,c)),c}function $b(d,a){var b=a instanceof oc?'function':a instanceof Tb?'struct':'variable',c=Aa(d,b,a.c);c.c!=''?c.c+='\n':c.d=yc(a.f),c.c+=xc(a)}function $c(E,a,b){if(!a)return!1;var c=$d(E,a.c);switch(a.b){case 11:if($b(E,a.e),c){var d=a.e;Aa(E,'keyword','discard'),Aa(E,'keyword','return');for(var F=0,H=d.n,O=H.length;F<O;F=F+1|0){var e=H[F];$b(E,e)}$c(E,d.p,!1)}break;case 2:$b(E,a.e);break;case 16:$b(E,a.e);break;case 10:case 19:case 7:c&&(Aa(E,
24
- 'keyword','break'),Aa(E,'keyword','continue'));break;case 21:var f=a.g;if(c&&!$d(E,f.c)){E.d=[];var h=f.f;switch(h){case Lb:case vb:case Fa:case Mb:case wb:case Ga:case Nb:case xb:case Ha:for(var ha=0,L=sd(Ea(h)),ia=L.length;ha<ia;ha=ha+1|0)for(var m=L[ha],l=1;l<5;l=l+1|0){for(var g=[],i=0;i<l;i=i+1|0)g.push(0);for(;;){for(var n='',k=0;k<l;k=k+1|0)n+=m[g[k]];var p=td(fa(h),n.length).a;Aa(E,'variable',n).c=p.c+' '+n+';';for(var t=0;t<l;){var w=g[t];if((w=w+1|0)^m.length||(w=0),g[t]=w,w)break;t=t+1|0}if(t==l)break}}break;default:if(h.a&&h.a instanceof Tb)for(var Z=0,$=h.a.i,ca=$.length;Z<ca;Z=Z+1|0){var v=$[Z];$b(E,v)}break}return!0}break}if(b||c||a.b==17)for(var q=a.g;q;q=q.k)if($c(E,q,!1))return!0;return c}function ae(b,a){return a!=null&&a.a==b.a&&fc(a,b.b)}function ad(la,a){if(!a||a.b&&!ae(la,a.c))return!1;for(var b=a.g;b;b=b.k)if(ad(la,b))return!0;switch(a.b){case 11:return ad(la,a.e.p),!0;case 20:var c=a.g;if(!ae(la,c.c)){for(var d=c.k,e=c.f,f=e.a,h=[],m=d;m;m=m.k)h.push(m);if(f instanceof oc){for(var l=[],g=f;g;g=g.t)~l.indexOf(g.w)||l.push(g);
25
- l.reverse();for(var rb=0,La=l.length;rb<La;rb=rb+1|0){var i=l[rb];la.c.push(new Hh(xc(i),i.n.map(function(n){return _b(n)}),yc(i.f)))}if(la.c.length){la.e=0;for(var k=[],p=0;p<l.length;p=p+1|0)k.push(p);for(var t=h.length;t>0;t=t-1|0){for(var w=[],Va=0,wa=k,xa=wa.length;Va<xa;Va=Va+1|0){var v=wa[Va];l[v].n.length>=t&&w.push(v)}if(w.length){k=w;break}}if(k.length>1){var q=k.slice();Ab(q,function(E){for(var F=l[E].n,H=0,eb=Math.min(F.length,h.length);H<eb;H=H+1|0){var O=F[H].q.f,ha=h[H].f;if(ha!=M&&O!=ha)return!0}return!1}),q.length||(q=k.slice(),Ab(q,function(L){for(var ia=l[L].n,Z=0,Ia=Math.min(ia.length,h.length);Z<Ia;Z=Z+1|0){var $=ia[Z].q.f,ca=h[Z].f,ua=Ea($),aa=Ea(ca);if(ca!=M&&$!=ca&&(!ua||!aa||ua^aa))return!0}return!1})),q.length&&(k=q)}k.length&&(la.e=k[0])}}if(f instanceof Tb&&!fa(e)){var ka=f.i.map(function(va){return _b(va)});la.c.push(new Hh(f.c+'('+ka.join(', ')+');',ka,yc(f.f))),la.e=0}if(h.length){la.d=0;for(var Ja=0,fb=h.length;Ja<fb;Ja=Ja+1|0){var Ua=h[Ja];if(la.b<=Ua.c.c||!Ua.k)break;la.d=la.d+1|0}}
26
- return!0}break}return!1}function Yd(a){switch(a.b){case 30:return (a.h|0).toString();case 28:return (!!a.h).toString();case 29:return Ld(a.h,0);case 20:for(var b=a.g,c=C(a.f)+'(',d=b.k;d;d=d.k)d.n!=b&&(c+=', '),c+=Yd(d);return c+')'}return null}function xc(a){if(a instanceof Tb){var b=a,c=$a(b.e)+'struct '+a.c;if(b.a>-1){c+=' {\n';for(var i=0,n=b.i,k=n.length;i<k;i=i+1|0){var d=n[i];c+=' '+_b(d)+';\n'}c+='}'}return c+';'}if(a instanceof Ie){var e=a,f=_b(e);if(e.h){var h=Yd(e.h);h!=null&&(f+=' = '+h)}return f+';'}if(a instanceof oc){for(var m=a,l=$a(m.e)+C(m.k.f)+' '+a.c+'(',p=0,t=m.n,w=t.length;p<w;p=p+1|0){var g=t[p];g!=m.n[0]&&(l+=', '),l+=_b(g)}return l+');'}return null}function _b(a){var b=a.q.f,c=$a(a.e)+C(b.b||b)+' '+a.c;return b.b&&(c+=b.c?'['+b.c+']':'[]'),c}function yc(a){var b='';if(a)for(var f=0,h=a.length;f<h;f=f+1|0){var c=a[f],d=0,e=c.length;for(c.startsWith('//')?d=d+2|0:c.startsWith('/*')&&(d=d+2|0,e=e-2|0);d<e&&c.charCodeAt(d)==32;)d=d+1|0;for(;e>d&&c.charCodeAt(e-1|0)==32;)e=e-1|0;b!=''&&(b+='\n'),
27
- b+=c.slice(d,e)}return b}function be(a,b,c){if(!b)return a+': '+c+'\n';var d=ld(b,0);return kd(b)+': '+a+': '+c+'\n'+d.a+'\n'+d.b+'\n'}function Hf(c){for(var a=new ph,d=0,e=c.a,f=e.length;d<f;d=d+1|0){var b=e[d];a.a+=be(b.a?'warning':'error',b.b,b.c),b.d&&(a.a+=be('note',b.d,b.e))}return a.a}function u(c,a,b){(!c.e||c.e.b^a.b)&&(c.e=a,c.a.push(new Jh(0,a,b)),c.d=c.d+1|0)}function If(c,a,b){c.a.push(new Jh(1,a,b)),c.c=c.c+1|0}function Ac(d,a,b){var c=Rc(d.a);c.d=a,c.e=b}function Jf(b,a){u(b,a,'"'+N(a)+'" is a reserved word')}function Kf(b,a){u(b,a.a,'Unexpected '+Qe[a.b])}function Lf(b,a){u(b,a,'There is no symbol called "'+N(a)+'" in the current scope')}function bd(c,a,b){u(c,a,'There is already a symbol called "'+N(a)+'" in the current scope'),Ac(c,b,'The previous definition of "'+N(b)+'" is here')}function Mf(f,a,b,c,d,e){u(f,a,'Cannot change the return type of "'+b+'" to type "'+C(c)+'"'),Ac(f,e,'The forward declaration of "'+b+'" has a return type of "'+C(d)+'"')}function ce(b,a){u(b,a,'The operator "'+N(a)+'" is reserved and cannot be used')}
28
- function Nf(e,a,b,c,d){u(e,a,'The constructor for type "'+C(b)+'" only takes '+c+' argument'+(c^1?'s':'')+' and this argument would bring the total to '+d)}function Of(d,a,b,c){u(d,a,'Cannot construct type "'+C(b)+'" with '+c+' argument'+(c^1?'s':''))}function Pf(f,a,b,c,d,e){u(f,a,'Expected '+b+' argument'+(b^1?'s':'')+' but found '+c+' argument'+(c^1?'s':'')+' when calling function "'+d+'"'),e&&Ac(f,e,'The definition of function "'+d+'" is here')}function Qf(f,a,b,c,d,e){u(f,a,'Expected '+b+' argument'+(b^1?'s':'')+' but found '+c+' argument'+(c^1?'s':'')+' when constructing type "'+d+'"'),e&&Ac(f,e,'The definition of struct "'+d+'" is here')}function Rf(c,a,b){b.b?u(c,a,'Cannot use a conditional expression with array type "'+C(b)+'"'):u(c,a,'Cannot use a conditional expression with type "'+C(b)+'" because it contains an array')}function de(c,a,b){b.b?u(c,a,'Cannot assign to array type "'+C(b)+'"'):u(c,a,'Cannot assign to type "'+C(b)+'" because it contains an array')}function Sf(e,a,b,c,d){c==d?u(e,a,'There is no operator "'+b+'" defined for type "'+C(c)+'"'):u(e,
29
- a,'No binary operator "'+b+'" for type "'+C(c)+'" and type "'+C(d)+'"')}function fe(b,a){b.b=a.b,b.c=a.c,b.d=a.d,b.e=a.e,b.f=a.f,b.h=a.h,b.m=a.m}function ge(b){var a=new Lh(b.b);return fe(a,b),a}function fd(b){for(var a=ge(b);b.g;)o(a,r(b.g));return a}function Ya(c){for(var a=ge(c),b=c.g;b;b=b.k)o(a,Ya(b));return a}function I(b,a){a!=b&&(fe(b,a),Wf(b),Vf(b,a))}function he(a){return a.g!=null&&a.g==a.i}function ac(c,a){for(var b=c.g;a;)b=b.k,a=a-1|0;return b}function s(b,a){return b.f=a,b}function Dc(b,a){return b.e=a,b}function Ba(b,a){return b.h=+a,b}function _(b,a){return b.h=a,b}function ma(b,a){return b.h=a,b}function bc(b,a){return b.m=a,b}function x(b,a){return b.c=a,b}function Qa(b,a){return b.d=a,b}function o(b,a){return a?(a.l=b,b.g?(a.n=b.i,b.i.k=a,b.i=a):b.i=b.g=a,b):b}function Vf(b,a){for(;a.g;)o(b,r(a.g));return b}function r(a){return a.n?a.n.k=a.k:a.l.g=a.k,a.k?a.k.n=a.n:a.l.i=a.n,a.l=null,a.n=null,a.k=null,a}function Wf(a){for(;a.g;)r(a.g)}function ea(b,a){return a.l=b.l,a.n=b.n,a.k=b.k,b.n?b.n.k=a:b.l.g=a,
30
- b.k?b.k.n=a:b.l.i=a,b.l=null,b.n=null,b.k=null,b}function Ec(c,a,b){return b?a?(b.l=c,b.n=a.n,b.k=a,a.n?a.n.k=b:c.g=b,a.n=b,c):o(c,b):c}function ie(a){for(;a.g;)Ec(a.l,a.k,r(a.i));r(a)}function Ra(a){return a.b==28&&!!a.h}function Cb(a){return a.b==28&&!!!a.h}function cc(b,a){return b.b==30&&(b.h|0)==a||b.b==29&&b.h==a}function Xf(a){return a.l!=null&&a.l.b==20&&a.l.g==a}function je(a){return a.l!=null&&(ed(a.l.b)||Cc(a.l.b)&&a.l.g==a)}function ke(a){return je(a)?!0:a.l&&(a.l.b==21||a.l.b==43)?ke(a.l):!1}function le(a){return a.b==3&&a.g==null}function gd(a){return a.b==25&&a.g==null}function Yf(a){return a.b==30&&(a.h|0)<0||a.b==29&&a.h<0}function na(a){switch(a.b){case 28:case 29:case 30:case 23:return!0;case 22:return na(a.g)&&na(a.g.k)&&na(a.i);case 21:return na(a.g)}return dd(a.b)?!ed(a.b)&&na(a.g):Bc(a.b)?!Cc(a.b)&&na(a.g)&&na(a.i):!1}function Db(a){switch(a.b){case 28:Ba(a,!!!a.h);break;case 32:I(a,r(a.g));break;case 40:a.b=50;break;case 50:a.b=40;break;case 44:a.b=42;break;case 41:a.b=45;break;case 45:
31
- a.b=41;break;case 42:a.b=44;break;case 25:Db(a.i);break;case 47:a.b=46,Db(a.g),Db(a.i);break;case 46:a.b=47,Db(a.g),Db(a.i);break;default:I(a,s(o(new Lh(32),fd(a)),Y));break}}function oa(d,a){if(d.b==a.b){switch(d.b){case 28:return !!d.h==!!a.h;case 29:return d.h==a.h;case 30:return (d.h|0)==(a.h|0);case 23:return d.e==a.e;case 26:return d.f==a.f;case 21:return oa(d.g,a.g)&&d.e==a.e&&d.m==a.m;case 22:return oa(d.g,a.g)&&oa(d.g.k,a.g.k)&&oa(d.i,a.i);case 20:for(var b=d.g,c=a.g;b&&c;){if(!oa(b,c))return!1;b=b.k,c=c.k}return b==null&&c==null}if(dd(d.b))return oa(d.g,a.g);if(Bc(d.b))return oa(d.g,a.g)&&oa(d.i,a.i)}return!1}function me(a,b,c,d){return o(o(o(o(new Lh(10),a||new Lh(25)),b||new Lh(25)),c||new Lh(25)),d)}function sa(a){return s(o(new Lh(20),s(new Lh(26),a)),a)}function kb(a){return gd(a.g)?null:a.g}function Ca(a){return gd(a.g.k)?null:a.g.k}function Fc(a){return gd(a.i.n)?null:a.i.n}function ne(){return Re=Re+1|0,Re}function ba(a){return function(b,c){return x(s(new Lh(26),a),c.a)}}function dc(a){return function(b,c,d){
32
- return Qa(x(o(new Lh(a),d),_a(c.a,d.c)),c.a)}}function oe(a){return function(b,c,d){return Qa(x(o(new Lh(a),c),_a(c.c,d.a)),d.a)}}function W(a){return function(b,c,d,e){return Qa(x(o(o(new Lh(a),c),e),_a(c.c,e.c)),d.a)}}function Zf(a){return a.length>1&&a.charCodeAt(0)==48&&a.charCodeAt(1)^120&&a.charCodeAt(1)^88?parseInt(a,8):a|0}function _f(){var a=new Qh,b=function(c,d,e){return ce(c.a,d.a),x(s(new Lh(27),M),_a(d.a,e.c))},f=function(h,m,l,g){return ce(h.a,l.a),x(s(new Lh(27),M),_a(m.c,g.c))};return R(a,36,function(i,n){return x(s(Ba(new Lh(28),!0),Y),n.a)}),R(a,13,function(k,p){return x(s(Ba(new Lh(28),!1),Y),p.a)}),R(a,97,function(t,w){return x(s(_(new Lh(30),Zf(N(w.a))),ga),w.a)}),R(a,95,function(v,q){return x(s(ma(new Lh(29),+N(q.a)),da),q.a)}),R(a,3,ba(Y)),R(a,5,ba(Lb)),R(a,6,ba(Mb)),R(a,7,ba(Nb)),R(a,14,ba(da)),R(a,20,ba(ga)),R(a,22,ba(vb)),R(a,23,ba(wb)),R(a,24,ba(xb)),R(a,26,ba(ob)),R(a,27,ba(pb)),R(a,28,ba(qb)),R(a,39,ba(Fa)),R(a,40,ba(Ga)),R(a,41,ba(Ha)),R(a,42,ba(zd)),Ib(a,46,14,b),Ib(a,47,14,dc(34)),
33
- Ib(a,48,14,dc(35)),Ib(a,62,14,dc(31)),Ib(a,49,14,dc(32)),Ib(a,65,14,dc(33)),xe(a,47,15,oe(36)),xe(a,48,15,oe(37)),S(a,53,13,W(39)),S(a,54,10,W(40)),S(a,55,10,W(41)),S(a,56,10,W(42)),S(a,57,10,W(44)),S(a,58,10,W(45)),S(a,62,12,W(51)),S(a,63,13,W(49)),S(a,64,10,W(50)),S(a,65,12,W(38)),S(a,66,13,f),S(a,67,11,f),S(a,68,11,f),S(a,60,3,W(47)),S(a,61,4,W(48)),S(a,59,5,W(46)),S(a,50,8,f),S(a,51,6,f),S(a,52,7,f),ta(a,69,2,W(52)),ta(a,70,2,W(53)),ta(a,71,2,f),ta(a,72,2,f),ta(a,73,2,f),ta(a,74,2,W(54)),ta(a,75,2,W(55)),ta(a,76,2,f),ta(a,77,2,f),ta(a,78,2,f),ta(a,79,2,W(56)),R(a,96,function(E,F){var H=N(F.a),O=qd(E.l,H);return O?(O.m!=null&&ya(E.c.a,O.m,0)==1&&u(E.a,F.a,'Cannot use "'+H+'" from disabled extension "'+O.m+'"'),O.g=O.g+1|0,x(O instanceof Tb?s(new Lh(26),K(O)):Dc(new Lh(23),O),F.a)):(Lf(E.a,F.a),x(s(new Lh(24),M),F.a))}),S(a,81,1,function(ha,L,ia,Z){return L.b^25&&(L=x(o(new Lh(25),L),L.c)),o(L,Z),x(L,B(ha,L.c))}),Da(a,82,16).c=function($,ca){var ua=y($).a;D($);var aa=y($).a;return A($,96)?Qa(x(bc(o(new Lh(21),
34
- ca),N(aa)),B($,ca.c)),aa):Qa(x(bc(o(new Lh(21),ca),''),B($,ca.c)),ze(ua))},Da(a,85,0).b=function(ka){var va=D(ka),Ua=U(a,ka,0);return !Ua||!A(ka,89)?x(s(new Lh(24),M),B(ka,va.a)):x(Ua,B(ka,va.a))},Da(a,85,15).c=function(la,rb){var La=D(la),Va=o(new Lh(20),rb);return $f(la,Va,89)?Qa(x(Va,B(la,rb.c)),B(la,La.a)):x(s(new Lh(24),M),B(la,La.a))},Da(a,84,16).c=function(wa,xa){var eb=D(wa);if(y(wa).b==88)return Gb(wa),D(wa),x(s(new Lh(24),M),B(wa,eb.a));var Ia=U(a,wa,0);return !Ia||!A(wa,88)?x(s(new Lh(24),M),B(wa,eb.a)):Qa(x(o(o(new Lh(43),xa),Ia),B(wa,xa.c)),B(wa,eb.a))},Da(a,86,2).c=function(Ja,fb){var sb=D(Ja),tb=U(a,Ja,1);if(!tb||!A(Ja,80))return x(s(new Lh(24),M),B(Ja,sb.a));var bb=U(a,Ja,1);return bb?x(o(o(o(new Lh(22),fb),tb),bb),B(Ja,fb.c)):x(s(new Lh(24),M),B(Ja,sb.a))},a}function $f(a,b,c){for(var d=!0;!Q(a,c);){d||A(a,81);var e=y(a),f=U(db,a,1);if(f)o(b,f);else if(o(b,x(s(new Lh(24),M),B(a,e.a))),y(a).b^81&&y(a).b^c)return!1;d=!1}return!0}function ag(a){var b=D(a);a.l=new Xh(3,a.l);var c=Za(a,2);if(!c||!A(a,
35
- 43)||!A(a,85))return null;var d=U(db,a,0);return !d||!A(a,89)?null:(Hb(a),Eb(a,b.a,o(o(new Lh(7),c),d)))}function bg(a){var b=D(a),c=a.h;if(a.h|=b.b^44?2048:1024,Q(a,83)){var d=new Lh(13);return !ec(a,d,1)||!A(a,87)?null:(a.h=c,x(d,B(a,b.a)))}var e=Za(a,1);return e&&(a.h=c,e)}function dg(a){var b=D(a),c=y(a).a;if(!A(a,96))return null;var d=N(c);if(Q(a,83)){a.c.a.has(d)||Na(a.c.a,d,0);var e=new Lh(13);if(!ec(a,e,1)||!A(a,87))return null;for(var f=e.g;f;f=f.k)if(f.b^17)f.e&&(f.e.m=d);else for(var h=f.g.k;h;h=h.k)h.e.m=d;return x(e,B(a,b.a))}if(!dh.has(d)&&!a.c.a.has(d)&&If(a.a,c,'The extension "'+d+'" is not in the known list of valid WebGL extensions'),!A(a,80))return null;var m=N(y(a).a);if(!cg.has(m))return Gb(a),null;D(a);var l=cg.get(m);return Na(a.c.a,d,l),Qa(x(_(bc(new Lh(9),d),l),B(a,b.a)),c)}function eg(a){var b=D(a);if(a.l=new Xh(3,a.l),!A(a,85))return null;var c=null;if(!Q(a,90)){var d=re(a),e=hd(a,2),f=null;if(e){if(f=Fb(a,1),!f)return null}else f=Fb(a,0);if(f){if(c=qe(a,b.a,e,f,0,d),!c)return null}else if((c=U(db,
36
- a,0),!c)||!A(a,90))return null}var h=null;if(!Q(a,90)&&((h=U(db,a,0),!h)||!A(a,90)))return null;var m=null;if(!Q(a,89)&&((m=U(db,a,0),!m)||!A(a,89)))return null;var l=Za(a,2);return l&&(Hb(a),x(me(c,h,m,l),B(a,b.a)))}function fg(a){var b=D(a);if(!A(a,85))return null;var c=y(a),d=U(db,a,0);if(d||(d=x(s(new Lh(24),M),B(a,c.a))),!A(a,89))return null;var e=Za(a,2);if(!e)return null;var f=null;return Q(a,12)&&(f=Za(a,2),!f)?null:x(o(o(o(new Lh(12),d),e),f),B(a,b.a))}function gg(a){var b=D(a),c=y(a).a;return A(a,97)?x(_(new Lh(18),N(c)|0),B(a,b.a)):null}function hg(a){var b=D(a);if(a.l=new Xh(3,a.l),!A(a,85))return null;var c=y(a),d=U(db,a,0);if(d||(d=x(s(new Lh(24),M),B(a,c.a))),!A(a,89))return null;var e=Za(a,2);return e&&(Hb(a),x(o(o(new Lh(19),d),e),B(a,b.a)))}function ig(a){var b=D(a),c=null;if(!Q(a,90)){var d=y(a);c=U(db,a,0),c||(c=x(s(new Lh(24),M),B(a,d.a))),A(a,90)}return x(o(new Lh(15),c),B(a,b.a))}function jg(a){var b=D(a),c=0;switch(y(a).b){case 25:c=32;break;case 29:c=64;break;case 16:c=4;break;default:
37
- return Gb(a),null}D(a);var d=Fb(a,1);return d&&Eb(a,b.a,o(_(new Lh(14),c),d))}function kg(a,b,c){var d=y(a).a;if(!A(a,96))return null;var e=new Tb(tc(a.c),d,N(d),new Xh(4,a.l));if(e.e|=a.h|b,e.f=c,!id(a,e))return null;var f=y(a).a,h=new Lh(1),m=null;if(!A(a,83))return null;for(a.l=e.d;y(a).b^87&&y(a).b^99;){var l=Za(a,3);if(!l)return null;if(l.b^17)u(a.a,l.c,'This statement cannot be used inside a struct');else{o(h,l);for(var g=l.g.k;g;g=g.k){var i=g.e;e.i.push(i),P(i)&&u(a.a,P(i).c,'Cannot initialize struct variables')}}}if(Hb(a),!A(a,87))return null;if(x(h,B(a,f)),y(a).b^96)A(a,90);else if(m=ve(0,s(new Lh(26),K(e)),D(a).a,a,c),!m)return null;return o(o(Dc(new Lh(16),e),h),m)}function pe(a,b,c){for(var d=!1,e=a.l;e;e=e.b)if(e.a==3){d=!0;break}return d||u(a.a,b,'This statement cannot be used outside a loop'),Eb(a,b,c)}function Eb(a,b,c){return A(a,90),x(c,B(a,b))}function qe(a,b,c,d,e,f){var h=y(a).a;if(!c&&y(a).b^96){var m=we(db,a,0,d);return m&&Eb(a,b,o(new Lh(8),m))}if(!A(a,96))return null;if(Q(a,85))return mg(c,
38
- d,h,a,f);var l=ve(c,d,h,a,f);return l&&x(l,B(a,b))}function re(a){var b=y(a),c=b.c;if(!c)return null;for(var d=b.a.b,e=null,f=c.length-1|0;f>-1;f=f-1|0){for(var h=c[f],m=h.a.b.slice(h.c,d),l=0,g=0;g<m.length;g=g+1|0){var i=m.charCodeAt(g);(i==13||i==10)&&(l=l+1|0,i==13&&(g+1|0)<m.length&&m.charCodeAt(g+1|0)==10&&(g=g+1|0))}if(l>1)break;(e||(e=[])).push(N(h)),d=h.b}return e&&e.reverse(),e}function Za(a,b){var c=y(a);switch(c.b){case 4:return pe(a,D(a).a,new Lh(4));case 9:return pe(a,D(a).a,new Lh(5));case 10:return Eb(a,D(a).a,new Lh(6));case 11:return ag(a);case 44:case 45:return bg(a);case 91:return dg(a);case 15:return eg(a);case 17:return fg(a);case 83:return te(a);case 31:return jg(a);case 32:return ig(a);case 90:return x(new Lh(3),D(a).a);case 92:return gg(a);case 43:return hg(a)}var d=re(a),e=hd(a,b),f=null;if(Q(a,35)){var h=kg(a,e,d);return h&&x(h,B(a,c.a))}if(e){if(f=Fb(a,1),!f)return null}else f=Fb(a,0);if(f)return qe(a,c.a,e,f,1,d);var m=U(db,a,0);return m&&Eb(a,c.a,o(new Lh(8),m))}function se(a,b){if(b.b^17&&b.b^16){
39
- var c=a.l.a==1||a.l.a==4,d=b.b==9||b.b==11||b.b==14||b.b==18;d&&!c?u(a.a,b.c,'This statement cannot be used inside a function'):!d&&c&&u(a.a,b.c,'This statement cannot be used outside a function')}}function lg(a,b){var c=y(a).a;if(!A(a,98))return!1;var d=null;try{d=JSON.parse(N(c))}catch(l){return u(a.a,c,'Invalid string literal'),!1}var e=a.c.b;if(!e)return u(a.a,c,'Cannot include files without access to a file system'),!1;var f=e(d,c.a.a);if(!f)return u(a.a,c,'Cannot read the file '+JSON.stringify(d)),!1;if(a.e.has(f.a))return!0;Na(a.e,f.a,!0),a.f.push(new Nh(c,Eg(f)));var h=Kc(a.a,f,0),m=new Oh(a.a,h,a.c,a.d,a.e);return m.l=a.l,!ec(m,b,1)||!A(m,99)?!1:!0}function te(a){var b=y(a),c=new Lh(3);return a.l=new Xh(2,a.l),!A(a,83)||!ec(a,c,2)||!A(a,87)?null:(Hb(a),x(c,B(a,b.a)))}function hd(a,b){for(var c=0;;){var d=y(a).b;switch(d){case 2:c|=1;break;case 8:c|=2;break;case 16:c|=4;break;case 18:c|=8;break;case 19:c|=16;break;case 25:c|=32;break;case 29:c|=64;break;case 30:c|=128;break;case 37:c|=256;break;case 38:
40
- c|=512;break;default:return c}(!b&&(d==2||d==37||d==38)||b==3&&d^25&&d^29&&d^16||b&&(d==18||d==30||d==19))&&u(a.a,y(a).a,'Cannot use this qualifier here'),D(a)}}function Fb(a,b){var c=y(a),d=null;switch(c.b){case 3:d=Y;break;case 5:d=Lb;break;case 6:d=Mb;break;case 7:d=Nb;break;case 14:d=da;break;case 20:d=ga;break;case 22:d=vb;break;case 23:d=wb;break;case 24:d=xb;break;case 26:d=ob;break;case 27:d=pb;break;case 28:d=qb;break;case 33:d=Ng;break;case 34:d=Og;break;case 39:d=Fa;break;case 40:d=Ga;break;case 41:d=Ha;break;case 42:d=zd;break;case 96:var e=qd(a.l,N(c.a));if(!e||!(e instanceof Tb))return b^1||Gb(a),null;d=K(e);break;default:return b^1||Gb(a),null}return D(a),x(s(new Lh(26),d),B(a,c.a))}function mg(a,b,c,d,e){var f=d.l,h=new oc(tc(d.c),c,N(c),new Xh(0,f));if(h.e|=d.h|a|(h.c=='main'?1024:0),h.f=e,h.k=b,d.l=h.d,Q(d,42)){if(!A(d,89))return null}else if(!Q(d,89)){for(;;){var m=hd(d,0),l=Fb(d,1);if(!l)return null;var g=y(d).a;if(!A(d,96))return null;var i=new Ie(tc(d.c),g,N(g),d.l,0);if(i.e|=m,i.q=l,h.n.push(i),
41
- id(d,i),!ue(d,i))return null;if(!Q(d,81))break}if(!A(d,89))return null}var n=ya(f.c,N(c),null),k=!Q(d,90);if(n){if(n instanceof oc){for(var p=n;p;p=p.t)if(Gg(p,h)){p.k.f!=h.k.f?Mf(d.a,h.k.c,h.c,h.k.f,p.k.f,p.k.c):p.p||!k?bd(d.a,h.b,p.b):(p.w=h,h.w=p,h.e|=p.e,p.e=h.e);break}h.t=n,Dg(f,h)}else return bd(d.a,c,n.b),null}else He(f,h);if(k){var t=d.h;if(d.h&=-3073,h.p=te(d),d.h&=t,!h.p)return null}return Hb(d),x(Dc(new Lh(11),h),B(d,b.c))}function ue(a,b){var c=y(a);if(Q(a,84)){if(Q(a,88))return u(a.a,B(a,c.a),'All array sizes must be specified'),!0;if(b.F=U(db,a,0),!b.F||!A(a,88))return!1;var d=0;if(X(a.d,b.F),pa(a.d,b.F,ga),b.F.f!=M){var e=G(b.F);if(e){if(e.b==30){var f=e.h|0;f<1?u(a.a,b.F.c,'Cannot declare an array with a size of "'+f+'"'):d=f}}else u(a.a,b.F.c,'This value must be a compile-time constant')}for(;y(a).b==84;){if(c=D(a),y(a).b^88&&!U(db,a,0)||!A(a,88))return!1;u(a.a,B(a,c.a),'Multidimensional arrays are not a part of the language')}b.q=x(s(new Lh(26),Kg(b.q.f,d)),b.q.c)}return!0}function ve(a,b,c,d,e){
42
- for(var f=o(_(new Lh(17),d.h|a),b);;){var h=new Ie(tc(d.c),c,N(c),d.l,d.l.a^1?d.l.a^4?2:3:1);if(h.e|=d.h|a,h.f=e,h.q=b,!ue(d,h))return null;var m=y(d).a,l=null;if(Q(d,69)){var g=y(d);l=U(db,d,1),l||(l=x(s(new Lh(24),M),B(d,g.a)))}else m=null;var i=Qa(x(o(Dc(new Lh(2),h),l),B(d,h.b)),m);if(h.E=i,h.e&2&&X(d.d,i),o(f,i),id(d,h),!Q(d,81))return A(d,90),f;if(c=y(d).a,!A(d,96))return null}}function id(a,b){var c=ya(a.l.c,b.c,null);return c?(bd(a.a,b.b,c.b),!1):(He(a.l,b),!0)}function ec(a,b,c){for(;y(a).b^99&&y(a).b^87;){var d=y(a).a;if(Q(a,93)){if(c^1)return u(a.a,d,'"#include" statements cannot be used here'),Q(a,98),!1;if(!lg(a,b))return!1}else{var e=Za(a,c);if(!e)return!1;if(e.b^13)se(a,e),o(b,e);else for(;e.g;){var f=r(e.g);se(a,f),o(b,f)}}}return!0}function jd(a,b,c,d,e,f){db||(db=_f());var h=new Map,m=new Oh(a,b,d,f,h);return m.l=e,ec(m,c,1)&&A(m,99),new Mh(m.f)}function y(a){return a.b[a.m]}function D(b){var a=y(b);return (b.m+1|0)<b.b.length&&(b.m=b.m+1|0),a}function B(c,a){var b=c.b[c.m>0?c.m-1|0:0];return b.a.c<a.b?a:_a(a,
43
- b.a)}function Q(b,a){return y(b).b^a?!1:(D(b),!0)}function A(e,a){if(Q(e,a))return!0;var b=y(e),c=b.a,d=(e.m>0?e.b[e.m-1|0]:b).a;return a==90||ye(d).a^ye(c).a?u(e.a,ze(d),'Expected '+Qe[a]):u(e.a,c,'Expected '+Qe[a]+' but found '+Qe[b.b]),!1}function Gb(a){Kf(a.a,y(a))}function Hb(a){a.l=a.l.b}function Da(e,a,b){var c=ra(e.a,a,null);if(c)b>c.a&&(c.a=b);else{var d=new Ph(b);c=d,za(e.a,a,d)}return c}function U(f,a,b){var c=y(a),d=ra(f.a,c.b,null);if(!d||!d.b)return Gb(a),null;var e=we(f,a,b,d.b(a));return e}function we(f,a,b,c){for(;c;){var d=y(a).b,e=ra(f.a,d,null);if(!e||!e.c||e.a<=b)break;c=e.c(a,c)}return c}function R(d,a,b){Da(d,a,0).b=function(c){return b(c,D(c))}}function Ib(h,a,b,c){Da(h,a,0).b=function(d){var e=D(d),f=U(h,d,b);return f&&c(d,e,f)}}function xe(f,a,b,c){Da(f,a,b).c=function(d,e){return c(d,e,D(d))}}function S(m,a,b,c){Da(m,a,b).c=function(d,e){var f=D(d),h=U(m,d,b);return h&&c(d,e,f,h)}}function ta(m,a,b,c){Da(m,a,b).c=function(d,e){var f=D(d),h=U(m,d,b-1|0);return h&&c(d,e,f,h)}}function N(a){
44
- return a.a.b.slice(a.b,a.c)}function kd(b){var a=Jb(b.a,b.b);return b.a.a+':'+(a.a+1|0)+':'+(a.b+1|0)}function ng(b,a){return b.a==a.a&&b.b<a.c&&a.b<b.c}function fc(b,a){return b.b<=a&&a<=b.c}function ld(q,a){for(var b=Jb(q.a,q.b),c=Jb(q.a,q.c),d=Fg(q.a,b.a),e=b.b,f=c.a^b.a?d.length:c.b,h=We(bh,d,0),m=[],l=0,g=0;;){h.b^e||(l=m.length),h.b^f||(g=m.length);var i=Xe(h);if(i<0)break;if(i^9)m.push(i);else for(var n=0,E=8-m.length%8|0;n<E;n=n+1|0)m.push(32)}var k=m.length;if(a>0&&k>a){var p=Math.min(g-l|0,a/2|0),t=Math.max((a-p|0)/2|0,3);if(l<t)d=sc(m.slice(0,a-3|0))+'...',g>(a-3|0)&&(g=a-3|0);else if((k-l|0)<(a-t|0)){var w=k-a|0;d='...'+sc(m.slice(w+3|0,k)),l=l-w|0,g=g-w|0}else{var v=l-t|0;d='...'+sc(m.slice(v+3|0,(v+a|0)-3|0))+'...',l=l-v|0,g=g-v|0,g>(a-3|0)&&(g=a-3|0)}}else d=sc(m);return new Rh(d,Xb(' ',l)+((g-l|0)<2?'^':Xb('~',g-l|0)))}function og(c,a,b){return new Sh(c.a,c.b+a|0,c.b+b|0)}function ye(a){return Jb(a.a,a.b)}function ze(a){return new Sh(a.a,a.c,a.c)}function _a(a,b){return new Sh(a.a,a.b,b.c)}function pg(a){
45
- var b='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_'[a%53];for(a=a/53|0;a>0;)a=a-1|0,b+='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_0123456789'[a%63],a=a/63|0;return b}function qg(n,a){for(var b=0,k=a.length;b<k;b=b+1|0)n.h=b,lb(n,a[b]);sg(n);var c=new Map,d=Ae(n,n.f,null);d.sort(function(e,f){return Qc(Be(n,f),Be(n,e))});for(var E=0,F=d.length;E<F;E=E+1|0)for(var h=d[E],m=null,v=0,q=h.length;v<q;v=v+1|0)for(var l=h[v],p=0,t=Array.from(l.c.values()),w=t.length;p<w;p=p+1|0){var g=t[p],i=g.c;!(g.e&3072)&&(!n.a||n.a==1&&!(g.e&257))&&(m==null&&(m=rg(n)),g.c=m),!(g.e&2048)&&g.e&257&&Na(c,i,g.c)}return c}function lb(f,a){var m,h;a.e&&((h=md(f,a.e)).d=h.d+1|0);for(var b=a.g;b;b=b.k)lb(f,b);switch(a.b){case 2:var c=a.e;lb(f,c.q),P(c)&&lb(f,P(c));break;case 11:var d=a.e;f.l=f.d.get(a.e.a).b,d.w&&yd(f.f,f.l,md(f,d.w).b),lb(f,d.k);for(var l=0,g=d.n,i=g.length;l<i;l=l+1|0){var e=g[l];(m=md(f,e)).d=m.d+1|0,lb(f,e.q)}d.p&&lb(f,d.p),f.l=-1;break}}function md(c,a){var b=ra(c.d,a.a,null);return b||(b=new Uh(a.c,
46
- c.c.length),b.e=ud(a),c.c.push(b),za(c.d,a.a,b),Le(c.e),Le(c.f)),b.c.has(c.h)||za(b.c,c.h,a),ud(a)&&yd(c.e,c.l,b.b),b}function rg(b){for(;;){var a=pg(b.m);if(b.m=b.m+1|0,!Ig.has(a)&&!Jg.has(a)&&!a.startsWith('gl_'))return a}}function Ae(h,a,b){for(var c=new Map,m=0,l=h.c,g=l.length;m<g;m=m+1|0){var d=l[m];if(!b||b(d)){var e=Nc(a,d.b),f=ra(c,e,null);f||(f=[],za(c,e,f)),f.push(d)}}return Array.from(c.values())}function sg(b){tg(b,Ae(b,b.e,function(a){return a.e}))}function tg(m,a){for(var b=[],g=0,i=a.length;g<i;g=g+1|0){var c=a[g];c.sort(function(d,e){return Qc(e.d,d.d)});for(var f=0,l=c.length;f<l;f=f+1|0){var h=c[f];f<b.length?yd(m.f,h.b,b[f]):b.push(h.b)}}}function Be(d,a){for(var b=0,e=0,f=a.length;e<f;e=e+1|0){var c=a[e];b=b+c.d|0}return b}function nd(e,a){X(e,a);for(var f=0,h=e.d,m=h.length;f<m;f=f+1|0){var b=h[f];r(b)}var c=a.g;e.d.length&&Ec(a,c,e.d[0]);for(var l=0,g=Array.from(e.e.values()),i=g.length;l<i;l=l+1|0){var d=g[l];Ec(a,c,d)}}function od(b,a){a.b.a.a!='<api>'&&!a.g&&!(a.e&1024)&&b.a.b.push(a)}
47
- function X(q,a){if(!a.f){a.f=M;var b=a.b;switch(b){case 0:case 1:pd(q,a);break;case 2:var c=a.e;od(q,c),X(q,c.q);var d=c.q.f;if(d==zd&&(u(q.a,c.q.c,'Cannot create a variable of type "'+C(d)+'"'),d=M),c.F&&(ja(q,c.F),pa(q,c.F,ga)),P(c)&&(ja(q,P(c)),pa(q,P(c),d),d.d&&de(q.a,a.d,d)),c.e&2)if(P(c)){if(P(c).f!=M){var e=G(P(c));e?c.h=e:u(q.a,P(c).c,'This value must be a compile-time constant')}}else c.v^2||u(q.a,c.b,'Constants must be initialized');break;case 3:mb(q,a);break;case 4:case 5:case 6:break;case 7:mb(q,a.g),X(q,a.i),pa(q,a.i,Y);break;case 8:X(q,a.g);break;case 9:break;case 10:kb(a)&&ja(q,kb(a)),Ca(a)&&(ja(q,Ca(a)),pa(q,Ca(a),Y)),Fc(a)&&ja(q,Fc(a)),mb(q,a.i);break;case 11:var f=a.e;od(q,f);for(var E=0,F=f.n,H=F.length;E<H;E=E+1|0){var h=F[E];X(q,h.q)}X(q,f.k),f.p&&(q.f=f.k.f,mb(q,f.p),q.f&&q.f!=zd&&f.p.p&&u(q.a,f.b,'All control paths for "'+f.c+'" must return a value of type "'+C(q.f)+'"'),q.f=null);break;case 12:X(q,a.g),pa(q,a.g,Y),mb(q,a.g.k),a.g.k.k&&mb(q,a.g.k.k);break;case 14:break;case 15:a.g?(X(q,a.g),
48
- pa(q,a.g,q.f||M)):(a.f=zd,pa(q,a,q.f||M));break;case 16:var m=a.e;od(q,m),pd(q,a);for(var l=K(m),O=0,ha=m.i,L=ha.length;O<L;O=O+1|0){var g=ha[O],i=g.q.f;i.d&&(l.d=!0),i.e&&(l.e=!0)}break;case 17:pd(q,a);break;case 18:q.d.push(a);break;case 19:X(q,a.g),pa(q,a.g,Y),mb(q,a.i);break;case 20:wg(q,a);break;case 21:xg(q,a);break;case 22:var n=a.g,k=a.i,p=a.g.k;ja(q,n),pa(q,n,Y),ja(q,p),ja(q,k),p.f!=k.f?u(q.a,_a(p.c,k.c),'Cannot merge type "'+C(p.f)+'" and type "'+C(k.f)+'"'):p.f.d?Rf(q.a,_a(p.c,k.c),p.f):a.f=p.f;break;case 23:var t=a.e;t instanceof Ie?(X(q,t.q),a.f=t.q.f):t instanceof oc&&!Xf(a)?u(q.a,a.c,'The function "'+t.c+'" must be called'):a.f=K(t);var w=t.m;w!=null&&!q.e.has(w)&&!ya(q.b.a,w,0)&&Na(q.e,w,_(bc(new Lh(9),w),2));break;case 25:for(var v=a.g;v;v=v.k)ja(q,v);a.f=a.i.f;break;default:dd(b)?ug(q,a):Bc(b)&&vg(q,a);break}}}function mb(c,a){if(df(c.c,a),a.b^3)X(c,a),Jd(c.c,a);else for(var b=a.g;b;b=b.k)X(c,b),Jd(c.c,b);ef(c.c,a)}function ug(d,a){var b=a.g;ja(d,b),ed(a.b)&&Ce(d,b);var c=b.f;switch(a.b){case 31:case 33:case 34:case 35:case 36:case 37:
49
- a.f=Lg(c)?c:M;break;case 32:a.f=c==Y?Y:M;break}a.f==M&&c!=M&&u(d.a,a.d,'No unary operator "'+N(a.d)+'" for type "'+C(c)+'"')}function vg(i,a){var b=a.g,c=a.i;ja(i,b),ja(i,c),Cc(a.b)&&Ce(i,b);var d=b.f,e=c.f,f=d==e;switch(a.b){case 38:case 51:case 49:case 39:a.f=f&&fa(d)||Mc(d)&&e==da||Lc(d)&&e==ga?d:d==da&&Mc(e)||d==ga&&Lc(e)?e:a.b==49&&(d==Fa&&e==ob||d==ob&&e==Fa)?Fa:a.b==49&&(d==Ga&&e==pb||d==pb&&e==Ga)?Ga:a.b==49&&(d==Ha&&e==qb||d==qb&&e==Ha)?Ha:M;break;case 40:case 50:a.f=f&&Mg(d)?Y:M;break;case 46:case 47:case 48:a.f=f&&d==Y?Y:M;break;case 44:case 45:case 41:case 42:a.f=f&&(d==da||d==ga)?Y:M;break;case 52:a.f=d,d.d&&de(i.a,a.d,d),pa(i,c,d);return;case 53:case 56:case 55:case 54:a.f=f&&fa(d)||Mc(d)&&e==da||Lc(d)&&e==ga||a.b==55&&(d==Fa&&e==ob||d==Ga&&e==pb||d==Ha&&e==qb)?d:M;break;case 43:if(e==ga){var h=wd(d);h&&(a.f=h);var m=G(c);if(m&&m.b==30){var l=m.h|0,g=Sa(d);(l<0||g&&l>=g)&&u(i.a,c.c,'Index "'+l+'" is out of bounds for type "'+C(d)+'"')}}break}a.f==M&&d!=M&&e!=M&&(a.b^43?Sf(i.a,a.d,N(a.d),d,e):u(i.a,
50
- a.d,'No index operator for type "'+C(d)+'" and type "'+C(e)+'"'))}function wg(m,a){var b=a.g;X(m,b);for(var c=b.f,d=c.a,e=[],f=!1,h=b.k;h;h=h.k)ja(m,h),e.push(h),h.f==M&&(f=!0);if(!f){if(d){if(d instanceof oc){yg(m,d,a,e);return}if(d instanceof Tb){zg(m,c,a,e);return}}c!=M&&u(m.a,b.c,'Cannot call type "'+C(c)+'"')}}function xg(m,a){var b=a.g,c=a.m,d=a.d;if(ja(m,b),c!=''){var e=b.f,f=je(a);switch(e){case Lb:case vb:case Fa:case Mb:case wb:case Ga:case Nb:case xb:case Ha:a.f=Ag(m,d,e,c,f);break;case M:break;default:if(e.a&&e.a instanceof Tb)for(var l=0,g=e.a.i,i=g.length;l<i;l=l+1|0){var h=g[l];if(h.c==c){a.e=h,X(m,h.q),a.f=h.q.f;break}}a.e||u(m.a,d,'Cannot find "'+c+'" on type "'+C(e)+'"');break}}}function yg(q,a,b,c){for(var d=[],e=a;e;e=e.t)~d.indexOf(e.w)||d.push(e);if(d.length^1&&(d=d.slice(),Ab(d,function(f){return f.n.length!=c.length}),d.length^1)){var h=d.slice();Ab(d,function(m){for(var l=0,E=c.length;l<E;l=l+1|0)if(m.n[l].q.f!=c[l].f)return!0;return!1}),d.length^1&&(d=h,Ab(d,function(g){for(var i=0,F=c.length;i<F;i=i+1|0){
51
- var n=g.n[i].q.f,k=c[i].f,p=Ea(n),t=Ea(k);if(n!=k&&(!p||!t||p^t))return!0}return!1}))}if(d.length^1)u(q.a,b.g.c,'No matching overload for function "'+a.c+'"');else{var w=d[0];if(w.n.length^c.length)Pf(q.a,b.d,w.n.length,c.length,w.c,w.b);else for(var v=0,H=c.length;v<H;v=v+1|0)pa(q,c[v],w.n[v].q.f);b.g.e=w,b.f=w.k.f}}function zg(w,a,b,c){if(b.f=a,a!=M)if(fa(a)){for(var d=Ea(a),e=!1,f=0,v=0,q=c.length;v<q;v=v+1|0){var h=c[v],m=h.f,l=Ea(m);if(!fa(m)){m!=M&&u(w.a,h.c,'Cannot use value of type "'+C(m)+'" when constructing type "'+C(a)+'"');return}f>=d&&Nf(w.a,h.c,a,d,f+l|0),ab(m)&&(e=!0),f=f+l|0}var g=ab(a)&&e;g&&c.length^1?u(w.a,b.d,'If a matrix argument is given to a matrix constructor, it is an error to have any other arguments'):f<d&&f^1&&!g&&Of(w.a,b.d,a,f)}else{var i=a.a,n=i.i,k=n.length,p=c.length;if(k^p)Qf(w.a,b.d,k,p,i.c,i.b);else for(var t=0;t<k;t=t+1|0)pa(w,c[t],n[t].q.f)}}function Ag(l,a,b,c,d){var e=c.length;if(e<1||e>4)return u(l.a,a,'Invalid swizzle "'+c+'" on type "'+C(b)+'"'),M;for(var f=Ea(b),g=0,i=sd(f),n=i.length;g<n;g=g+1|0){
52
- var h=i[g];if(~h.indexOf(c[0])){for(var m=1;m<e;m=m+1|0){if(h.indexOf(c[m])==-1)return u(l.a,a,'Invalid swizzle "'+c+'" on type "'+C(b)+'"'),M;if(d&&~c.slice(0,m).indexOf(c[m]))return u(l.a,og(a,m,m+1|0),'The field "'+c[m]+'" cannot be specified multiple times when used as a storage location'),M}return td(fa(b),e)}}return u(l.a,a,'Invalid swizzle "'+c+'" on type "'+C(b)+'"'),M}function ja(b,a){X(b,a),a.b==26&&a.f!=M&&(u(b.a,a.c,'Unexpected type "'+C(a.f)+'"'),a.f=M)}function pd(c,a){for(var b=a.g;b;b=b.k)X(c,b)}function Ce(c,a){d:for(var b=a;;){if(b.f==M)break;switch(b.b){case 23:(b.e.e&2||b.e.e&256)&&u(c.a,a.c,'Cannot store to this location');break d;case 21:b=b.g;break;case 43:b=b.g;break;default:u(c.a,a.c,'Cannot store to this location');break d}}}function pa(c,a,b){a.f!=b&&a.f!=M&&b!=M&&u(c.a,a.c,'Cannot convert from type "'+C(a.f)+'" to type "'+C(b)+'"')}function Bg(a,b,c){for(;;){var d=new Wh;if(c.a&&Ic(d,a),c.d&&(Gc(d,a),Hc(d,a),Cg(d,a,b)),!d.a)break}c.a&&nb(a)}function nb(a){switch(a.b){case 12:if(!a.g.k.k)return!0;
53
- var b=a.g.k,c=nb(b);return c&&b.b^3&&ea(b,o(new Lh(3),fd(b))),nb(a.g.k.k);case 10:return nb(a.i);case 11:var d=a.e;d.p&&nb(d.p);break;case 19:return nb(a.i);default:for(var e=a.g;e;e=e.k)nb(e);return!1}return!1}function Gc(m,a){for(var b=a.g;b;b=b.k)Gc(m,b);switch(a.b){case 2:var c=a.e;P(c)&&Gc(m,P(c)),(c.v==2||c.v==1)&&(m.b.push(c),za(m.c,c.a,0),za(m.d,c.a,0));break;case 11:var d=a.e;za(m.c,d.a,0),d.p&&Gc(m,d.p);break;case 23:var e=a.e.a,f=ra(m.c,e,-1);~f&&za(m.c,e,f+1|0),ke(a)&&(f=ra(m.d,e,-1),~f&&za(m.d,e,f+1|0));var h=a.e.m;h!=null&&Na(m.e,h,0);break}}function Hc(l,a){for(var b=a.g,c=null;b;b=c)c=b.k,Hc(l,b);switch(a.b){case 2:if(Fe(l,a.e)||Ge(l,a.e)||Ee(l,a.e)&&(!a.g||na(a.g)||a.e.h))r(a),l.a=!0;else{a.g&&Hc(l,a.g);var d=a.e.F;if(d&&d.b==23){var e=De(l,d.e);e&&(a.e.F=e,l.a=!0)}}break;case 11:var f=a.e;Ee(l,f)&&!(f.e&1024)?(r(a),l.a=!0):f.p&&Hc(l,f.p);break;case 17:if(!a.g.k){var h=a.l.b;h==3||!h||h==16?r(a):h^10?I(a,new Lh(3)):I(a,new Lh(25)),l.a=!0}break;case 23:var m=De(l,a.e);m&&(ea(a,m),l.a=!0);break}}
54
- function De(b,a){return Fe(b,a)?Ya(a.h):Ge(b,a)?Ya(P(a)):null}function Cg(e,a,b){for(var c=a.g,d=null;c;c=d)d=c.k,c.b==9&&!e.e.has(c.m)&&!ya(b.a,c.m,0)&&r(c)}function Ee(b,a){return ra(b.c,a.a,-1)==0&&(!(a instanceof oc)||a.w==null||ra(b.c,a.w.a,-1)==0)}function Fe(b,a){return a.h!=null&&cd(a.h.b)}function Ge(b,a){return ra(b.d,a.a,-1)==0&&P(a)!=null&&cd(P(a).b)}function Ic(z,a){for(var b=a.g,c=null;b;b=c)c=b.k,Ic(z,b);switch(a.b){case 2:var d=a.e;P(d)&&Ic(z,P(d));break;case 3:for(var e=a.g;e;e=e.k)if(Uf(e.b)&&e.k){for(;e.k;)r(e.k);z.a=!0}if(a.l&&a.l.b==3){for(var f=!1,h=a.g;h;h=h.k)h.b^17||(f=!0);if(!f){ie(a),z.a=!0;return}}break;case 8:if(a.l.b==3){if(na(a.g)){r(a),z.a=!0;return}var m=a.n;if(m&&m.b==8){var l=r(a.g);o(a,o(o(new Lh(25),r(r(m).g)),l)),z.a=!0;return}}break;case 7:Jc(z,a.g),Cb(a.i)&&(ea(a,o(new Lh(3),r(a.g))),z.a=!0);break;case 10:if(Jc(z,a.i),!kb(a)&&a.n&&a.n.b==8&&(ea(a.g,r(a.n.g)),r(a.n),z.a=!0),Ca(a)&&Ra(Ca(a))&&(ea(Ca(a),new Lh(25)),z.a=!0),a.i.b^5){for(;a.i.g&&a.i.i.b==5;)r(a.i.i),z.a=!0}else ea(a.i,
55
- new Lh(3)),z.a=!0;break;case 11:var g=a.e;g.p&&Ic(z,g.p);break;case 12:if(Jc(z,a.g.k),a.g.k.k&&Jc(z,a.g.k.k),Ra(a.g)){ea(a,r(a.g.k)),z.a=!0;return}if(Cb(a.g)){a.g.k.k?ea(a,r(a.g.k.k)):r(a),z.a=!0;return}if(a.g.k.k&&a.g.k.b==15&&a.g.k.k.b==15){var i=a.g.k.g,n=a.g.k.k.g;if(i&&n){ea(a,o(new Lh(15),s(o(o(o(new Lh(22),r(a.g)),r(i)),r(n)),i.f))),z.a=!0;return}}if(a.g.k.k&&a.g.k.b==8&&a.g.k.k.b==8){var k=a.g.k.g,p=a.g.k.k.g;if(k.f==p.f){ea(a,o(new Lh(8),s(o(o(o(new Lh(22),r(a.g)),r(k)),r(p)),k.f))),z.a=!0;return}}if(!a.g.k.k&&a.g.k.b==8){var t=a.g.k.g,w=t.b==52&&t.g.b==23&&ud(t.g.e);if(t.f==ga||t.f==da||w){var v=w?Ya(t.g):t.f==ga?s(_(new Lh(30),0),ga):s(ma(new Lh(29),0),da);ea(a,o(new Lh(8),s(o(o(o(new Lh(22),r(a.g)),r(t)),v),t.f))),z.a=!0;return}}if(!a.g.k.k&&a.g.k.b==12&&!a.g.k.g.k.k){var q=a.g,E=a.g.k.g,F=a.g.k.g.k;I(q,s(o(o(new Lh(46),fd(q)),r(E)),Y)),I(a.g.k,r(F)),z.a=!0;return}if(le(a.g.k)){a.g.k.k?(Db(a.g),r(a.g.k)):ea(a,o(new Lh(8),r(a.g))),z.a=!0;return}if(a.g.k.k&&le(a.g.k.k)){r(a.g.k.k),z.a=!0;return}break;
56
- case 15:for(var H=a.n;H&&H.b==12&&!H.g.k.k&&H.g.k.b==15;){var O=H.g.k.g,ha=a.g;if(!O||!ha)break;ea(a,o(new Lh(15),s(o(o(o(new Lh(22),r(H.g)),r(O)),r(ha)),O.f))),r(H),H=a.n,z.a=!0}break;case 17:for(var L=a.n;L;L=L.n){if(L.b^17)break;if(L.g.f==a.g.f&&(L.h|0)==(a.h|0)){for(;L.i!=L.g;)Ec(a,a.g.k,r(L.i));r(L),z.a=!0;return}for(var ia=L.g.k;ia;ia=ia.k){var Z=ia.g;if(Z&&!cd(Z.b))return}}break;case 19:var $=a.g,ca=a.i;ea(a,me(null,r($),null,r(ca))),z.a=!0;break;case 22:var ua=a.g,aa=a.g.k,ka=a.i;if(Ra(ua)){I(a,r(aa)),z.a=!0;return}if(Cb(ua)){I(a,r(ka)),z.a=!0;return}if(aa.b==ka.b&&Bc(aa.b)&&oa(aa.g,ka.g)&&aa.b^43){var va=aa.g,Ua=aa.i,la=ka.i,rb=o(o(o(new Lh(22),r(ua)),r(Ua)),r(la));I(a,o(o(new Lh(aa.b),r(va)),rb)),z.a=!0;return}if(aa.b==52&&oa(aa.g,ka)&&na(ka)){var La=aa.g,Va=aa.i,wa=o(o(o(new Lh(22),r(ua)),r(Va)),r(ka));I(a,o(o(new Lh(52),r(La)),wa)),z.a=!0;return}break;case 25:for(var xa=a.g,eb=null;xa!=a.i;xa=eb)eb=xa.k,na(xa)&&(r(xa),z.a=!0);if(a.l.b==25){ie(a),z.a=!0;return}if(he(a)){I(a,r(a.g)),z.a=!0;return}break;
57
- case 31:var Ia=a.g;Ia.b^31?Ia.b^30?Ia.b^29||gc(z,a,-Ia.h):hc(z,a,-(Ia.h|0)|0):(I(a,r(Ia.g)),z.a=!0);break;case 32:var Ja=a.g;Ja.b^32?Ja.b^28||T(z,a,!!!Ja.h):(I(a,r(Ja.g)),z.a=!0);break;case 33:I(a,r(a.g));break;case 38:var fb=a.g,sb=a.i;cc(fb,0)?(I(a,r(sb)),z.a=!0):cc(sb,0)?(I(a,r(fb)),z.a=!0):fb.b==30&&sb.b==30?hc(z,a,(fb.h|0)+(sb.h|0)|0):fb.b==29&&sb.b==29&&gc(z,a,fb.h+sb.h);break;case 39:var tb=a.g,bb=a.i;cc(bb,1)?(I(a,r(tb)),z.a=!0):tb.b==30&&bb.b==30?hc(z,a,bb.h|0?(tb.h|0)/(bb.h|0)|0:0):tb.b==29&&bb.b==29&&gc(z,a,bb.h!=0?tb.h/bb.h:0);break;case 40:var cb=a.g,Ub=a.i;oa(cb,Ub)&&na(cb)?(T(z,a,!0),z.a=!0):cb.b==30&&Ub.b==30?T(z,a,(cb.h|0)==(Ub.h|0)):cb.b==29&&Ub.b==29&&T(z,a,cb.h==Ub.h);break;case 41:var ub=a.g,ic=a.i;ub.b==30&&ic.b==30?T(z,a,(ub.h|0)>(ic.h|0)):ub.b==29&&ic.b==29&&T(z,a,ub.h>ic.h);break;case 42:var Ka=a.g,Wa=a.i;Ka.b^30?Wa.b^30?Ka.b==30&&Wa.b==30?T(z,a,(Ka.h|0)>=(Wa.h|0)):Ka.b==29&&Wa.b==29&&T(z,a,Ka.h>=Wa.h):(a.b=41,_(Wa,(Wa.h|0)-1|0),z.a=!0):(a.b=41,_(Ka,(Ka.h|0)+1|0),z.a=!0);break;case 43:
58
- var qc=a.g,jc=a.i,Oc=qc.f;if(jc.b==30){var Ob=jc.h|0,Pb=0;switch(Oc){case Lb:case vb:case Fa:Pb=2;break;case Mb:case wb:case Ga:Pb=3;break;case Nb:case xb:case Ha:Pb=4;break}Ob>-1&&Ob<Pb&&(I(a,s(bc(o(new Lh(21),r(qc)),'xyzw'[Ob]),a.f)),z.a=!0)}break;case 44:var kc=a.g,Qb=a.i;kc.b==30&&Qb.b==30?T(z,a,(kc.h|0)<(Qb.h|0)):kc.b==29&&Qb.b==29&&T(z,a,kc.h<Qb.h);break;case 45:var Rb=a.g,yb=a.i;Rb.b^30?yb.b^30?Rb.b==30&&yb.b==30?T(z,a,(Rb.h|0)<=(yb.h|0)):Rb.b==29&&yb.b==29&&T(z,a,Rb.h<=yb.h):(a.b=44,_(yb,(yb.h|0)+1|0),z.a=!0):(a.b=44,_(Rb,(Rb.h|0)-1|0),z.a=!0);break;case 46:var Sb=a.g,Pc=a.i;Sb.b==28&&Ra(Sb)?(I(a,r(Pc)),z.a=!0):Sb.b==28&&Cb(Sb)?T(z,a,!1):Sb.b==28&&Pc.b==28&&T(z,a,!!Sb.h&&!!Pc.h);break;case 47:var Vb=a.g,rc=a.i;Vb.b==28&&Cb(Vb)?(I(a,r(rc)),z.a=!0):Vb.b==28&&Ra(Vb)?T(z,a,!0):Vb.b==28&&rc.b==28&&T(z,a,!!Vb.h&&!!rc.h);break;case 48:var Ta=a.g,lc=a.i;Ta.b==28&&lc.b==28&&T(z,a,!!Ta.h!=!!lc.h);break;case 49:var Ma=a.g,zb=a.i;Ma.b==30&&(Ma.h|0)==1?(I(a,r(zb)),z.a=!0):zb.b==30&&(zb.h|0)==1?(I(a,r(Ma)),z.a=!0):Ma.b==30&&zb.b==30?hc(z,
59
- a,sh(Ma.h|0,zb.h|0)):Ma.b==29&&zb.b==29&&gc(z,a,Ma.h*zb.h);break;case 50:var gb=a.g,mc=a.i;oa(gb,mc)&&na(gb)?(T(z,a,!1),z.a=!0):gb.b==30&&mc.b==30?T(z,a,(gb.h|0)!=(mc.h|0)):gb.b==29&&mc.b==29&&T(z,a,gb.h!=mc.h);break;case 51:var nc=a.g,Wb=a.i;cc(nc,0)?(I(a,s(o(new Lh(31),r(Wb)),a.f)),z.a=!0):cc(Wb,0)?(I(a,r(nc)),z.a=!0):nc.b==30&&Wb.b==30?hc(z,a,(nc.h|0)-(Wb.h|0)|0):nc.b==29&&Wb.b==29&&gc(z,a,nc.h-Wb.h);break}}function T(c,a,b){I(a,s(s(Ba(new Lh(28),b),Y),Y)),c.a=!0}function gc(c,a,b){I(a,s(s(ma(new Lh(29),b),da),Y)),c.a=!0}function hc(c,a,b){I(a,s(s(_(new Lh(30),b),ga),Y)),c.a=!0}function Jc(b,a){a.b==3&&he(a)&&(ea(a,r(a.g)),b.a=!0)}function He(b,a){Na(b.c,a.c,a)}function Dg(b,a){Na(b.c,a.c,a)}function qd(c,a){var b=ya(c.c,a,null);return b||c.b&&qd(c.b,a)}function Eg(a){return new Sh(a,0,a.b.length)}function Fg(d,a){if(rd(d),a<0||a>=d.d.length)return'';var b=d.d[a],c=(a+1|0)<d.d.length?d.d[a+1|0]-1|0:d.b.length;return d.b.slice(b,c)}function Jb(h,a){rd(h);for(var b=h.d.length,c=0;b>0;){var d=b/2|0,e=c+d|0;h.d[e]<=a?(c=e+1|0,
60
- b=(b-d|0)-1|0):b=d}var f=c>0?a-h.d[c-1|0]|0:a;return new Yh(c-1|0,f)}function Kb(d,a,b){if(rd(d),a>-1&&a<d.d.length){var c=d.d[a];if(b>-1&&(c+b|0)<((a+1|0)<d.d.length?d.d[a+1|0]:d.b.length))return c+b|0}return-1}function rd(b){if(!b.d){b.d=[0];for(var a=0,c=b.b.length;a<c;a=a+1|0)b.b.charCodeAt(a)^10||b.d.push(a+1|0)}}function sd(a){switch(a){case 2:return eh;case 3:return fh;case 4:return gh}return null}function td(a,b){switch(a){case Y:switch(b){case 1:return Y;case 2:return Lb;case 3:return Mb;case 4:return Nb}break;case da:switch(b){case 1:return da;case 2:return Fa;case 3:return Ga;case 4:return Ha}break;case ga:switch(b){case 1:return ga;case 2:return vb;case 3:return wb;case 4:return xb}break}return null}function ud(a){return a instanceof Ie&&(a.v==0||a.v==2)}function K(a){return a.l||(a.l=new ai(a,null,0)),a.l}function Gg(c,a){if(c.n.length^a.n.length)return!1;for(var b=0,d=c.n.length;b<d;b=b+1|0)if(c.n[b].q.f!=a.n[b].q.f)return!1;return!0}function P(a){var b;return (b=a.E)&&b.g}function Kc(a,b,c){for(var d=b.b.split(hh),e=[],f=null,h=0,m=0,l=0,q=d.length;l<q;l=l+1|0){
61
- var g=d[l],i=g.length,n=m+i|0,k=new Sh(b,m,n);if(l%2){var p=g.charCodeAt(0);if(p>64&&p<91||p>96&&p<123||p==95){var t=ya(Ig,g,99);t^99?e.push(new $h(k,t,f)):Jg.has(g)?Jf(a,k):e.push(new $h(k,96,f))}else if(p>47&&p<58||p==46&&i>1)e.push(new $h(k,ih.test(g)?97:95,f));else if(p^35){if(p^34){var v=ya(jh,g,99);v^99||(g.startsWith('//')?c^1?(f||(f=[])).push(k):v=0:g.startsWith('/*')&&(c^1?(f||(f=[])).push(k):v=1)),v^99&&e.push(new $h(k,v,f))}else e.push(new $h(k,98,f))}else{var w=94;switch(g){case'#version':w=92;break;case'#extension':w=91;break;case'#include':w=93;break}e.push(new $h(k,w,f))}}else if(g!=''){u(a,k,'Syntax error "'+g+'"');break}e.length^h&&(f=null,h=e.length),m=n}return e.push(new $h(new Sh(b,m,m),99,f)),e}function Je(a){return a.b?Je(a.b):a}function Kg(c,a){c.f||(c.f=new Map);var b=ra(c.f,a,null);return b||(za(c.f,a,b=new ai(null,c,a)),b.d=!0,b.e=c.e),b}function C(a){return a.b?a.c?C(a.b)+'['+a.c+']':C(a.b)+'[]':a.a.c}function Sa(a){switch(a){case Lb:case Fa:case vb:case ob:return 2;case Mb:case Ga:case wb:case pb:
62
- return 3;case Nb:case Ha:case xb:case qb:return 4}return a.c}function wd(a){switch(a){case Lb:case Mb:case Nb:return Y;case Fa:case Ga:case Ha:return da;case vb:case wb:case xb:return ga;case ob:return Fa;case pb:return Ga;case qb:return Ha}return a.b}function Ea(a){switch(a){case Y:case da:case ga:return 1;case Lb:case Fa:case vb:return 2;case Mb:case Ga:case wb:return 3;case Nb:case Ha:case xb:case ob:return 4;case pb:return 9;case qb:return 16}return 0}function fa(a){switch(a){case Y:case Lb:case Mb:case Nb:return Y;case da:case Fa:case Ga:case Ha:case ob:case pb:case qb:return da;case ga:case vb:case wb:case xb:return ga}return null}function xd(a){switch(a){case Lb:case Mb:case Nb:case vb:case wb:case xb:case Fa:case Ga:case Ha:return!0}return!1}function ab(a){switch(a){case ob:case pb:case qb:return!0}return!1}function Lc(a){switch(a){case ga:case vb:case wb:case xb:return!0}return!1}function Mc(a){switch(a){case da:case Fa:case Ga:case Ha:return!0;case ob:case pb:case qb:return!0}return!1}function Lg(a){
63
- return Lc(a)||Mc(a)}function Mg(a){return !a.e&&!a.d}function Ke(a){return a.e=!0,a}function Le(b){var a=b.a.length;return b.a.push(a),a}function yd(c,a,b){c.a[Nc(c,a)]=Nc(c,b)}function Nc(c,a){var b=c.a[a];return b^a&&(b=Nc(c,b),c.a[a]=b),b}function qa(a,b){Me(a),process.stdout.write(b),Me(0)}function Qg(a){qa(3,'error: '),qa(1,a+'\n')}function Rg(a){qa(2,'note: '),qa(1,a+'\n')}function Sg(a){qa(7,'warning: '),qa(1,a+'\n')}function Ne(a){for(var b=process.stdout.columns,l=0,g=a.a,i=g.length;l<i;l=l+1|0){var c=g[l];c.b&&qa(1,kd(c.b)+': ');switch(c.a){case 1:Sg(c.c);break;case 0:Qg(c.c);break}if(c.b){var d=ld(c.b,b);qa(2,d.a+'\n'),qa(4,d.b+'\n')}if(c.d){qa(1,kd(c.d)+': '),Rg(c.e);var e=ld(c.d,b);qa(2,e.a+'\n'),qa(4,e.b+'\n')}}var f=a.d!=0,h=a.c!=0,m='';h&&(m+=a.c+' warning'+(a.c^1?'s':''),f&&(m+=' and ')),f&&(m+=a.d+' error'+(a.d^1?'s':'')),(h||f)&&process.stdout.write(m+' generated\n')}function Oe(a){if(th(a))return[new Zh('<stdin>',a)];if(a instanceof Array){for(var b=[],c=0,e=a.length;c<e;c=c+1|0){var d=a[c];
64
- b.push(new Zh(uh(d.name),uh(d.contents)))}return b}return[new Zh(uh(a.name),uh(a.contents))]}function Pe(a){return function(b,c){var d=a(b,c);if(th(d))return new Zh(b,d);if(!d)return null;var e=d.name,f=d.contents;if(th(e)&&th(f))return new Zh(e,f);throw new Error('Invalid file access result')}}function Tg(){var a=process.argv.slice(2),b=new vh,c=[],d=0,e=null,f=require('fs'),h=require('path');b.e=function(m,l){var g=h.resolve(h.dirname(l),m);try{return new Zh(g,f.readFileSync(g,'utf8'))}catch(q){}return null};for(var w=0,v=a.length;w<v;w=w+1|0){var i=a[w];if(i.startsWith('-'))switch(i){case'--disable-rewriting':b.a=!1;break;case'--pretty-print':b.b=!1;break;case'--keep-symbols':b.d=!1;break;case'--help':case'-h':console.log("\nUsage: glslx [sources] [flags]\n\n --output=PATH\n Set the path to the output file. Defaults to standard out.\n\n --format=FORMAT\n Set the output format, must be json, js, c++, skew or rust. Defaults to json.\n\nAdvanced:\n\n --disable-rewriting\n Disable syntax tree rewriting, useful to check for driver bugs.\n\n --pretty-print\n Format the output nicely instead of minifying it.\n\n --renaming=MODE\n Valid modes are all, internal-only, or none. Defaults to all.\n\n --keep-symbols\n Don't inline constants or remove unused symbols.\n");
65
- return;default:if(i.startsWith('--output='))e=i.slice(9);else if(i.startsWith('--format=')){var n=i.slice(9);Se.has(n)||(console.log('invalid output format "'+n+'"'),process.exit(1)),d=Se.get(n)}else if(i.startsWith('--renaming=')){var k=i.slice(11);Te.has(k)||(console.log('invalid symbol renaming mode "'+k+'"'),process.exit(1)),b.c=Te.get(k)}else console.log('invalid flag "'+i+'"'),process.exit(1);break}else c.push(new Zh(h.resolve(i),f.readFileSync(i,'utf8')))}if(c.length){var p=new Kh,t=Id(p,c,b);t?e!=null?(f.writeFileSync(e,Sc(t,d)),Ne(p)):process.stdout.write(Sc(t,d)):(Ne(p),process.exit(1))}else console.log("\nUsage: glslx [sources] [flags]\n\n --output=PATH\n Set the path to the output file. Defaults to standard out.\n\n --format=FORMAT\n Set the output format, must be json, js, c++, skew or rust. Defaults to json.\n\nAdvanced:\n\n --disable-rewriting\n Disable syntax tree rewriting, useful to check for driver bugs.\n\n --pretty-print\n Format the output nicely instead of minifying it.\n\n --renaming=MODE\n Valid modes are all, internal-only, or none. Defaults to all.\n\n --keep-symbols\n Don't inline constants or remove unused symbols.\n")}
66
- function ci(){var a=(function(){return this})(),b=typeof exports!=='undefined'?exports:a.GLSLX={};b.compile=lh,b.compileIDE=mh,b.format=nh,typeof require!=='undefined'&&typeof module!=='undefined'&&require.main===module&&Tg()}function cd(a){return a>27&&a<31}function dd(a){return a>30&&a<38}function Tf(a){return a>30&&a<36}function ed(a){return a>33&&a<38}function Bc(a){return a>37&&a<57}function Cc(a){return a>51&&a<57}function Uf(a){return a==4||a==5||a==6||a==15}function ee(a){return a==7||a==10||a==19}function $a(b){var a='';return b&1&&(a+='attribute '),b&2&&(a+='const '),b&256&&(a+='uniform '),b&512&&(a+='varying '),b&4&&(a+='highp '),b&32&&(a+='lowp '),b&64&&(a+='mediump '),b&8&&(a+='in '),b&16&&(a+='inout '),b&128&&(a+='out '),a}function Hg(a){return a>49&&a<80}function vd(a){switch(a){case 96:case 42:case 33:case 34:case 14:case 39:case 40:case 41:case 20:case 22:case 23:case 24:case 3:case 5:case 6:case 7:case 26:case 27:case 28:return!0}return!1}function Me(a){process.stdout.isTTY&&process.stdout.write('\x1B[0;'+kh.get(a)+'m')}
67
- function hb(b,a){return b[b.length-1|0]=a}function Rc(a){return a[a.length-1|0]}function $e(c,a){for(var d=0,e=a.length;d<e;d=d+1|0){var b=a[d];c.push(b)}}function Ab(d,a){for(var b=0,c=0,e=d.length;c<e;c=c+1|0)a(d[c])||(b<c&&(d[b]=d[c]),b=b+1|0);for(;b<d.length;)d.pop()}function Na(c,a,b){return c.set(a,b),b}function j(c,a,b){return c.set(a,b),c}function ya(d,a,b){var c=d.get(a);return c!==void 0?c:b}function za(c,a,b){return c.set(a,b),b}function Oa(c,a,b){return c.set(a,b),c}function ra(d,a,b){var c=d.get(a);return c!==void 0?c:b}function Qc(b,a){return (a<b|0)-(a>b|0)|0}function sc(a){for(var b=new ph,d=0,e=a.length;d<e;d=d+1|0){var c=a[d];b.a+=Ye(c)}return b.a}function _e(b,a){return (a<b|0)-(a>b|0)|0}function Xb(d,a){for(var b='',c=0;c<a;c=c+1|0)b+=d;return b}function Ye(a){return a<65536?String.fromCharCode(a):String.fromCharCode((a-65536>>10)+55296|0)+String.fromCharCode((a-65536&1023)+56320|0)}function pc(a){if(!a)return null;var b=a.a,c=Jb(b,a.b),d=Jb(b,a.c);return{source:b.a,start:{line:c.a,column:c.b},
68
- end:{line:d.a,column:d.b}}}function lh(a,b){b=b||{};var c=Oe(a),d=new Kh,e=new vh;e.c=ya(Te,b.renaming,0),b.disableRewriting&&(e.a=!1),b.prettyPrint&&(e.b=!1),b.keepSymbols&&(e.d=!1),b.fileAccess&&(e.e=Pe(b.fileAccess));var f=Id(d,c,e);return{log:Hf(d),output:f?Sc(f,ya(Se,b.format,0)):null}}function mh(a,b){b=b||{};var c=Oe(a),d=new Kh,e=new vh;b.fileAccess&&(e.e=Pe(b.fileAccess));var f=af(d,c,e),h=function(m){for(var z,l=m.source+'',g=m.line|0,i=m.column|0,n=!!m.ignoreDiagnostics,k=null,p=null,t=null,Bd=0,Wg=c.length;Bd<Wg;Bd=Bd+1|0){var w=c[Bd];if(w.a==l){var v=Kb(w,g,i);if(~v){if(!n&&d)for(var Ad=0,Ue=d.a,Vg=Ue.length;Ad<Vg;Ad=Ad+1|0){var q=Ue[Ad];if(q.b&&q.b.a==w&&fc(q.b,v)){p=new Bh(q.c,''),k=q.b;break}}if(!p&&f){var E=new Ch(w,v);Pa(E,f.a),p=Af(E),p&&(k=E.e,t=(z=E.d)&&z.c)}}break}}return{tooltip:p&&p.a,range:pc(k),symbol:t,documentation:p&&p.b}},F=function(H){for(var O=H.source+'',ha=H.line|0,L=H.column|0,ia=null,Z=null,$=null,Cd=0,Ve=f.b,Xg=Ve.length;Cd<Xg;Cd=Cd+1|0){var ca=Ve[Cd];if(ca.a.a.a==O){var ua=Kb(ca.a.a,
69
- ha,L);if(~ua&&fc(ca.a,ua))return{definition:pc(ca.b),range:pc(ca.a),symbol:ca.b.a.a}}}for(var Dd=0,Yg=c.length;Dd<Yg;Dd=Dd+1|0){var aa=c[Dd];if(aa.a==O){var ka=Kb(aa,ha,L);if(~ka&&f){var va=new Ch(aa,ka);Pa(va,f.a),va.d&&va.d.b&&va.d.b.a.a!='<api>'&&(Z=va.d.b,ia=va.e,$=va.d.c)}break}}return{definition:pc(Z),range:pc(ia),symbol:$}},Ua=function(la){for(var rb=la.source+'',La=null,Ed=0,Zg=c.length;Ed<Zg;Ed=Ed+1|0){var Va=c[Ed];if(Va.a==rb){if(f){var wa=new Dh(Va);Zd(wa,f.a),La=wa.b.map(function(xa){return{name:xa.c,kind:xa instanceof Ie?'variable':xa instanceof oc?'function':xa instanceof Tb?'struct':null,range:pc(xa.b)}})}break}}return{symbols:La}},eb=function(Ia){for(var Ja=Ia.source+'',fb=Ia.line|0,sb=Ia.column|0,tb=null,bb=null,Fd=0,_g=c.length;Fd<_g;Fd=Fd+1|0){var cb=c[Fd];if(cb.a==Ja){var Ub=Kb(cb,fb,sb);if(~Ub&&f){var ub=new Eh(cb,Ub);Df(ub,f.a),ub.d&&ub.d.b&&ub.d.b.a.a!='<api>'&&(tb=ub.c.map(pc),bb=ub.d.c)}break}}return{ranges:tb,symbol:bb}},ic=function(Ka){for(var Wa=Ka.source+'',qc=Ka.line|0,jc=Ka.column|0,Oc=[],Gd=0,$g=c.length;Gd<$g;Gd=Gd+1|0){
70
- var Ob=c[Gd];if(Ob.a==Wa){var Pb=Kb(Ob,qc,jc);if(~Pb&&f){var kc=new Gh(Ob,Pb);Gf(kc,f.a),Oc=kc.d.map(function(Qb){return{kind:Qb.a,name:Qb.b,detail:Qb.c,documentation:Qb.d}})}}}return{completions:Oc}},Rb=function(yb){for(var Sb=yb.source+'',Pc=yb.line|0,Vb=yb.column|0,rc=[],Ta=-1,lc=-1,Hd=0,ah=c.length;Hd<ah;Hd=Hd+1|0){var Ma=c[Hd];if(Ma.a==Sb){var zb=Kb(Ma,Pc,Vb);if(~zb&&f){var gb=new Ih(Ma,zb);ad(gb,f.a),Ta=gb.d,lc=gb.e,rc=gb.c.map(function(mc){return{text:mc.a,'arguments':mc.b,documentation:mc.c}})}}}return{signatures:rc,activeArgument:Ta,activeSignature:lc}};return{unusedSymbols:d.b.map(function(nc){return{name:nc.c,range:pc(nc.b)}}),diagnostics:d.a.map(function(Wb){return{kind:oh[Wb.a].toLowerCase(),range:pc(Wb.b),text:Wb.c}}),tooltipQuery:h,definitionQuery:F,symbolsQuery:Ua,renameQuery:eb,completionQuery:ic,signatureQuery:Rb}}function nh(a,b){b=b||{};var c='indent'in b?uh(b.indent):' ',d='newline'in b?uh(b.newline):'\n',e=2;if('trailingNewline'in b){var f=uh(b.trailingNewline);switch(f){case'preserve':e=0;
71
- break;case'remove':e=1;break;case'insert':e=2;break;default:throw new Error('Invalid "trailingNewline" value: '+f)}}return zf(uh(a),c,d,e)}function ph(){this.a=''}function qh(){this.a='',this.b=0,this.c=0}function vh(){this.a=!0,this.b=!0,this.c=0,this.d=!0,this.e=null}function wh(a){this.a=new Map,this.b=a,this.c=0}function xh(a,b){this.a=a,this.b=b}function yh(a,b){this.a=a,this.b=b}function zh(){this.a=[],this.b=[]}function Ah(a,b){this.a='',this.b='',this.c='\n',this.d=' ',this.e=b.b,this.e&&(this.d='',this.c='');for(var c=null,d=a.g;d;d=d.k)gf(this,d)||(c&&ff(c,d)&&(this.a+=this.c),Xa(this,d),this.a+=this.c,c=d)}function Bh(a,b){this.a=a,this.b=b}function Ch(a,b){this.a=a,this.b=b,this.c=null,this.d=null,this.e=null,this.f=null,this.h=null}function Dh(a){this.a=a,this.b=[]}function Eh(a,b){this.a=a,this.b=b,this.c=[],this.d=null}function Fh(a,b){this.a=a,this.b=b,this.c='',this.d=''}function Gh(a,b){this.a=a,this.b=b,this.c=new Map,this.d=[]}function Hh(a,b,c){this.a=a,this.b=b,this.c=c}function Ih(a,b){this.a=a,
72
- this.b=b,this.c=[],this.d=-1,this.e=-1}function Jh(a,b,c){this.a=a,this.b=b,this.c=c,this.d=null,this.e=''}function Kh(){this.a=[],this.b=[],this.c=0,this.d=0,this.e=null}function Lh(a){this.a=ne(),this.b=a,this.c=null,this.d=null,this.e=null,this.f=null,this.h=0,this.m=null,this.l=null,this.g=null,this.i=null,this.n=null,this.k=null,this.p=!1}function Mh(a){this.a=a}function Nh(a,b){this.a=a,this.b=b}function Oh(a,b,c,d,e){this.a=a,this.b=b,this.c=c,this.d=d,this.e=e,this.f=[],this.h=0,this.m=0,this.l=null}function Ph(a){this.a=a,this.b=null,this.c=null}function Qh(){this.a=new Map}function Rh(a,b){this.a=a,this.b=b}function Sh(a,b,c){this.a=a,this.b=b,this.c=c}function Uh(a,b){this.a=a,this.b=b,this.c=new Map,this.d=0,this.e=!1}function Th(a){this.a=a,this.b=[],this.c=[],this.d=new Map,this.e=new bi,this.f=new bi,this.h=0,this.m=0,this.l=-1}function Vh(a,b){this.a=a,this.b=b,this.c=new zh,this.d=[],this.e=new Map,this.f=null}function Wh(){this.a=!1,this.b=[],this.c=new Map,this.d=new Map,this.e=new Map}function Xh(a,b){
73
- this.a=a,this.b=b,this.c=new Map}function Yh(a,b){this.a=a,this.b=b}function Zh(a,b){this.a=a,this.b=b,this.c=null,this.d=null}function _h(a,b,c,d){this.a=a,this.b=b,this.c=c,this.d=d,this.e=0,this.f=null,this.h=null,this.m=null,this.l=null,this.g=0}function Tb(a,b,c,d){_h.call(this,a,b,c,d),this.i=[]}rh(Tb,_h);function oc(a,b,c,d){_h.call(this,a,b,c,d),this.n=[],this.k=null,this.p=null,this.t=null,this.w=null}rh(oc,_h);function Ie(a,b,c,d,e){_h.call(this,a,b,c,d),this.v=e,this.q=null,this.E=null,this.F=null}rh(Ie,_h);function $h(a,b,c){this.a=a,this.b=b,this.c=c}function ai(a,b,c){this.a=a,this.b=b,this.c=c,this.d=!1,this.e=!1,this.f=null}function bi(){this.a=[]}var bh=new qh,Re=0,db=null,cg=j(j(j(j(new Map,'disable',1),'enable',2),'require',3),'warn',4),dh=j(j(j(j(new Map,'GL_OES_standard_derivatives',0),'GL_EXT_frag_depth',0),'GL_EXT_draw_buffers',0),'GL_EXT_shader_texture_lod',0),eh=['xy','st','rg'],fh=['xyz','stp','rgb'],gh=['xyzw','stpq','rgba'],hh=new RegExp('(\\.[0-9]+[eE][+-]?[0-9]+\\b|\\.[0-9]+\\b|[0-9]+\\.[0-9]+[eE][+-]?[0-9]+\\b|[0-9]+\\.[0-9]+\\b|[0-9]+\\.[eE][+-]?[0-9]+\\b|[0-9]+\\.|[0-9]+[eE][+-]?[0-9]+\\b|[1-9][0-9]*\\b|0[0-7]*\\b|0[xX][0-9A-Fa-f]+\\b|[ \t\r\n]|/\\*(?:.|\r\n|\n)*?\\*/|//.*|&&|\\|\\||\\^\\^|\\+\\+|--|<<=?|>>=?|[()[\\]{}\\.,?:;]|[+\\-*/%=!<>&|^~]=?|[A-Za-z_][A-Za-z0-9_]*\\b|#\\w+\\b|"(?:[^"\\\\]|\\\\.)*")'),ih=new RegExp('^([1-9][0-9]*|0[0-7]*|0[xX][0-9A-Fa-f]+)$'),Ig=j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(new Map,
74
- 'attribute',2),'bool',3),'break',4),'bvec2',5),'bvec3',6),'bvec4',7),'const',8),'continue',9),'discard',10),'do',11),'else',12),'false',13),'float',14),'for',15),'highp',16),'if',17),'in',18),'inout',19),'int',20),'invariant',21),'ivec2',22),'ivec3',23),'ivec4',24),'lowp',25),'mat2',26),'mat3',27),'mat4',28),'mediump',29),'out',30),'precision',31),'return',32),'sampler2D',33),'samplerCube',34),'struct',35),'true',36),'uniform',37),'varying',38),'vec2',39),'vec3',40),'vec4',41),'void',42),'while',43),'export',44),'import',45),jh=j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(new Map,'~',46),'--',47),'++',48),'!',49),'&',50),'|',51),'^',52),'/',53),'==',54),'>',55),'>=',56),'<',57),'<=',58),'&&',59),'||',60),'^^',61),'-',62),'*',63),'!=',64),'+',65),'%',66),'<<',67),'>>',68),'=',69),'+=',70),'&=',71),'|=',72),'^=',73),'/=',74),'*=',75),'%=',76),'<<=',77),'>>=',78),'-=',79),':',80),',',81),'.',82),'{',83),'[',84),'(',85),'?',86),'}',87),']',88),')',89),';',90),Jg=j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(new Map,
75
- 'asm',0),'cast',0),'class',0),'default',0),'double',0),'dvec2',0),'dvec3',0),'dvec4',0),'enum',0),'extern',0),'external',0),'fixed',0),'flat',0),'fvec2',0),'fvec3',0),'fvec4',0),'goto',0),'half',0),'hvec2',0),'hvec3',0),'hvec4',0),'inline',0),'input',0),'interface',0),'long',0),'namespace',0),'noinline',0),'output',0),'packed',0),'public',0),'sampler1D',0),'sampler1DShadow',0),'sampler2DRect',0),'sampler2DRectShadow',0),'sampler2DShadow',0),'sampler3D',0),'sampler3DRect',0),'short',0),'sizeof',0),'static',0),'superp',0),'switch',0),'template',0),'this',0),'typedef',0),'union',0),'unsigned',0),'using',0),'volatile',0),Y=K(new Tb(-1,null,'bool',null)),Lb=K(new Tb(-2,null,'bvec2',null)),Mb=K(new Tb(-3,null,'bvec3',null)),Nb=K(new Tb(-4,null,'bvec4',null)),M=K(new Tb(-5,null,'<error>',null)),da=K(new Tb(-6,null,'float',null)),ga=K(new Tb(-7,null,'int',null)),vb=K(new Tb(-8,null,'ivec2',null)),wb=K(new Tb(-9,null,'ivec3',null)),xb=K(new Tb(-10,null,'ivec4',null)),ob=K(new Tb(-11,null,'mat2',null)),pb=K(new Tb(-12,null,
76
- 'mat3',null)),qb=K(new Tb(-13,null,'mat4',null)),Ng=Ke(K(new Tb(-14,null,'sampler2D',null))),Og=Ke(K(new Tb(-15,null,'samplerCube',null))),Fa=K(new Tb(-16,null,'vec2',null)),Ga=K(new Tb(-17,null,'vec3',null)),Ha=K(new Tb(-18,null,'vec4',null)),zd=K(new Tb(-19,null,'void',null)),Pg=[Y,Lb,Mb,Nb,da,ga,vb,wb,xb,ob,pb,qb,Ng,Og,Fa,Ga,Ha],Se=j(j(j(j(j(new Map,'json',0),'js',1),'c++',2),'skew',3),'rust',4),Te=j(j(j(new Map,'all',0),'internal-only',1),'none',2),oh=['ERROR','WARNING'],Ug=['GLOBAL','STRUCT_BLOCK','VARIABLE','BLOCK','BREAK','CONTINUE','DISCARD','DO_WHILE','EXPRESSION','EXTENSION','FOR','FUNCTION','IF','MODIFIER_BLOCK','PRECISION','RETURN','STRUCT','VARIABLES','VERSION','WHILE','CALL','DOT','HOOK','NAME','PARSE_ERROR','SEQUENCE','TYPE','UNKNOWN_CONSTANT','BOOL','FLOAT','INT','NEGATIVE','NOT','POSITIVE','PREFIX_DECREMENT','PREFIX_INCREMENT','POSTFIX_DECREMENT','POSTFIX_INCREMENT','ADD','DIVIDE','EQUAL','GREATER_THAN','GREATER_THAN_OR_EQUAL','INDEX','LESS_THAN','LESS_THAN_OR_EQUAL','LOGICAL_AND','LOGICAL_OR',
77
- 'LOGICAL_XOR','MULTIPLY','NOT_EQUAL','SUBTRACT','ASSIGN','ASSIGN_ADD','ASSIGN_DIVIDE','ASSIGN_MULTIPLY','ASSIGN_SUBTRACT'],Qe=['SINGLE_LINE_COMMENT','MULTI_LINE_COMMENT','ATTRIBUTE','BOOL','BREAK','BVEC2','BVEC3','BVEC4','CONST','CONTINUE','DISCARD','DO','ELSE','FALSE','FLOAT','FOR','HIGHP','IF','IN','INOUT','INT','INVARIANT','IVEC2','IVEC3','IVEC4','LOWP','MAT2','MAT3','MAT4','MEDIUMP','OUT','PRECISION','RETURN','SAMPLER2D','SAMPLERCUBE','STRUCT','TRUE','UNIFORM','VARYING','VEC2','VEC3','VEC4','VOID','WHILE','EXPORT','IMPORT','COMPLEMENT','DECREMENT','INCREMENT','NOT','BITWISE_AND','BITWISE_OR','BITWISE_XOR','DIVIDE','EQUAL','GREATER_THAN','GREATER_THAN_OR_EQUAL','LESS_THAN','LESS_THAN_OR_EQUAL','LOGICAL_AND','LOGICAL_OR','LOGICAL_XOR','MINUS','MULTIPLY','NOT_EQUAL','PLUS','REMAINDER','SHIFT_LEFT','SHIFT_RIGHT','ASSIGN','ASSIGN_ADD','ASSIGN_BITWISE_AND','ASSIGN_BITWISE_OR','ASSIGN_BITWISE_XOR','ASSIGN_DIVIDE','ASSIGN_MULTIPLY','ASSIGN_REMAINDER','ASSIGN_SHIFT_LEFT','ASSIGN_SHIFT_RIGHT','ASSIGN_SUBTRACT','COLON',
78
- 'COMMA','DOT','LEFT_BRACE','LEFT_BRACKET','LEFT_PARENTHESIS','QUESTION','RIGHT_BRACE','RIGHT_BRACKET','RIGHT_PARENTHESIS','SEMICOLON','EXTENSION','VERSION','INCLUDE','PRAGMA','FLOAT_LITERAL','IDENTIFIER','INT_LITERAL','STRING_LITERAL','END_OF_FILE'],kh=Oa(Oa(Oa(Oa(Oa(Oa(Oa(Oa(Oa(new Map,0,0),1,1),2,90),3,31),4,32),5,33),6,34),7,35),8,36);ci()})();
2
+ (function(){var ch=Object.create||function(a){return{__proto__:a}};function rh(a,b){a.prototype=ch(b.prototype),a.prototype.constructor=a}var sh=Math.imul||function(a,b){return (a*(b>>>16)<<16)+a*(b&65535)|0};var $e;function th(a){return typeof a==='string'}function uh(a){return a===null?a:a+''}function Ye(c,a,b){return c.a=a,c.b=b,c.c=a.length,c}function Ze(c){if(c.b>=c.c)return-1;var a=c.a.charCodeAt((c.b=c.b+1|0)-1|0);if(a&64512^55296)return a;if(c.b>=c.c)return-1;var b=c.a.charCodeAt((c.b=c.b+1|0)-1|0);return ((a<<10)+b|0)-56613888|0}function wc(a){return a.c=a.c+1|0,a.c}function Yc(v,a){switch(a){case 0:var b={};return Array.from(v.b.keys()).forEach(function(c){b[c]=v.b.get(c)}),JSON.stringify({shaders:v.a?v.a.map(function(d){return{name:d.a,contents:d.b}}):null,renaming:b},null,2)+'\n';case 1:if(v.a){for(var e='',q=0,K=v.a,C=K.length;q<C;q=q+1|0){var f=K[q];e+='export const GLSLX_SOURCE_'+f.a.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+' = '+JSON.stringify(f.b)+'\n'}if(v.b&&Array.from(v.b.keys()).length){
3
+ e+='\n';for(var F=0,O=Array.from(v.b.keys()),la=O.length;F<la;F=F+1|0){var h=O[F];e+='export const GLSLX_NAME_'+h.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+' = '+JSON.stringify(v.b.get(h))+'\n'}}return e}break;case 2:if(v.a){var l='';l+='#ifndef GLSLX_STRINGS_H\n',l+='#define GLSLX_STRINGS_H\n',l+='\n';for(var L=0,ha=v.a,ga=ha.length;L<ga;L=L+1|0){var m=ha[L];l+='static const char *GLSLX_SOURCE_'+m.a.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+' = '+JSON.stringify(m.b)+';\n'}if(l+='\n',v.b){for(var Z=0,ba=Array.from(v.b.keys()),sa=ba.length;Z<sa;Z=Z+1|0){var g=ba[Z];l+='static const char *GLSLX_NAME_'+g.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+' = '+JSON.stringify(v.b.get(g))+';\n'}l+='\n'}return l+='#endif\n',l}break;case 3:if(v.a){for(var i='',ca=0,ma=v.a,ya=ma.length;ca<ya;ca=ca+1|0){var n=ma[ca];i+='const GLSLX_SOURCE_'+n.a.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+' = '+JSON.stringify(n.b)+'\n'}if(v.b&&Array.from(v.b.keys()).length){
4
+ i+='\n';for(var La=0,ka=Array.from(v.b.keys()),cb=ka.length;La<cb;La=La+1|0){var k=ka[La];i+='const GLSLX_NAME_'+k.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+' = '+JSON.stringify(v.b.get(k))+'\n'}}return i}break;case 4:if(v.a){for(var p='',Ma=0,Ua=v.a,wa=Ua.length;Ma<wa;Ma=Ma+1|0){var t=Ua[Ma];p+='pub static GLSLX_SOURCE_'+t.a.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+': &str = '+JSON.stringify(t.b)+';\n'}if(v.b&&Array.from(v.b.keys()).length){p+='\n';for(var za=0,db=Array.from(v.b.keys()),Ja=db.length;za<Ja;za=za+1|0){var w=db[za];p+='pub static GLSLX_NAME_'+w.replace(new RegExp('([a-z0-9])([A-Z])','g'),'$1_$2').toUpperCase()+': &str = '+JSON.stringify(v.b.get(w))+';\n'}}return p}break}return null}function cf(a,b,c){if(a.d)return null;b.unshift(new Zh('<api>',"\nimport {\n // The variable `gl_Position` is available only in the vertex language and is intended for writing the\n // homogeneous vertex position. This value will be used by primitive assembly, clipping, culling, and other\n // fixed functionality operations that operate on primitives after vertex processing has occurred.\n //\n // All executions of a well-formed vertex shader should write a value into this variable. It can be\n // written at any time during shader execution. It may also be read back by the shader after being written.\n // Compilers may generate a diagnostic message if they detect `gl_Position` is not written, or read before\n // being written, but not all such cases are detectable. The value of `gl_Position` is undefined if a vertex\n // shader is executed and does not write `gl_Position`.\n highp vec4 gl_Position;\n\n // The variable `gl_PointSize` is available only in the vertex language and is intended for\n // a vertex shader to write the size of the point to be rasterized. It is measured in pixels.\n mediump float gl_PointSize;\n\n const int gl_MaxVertexAttribs;\n const int gl_MaxVertexUniformVectors;\n const int gl_MaxVaryingVectors;\n const int gl_MaxVertexTextureImageUnits;\n const int gl_MaxCombinedTextureImageUnits;\n const int gl_MaxTextureImageUnits;\n const int gl_MaxFragmentUniformVectors;\n const int gl_MaxDrawBuffers;\n\n // The fragment shader has access to the read-only built-in variable `gl_FrontFacing` whose value is `true` if\n // the fragment belongs to a front-facing primitive. One use of this is to emulate two-sided lighting by\n // selecting one of two colors calculated by the vertex shader.\n const bool gl_FrontFacing;\n\n // The fragment shader has access to the read-only built-in variable `gl_PointCoord`. The values in\n // `gl_PointCoord` are two-dimensional coordinates indicating where within a point primitive the current\n // fragment is located. They range from 0.0 to 1.0 across the point. If the current primitive is not a\n // point, then the values read from `gl_PointCoord` are undefined.\n const mediump vec2 gl_PointCoord;\n\n // The variable `gl_FragCoord` is available as a read-only variable from within fragment shaders and it holds\n // the window relative coordinates `x`, `y`, `z`, and `1/w` values for the fragment. This value is the result\n // of the fixed functionality that interpolates primitives after vertex processing to generate fragments. The `z`\n // component is the depth value that will be used for the fragment's depth.\n const mediump vec4 gl_FragCoord;\n\n // Writing to `gl_FragColor` specifies the fragment color that will be used by the subsequent fixed\n // functionality pipeline.\n //\n // If subsequent fixed functionality consumes fragment color and an execution of a fragment shader\n // does not write a value to `gl_FragColor` then the fragment color consumed is undefined.\n mediump vec4 gl_FragColor;\n\n // The variable `gl_FragData` is an array. Writing to `gl_FragData[n]` specifies the fragment data that will be\n // used by the subsequent fixed functionality pipeline for data `n`.\n //\n // If subsequent fixed functionality consumes fragment data and an execution of a fragment shader does not write\n // a value to it, then the fragment data consumed is undefined.\n mediump vec4 gl_FragData[gl_MaxDrawBuffers];\n\n // Depth range in window coordinates\n struct gl_DepthRangeParameters {\n float near;\n float far;\n // Equal to `far - near`\n float diff;\n };\n\n uniform gl_DepthRangeParameters gl_DepthRange;\n\n ////////////////////////////////////////////////////////////////////////////////\n // Angle and Trigonometry Functions\n\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n float radians(float degrees);\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n vec2 radians(vec2 degrees);\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n vec3 radians(vec3 degrees);\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n vec4 radians(vec4 degrees);\n\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n float degrees(float radians);\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n vec2 degrees(vec2 radians);\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n vec3 degrees(vec3 radians);\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n vec4 degrees(vec4 radians);\n\n // The standard trigonometric sine function.\n float sin(float angle);\n // The standard trigonometric sine function.\n vec2 sin(vec2 angle);\n // The standard trigonometric sine function.\n vec3 sin(vec3 angle);\n // The standard trigonometric sine function.\n vec4 sin(vec4 angle);\n\n // The standard trigonometric cosine function.\n float cos(float angle);\n // The standard trigonometric cosine function.\n vec2 cos(vec2 angle);\n // The standard trigonometric cosine function.\n vec3 cos(vec3 angle);\n // The standard trigonometric cosine function.\n vec4 cos(vec4 angle);\n\n // The standard trigonometric tangent.\n float tan(float angle);\n // The standard trigonometric tangent.\n vec2 tan(vec2 angle);\n // The standard trigonometric tangent.\n vec3 tan(vec3 angle);\n // The standard trigonometric tangent.\n vec4 tan(vec4 angle);\n\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n float asin(float x);\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n vec2 asin(vec2 x);\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n vec3 asin(vec3 x);\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n vec4 asin(vec4 x);\n\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n float acos(float x);\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n vec2 acos(vec2 x);\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n vec3 acos(vec3 x);\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n vec4 acos(vec4 x);\n\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n float atan(float y, float x);\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n vec2 atan(vec2 y, vec2 x);\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n vec3 atan(vec3 y, vec3 x);\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n vec4 atan(vec4 y, vec4 x);\n\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n float atan(float y_over_x);\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n vec2 atan(vec2 y_over_x);\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n vec3 atan(vec3 y_over_x);\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n vec4 atan(vec4 y_over_x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Exponential Functions\n\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n float pow(float x, float y);\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n vec2 pow(vec2 x, vec2 y);\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n vec3 pow(vec3 x, vec3 y);\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n vec4 pow(vec4 x, vec4 y);\n\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n float exp(float x);\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n vec2 exp(vec2 x);\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n vec3 exp(vec3 x);\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n vec4 exp(vec4 x);\n\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n float log(float x);\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n vec2 log(vec2 x);\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n vec3 log(vec3 x);\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n vec4 log(vec4 x);\n\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n float exp2(float x);\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n vec2 exp2(vec2 x);\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n vec3 exp2(vec3 x);\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n vec4 exp2(vec4 x);\n\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n float log2(float x);\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n vec2 log2(vec2 x);\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n vec3 log2(vec3 x);\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n vec4 log2(vec4 x);\n\n // Returns `√x`. Results are undefined if `x < 0`.\n float sqrt(float x);\n // Returns `√x`. Results are undefined if `x < 0`.\n vec2 sqrt(vec2 x);\n // Returns `√x`. Results are undefined if `x < 0`.\n vec3 sqrt(vec3 x);\n // Returns `√x`. Results are undefined if `x < 0`.\n vec4 sqrt(vec4 x);\n\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n float inversesqrt(float x);\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n vec2 inversesqrt(vec2 x);\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n vec3 inversesqrt(vec3 x);\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n vec4 inversesqrt(vec4 x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Common Functions\n\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n float abs(float x);\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n vec2 abs(vec2 x);\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n vec3 abs(vec3 x);\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n vec4 abs(vec4 x);\n\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n float sign(float x);\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n vec2 sign(vec2 x);\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n vec3 sign(vec3 x);\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n vec4 sign(vec4 x);\n\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n float floor(float x);\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n vec2 floor(vec2 x);\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n vec3 floor(vec3 x);\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n vec4 floor(vec4 x);\n\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n float ceil(float x);\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n vec2 ceil(vec2 x);\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n vec3 ceil(vec3 x);\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n vec4 ceil(vec4 x);\n\n // Returns `x - floor(x)`\n float fract(float x);\n // Returns `x - floor(x)`\n vec2 fract(vec2 x);\n // Returns `x - floor(x)`\n vec3 fract(vec3 x);\n // Returns `x - floor(x)`\n vec4 fract(vec4 x);\n\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n float mod(float x, float y);\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n vec2 mod(vec2 x, float y);\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n vec3 mod(vec3 x, float y);\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n vec4 mod(vec4 x, float y);\n\n // Modulus. Returns `x - y * floor(x/y)`\n vec2 mod(vec2 x, vec2 y);\n // Modulus. Returns `x - y * floor(x/y)`\n vec3 mod(vec3 x, vec3 y);\n // Modulus. Returns `x - y * floor(x/y)`\n vec4 mod(vec4 x, vec4 y);\n\n // Returns `y` if `y < x`, otherwise it returns `x`\n float min(float x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec2 min(vec2 x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec2 min(vec2 x, vec2 y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec3 min(vec3 x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec3 min(vec3 x, vec3 y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec4 min(vec4 x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec4 min(vec4 x, vec4 y);\n\n // Returns `y` if `x < y`, otherwise it returns `x`\n float max(float x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec2 max(vec2 x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec2 max(vec2 x, vec2 y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec3 max(vec3 x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec3 max(vec3 x, vec3 y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec4 max(vec4 x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec4 max(vec4 x, vec4 y);\n\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n float clamp(float x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec2 clamp(vec2 x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec2 clamp(vec2 x, vec2 minVal, vec2 maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec3 clamp(vec3 x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec3 clamp(vec3 x, vec3 minVal, vec3 maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec4 clamp(vec4 x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec4 clamp(vec4 x, vec4 minVal, vec4 maxVal);\n\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n float mix(float x, float y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec2 mix(vec2 x, vec2 y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec2 mix(vec2 x, vec2 y, vec2 a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec3 mix(vec3 x, vec3 y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec3 mix(vec3 x, vec3 y, vec3 a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec4 mix(vec4 x, vec4 y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec4 mix(vec4 x, vec4 y, vec4 a);\n\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n float step(float edge, float x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec2 step(float edge, vec2 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec2 step(vec2 edge, vec2 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec3 step(float edge, vec3 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec3 step(vec3 edge, vec3 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec4 step(float edge, vec4 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec4 step(vec4 edge, vec4 x);\n\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // float t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n float smoothstep(float edge0, float edge1, float x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec2 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec2 smoothstep(float edge0, float edge1, vec2 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec2 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec2 smoothstep(vec2 edge0, vec2 edge1, vec2 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec3 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec3 smoothstep(float edge0, float edge1, vec3 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec3 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec3 smoothstep(vec3 edge0, vec3 edge1, vec3 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec4 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec4 smoothstep(float edge0, float edge1, vec4 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec4 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec4 smoothstep(vec4 edge0, vec4 edge1, vec4 x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Geometric Functions\n\n // Returns the length of vector `x`, i.e. `√x²`\n float length(float x);\n // Returns the length of vector `x`, i.e. `√x[0]² + x[1]²`\n float length(vec2 x);\n // Returns the length of vector `x`, i.e. `√x[0]² + x[1]² + x[2]²`\n float length(vec3 x);\n // Returns the length of vector `x`, i.e. `√x[0]² + x[1]² + x[2]² + x[3]²`\n float length(vec4 x);\n\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(float p0, float p1);\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(vec2 p0, vec2 p1);\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(vec3 p0, vec3 p1);\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(vec4 p0, vec4 p1);\n\n // Returns the dot product of `x` and `y`, i.e. `x*y`\n float dot(float x, float y);\n // Returns the dot product of `x` and `y`, i.e. `x[0]*y[0] + x[1]*y[1]`\n float dot(vec2 x, vec2 y);\n // Returns the dot product of `x` and `y`, i.e. `x[0]*y[0] + x[1]*y[1] + x[2]*y[2]`\n float dot(vec3 x, vec3 y);\n // Returns the dot product of `x` and `y`, i.e. `x[0]*y[0] + x[1]*y[1] + x[2]*y[2] + x[3]*y[3]`\n float dot(vec4 x, vec4 y);\n\n // Returns the cross product of `x` and `y`, i.e.\n //\n // ```glslx\n // vec3(\n // x[1]*y[2] - y[1]*x[2],\n // x[2]*y[0] - y[2]*x[0],\n // x[0]*y[1] - y[0]*x[1])\n // ```\n vec3 cross(vec3 x, vec3 y);\n\n // Returns a vector in the same direction as `x` but with a length of 1.\n float normalize(float x);\n // Returns a vector in the same direction as `x` but with a length of 1.\n vec2 normalize(vec2 x);\n // Returns a vector in the same direction as `x` but with a length of 1.\n vec3 normalize(vec3 x);\n // Returns a vector in the same direction as `x` but with a length of 1.\n vec4 normalize(vec4 x);\n\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n float faceforward(float N, float I, float Nref);\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n vec2 faceforward(vec2 N, vec2 I, vec2 Nref);\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n vec3 faceforward(vec3 N, vec3 I, vec3 Nref);\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n vec4 faceforward(vec4 N, vec4 I, vec4 Nref);\n\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n float reflect(float I, float N);\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n vec2 reflect(vec2 I, vec2 N);\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n vec3 reflect(vec3 I, vec3 N);\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n vec4 reflect(vec4 I, vec4 N);\n\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return float(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n float refract(float I, float N, float eta);\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return vec2(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n vec2 refract(vec2 I, vec2 N, float eta);\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return vec3(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n vec3 refract(vec3 I, vec3 N, float eta);\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return vec4(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n vec4 refract(vec4 I, vec4 N, float eta);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Matrix Functions\n\n // Multiply matrix `x` by matrix `y` component-wise, i.e., `result[i][j]` is the scalar product of `x[i][j]` and `y[i][j]`.\n // Note: to get linear algebraic matrix multiplication, use the multiply operator (`*`).\n mat2 matrixCompMult(mat2 x, mat2 y);\n // Multiply matrix `x` by matrix `y` component-wise, i.e., `result[i][j]` is the scalar product of `x[i][j]` and `y[i][j]`.\n // Note: to get linear algebraic matrix multiplication, use the multiply operator (`*`).\n mat3 matrixCompMult(mat3 x, mat3 y);\n // Multiply matrix `x` by matrix `y` component-wise, i.e., `result[i][j]` is the scalar product of `x[i][j]` and `y[i][j]`.\n // Note: to get linear algebraic matrix multiplication, use the multiply operator (`*`).\n mat4 matrixCompMult(mat4 x, mat4 y);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Vector Relational Functions\n\n // Returns the component-wise compare of `x < y`.\n bvec2 lessThan(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x < y`.\n bvec2 lessThan(vec2 x, vec2 y);\n // Returns the component-wise compare of `x < y`.\n bvec3 lessThan(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x < y`.\n bvec3 lessThan(vec3 x, vec3 y);\n // Returns the component-wise compare of `x < y`.\n bvec4 lessThan(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x < y`.\n bvec4 lessThan(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x <= y`.\n bvec2 lessThanEqual(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x <= y`.\n bvec2 lessThanEqual(vec2 x, vec2 y);\n // Returns the component-wise compare of `x <= y`.\n bvec3 lessThanEqual(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x <= y`.\n bvec3 lessThanEqual(vec3 x, vec3 y);\n // Returns the component-wise compare of `x <= y`.\n bvec4 lessThanEqual(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x <= y`.\n bvec4 lessThanEqual(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x > y`.\n bvec2 greaterThan(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x > y`.\n bvec2 greaterThan(vec2 x, vec2 y);\n // Returns the component-wise compare of `x > y`.\n bvec3 greaterThan(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x > y`.\n bvec3 greaterThan(vec3 x, vec3 y);\n // Returns the component-wise compare of `x > y`.\n bvec4 greaterThan(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x > y`.\n bvec4 greaterThan(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x >= y`.\n bvec2 greaterThanEqual(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x >= y`.\n bvec2 greaterThanEqual(vec2 x, vec2 y);\n // Returns the component-wise compare of `x >= y`.\n bvec3 greaterThanEqual(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x >= y`.\n bvec3 greaterThanEqual(vec3 x, vec3 y);\n // Returns the component-wise compare of `x >= y`.\n bvec4 greaterThanEqual(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x >= y`.\n bvec4 greaterThanEqual(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x == y`.\n bvec2 equal(bvec2 x, bvec2 y);\n // Returns the component-wise compare of `x == y`.\n bvec2 equal(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x == y`.\n bvec2 equal(vec2 x, vec2 y);\n // Returns the component-wise compare of `x == y`.\n bvec3 equal(bvec3 x, bvec3 y);\n // Returns the component-wise compare of `x == y`.\n bvec3 equal(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x == y`.\n bvec3 equal(vec3 x, vec3 y);\n // Returns the component-wise compare of `x == y`.\n bvec4 equal(bvec4 x, bvec4 y);\n // Returns the component-wise compare of `x == y`.\n bvec4 equal(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x == y`.\n bvec4 equal(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x != y`.\n bvec2 notEqual(bvec2 x, bvec2 y);\n // Returns the component-wise compare of `x != y`.\n bvec2 notEqual(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x != y`.\n bvec2 notEqual(vec2 x, vec2 y);\n // Returns the component-wise compare of `x != y`.\n bvec3 notEqual(bvec3 x, bvec3 y);\n // Returns the component-wise compare of `x != y`.\n bvec3 notEqual(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x != y`.\n bvec3 notEqual(vec3 x, vec3 y);\n // Returns the component-wise compare of `x != y`.\n bvec4 notEqual(bvec4 x, bvec4 y);\n // Returns the component-wise compare of `x != y`.\n bvec4 notEqual(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x != y`.\n bvec4 notEqual(vec4 x, vec4 y);\n\n // Returns true if any component of `x` is `true`.\n bool any(bvec2 x);\n // Returns true if any component of `x` is `true`.\n bool any(bvec3 x);\n // Returns true if any component of `x` is `true`.\n bool any(bvec4 x);\n\n // Returns true only if all components of `x` are `true`.\n bool all(bvec2 x);\n // Returns true only if all components of `x` are `true`.\n bool all(bvec3 x);\n // Returns true only if all components of `x` are `true`.\n bool all(bvec4 x);\n\n // Returns the component-wise logical complement of `x`.\n bvec2 not(bvec2 x);\n // Returns the component-wise logical complement of `x`.\n bvec3 not(bvec3 x);\n // Returns the component-wise logical complement of `x`.\n bvec4 not(bvec4 x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Texture Lookup Functions\n\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n vec4 texture2D(sampler2D sampler, vec2 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n vec4 texture2D(sampler2D sampler, vec2 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n vec4 texture2DLod(sampler2D sampler, vec2 coord, float lod);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`.\n vec4 texture2DProj(sampler2D sampler, vec3 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`.\n vec4 texture2DProj(sampler2D sampler, vec3 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`.\n vec4 texture2DProjLod(sampler2D sampler, vec3 coord, float lod);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`. The third component of `coord` is ignored.\n vec4 texture2DProj(sampler2D sampler, vec4 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`. The third component of `coord` is ignored.\n vec4 texture2DProj(sampler2D sampler, vec4 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`. The third component of `coord` is ignored.\n vec4 texture2DProjLod(sampler2D sampler, vec4 coord, float lod);\n\n // Use the texture coordinate `coord` to do a texture lookup in the cube map texture currently bound to `sampler`.\n // The direction of `coord` is used to select which face to do a 2-dimensional texture lookup in.\n vec4 textureCube(samplerCube sampler, vec3 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the cube map texture currently bound to `sampler`.\n // The direction of `coord` is used to select which face to do a 2-dimensional texture lookup in.\n vec4 textureCube(samplerCube sampler, vec3 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the cube map texture currently bound to `sampler`.\n // The direction of `coord` is used to select which face to do a 2-dimensional texture lookup in.\n vec4 textureCubeLod(samplerCube sampler, vec3 coord, float lod);\n\n #extension GL_OES_standard_derivatives {\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n float dFdx(float v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec2 dFdx(vec2 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec3 dFdx(vec3 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec4 dFdx(vec4 v);\n\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n float dFdy(float v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec2 dFdy(vec2 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec3 dFdy(vec3 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec4 dFdy(vec4 v);\n\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n float fwidth(float v);\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n vec2 fwidth(vec2 v);\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n vec3 fwidth(vec3 v);\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n vec4 fwidth(vec4 v);\n }\n\n #extension GL_EXT_frag_depth {\n // Available only in the fragment language, `gl_FragDepthEXT` is an output variable that is used to establish the depth value for the current fragment.\n // If depth buffering is enabled and no shader writes to `gl_FragDepthEXT`, then the fixed function value for depth will be used (this value is contained\n // in the `z` component of `gl_FragCoord`) otherwise, the value written to `gl_FragDepthEXT` is used.\n //\n // If a shader statically assigns to `gl_FragDepthEXT`, then the value of the fragment's depth may be undefined for executions of the shader that take\n // that path. That is, if the set of linked fragment shaders statically contain a write to `gl_FragDepthEXT`, then it is responsible for always writing it.\n float gl_FragDepthEXT;\n }\n\n #extension GL_EXT_shader_texture_lod {\n vec4 texture2DGradEXT(sampler2D sampler, vec2 P, vec2 dPdx, vec2 dPdy);\n vec4 texture2DLodEXT(sampler2D sampler, vec2 coord, float lod);\n vec4 texture2DProjGradEXT(sampler2D sampler, vec3 P, vec2 dPdx, vec2 dPdy);\n vec4 texture2DProjGradEXT(sampler2D sampler, vec4 P, vec2 dPdx, vec2 dPdy);\n vec4 texture2DProjLodEXT(sampler2D sampler, vec3 coord, float lod);\n vec4 texture2DProjLodEXT(sampler2D sampler, vec4 coord, float lod);\n vec4 textureCubeGradEXT(samplerCube sampler, vec3 P, vec3 dPdx, vec3 dPdy);\n vec4 textureCubeLodEXT(samplerCube sampler, vec3 coord, float lod);\n }\n}\n"));
5
+ for(var n=0,k=b.length;n<k;n=n+1|0){var d=b[n];d.c=Nc(a,d,0)}for(var e=new Lh(0),f=new Xh(1,null),h=new wh(c.e),l=new Vh(a,h),m=[],p=0,t=b.length;p<t;p=p+1|0){var g=b[p],i=qd(a,g.c,e,h,f,l);bf(m,i.a)}return ud(l,e),new yh(e,m)}function Nd(a,b,c){if(a.d)return null;b.unshift(new Zh('<api>',"\nimport {\n // The variable `gl_Position` is available only in the vertex language and is intended for writing the\n // homogeneous vertex position. This value will be used by primitive assembly, clipping, culling, and other\n // fixed functionality operations that operate on primitives after vertex processing has occurred.\n //\n // All executions of a well-formed vertex shader should write a value into this variable. It can be\n // written at any time during shader execution. It may also be read back by the shader after being written.\n // Compilers may generate a diagnostic message if they detect `gl_Position` is not written, or read before\n // being written, but not all such cases are detectable. The value of `gl_Position` is undefined if a vertex\n // shader is executed and does not write `gl_Position`.\n highp vec4 gl_Position;\n\n // The variable `gl_PointSize` is available only in the vertex language and is intended for\n // a vertex shader to write the size of the point to be rasterized. It is measured in pixels.\n mediump float gl_PointSize;\n\n const int gl_MaxVertexAttribs;\n const int gl_MaxVertexUniformVectors;\n const int gl_MaxVaryingVectors;\n const int gl_MaxVertexTextureImageUnits;\n const int gl_MaxCombinedTextureImageUnits;\n const int gl_MaxTextureImageUnits;\n const int gl_MaxFragmentUniformVectors;\n const int gl_MaxDrawBuffers;\n\n // The fragment shader has access to the read-only built-in variable `gl_FrontFacing` whose value is `true` if\n // the fragment belongs to a front-facing primitive. One use of this is to emulate two-sided lighting by\n // selecting one of two colors calculated by the vertex shader.\n const bool gl_FrontFacing;\n\n // The fragment shader has access to the read-only built-in variable `gl_PointCoord`. The values in\n // `gl_PointCoord` are two-dimensional coordinates indicating where within a point primitive the current\n // fragment is located. They range from 0.0 to 1.0 across the point. If the current primitive is not a\n // point, then the values read from `gl_PointCoord` are undefined.\n const mediump vec2 gl_PointCoord;\n\n // The variable `gl_FragCoord` is available as a read-only variable from within fragment shaders and it holds\n // the window relative coordinates `x`, `y`, `z`, and `1/w` values for the fragment. This value is the result\n // of the fixed functionality that interpolates primitives after vertex processing to generate fragments. The `z`\n // component is the depth value that will be used for the fragment's depth.\n const mediump vec4 gl_FragCoord;\n\n // Writing to `gl_FragColor` specifies the fragment color that will be used by the subsequent fixed\n // functionality pipeline.\n //\n // If subsequent fixed functionality consumes fragment color and an execution of a fragment shader\n // does not write a value to `gl_FragColor` then the fragment color consumed is undefined.\n mediump vec4 gl_FragColor;\n\n // The variable `gl_FragData` is an array. Writing to `gl_FragData[n]` specifies the fragment data that will be\n // used by the subsequent fixed functionality pipeline for data `n`.\n //\n // If subsequent fixed functionality consumes fragment data and an execution of a fragment shader does not write\n // a value to it, then the fragment data consumed is undefined.\n mediump vec4 gl_FragData[gl_MaxDrawBuffers];\n\n // Depth range in window coordinates\n struct gl_DepthRangeParameters {\n float near;\n float far;\n // Equal to `far - near`\n float diff;\n };\n\n uniform gl_DepthRangeParameters gl_DepthRange;\n\n ////////////////////////////////////////////////////////////////////////////////\n // Angle and Trigonometry Functions\n\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n float radians(float degrees);\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n vec2 radians(vec2 degrees);\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n vec3 radians(vec3 degrees);\n // Converts `degrees` to radians, i.e. `π / 180 * degrees`\n vec4 radians(vec4 degrees);\n\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n float degrees(float radians);\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n vec2 degrees(vec2 radians);\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n vec3 degrees(vec3 radians);\n // Converts `radians` to degrees, i.e. `180 / π * radians`\n vec4 degrees(vec4 radians);\n\n // The standard trigonometric sine function.\n float sin(float angle);\n // The standard trigonometric sine function.\n vec2 sin(vec2 angle);\n // The standard trigonometric sine function.\n vec3 sin(vec3 angle);\n // The standard trigonometric sine function.\n vec4 sin(vec4 angle);\n\n // The standard trigonometric cosine function.\n float cos(float angle);\n // The standard trigonometric cosine function.\n vec2 cos(vec2 angle);\n // The standard trigonometric cosine function.\n vec3 cos(vec3 angle);\n // The standard trigonometric cosine function.\n vec4 cos(vec4 angle);\n\n // The standard trigonometric tangent.\n float tan(float angle);\n // The standard trigonometric tangent.\n vec2 tan(vec2 angle);\n // The standard trigonometric tangent.\n vec3 tan(vec3 angle);\n // The standard trigonometric tangent.\n vec4 tan(vec4 angle);\n\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n float asin(float x);\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n vec2 asin(vec2 x);\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n vec3 asin(vec3 x);\n // Arc sine. Returns an angle whose sine is `x`. The range of values returned by this function is `[-π/2, π/2]`. Results are undefined if `∣x∣>1`.\n vec4 asin(vec4 x);\n\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n float acos(float x);\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n vec2 acos(vec2 x);\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n vec3 acos(vec3 x);\n // Arc cosine. Returns an angle whose cosine is `x`. The range of values returned by this function is `[0, π]`. Results are undefined if `∣x∣>1`.\n vec4 acos(vec4 x);\n\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n float atan(float y, float x);\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n vec2 atan(vec2 y, vec2 x);\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n vec3 atan(vec3 y, vec3 x);\n // Arc tangent. Returns an angle whose tangent is `y/x`. The signs of `x` and `y` are used to determine what quadrant the\n // angle is in. The range of values returned by this function is `[−π,π]`. Results are undefined if `x` and `y` are both 0.\n vec4 atan(vec4 y, vec4 x);\n\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n float atan(float y_over_x);\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n vec2 atan(vec2 y_over_x);\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n vec3 atan(vec3 y_over_x);\n // Arc tangent. Returns an angle whose tangent is `y_over_x`. The range of values returned by this function is `[-π/2, π/2]`.\n vec4 atan(vec4 y_over_x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Exponential Functions\n\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n float pow(float x, float y);\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n vec2 pow(vec2 x, vec2 y);\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n vec3 pow(vec3 x, vec3 y);\n // Returns `x` raised to the `y` power, i.e., `xʸ`. Results are undefined if `x < 0`. Results are undefined if `x = 0` and `y <= 0`.\n vec4 pow(vec4 x, vec4 y);\n\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n float exp(float x);\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n vec2 exp(vec2 x);\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n vec3 exp(vec3 x);\n // Returns the natural exponentiation of `x`, i.e., `eˣ`\n vec4 exp(vec4 x);\n\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n float log(float x);\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n vec2 log(vec2 x);\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n vec3 log(vec3 x);\n // Returns the natural logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = eʸ`. Results are undefined if `x <= 0`.\n vec4 log(vec4 x);\n\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n float exp2(float x);\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n vec2 exp2(vec2 x);\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n vec3 exp2(vec3 x);\n // Returns 2 raised to the `x` power, i.e., `2ˣ`.\n vec4 exp2(vec4 x);\n\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n float log2(float x);\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n vec2 log2(vec2 x);\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n vec3 log2(vec3 x);\n // Returns the base 2 logarithm of `x`, i.e., returns the value `y` which satisfies the equation `x = 2ʸ`. Results are undefined if `x <= 0`.\n vec4 log2(vec4 x);\n\n // Returns `√x`. Results are undefined if `x < 0`.\n float sqrt(float x);\n // Returns `√x`. Results are undefined if `x < 0`.\n vec2 sqrt(vec2 x);\n // Returns `√x`. Results are undefined if `x < 0`.\n vec3 sqrt(vec3 x);\n // Returns `√x`. Results are undefined if `x < 0`.\n vec4 sqrt(vec4 x);\n\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n float inversesqrt(float x);\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n vec2 inversesqrt(vec2 x);\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n vec3 inversesqrt(vec3 x);\n // Returns `1 / √x`. Results are undefined if `x <= 0`.\n vec4 inversesqrt(vec4 x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Common Functions\n\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n float abs(float x);\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n vec2 abs(vec2 x);\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n vec3 abs(vec3 x);\n // Returns `x` if `x >= 0`, otherwise it returns `-x`.\n vec4 abs(vec4 x);\n\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n float sign(float x);\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n vec2 sign(vec2 x);\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n vec3 sign(vec3 x);\n // Returns `1.0` if `x > 0`, `0.0` if `x = 0`, or `-1.0` if `x < 0`\n vec4 sign(vec4 x);\n\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n float floor(float x);\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n vec2 floor(vec2 x);\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n vec3 floor(vec3 x);\n // Returns a value equal to the nearest integer that is less than or equal to `x`\n vec4 floor(vec4 x);\n\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n float ceil(float x);\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n vec2 ceil(vec2 x);\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n vec3 ceil(vec3 x);\n // Returns a value equal to the nearest integer that is greater than or equal to `x`\n vec4 ceil(vec4 x);\n\n // Returns `x - floor(x)`\n float fract(float x);\n // Returns `x - floor(x)`\n vec2 fract(vec2 x);\n // Returns `x - floor(x)`\n vec3 fract(vec3 x);\n // Returns `x - floor(x)`\n vec4 fract(vec4 x);\n\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n float mod(float x, float y);\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n vec2 mod(vec2 x, float y);\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n vec3 mod(vec3 x, float y);\n // Modulus (modulo). Returns `x - y * floor(x/y)`\n vec4 mod(vec4 x, float y);\n\n // Modulus. Returns `x - y * floor(x/y)`\n vec2 mod(vec2 x, vec2 y);\n // Modulus. Returns `x - y * floor(x/y)`\n vec3 mod(vec3 x, vec3 y);\n // Modulus. Returns `x - y * floor(x/y)`\n vec4 mod(vec4 x, vec4 y);\n\n // Returns `y` if `y < x`, otherwise it returns `x`\n float min(float x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec2 min(vec2 x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec2 min(vec2 x, vec2 y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec3 min(vec3 x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec3 min(vec3 x, vec3 y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec4 min(vec4 x, float y);\n // Returns `y` if `y < x`, otherwise it returns `x`\n vec4 min(vec4 x, vec4 y);\n\n // Returns `y` if `x < y`, otherwise it returns `x`\n float max(float x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec2 max(vec2 x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec2 max(vec2 x, vec2 y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec3 max(vec3 x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec3 max(vec3 x, vec3 y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec4 max(vec4 x, float y);\n // Returns `y` if `x < y`, otherwise it returns `x`\n vec4 max(vec4 x, vec4 y);\n\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n float clamp(float x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec2 clamp(vec2 x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec2 clamp(vec2 x, vec2 minVal, vec2 maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec3 clamp(vec3 x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec3 clamp(vec3 x, vec3 minVal, vec3 maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec4 clamp(vec4 x, float minVal, float maxVal);\n // Returns `min(max(x, minVal), maxVal)`. Results are undefined if `minVal > maxVal`.\n vec4 clamp(vec4 x, vec4 minVal, vec4 maxVal);\n\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n float mix(float x, float y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec2 mix(vec2 x, vec2 y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec2 mix(vec2 x, vec2 y, vec2 a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec3 mix(vec3 x, vec3 y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec3 mix(vec3 x, vec3 y, vec3 a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec4 mix(vec4 x, vec4 y, float a);\n // Returns the linear blend of `x` and `y`, i.e. `x * (1-a) + y * a`\n vec4 mix(vec4 x, vec4 y, vec4 a);\n\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n float step(float edge, float x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec2 step(float edge, vec2 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec2 step(vec2 edge, vec2 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec3 step(float edge, vec3 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec3 step(vec3 edge, vec3 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec4 step(float edge, vec4 x);\n // Returns `0.0` if `x < edge`, otherwise it returns `1.0`\n vec4 step(vec4 edge, vec4 x);\n\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // float t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n float smoothstep(float edge0, float edge1, float x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec2 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec2 smoothstep(float edge0, float edge1, vec2 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec2 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec2 smoothstep(vec2 edge0, vec2 edge1, vec2 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec3 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec3 smoothstep(float edge0, float edge1, vec3 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec3 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec3 smoothstep(vec3 edge0, vec3 edge1, vec3 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec4 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec4 smoothstep(float edge0, float edge1, vec4 x);\n // Returns `0.0` if `x <= edge0` and `1.0` if `x >= edge1` and performs smooth Hermite interpolation between 0 and 1 when `edge0 < x < edge1`.\n // This is useful in cases where you would want a threshold function with a smooth transition. This is equivalent to:\n //\n // ```glslx\n // vec4 t = clamp((x - edge0) / (edge1 - edge0), 0.0, 1.0);\n // return t * t * (3.0 - 2.0 * t);\n // ```\n //\n // Results are undefined if `edge0 >= edge1`.\n vec4 smoothstep(vec4 edge0, vec4 edge1, vec4 x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Geometric Functions\n\n // Returns the length of vector `x`, i.e. `√x²`\n float length(float x);\n // Returns the length of vector `x`, i.e. `√x[0]² + x[1]²`\n float length(vec2 x);\n // Returns the length of vector `x`, i.e. `√x[0]² + x[1]² + x[2]²`\n float length(vec3 x);\n // Returns the length of vector `x`, i.e. `√x[0]² + x[1]² + x[2]² + x[3]²`\n float length(vec4 x);\n\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(float p0, float p1);\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(vec2 p0, vec2 p1);\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(vec3 p0, vec3 p1);\n // Returns the distance between `p0` and `p1`, i.e. `length(p0 - p1)`\n float distance(vec4 p0, vec4 p1);\n\n // Returns the dot product of `x` and `y`, i.e. `x*y`\n float dot(float x, float y);\n // Returns the dot product of `x` and `y`, i.e. `x[0]*y[0] + x[1]*y[1]`\n float dot(vec2 x, vec2 y);\n // Returns the dot product of `x` and `y`, i.e. `x[0]*y[0] + x[1]*y[1] + x[2]*y[2]`\n float dot(vec3 x, vec3 y);\n // Returns the dot product of `x` and `y`, i.e. `x[0]*y[0] + x[1]*y[1] + x[2]*y[2] + x[3]*y[3]`\n float dot(vec4 x, vec4 y);\n\n // Returns the cross product of `x` and `y`, i.e.\n //\n // ```glslx\n // vec3(\n // x[1]*y[2] - y[1]*x[2],\n // x[2]*y[0] - y[2]*x[0],\n // x[0]*y[1] - y[0]*x[1])\n // ```\n vec3 cross(vec3 x, vec3 y);\n\n // Returns a vector in the same direction as `x` but with a length of 1.\n float normalize(float x);\n // Returns a vector in the same direction as `x` but with a length of 1.\n vec2 normalize(vec2 x);\n // Returns a vector in the same direction as `x` but with a length of 1.\n vec3 normalize(vec3 x);\n // Returns a vector in the same direction as `x` but with a length of 1.\n vec4 normalize(vec4 x);\n\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n float faceforward(float N, float I, float Nref);\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n vec2 faceforward(vec2 N, vec2 I, vec2 Nref);\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n vec3 faceforward(vec3 N, vec3 I, vec3 Nref);\n // If `dot(Nref, I) < 0` return `N`, otherwise return `-N`\n vec4 faceforward(vec4 N, vec4 I, vec4 Nref);\n\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n float reflect(float I, float N);\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n vec2 reflect(vec2 I, vec2 N);\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n vec3 reflect(vec3 I, vec3 N);\n // For the incident vector `I` and surface orientation `N`, returns the reflection direction: `I - 2 * dot(N, I) * N`.\n // `N` must already be normalized in order to achieve the desired result.\n vec4 reflect(vec4 I, vec4 N);\n\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return float(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n float refract(float I, float N, float eta);\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return vec2(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n vec2 refract(vec2 I, vec2 N, float eta);\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return vec3(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n vec3 refract(vec3 I, vec3 N, float eta);\n // For the incident vector `I` and surface normal `N`, and the ratio of indices of refraction `eta`, return the refraction vector.\n // The result is computed by:\n //\n // ```glslx\n // float k = 1.0 - eta * eta * (1.0 - dot(N, I) * dot(N, I));\n // if (k < 0.0) return vec4(0.0);\n // else return eta * I - (eta * dot(N, I) + sqrt(k)) * N;\n // ```\n //\n // The input parameters for the incident vector `I` and the surface normal `N`.\n vec4 refract(vec4 I, vec4 N, float eta);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Matrix Functions\n\n // Multiply matrix `x` by matrix `y` component-wise, i.e., `result[i][j]` is the scalar product of `x[i][j]` and `y[i][j]`.\n // Note: to get linear algebraic matrix multiplication, use the multiply operator (`*`).\n mat2 matrixCompMult(mat2 x, mat2 y);\n // Multiply matrix `x` by matrix `y` component-wise, i.e., `result[i][j]` is the scalar product of `x[i][j]` and `y[i][j]`.\n // Note: to get linear algebraic matrix multiplication, use the multiply operator (`*`).\n mat3 matrixCompMult(mat3 x, mat3 y);\n // Multiply matrix `x` by matrix `y` component-wise, i.e., `result[i][j]` is the scalar product of `x[i][j]` and `y[i][j]`.\n // Note: to get linear algebraic matrix multiplication, use the multiply operator (`*`).\n mat4 matrixCompMult(mat4 x, mat4 y);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Vector Relational Functions\n\n // Returns the component-wise compare of `x < y`.\n bvec2 lessThan(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x < y`.\n bvec2 lessThan(vec2 x, vec2 y);\n // Returns the component-wise compare of `x < y`.\n bvec3 lessThan(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x < y`.\n bvec3 lessThan(vec3 x, vec3 y);\n // Returns the component-wise compare of `x < y`.\n bvec4 lessThan(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x < y`.\n bvec4 lessThan(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x <= y`.\n bvec2 lessThanEqual(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x <= y`.\n bvec2 lessThanEqual(vec2 x, vec2 y);\n // Returns the component-wise compare of `x <= y`.\n bvec3 lessThanEqual(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x <= y`.\n bvec3 lessThanEqual(vec3 x, vec3 y);\n // Returns the component-wise compare of `x <= y`.\n bvec4 lessThanEqual(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x <= y`.\n bvec4 lessThanEqual(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x > y`.\n bvec2 greaterThan(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x > y`.\n bvec2 greaterThan(vec2 x, vec2 y);\n // Returns the component-wise compare of `x > y`.\n bvec3 greaterThan(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x > y`.\n bvec3 greaterThan(vec3 x, vec3 y);\n // Returns the component-wise compare of `x > y`.\n bvec4 greaterThan(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x > y`.\n bvec4 greaterThan(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x >= y`.\n bvec2 greaterThanEqual(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x >= y`.\n bvec2 greaterThanEqual(vec2 x, vec2 y);\n // Returns the component-wise compare of `x >= y`.\n bvec3 greaterThanEqual(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x >= y`.\n bvec3 greaterThanEqual(vec3 x, vec3 y);\n // Returns the component-wise compare of `x >= y`.\n bvec4 greaterThanEqual(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x >= y`.\n bvec4 greaterThanEqual(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x == y`.\n bvec2 equal(bvec2 x, bvec2 y);\n // Returns the component-wise compare of `x == y`.\n bvec2 equal(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x == y`.\n bvec2 equal(vec2 x, vec2 y);\n // Returns the component-wise compare of `x == y`.\n bvec3 equal(bvec3 x, bvec3 y);\n // Returns the component-wise compare of `x == y`.\n bvec3 equal(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x == y`.\n bvec3 equal(vec3 x, vec3 y);\n // Returns the component-wise compare of `x == y`.\n bvec4 equal(bvec4 x, bvec4 y);\n // Returns the component-wise compare of `x == y`.\n bvec4 equal(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x == y`.\n bvec4 equal(vec4 x, vec4 y);\n\n // Returns the component-wise compare of `x != y`.\n bvec2 notEqual(bvec2 x, bvec2 y);\n // Returns the component-wise compare of `x != y`.\n bvec2 notEqual(ivec2 x, ivec2 y);\n // Returns the component-wise compare of `x != y`.\n bvec2 notEqual(vec2 x, vec2 y);\n // Returns the component-wise compare of `x != y`.\n bvec3 notEqual(bvec3 x, bvec3 y);\n // Returns the component-wise compare of `x != y`.\n bvec3 notEqual(ivec3 x, ivec3 y);\n // Returns the component-wise compare of `x != y`.\n bvec3 notEqual(vec3 x, vec3 y);\n // Returns the component-wise compare of `x != y`.\n bvec4 notEqual(bvec4 x, bvec4 y);\n // Returns the component-wise compare of `x != y`.\n bvec4 notEqual(ivec4 x, ivec4 y);\n // Returns the component-wise compare of `x != y`.\n bvec4 notEqual(vec4 x, vec4 y);\n\n // Returns true if any component of `x` is `true`.\n bool any(bvec2 x);\n // Returns true if any component of `x` is `true`.\n bool any(bvec3 x);\n // Returns true if any component of `x` is `true`.\n bool any(bvec4 x);\n\n // Returns true only if all components of `x` are `true`.\n bool all(bvec2 x);\n // Returns true only if all components of `x` are `true`.\n bool all(bvec3 x);\n // Returns true only if all components of `x` are `true`.\n bool all(bvec4 x);\n\n // Returns the component-wise logical complement of `x`.\n bvec2 not(bvec2 x);\n // Returns the component-wise logical complement of `x`.\n bvec3 not(bvec3 x);\n // Returns the component-wise logical complement of `x`.\n bvec4 not(bvec4 x);\n\n ////////////////////////////////////////////////////////////////////////////////\n // Texture Lookup Functions\n\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n vec4 texture2D(sampler2D sampler, vec2 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n vec4 texture2D(sampler2D sampler, vec2 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n vec4 texture2DLod(sampler2D sampler, vec2 coord, float lod);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`.\n vec4 texture2DProj(sampler2D sampler, vec3 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`.\n vec4 texture2DProj(sampler2D sampler, vec3 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`.\n vec4 texture2DProjLod(sampler2D sampler, vec3 coord, float lod);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`. The third component of `coord` is ignored.\n vec4 texture2DProj(sampler2D sampler, vec4 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`. The third component of `coord` is ignored.\n vec4 texture2DProj(sampler2D sampler, vec4 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the 2D texture currently bound to `sampler`.\n // The texture coordinate `(coord.s, coord.t)` is divided by the last component of `coord`. The third component of `coord` is ignored.\n vec4 texture2DProjLod(sampler2D sampler, vec4 coord, float lod);\n\n // Use the texture coordinate `coord` to do a texture lookup in the cube map texture currently bound to `sampler`.\n // The direction of `coord` is used to select which face to do a 2-dimensional texture lookup in.\n vec4 textureCube(samplerCube sampler, vec3 coord);\n // Use the texture coordinate `coord` to do a texture lookup in the cube map texture currently bound to `sampler`.\n // The direction of `coord` is used to select which face to do a 2-dimensional texture lookup in.\n vec4 textureCube(samplerCube sampler, vec3 coord, float bias);\n // Use the texture coordinate `coord` to do a texture lookup in the cube map texture currently bound to `sampler`.\n // The direction of `coord` is used to select which face to do a 2-dimensional texture lookup in.\n vec4 textureCubeLod(samplerCube sampler, vec3 coord, float lod);\n\n #extension GL_OES_standard_derivatives {\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n float dFdx(float v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec2 dFdx(vec2 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec3 dFdx(vec3 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `x` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdx(dFdx(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec4 dFdx(vec4 v);\n\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n float dFdy(float v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec2 dFdy(vec2 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec3 dFdy(vec3 v);\n // Available only in the fragment shader, this function returns the partial derivative of expression `p` with respect to the window `y` coordinate.\n //\n // Expressions that imply higher order derivatives such as `dFdy(dFdy(n))` have undefined results, as do mixed-order derivatives such as\n // `dFdx(dFdy(n))`. It is assumed that the expression `p` is continuous and therefore, expressions evaluated via non-uniform control flow may be undefined.\n vec4 dFdy(vec4 v);\n\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n float fwidth(float v);\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n vec2 fwidth(vec2 v);\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n vec3 fwidth(vec3 v);\n // Returns the sum of the absolute derivative in `x` and `y` using local differencing for the input argument `p`, i.e. `abs(dFdx(p)) + abs(dFdy(p))`\n vec4 fwidth(vec4 v);\n }\n\n #extension GL_EXT_frag_depth {\n // Available only in the fragment language, `gl_FragDepthEXT` is an output variable that is used to establish the depth value for the current fragment.\n // If depth buffering is enabled and no shader writes to `gl_FragDepthEXT`, then the fixed function value for depth will be used (this value is contained\n // in the `z` component of `gl_FragCoord`) otherwise, the value written to `gl_FragDepthEXT` is used.\n //\n // If a shader statically assigns to `gl_FragDepthEXT`, then the value of the fragment's depth may be undefined for executions of the shader that take\n // that path. That is, if the set of linked fragment shaders statically contain a write to `gl_FragDepthEXT`, then it is responsible for always writing it.\n float gl_FragDepthEXT;\n }\n\n #extension GL_EXT_shader_texture_lod {\n vec4 texture2DGradEXT(sampler2D sampler, vec2 P, vec2 dPdx, vec2 dPdy);\n vec4 texture2DLodEXT(sampler2D sampler, vec2 coord, float lod);\n vec4 texture2DProjGradEXT(sampler2D sampler, vec3 P, vec2 dPdx, vec2 dPdy);\n vec4 texture2DProjGradEXT(sampler2D sampler, vec4 P, vec2 dPdx, vec2 dPdy);\n vec4 texture2DProjLodEXT(sampler2D sampler, vec3 coord, float lod);\n vec4 texture2DProjLodEXT(sampler2D sampler, vec4 coord, float lod);\n vec4 textureCubeGradEXT(samplerCube sampler, vec3 P, vec3 dPdx, vec3 dPdy);\n vec4 textureCubeLodEXT(samplerCube sampler, vec3 coord, float lod);\n }\n}\n"));
6
+ for(var O=0,la=b.length;O<la;O=O+1|0){var d=b[O];d.c=Nc(a,d,0)}for(var e=new Lh(0),f=new Xh(1,null),h=new wh(c.e),l=new Vh(a,h),L=0,ha=b.length;L<ha;L=L+1|0){var m=b[L];qd(a,m.c,e,h,f,l)}if(ud(l,e),a.d)return null;for(var g=[],i=[],ba=0,sa=df(f),ca=sa.length;ba<ca;ba=ba+1|0){for(var n=sa[ba],k=new Lh(0),p=new Xh(1,null),t=new wh(c.e),w=new Kh,v=new Vh(w,t),ga=0,Z=b.length;ga<Z;ga=ga+1|0){var q=b[ga];qd(w,q.c,k,t,p,v)}ud(v,k),ef(p,n),Dg(k,t,c),i.push(k),g.push(n.c)}for(var K=[],C=sg(new Th(c.c),i),F=0,ma=g.length;F<ma;F=F+1|0)K.push(new Zh(g[F],new Ah(i[F],c).a));return new xh(K,C)}function df(a){for(var b=[],d=0,e=Array.from(a.c.values()),f=e.length;d<f;d=d+1|0){var c=e[d];c instanceof mc&&c.e&1024&&b.push(c)}return b}function ef(a,b){for(var e=0,f=Array.from(a.c.values()),h=f.length;e<h;e=e+1|0){var c=f[e];if(c.a^b.a)c.e&=-1025;else{c.c='main';var d=c.w;d&&(d.c=c.c)}}}function ff(c,a){var b=a.m;c.b.push(c.b.length==0||Xc(c.b)),b&&ie(b.b)&&c.a.push(!1)}function gf(d,a){var b=a.m,c=d.b.pop();c&&(a.p=!0),b&&ie(b.b)&&!d.a.pop()&&(b.b==19&&Sa(b.g)||b.b==7&&Sa(b.i)||b.b==10&&(!Da(b)||Sa(Da(b))))&&hb(d.b,
7
+ !1)}function Od(e,a){if(Xc(e.b))switch(a.b){case 4:e.a.length&&hb(e.a,!0),hb(e.b,!1);break;case 15:case 6:case 5:hb(e.b,!1);break;case 12:var b=a.g,c=a.g.k,d=a.g.k.k;Sa(b)?c.p||hb(e.b,!1):Ib(b)&&d?d.p||hb(e.b,!1):c&&d&&!c.p&&!d.p&&hb(e.b,!1);break}}function hf(a,b){return Pd(a)||Pd(b)||a.b!=b.b&&(a.b==14||b.b==14||a.b==9||b.b==9)}function Pd(a){return a.b==11&&a.e.p!=null}function Qd(a,b){var c=a.toString(),d=a.toExponential();d.length<c.length&&(c=d);var e=c.indexOf('e'),f='';return ~e&&(f=c.slice(e),c=c.slice(0,e)),c=(+(+c).toFixed(6)).toString(),f==''&&c.indexOf('.')==-1&&(c+=b^1?'.0':'.'),b==1&&c.startsWith('0.')&&c!='0.'&&(c=c.slice(1)),b==1&&c.startsWith('-0.')&&c!='-0.'&&(c='-'+c.slice(2)),c+f}function jf(b,a){switch(a.b){case 11:case 16:return (a.e.e&2048)!=0;case 17:return ((a.h|0)&2048)!=0}return!1}function Zc(a){a.e||(a.b+=' ')}function _c(a){a.e||(a.b=a.b.slice(2))}function Wa(i,a){switch(a.b){case 3:if(!a.g&&a.m)i.a+=';';else{i.a+='{'+i.c,Zc(i);for(var b=a.g;b;b=b.k)i.a+=i.b,Wa(i,b),i.a+=i.c;_c(i),
8
+ i.a+=i.b+'}'}break;case 4:i.a+='break;';break;case 5:i.a+='continue;';break;case 6:i.a+='discard;';break;case 7:i.a+='do',cc(i,a.g,0),i.a+=i.c+i.b+'while'+i.d+'(',J(i,a.i,0),i.a+=');';break;case 8:J(i,a.g,0),i.a+=';';break;case 9:Rd(i),i.a+='#extension '+a.l+i.d+':'+i.d;switch(a.h|0){case 1:i.a+='disable';break;case 2:i.a+='enable';break;case 3:i.a+='require';break;case 4:i.a+='warn';break}Sd(i);break;case 10:i.a+='for'+i.d+'(',kb(a)?kb(a).b^17?(J(i,kb(a),0),i.a+=';'):Wa(i,kb(a)):i.a+=';',Da(a)&&(i.a+=i.d,J(i,Da(a),0)),i.a+=';',Ic(a)&&(i.a+=i.d,J(i,Ic(a),0)),i.a+=')',cc(i,a.i,1);break;case 11:var c=a.e;i.a+=_a(c.e),J(i,c.k,0),i.a+=' ',i.a+=c.c,i.a+='(';for(var n=0,k=c.n,p=k.length;n<p;n=n+1|0){var d=k[n];d!=c.n[0]&&(i.a+=','+i.d),i.a+=_a(d.e),J(i,d.q,0),i.a+=' ',$c(i,d)}i.a+=')',c.p?(i.a+=i.d,Wa(i,c.p)):i.a+=';';break;case 12:i.a+='if'+i.d+'(',J(i,a.g,0),i.a+=')',cc(i,a.g.k,1),a.g.k.k&&(i.a+=i.c+i.b+'else',a.g.k.k.b^12?cc(i,a.g.k.k,0):(i.a+=' ',Wa(i,a.g.k.k)));break;case 14:i.a+='precision ',i.a+=_a(a.h|0),J(i,
9
+ a.g,0),i.a+=';';break;case 15:var e=a.g;i.a+='return',e&&(Vf(e.b)||(i.a+=' '),J(i,e,0)),i.a+=';';break;case 16:var f=a.e;i.a+=_a(f.e),i.a+='struct '+f.c+i.d+'{'+i.c,Zc(i);for(var h=a.g.g;h;h=h.k)i.a+=i.b,Wa(i,h),i.a+=i.c;if(_c(i),i.a+=i.b+'}',a.g.k)for(var l=a.g.k.g.k;l;l=l.k)i.a+=l.n.n?','+i.d:i.d,$c(i,l.e);i.a+=';';break;case 17:i.a+=_a(a.h|0),J(i,a.g,0);for(var m=a.g.k;m;m=m.k){var g=m.e;i.a+=m.n.n?','+i.d:' ',$c(i,g)}i.a+=';';break;case 18:Rd(i),i.a+='#version '+(a.h|0),Sd(i);break;case 19:i.a+='while'+i.d+'(',J(i,a.g,0),i.a+=')',cc(i,a.i,1);break;default:i.a+=Wg[a.b];break}}function Rd(a){a.a!=''&&!a.a.endsWith('\n')&&(a.a+='\n')}function Sd(a){a.e&&(a.a+='\n')}function cc(c,a,b){a.b^3?(c.a+=c.e&&!b?' ':c.c,Zc(c),c.a+=c.b,Wa(c,a),_c(c)):(c.a+=c.d,Wa(c,a))}function Td(c,a){for(var b=a;b;b=b.k)b!=a&&(c.a+=','+c.d),J(c,b,1)}function $c(b,a){b.a+=a.c,a.C&&(b.a+='[',J(b,a.C,0),b.a+=']'),P(a)&&(b.a+=b.d+'='+b.d,J(b,P(a),1))}function J(c,a,b){switch(a.b){case 20:J(c,a.g,15),c.a+='(',Td(c,a.g.k),c.a+=')';break;case 21:
10
+ J(c,a.g,16),c.a+='.',c.a+=a.e?a.e.c:a.l;break;case 22:2<b&&(c.a+='('),J(c,a.g,3),c.a+=c.d+'?'+c.d,J(c,a.g.k,2),c.a+=c.d+':'+c.d,J(c,a.i,2),2<b&&(c.a+=')');break;case 23:c.a+=a.e.c;break;case 25:0<b&&(c.a+='('),Td(c,a.g),0<b&&(c.a+=')');break;case 26:c.a+=Ne(a.f).a.c;break;case 28:c.a+=(!!a.h).toString();break;case 29:c.a+=Qd(a.h,c.e?1:0);break;case 30:c.a+=(a.h|0).toString();break;case 43:J(c,a.g,16),c.a+='[',J(c,a.i,0),c.a+=']';break;case 31:dc(c,'-',a,b);break;case 32:dc(c,'!',a,b);break;case 33:dc(c,'+',a,b);break;case 34:dc(c,'--',a,b);break;case 35:dc(c,'++',a,b);break;case 36:Ud(c,'--',a,b);break;case 37:Ud(c,'++',a,b);break;case 38:V(c,'+',a,b,12);break;case 39:V(c,'/',a,b,13);break;case 40:V(c,'==',a,b,10);break;case 41:V(c,'>',a,b,10);break;case 42:V(c,'>=',a,b,10);break;case 44:V(c,'<',a,b,10);break;case 45:V(c,'<=',a,b,10);break;case 46:V(c,'&&',a,b,5);break;case 47:V(c,'||',a,b,3);break;case 48:V(c,'^^',a,b,4);break;case 49:V(c,'*',a,b,13);break;case 50:V(c,'!=',a,b,10);break;case 51:V(c,'-',a,b,12);
11
+ break;case 52:V(c,'=',a,b,2);break;case 53:V(c,'+=',a,b,2);break;case 54:V(c,'/=',a,b,2);break;case 55:V(c,'*=',a,b,2);break;case 56:V(c,'-=',a,b,2);break;default:c.a+=Wg[a.b];break}}function dc(f,a,b,c){var d=b.g,e=d.b;f.a+=a,(a.charCodeAt(0)==45&&(e==31||e==34||_f(d))||a.charCodeAt(0)==43&&(e==33||e==35))&&(f.a+=' '),J(f,d,14)}function Ud(d,a,b,c){J(d,b.g,15),d.a+=a}function V(f,a,b,c,d){var e=Fc(b.b);d<c&&(f.a+='('),J(f,b.g,d+(e|0)|0),f.a+=f.d+a+f.d,J(f,b.i,d+(!e|0)|0),d<c&&(f.a+=')')}function G(a){if(a.f==I)return null;switch(a.b){case 30:case 29:case 28:return Xa(a);case 23:return kf(a);case 25:return lf(a);case 22:return mf(a);case 21:return nf(a);case 43:return of(a);case 20:return pf(a);case 31:return _d(a,function(b){return-b},function(c){return -c|0});case 32:return wf(a,function(d){return!d});case 33:return _d(a,function(e){return+e},function(f){return+f});case 38:return bd(a,function(h,l){return h+l},function(m,g){return m+g|0});case 51:return bd(a,function(i,n){return i-n},function(k,p){return k-p|0});
12
+ case 49:return qf(a);case 39:return bd(a,function(t,w){return w!=0?t/w:0},function(v,q){return q?v/q|0:0});case 40:case 50:return tf(a);case 46:return ad(a,function(K,C){return K&&C});case 47:return ad(a,function(F,O){return F||O});case 48:return ad(a,function(la,L){return la!=L});case 41:return xc(a,function(ha,ga){return ha>ga});case 42:return xc(a,function(Z,ba){return Z>=ba});case 44:return xc(a,function(sa,ca){return sa<ca});case 45:return xc(a,function(ma,ya){return ma<=ya})}return null}function kf(a){var b=a.e;if(b&&b.e&2){if(b.h)return Xa(b.h);if(b.v)return s(new Lh(27),a.f)}return null}function lf(a){for(var b=a.g;b;b=b.k){var c=G(b);if(!c||b==a.i)return c}return null}function mf(a){var b=G(a.g),c=G(a.g.k),d=G(a.i);return b&&b.b==28&&c&&d?!b.h?d:c:null}function nf(a){var b=G(a.g);if(b&&b.b==20){var c=b.f,d=a.l;if(Ed(c))for(var e=d.length,f=Fa(c),t=0,w=zd(f),v=w.length;t<v;t=t+1|0){var h=w[t];if(~h.indexOf(d[0])){if(e==1)return r(gc(b,1+h.indexOf(d)|0));for(var l=Ad(ea(c),e),m=ua(l),g=0;g<e;g=g+1|0)o(m,
13
+ Xa(gc(b,1+h.indexOf(d[g])|0)));return m}}else if(c.a&&c.a instanceof ac)for(var i=c.a,n=i.i,k=0,q=n.length;k<q;k=k+1|0){var p=n[k];if(p.c==d)return r(gc(b,1+k|0))}}return null}function of(a){var b=G(a.g),c=G(a.i);if(b&&b.b==20&&c&&c.b==30){var d=b.f;if(Ed(d)){var e=Ta(d),f=c.h|0;if(-1<f&&f<e)return r(gc(b,f+1|0))}else if($a(d)){var h=Ta(d),l=c.h|0;if(-1<l&&l<h){for(var m=Dd(d),g=ua(m),i=gc(b,sh(l,h)),n=0;n<h;n=n+1|0)o(g,r(i.k));return g}}}return null}function pf(a){var b=a.g;if(b.b^26)return null;for(var c=b.f,d=ea(c),e=0,f=[],h=0,l=b.k;l;l=l.k){var m=G(l);if(!m)return null;if(m.b==20&&d&&ea(m.g.f))for(var g=m.g.k;g;g=g.k){var i=Vd(d,g);if(!i)return null;f.push(i)}else{if(d&&(m=Vd(d,m),!m))return null;f.push(m)}$a(m.f)&&(e=Ta(m.f)),h=h+1|0}return $a(c)&&e&&h^1?null:ea(c)?rf(f,c,$a(c)?e:0):c.a&&c.a instanceof ac?sf(f,c):null}function Hb(a){for(var b=[],c=a.g.k;c;c=c.k)b.push(c.h);return b}function qf(a){var ya,b=G(a.g),c=G(a.i),d=b&&b.f,e=c&&c.f;if(b&&c){if(d==Ga&&e==ob||d==Ha&&e==pb||d==Ia&&e==qb){for(var f=Ta(d),h=ua(d),l=Hb(b),m=Hb(c),g=0;g<f;g=g+1|0){
14
+ for(var i=0,n=0;n<f;n=n+1|0)i+=l[n]*m[n+sh(g,f)|0];o(h,s(na(new Lh(29),i),$))}return h}if(d==ob&&e==Ga||d==pb&&e==Ha||d==qb&&e==Ia){for(var k=Ta(d),p=ua(e),t=Hb(b),w=Hb(c),v=0;v<k;v=v+1|0){for(var q=0,K=0;K<k;K=K+1|0)q+=t[v+sh(K,k)|0]*w[K];o(p,s(na(new Lh(29),q),$))}return p}if($a(d)&&e==d){for(var C=Ta(d),F=ua(d),O=Hb(b),la=Hb(c),L=0;L<C;L=L+1|0)for(var ha=0;ha<C;ha=ha+1|0){for(var ga=0,Z=0;Z<C;Z=Z+1|0)ga+=O[ha+sh(Z,C)|0]*la[Z+sh(L,C)|0];o(F,s(na(new Lh(29),ga),$))}return F}return (ya=Yd(b,c,function(ba,sa){return ba*sa}))||Zd(b,c,function(ca,ma){return sh(ca,ma)})}return null}function Vd(a,b){var c=0;switch(b.b){case 28:c=+!!b.h;break;case 30:c=b.h|0;break;case 29:c=b.h;break;default:return null}switch(a){case aa:return s(Ca(new Lh(28),!!c),aa);case fa:return s(_(new Lh(30),c|0),fa);case $:return s(na(new Lh(29),c),$)}return null}function rf(a,b,c){var d=Fa(b),e=ea(b),f=ua(b);if(a.length^1){if(c){for(var n=Ta(b),k=0;k<n;k=k+1|0)for(var p=0;p<n;p=p+1|0)o(f,p<c&&k<c?a[p+sh(k,c)|0]:s(na(new Lh(29),p^k?0:1),$))}
15
+ else{if(a.length<d)return null;for(var t=0;t<d;t=t+1|0){var w=a[t];if(w.f!=e)return null;o(f,w)}}}else{var h=a[0];if(h.f!=e)return null;for(var l=$a(b),m=Ta(b),g=0;g<d;g=g+1|0){var i=l&&(g%(m+1|0)|0)!=0;o(f,i?s(na(new Lh(29),0),$):Xa(h))}}return Dd(b)?f:r(f.i)}function sf(a,b){var c=b.a.i,d=ua(b);if(a.length^c.length)return null;for(var e=0,f=a.length;e<f;e=e+1|0){if(a[e].f!=c[e].q.f)return null;o(d,a[e])}return d}function tf(a){var b=G(a.g),c=G(a.i);if(b&&c){var d=pa(b,c);return s(Ca(new Lh(28),a.b^40?!d:d),aa)}return null}function Wd(a,b,c,d){if(a.b==20&&a.g.b==26&&ea(a.g.f)==b){for(var e=ua(a.g.f),f=a.g.k;f;f=f.k){var h=G(f);if(!h||h.b^c)return null;o(e,d(h))}return e}return null}function uf(a,b){return a.b^29?Wd(a,$,29,function(c){return s(na(new Lh(29),b(c.h)),$)}):s(na(new Lh(29),b(a.h)),$)}function vf(a,b){return a.b^30?Wd(a,fa,30,function(c){return s(_(new Lh(30),b(c.h|0)),fa)}):s(_(new Lh(30),b(a.h|0)),fa)}function Xd(a,b,c,d,e){var f=a.b==20&&a.g.b==26&&ea(a.g.f)==c,h=b.b==20&&b.g.b==26&&ea(b.g.f)==c;
16
+ if(f&&h&&b.f==a.f){for(var l=ua(a.f),m=a.g.k,g=b.g.k;m&&g;){var i=G(m),n=G(g);if(!i||i.b^d||!n||n.b^d)return null;o(l,e(i,n)),m=m.k,g=g.k}if(!m&&!g)return l}else if(f&&b.b==d){for(var k=ua(a.f),p=a.g.k;p;p=p.k){var t=G(p);if(!t||t.b^d)return null;o(k,e(t,b))}return k}else if(a.b==d&&h){for(var w=ua(b.f),v=b.g.k;v;v=v.k){var q=G(v);if(!q||q.b^d)return null;o(w,e(a,q))}return w}return null}function Yd(a,b,c){return a.b==29&&b.b==29?s(na(new Lh(29),c(a.h,b.h)),$):Xd(a,b,$,29,function(d,e){return s(na(new Lh(29),c(d.h,e.h)),$)})}function Zd(a,b,c){return a.b==30&&b.b==30?s(_(new Lh(30),c(a.h|0,b.h|0)),fa):Xd(a,b,fa,30,function(d,e){return s(_(new Lh(30),c(d.h|0,e.h|0)),fa)})}function wf(a,b){var c=G(a.g);return c&&c.b==28?s(Ca(new Lh(28),b(!!c.h)),aa):null}function _d(a,b,c){var e,d=G(a.g);return d&&((e=uf(d,b))||vf(d,c))}function ad(a,b){var c=G(a.g),d=G(a.i);return c&&d&&c.b==28&&d.b==28?s(Ca(new Lh(28),b(!!c.h,!!d.h)),aa):null}function bd(a,b,c){var f,d=G(a.g),e=G(a.i);return d&&e?(f=Yd(d,e,b))||Zd(d,e,c):null}
17
+ function xc(a,b){var c=G(a.g),d=G(a.i);if(c&&d){if(c.b==29&&d.b==29)return s(Ca(new Lh(28),b(c.h,d.h)),aa);if(c.b==30&&d.b==30)return s(Ca(new Lh(28),b(c.h|0,d.h|0)),aa)}return null}function $d(a,b,c){for(var d=0,e=0,f=a.length;e<f;){var h=a.charCodeAt(e);e=e+1|0,yc(h)&&(d=d+1|0,h==13&&e<f&&a.charCodeAt(e)==10&&(e=e+1|0))}return d>2&&(d=2),bc(c,d)}function xf(a,b,c){switch(c){case 48:switch(b){case 65:return!0;case 96:return!1}break;case 47:switch(b){case 62:return!0;case 96:return!1}break;case 65:if(b==65)return!0;break;case 62:if(b==62)return!0;break;case 85:if(Cd(b)||b==88)return!1;break;case 84:if(Cd(b)||b==88)return!1;break;case 81:case 90:case 89:case 88:case 82:return!1;case 87:if(b==83)return!1;break}switch(b){case 85:case 84:case 82:case 49:case 46:return!1;case 65:case 62:switch(a){case 99:case 85:case 84:case 81:case 80:case 90:case 49:case 46:case 32:case 12:return!1}if(Jg(a))return!1;break;case 48:case 47:if(c==96)return!1;break}return!0}function yc(a){return a==10||a==13}function yf(a){for(var b=0,c=a.length;b<c;b=b+1|0)if(yc(a.charCodeAt(b)))return!0;
18
+ return!1}function ae(a){return a==32||a==9}function zc(a){for(var b=0,c=a.length;b<c;b=b+1|0)if(!ae(a.charCodeAt(b)))return!1;return!0}function zf(a){for(var b=a.length;ae(a.charCodeAt(b-1|0));)b=b-1|0;return a.slice(0,b)}function Af(a,b,c,d){for(var e=[],f=0,h=0,l=a.length;h<l;h=h+1|0){var m=a.charCodeAt(h);yc(m)&&(e.push(a.slice(f,h)),m==13&&(h+1|0)<l&&a.charCodeAt(h+1|0)==10&&(h=h+1|0),f=h+1|0)}e.push(a.slice(f));for(var g=b.length;g>0&&!yc(b.charCodeAt(g-1|0));)g=g-1|0;for(var i=b.slice(g),n=i,q=0,K=e.slice(1),C=K.length;q<C;q=q+1|0){var k=K[q];if(!zc(k)){for(var p=0,t=k.length;p<t&&p<n.length&&k.charCodeAt(p)==n.charCodeAt(p);)p=p+1|0;n=n.slice(0,p)}}for(var w='',F=0,O=e.length;F<O;F=F+1|0){var v=e[F];w==''?(zc(i)&&(w+=i.slice(n.length)),w+=v):(w+=d,zc(v)||(w+=c+v.slice(n.length)))}return w}function Bf(a,b,c,d){var e=new Kh,f=new Zh('<stdin>',a),h=Nc(e,f,1);if(e.d)return a;var l='',m=99,g=99,i=0,n=0,k=!0,p=0,t=null,w=function(v){return!zc(a.slice(h[v-1|0].a.c,h[v].a.b))},q=function(K,C){switch(K){case 90:case 87:
19
+ return!0;case 4:case 9:case 10:case 11:case 12:case 15:case 17:case 32:case 43:return!C}return!1},F=null,O=function(){for(var la=1,L=p;L<h.length;L=L+1|0){switch(h[L].b){case 0:case 1:continue;case 83:la=0;break}break}n=n+la|0,F(),n=n-la|0},ha=function(){var ga=1;return h[p].b==85&&w(p+1|0)&&(ga=0),n=n+ga|0,t(function(Z){return Z==85})?(n=n-ga|0,!0):(n=n-ga|0,!1)};F=function(){for(;t(function(ba){return ba==0||ba==1}););switch(h[p].b){case 99:case 87:return!1;case 45:case 44:t(function(sa){return!0});break;case 17:t(function(ca){return!0}),ha()&&O(),h[p].b^12||F();break;case 15:case 43:t(function(ma){return!0}),ha()&&O();break;case 11:t(function(ya){return!0}),O(),t(function(La){return La==43})&&(ha(),t(function(ka){return ka==90}));break;case 12:if(t(function(cb){return!0}),h[p].b^17)O();else{var Ma=w(p);Ma&&(n=n+1|0),t(function(Ua){return!0}),ha()&&O(),Ma&&(n=n-1|0)}break;case 83:case 90:t(function(wa){return!0});break;case 91:case 92:case 93:case 94:for(t(function(za){return!0});t(function(db){return!w(p)}););
20
+ break;default:var Ja=Cd(h[p].b);if(t(function(Ka){return!0}),Ja&&t(function(eb){return eb==96})&&t(function(rb){return rb==85}))t(function(sb){return sb==83})||t(function(Wb){return Wb==90});else{for(var tb=!1;!tb&&w(p)&&(tb=!0,n=n+1|0),t(function(nc){return!q(nc,!1)}););t(function(ab){return ab==90}),tb&&(n=n-1|0)}break}return!0};var Rc=function(){for(var fb=[],gb=p;gb<h.length;){var ub=h[gb].b;switch(ub){case 83:case 84:case 85:fb.push(ub);break;case 87:if(!fb.length)return gb;if(fb.pop()^83)return-1;break;case 88:if(!fb.length||fb.pop()^84)return-1;break;case 89:if(!fb.length||fb.pop()^85)return-1;break}gb=gb+1|0}return-1},vb=-1,Xb=function(){var Bb=Rc(),Yb=Bb!=-1&&yf(a.slice(h[p-1|0].a.c,h[Bb].a.b));for(Yb&&(vb=p),n=n+1|0;F(););n=n-1|0,Yb&&(vb=p),t(function(Cb){return Cb==87})},Na=!1,Sc=function(){var oc=!Na;for(Na=!0,oc&&(n=n+1|0);t(function(Gd){return Gd!=89}););oc&&(n=n-1|0),t(function(Tc){return Tc==89})},pc=function(){var Zb=!Na;for(Na=!0,Zb&&(n=n+1|0);t(function(qc){return qc!=88}););Zb&&(n=n-1|0),t(function(Db){
21
+ return Db==88})};for(t=function(wb){var xa=h[p];if(!wb(xa.b)||xa.b==99)return!1;var Eb=vb^p?g^99?$d(a.slice(i,xa.a.b),b,c):'':'\n';p=p+1|0,l+=Eb,Eb!=''&&(k=!0,Na=!1),k?l+=bc(b,n):xf(m,g,xa.b)&&(l+=' ');var Va=N(xa.a);switch(xa.b){case 0:Va=zf(Va);break;case 1:Va=Af(Va,a.slice(0,xa.a.b),bc(b,n),c);break}l+=Va,m=g,g=xa.b,i=xa.a.c,k=!1;switch(xa.b){case 83:Xb();break;case 85:Sc();break;case 84:pc();break}return!0};F()||t(function(Uc){return Uc!=99}););var uc=$d(a.slice(i),b,c);switch(d){case 0:uc!=''&&(l+=c);break;case 2:l!=''&&(l+=c);break}return l}function Cf(a){return a.f!=null?new Bh(D(a.h)+' '+a.f+';',''):a.d&&new Bh(Ac(a.d),Bc(a.d.f))}function Cc(b,a){return a.a==b.a&&lc(a,b.b)}function cd(b,a){return Cc(b,a.b)?(b.c=M(a),b.d=a,b.e=a.b,!0):!1}function dd(b,a){return cd(b,a)||Qa(b,a.q)||Qa(b,a.C)||Qa(b,P(a))}function Df(c,a){for(var d=0,e=a.n,f=e.length;d<f;d=d+1|0){var b=e[d];if(dd(c,b))return!0}return cd(c,a)||Qa(c,a.k)||Qa(c,a.p)}function Ef(c,a){for(var d=0,e=a.i,f=e.length;d<f;d=d+1|0){var b=e[d];if(dd(c,
22
+ b))return!0}return cd(c,a)}function Qa(c,a){var d;if(!a)return!1;for(var b=a.g;b;b=b.k)if(Qa(c,b))return!0;switch(a.b){case 23:if(Cc(c,a.c))return c.c=a.f,c.d=a.e,c.e=a.c,!0;break;case 26:if(Cc(c,a.c))return c.c=a.f,c.d=((d=c.c).b?d.b:c.c).a,c.e=a.c,!0;break;case 21:if(Cc(c,a.d))return c.c=a.f,Ed(a.g.f)?(c.f=a.l,c.h=a.f):c.d=a.e,c.e=a.d,!0;break;case 2:return dd(c,a.e);case 11:return Df(c,a.e);case 16:return Ef(c,a.e)}return!1}function ce(d,a){switch(a.b){case 16:case 11:de(d,a.e);break;case 17:for(var b=a.g.k;b;b=b.k)de(d,b.e);break;case 0:for(var c=a.g;c;c=c.k)ce(d,c);break}}function de(b,a){a.b&&a.b.a==b.a&&b.b.push(a)}function Ff(l,a){var b=new Ch(l.a,l.b);if(Qa(b,a),l.d=b.d,l.d){jb(l,a);var c=null;l.c.sort(function(d,e){return d.a==e.a?Wc(d.b,e.b):af(d.a.a,e.a.a)}),Gb(l.c,function(f){var h=c;return c=f,h!=null&&pg(c,h)})}}function ib(c,a,b){b==c.d&&a&&N(a)==c.d.c&&c.c.push(a)}function ed(b,a){ib(b,a.b,a),jb(b,a.q),jb(b,a.C),jb(b,P(a))}function Gf(c,a){ib(c,a.b,a),ib(c,a.b,a.w),jb(c,a.k),jb(c,a.p);for(var d=0,e=a.n,f=e.length;d<f;d=d+1|0){
23
+ var b=e[d];ed(c,b)}}function Hf(c,a){ib(c,a.b,a);for(var d=0,e=a.i,f=e.length;d<f;d=d+1|0){var b=e[d];ed(c,b)}}function jb(c,a){if(a){for(var b=a.g;b;b=b.k)jb(c,b);switch(a.b){case 23:ib(c,a.c,a.e);break;case 21:ib(c,a.d,a.e);break;case 26:ib(c,a.c,a.f.a);break;case 2:ed(c,a.e);break;case 11:Gf(c,a.e);break;case 16:Hf(c,a.e);break}}}function If(c,a){W(c,'keyword','false'),W(c,'keyword','true'),W(c,'keyword','void'),W(c,'keyword','const'),W(c,'keyword','lowp'),W(c,'keyword','mediump'),W(c,'keyword','highp');for(var d=0,e=Rg.length;d<e;d=d+1|0){var b=Rg[d];W(c,'struct',b.a.c).c=Ac(b.a)}gd(c,a)}function fd(b,a){return a!=null&&a.a==b.a&&lc(a,b.b)}function W(d,a,b){var c=null;return d.c.has(b)?c=d.c.get(b):(c=new Fh(a,b),d.d.push(c),Oa(d.c,b,c)),c}function fc(d,a){var b=a instanceof mc?'function':a instanceof ac?'struct':'variable',c=W(d,b,a.c);c.c!=''?c.c+='\n':c.d=Bc(a.f),c.c+=Ac(a)}function gd(C,a){if(!a)return!1;var b=fd(C,a.c);switch(a.b){case 0:for(var c=!1,d=a.g;d;d=d.k)if(d.b==11&&fd(C,d.c)){c=!0;break}c||(W(C,
24
+ 'keyword','precision'),W(C,'keyword','uniform'),W(C,'keyword','attribute'),W(C,'keyword','varying'));break;case 11:if(fc(C,a.e),b){var e=a.e;W(C,'keyword','discard'),W(C,'keyword','return');for(var F=0,O=e.n,la=O.length;F<la;F=F+1|0){var f=O[F];fc(C,f)}gd(C,e.p)}break;case 2:fc(C,a.e);break;case 16:fc(C,a.e);break;case 10:case 19:case 7:b&&(W(C,'keyword','break'),W(C,'keyword','continue'));break;case 21:var h=a.g;if(b&&!fd(C,h.c)){C.d=[];var l=h.f;switch(l){case Tb:case yb:case Ga:case Ub:case zb:case Ha:case Vb:case Ab:case Ia:for(var L=0,ha=zd(Fa(l)),ga=ha.length;L<ga;L=L+1|0)for(var m=ha[L],g=1;g<5;g=g+1|0){for(var i=[],n=0;n<g;n=n+1|0)i.push(0);for(;;){for(var k='',p=0;p<g;p=p+1|0)k+=m[i[p]];var t=Ad(ea(l),k.length).a;W(C,'variable',k).c=t.c+' '+k+';';for(var w=0;w<g;){var v=i[w];if((v=v+1|0)^m.length||(v=0),i[w]=v,v)break;w=w+1|0}if(w==g)break}}break;default:if(l.a&&l.a instanceof ac)for(var Z=0,ba=l.a.i,sa=ba.length;Z<sa;Z=Z+1|0){var q=ba[Z];fc(C,q)}break}return!0}break}if(!a.b||b||a.b==17)for(var K=a.g;K;K=K.k)if(gd(C,
25
+ K))return!0;return b}function ee(b,a){return a!=null&&a.a==b.a&&lc(a,b.b)}function hd(ka,a){if(!a||a.b&&!ee(ka,a.c))return!1;for(var b=a.g;b;b=b.k)if(hd(ka,b))return!0;switch(a.b){case 11:return hd(ka,a.e.p),!0;case 20:var c=a.g;if(!ee(ka,c.c)){for(var d=c.k,e=c.f,f=e.a,h=[],l=d;l;l=l.k)h.push(l);if(f instanceof mc){for(var m=[],g=f;g;g=g.t)~m.indexOf(g.w)||m.push(g);m.reverse();for(var cb=0,Ma=m.length;cb<Ma;cb=cb+1|0){var i=m[cb];ka.c.push(new Hh(Ac(i),i.n.map(function(n){return ec(n)}),Bc(i.f)))}if(ka.c.length){ka.e=0;for(var k=[],p=0;p<m.length;p=p+1|0)k.push(p);for(var t=h.length;t>0;t=t-1|0){for(var w=[],Ua=0,wa=k,za=wa.length;Ua<za;Ua=Ua+1|0){var v=wa[Ua];m[v].n.length>=t&&w.push(v)}if(w.length){k=w;break}}if(k.length>1){var q=k.slice();Gb(q,function(K){for(var C=m[K].n,F=0,db=Math.min(C.length,h.length);F<db;F=F+1|0){var O=C[F].q.f,la=h[F].f;if(la!=I&&O!=la)return!0}return!1}),q.length||(q=k.slice(),Gb(q,function(L){for(var ha=m[L].n,ga=0,Ja=Math.min(ha.length,h.length);ga<Ja;ga=ga+1|0){var Z=ha[ga].q.f,ba=h[ga].f,sa=Fa(Z),ca=Fa(ba);
26
+ if(ba!=I&&Z!=ba&&(!sa||!ca||sa^ca))return!0}return!1})),q.length&&(k=q)}k.length&&(ka.e=k[0])}}if(f instanceof ac&&!ea(e)){var ma=f.i.map(function(ya){return ec(ya)});ka.c.push(new Hh(f.c+'('+ma.join(', ')+');',ma,Bc(f.f))),ka.e=0}if(h.length){ka.d=0;for(var Ka=0,eb=h.length;Ka<eb;Ka=Ka+1|0){var La=h[Ka];if(ka.b<=La.c.c||!La.k)break;ka.d=ka.d+1|0}}return!0}break}return!1}function be(a){switch(a.b){case 30:return (a.h|0).toString();case 28:return (!!a.h).toString();case 29:return Qd(a.h,0);case 20:for(var b=a.g,c=D(a.f)+'(',d=b.k;d;d=d.k)d.n!=b&&(c+=', '),c+=be(d);return c+')'}return null}function Ac(a){if(a instanceof ac){var b=a,c=_a(b.e)+'struct '+a.c;if(b.a>-1){c+=' {\n';for(var i=0,n=b.i,k=n.length;i<k;i=i+1|0){var d=n[i];c+=' '+ec(d)+';\n'}c+='}'}return c+';'}if(a instanceof Me){var e=a,f=ec(e);if(e.h){var h=be(e.h);h!=null&&(f+=' = '+h)}return f+';'}if(a instanceof mc){for(var l=a,m=_a(l.e)+D(l.k.f)+' '+a.c+'(',p=0,t=l.n,w=t.length;p<w;p=p+1|0){var g=t[p];g!=l.n[0]&&(m+=', '),m+=ec(g)}return m+');'}return null}
27
+ function ec(a){var b=a.q.f,c=_a(a.e)+D(b.b||b)+' '+a.c;return b.b&&(c+=b.c?'['+b.c+']':'[]'),c}function Bc(a){var b='';if(a)for(var f=0,h=a.length;f<h;f=f+1|0){var c=a[f],d=0,e=c.length;for(c.startsWith('//')?d=d+2|0:c.startsWith('/*')&&(d=d+2|0,e=e-2|0);d<e&&c.charCodeAt(d)==32;)d=d+1|0;for(;e>d&&c.charCodeAt(e-1|0)==32;)e=e-1|0;b!=''&&(b+='\n'),b+=c.slice(d,e)}return b}function fe(a,b,c){if(!b)return a+': '+c+'\n';var d=sd(b,0);return rd(b)+': '+a+': '+c+'\n'+d.a+'\n'+d.b+'\n'}function Jf(c){for(var a=new ph,d=0,e=c.a,f=e.length;d<f;d=d+1|0){var b=e[d];a.a+=fe(b.a?'warning':'error',b.b,b.c),b.d&&(a.a+=fe('note',b.d,b.e))}return a.a}function u(c,a,b){(!c.e||c.e.b^a.b)&&(c.e=a,c.a.push(new Jh(0,a,b)),c.d=c.d+1|0)}function Kf(c,a,b){c.a.push(new Jh(1,a,b)),c.c=c.c+1|0}function Dc(d,a,b){var c=Xc(d.a);c.d=a,c.e=b}function Lf(b,a){u(b,a,'"'+N(a)+'" is a reserved word')}function Mf(b,a){u(b,a.a,'Unexpected '+Ue[a.b])}function Nf(b,a){u(b,a,'There is no symbol called "'+N(a)+'" in the current scope')}function id(c,a,b){
28
+ u(c,a,'There is already a symbol called "'+N(a)+'" in the current scope'),Dc(c,b,'The previous definition of "'+N(b)+'" is here')}function Of(f,a,b,c,d,e){u(f,a,'Cannot change the return type of "'+b+'" to type "'+D(c)+'"'),Dc(f,e,'The forward declaration of "'+b+'" has a return type of "'+D(d)+'"')}function ge(b,a){u(b,a,'The operator "'+N(a)+'" is reserved and cannot be used')}function Pf(e,a,b,c,d){u(e,a,'The constructor for type "'+D(b)+'" only takes '+c+' argument'+(c^1?'s':'')+' and this argument would bring the total to '+d)}function Qf(d,a,b,c){u(d,a,'Cannot construct type "'+D(b)+'" with '+c+' argument'+(c^1?'s':''))}function Rf(f,a,b,c,d,e){u(f,a,'Expected '+b+' argument'+(b^1?'s':'')+' but found '+c+' argument'+(c^1?'s':'')+' when calling function "'+d+'"'),e&&Dc(f,e,'The definition of function "'+d+'" is here')}function Sf(f,a,b,c,d,e){u(f,a,'Expected '+b+' argument'+(b^1?'s':'')+' but found '+c+' argument'+(c^1?'s':'')+' when constructing type "'+d+'"'),e&&Dc(f,e,'The definition of struct "'+d+'" is here')}
29
+ function Tf(c,a,b){b.b?u(c,a,'Cannot use a conditional expression with array type "'+D(b)+'"'):u(c,a,'Cannot use a conditional expression with type "'+D(b)+'" because it contains an array')}function he(c,a,b){b.b?u(c,a,'Cannot assign to array type "'+D(b)+'"'):u(c,a,'Cannot assign to type "'+D(b)+'" because it contains an array')}function Uf(e,a,b,c,d){c==d?u(e,a,'There is no operator "'+b+'" defined for type "'+D(c)+'"'):u(e,a,'No binary operator "'+b+'" for type "'+D(c)+'" and type "'+D(d)+'"')}function je(b,a){b.b=a.b,b.c=a.c,b.d=a.d,b.e=a.e,b.f=a.f,b.h=a.h,b.l=a.l}function ke(b){var a=new Lh(b.b);return je(a,b),a}function md(b){for(var a=ke(b);b.g;)o(a,r(b.g));return a}function Xa(c){for(var a=ke(c),b=c.g;b;b=b.k)o(a,Xa(b));return a}function H(b,a){a!=b&&(je(b,a),Yf(b),Xf(b,a))}function le(a){return a.g!=null&&a.g==a.i}function gc(c,a){for(var b=c.g;a;)b=b.k,a=a-1|0;return b}function s(b,a){return b.f=a,b}function Gc(b,a){return b.e=a,b}function Ca(b,a){return b.h=+a,b}function _(b,a){return b.h=a,b}function na(b,a){
30
+ return b.h=a,b}function hc(b,a){return b.l=a,b}function x(b,a){return b.c=a,b}function Ra(b,a){return b.d=a,b}function o(b,a){return a?(a.m=b,b.g?(a.n=b.i,b.i.k=a,b.i=a):b.i=b.g=a,b):b}function Xf(b,a){for(;a.g;)o(b,r(a.g));return b}function r(a){return a.n?a.n.k=a.k:a.m.g=a.k,a.k?a.k.n=a.n:a.m.i=a.n,a.m=null,a.n=null,a.k=null,a}function Yf(a){for(;a.g;)r(a.g)}function ia(b,a){return a.m=b.m,a.n=b.n,a.k=b.k,b.n?b.n.k=a:b.m.g=a,b.k?b.k.n=a:b.m.i=a,b.m=null,b.n=null,b.k=null,b}function Hc(c,a,b){return b?a?(b.m=c,b.n=a.n,b.k=a,a.n?a.n.k=b:c.g=b,a.n=b,c):o(c,b):c}function me(a){for(;a.g;)Hc(a.m,a.k,r(a.i));r(a)}function Sa(a){return a.b==28&&!!a.h}function Ib(a){return a.b==28&&!!!a.h}function ic(b,a){return b.b==30&&(b.h|0)==a||b.b==29&&b.h==a}function Zf(a){return a.m!=null&&a.m.b==20&&a.m.g==a}function ne(f){if(f.m){if(ld(f.m.b)||Fc(f.m.b)&&f.m.g==f)return!0;if(f.m.b==20&&f.m.f!=I){var a=f.m.g,b=a.e;if(b&&b instanceof mc)for(var c=b,d=0,e=a.k;e;e=e.k){if(e==f)return (c.n[d].e&16)!=0;d=d+1|0}}}return!1}function oe(a){
31
+ return ne(a)?!0:a.m&&(a.m.b==21||a.m.b==43)?oe(a.m):!1}function pe(a){return a.b==3&&a.g==null}function nd(a){return a.b==25&&a.g==null}function _f(a){return a.b==30&&(a.h|0)<0||a.b==29&&a.h<0}function oa(a){switch(a.b){case 28:case 29:case 30:case 23:return!0;case 22:return oa(a.g)&&oa(a.g.k)&&oa(a.i);case 21:return oa(a.g)}return kd(a.b)?!ld(a.b)&&oa(a.g):Ec(a.b)?!Fc(a.b)&&oa(a.g)&&oa(a.i):!1}function Jb(a){switch(a.b){case 28:Ca(a,!!!a.h);break;case 32:H(a,r(a.g));break;case 40:a.b=50;break;case 50:a.b=40;break;case 44:a.b=42;break;case 41:a.b=45;break;case 45:a.b=41;break;case 42:a.b=44;break;case 25:Jb(a.i);break;case 47:a.b=46,Jb(a.g),Jb(a.i);break;case 46:a.b=47,Jb(a.g),Jb(a.i);break;default:H(a,s(o(new Lh(32),md(a)),aa));break}}function pa(d,a){if(d.b==a.b){switch(d.b){case 28:return !!d.h==!!a.h;case 29:return d.h==a.h;case 30:return (d.h|0)==(a.h|0);case 23:return d.e==a.e;case 26:return d.f==a.f;case 21:return pa(d.g,a.g)&&d.e==a.e&&d.l==a.l;case 22:return pa(d.g,a.g)&&pa(d.g.k,a.g.k)&&pa(d.i,a.i);case 20:
32
+ for(var b=d.g,c=a.g;b&&c;){if(!pa(b,c))return!1;b=b.k,c=c.k}return b==null&&c==null}if(kd(d.b))return pa(d.g,a.g);if(Ec(d.b))return pa(d.g,a.g)&&pa(d.i,a.i)}return!1}function qe(a,b,c,d){return o(o(o(o(new Lh(10),a||new Lh(25)),b||new Lh(25)),c||new Lh(25)),d)}function ua(a){return s(o(new Lh(20),s(new Lh(26),a)),a)}function kb(a){return nd(a.g)?null:a.g}function Da(a){return nd(a.g.k)?null:a.g.k}function Ic(a){return nd(a.i.n)?null:a.i.n}function re(){return Ve=Ve+1|0,Ve}function da(a){return function(b,c){return x(s(new Lh(26),a),c.a)}}function jc(a){return function(b,c,d){return Ra(x(o(new Lh(a),d),Za(c.a,d.c)),c.a)}}function se(a){return function(b,c,d){return Ra(x(o(new Lh(a),c),Za(c.c,d.a)),d.a)}}function X(a){return function(b,c,d,e){return Ra(x(o(o(new Lh(a),c),e),Za(c.c,e.c)),d.a)}}function $f(a){return a.length>1&&a.charCodeAt(0)==48&&a.charCodeAt(1)^120&&a.charCodeAt(1)^88?parseInt(a,8):a|0}function ag(){var a=new Qh,b=function(c,d,e){return ge(c.a,d.a),x(s(new Lh(27),I),Za(d.a,e.c))},f=function(h,l,m,g){
33
+ return ge(h.a,m.a),x(s(new Lh(27),I),Za(l.c,g.c))};return R(a,36,function(i,n){return x(s(Ca(new Lh(28),!0),aa),n.a)}),R(a,13,function(k,p){return x(s(Ca(new Lh(28),!1),aa),p.a)}),R(a,97,function(t,w){return x(s(_(new Lh(30),$f(N(w.a))),fa),w.a)}),R(a,95,function(v,q){return x(s(na(new Lh(29),+N(q.a)),$),q.a)}),R(a,3,da(aa)),R(a,5,da(Tb)),R(a,6,da(Ub)),R(a,7,da(Vb)),R(a,14,da($)),R(a,20,da(fa)),R(a,22,da(yb)),R(a,23,da(zb)),R(a,24,da(Ab)),R(a,26,da(ob)),R(a,27,da(pb)),R(a,28,da(qb)),R(a,39,da(Ga)),R(a,40,da(Ha)),R(a,41,da(Ia)),R(a,42,da(Hd)),Ob(a,46,14,b),Ob(a,47,14,jc(34)),Ob(a,48,14,jc(35)),Ob(a,62,14,jc(31)),Ob(a,49,14,jc(32)),Ob(a,65,14,jc(33)),Be(a,47,15,se(36)),Be(a,48,15,se(37)),S(a,53,13,X(39)),S(a,54,10,X(40)),S(a,55,10,X(41)),S(a,56,10,X(42)),S(a,57,10,X(44)),S(a,58,10,X(45)),S(a,62,12,X(51)),S(a,63,13,X(49)),S(a,64,10,X(50)),S(a,65,12,X(38)),S(a,66,13,f),S(a,67,11,f),S(a,68,11,f),S(a,60,3,X(47)),S(a,61,4,X(48)),S(a,59,5,X(46)),S(a,50,8,f),S(a,51,6,f),S(a,52,7,f),va(a,69,2,X(52)),va(a,70,2,X(53)),va(a,
34
+ 71,2,f),va(a,72,2,f),va(a,73,2,f),va(a,74,2,X(54)),va(a,75,2,X(55)),va(a,76,2,f),va(a,77,2,f),va(a,78,2,f),va(a,79,2,X(56)),R(a,96,function(K,C){var F=N(C.a),O=xd(K.m,F);return O?(O.l!=null&&Aa(K.c.a,O.l,0)==1&&u(K.a,C.a,'Cannot use "'+F+'" from disabled extension "'+O.l+'"'),O.g=O.g+1|0,x(O instanceof ac?s(new Lh(26),M(O)):Gc(new Lh(23),O),C.a)):(Nf(K.a,C.a),x(s(new Lh(24),I),C.a))}),S(a,81,1,function(la,L,ha,ga){return L.b^25&&(L=x(o(new Lh(25),L),L.c)),o(L,ga),x(L,B(la,L.c))}),Ea(a,82,16).c=function(Z,ba){var sa=z(Z).a;E(Z);var ca=z(Z).a;return A(Z,96)?Ra(x(hc(o(new Lh(21),ba),N(ca)),B(Z,ba.c)),ca):Ra(x(hc(o(new Lh(21),ba),''),B(Z,ba.c)),De(sa))},Ea(a,85,0).b=function(ma){var ya=E(ma),La=U(a,ma,0);return !La||!A(ma,89)?x(s(new Lh(24),I),B(ma,ya.a)):x(La,B(ma,ya.a))},Ea(a,85,15).c=function(ka,cb){var Ma=E(ka),Ua=o(new Lh(20),cb);return bg(ka,Ua,89)?Ra(x(Ua,B(ka,cb.c)),B(ka,Ma.a)):x(s(new Lh(24),I),B(ka,Ma.a))},Ea(a,84,16).c=function(wa,za){var db=E(wa);if(z(wa).b==88)return Mb(wa),E(wa),x(s(new Lh(24),I),B(wa,
35
+ db.a));var Ja=U(a,wa,0);return !Ja||!A(wa,88)?x(s(new Lh(24),I),B(wa,db.a)):Ra(x(o(o(new Lh(43),za),Ja),B(wa,za.c)),B(wa,db.a))},Ea(a,86,2).c=function(Ka,eb){var rb=E(Ka),sb=U(a,Ka,1);if(!sb||!A(Ka,80))return x(s(new Lh(24),I),B(Ka,rb.a));var Wb=U(a,Ka,1);return Wb?x(o(o(o(new Lh(22),eb),sb),Wb),B(Ka,eb.c)):x(s(new Lh(24),I),B(Ka,rb.a))},a}function bg(a,b,c){for(var d=!0;!Q(a,c);){d||A(a,81);var e=z(a),f=U(bb,a,1);if(f)o(b,f);else if(o(b,x(s(new Lh(24),I),B(a,e.a))),z(a).b^81&&z(a).b^c)return!1;d=!1}return!0}function cg(a){var b=E(a);a.m=new Xh(3,a.m);var c=Ya(a,2);if(!c||!A(a,43)||!A(a,85))return null;var d=U(bb,a,0);return !d||!A(a,89)?null:(Nb(a),Kb(a,b.a,o(o(new Lh(7),c),d)))}function dg(a){var b=E(a),c=a.h;if(a.h|=b.b^44?2048:1024,Q(a,83)){var d=new Lh(13);return !kc(a,d,1)||!A(a,87)?null:(a.h=c,x(d,B(a,b.a)))}var e=Ya(a,1);return e&&(a.h=c,e)}function fg(a){var b=E(a),c=z(a).a;if(!A(a,96))return null;var d=N(c);if(Q(a,83)){a.c.a.has(d)||Oa(a.c.a,d,0);var e=new Lh(13);if(!kc(a,e,1)||!A(a,87))return null;for(var f=e.g;f;f=f.k)if(f.b^17)f.e&&(f.e.l=d);
36
+ else for(var h=f.g.k;h;h=h.k)h.e.l=d;return x(e,B(a,b.a))}if(!dh.has(d)&&!a.c.a.has(d)&&Kf(a.a,c,'The extension "'+d+'" is not in the known list of valid WebGL extensions'),!A(a,80))return null;var l=N(z(a).a);if(!eg.has(l))return Mb(a),null;E(a);var m=eg.get(l);return Oa(a.c.a,d,m),Ra(x(_(hc(new Lh(9),d),m),B(a,b.a)),c)}function gg(a){var b=E(a);if(a.m=new Xh(3,a.m),!A(a,85))return null;var c=null;if(!Q(a,90)){var d=ve(a),e=od(a,2),f=null;if(e){if(f=Lb(a,1),!f)return null}else f=Lb(a,0);if(f){if(c=ue(a,b.a,e,f,0,d),!c)return null}else if((c=U(bb,a,0),!c)||!A(a,90))return null}var h=null;if(!Q(a,90)&&((h=U(bb,a,0),!h)||!A(a,90)))return null;var l=null;if(!Q(a,89)&&((l=U(bb,a,0),!l)||!A(a,89)))return null;var m=Ya(a,2);return m&&(Nb(a),x(qe(c,h,l,m),B(a,b.a)))}function hg(a){var b=E(a);if(!A(a,85))return null;var c=z(a),d=U(bb,a,0);if(d||(d=x(s(new Lh(24),I),B(a,c.a))),!A(a,89))return null;var e=Ya(a,2);if(!e)return null;var f=null;return Q(a,12)&&(f=Ya(a,2),!f)?null:x(o(o(o(new Lh(12),d),e),f),B(a,b.a))}function ig(a){
37
+ var b=E(a),c=z(a).a;return A(a,97)?x(_(new Lh(18),N(c)|0),B(a,b.a)):null}function jg(a){var b=E(a);if(a.m=new Xh(3,a.m),!A(a,85))return null;var c=z(a),d=U(bb,a,0);if(d||(d=x(s(new Lh(24),I),B(a,c.a))),!A(a,89))return null;var e=Ya(a,2);return e&&(Nb(a),x(o(o(new Lh(19),d),e),B(a,b.a)))}function kg(a){var b=E(a),c=null;if(!Q(a,90)){var d=z(a);c=U(bb,a,0),c||(c=x(s(new Lh(24),I),B(a,d.a))),A(a,90)}return x(o(new Lh(15),c),B(a,b.a))}function lg(a){var b=E(a),c=0;switch(z(a).b){case 25:c=32;break;case 29:c=64;break;case 16:c=4;break;default:return Mb(a),null}E(a);var d=Lb(a,1);return d&&Kb(a,b.a,o(_(new Lh(14),c),d))}function mg(a,b,c){var d=z(a).a;if(!A(a,96))return null;var e=new ac(wc(a.c),d,N(d),new Xh(4,a.m));if(e.e|=a.h|b,e.f=c,!pd(a,e))return null;var f=z(a).a,h=new Lh(1),l=null;if(!A(a,83))return null;for(a.m=e.d;z(a).b^87&&z(a).b^99;){var m=Ya(a,3);if(!m)return null;if(m.b^17)u(a.a,m.c,'This statement cannot be used inside a struct');else{o(h,m);for(var g=m.g.k;g;g=g.k){var i=g.e;e.i.push(i),P(i)&&u(a.a,
38
+ P(i).c,'Cannot initialize struct variables')}}}if(Nb(a),!A(a,87))return null;if(x(h,B(a,f)),z(a).b^96)A(a,90);else if(l=ze(0,s(new Lh(26),M(e)),E(a).a,a,c),!l)return null;return o(o(Gc(new Lh(16),e),h),l)}function te(a,b,c){for(var d=!1,e=a.m;e;e=e.b)if(e.a==3){d=!0;break}return d||u(a.a,b,'This statement cannot be used outside a loop'),Kb(a,b,c)}function Kb(a,b,c){return A(a,90),x(c,B(a,b))}function ue(a,b,c,d,e,f){var h=z(a).a;if(!c&&z(a).b^96){var l=Ae(bb,a,0,d);return l&&Kb(a,b,o(new Lh(8),l))}if(!A(a,96))return null;if(Q(a,85))return og(c,d,h,a,f);var m=ze(c,d,h,a,f);return m&&x(m,B(a,b))}function ve(a){var b=z(a),c=b.c;if(!c)return null;for(var d=b.a.b,e=null,f=c.length-1|0;f>-1;f=f-1|0){for(var h=c[f],l=h.a.b.slice(h.c,d),m=0,g=0;g<l.length;g=g+1|0){var i=l.charCodeAt(g);(i==13||i==10)&&(m=m+1|0,i==13&&(g+1|0)<l.length&&l.charCodeAt(g+1|0)==10&&(g=g+1|0))}if(m>1)break;(e||(e=[])).push(N(h)),d=h.b}return e&&e.reverse(),e}function Ya(a,b){var c=z(a);switch(c.b){case 4:return te(a,E(a).a,new Lh(4));case 9:
39
+ return te(a,E(a).a,new Lh(5));case 10:return Kb(a,E(a).a,new Lh(6));case 11:return cg(a);case 44:case 45:return dg(a);case 91:return fg(a);case 15:return gg(a);case 17:return hg(a);case 83:return xe(a);case 31:return lg(a);case 32:return kg(a);case 90:return x(new Lh(3),E(a).a);case 92:return ig(a);case 43:return jg(a)}var d=ve(a),e=od(a,b),f=null;if(Q(a,35)){var h=mg(a,e,d);return h&&x(h,B(a,c.a))}if(e){if(f=Lb(a,1),!f)return null}else f=Lb(a,0);if(f)return ue(a,c.a,e,f,1,d);var l=U(bb,a,0);return l&&Kb(a,c.a,o(new Lh(8),l))}function we(a,b){if(b.b^17&&b.b^16){var c=a.m.a==1||a.m.a==4,d=b.b==9||b.b==11||b.b==14||b.b==18;d&&!c?u(a.a,b.c,'This statement cannot be used inside a function'):!d&&c&&u(a.a,b.c,'This statement cannot be used outside a function')}}function ng(a,b){var c=z(a).a;if(!A(a,98))return!1;var d=null;try{d=JSON.parse(N(c))}catch(m){return u(a.a,c,'Invalid string literal'),!1}var e=a.c.b;if(!e)return u(a.a,c,'Cannot include files without access to a file system'),!1;var f=e(d,c.a.a);if(!f)return u(a.a,
40
+ c,'Cannot read the file '+JSON.stringify(d)),!1;if(a.e.has(f.a))return!0;Oa(a.e,f.a,!0),a.f.push(new Nh(c,Gg(f)));var h=Nc(a.a,f,0),l=new Oh(a.a,h,a.c,a.d,a.e);return l.m=a.m,!kc(l,b,1)||!A(l,99)?!1:!0}function xe(a){var b=z(a),c=new Lh(3);return a.m=new Xh(2,a.m),!A(a,83)||!kc(a,c,2)||!A(a,87)?null:(Nb(a),x(c,B(a,b.a)))}function od(a,b){for(var c=0;;){var d=z(a).b;switch(d){case 2:c|=1;break;case 8:c|=2;break;case 16:c|=4;break;case 18:c|=8;break;case 19:c|=16;break;case 25:c|=32;break;case 29:c|=64;break;case 30:c|=128;break;case 37:c|=256;break;case 38:c|=512;break;default:return c}(!b&&(d==2||d==37||d==38)||b==3&&d^25&&d^29&&d^16||b&&(d==18||d==30||d==19))&&u(a.a,z(a).a,'Cannot use this qualifier here'),E(a)}}function Lb(a,b){var c=z(a),d=null;switch(c.b){case 3:d=aa;break;case 5:d=Tb;break;case 6:d=Ub;break;case 7:d=Vb;break;case 14:d=$;break;case 20:d=fa;break;case 22:d=yb;break;case 23:d=zb;break;case 24:d=Ab;break;case 26:d=ob;break;case 27:d=pb;break;case 28:d=qb;break;case 33:d=Pg;break;case 34:d=Qg;
41
+ break;case 39:d=Ga;break;case 40:d=Ha;break;case 41:d=Ia;break;case 42:d=Hd;break;case 96:var e=xd(a.m,N(c.a));if(!e||!(e instanceof ac))return b^1||Mb(a),null;d=M(e);break;default:return b^1||Mb(a),null}return E(a),x(s(new Lh(26),d),B(a,c.a))}function og(a,b,c,d,e){var f=d.m,h=new mc(wc(d.c),c,N(c),new Xh(0,f));if(h.e|=d.h|a|(h.c=='main'?1024:0),h.f=e,h.k=b,d.m=h.d,Q(d,42)){if(!A(d,89))return null}else if(!Q(d,89)){for(;;){var l=od(d,0),m=Lb(d,1);if(!m)return null;var g=z(d).a;if(!A(d,96))return null;var i=new Me(wc(d.c),g,N(g),d.m,0);if(i.e|=l,i.q=m,h.n.push(i),pd(d,i),!ye(d,i))return null;if(!Q(d,81))break}if(!A(d,89))return null}var n=Aa(f.c,N(c),null),k=!Q(d,90);if(n){if(n instanceof mc){for(var p=n;p;p=p.t)if(Ig(p,h)){p.k.f!=h.k.f?Of(d.a,h.k.c,h.c,h.k.f,p.k.f,p.k.c):p.p||!k?id(d.a,h.b,p.b):(p.w=h,h.w=p,h.e|=p.e,p.e=h.e);break}h.t=n,Fg(f,h)}else return id(d.a,c,n.b),null}else Le(f,h);if(k){var t=d.h;if(d.h&=-3073,h.p=xe(d),d.h&=t,!h.p)return null}return Nb(d),x(Gc(new Lh(11),h),B(d,b.c))}function ye(a,b){
42
+ var c=z(a);if(Q(a,84)){if(Q(a,88))return u(a.a,B(a,c.a),'All array sizes must be specified'),!0;if(b.C=U(bb,a,0),!b.C||!A(a,88))return!1;var d=0;if(Y(a.d,b.C),qa(a.d,b.C,fa),b.C.f!=I){var e=G(b.C);if(e){if(e.b==30){var f=e.h|0;f<1?u(a.a,b.C.c,'Cannot declare an array with a size of "'+f+'"'):d=f}}else u(a.a,b.C.c,'This value must be a compile-time constant')}for(;z(a).b==84;){if(c=E(a),z(a).b^88&&!U(bb,a,0)||!A(a,88))return!1;u(a.a,B(a,c.a),'Multidimensional arrays are not a part of the language')}b.q=x(s(new Lh(26),Mg(b.q.f,d)),b.q.c)}return!0}function ze(a,b,c,d,e){for(var f=o(_(new Lh(17),d.h|a),b);;){var h=new Me(wc(d.c),c,N(c),d.m,d.m.a^1?d.m.a^4?2:3:1);if(h.e|=d.h|a,h.f=e,h.q=b,!ye(d,h))return null;var l=z(d).a,m=null;if(Q(d,69)){var g=z(d);m=U(bb,d,1),m||(m=x(s(new Lh(24),I),B(d,g.a)))}else l=null;var i=Ra(x(o(Gc(new Lh(2),h),m),B(d,h.b)),l);if(h.K=i,h.e&2&&Y(d.d,i),o(f,i),pd(d,h),!Q(d,81))return A(d,90),f;if(c=z(d).a,!A(d,96))return null}}function pd(a,b){var c=Aa(a.m.c,b.c,null);return c?(id(a.a,b.b,c.b),
43
+ !1):(Le(a.m,b),!0)}function kc(a,b,c){for(;z(a).b^99&&z(a).b^87;){var d=z(a).a;if(Q(a,93)){if(c^1)return u(a.a,d,'"#include" statements cannot be used here'),Q(a,98),!1;if(!ng(a,b))return!1}else{var e=Ya(a,c);if(!e)return!1;if(e.b^13)we(a,e),o(b,e);else for(;e.g;){var f=r(e.g);we(a,f),o(b,f)}}}return!0}function qd(a,b,c,d,e,f){bb||(bb=ag());var h=new Map,l=new Oh(a,b,d,f,h);return l.m=e,kc(l,c,1)&&A(l,99),new Mh(l.f)}function z(a){return a.b[a.l]}function E(b){var a=z(b);return (b.l+1|0)<b.b.length&&(b.l=b.l+1|0),a}function B(c,a){var b=c.b[c.l>0?c.l-1|0:0];return b.a.c<a.b?a:Za(a,b.a)}function Q(b,a){return z(b).b^a?!1:(E(b),!0)}function A(e,a){if(Q(e,a))return!0;var b=z(e),c=b.a,d=(e.l>0?e.b[e.l-1|0]:b).a;return a==90||Ce(d).a^Ce(c).a?u(e.a,De(d),'Expected '+Ue[a]):u(e.a,c,'Expected '+Ue[a]+' but found '+Ue[b.b]),!1}function Mb(a){Mf(a.a,z(a))}function Nb(a){a.m=a.m.b}function Ea(e,a,b){var c=ta(e.a,a,null);if(c)b>c.a&&(c.a=b);else{var d=new Ph(b);c=d,Ba(e.a,a,d)}return c}function U(f,a,b){var c=z(a),d=ta(f.a,
44
+ c.b,null);if(!d||!d.b)return Mb(a),null;var e=Ae(f,a,b,d.b(a));return e}function Ae(f,a,b,c){for(;c;){var d=z(a).b,e=ta(f.a,d,null);if(!e||!e.c||e.a<=b)break;c=e.c(a,c)}return c}function R(d,a,b){Ea(d,a,0).b=function(c){return b(c,E(c))}}function Ob(h,a,b,c){Ea(h,a,0).b=function(d){var e=E(d),f=U(h,d,b);return f&&c(d,e,f)}}function Be(f,a,b,c){Ea(f,a,b).c=function(d,e){return c(d,e,E(d))}}function S(l,a,b,c){Ea(l,a,b).c=function(d,e){var f=E(d),h=U(l,d,b);return h&&c(d,e,f,h)}}function va(l,a,b,c){Ea(l,a,b).c=function(d,e){var f=E(d),h=U(l,d,b-1|0);return h&&c(d,e,f,h)}}function N(a){return a.a.b.slice(a.b,a.c)}function rd(b){var a=Rb(b.a,b.b);return b.a.a+':'+(a.a+1|0)+':'+(a.b+1|0)}function pg(b,a){return b.a==a.a&&b.b<a.c&&a.b<b.c}function lc(b,a){return b.b<=a&&a<=b.c}function sd(q,a){for(var b=Rb(q.a,q.b),c=Rb(q.a,q.c),d=Hg(q.a,b.a),e=b.b,f=c.a^b.a?d.length:c.b,h=Ye(bh,d,0),l=[],m=0,g=0;;){h.b^e||(m=l.length),h.b^f||(g=l.length);var i=Ze(h);if(i<0)break;if(i^9)l.push(i);else for(var n=0,K=8-l.length%8|0;n<K;n=n+1|0)l.push(32)}
45
+ var k=l.length;if(a>0&&k>a){var p=Math.min(g-m|0,a/2|0),t=Math.max((a-p|0)/2|0,3);if(m<t)d=vc(l.slice(0,a-3|0))+'...',g>(a-3|0)&&(g=a-3|0);else if((k-m|0)<(a-t|0)){var w=k-a|0;d='...'+vc(l.slice(w+3|0,k)),m=m-w|0,g=g-w|0}else{var v=m-t|0;d='...'+vc(l.slice(v+3|0,(v+a|0)-3|0))+'...',m=m-v|0,g=g-v|0,g>(a-3|0)&&(g=a-3|0)}}else d=vc(l);return new Rh(d,bc(' ',m)+((g-m|0)<2?'^':bc('~',g-m|0)))}function qg(c,a,b){return new Sh(c.a,c.b+a|0,c.b+b|0)}function Ce(a){return Rb(a.a,a.b)}function De(a){return new Sh(a.a,a.c,a.c)}function Za(a,b){return new Sh(a.a,a.b,b.c)}function rg(a){var b='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_'[a%53];for(a=a/53|0;a>0;)a=a-1|0,b+='abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ_0123456789'[a%63],a=a/63|0;return b}function sg(n,a){for(var b=0,k=a.length;b<k;b=b+1|0)n.h=b,lb(n,a[b]);ug(n);var c=new Map,d=Ee(n,n.f,null);d.sort(function(e,f){return Wc(Fe(n,f),Fe(n,e))});for(var K=0,C=d.length;K<C;K=K+1|0)for(var h=d[K],l=null,v=0,q=h.length;v<q;v=v+1|0)for(var m=h[v],p=0,t=Array.from(m.c.values()),w=t.length;p<w;p=p+1|0){
46
+ var g=t[p],i=g.c;!(g.e&3072)&&(!n.a||n.a==1&&!(g.e&257))&&(l==null&&(l=tg(n)),g.c=l),!(g.e&2048)&&g.e&257&&Oa(c,i,g.c)}return c}function lb(f,a){var l,h;a.e&&((h=td(f,a.e)).d=h.d+1|0);for(var b=a.g;b;b=b.k)lb(f,b);switch(a.b){case 2:var c=a.e;lb(f,c.q),P(c)&&lb(f,P(c));break;case 11:var d=a.e;f.m=f.d.get(a.e.a).b,d.w&&Fd(f.f,f.m,td(f,d.w).b),lb(f,d.k);for(var m=0,g=d.n,i=g.length;m<i;m=m+1|0){var e=g[m];(l=td(f,e)).d=l.d+1|0,lb(f,e.q)}d.p&&lb(f,d.p),f.m=-1;break}}function td(c,a){var b=ta(c.d,a.a,null);return b||(b=new Uh(a.c,c.c.length),b.e=Bd(a),c.c.push(b),Ba(c.d,a.a,b),Pe(c.e),Pe(c.f)),b.c.has(c.h)||Ba(b.c,c.h,a),Bd(a)&&Fd(c.e,c.m,b.b),b}function tg(b){for(;;){var a=rg(b.l);if(b.l=b.l+1|0,!Kg.has(a)&&!Lg.has(a)&&!a.startsWith('gl_'))return a}}function Ee(h,a,b){for(var c=new Map,l=0,m=h.c,g=m.length;l<g;l=l+1|0){var d=m[l];if(!b||b(d)){var e=Qc(a,d.b),f=ta(c,e,null);f||(f=[],Ba(c,e,f)),f.push(d)}}return Array.from(c.values())}function ug(b){vg(b,Ee(b,b.e,function(a){return a.e}))}function vg(l,a){for(var b=[],g=0,i=a.length;g<i;g=g+1|0){
47
+ var c=a[g];c.sort(function(d,e){return Wc(e.d,d.d)});for(var f=0,m=c.length;f<m;f=f+1|0){var h=c[f];f<b.length?Fd(l.f,h.b,b[f]):b.push(h.b)}}}function Fe(d,a){for(var b=0,e=0,f=a.length;e<f;e=e+1|0){var c=a[e];b=b+c.d|0}return b}function ud(f,a){Y(f,a);for(var h=0,l=f.d,m=l.length;h<m;h=h+1|0){var b=l[h];r(b)}var c=a.g;f.d.length&&Hc(a,c,f.d[0]);for(var g=0,i=Array.from(f.e.values()),n=i.length;g<n;g=g+1|0){var d=i[g];Hc(a,c,d)}f.a.b=f.a.b.filter(function(e){return e.g==0})}function vd(b,a){a.b.a.a!='<api>'&&!a.g&&!(a.e&1024)&&b.a.b.push(a)}function Y(q,a){if(!a.f){a.f=I;var b=a.b;switch(b){case 0:case 1:wd(q,a);break;case 2:var c=a.e;vd(q,c),Y(q,c.q);var d=c.q.f;if(d==Hd&&(u(q.a,c.q.c,'Cannot create a variable of type "'+D(d)+'"'),d=I),c.C&&(ja(q,c.C),qa(q,c.C,fa)),P(c)&&(ja(q,P(c)),qa(q,P(c),d),d.d&&he(q.a,a.d,d)),c.e&2)if(P(c)){if(P(c).f!=I){var e=G(P(c));e?c.h=e:u(q.a,P(c).c,'This value must be a compile-time constant')}}else c.v^2||u(q.a,c.b,'Constants must be initialized');break;case 3:mb(q,a);break;case 4:case 5:case 6:
48
+ break;case 7:mb(q,a.g),Y(q,a.i),qa(q,a.i,aa);break;case 8:Y(q,a.g);break;case 9:break;case 10:kb(a)&&ja(q,kb(a)),Da(a)&&(ja(q,Da(a)),qa(q,Da(a),aa)),Ic(a)&&ja(q,Ic(a)),mb(q,a.i);break;case 11:var f=a.e;vd(q,f);for(var K=0,C=f.n,F=C.length;K<F;K=K+1|0){var h=C[K];Y(q,h.q)}Y(q,f.k),f.p&&(q.f=f.k.f,mb(q,f.p),q.f&&q.f!=Hd&&f.p.p&&u(q.a,f.b,'All control paths for "'+f.c+'" must return a value of type "'+D(q.f)+'"'),q.f=null);break;case 12:Y(q,a.g),qa(q,a.g,aa),mb(q,a.g.k),a.g.k.k&&mb(q,a.g.k.k);break;case 14:break;case 15:a.g?(Y(q,a.g),qa(q,a.g,q.f||I)):(a.f=Hd,qa(q,a,q.f||I));break;case 16:var l=a.e;vd(q,l),wd(q,a);for(var m=M(l),O=0,la=l.i,L=la.length;O<L;O=O+1|0){var g=la[O],i=g.q.f;i.d&&(m.d=!0),i.e&&(m.e=!0)}break;case 17:wd(q,a);break;case 18:q.d.push(a);break;case 19:Y(q,a.g),qa(q,a.g,aa),mb(q,a.i);break;case 20:yg(q,a);break;case 21:zg(q,a);break;case 22:var n=a.g,k=a.i,p=a.g.k;ja(q,n),qa(q,n,aa),ja(q,p),ja(q,k),p.f==I||k.f==I?a.f=I:p.f!=k.f?u(q.a,Za(p.c,k.c),'Cannot merge type "'+D(p.f)+'" and type "'+D(k.f)+'"'):p.f.d?Tf(q.a,
49
+ Za(p.c,k.c),p.f):a.f=p.f;break;case 23:var t=a.e;t instanceof Me?(Y(q,t.q),a.f=t.q.f):t instanceof mc&&!Zf(a)?u(q.a,a.c,'The function "'+t.c+'" must be called'):a.f=M(t);var w=t.l;w!=null&&!q.e.has(w)&&!Aa(q.b.a,w,0)&&Oa(q.e,w,_(hc(new Lh(9),w),2));break;case 25:for(var v=a.g;v;v=v.k)ja(q,v);a.f=a.i.f;break;default:kd(b)?wg(q,a):Ec(b)&&xg(q,a);break}}}function mb(c,a){if(ff(c.c,a),a.b^3)Y(c,a),Od(c.c,a);else for(var b=a.g;b;b=b.k)Y(c,b),Od(c.c,b);gf(c.c,a)}function wg(d,a){var b=a.g;ja(d,b),ld(a.b)&&Ge(d,b);var c=b.f;switch(a.b){case 31:case 33:case 34:case 35:case 36:case 37:a.f=Ng(c)?c:I;break;case 32:a.f=c==aa?aa:I;break}a.f==I&&c!=I&&u(d.a,a.d,'No unary operator "'+N(a.d)+'" for type "'+D(c)+'"')}function xg(i,a){var b=a.g,c=a.i;ja(i,b),ja(i,c),Fc(a.b)&&Ge(i,b);var d=b.f,e=c.f,f=d==e;switch(a.b){case 38:case 51:case 49:case 39:a.f=f&&ea(d)||Pc(d)&&e==$||Oc(d)&&e==fa?d:d==$&&Pc(e)||d==fa&&Oc(e)?e:a.b==49&&(d==Ga&&e==ob||d==ob&&e==Ga)?Ga:a.b==49&&(d==Ha&&e==pb||d==pb&&e==Ha)?Ha:a.b==49&&(d==Ia&&e==qb||d==qb&&e==Ia)?Ia:I;
50
+ break;case 40:case 50:a.f=f&&Og(d)?aa:I;break;case 46:case 47:case 48:a.f=f&&d==aa?aa:I;break;case 44:case 45:case 41:case 42:a.f=f&&(d==$||d==fa)?aa:I;break;case 52:a.f=d,d.d&&he(i.a,a.d,d),qa(i,c,d);return;case 53:case 56:case 55:case 54:a.f=f&&ea(d)||Pc(d)&&e==$||Oc(d)&&e==fa||a.b==55&&(d==Ga&&e==ob||d==Ha&&e==pb||d==Ia&&e==qb)?d:I;break;case 43:if(e==fa){var h=Dd(d);h&&(a.f=h);var l=G(c);if(l&&l.b==30){var m=l.h|0,g=Ta(d);(m<0||g&&m>=g)&&u(i.a,c.c,'Index "'+m+'" is out of bounds for type "'+D(d)+'"')}}break}a.f==I&&d!=I&&e!=I&&(a.b^43?Uf(i.a,a.d,N(a.d),d,e):u(i.a,a.d,'No index operator for type "'+D(d)+'" and type "'+D(e)+'"'))}function yg(l,a){var b=a.g;Y(l,b);for(var c=b.f,d=c.a,e=[],f=!1,h=b.k;h;h=h.k)ja(l,h),e.push(h),h.f==I&&(f=!0);if(!f){if(d){if(d instanceof mc){Ag(l,d,a,e);return}if(d instanceof ac){Bg(l,c,a,e);return}}c!=I&&u(l.a,b.c,'Cannot call type "'+D(c)+'"')}}function zg(l,a){var b=a.g,c=a.l,d=a.d;if(ja(l,b),c!=''){var e=b.f,f=ne(a);switch(e){case Tb:case yb:case Ga:case Ub:case zb:case Ha:case Vb:case Ab:case Ia:
51
+ a.f=Cg(l,d,e,c,f);break;case I:break;default:if(e.a&&e.a instanceof ac)for(var m=0,g=e.a.i,i=g.length;m<i;m=m+1|0){var h=g[m];if(h.c==c){a.e=h,Y(l,h.q),a.f=h.q.f;break}}a.e||u(l.a,d,'Cannot find "'+c+'" on type "'+D(e)+'"');break}}}function Ag(q,a,b,c){for(var d=[],e=a;e;e=e.t)~d.indexOf(e.w)||d.push(e);if(d.length^1&&(d=d.slice(),Gb(d,function(f){return f.n.length!=c.length}),d.length^1)){var h=d.slice();Gb(d,function(l){for(var m=0,K=c.length;m<K;m=m+1|0)if(l.n[m].q.f!=c[m].f)return!0;return!1}),d.length^1&&(d=h,Gb(d,function(g){for(var i=0,C=c.length;i<C;i=i+1|0){var n=g.n[i].q.f,k=c[i].f,p=Fa(n),t=Fa(k);if(n!=k&&(!p||!t||p^t))return!0}return!1}))}if(d.length^1)u(q.a,b.g.c,'No matching overload for function "'+a.c+'"');else{var w=d[0];if(w.n.length^c.length)Rf(q.a,b.d,w.n.length,c.length,w.c,w.b);else for(var v=0,F=c.length;v<F;v=v+1|0)qa(q,c[v],w.n[v].q.f);b.g.e=w,b.f=w.k.f}}function Bg(w,a,b,c){if(b.f=a,a!=I)if(ea(a)){for(var d=Fa(a),e=!1,f=0,v=0,q=c.length;v<q;v=v+1|0){var h=c[v],l=h.f,m=Fa(l);if(!ea(l)){
52
+ l!=I&&u(w.a,h.c,'Cannot use value of type "'+D(l)+'" when constructing type "'+D(a)+'"');return}f>=d&&Pf(w.a,h.c,a,d,f+m|0),$a(l)&&(e=!0),f=f+m|0}var g=$a(a)&&e;g&&c.length^1?u(w.a,b.d,'If a matrix argument is given to a matrix constructor, it is an error to have any other arguments'):f<d&&f^1&&!g&&Qf(w.a,b.d,a,f)}else{var i=a.a,n=i.i,k=n.length,p=c.length;if(k^p)Sf(w.a,b.d,k,p,i.c,i.b);else for(var t=0;t<k;t=t+1|0)qa(w,c[t],n[t].q.f)}}function Cg(m,a,b,c,d){var e=c.length;if(e<1||e>4)return u(m.a,a,'Invalid swizzle "'+c+'" on type "'+D(b)+'"'),I;for(var f=Fa(b),g=0,i=zd(f),n=i.length;g<n;g=g+1|0){var h=i[g];if(~h.indexOf(c[0])){for(var l=1;l<e;l=l+1|0){if(h.indexOf(c[l])==-1)return u(m.a,a,'Invalid swizzle "'+c+'" on type "'+D(b)+'"'),I;if(d&&~c.slice(0,l).indexOf(c[l]))return u(m.a,qg(a,l,l+1|0),'The field "'+c[l]+'" cannot be specified multiple times when used as a storage location'),I}return Ad(ea(b),e)}}return u(m.a,a,'Invalid swizzle "'+c+'" on type "'+D(b)+'"'),I}function ja(b,a){Y(b,a),a.b==26&&a.f!=I&&(u(b.a,
53
+ a.c,'Unexpected type "'+D(a.f)+'"'),a.f=I)}function wd(c,a){for(var b=a.g;b;b=b.k)Y(c,b)}function Ge(c,a){d:for(var b=a;;){if(b.f==I)break;switch(b.b){case 23:(b.e.e&2||b.e.e&256)&&u(c.a,a.c,'Cannot store to this location');break d;case 21:b=b.g;break;case 43:b=b.g;break;default:u(c.a,a.c,'Cannot store to this location');break d}}}function qa(c,a,b){a.f!=b&&a.f!=I&&b!=I&&u(c.a,a.c,'Cannot convert from type "'+D(a.f)+'" to type "'+D(b)+'"')}function Dg(a,b,c){for(;;){var d=new Wh;if(c.a&&Lc(d,a),c.d&&(Jc(d,a),Kc(d,a),Eg(d,a,b)),!d.a)break}c.a&&nb(a)}function nb(a){switch(a.b){case 12:if(!a.g.k.k)return!0;var b=a.g.k,c=nb(b);return c&&b.b^3&&ia(b,o(new Lh(3),md(b))),nb(a.g.k.k);case 10:return nb(a.i);case 11:var d=a.e;d.p&&nb(d.p);break;case 19:return nb(a.i);default:for(var e=a.g;e;e=e.k)nb(e);return!1}return!1}function Jc(l,a){for(var b=a.g;b;b=b.k)Jc(l,b);switch(a.b){case 2:var c=a.e;P(c)&&Jc(l,P(c)),(c.v==2||c.v==1)&&(l.b.push(c),Ba(l.c,c.a,0),Ba(l.d,c.a,0));break;case 11:var d=a.e;Ba(l.c,d.a,0),d.p&&Jc(l,d.p);
54
+ break;case 23:var e=a.e.a,f=ta(l.c,e,-1);~f&&Ba(l.c,e,f+1|0),oe(a)&&(f=ta(l.d,e,-1),~f&&Ba(l.d,e,f+1|0));var h=a.e.l;h!=null&&Oa(l.e,h,0);break}}function Kc(m,a){for(var b=a.g,c=null;b;b=c)c=b.k,Kc(m,b);switch(a.b){case 2:if(Je(m,a.e)||Ke(m,a.e)||Ie(m,a.e)&&(!a.g||oa(a.g)||a.e.h))r(a),m.a=!0;else{a.g&&Kc(m,a.g);var d=a.e.C;if(d&&d.b==23){var e=He(m,d.e);e&&(a.e.C=e,m.a=!0)}}break;case 11:var f=a.e;Ie(m,f)&&!(f.e&1024)?(r(a),m.a=!0):f.p&&Kc(m,f.p);break;case 17:if(!a.g.k){var h=a.m.b;h==3||!h||h==16?r(a):h^10?H(a,new Lh(3)):H(a,new Lh(25)),m.a=!0}break;case 23:var l=He(m,a.e);l&&(ia(a,l),m.a=!0);break}}function He(b,a){return Je(b,a)?Xa(a.h):Ke(b,a)?Xa(P(a)):null}function Eg(e,a,b){for(var c=a.g,d=null;c;c=d)d=c.k,c.b==9&&!e.e.has(c.l)&&!Aa(b.a,c.l,0)&&r(c)}function Ie(b,a){return ta(b.c,a.a,-1)==0&&(!(a instanceof mc)||a.w==null||ta(b.c,a.w.a,-1)==0)}function Je(b,a){return a.h!=null&&jd(a.h.b)}function Ke(b,a){return ta(b.d,a.a,-1)==0&&P(a)!=null&&jd(P(a).b)}function Lc(y,a){for(var b=a.g,c=null;b;b=c)c=b.k,Lc(y,
55
+ b);switch(a.b){case 2:var d=a.e;P(d)&&Lc(y,P(d));break;case 3:for(var e=a.g;e;e=e.k)if(Wf(e.b)&&e.k){for(;e.k;)r(e.k);y.a=!0}if(a.m&&a.m.b==3){for(var f=!1,h=a.g;h;h=h.k)h.b^17||(f=!0);if(!f){me(a),y.a=!0;return}}break;case 8:if(a.m.b==3){if(oa(a.g)){r(a),y.a=!0;return}var l=a.n;if(l&&l.b==8){var m=r(a.g);o(a,o(o(new Lh(25),r(r(l).g)),m)),y.a=!0;return}}break;case 7:Mc(y,a.g),Ib(a.i)&&(ia(a,o(new Lh(3),r(a.g))),y.a=!0);break;case 10:if(Mc(y,a.i),!kb(a)&&a.n&&a.n.b==8&&(ia(a.g,r(a.n.g)),r(a.n),y.a=!0),Da(a)&&Sa(Da(a))&&(ia(Da(a),new Lh(25)),y.a=!0),a.i.b^5){for(;a.i.g&&a.i.i.b==5;)r(a.i.i),y.a=!0}else ia(a.i,new Lh(3)),y.a=!0;break;case 11:var g=a.e;g.p&&Lc(y,g.p);break;case 12:if(Mc(y,a.g.k),a.g.k.k&&Mc(y,a.g.k.k),Sa(a.g)){ia(a,r(a.g.k)),y.a=!0;return}if(Ib(a.g)){a.g.k.k?ia(a,r(a.g.k.k)):r(a),y.a=!0;return}if(a.g.k.k&&a.g.k.b==15&&a.g.k.k.b==15){var i=a.g.k.g,n=a.g.k.k.g;if(i&&n){ia(a,o(new Lh(15),s(o(o(o(new Lh(22),r(a.g)),r(i)),r(n)),i.f))),y.a=!0;return}}if(a.g.k.k&&a.g.k.b==8&&a.g.k.k.b==8){var k=a.g.k.g,p=a.g.k.k.g;
56
+ if(k.f==p.f){ia(a,o(new Lh(8),s(o(o(o(new Lh(22),r(a.g)),r(k)),r(p)),k.f))),y.a=!0;return}}if(!a.g.k.k&&a.g.k.b==8){var t=a.g.k.g,w=t.b==52&&t.g.b==23&&Bd(t.g.e);if(t.f==fa||t.f==$||w){var v=w?Xa(t.g):t.f==fa?s(_(new Lh(30),0),fa):s(na(new Lh(29),0),$);ia(a,o(new Lh(8),s(o(o(o(new Lh(22),r(a.g)),r(t)),v),t.f))),y.a=!0;return}}if(!a.g.k.k&&a.g.k.b==12&&!a.g.k.g.k.k){var q=a.g,K=a.g.k.g,C=a.g.k.g.k;H(q,s(o(o(new Lh(46),md(q)),r(K)),aa)),H(a.g.k,r(C)),y.a=!0;return}if(pe(a.g.k)){a.g.k.k?(Jb(a.g),r(a.g.k)):ia(a,o(new Lh(8),r(a.g))),y.a=!0;return}if(a.g.k.k&&pe(a.g.k.k)){r(a.g.k.k),y.a=!0;return}break;case 15:for(var F=a.n;F&&F.b==12&&!F.g.k.k&&F.g.k.b==15;){var O=F.g.k.g,la=a.g;if(!O||!la)break;ia(a,o(new Lh(15),s(o(o(o(new Lh(22),r(F.g)),r(O)),r(la)),O.f))),r(F),F=a.n,y.a=!0}break;case 17:for(var L=a.n;L;L=L.n){if(L.b^17)break;if(L.g.f==a.g.f&&(L.h|0)==(a.h|0)){for(;L.i!=L.g;)Hc(a,a.g.k,r(L.i));r(L),y.a=!0;return}for(var ha=L.g.k;ha;ha=ha.k){var ga=ha.g;if(ga&&!jd(ga.b))return}}break;case 19:var Z=a.g,ba=a.i;ia(a,
57
+ qe(null,r(Z),null,r(ba))),y.a=!0;break;case 22:var sa=a.g,ca=a.g.k,ma=a.i;if(Sa(sa)){H(a,r(ca)),y.a=!0;return}if(Ib(sa)){H(a,r(ma)),y.a=!0;return}if(ca.b==ma.b&&Ec(ca.b)&&pa(ca.g,ma.g)&&ca.b^43){var ya=ca.g,La=ca.i,ka=ma.i;if(La.f==ka.f){var cb=o(o(o(new Lh(22),r(sa)),r(La)),r(ka));cb.f=La.f,H(a,o(o(new Lh(ca.b),r(ya)),cb)),y.a=!0;return}}if(ca.b==52&&pa(ca.g,ma)&&oa(ma)){var Ma=ca.g,Ua=ca.i,wa=o(o(o(new Lh(22),r(sa)),r(Ua)),r(ma));wa.f=Ua.f,H(a,o(o(new Lh(52),r(Ma)),wa)),y.a=!0;return}break;case 25:for(var za=a.g,db=null;za!=a.i;za=db)db=za.k,oa(za)&&(r(za),y.a=!0);if(a.m.b==25){me(a),y.a=!0;return}if(le(a)){H(a,r(a.g)),y.a=!0;return}break;case 31:var Ja=a.g;Ja.b^31?Ja.b^30?Ja.b^29||Pb(y,a,-Ja.h):Qb(y,a,-(Ja.h|0)|0):(H(a,r(Ja.g)),y.a=!0);break;case 32:var Ka=a.g;Ka.b^32?Ka.b^28||T(y,a,!!!Ka.h):(H(a,r(Ka.g)),y.a=!0);break;case 33:H(a,r(a.g));break;case 38:var eb=a.g,rb=a.i;ic(eb,0)?(H(a,r(rb)),y.a=!0):ic(rb,0)?(H(a,r(eb)),y.a=!0):eb.b==30&&rb.b==30?Qb(y,a,(eb.h|0)+(rb.h|0)|0):eb.b==29&&rb.b==29&&Pb(y,a,eb.h+rb.h);
58
+ break;case 20:var sb=a.g;if(sb.b==26){var Wb=sb.f;if(Wb==fa){var tb=sb.k;tb&&!tb.k&&tb.b==30&&(H(a,r(tb)),y.a=!0)}else if(Wb==$){var nc=sb.k;nc&&!nc.k&&nc.b==30&&Pb(y,a,nc.h|0)}else if(ea(Wb)==$)for(var ab=sb.k;ab;ab=ab.k)if(ab.b==29){var Rc=ab.h,fb=Rc|0;Rc==fb&&Qb(y,ab,fb)}}break;case 39:var gb=a.g,ub=a.i;ic(ub,1)?(H(a,r(gb)),y.a=!0):gb.b==30&&ub.b==30?Qb(y,a,ub.h|0?(gb.h|0)/(ub.h|0)|0:0):gb.b==29&&ub.b==29&&Pb(y,a,ub.h!=0?gb.h/ub.h:0);break;case 40:var vb=a.g,Xb=a.i;pa(vb,Xb)&&oa(vb)?(T(y,a,!0),y.a=!0):vb.b==30&&Xb.b==30?T(y,a,(vb.h|0)==(Xb.h|0)):vb.b==29&&Xb.b==29&&T(y,a,vb.h==Xb.h);break;case 41:var Bb=a.g,Yb=a.i;Bb.b==30&&Yb.b==30?T(y,a,(Bb.h|0)>(Yb.h|0)):Bb.b==29&&Yb.b==29&&T(y,a,Bb.h>Yb.h);break;case 42:var Cb=a.g,Na=a.i;Cb.b^30?Na.b^30?Cb.b==30&&Na.b==30?T(y,a,(Cb.h|0)>=(Na.h|0)):Cb.b==29&&Na.b==29&&T(y,a,Cb.h>=Na.h):(a.b=41,_(Na,(Na.h|0)-1|0),y.a=!0):(a.b=41,_(Cb,(Cb.h|0)+1|0),y.a=!0);break;case 43:var Sc=a.g,oc=a.i,Gd=Sc.f;if(oc.b==30){var Tc=oc.h|0,pc=0;switch(Gd){case Tb:case yb:case Ga:pc=2;break;
59
+ case Ub:case zb:case Ha:pc=3;break;case Vb:case Ab:case Ia:pc=4;break}Tc>-1&&Tc<pc&&(H(a,s(hc(o(new Lh(21),r(Sc)),'xyzw'[Tc]),a.f)),y.a=!0)}break;case 44:var Zb=a.g,qc=a.i;Zb.b==30&&qc.b==30?T(y,a,(Zb.h|0)<(qc.h|0)):Zb.b==29&&qc.b==29&&T(y,a,Zb.h<qc.h);break;case 45:var Db=a.g,wb=a.i;Db.b^30?wb.b^30?Db.b==30&&wb.b==30?T(y,a,(Db.h|0)<=(wb.h|0)):Db.b==29&&wb.b==29&&T(y,a,Db.h<=wb.h):(a.b=44,_(wb,(wb.h|0)+1|0),y.a=!0):(a.b=44,_(Db,(Db.h|0)-1|0),y.a=!0);break;case 46:var xa=a.g,Eb=a.i;xa.b==28&&Sa(xa)?(H(a,r(Eb)),y.a=!0):xa.b==28&&Ib(xa)?T(y,a,!1):xa.b==28&&Eb.b==28&&T(y,a,!!xa.h&&!!Eb.h);break;case 47:var Va=a.g,Uc=a.i;Va.b==28&&Ib(Va)?(H(a,r(Uc)),y.a=!0):Va.b==28&&Sa(Va)?T(y,a,!0):Va.b==28&&Uc.b==28&&T(y,a,!!Va.h&&!!Uc.h);break;case 48:var uc=a.g,Vc=a.i;uc.b==28&&Vc.b==28&&T(y,a,!!uc.h!=!!Vc.h);break;case 49:var xb=a.g,_b=a.i;xb.b==30&&(xb.h|0)==1?(H(a,r(_b)),y.a=!0):_b.b==30&&(_b.h|0)==1?(H(a,r(xb)),y.a=!0):xb.b==30&&_b.b==30?Qb(y,a,sh(xb.h|0,_b.h|0)):xb.b==29&&_b.b==29&&Pb(y,a,xb.h*_b.h);break;case 50:var rc=a.g,$b=a.i;
60
+ pa(rc,$b)&&oa(rc)?(T(y,a,!1),y.a=!0):rc.b==30&&$b.b==30?T(y,a,(rc.h|0)!=($b.h|0)):rc.b==29&&$b.b==29&&T(y,a,rc.h!=$b.h);break;case 51:var sc=a.g,Fb=a.i;ic(sc,0)?(H(a,s(o(new Lh(31),r(Fb)),a.f)),y.a=!0):ic(Fb,0)?(H(a,r(sc)),y.a=!0):sc.b==30&&Fb.b==30?Qb(y,a,(sc.h|0)-(Fb.h|0)|0):sc.b==29&&Fb.b==29&&Pb(y,a,sc.h-Fb.h);break}}function T(c,a,b){H(a,s(s(Ca(new Lh(28),b),aa),aa)),c.a=!0}function Pb(c,a,b){H(a,s(s(na(new Lh(29),b),$),$)),c.a=!0}function Qb(c,a,b){H(a,s(s(_(new Lh(30),b),fa),fa)),c.a=!0}function Mc(b,a){a.b==3&&le(a)&&(ia(a,r(a.g)),b.a=!0)}function Le(b,a){Oa(b.c,a.c,a)}function Fg(b,a){Oa(b.c,a.c,a)}function xd(c,a){var b=Aa(c.c,a,null);return b||c.b&&xd(c.b,a)}function Gg(a){return new Sh(a,0,a.b.length)}function Hg(d,a){if(yd(d),a<0||a>=d.d.length)return'';var b=d.d[a],c=(a+1|0)<d.d.length?d.d[a+1|0]-1|0:d.b.length;return d.b.slice(b,c)}function Rb(h,a){yd(h);for(var b=h.d.length,c=0;b>0;){var d=b/2|0,e=c+d|0;h.d[e]<=a?(c=e+1|0,b=(b-d|0)-1|0):b=d}var f=c>0?a-h.d[c-1|0]|0:a;return new Yh(c-1|0,f)}function Sb(d,a,b){
61
+ if(yd(d),a>-1&&a<d.d.length){var c=d.d[a];if(b>-1&&(c+b|0)<((a+1|0)<d.d.length?d.d[a+1|0]:d.b.length))return c+b|0}return-1}function yd(b){if(!b.d){b.d=[0];for(var a=0,c=b.b.length;a<c;a=a+1|0)b.b.charCodeAt(a)^10||b.d.push(a+1|0)}}function zd(a){switch(a){case 2:return eh;case 3:return fh;case 4:return gh}return null}function Ad(a,b){switch(a){case aa:switch(b){case 1:return aa;case 2:return Tb;case 3:return Ub;case 4:return Vb}break;case $:switch(b){case 1:return $;case 2:return Ga;case 3:return Ha;case 4:return Ia}break;case fa:switch(b){case 1:return fa;case 2:return yb;case 3:return zb;case 4:return Ab}break}return null}function Bd(a){return a instanceof Me&&(a.v==0||a.v==2)}function M(a){return a.m||(a.m=new ai(a,null,0)),a.m}function Ig(c,a){if(c.n.length^a.n.length)return!1;for(var b=0,d=c.n.length;b<d;b=b+1|0)if(c.n[b].q.f!=a.n[b].q.f)return!1;return!0}function P(a){var b;return (b=a.K)&&b.g}function Nc(a,b,c){for(var d=b.b.split(hh),e=[],f=null,h=0,l=0,m=0,q=d.length;m<q;m=m+1|0){var g=d[m],i=g.length,n=l+i|0,k=new Sh(b,
62
+ l,n);if(m%2){var p=g.charCodeAt(0);if(p>64&&p<91||p>96&&p<123||p==95){var t=Aa(Kg,g,99);t^99?e.push(new $h(k,t,f)):Lg.has(g)?Lf(a,k):e.push(new $h(k,96,f))}else if(p>47&&p<58||p==46&&i>1)e.push(new $h(k,ih.test(g)?97:95,f));else if(p^35){if(p^34){var v=Aa(jh,g,99);v^99||(g.startsWith('//')?c^1?(f||(f=[])).push(k):v=0:g.startsWith('/*')&&(c^1?(f||(f=[])).push(k):v=1)),v^99&&e.push(new $h(k,v,f))}else e.push(new $h(k,98,f))}else{var w=94;switch(g){case'#version':w=92;break;case'#extension':w=91;break;case'#include':w=93;break}e.push(new $h(k,w,f))}}else if(g!=''){u(a,k,'Syntax error "'+g+'"');break}e.length^h&&(f=null,h=e.length),l=n}return e.push(new $h(new Sh(b,l,l),99,f)),e}function Ne(a){return a.b?Ne(a.b):a}function Mg(c,a){c.f||(c.f=new Map);var b=ta(c.f,a,null);return b||(Ba(c.f,a,b=new ai(null,c,a)),b.d=!0,b.e=c.e),b}function D(a){return a.b?a.c?D(a.b)+'['+a.c+']':D(a.b)+'[]':a.a.c}function Ta(a){switch(a){case Tb:case Ga:case yb:case ob:return 2;case Ub:case Ha:case zb:case pb:return 3;case Vb:case Ia:case Ab:case qb:
63
+ return 4}return a.c}function Dd(a){switch(a){case Tb:case Ub:case Vb:return aa;case Ga:case Ha:case Ia:return $;case yb:case zb:case Ab:return fa;case ob:return Ga;case pb:return Ha;case qb:return Ia}return a.b}function Fa(a){switch(a){case aa:case $:case fa:return 1;case Tb:case Ga:case yb:return 2;case Ub:case Ha:case zb:return 3;case Vb:case Ia:case Ab:case ob:return 4;case pb:return 9;case qb:return 16}return 0}function ea(a){switch(a){case aa:case Tb:case Ub:case Vb:return aa;case $:case Ga:case Ha:case Ia:case ob:case pb:case qb:return $;case fa:case yb:case zb:case Ab:return fa}return null}function Ed(a){switch(a){case Tb:case Ub:case Vb:case yb:case zb:case Ab:case Ga:case Ha:case Ia:return!0}return!1}function $a(a){switch(a){case ob:case pb:case qb:return!0}return!1}function Oc(a){switch(a){case fa:case yb:case zb:case Ab:return!0}return!1}function Pc(a){switch(a){case $:case Ga:case Ha:case Ia:return!0;case ob:case pb:case qb:return!0}return!1}function Ng(a){return Oc(a)||Pc(a)}function Og(a){return !a.e&&!a.d}
64
+ function Oe(a){return a.e=!0,a}function Pe(b){var a=b.a.length;return b.a.push(a),a}function Fd(c,a,b){c.a[Qc(c,a)]=Qc(c,b)}function Qc(c,a){var b=c.a[a];return b^a&&(b=Qc(c,b),c.a[a]=b),b}function ra(a,b){Qe(a),process.stdout.write(b),Qe(0)}function Sg(a){ra(3,'error: '),ra(1,a+'\n')}function Tg(a){ra(2,'note: '),ra(1,a+'\n')}function Ug(a){ra(7,'warning: '),ra(1,a+'\n')}function Re(a){for(var b=process.stdout.columns,m=0,g=a.a,i=g.length;m<i;m=m+1|0){var c=g[m];c.b&&ra(1,rd(c.b)+': ');switch(c.a){case 1:Ug(c.c);break;case 0:Sg(c.c);break}if(c.b){var d=sd(c.b,b);ra(2,d.a+'\n'),ra(4,d.b+'\n')}if(c.d){ra(1,rd(c.d)+': '),Tg(c.e);var e=sd(c.d,b);ra(2,e.a+'\n'),ra(4,e.b+'\n')}}var f=a.d!=0,h=a.c!=0,l='';h&&(l+=a.c+' warning'+(a.c^1?'s':''),f&&(l+=' and ')),f&&(l+=a.d+' error'+(a.d^1?'s':'')),(h||f)&&process.stdout.write(l+' generated\n')}function Se(a){if(th(a))return[new Zh('<stdin>',a)];if(a instanceof Array){for(var b=[],c=0,e=a.length;c<e;c=c+1|0){var d=a[c];b.push(new Zh(uh(d.name),uh(d.contents)))}return b}return[new Zh(uh(a.name),
65
+ uh(a.contents))]}function Te(a){return function(b,c){var d=a(b,c);if(th(d))return new Zh(b,d);if(!d)return null;var e=d.name,f=d.contents;if(th(e)&&th(f))return new Zh(e,f);throw new Error('Invalid file access result')}}function Vg(){var a=process.argv.slice(2),b=new vh,c=[],d=0,e=null,f=require('fs'),h=require('path');b.e=function(l,m){var g=h.resolve(h.dirname(m),l);try{return new Zh(g,f.readFileSync(g,'utf8'))}catch(q){}return null};for(var w=0,v=a.length;w<v;w=w+1|0){var i=a[w];if(i.startsWith('-'))switch(i){case'--disable-rewriting':b.a=!1;break;case'--pretty-print':b.b=!1;break;case'--keep-symbols':b.d=!1;break;case'--help':case'-h':console.log("\nUsage: glslx [sources] [flags]\n\n --output=PATH\n Set the path to the output file. Defaults to standard out.\n\n --format=FORMAT\n Set the output format, must be json, js, c++, skew or rust. Defaults to json.\n\nAdvanced:\n\n --disable-rewriting\n Disable syntax tree rewriting, useful to check for driver bugs.\n\n --pretty-print\n Format the output nicely instead of minifying it.\n\n --renaming=MODE\n Valid modes are all, internal-only, or none. Defaults to all.\n\n --keep-symbols\n Don't inline constants or remove unused symbols.\n");
66
+ return;default:if(i.startsWith('--output='))e=i.slice(9);else if(i.startsWith('--format=')){var n=i.slice(9);We.has(n)||(console.log('invalid output format "'+n+'"'),process.exit(1)),d=We.get(n)}else if(i.startsWith('--renaming=')){var k=i.slice(11);Xe.has(k)||(console.log('invalid symbol renaming mode "'+k+'"'),process.exit(1)),b.c=Xe.get(k)}else console.log('invalid flag "'+i+'"'),process.exit(1);break}else c.push(new Zh(h.resolve(i),f.readFileSync(i,'utf8')))}if(c.length){var p=new Kh,t=Nd(p,c,b);t?e!=null?(f.writeFileSync(e,Yc(t,d)),Re(p)):process.stdout.write(Yc(t,d)):(Re(p),process.exit(1))}else console.log("\nUsage: glslx [sources] [flags]\n\n --output=PATH\n Set the path to the output file. Defaults to standard out.\n\n --format=FORMAT\n Set the output format, must be json, js, c++, skew or rust. Defaults to json.\n\nAdvanced:\n\n --disable-rewriting\n Disable syntax tree rewriting, useful to check for driver bugs.\n\n --pretty-print\n Format the output nicely instead of minifying it.\n\n --renaming=MODE\n Valid modes are all, internal-only, or none. Defaults to all.\n\n --keep-symbols\n Don't inline constants or remove unused symbols.\n")}
67
+ function ci(){var a=(function(){return this})(),b=typeof exports!=='undefined'?exports:a.GLSLX={};b.compile=lh,b.compileIDE=mh,b.format=nh,typeof require!=='undefined'&&typeof module!=='undefined'&&require.main===module&&Vg()}function jd(a){return a>27&&a<31}function kd(a){return a>30&&a<38}function Vf(a){return a>30&&a<36}function ld(a){return a>33&&a<38}function Ec(a){return a>37&&a<57}function Fc(a){return a>51&&a<57}function Wf(a){return a==4||a==5||a==6||a==15}function ie(a){return a==7||a==10||a==19}function _a(b){var a='';return b&1&&(a+='attribute '),b&2&&(a+='const '),b&256&&(a+='uniform '),b&512&&(a+='varying '),b&4&&(a+='highp '),b&32&&(a+='lowp '),b&64&&(a+='mediump '),b&8&&(a+='in '),b&16&&(a+='inout '),b&128&&(a+='out '),a}function Jg(a){return a>49&&a<80}function Cd(a){switch(a){case 96:case 42:case 33:case 34:case 14:case 39:case 40:case 41:case 20:case 22:case 23:case 24:case 3:case 5:case 6:case 7:case 26:case 27:case 28:return!0}return!1}function Qe(a){process.stdout.isTTY&&process.stdout.write('\x1B[0;'+kh.get(a)+'m')}
68
+ function hb(b,a){return b[b.length-1|0]=a}function Xc(a){return a[a.length-1|0]}function bf(c,a){for(var d=0,e=a.length;d<e;d=d+1|0){var b=a[d];c.push(b)}}function Gb(d,a){for(var b=0,c=0,e=d.length;c<e;c=c+1|0)a(d[c])||(b<c&&(d[b]=d[c]),b=b+1|0);for(;b<d.length;)d.pop()}function Oa(c,a,b){return c.set(a,b),b}function j(c,a,b){return c.set(a,b),c}function Aa(d,a,b){var c=d.get(a);return c!==void 0?c:b}function Ba(c,a,b){return c.set(a,b),b}function Pa(c,a,b){return c.set(a,b),c}function ta(d,a,b){var c=d.get(a);return c!==void 0?c:b}function Wc(b,a){return (a<b|0)-(a>b|0)|0}function vc(a){for(var b=new ph,d=0,e=a.length;d<e;d=d+1|0){var c=a[d];b.a+=_e(c)}return b.a}function af(b,a){return (a<b|0)-(a>b|0)|0}function bc(d,a){for(var b='',c=0;c<a;c=c+1|0)b+=d;return b}function _e(a){return a<65536?String.fromCharCode(a):String.fromCharCode((a-65536>>10)+55296|0)+String.fromCharCode((a-65536&1023)+56320|0)}function tc(a){if(!a)return null;var b=a.a,c=Rb(b,a.b),d=Rb(b,a.c);return{source:b.a,start:{line:c.a,column:c.b},
69
+ end:{line:d.a,column:d.b}}}function lh(a,b){b=b||{};var c=Se(a),d=new Kh,e=new vh;e.c=Aa(Xe,b.renaming,0),b.disableRewriting&&(e.a=!1),b.prettyPrint&&(e.b=!1),b.keepSymbols&&(e.d=!1),b.fileAccess&&(e.e=Te(b.fileAccess));var f=Nd(d,c,e);return{log:Jf(d),output:f?Yc(f,Aa(We,b.format,0)):null}}function mh(a,b){b=b||{};var c=Se(a),d=new Kh,e=new vh;b.fileAccess&&(e.e=Te(b.fileAccess));var f=cf(d,c,e),h=function(l){for(var Vc,m=l.source+'',g=l.line|0,i=l.column|0,n=!!l.ignoreDiagnostics,k=null,p=null,t=null,$b=0,sc=c.length;$b<sc;$b=$b+1|0){var w=c[$b];if(w.a==m){var v=Sb(w,g,i);if(~v){if(!n&&d)for(var xb=0,_b=d.a,rc=_b.length;xb<rc;xb=xb+1|0){var q=_b[xb];if(q.b&&q.b.a==w&&lc(q.b,v)){p=new Bh(q.c,''),k=q.b;break}}if(!p&&f){var K=new Ch(w,v);Qa(K,f.a),p=Cf(K),p&&(k=K.e,t=(Vc=K.d)&&Vc.c)}}break}}return{tooltip:p&&p.a,range:tc(k),symbol:t,documentation:p&&p.b}},C=function(F){for(var O=F.source+'',la=F.line|0,L=F.column|0,ha=null,ga=null,Z=null,Fb=0,y=f.b,Xg=y.length;Fb<Xg;Fb=Fb+1|0){var ba=y[Fb];if(ba.a.a.a==O){var sa=Sb(ba.a.a,
70
+ la,L);if(~sa&&lc(ba.a,sa))return{definition:tc(ba.b),range:tc(ba.a),symbol:ba.b.a.a}}}for(var Id=0,Yg=c.length;Id<Yg;Id=Id+1|0){var ca=c[Id];if(ca.a==O){var ma=Sb(ca,la,L);if(~ma&&f){var ya=new Ch(ca,ma);Qa(ya,f.a),ya.d&&ya.d.b&&ya.d.b.a.a!='<api>'&&(ga=ya.d.b,ha=ya.e,Z=ya.d.c)}break}}return{definition:tc(ga),range:tc(ha),symbol:Z}},La=function(ka){for(var cb=ka.source+'',Ma=null,Jd=0,Zg=c.length;Jd<Zg;Jd=Jd+1|0){var Ua=c[Jd];if(Ua.a==cb){if(f){var wa=new Dh(Ua);ce(wa,f.a),Ma=wa.b.map(function(za){return{name:za.c,kind:za instanceof Me?'variable':za instanceof mc?'function':za instanceof ac?'struct':null,range:tc(za.b)}})}break}}return{symbols:Ma}},db=function(Ja){for(var Ka=Ja.source+'',eb=Ja.line|0,rb=Ja.column|0,sb=null,Wb=null,Kd=0,_g=c.length;Kd<_g;Kd=Kd+1|0){var tb=c[Kd];if(tb.a==Ka){var nc=Sb(tb,eb,rb);if(~nc&&f){var ab=new Eh(tb,nc);Ff(ab,f.a),ab.d&&ab.d.b&&ab.d.b.a.a!='<api>'&&(sb=ab.c.map(tc),Wb=ab.d.c)}break}}return{ranges:sb,symbol:Wb}},Rc=function(fb){for(var gb=fb.source+'',ub=fb.line|0,vb=fb.column|0,Xb=[],Ld=0,$g=c.length;Ld<$g;Ld=Ld+1|0){
71
+ var Bb=c[Ld];if(Bb.a==gb){var Yb=Sb(Bb,ub,vb);if(~Yb&&f){var Cb=new Gh(Bb,Yb);If(Cb,f.a),Xb=Cb.d.map(function(Na){return{kind:Na.a,name:Na.b,detail:Na.c,documentation:Na.d}})}}}return{completions:Xb}},Sc=function(oc){for(var Gd=oc.source+'',Tc=oc.line|0,pc=oc.column|0,Zb=[],qc=-1,Db=-1,Md=0,ah=c.length;Md<ah;Md=Md+1|0){var wb=c[Md];if(wb.a==Gd){var xa=Sb(wb,Tc,pc);if(~xa&&f){var Eb=new Ih(wb,xa);hd(Eb,f.a),qc=Eb.d,Db=Eb.e,Zb=Eb.c.map(function(Va){return{text:Va.a,'arguments':Va.b,documentation:Va.c}})}}}return{signatures:Zb,activeArgument:qc,activeSignature:Db}};return{unusedSymbols:d.b.map(function(Uc){return{name:Uc.c,range:tc(Uc.b)}}),diagnostics:d.a.map(function(uc){return{kind:oh[uc.a].toLowerCase(),range:tc(uc.b),text:uc.c}}),tooltipQuery:h,definitionQuery:C,symbolsQuery:La,renameQuery:db,completionQuery:Rc,signatureQuery:Sc}}function nh(a,b){b=b||{};var c='indent'in b?uh(b.indent):' ',d='newline'in b?uh(b.newline):'\n',e=2;if('trailingNewline'in b){var f=uh(b.trailingNewline);switch(f){case'preserve':e=0;
72
+ break;case'remove':e=1;break;case'insert':e=2;break;default:throw new Error('Invalid "trailingNewline" value: '+f)}}return Bf(uh(a),c,d,e)}function ph(){this.a=''}function qh(){this.a='',this.b=0,this.c=0}function vh(){this.a=!0,this.b=!0,this.c=0,this.d=!0,this.e=null}function wh(a){this.a=new Map,this.b=a,this.c=0}function xh(a,b){this.a=a,this.b=b}function yh(a,b){this.a=a,this.b=b}function zh(){this.a=[],this.b=[]}function Ah(a,b){this.a='',this.b='',this.c='\n',this.d=' ',this.e=b.b,this.e&&(this.d='',this.c='');for(var c=null,d=a.g;d;d=d.k)jf(this,d)||(c&&hf(c,d)&&(this.a+=this.c),Wa(this,d),this.a+=this.c,c=d)}function Bh(a,b){this.a=a,this.b=b}function Ch(a,b){this.a=a,this.b=b,this.c=null,this.d=null,this.e=null,this.f=null,this.h=null}function Dh(a){this.a=a,this.b=[]}function Eh(a,b){this.a=a,this.b=b,this.c=[],this.d=null}function Fh(a,b){this.a=a,this.b=b,this.c='',this.d=''}function Gh(a,b){this.a=a,this.b=b,this.c=new Map,this.d=[]}function Hh(a,b,c){this.a=a,this.b=b,this.c=c}function Ih(a,b){this.a=a,
73
+ this.b=b,this.c=[],this.d=-1,this.e=-1}function Jh(a,b,c){this.a=a,this.b=b,this.c=c,this.d=null,this.e=''}function Kh(){this.a=[],this.b=[],this.c=0,this.d=0,this.e=null}function Lh(a){this.a=re(),this.b=a,this.c=null,this.d=null,this.e=null,this.f=null,this.h=0,this.l=null,this.m=null,this.g=null,this.i=null,this.n=null,this.k=null,this.p=!1}function Mh(a){this.a=a}function Nh(a,b){this.a=a,this.b=b}function Oh(a,b,c,d,e){this.a=a,this.b=b,this.c=c,this.d=d,this.e=e,this.f=[],this.h=0,this.l=0,this.m=null}function Ph(a){this.a=a,this.b=null,this.c=null}function Qh(){this.a=new Map}function Rh(a,b){this.a=a,this.b=b}function Sh(a,b,c){this.a=a,this.b=b,this.c=c}function Uh(a,b){this.a=a,this.b=b,this.c=new Map,this.d=0,this.e=!1}function Th(a){this.a=a,this.b=[],this.c=[],this.d=new Map,this.e=new bi,this.f=new bi,this.h=0,this.l=0,this.m=-1}function Vh(a,b){this.a=a,this.b=b,this.c=new zh,this.d=[],this.e=new Map,this.f=null}function Wh(){this.a=!1,this.b=[],this.c=new Map,this.d=new Map,this.e=new Map}function Xh(a,b){
74
+ this.a=a,this.b=b,this.c=new Map}function Yh(a,b){this.a=a,this.b=b}function Zh(a,b){this.a=a,this.b=b,this.c=null,this.d=null}function _h(a,b,c,d){this.a=a,this.b=b,this.c=c,this.d=d,this.e=0,this.f=null,this.h=null,this.l=null,this.m=null,this.g=0}function ac(a,b,c,d){_h.call(this,a,b,c,d),this.i=[]}rh(ac,_h);function mc(a,b,c,d){_h.call(this,a,b,c,d),this.n=[],this.k=null,this.p=null,this.t=null,this.w=null}rh(mc,_h);function Me(a,b,c,d,e){_h.call(this,a,b,c,d),this.v=e,this.q=null,this.K=null,this.C=null}rh(Me,_h);function $h(a,b,c){this.a=a,this.b=b,this.c=c}function ai(a,b,c){this.a=a,this.b=b,this.c=c,this.d=!1,this.e=!1,this.f=null}function bi(){this.a=[]}var bh=new qh,Ve=0,bb=null,eg=j(j(j(j(new Map,'disable',1),'enable',2),'require',3),'warn',4),dh=j(j(j(j(new Map,'GL_OES_standard_derivatives',0),'GL_EXT_frag_depth',0),'GL_EXT_draw_buffers',0),'GL_EXT_shader_texture_lod',0),eh=['xy','st','rg'],fh=['xyz','stp','rgb'],gh=['xyzw','stpq','rgba'],hh=new RegExp('(\\.[0-9]+[eE][+-]?[0-9]+\\b|\\.[0-9]+\\b|[0-9]+\\.[0-9]+[eE][+-]?[0-9]+\\b|[0-9]+\\.[0-9]+\\b|[0-9]+\\.[eE][+-]?[0-9]+\\b|[0-9]+\\.|[0-9]+[eE][+-]?[0-9]+\\b|[1-9][0-9]*\\b|0[0-7]*\\b|0[xX][0-9A-Fa-f]+\\b|[ \t\r\n]|/\\*(?:.|\r\n|\n)*?\\*/|//.*|&&|\\|\\||\\^\\^|\\+\\+|--|<<=?|>>=?|[()[\\]{}\\.,?:;]|[+\\-*/%=!<>&|^~]=?|[A-Za-z_][A-Za-z0-9_]*\\b|#\\w+\\b|"(?:[^"\\\\]|\\\\.)*")'),ih=new RegExp('^([1-9][0-9]*|0[0-7]*|0[xX][0-9A-Fa-f]+)$'),Kg=j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(new Map,
75
+ 'attribute',2),'bool',3),'break',4),'bvec2',5),'bvec3',6),'bvec4',7),'const',8),'continue',9),'discard',10),'do',11),'else',12),'false',13),'float',14),'for',15),'highp',16),'if',17),'in',18),'inout',19),'int',20),'invariant',21),'ivec2',22),'ivec3',23),'ivec4',24),'lowp',25),'mat2',26),'mat3',27),'mat4',28),'mediump',29),'out',30),'precision',31),'return',32),'sampler2D',33),'samplerCube',34),'struct',35),'true',36),'uniform',37),'varying',38),'vec2',39),'vec3',40),'vec4',41),'void',42),'while',43),'export',44),'import',45),jh=j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(new Map,'~',46),'--',47),'++',48),'!',49),'&',50),'|',51),'^',52),'/',53),'==',54),'>',55),'>=',56),'<',57),'<=',58),'&&',59),'||',60),'^^',61),'-',62),'*',63),'!=',64),'+',65),'%',66),'<<',67),'>>',68),'=',69),'+=',70),'&=',71),'|=',72),'^=',73),'/=',74),'*=',75),'%=',76),'<<=',77),'>>=',78),'-=',79),':',80),',',81),'.',82),'{',83),'[',84),'(',85),'?',86),'}',87),']',88),')',89),';',90),Lg=j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(j(new Map,
76
+ 'asm',0),'cast',0),'class',0),'default',0),'double',0),'dvec2',0),'dvec3',0),'dvec4',0),'enum',0),'extern',0),'external',0),'fixed',0),'flat',0),'fvec2',0),'fvec3',0),'fvec4',0),'goto',0),'half',0),'hvec2',0),'hvec3',0),'hvec4',0),'inline',0),'input',0),'interface',0),'long',0),'namespace',0),'noinline',0),'output',0),'packed',0),'public',0),'sampler1D',0),'sampler1DShadow',0),'sampler2DRect',0),'sampler2DRectShadow',0),'sampler2DShadow',0),'sampler3D',0),'sampler3DRect',0),'short',0),'sizeof',0),'static',0),'superp',0),'switch',0),'template',0),'this',0),'typedef',0),'union',0),'unsigned',0),'using',0),'volatile',0),aa=M(new ac(-1,null,'bool',null)),Tb=M(new ac(-2,null,'bvec2',null)),Ub=M(new ac(-3,null,'bvec3',null)),Vb=M(new ac(-4,null,'bvec4',null)),I=M(new ac(-5,null,'<error>',null)),$=M(new ac(-6,null,'float',null)),fa=M(new ac(-7,null,'int',null)),yb=M(new ac(-8,null,'ivec2',null)),zb=M(new ac(-9,null,'ivec3',null)),Ab=M(new ac(-10,null,'ivec4',null)),ob=M(new ac(-11,null,'mat2',null)),pb=M(new ac(-12,null,
77
+ 'mat3',null)),qb=M(new ac(-13,null,'mat4',null)),Pg=Oe(M(new ac(-14,null,'sampler2D',null))),Qg=Oe(M(new ac(-15,null,'samplerCube',null))),Ga=M(new ac(-16,null,'vec2',null)),Ha=M(new ac(-17,null,'vec3',null)),Ia=M(new ac(-18,null,'vec4',null)),Hd=M(new ac(-19,null,'void',null)),Rg=[aa,Tb,Ub,Vb,$,fa,yb,zb,Ab,ob,pb,qb,Pg,Qg,Ga,Ha,Ia],We=j(j(j(j(j(new Map,'json',0),'js',1),'c++',2),'skew',3),'rust',4),Xe=j(j(j(new Map,'all',0),'internal-only',1),'none',2),oh=['ERROR','WARNING'],Wg=['GLOBAL','STRUCT_BLOCK','VARIABLE','BLOCK','BREAK','CONTINUE','DISCARD','DO_WHILE','EXPRESSION','EXTENSION','FOR','FUNCTION','IF','MODIFIER_BLOCK','PRECISION','RETURN','STRUCT','VARIABLES','VERSION','WHILE','CALL','DOT','HOOK','NAME','PARSE_ERROR','SEQUENCE','TYPE','UNKNOWN_CONSTANT','BOOL','FLOAT','INT','NEGATIVE','NOT','POSITIVE','PREFIX_DECREMENT','PREFIX_INCREMENT','POSTFIX_DECREMENT','POSTFIX_INCREMENT','ADD','DIVIDE','EQUAL','GREATER_THAN','GREATER_THAN_OR_EQUAL','INDEX','LESS_THAN','LESS_THAN_OR_EQUAL','LOGICAL_AND','LOGICAL_OR',
78
+ 'LOGICAL_XOR','MULTIPLY','NOT_EQUAL','SUBTRACT','ASSIGN','ASSIGN_ADD','ASSIGN_DIVIDE','ASSIGN_MULTIPLY','ASSIGN_SUBTRACT'],Ue=['SINGLE_LINE_COMMENT','MULTI_LINE_COMMENT','ATTRIBUTE','BOOL','BREAK','BVEC2','BVEC3','BVEC4','CONST','CONTINUE','DISCARD','DO','ELSE','FALSE','FLOAT','FOR','HIGHP','IF','IN','INOUT','INT','INVARIANT','IVEC2','IVEC3','IVEC4','LOWP','MAT2','MAT3','MAT4','MEDIUMP','OUT','PRECISION','RETURN','SAMPLER2D','SAMPLERCUBE','STRUCT','TRUE','UNIFORM','VARYING','VEC2','VEC3','VEC4','VOID','WHILE','EXPORT','IMPORT','COMPLEMENT','DECREMENT','INCREMENT','NOT','BITWISE_AND','BITWISE_OR','BITWISE_XOR','DIVIDE','EQUAL','GREATER_THAN','GREATER_THAN_OR_EQUAL','LESS_THAN','LESS_THAN_OR_EQUAL','LOGICAL_AND','LOGICAL_OR','LOGICAL_XOR','MINUS','MULTIPLY','NOT_EQUAL','PLUS','REMAINDER','SHIFT_LEFT','SHIFT_RIGHT','ASSIGN','ASSIGN_ADD','ASSIGN_BITWISE_AND','ASSIGN_BITWISE_OR','ASSIGN_BITWISE_XOR','ASSIGN_DIVIDE','ASSIGN_MULTIPLY','ASSIGN_REMAINDER','ASSIGN_SHIFT_LEFT','ASSIGN_SHIFT_RIGHT','ASSIGN_SUBTRACT','COLON',
79
+ 'COMMA','DOT','LEFT_BRACE','LEFT_BRACKET','LEFT_PARENTHESIS','QUESTION','RIGHT_BRACE','RIGHT_BRACKET','RIGHT_PARENTHESIS','SEMICOLON','EXTENSION','VERSION','INCLUDE','PRAGMA','FLOAT_LITERAL','IDENTIFIER','INT_LITERAL','STRING_LITERAL','END_OF_FILE'],kh=Pa(Pa(Pa(Pa(Pa(Pa(Pa(Pa(Pa(new Map,0,0),1,1),2,90),3,31),4,32),5,33),6,34),7,35),8,36);ci()})();