1static constexpr char SKSL_MINIFIED_sksl_shared[] = 2"$pure $genType radians($genType degrees);$pure $genHType radians($genHType degrees" 3");$pure $genType degrees($genType radians);$pure $genHType degrees($genHType" 4" radians);$pure $genType sin($genType angle);$pure $genHType sin($genHType angle" 5");$pure $genType cos($genType angle);$pure $genHType cos($genHType angle);$pure" 6" $genType tan($genType angle);$pure $genHType tan($genHType angle);$pure $genType" 7" asin($genType x);$pure $genHType asin($genHType x);$pure $genType acos($genType" 8" x);$pure $genHType acos($genHType x);$pure $genType atan($genType y,$genType" 9" x);$pure $genHType atan($genHType y,$genHType x);$pure $genType atan($genType" 10" y_over_x);$pure $genHType atan($genHType y_over_x);$es3 $pure $genType sinh" 11"($genType x);$es3 $pure $genHType sinh($genHType x);$es3 $pure $genType cosh" 12"($genType x);$es3 $pure $genHType cosh($genHType x);$es3 $pure $genType tanh" 13"($genType x);$es3 $pure $genHType tanh($genHType x);$es3 $pure $genType asinh" 14"($genType x);$es3 $pure $genHType asinh($genHType x);$es3 $pure $genType acosh" 15"($genType x);$es3 $pure $genHType acosh($genHType x);$es3 $pure $genType atanh" 16"($genType x);$es3 $pure $genHType atanh($genHType x);$pure $genType pow($genType" 17" x,$genType y);$pure $genHType pow($genHType x,$genHType y);$pure $genType exp" 18"($genType x);$pure $genHType exp($genHType x);$pure $genType log($genType x" 19");$pure $genHType log($genHType x);$pure $genType exp2($genType x);$pure $genHType" 20" exp2($genHType x);$pure $genType log2($genType x);$pure $genHType log2($genHType" 21" x);$pure $genType sqrt($genType x);$pure $genHType sqrt($genHType x);$pure" 22" $genType inversesqrt($genType x);$pure $genHType inversesqrt($genHType x);" 23"$pure $genType abs($genType x);$pure $genHType abs($genHType x);$pure $genType" 24" sign($genType x);$pure $genHType sign($genHType x);$pure $genType floor($genType" 25" x);$pure $genHType floor($genHType x);$pure $genType ceil($genType x);$pure" 26" $genHType ceil($genHType x);$pure $genType fract($genType x);$pure $genHType" 27" fract($genHType x);$pure $genType mod($genType x,float y);$pure $genType mod" 28"($genType x,$genType y);$pure $genHType mod($genHType x,half y);$pure $genHType" 29" mod($genHType x,$genHType y);$pure $genType min($genType x,$genType y);$pure" 30" $genType min($genType x,float y);$pure $genHType min($genHType x,$genHType" 31" y);$pure $genHType min($genHType x,half y);$pure $genType max($genType x,$genType" 32" y);$pure $genType max($genType x,float y);$pure $genHType max($genHType x," 33"$genHType y);$pure $genHType max($genHType x,half y);$pure $genType clamp($genType" 34" x,$genType minVal,$genType maxVal);$pure $genType clamp($genType x,float minVal" 35",float maxVal);$pure $genHType clamp($genHType x,$genHType minVal,$genHType" 36" maxVal);$pure $genHType clamp($genHType x,half minVal,half maxVal);$pure $genType" 37" saturate($genType x);$pure $genHType saturate($genHType x);$pure $genType mix" 38"($genType x,$genType y,$genType a);$pure $genType mix($genType x,$genType y" 39",float a);$pure $genHType mix($genHType x,$genHType y,$genHType a);$pure $genHType" 40" mix($genHType x,$genHType y,half a);$pure $genType step($genType edge,$genType" 41" x);$pure $genType step(float edge,$genType x);$pure $genHType step($genHType" 42" edge,$genHType x);$pure $genHType step(half edge,$genHType x);$pure $genType" 43" smoothstep($genType edge0,$genType edge1,$genType x);$pure $genType smoothstep" 44"(float edge0,float edge1,$genType x);$pure $genHType smoothstep($genHType edge0" 45",$genHType edge1,$genHType x);$pure $genHType smoothstep(half edge0,half edge1" 46",$genHType x);$es3 $pure $genIType abs($genIType x);$es3 $pure $genIType sign" 47"($genIType x);$es3 $pure $genIType floatBitsToInt($genType value);$es3 $pure" 48" $genUType floatBitsToUint($genType value);$es3 $pure $genType intBitsToFloat" 49"($genIType value);$es3 $pure $genType uintBitsToFloat($genUType value);$es3" 50" $pure $genType trunc($genType x);$es3 $pure $genHType trunc($genHType x);$es3" 51" $pure $genType round($genType x);$es3 $pure $genHType round($genHType x);$es3" 52" $pure $genType roundEven($genType x);$es3 $pure $genHType roundEven($genHType" 53" x);$es3 $pure $genIType min($genIType x,$genIType y);$es3 $pure $genIType min" 54"($genIType x,int y);$es3 $pure $genUType min($genUType x,$genUType y);$es3 $pure" 55" $genUType min($genUType x,uint y);$es3 $pure $genIType max($genIType x,$genIType" 56" y);$es3 $pure $genIType max($genIType x,int y);$es3 $pure $genUType max($genUType" 57" x,$genUType y);$es3 $pure $genUType max($genUType x,uint y);$es3 $pure $genIType" 58" clamp($genIType x,$genIType minVal,$genIType maxVal);$es3 $pure $genIType clamp" 59"($genIType x,int minVal,int maxVal);$es3 $pure $genUType clamp($genUType x," 60"$genUType minVal,$genUType maxVal);$es3 $pure $genUType clamp($genUType x,uint" 61" minVal,uint maxVal);$es3 $pure $genType mix($genType x,$genType y,$genBType" 62" a);$es3 $pure $genHType mix($genHType x,$genHType y,$genBType a);$es3 $pure" 63" $genBType isnan($genType x);$es3 $pure $genBType isnan($genHType x);$es3 $pure" 64" $genBType isinf($genType x);$es3 $pure $genBType isinf($genHType x);$es3 $pure" 65" $genType modf($genType x,out $genType i);$es3 $pure $genHType modf($genHType" 66" x,out $genHType i);$es3 $pure uint packUnorm2x16(float2 v);$es3 $pure float2" 67" unpackUnorm2x16(uint p);$pure float length($genType x);$pure half length($genHType" 68" x);$pure float distance($genType p0,$genType p1);$pure half distance($genHType" 69" p0,$genHType p1);$pure float dot($genType x,$genType y);$pure half dot($genHType" 70" x,$genHType y);$pure float3 cross(float3 x,float3 y);$pure half3 cross(half3" 71" x,half3 y);$pure $genType normalize($genType x);$pure $genHType normalize(" 72"$genHType x);$pure $genType faceforward($genType N,$genType I,$genType Nref" 73");$pure $genHType faceforward($genHType N,$genHType I,$genHType Nref);$pure" 74" $genType reflect($genType I,$genType N);$pure $genHType reflect($genHType I" 75",$genHType N);$pure $genType refract($genType I,$genType N,float eta);$pure" 76" $genHType refract($genHType I,$genHType N,half eta);$pure $squareMat matrixCompMult" 77"($squareMat x,$squareMat y);$pure $squareHMat matrixCompMult($squareHMat x," 78"$squareHMat y);$es3 $pure $mat matrixCompMult($mat x,$mat y);$es3 $pure $hmat" 79" matrixCompMult($hmat x,$hmat y);$pure $squareMat inverse($squareMat m);$pure" 80" $squareHMat inverse($squareHMat m);$es3 $pure float determinant($squareMat" 81" m);$es3 $pure half determinant($squareHMat m);$es3 $pure $squareMat transpose" 82"($squareMat m);$es3 $pure $squareHMat transpose($squareHMat m);$es3 $pure float2x3" 83" transpose(float3x2 m);$es3 $pure half2x3 transpose(half3x2 m);$es3 $pure float2x4" 84" transpose(float4x2 m);$es3 $pure half2x4 transpose(half4x2 m);$es3 $pure float3x2" 85" transpose(float2x3 m);$es3 $pure half3x2 transpose(half2x3 m);$es3 $pure float3x4" 86" transpose(float4x3 m);$es3 $pure half3x4 transpose(half4x3 m);$es3 $pure float4x2" 87" transpose(float2x4 m);$es3 $pure half4x2 transpose(half2x4 m);$es3 $pure float4x3" 88" transpose(float3x4 m);$es3 $pure half4x3 transpose(half3x4 m);$es3 $pure $squareMat" 89" outerProduct($vec c,$vec r);$es3 $pure $squareHMat outerProduct($hvec c,$hvec" 90" r);$es3 $pure float2x3 outerProduct(float3 c,float2 r);$es3 $pure half2x3 outerProduct" 91"(half3 c,half2 r);$es3 $pure float3x2 outerProduct(float2 c,float3 r);$es3 $pure" 92" half3x2 outerProduct(half2 c,half3 r);$es3 $pure float2x4 outerProduct(float4" 93" c,float2 r);$es3 $pure half2x4 outerProduct(half4 c,half2 r);$es3 $pure float4x2" 94" outerProduct(float2 c,float4 r);$es3 $pure half4x2 outerProduct(half2 c,half4" 95" r);$es3 $pure float3x4 outerProduct(float4 c,float3 r);$es3 $pure half3x4 outerProduct" 96"(half4 c,half3 r);$es3 $pure float4x3 outerProduct(float3 c,float4 r);$es3 $pure" 97" half4x3 outerProduct(half3 c,half4 r);$pure $bvec lessThan($vec x,$vec y);" 98"$pure $bvec lessThan($hvec x,$hvec y);$pure $bvec lessThan($ivec x,$ivec y)" 99";$pure $bvec lessThan($svec x,$svec y);$pure $bvec lessThanEqual($vec x,$vec" 100" y);$pure $bvec lessThanEqual($hvec x,$hvec y);$pure $bvec lessThanEqual($ivec" 101" x,$ivec y);$pure $bvec lessThanEqual($svec x,$svec y);$pure $bvec greaterThan" 102"($vec x,$vec y);$pure $bvec greaterThan($hvec x,$hvec y);$pure $bvec greaterThan" 103"($ivec x,$ivec y);$pure $bvec greaterThan($svec x,$svec y);$pure $bvec greaterThanEqual" 104"($vec x,$vec y);$pure $bvec greaterThanEqual($hvec x,$hvec y);$pure $bvec greaterThanEqual" 105"($ivec x,$ivec y);$pure $bvec greaterThanEqual($svec x,$svec y);$pure $bvec" 106" equal($vec x,$vec y);$pure $bvec equal($hvec x,$hvec y);$pure $bvec equal(" 107"$ivec x,$ivec y);$pure $bvec equal($svec x,$svec y);$pure $bvec equal($bvec" 108" x,$bvec y);$pure $bvec notEqual($vec x,$vec y);$pure $bvec notEqual($hvec x" 109",$hvec y);$pure $bvec notEqual($ivec x,$ivec y);$pure $bvec notEqual($svec x" 110",$svec y);$pure $bvec notEqual($bvec x,$bvec y);$es3 $pure $bvec lessThan($usvec" 111" x,$usvec y);$es3 $pure $bvec lessThan($uvec x,$uvec y);$es3 $pure $bvec lessThanEqual" 112"($uvec x,$uvec y);$es3 $pure $bvec lessThanEqual($usvec x,$usvec y);$es3 $pure" 113" $bvec greaterThan($uvec x,$uvec y);$es3 $pure $bvec greaterThan($usvec x,$usvec" 114" y);$es3 $pure $bvec greaterThanEqual($uvec x,$uvec y);$es3 $pure $bvec greaterThanEqual" 115"($usvec x,$usvec y);$es3 $pure $bvec equal($uvec x,$uvec y);$es3 $pure $bvec" 116" equal($usvec x,$usvec y);$es3 $pure $bvec notEqual($uvec x,$uvec y);$es3 $pure" 117" $bvec notEqual($usvec x,$usvec y);$pure bool any($bvec x);$pure bool all($bvec" 118" x);$pure $bvec not($bvec x);$es3 $pure $genType dFdx($genType p);$es3 $pure" 119" $genType dFdy($genType p);$es3 $pure $genHType dFdx($genHType p);$es3 $pure" 120" $genHType dFdy($genHType p);$es3 $pure $genType fwidth($genType p);$es3 $pure" 121" $genHType fwidth($genHType p);$pure half4 unpremul(half4 color){return half4" 122"(color.xyz/max(color.w,.0001),color.w);}$pure float4 unpremul(float4 color)" 123"{return float4(color.xyz/max(color.w,.0001),color.w);}$export $pure half4 $unpremul_polar" 124"(half4 color){return half4(color.x,color.yz/max(color.w,.0001),color.w);}$export" 125" $pure half4 $rgb_to_hsl(half3 c,half a){half4 p=c.y<c.z?half4(c.zy,-1.,.6666667" 126"):half4(c.yz,0.,-.333333343);half4 q=c.x<p.x?half4(p.x,c.x,p.yw):half4(c.x," 127"p.x,p.yz);const half kEps=.0001;half pmV=q.x;half pmC=pmV-min(q.y,q.z);half" 128" pmL=pmV-pmC*.5;half H=abs(q.w+(q.y-q.z)/(pmC*6.+kEps));half S=pmC/((a+kEps" 129")-abs(pmL*2.-a));half L=pmL/(a+kEps);return half4(H,S,L,a);}$export $pure half3" 130" $hsl_to_rgb(half3 hsl){half C=(1.-abs(2.*hsl.z-1.))*hsl.y;half3 p=hsl.xxx+" 131"half3(0.,.6666667,.333333343);half3 q=saturate(abs(fract(p)*6.-3.)-1.);return" 132"(q-.5)*C+hsl.z;}$export $pure half4 $hsl_to_rgb(half3 hsl,half a){return saturate" 133"(half4($hsl_to_rgb(hsl)*a,a));}$export $pure half3 $css_lab_to_xyz(half3 lab" 134"){const half k=903.2963;const half e=.008856452;half3 f;f.y=(lab.x+16.)*.00862069" 135";f.x=lab.y*.002+f.y;f.z=f.y-lab.z*.005;half3 f_cubed=pow(f,half3(3.));half3" 136" xyz=half3(f_cubed.x>e?f_cubed.x:(116.*f.x-16.)*.00110705639,lab.x>8.000001" 137"?f_cubed.y:lab.x*.00110705639,f_cubed.z>e?f_cubed.z:(116.*f.z-16.)*.00110705639" 138");const half3 D50=half3(.9642956,1.,.825104535);return xyz*D50;}$pure half3" 139" $css_hcl_to_lab(half3 hcl){return half3(hcl.z,hcl.y*cos(radians(hcl.x)),hcl" 140".y*sin(radians(hcl.x)));}$export $pure half3 $css_hcl_to_xyz(half3 hcl){return" 141" $css_lab_to_xyz($css_hcl_to_lab(hcl));}$export $pure half3 $css_oklab_to_linear_srgb" 142"(half3 oklab){half l_=(oklab.x+.396337777*oklab.y)+.215803757*oklab.z;half m_" 143"=(oklab.x-.105561346*oklab.y)-.06385417*oklab.z;half s_=(oklab.x-.08948418*" 144"oklab.y)-1.29148555*oklab.z;half l=(l_*l_)*l_;half m=(m_*m_)*m_;half s=(s_*" 145"s_)*s_;return half3((4.0767417*l-3.3077116*m)+.230969936*s,(-1.268438*l+2.60975742" 146"*m)-.341319382*s,(-.00419608643*l-.7034186*m)+1.70761466*s);}$export $pure half3" 147" $css_okhcl_to_linear_srgb(half3 okhcl){return $css_oklab_to_linear_srgb($css_hcl_to_lab" 148"(okhcl));}$export $pure half3 $css_hsl_to_srgb(half3 hsl){hsl.x=mod(hsl.x,360." 149");if(hsl.x<0.){hsl.x+=360.;}hsl.yz*=.01;half3 k=mod(half3(0.,8.,4.)+hsl.x*.0333333351" 150",12.);half a=hsl.y*min(hsl.z,1.-hsl.z);return hsl.z-a*clamp(min(k-3.,9.-k)," 151"-1.,1.);}$export $pure half3 $css_hwb_to_srgb(half3 hwb){hwb.yz*=.01;if(hwb" 152".y+hwb.z>=1.){half gray=hwb.y/(hwb.y+hwb.z);return half3(gray);}half3 rgb=$css_hsl_to_srgb" 153"(half3(hwb.x,100.,50.));rgb*=(1.-hwb.y)-hwb.z;rgb+=hwb.y;return rgb;}$export" 154" $pure half4 $interpolated_to_rgb_unpremul(half4 color,int colorSpace,int doUnpremul" 155"){const int kDestination=0;const int kSRGBLinear=1;const int kLab=2;const int" 156" kOKLab=3;const int kLCH=4;const int kOKLCH=5;const int kSRGB=6;const int kHSL" 157"=7;const int kHWB=8;if(bool(doUnpremul)){switch(colorSpace){case 2:;case 3:" 158"color=unpremul(color);break;case 4:;case 5:;case 7:;case 8:color=$unpremul_polar" 159"(color);break;}}switch(colorSpace){case 2:{color.xyz=$css_lab_to_xyz(color." 160"xyz);break;}case 3:{color.xyz=$css_oklab_to_linear_srgb(color.xyz);break;}case" 161" 4:{color.xyz=$css_hcl_to_xyz(color.xyz);break;}case 5:{color.xyz=$css_okhcl_to_linear_srgb" 162"(color.xyz);break;}case 7:{color.xyz=$css_hsl_to_srgb(color.xyz);break;}case" 163" 8:{color.xyz=$css_hwb_to_srgb(color.xyz);break;}}return color;}"; 164