@flock/wirespec
Advanced tools
Comparing version 0.9.9 to 0.9.10
@@ -69,17 +69,17 @@ (function (root, factory) { | ||
alpha = alpha === VOID ? 1.0 : alpha; | ||
return $super === VOID ? this.q33(r, g, b, alpha) : $super.q33.call(this, r, g, b, alpha); | ||
return $super === VOID ? this.r33(r, g, b, alpha) : $super.r33.call(this, r, g, b, alpha); | ||
} | ||
function invoke(r, g, b, alpha) { | ||
return this.q33(numberToDouble(r), numberToDouble(g), numberToDouble(b), numberToDouble(alpha)); | ||
return this.r33(numberToDouble(r), numberToDouble(g), numberToDouble(b), numberToDouble(alpha)); | ||
} | ||
function invoke$default_0(r, g, b, alpha, $super) { | ||
alpha = alpha === VOID ? 1.0 : alpha; | ||
return $super === VOID ? this.a34(r, g, b, alpha) : invoke(r, g, b, alpha); | ||
return $super === VOID ? this.b34(r, g, b, alpha) : invoke(r, g, b, alpha); | ||
} | ||
function from255(r, g, b, alpha) { | ||
return this.q33(r / 255.0, g / 255.0, b / 255.0, alpha / 255.0); | ||
return this.r33(r / 255.0, g / 255.0, b / 255.0, alpha / 255.0); | ||
} | ||
function from255$default(r, g, b, alpha, $super) { | ||
alpha = alpha === VOID ? 255 : alpha; | ||
return $super === VOID ? this.b34(r, g, b, alpha) : from255(r, g, b, alpha); | ||
return $super === VOID ? this.c34(r, g, b, alpha) : from255(r, g, b, alpha); | ||
} | ||
@@ -104,3 +104,3 @@ function invoke_0(hex) { | ||
} | ||
return this.b34(tmp, tmp_0, tmp_1, tmp_2); | ||
return this.c34(tmp, tmp_0, tmp_1, tmp_2); | ||
} | ||
@@ -127,15 +127,15 @@ setMetadataFor(RGBColorSpace, 'RGBColorSpace', interfaceMeta); | ||
function ColorComponentInfo(name, isPolar) { | ||
this.k32_1 = name; | ||
this.l32_1 = isPolar; | ||
this.l32_1 = name; | ||
this.m32_1 = isPolar; | ||
} | ||
function WhitePoint(name, chromaticity) { | ||
this.m32_1 = name; | ||
this.n32_1 = chromaticity; | ||
this.n32_1 = name; | ||
this.o32_1 = chromaticity; | ||
} | ||
protoOf(WhitePoint).toString = function () { | ||
return this.m32_1; | ||
return this.n32_1; | ||
}; | ||
protoOf(WhitePoint).hashCode = function () { | ||
var result = getStringHashCode(this.m32_1); | ||
result = imul(result, 31) + this.n32_1.hashCode() | 0; | ||
var result = getStringHashCode(this.n32_1); | ||
result = imul(result, 31) + this.o32_1.hashCode() | 0; | ||
return result; | ||
@@ -149,5 +149,5 @@ }; | ||
var tmp0_other_with_cast = other instanceof WhitePoint ? other : THROW_CCE(); | ||
if (!(this.m32_1 === tmp0_other_with_cast.m32_1)) | ||
if (!(this.n32_1 === tmp0_other_with_cast.n32_1)) | ||
return false; | ||
if (!this.n32_1.equals(tmp0_other_with_cast.n32_1)) | ||
if (!this.o32_1.equals(tmp0_other_with_cast.o32_1)) | ||
return false; | ||
@@ -158,10 +158,10 @@ return true; | ||
Illuminant_instance = this; | ||
this.o32_1 = new WhitePoint('A', xyY_init_$Create$(0.44758, 0.40745)); | ||
this.p32_1 = new WhitePoint('B', xyY_init_$Create$(0.34842, 0.35161)); | ||
this.q32_1 = new WhitePoint('C', xyY_init_$Create$(0.31006, 0.31616)); | ||
this.r32_1 = new WhitePoint('D50', xyY_init_$Create$(0.3457, 0.3585)); | ||
this.s32_1 = new WhitePoint('D55', xyY_init_$Create$(0.33243, 0.34744)); | ||
this.t32_1 = new WhitePoint('D65', xyY_init_$Create$(0.3127, 0.329)); | ||
this.u32_1 = new WhitePoint('D75', xyY_init_$Create$(0.29903, 0.31488)); | ||
this.v32_1 = new WhitePoint('E', xyY_init_$Create$(0.3333333333333333, 0.3333333333333333)); | ||
this.p32_1 = new WhitePoint('A', xyY_init_$Create$(0.44758, 0.40745)); | ||
this.q32_1 = new WhitePoint('B', xyY_init_$Create$(0.34842, 0.35161)); | ||
this.r32_1 = new WhitePoint('C', xyY_init_$Create$(0.31006, 0.31616)); | ||
this.s32_1 = new WhitePoint('D50', xyY_init_$Create$(0.3457, 0.3585)); | ||
this.t32_1 = new WhitePoint('D55', xyY_init_$Create$(0.33243, 0.34744)); | ||
this.u32_1 = new WhitePoint('D65', xyY_init_$Create$(0.3127, 0.329)); | ||
this.v32_1 = new WhitePoint('D75', xyY_init_$Create$(0.29903, 0.31488)); | ||
this.w32_1 = new WhitePoint('E', xyY_init_$Create$(0.3333333333333333, 0.3333333333333333)); | ||
} | ||
@@ -353,3 +353,3 @@ var Illuminant_instance; | ||
Companion_instance = this; | ||
this.w32_1 = componentInfoList([new ColorComponentInfo('code', false)]); | ||
this.x32_1 = componentInfoList([new ColorComponentInfo('code', false)]); | ||
} | ||
@@ -364,31 +364,31 @@ var Companion_instance; | ||
Companion_getInstance(); | ||
this.x32_1 = code; | ||
this.y32_1 = code; | ||
} | ||
protoOf(Ansi16).y32 = function () { | ||
switch (this.x32_1) { | ||
protoOf(Ansi16).z32 = function () { | ||
switch (this.y32_1) { | ||
case 30: | ||
case 40: | ||
return Companion_getInstance_2().z32(0.0, 0.0, 0.0); | ||
return Companion_getInstance_2().a33(0.0, 0.0, 0.0); | ||
case 90: | ||
case 100: | ||
return Companion_getInstance_2().a33(128, 128, 128); | ||
return Companion_getInstance_2().b33(128, 128, 128); | ||
case 37: | ||
case 47: | ||
return Companion_getInstance_2().a33(192, 192, 192); | ||
return Companion_getInstance_2().b33(192, 192, 192); | ||
case 97: | ||
case 107: | ||
return Companion_getInstance_2().z32(1.0, 1.0, 1.0); | ||
return Companion_getInstance_2().a33(1.0, 1.0, 1.0); | ||
} | ||
var color = this.x32_1 % 10 | 0; | ||
var mul = this.x32_1 > 50 ? 1.0 : 0.5; | ||
var color = this.y32_1 % 10 | 0; | ||
var mul = this.y32_1 > 50 ? 1.0 : 0.5; | ||
var r = (color % 2 | 0) * mul; | ||
var g = ((color / 2 | 0) % 2 | 0) * mul; | ||
var b = ((color / 4 | 0) % 2 | 0) * mul; | ||
return Companion_getInstance_2().z32(r, g, b); | ||
return Companion_getInstance_2().a33(r, g, b); | ||
}; | ||
protoOf(Ansi16).toString = function () { | ||
return 'Ansi16(code=' + this.x32_1 + ')'; | ||
return 'Ansi16(code=' + this.y32_1 + ')'; | ||
}; | ||
protoOf(Ansi16).hashCode = function () { | ||
return this.x32_1; | ||
return this.y32_1; | ||
}; | ||
@@ -401,3 +401,3 @@ protoOf(Ansi16).equals = function (other) { | ||
var tmp0_other_with_cast = other instanceof Ansi16 ? other : THROW_CCE(); | ||
if (!(this.x32_1 === tmp0_other_with_cast.x32_1)) | ||
if (!(this.y32_1 === tmp0_other_with_cast.y32_1)) | ||
return false; | ||
@@ -408,3 +408,3 @@ return true; | ||
Companion_instance_0 = this; | ||
this.b33_1 = componentInfoList([new ColorComponentInfo('code', false)]); | ||
this.c33_1 = componentInfoList([new ColorComponentInfo('code', false)]); | ||
} | ||
@@ -419,12 +419,12 @@ var Companion_instance_0; | ||
Companion_getInstance_0(); | ||
this.c33_1 = code; | ||
this.d33_1 = code; | ||
} | ||
protoOf(Ansi256).y32 = function () { | ||
if (this.c33_1 < 16) | ||
return this.d33().y32(); | ||
if (this.c33_1 >= 232) { | ||
var c = imul(this.c33_1 - 232 | 0, 10) + 8 | 0; | ||
return Companion_getInstance_2().a33(c, c, c); | ||
protoOf(Ansi256).z32 = function () { | ||
if (this.d33_1 < 16) | ||
return this.e33().z32(); | ||
if (this.d33_1 >= 232) { | ||
var c = imul(this.d33_1 - 232 | 0, 10) + 8 | 0; | ||
return Companion_getInstance_2().b33(c, c, c); | ||
} | ||
var c_0 = this.c33_1 - 16 | 0; | ||
var c_0 = this.d33_1 - 16 | 0; | ||
var rem = c_0 % 36 | 0; | ||
@@ -438,12 +438,12 @@ // Inline function 'kotlin.math.floor' call | ||
var b = (rem % 6 | 0) / 5.0; | ||
return Companion_getInstance_2().e33(r, g, b); | ||
return Companion_getInstance_2().f33(r, g, b); | ||
}; | ||
protoOf(Ansi256).d33 = function () { | ||
return this.c33_1 < 8 ? new Ansi16(this.c33_1 + 30 | 0) : this.c33_1 < 16 ? new Ansi16((this.c33_1 - 8 | 0) + 90 | 0) : this.y32().d33(); | ||
protoOf(Ansi256).e33 = function () { | ||
return this.d33_1 < 8 ? new Ansi16(this.d33_1 + 30 | 0) : this.d33_1 < 16 ? new Ansi16((this.d33_1 - 8 | 0) + 90 | 0) : this.z32().e33(); | ||
}; | ||
protoOf(Ansi256).toString = function () { | ||
return 'Ansi256(code=' + this.c33_1 + ')'; | ||
return 'Ansi256(code=' + this.d33_1 + ')'; | ||
}; | ||
protoOf(Ansi256).hashCode = function () { | ||
return this.c33_1; | ||
return this.d33_1; | ||
}; | ||
@@ -456,3 +456,3 @@ protoOf(Ansi256).equals = function (other) { | ||
var tmp0_other_with_cast = other instanceof Ansi256 ? other : THROW_CCE(); | ||
if (!(this.c33_1 === tmp0_other_with_cast.c33_1)) | ||
if (!(this.d33_1 === tmp0_other_with_cast.d33_1)) | ||
return false; | ||
@@ -463,3 +463,3 @@ return true; | ||
Companion_instance_1 = this; | ||
this.k33_1 = polarComponentInfo('HSV'); | ||
this.l33_1 = polarComponentInfo('HSV'); | ||
} | ||
@@ -484,23 +484,23 @@ var Companion_instance_1; | ||
alpha = alpha === VOID ? 1.0 : alpha; | ||
this.l33_1 = h; | ||
this.m33_1 = s; | ||
this.n33_1 = v; | ||
this.o33_1 = alpha; | ||
this.m33_1 = h; | ||
this.n33_1 = s; | ||
this.o33_1 = v; | ||
this.p33_1 = alpha; | ||
} | ||
protoOf(HSV).y32 = function () { | ||
if (this.m33_1 < 1.0E-7) | ||
return Companion_getInstance_2().q33(this.n33_1, this.n33_1, this.n33_1, this.o33_1); | ||
var v = this.n33_1; | ||
var h = normalizeDeg_0(this.l33_1) / 60.0; | ||
var s = this.m33_1; | ||
return SRGB_getInstance().q33(toSRGB$f(h, v, s, 5), toSRGB$f(h, v, s, 3), toSRGB$f(h, v, s, 1), this.o33_1); | ||
protoOf(HSV).z32 = function () { | ||
if (this.n33_1 < 1.0E-7) | ||
return Companion_getInstance_2().r33(this.o33_1, this.o33_1, this.o33_1, this.p33_1); | ||
var v = this.o33_1; | ||
var h = normalizeDeg_0(this.m33_1) / 60.0; | ||
var s = this.n33_1; | ||
return SRGB_getInstance().r33(toSRGB$f(h, v, s, 5), toSRGB$f(h, v, s, 3), toSRGB$f(h, v, s, 1), this.p33_1); | ||
}; | ||
protoOf(HSV).toString = function () { | ||
return 'HSV(h=' + this.l33_1 + ', s=' + this.m33_1 + ', v=' + this.n33_1 + ', alpha=' + this.o33_1 + ')'; | ||
return 'HSV(h=' + this.m33_1 + ', s=' + this.n33_1 + ', v=' + this.o33_1 + ', alpha=' + this.p33_1 + ')'; | ||
}; | ||
protoOf(HSV).hashCode = function () { | ||
var result = getNumberHashCode(this.l33_1); | ||
result = imul(result, 31) + getNumberHashCode(this.m33_1) | 0; | ||
var result = getNumberHashCode(this.m33_1); | ||
result = imul(result, 31) + getNumberHashCode(this.n33_1) | 0; | ||
result = imul(result, 31) + getNumberHashCode(this.o33_1) | 0; | ||
result = imul(result, 31) + getNumberHashCode(this.p33_1) | 0; | ||
return result; | ||
@@ -514,4 +514,2 @@ }; | ||
var tmp0_other_with_cast = other instanceof HSV ? other : THROW_CCE(); | ||
if (!equals(this.l33_1, tmp0_other_with_cast.l33_1)) | ||
return false; | ||
if (!equals(this.m33_1, tmp0_other_with_cast.m33_1)) | ||
@@ -523,18 +521,20 @@ return false; | ||
return false; | ||
if (!equals(this.p33_1, tmp0_other_with_cast.p33_1)) | ||
return false; | ||
return true; | ||
}; | ||
function GammaTransferFunctions(gamma) { | ||
this.x33_1 = gamma; | ||
this.y33_1 = gamma; | ||
} | ||
protoOf(GammaTransferFunctions).y33 = function (x) { | ||
return spow(x, this.x33_1); | ||
}; | ||
protoOf(GammaTransferFunctions).z33 = function (x) { | ||
return spow(x, 1.0 / this.x33_1); | ||
return spow(x, this.y33_1); | ||
}; | ||
protoOf(GammaTransferFunctions).a34 = function (x) { | ||
return spow(x, 1.0 / this.y33_1); | ||
}; | ||
protoOf(GammaTransferFunctions).toString = function () { | ||
return 'GammaTransferFunctions(gamma=' + this.x33_1 + ')'; | ||
return 'GammaTransferFunctions(gamma=' + this.y33_1 + ')'; | ||
}; | ||
protoOf(GammaTransferFunctions).hashCode = function () { | ||
return getNumberHashCode(this.x33_1); | ||
return getNumberHashCode(this.y33_1); | ||
}; | ||
@@ -547,3 +547,3 @@ protoOf(GammaTransferFunctions).equals = function (other) { | ||
var tmp0_other_with_cast = other instanceof GammaTransferFunctions ? other : THROW_CCE(); | ||
if (!equals(this.x33_1, tmp0_other_with_cast.x33_1)) | ||
if (!equals(this.y33_1, tmp0_other_with_cast.y33_1)) | ||
return false; | ||
@@ -555,6 +555,6 @@ return true; | ||
} | ||
protoOf(LinearTransferFunctions).y33 = function (x) { | ||
protoOf(LinearTransferFunctions).z33 = function (x) { | ||
return x; | ||
}; | ||
protoOf(LinearTransferFunctions).z33 = function (x) { | ||
protoOf(LinearTransferFunctions).a34 = function (x) { | ||
return x; | ||
@@ -572,27 +572,27 @@ }; | ||
Companion_instance_2 = this; | ||
this.p33_1 = RGBColorSpaces_getInstance().g34_1; | ||
this.q33_1 = RGBColorSpaces_getInstance().h34_1; | ||
} | ||
protoOf(Companion_2).f34 = function () { | ||
return this.q33_1.f34(); | ||
}; | ||
protoOf(Companion_2).e34 = function () { | ||
return this.p33_1.e34(); | ||
return this.q33_1.e34(); | ||
}; | ||
protoOf(Companion_2).d34 = function () { | ||
return this.p33_1.d34(); | ||
return this.q33_1.d34(); | ||
}; | ||
protoOf(Companion_2).c34 = function () { | ||
return this.p33_1.c34(); | ||
protoOf(Companion_2).g34 = function () { | ||
return this.q33_1.g34(); | ||
}; | ||
protoOf(Companion_2).f34 = function () { | ||
return this.p33_1.f34(); | ||
protoOf(Companion_2).c34 = function (r, g, b, alpha) { | ||
return this.q33_1.c34(r, g, b, alpha); | ||
}; | ||
protoOf(Companion_2).r33 = function (r, g, b, alpha) { | ||
return this.q33_1.r33(r, g, b, alpha); | ||
}; | ||
protoOf(Companion_2).b34 = function (r, g, b, alpha) { | ||
return this.p33_1.b34(r, g, b, alpha); | ||
return this.q33_1.b34(r, g, b, alpha); | ||
}; | ||
protoOf(Companion_2).q33 = function (r, g, b, alpha) { | ||
return this.p33_1.q33(r, g, b, alpha); | ||
}; | ||
protoOf(Companion_2).a34 = function (r, g, b, alpha) { | ||
return this.p33_1.a34(r, g, b, alpha); | ||
}; | ||
protoOf(Companion_2).j28 = function (hex) { | ||
return this.p33_1.j28(hex); | ||
return this.q33_1.j28(hex); | ||
}; | ||
@@ -607,13 +607,8 @@ var Companion_instance_2; | ||
Companion_getInstance_2(); | ||
this.f33_1 = r; | ||
this.g33_1 = g; | ||
this.h33_1 = b; | ||
this.i33_1 = alpha; | ||
this.j33_1 = space; | ||
this.g33_1 = r; | ||
this.h33_1 = g; | ||
this.i33_1 = b; | ||
this.j33_1 = alpha; | ||
this.k33_1 = space; | ||
} | ||
protoOf(RGB).s34 = function () { | ||
// Inline function 'kotlin.math.roundToInt' call | ||
var tmp0_roundToInt = this.f33_1 * 255; | ||
return roundToInt(tmp0_roundToInt); | ||
}; | ||
protoOf(RGB).t34 = function () { | ||
@@ -629,10 +624,15 @@ // Inline function 'kotlin.math.roundToInt' call | ||
}; | ||
protoOf(RGB).v34 = function (space) { | ||
var f = SRGB_getInstance().u33_1; | ||
return equals(this.j33_1, space) ? this : (equals(this.j33_1, SRGB_getInstance()) ? equals(space, RGBColorSpaces_getInstance().h34_1) : false) ? space.q33(f.y33(this.f33_1), f.y33(this.g33_1), f.y33(this.h33_1), this.i33_1) : (equals(this.j33_1, RGBColorSpaces_getInstance().h34_1) ? equals(space, SRGB_getInstance()) : false) ? space.q33(f.z33(this.f33_1), f.z33(this.g33_1), f.z33(this.h33_1), this.i33_1) : this.w34().c35(space); | ||
protoOf(RGB).v34 = function () { | ||
// Inline function 'kotlin.math.roundToInt' call | ||
var tmp0_roundToInt = this.i33_1 * 255; | ||
return roundToInt(tmp0_roundToInt); | ||
}; | ||
protoOf(RGB).d35 = function () { | ||
return this.e35(coerceIn(this.f33_1, 0.0, 1.0), coerceIn(this.g33_1, 0.0, 1.0), coerceIn(this.h33_1, 0.0, 1.0), coerceIn(this.i33_1, 0.0, 1.0)); | ||
protoOf(RGB).w34 = function (space) { | ||
var f = SRGB_getInstance().v33_1; | ||
return equals(this.k33_1, space) ? this : (equals(this.k33_1, SRGB_getInstance()) ? equals(space, RGBColorSpaces_getInstance().i34_1) : false) ? space.r33(f.z33(this.g33_1), f.z33(this.h33_1), f.z33(this.i33_1), this.j33_1) : (equals(this.k33_1, RGBColorSpaces_getInstance().i34_1) ? equals(space, SRGB_getInstance()) : false) ? space.r33(f.a34(this.g33_1), f.a34(this.h33_1), f.a34(this.i33_1), this.j33_1) : this.x34().d35(space); | ||
}; | ||
protoOf(RGB).f35 = function () { | ||
protoOf(RGB).e35 = function () { | ||
return this.f35(coerceIn(this.g33_1, 0.0, 1.0), coerceIn(this.h33_1, 0.0, 1.0), coerceIn(this.i33_1, 0.0, 1.0), coerceIn(this.j33_1, 0.0, 1.0)); | ||
}; | ||
protoOf(RGB).g35 = function () { | ||
var tmp$ret$3; | ||
@@ -642,6 +642,6 @@ $l$block: { | ||
// Inline function 'com.github.ajalt.colormath.model.RGB.toSRGB' call | ||
var tmp0_anonymous = this.v34(SRGB_getInstance()); | ||
var r = tmp0_anonymous.f33_1; | ||
var g = tmp0_anonymous.g33_1; | ||
var b = tmp0_anonymous.h33_1; | ||
var tmp0_anonymous = this.w34(SRGB_getInstance()); | ||
var r = tmp0_anonymous.g33_1; | ||
var g = tmp0_anonymous.h33_1; | ||
var b = tmp0_anonymous.i33_1; | ||
// Inline function 'kotlin.comparisons.minOf' call | ||
@@ -669,3 +669,3 @@ var min = Math.min(r, g, b); | ||
var s = max === 0.0 ? 0.0 : chroma / max; | ||
tmp$ret$3 = new HSV(tmp0_anonymous_0, s, max, this.i33_1); | ||
tmp$ret$3 = new HSV(tmp0_anonymous_0, s, max, this.j33_1); | ||
break $l$block; | ||
@@ -675,9 +675,9 @@ } | ||
}; | ||
protoOf(RGB).w34 = function () { | ||
var f = this.j33_1.c34(); | ||
protoOf(RGB).x34 = function () { | ||
var f = this.k33_1.d34(); | ||
// Inline function 'com.github.ajalt.colormath.internal.dot' call | ||
var tmp0_dot = _Matrix___init__impl__q3kp4w(this.j33_1.d34()); | ||
var tmp1_dot = f.y33(this.f33_1); | ||
var tmp2_dot = f.y33(this.g33_1); | ||
var tmp3_dot = f.y33(this.h33_1); | ||
var tmp0_dot = _Matrix___init__impl__q3kp4w(this.k33_1.e34()); | ||
var tmp1_dot = f.z33(this.g33_1); | ||
var tmp2_dot = f.z33(this.h33_1); | ||
var tmp3_dot = f.z33(this.i33_1); | ||
// Inline function 'com.github.ajalt.colormath.model.RGB.toXYZ.<anonymous>' call | ||
@@ -687,9 +687,9 @@ var tmp4_anonymous = Matrix__get_impl_xogbpk(tmp0_dot, 0, 0) * tmp1_dot + Matrix__get_impl_xogbpk(tmp0_dot, 1, 0) * tmp2_dot + Matrix__get_impl_xogbpk(tmp0_dot, 2, 0) * tmp3_dot; | ||
var tmp6_anonymous = Matrix__get_impl_xogbpk(tmp0_dot, 0, 2) * tmp1_dot + Matrix__get_impl_xogbpk(tmp0_dot, 1, 2) * tmp2_dot + Matrix__get_impl_xogbpk(tmp0_dot, 2, 2) * tmp3_dot; | ||
return XYZColorSpace(this.j33_1.f34()).q33(tmp4_anonymous, tmp5_anonymous, tmp6_anonymous, this.i33_1); | ||
return XYZColorSpace(this.k33_1.g34()).r33(tmp4_anonymous, tmp5_anonymous, tmp6_anonymous, this.j33_1); | ||
}; | ||
protoOf(RGB).d33 = function () { | ||
protoOf(RGB).e33 = function () { | ||
// Inline function 'com.github.ajalt.colormath.model.RGB.toSRGB' call | ||
var tmp0_anonymous = this.v34(SRGB_getInstance()); | ||
var tmp0_anonymous = this.w34(SRGB_getInstance()); | ||
// Inline function 'kotlin.math.roundToInt' call | ||
var tmp0_roundToInt = tmp0_anonymous.f35().n33_1 * 100; | ||
var tmp0_roundToInt = tmp0_anonymous.g35().o33_1 * 100; | ||
var value = roundToInt(tmp0_roundToInt); | ||
@@ -701,3 +701,3 @@ if (value === 30) | ||
// Inline function 'kotlin.math.roundToInt' call | ||
var tmp1_roundToInt = tmp0_anonymous.h33_1; | ||
var tmp1_roundToInt = tmp0_anonymous.i33_1; | ||
tmp$ret$1 = roundToInt(tmp1_roundToInt); | ||
@@ -707,16 +707,16 @@ var tmp = imul(tmp$ret$1, 4); | ||
// Inline function 'kotlin.math.roundToInt' call | ||
var tmp2_roundToInt = tmp0_anonymous.g33_1; | ||
var tmp2_roundToInt = tmp0_anonymous.h33_1; | ||
tmp$ret$2 = roundToInt(tmp2_roundToInt); | ||
var tmp_0 = tmp | imul(tmp$ret$2, 2); | ||
// Inline function 'kotlin.math.roundToInt' call | ||
var tmp3_roundToInt = tmp0_anonymous.f33_1; | ||
var tmp3_roundToInt = tmp0_anonymous.g33_1; | ||
var ansi = 30 + (tmp_0 | roundToInt(tmp3_roundToInt)) | 0; | ||
return new Ansi16(v === 2 ? ansi + 60 | 0 : ansi); | ||
}; | ||
protoOf(RGB).g35 = function () { | ||
protoOf(RGB).h35 = function () { | ||
// Inline function 'com.github.ajalt.colormath.model.RGB.toSRGB' call | ||
var tmp0_anonymous = this.v34(SRGB_getInstance()); | ||
var ri = tmp0_anonymous.s34(); | ||
var gi = tmp0_anonymous.t34(); | ||
var bi = tmp0_anonymous.u34(); | ||
var tmp0_anonymous = this.w34(SRGB_getInstance()); | ||
var ri = tmp0_anonymous.t34(); | ||
var gi = tmp0_anonymous.u34(); | ||
var bi = tmp0_anonymous.v34(); | ||
var tmp; | ||
@@ -728,3 +728,3 @@ if (ri === gi ? gi === bi : false) { | ||
// Inline function 'kotlin.math.roundToInt' call | ||
var tmp0_roundToInt = tmp0_anonymous.f33_1 * 5; | ||
var tmp0_roundToInt = tmp0_anonymous.g33_1 * 5; | ||
tmp$ret$0 = roundToInt(tmp0_roundToInt); | ||
@@ -734,7 +734,7 @@ var tmp_0 = 16 + imul(36, tmp$ret$0) | 0; | ||
// Inline function 'kotlin.math.roundToInt' call | ||
var tmp1_roundToInt = tmp0_anonymous.g33_1 * 5; | ||
var tmp1_roundToInt = tmp0_anonymous.h33_1 * 5; | ||
tmp$ret$1 = roundToInt(tmp1_roundToInt); | ||
var tmp_1 = tmp_0 + imul(6, tmp$ret$1) | 0; | ||
// Inline function 'kotlin.math.roundToInt' call | ||
var tmp2_roundToInt = tmp0_anonymous.h33_1 * 5; | ||
var tmp2_roundToInt = tmp0_anonymous.i33_1 * 5; | ||
tmp = tmp_1 + roundToInt(tmp2_roundToInt) | 0; | ||
@@ -745,25 +745,25 @@ } | ||
}; | ||
protoOf(RGB).y32 = function () { | ||
return this.v34(RGBColorSpaces_getInstance().g34_1); | ||
protoOf(RGB).z32 = function () { | ||
return this.w34(RGBColorSpaces_getInstance().h34_1); | ||
}; | ||
protoOf(RGB).h35 = function (r, g, b, alpha, space) { | ||
protoOf(RGB).i35 = function (r, g, b, alpha, space) { | ||
return new RGB(r, g, b, alpha, space); | ||
}; | ||
protoOf(RGB).e35 = function (r, g, b, alpha, space, $super) { | ||
r = r === VOID ? this.f33_1 : r; | ||
g = g === VOID ? this.g33_1 : g; | ||
b = b === VOID ? this.h33_1 : b; | ||
alpha = alpha === VOID ? this.i33_1 : alpha; | ||
space = space === VOID ? this.j33_1 : space; | ||
return $super === VOID ? this.h35(r, g, b, alpha, space) : $super.h35.call(this, r, g, b, alpha, space); | ||
protoOf(RGB).f35 = function (r, g, b, alpha, space, $super) { | ||
r = r === VOID ? this.g33_1 : r; | ||
g = g === VOID ? this.h33_1 : g; | ||
b = b === VOID ? this.i33_1 : b; | ||
alpha = alpha === VOID ? this.j33_1 : alpha; | ||
space = space === VOID ? this.k33_1 : space; | ||
return $super === VOID ? this.i35(r, g, b, alpha, space) : $super.i35.call(this, r, g, b, alpha, space); | ||
}; | ||
protoOf(RGB).toString = function () { | ||
return 'RGB(r=' + this.f33_1 + ', g=' + this.g33_1 + ', b=' + this.h33_1 + ', alpha=' + this.i33_1 + ', space=' + this.j33_1 + ')'; | ||
return 'RGB(r=' + this.g33_1 + ', g=' + this.h33_1 + ', b=' + this.i33_1 + ', alpha=' + this.j33_1 + ', space=' + this.k33_1 + ')'; | ||
}; | ||
protoOf(RGB).hashCode = function () { | ||
var result = getNumberHashCode(this.f33_1); | ||
result = imul(result, 31) + getNumberHashCode(this.g33_1) | 0; | ||
var result = getNumberHashCode(this.g33_1); | ||
result = imul(result, 31) + getNumberHashCode(this.h33_1) | 0; | ||
result = imul(result, 31) + getNumberHashCode(this.i33_1) | 0; | ||
result = imul(result, 31) + hashCode(this.j33_1) | 0; | ||
result = imul(result, 31) + getNumberHashCode(this.j33_1) | 0; | ||
result = imul(result, 31) + hashCode(this.k33_1) | 0; | ||
return result; | ||
@@ -777,4 +777,2 @@ }; | ||
var tmp0_other_with_cast = other instanceof RGB ? other : THROW_CCE(); | ||
if (!equals(this.f33_1, tmp0_other_with_cast.f33_1)) | ||
return false; | ||
if (!equals(this.g33_1, tmp0_other_with_cast.g33_1)) | ||
@@ -788,2 +786,4 @@ return false; | ||
return false; | ||
if (!equals(this.k33_1, tmp0_other_with_cast.k33_1)) | ||
return false; | ||
return true; | ||
@@ -891,14 +891,14 @@ }; | ||
RGBColorSpaces_instance = this; | ||
this.g34_1 = SRGB_getInstance(); | ||
this.h34_1 = RGBColorSpace_0('Linear sRGB', Illuminant_getInstance().t32_1, LinearTransferFunctions_getInstance(), get_SRGB_R(), get_SRGB_G(), get_SRGB_B()); | ||
this.i34_1 = RGBColorSpace_0('ACES2065-1', get_ACES_WHITE_POINT(), LinearTransferFunctions_getInstance(), get_ACES_AP0_R(), get_ACES_AP0_G(), get_ACES_AP0_B()); | ||
this.j34_1 = RGBColorSpace_0('ACEScc', get_ACES_WHITE_POINT(), ACESccTransferFunctions_getInstance(), get_ACES_AP1_R(), get_ACES_AP1_G(), get_ACES_AP1_B()); | ||
this.k34_1 = RGBColorSpace_0('ACEScct', get_ACES_WHITE_POINT(), ACEScctTransferFunctions_getInstance(), get_ACES_AP1_R(), get_ACES_AP1_G(), get_ACES_AP1_B()); | ||
this.l34_1 = RGBColorSpace_0('ACEScg', get_ACES_WHITE_POINT(), LinearTransferFunctions_getInstance(), get_ACES_AP1_R(), get_ACES_AP1_G(), get_ACES_AP1_B()); | ||
this.m34_1 = RGBColorSpace_0('Adobe RGB', Illuminant_getInstance().t32_1, new GammaTransferFunctions(2.19921875), xyY_init_$Create$(0.64, 0.33), xyY_init_$Create$(0.21, 0.71), xyY_init_$Create$(0.15, 0.06)); | ||
this.n34_1 = BT2020Space_getInstance(); | ||
this.o34_1 = RGBColorSpace_0('BT.709', Illuminant_getInstance().t32_1, BT709TransferFunctions_getInstance(), xyY_init_$Create$(0.64, 0.33), xyY_init_$Create$(0.3, 0.6), xyY_init_$Create$(0.15, 0.06)); | ||
this.p34_1 = RGBColorSpace_0('DCI P3', new WhitePoint('DCI P3', xyY_init_$Create$(0.314, 0.351)), new GammaTransferFunctions(2.6), xyY_init_$Create$(0.68, 0.32), xyY_init_$Create$(0.265, 0.69), xyY_init_$Create$(0.15, 0.06)); | ||
this.q34_1 = RGBColorSpace_0('Display P3', Illuminant_getInstance().t32_1, SRGBTransferFunctions_getInstance(), xyY_init_$Create$(0.68, 0.32), xyY_init_$Create$(0.265, 0.69), xyY_init_$Create$(0.15, 0.06)); | ||
this.r34_1 = RGBColorSpace_0('ROMM RGB', Illuminant_getInstance().r32_1, ROMMTransferFunctions_getInstance(), xyY_init_$Create$(0.7347, 0.2653), xyY_init_$Create$(0.1596, 0.8404), xyY_init_$Create$(0.0366, 1.0E-4)); | ||
this.h34_1 = SRGB_getInstance(); | ||
this.i34_1 = RGBColorSpace_0('Linear sRGB', Illuminant_getInstance().u32_1, LinearTransferFunctions_getInstance(), get_SRGB_R(), get_SRGB_G(), get_SRGB_B()); | ||
this.j34_1 = RGBColorSpace_0('ACES2065-1', get_ACES_WHITE_POINT(), LinearTransferFunctions_getInstance(), get_ACES_AP0_R(), get_ACES_AP0_G(), get_ACES_AP0_B()); | ||
this.k34_1 = RGBColorSpace_0('ACEScc', get_ACES_WHITE_POINT(), ACESccTransferFunctions_getInstance(), get_ACES_AP1_R(), get_ACES_AP1_G(), get_ACES_AP1_B()); | ||
this.l34_1 = RGBColorSpace_0('ACEScct', get_ACES_WHITE_POINT(), ACEScctTransferFunctions_getInstance(), get_ACES_AP1_R(), get_ACES_AP1_G(), get_ACES_AP1_B()); | ||
this.m34_1 = RGBColorSpace_0('ACEScg', get_ACES_WHITE_POINT(), LinearTransferFunctions_getInstance(), get_ACES_AP1_R(), get_ACES_AP1_G(), get_ACES_AP1_B()); | ||
this.n34_1 = RGBColorSpace_0('Adobe RGB', Illuminant_getInstance().u32_1, new GammaTransferFunctions(2.19921875), xyY_init_$Create$(0.64, 0.33), xyY_init_$Create$(0.21, 0.71), xyY_init_$Create$(0.15, 0.06)); | ||
this.o34_1 = BT2020Space_getInstance(); | ||
this.p34_1 = RGBColorSpace_0('BT.709', Illuminant_getInstance().u32_1, BT709TransferFunctions_getInstance(), xyY_init_$Create$(0.64, 0.33), xyY_init_$Create$(0.3, 0.6), xyY_init_$Create$(0.15, 0.06)); | ||
this.q34_1 = RGBColorSpace_0('DCI P3', new WhitePoint('DCI P3', xyY_init_$Create$(0.314, 0.351)), new GammaTransferFunctions(2.6), xyY_init_$Create$(0.68, 0.32), xyY_init_$Create$(0.265, 0.69), xyY_init_$Create$(0.15, 0.06)); | ||
this.r34_1 = RGBColorSpace_0('Display P3', Illuminant_getInstance().u32_1, SRGBTransferFunctions_getInstance(), xyY_init_$Create$(0.68, 0.32), xyY_init_$Create$(0.265, 0.69), xyY_init_$Create$(0.15, 0.06)); | ||
this.s34_1 = RGBColorSpace_0('ROMM RGB', Illuminant_getInstance().s32_1, ROMMTransferFunctions_getInstance(), xyY_init_$Create$(0.7347, 0.2653), xyY_init_$Create$(0.1596, 0.8404), xyY_init_$Create$(0.0366, 1.0E-4)); | ||
} | ||
@@ -913,13 +913,10 @@ var RGBColorSpaces_instance; | ||
SRGB_instance = this; | ||
this.r33_1 = 'sRGB'; | ||
this.s33_1 = rectangularComponentInfo('RGB'); | ||
this.t33_1 = Illuminant_getInstance().t32_1; | ||
this.u33_1 = SRGBTransferFunctions_getInstance(); | ||
this.v33_1 = _Matrix___get_rowMajor__impl__vmgxkq(rgbToXyzMatrix(this.t33_1, get_SRGB_R(), get_SRGB_G(), get_SRGB_B())); | ||
this.w33_1 = _Matrix___get_rowMajor__impl__vmgxkq(inverse(_Matrix___init__impl__q3kp4w(this.v33_1))); | ||
this.s33_1 = 'sRGB'; | ||
this.t33_1 = rectangularComponentInfo('RGB'); | ||
this.u33_1 = Illuminant_getInstance().u32_1; | ||
this.v33_1 = SRGBTransferFunctions_getInstance(); | ||
this.w33_1 = _Matrix___get_rowMajor__impl__vmgxkq(rgbToXyzMatrix(this.u33_1, get_SRGB_R(), get_SRGB_G(), get_SRGB_B())); | ||
this.x33_1 = _Matrix___get_rowMajor__impl__vmgxkq(inverse(_Matrix___init__impl__q3kp4w(this.w33_1))); | ||
} | ||
protoOf(SRGB).f34 = function () { | ||
return this.t33_1; | ||
}; | ||
protoOf(SRGB).c34 = function () { | ||
protoOf(SRGB).g34 = function () { | ||
return this.u33_1; | ||
@@ -933,6 +930,9 @@ }; | ||
}; | ||
protoOf(SRGB).f34 = function () { | ||
return this.x33_1; | ||
}; | ||
protoOf(SRGB).toString = function () { | ||
return this.r33_1; | ||
return this.s33_1; | ||
}; | ||
protoOf(SRGB).q33 = function (r, g, b, alpha) { | ||
protoOf(SRGB).r33 = function (r, g, b, alpha) { | ||
return new RGB(r, g, b, alpha, this); | ||
@@ -952,14 +952,14 @@ }; | ||
ACESccTransferFunctions_instance = this; | ||
this.i35_1 = 3.0517578125E-5; | ||
this.j35_1 = 1.52587890625E-5; | ||
this.k35_1 = -0.3013698630136986; | ||
this.j35_1 = 3.0517578125E-5; | ||
this.k35_1 = 1.52587890625E-5; | ||
this.l35_1 = -0.3013698630136986; | ||
var tmp = this; | ||
// Inline function 'kotlin.math.log2' call | ||
tmp.l35_1 = (log2(65504.0) + 9.72) / 17.52; | ||
tmp.m35_1 = (log2(65504.0) + 9.72) / 17.52; | ||
} | ||
protoOf(ACESccTransferFunctions).y33 = function (x) { | ||
protoOf(ACESccTransferFunctions).z33 = function (x) { | ||
var tmp; | ||
if (x <= -0.3013698630136986) { | ||
tmp = (spow_0(2.0, x * 17.52 - 9.72) - 1.52587890625E-5) * 2.0; | ||
} else if (x < this.l35_1) { | ||
} else if (x < this.m35_1) { | ||
// Inline function 'kotlin.math.pow' call | ||
@@ -973,3 +973,3 @@ var tmp0_pow = x * 17.52 - 9.72; | ||
}; | ||
protoOf(ACESccTransferFunctions).z33 = function (x) { | ||
protoOf(ACESccTransferFunctions).a34 = function (x) { | ||
var tmp; | ||
@@ -994,13 +994,13 @@ if (x < 3.0517578125E-5) { | ||
ACEScctTransferFunctions_instance = this; | ||
this.m35_1 = 10.5402377416545; | ||
this.n35_1 = 0.0729055341958355; | ||
this.n35_1 = 10.5402377416545; | ||
this.o35_1 = 0.0729055341958355; | ||
var tmp = this; | ||
// Inline function 'kotlin.math.log2' call | ||
tmp.o35_1 = (log2(65504.0) + 9.72) / 17.52; | ||
tmp.p35_1 = (log2(65504.0) + 9.72) / 17.52; | ||
} | ||
protoOf(ACEScctTransferFunctions).y33 = function (x) { | ||
protoOf(ACEScctTransferFunctions).z33 = function (x) { | ||
var tmp; | ||
if (x <= 0.155251141552511) { | ||
tmp = (x - 0.0729055341958355) / 10.5402377416545; | ||
} else if (x < this.o35_1) { | ||
} else if (x < this.p35_1) { | ||
// Inline function 'kotlin.math.pow' call | ||
@@ -1014,3 +1014,3 @@ var tmp0_pow = x * 17.52 - 9.72; | ||
}; | ||
protoOf(ACEScctTransferFunctions).z33 = function (x) { | ||
protoOf(ACEScctTransferFunctions).a34 = function (x) { | ||
var tmp; | ||
@@ -1033,26 +1033,26 @@ if (x < 0.0078125) { | ||
BT2020Space_instance = this; | ||
this.p35_1 = 'BT.2020'; | ||
this.q35_1 = rectangularComponentInfo('RGB'); | ||
this.r35_1 = Illuminant_getInstance().t32_1; | ||
this.s35_1 = BT2020TransferFunctions_getInstance(); | ||
this.t35_1 = _Matrix___get_rowMajor__impl__vmgxkq(rgbToXyzMatrix(this.r35_1, xyY_init_$Create$(0.708, 0.292), xyY_init_$Create$(0.17, 0.797), xyY_init_$Create$(0.131, 0.046))); | ||
this.u35_1 = _Matrix___get_rowMajor__impl__vmgxkq(inverse(_Matrix___init__impl__q3kp4w(this.t35_1))); | ||
this.q35_1 = 'BT.2020'; | ||
this.r35_1 = rectangularComponentInfo('RGB'); | ||
this.s35_1 = Illuminant_getInstance().u32_1; | ||
this.t35_1 = BT2020TransferFunctions_getInstance(); | ||
this.u35_1 = _Matrix___get_rowMajor__impl__vmgxkq(rgbToXyzMatrix(this.s35_1, xyY_init_$Create$(0.708, 0.292), xyY_init_$Create$(0.17, 0.797), xyY_init_$Create$(0.131, 0.046))); | ||
this.v35_1 = _Matrix___get_rowMajor__impl__vmgxkq(inverse(_Matrix___init__impl__q3kp4w(this.u35_1))); | ||
} | ||
protoOf(BT2020Space).f34 = function () { | ||
return this.r35_1; | ||
}; | ||
protoOf(BT2020Space).c34 = function () { | ||
protoOf(BT2020Space).g34 = function () { | ||
return this.s35_1; | ||
}; | ||
protoOf(BT2020Space).q33 = function (r, g, b, alpha) { | ||
return new RGB(r, g, b, alpha, this); | ||
}; | ||
protoOf(BT2020Space).d34 = function () { | ||
return this.t35_1; | ||
}; | ||
protoOf(BT2020Space).r33 = function (r, g, b, alpha) { | ||
return new RGB(r, g, b, alpha, this); | ||
}; | ||
protoOf(BT2020Space).e34 = function () { | ||
return this.u35_1; | ||
}; | ||
protoOf(BT2020Space).f34 = function () { | ||
return this.v35_1; | ||
}; | ||
protoOf(BT2020Space).toString = function () { | ||
return this.p35_1; | ||
return this.q35_1; | ||
}; | ||
@@ -1067,8 +1067,8 @@ var BT2020Space_instance; | ||
BT709TransferFunctions_instance = this; | ||
this.v35_1 = 1.099 * spow_0(0.018, 0.45) - 0.099; | ||
this.w35_1 = 1.099 * spow_0(0.018, 0.45) - 0.099; | ||
} | ||
protoOf(BT709TransferFunctions).y33 = function (x) { | ||
return numberToDouble(x < this.v35_1 ? x / 4.5 : spow_0((x + 0.099) / 1.099, 2.2222222222222223)); | ||
protoOf(BT709TransferFunctions).z33 = function (x) { | ||
return numberToDouble(x < this.w35_1 ? x / 4.5 : spow_0((x + 0.099) / 1.099, 2.2222222222222223)); | ||
}; | ||
protoOf(BT709TransferFunctions).z33 = function (x) { | ||
protoOf(BT709TransferFunctions).a34 = function (x) { | ||
return x < 0.018 ? 4.5 * x : 1.099 * spow(x, 0.45) - 0.099; | ||
@@ -1085,6 +1085,6 @@ }; | ||
} | ||
protoOf(SRGBTransferFunctions).z33 = function (x) { | ||
protoOf(SRGBTransferFunctions).a34 = function (x) { | ||
return x <= 0.0031308 ? x * 12.92 : 1.055 * spow(x, 0.4166666666666667) - 0.055; | ||
}; | ||
protoOf(SRGBTransferFunctions).y33 = function (x) { | ||
protoOf(SRGBTransferFunctions).z33 = function (x) { | ||
return x <= 0.04045 ? x / 12.92 : spow_0((x + 0.055) / 1.055, 2.4); | ||
@@ -1100,8 +1100,8 @@ }; | ||
ROMMTransferFunctions_instance = this; | ||
this.w35_1 = 0.001953; | ||
this.x35_1 = 0.001953; | ||
} | ||
protoOf(ROMMTransferFunctions).y33 = function (x) { | ||
protoOf(ROMMTransferFunctions).z33 = function (x) { | ||
return x < 0.031248 ? x / 16.0 : spow(x, 1.8); | ||
}; | ||
protoOf(ROMMTransferFunctions).z33 = function (x) { | ||
protoOf(ROMMTransferFunctions).a34 = function (x) { | ||
return x < 0.001953 ? x * 16.0 : spow(x, 0.5555555555555556); | ||
@@ -1117,9 +1117,9 @@ }; | ||
_init_properties_RGBColorSpaces_kt__nc9fsz(); | ||
var primaries = _Matrix___init__impl__q3kp4w_0(r.x35_1, g.x35_1, b.x35_1, r.y35_1, g.y35_1, b.y35_1, r.a36(), g.a36(), b.a36()); | ||
var wp = whitePoint.n32_1; | ||
var primaries = _Matrix___init__impl__q3kp4w_0(r.y35_1, g.y35_1, b.y35_1, r.z35_1, g.z35_1, b.z35_1, r.b36(), g.b36(), b.b36()); | ||
var wp = whitePoint.o32_1; | ||
// Inline function 'com.github.ajalt.colormath.internal.dot' call | ||
var tmp0_dot = inverse(primaries); | ||
var tmp1_dot = wp.b36(); | ||
var tmp2_dot = wp.z35_1; | ||
var tmp3_dot = wp.c36(); | ||
var tmp1_dot = wp.c36(); | ||
var tmp2_dot = wp.a36_1; | ||
var tmp3_dot = wp.d36(); | ||
// Inline function 'com.github.ajalt.colormath.model.rgbToXyzMatrix.<anonymous>' call | ||
@@ -1132,20 +1132,17 @@ var tmp4_anonymous = Matrix__get_impl_xogbpk(tmp0_dot, 0, 0) * tmp1_dot + Matrix__get_impl_xogbpk(tmp0_dot, 1, 0) * tmp2_dot + Matrix__get_impl_xogbpk(tmp0_dot, 2, 0) * tmp3_dot; | ||
function RGBColorSpaceImpl(name, whitePoint, transferFunctions, r, g, b) { | ||
this.d36_1 = name; | ||
this.e36_1 = whitePoint; | ||
this.f36_1 = transferFunctions; | ||
this.g36_1 = r; | ||
this.h36_1 = g; | ||
this.i36_1 = b; | ||
this.j36_1 = rectangularComponentInfo('RGB'); | ||
this.k36_1 = _Matrix___get_rowMajor__impl__vmgxkq(rgbToXyzMatrix(this.e36_1, this.g36_1, this.h36_1, this.i36_1)); | ||
this.l36_1 = _Matrix___get_rowMajor__impl__vmgxkq(inverse(_Matrix___init__impl__q3kp4w(this.k36_1))); | ||
this.e36_1 = name; | ||
this.f36_1 = whitePoint; | ||
this.g36_1 = transferFunctions; | ||
this.h36_1 = r; | ||
this.i36_1 = g; | ||
this.j36_1 = b; | ||
this.k36_1 = rectangularComponentInfo('RGB'); | ||
this.l36_1 = _Matrix___get_rowMajor__impl__vmgxkq(rgbToXyzMatrix(this.f36_1, this.h36_1, this.i36_1, this.j36_1)); | ||
this.m36_1 = _Matrix___get_rowMajor__impl__vmgxkq(inverse(_Matrix___init__impl__q3kp4w(this.l36_1))); | ||
} | ||
protoOf(RGBColorSpaceImpl).f34 = function () { | ||
return this.e36_1; | ||
}; | ||
protoOf(RGBColorSpaceImpl).c34 = function () { | ||
protoOf(RGBColorSpaceImpl).g34 = function () { | ||
return this.f36_1; | ||
}; | ||
protoOf(RGBColorSpaceImpl).d34 = function () { | ||
return this.k36_1; | ||
return this.g36_1; | ||
}; | ||
@@ -1155,15 +1152,18 @@ protoOf(RGBColorSpaceImpl).e34 = function () { | ||
}; | ||
protoOf(RGBColorSpaceImpl).f34 = function () { | ||
return this.m36_1; | ||
}; | ||
protoOf(RGBColorSpaceImpl).toString = function () { | ||
return this.d36_1; | ||
return this.e36_1; | ||
}; | ||
protoOf(RGBColorSpaceImpl).q33 = function (r, g, b, alpha) { | ||
protoOf(RGBColorSpaceImpl).r33 = function (r, g, b, alpha) { | ||
return new RGB(r, g, b, alpha, this); | ||
}; | ||
protoOf(RGBColorSpaceImpl).hashCode = function () { | ||
var result = getStringHashCode(this.d36_1); | ||
result = imul(result, 31) + this.e36_1.hashCode() | 0; | ||
result = imul(result, 31) + hashCode(this.f36_1) | 0; | ||
result = imul(result, 31) + this.g36_1.hashCode() | 0; | ||
var result = getStringHashCode(this.e36_1); | ||
result = imul(result, 31) + this.f36_1.hashCode() | 0; | ||
result = imul(result, 31) + hashCode(this.g36_1) | 0; | ||
result = imul(result, 31) + this.h36_1.hashCode() | 0; | ||
result = imul(result, 31) + this.i36_1.hashCode() | 0; | ||
result = imul(result, 31) + this.j36_1.hashCode() | 0; | ||
return result; | ||
@@ -1177,10 +1177,8 @@ }; | ||
var tmp0_other_with_cast = other instanceof RGBColorSpaceImpl ? other : THROW_CCE(); | ||
if (!(this.d36_1 === tmp0_other_with_cast.d36_1)) | ||
if (!(this.e36_1 === tmp0_other_with_cast.e36_1)) | ||
return false; | ||
if (!this.e36_1.equals(tmp0_other_with_cast.e36_1)) | ||
if (!this.f36_1.equals(tmp0_other_with_cast.f36_1)) | ||
return false; | ||
if (!equals(this.f36_1, tmp0_other_with_cast.f36_1)) | ||
if (!equals(this.g36_1, tmp0_other_with_cast.g36_1)) | ||
return false; | ||
if (!this.g36_1.equals(tmp0_other_with_cast.g36_1)) | ||
return false; | ||
if (!this.h36_1.equals(tmp0_other_with_cast.h36_1)) | ||
@@ -1190,2 +1188,4 @@ return false; | ||
return false; | ||
if (!this.j36_1.equals(tmp0_other_with_cast.j36_1)) | ||
return false; | ||
return true; | ||
@@ -1195,12 +1195,12 @@ }; | ||
BT2020TransferFunctions_instance = this; | ||
this.m36_1 = 1.0993; | ||
this.n36_1 = 0.0181; | ||
this.n36_1 = 1.0993; | ||
this.o36_1 = 0.0181; | ||
var tmp = this; | ||
// Inline function 'kotlin.math.pow' call | ||
tmp.o36_1 = 1.0993 * Math.pow(0.0181, 0.45) - 0.09929999999999994; | ||
tmp.p36_1 = 1.0993 * Math.pow(0.0181, 0.45) - 0.09929999999999994; | ||
} | ||
protoOf(BT2020TransferFunctions).y33 = function (x) { | ||
return numberToDouble(x < this.o36_1 ? x / 4.5 : spow_0((x + 0.09929999999999994) / 1.0993, 2.2222222222222223)); | ||
protoOf(BT2020TransferFunctions).z33 = function (x) { | ||
return numberToDouble(x < this.p36_1 ? x / 4.5 : spow_0((x + 0.09929999999999994) / 1.0993, 2.2222222222222223)); | ||
}; | ||
protoOf(BT2020TransferFunctions).z33 = function (x) { | ||
protoOf(BT2020TransferFunctions).a34 = function (x) { | ||
return x < 0.0181 ? 4.5 * x : 1.0993 * spow(x, 0.45) - 0.09929999999999994; | ||
@@ -1232,9 +1232,9 @@ }; | ||
Companion_instance_3 = this; | ||
this.p36_1 = XYZColorSpaces_getInstance().q36_1; | ||
this.q36_1 = XYZColorSpaces_getInstance().r36_1; | ||
} | ||
protoOf(Companion_3).f34 = function () { | ||
return this.p36_1.f34(); | ||
protoOf(Companion_3).g34 = function () { | ||
return this.q36_1.g34(); | ||
}; | ||
protoOf(Companion_3).q33 = function (x, y, z, alpha) { | ||
return this.p36_1.q33(x, y, z, alpha); | ||
protoOf(Companion_3).r33 = function (x, y, z, alpha) { | ||
return this.q36_1.r33(x, y, z, alpha); | ||
}; | ||
@@ -1248,9 +1248,9 @@ var Companion_instance_3; | ||
function adaptToM($this, space, m, mi) { | ||
if (space.f34().equals($this.b35_1.f34())) | ||
if (space.g34().equals($this.c35_1.g34())) | ||
return $this; | ||
var transform = chromaticAdaptationMatrix(space, $this.b35_1.f34().n32_1, m, mi); | ||
var transform = chromaticAdaptationMatrix(space, $this.c35_1.g34().o32_1, m, mi); | ||
// Inline function 'com.github.ajalt.colormath.internal.dot' call | ||
var tmp0_dot = $this.x34_1; | ||
var tmp1_dot = $this.y34_1; | ||
var tmp2_dot = $this.z34_1; | ||
var tmp0_dot = $this.y34_1; | ||
var tmp1_dot = $this.z34_1; | ||
var tmp2_dot = $this.a35_1; | ||
// Inline function 'com.github.ajalt.colormath.model.XYZ.adaptToM.<anonymous>' call | ||
@@ -1260,23 +1260,23 @@ var tmp3_anonymous = Matrix__get_impl_xogbpk(transform, 0, 0) * tmp0_dot + Matrix__get_impl_xogbpk(transform, 1, 0) * tmp1_dot + Matrix__get_impl_xogbpk(transform, 2, 0) * tmp2_dot; | ||
var tmp5_anonymous = Matrix__get_impl_xogbpk(transform, 0, 2) * tmp0_dot + Matrix__get_impl_xogbpk(transform, 1, 2) * tmp1_dot + Matrix__get_impl_xogbpk(transform, 2, 2) * tmp2_dot; | ||
return space.q33(tmp3_anonymous, tmp4_anonymous, tmp5_anonymous, $this.a35_1); | ||
return space.r33(tmp3_anonymous, tmp4_anonymous, tmp5_anonymous, $this.b35_1); | ||
} | ||
function XYZ(x, y, z, alpha, space) { | ||
Companion_getInstance_3(); | ||
this.x34_1 = x; | ||
this.y34_1 = y; | ||
this.z34_1 = z; | ||
this.a35_1 = alpha; | ||
this.b35_1 = space; | ||
this.y34_1 = x; | ||
this.z34_1 = y; | ||
this.a35_1 = z; | ||
this.b35_1 = alpha; | ||
this.c35_1 = space; | ||
} | ||
protoOf(XYZ).s36 = function (space) { | ||
protoOf(XYZ).t36 = function (space) { | ||
return adaptToM(this, space, get_CAT02_XYZ_TO_LMS(), get_CAT02_LMS_TO_XYZ()); | ||
}; | ||
protoOf(XYZ).c35 = function (space) { | ||
var tmp0_container = this.s36(XYZColorSpace(space.f34())); | ||
protoOf(XYZ).d35 = function (space) { | ||
var tmp0_container = this.t36(XYZColorSpace(space.g34())); | ||
var x = tmp0_container.gd(); | ||
var y = tmp0_container.hd(); | ||
var z = tmp0_container.ah(); | ||
var f = space.c34(); | ||
var f = space.d34(); | ||
// Inline function 'com.github.ajalt.colormath.internal.dot' call | ||
var tmp0_dot = _Matrix___init__impl__q3kp4w(space.e34()); | ||
var tmp0_dot = _Matrix___init__impl__q3kp4w(space.f34()); | ||
// Inline function 'com.github.ajalt.colormath.model.XYZ.toRGB.<anonymous>' call | ||
@@ -1286,25 +1286,25 @@ var tmp1_anonymous = Matrix__get_impl_xogbpk(tmp0_dot, 0, 0) * x + Matrix__get_impl_xogbpk(tmp0_dot, 1, 0) * y + Matrix__get_impl_xogbpk(tmp0_dot, 2, 0) * z; | ||
var tmp3_anonymous = Matrix__get_impl_xogbpk(tmp0_dot, 0, 2) * x + Matrix__get_impl_xogbpk(tmp0_dot, 1, 2) * y + Matrix__get_impl_xogbpk(tmp0_dot, 2, 2) * z; | ||
return space.q33(f.z33(tmp1_anonymous), f.z33(tmp2_anonymous), f.z33(tmp3_anonymous), this.a35_1); | ||
return space.r33(f.a34(tmp1_anonymous), f.a34(tmp2_anonymous), f.a34(tmp3_anonymous), this.b35_1); | ||
}; | ||
protoOf(XYZ).y32 = function () { | ||
return this.c35(RGBColorSpaces_getInstance().g34_1); | ||
protoOf(XYZ).z32 = function () { | ||
return this.d35(RGBColorSpaces_getInstance().h34_1); | ||
}; | ||
protoOf(XYZ).gd = function () { | ||
return this.x34_1; | ||
return this.y34_1; | ||
}; | ||
protoOf(XYZ).hd = function () { | ||
return this.y34_1; | ||
return this.z34_1; | ||
}; | ||
protoOf(XYZ).ah = function () { | ||
return this.z34_1; | ||
return this.a35_1; | ||
}; | ||
protoOf(XYZ).toString = function () { | ||
return 'XYZ(x=' + this.x34_1 + ', y=' + this.y34_1 + ', z=' + this.z34_1 + ', alpha=' + this.a35_1 + ', space=' + this.b35_1 + ')'; | ||
return 'XYZ(x=' + this.y34_1 + ', y=' + this.z34_1 + ', z=' + this.a35_1 + ', alpha=' + this.b35_1 + ', space=' + this.c35_1 + ')'; | ||
}; | ||
protoOf(XYZ).hashCode = function () { | ||
var result = getNumberHashCode(this.x34_1); | ||
result = imul(result, 31) + getNumberHashCode(this.y34_1) | 0; | ||
var result = getNumberHashCode(this.y34_1); | ||
result = imul(result, 31) + getNumberHashCode(this.z34_1) | 0; | ||
result = imul(result, 31) + getNumberHashCode(this.a35_1) | 0; | ||
result = imul(result, 31) + hashCode(this.b35_1) | 0; | ||
result = imul(result, 31) + getNumberHashCode(this.b35_1) | 0; | ||
result = imul(result, 31) + hashCode(this.c35_1) | 0; | ||
return result; | ||
@@ -1318,4 +1318,2 @@ }; | ||
var tmp0_other_with_cast = other instanceof XYZ ? other : THROW_CCE(); | ||
if (!equals(this.x34_1, tmp0_other_with_cast.x34_1)) | ||
return false; | ||
if (!equals(this.y34_1, tmp0_other_with_cast.y34_1)) | ||
@@ -1329,11 +1327,13 @@ return false; | ||
return false; | ||
if (!equals(this.c35_1, tmp0_other_with_cast.c35_1)) | ||
return false; | ||
return true; | ||
}; | ||
function XYZColorSpace(whitePoint) { | ||
return whitePoint.equals(Illuminant_getInstance().t32_1) ? XYZColorSpaces_getInstance().q36_1 : whitePoint.equals(Illuminant_getInstance().r32_1) ? XYZColorSpaces_getInstance().r36_1 : new XYZColorSpaceImpl(whitePoint); | ||
return whitePoint.equals(Illuminant_getInstance().u32_1) ? XYZColorSpaces_getInstance().r36_1 : whitePoint.equals(Illuminant_getInstance().s32_1) ? XYZColorSpaces_getInstance().s36_1 : new XYZColorSpaceImpl(whitePoint); | ||
} | ||
function XYZColorSpaces() { | ||
XYZColorSpaces_instance = this; | ||
this.q36_1 = new XYZColorSpaceImpl(Illuminant_getInstance().t32_1); | ||
this.r36_1 = new XYZColorSpaceImpl(Illuminant_getInstance().r32_1); | ||
this.r36_1 = new XYZColorSpaceImpl(Illuminant_getInstance().u32_1); | ||
this.s36_1 = new XYZColorSpaceImpl(Illuminant_getInstance().s32_1); | ||
} | ||
@@ -1349,22 +1349,22 @@ var XYZColorSpaces_instance; | ||
lmsToXyz = lmsToXyz === VOID ? get_CAT02_LMS_TO_XYZ() : lmsToXyz; | ||
var dstWp = _this__u8e3s4.f34().n32_1; | ||
var src = dot_0(xyzToLms, srcWp.b36(), srcWp.z35_1, srcWp.c36()); | ||
var dst = dot_0(xyzToLms, dstWp.b36(), dstWp.z35_1, dstWp.c36()); | ||
var dstWp = _this__u8e3s4.g34().o32_1; | ||
var src = dot_0(xyzToLms, srcWp.c36(), srcWp.a36_1, srcWp.d36()); | ||
var dst = dot_0(xyzToLms, dstWp.c36(), dstWp.a36_1, dstWp.d36()); | ||
return dot(dotDiagonal(lmsToXyz, _Vector___get_l__impl__envr1l(dst) / _Vector___get_l__impl__envr1l(src), _Vector___get_m__impl__e5qq0m(dst) / _Vector___get_m__impl__e5qq0m(src), _Vector___get_s__impl__pzuljk(dst) / _Vector___get_s__impl__pzuljk(src)), xyzToLms); | ||
} | ||
function XYZColorSpaceImpl(whitePoint) { | ||
this.t36_1 = whitePoint; | ||
this.u36_1 = rectangularComponentInfo('XYZ'); | ||
this.u36_1 = whitePoint; | ||
this.v36_1 = rectangularComponentInfo('XYZ'); | ||
} | ||
protoOf(XYZColorSpaceImpl).f34 = function () { | ||
return this.t36_1; | ||
protoOf(XYZColorSpaceImpl).g34 = function () { | ||
return this.u36_1; | ||
}; | ||
protoOf(XYZColorSpaceImpl).toString = function () { | ||
return 'XYZColorSpace(' + this.t36_1 + ')'; | ||
return 'XYZColorSpace(' + this.u36_1 + ')'; | ||
}; | ||
protoOf(XYZColorSpaceImpl).q33 = function (x, y, z, alpha) { | ||
protoOf(XYZColorSpaceImpl).r33 = function (x, y, z, alpha) { | ||
return new XYZ(x, y, z, alpha, this); | ||
}; | ||
protoOf(XYZColorSpaceImpl).hashCode = function () { | ||
return this.t36_1.hashCode(); | ||
return this.u36_1.hashCode(); | ||
}; | ||
@@ -1377,3 +1377,3 @@ protoOf(XYZColorSpaceImpl).equals = function (other) { | ||
var tmp0_other_with_cast = other instanceof XYZColorSpaceImpl ? other : THROW_CCE(); | ||
if (!this.t36_1.equals(tmp0_other_with_cast.t36_1)) | ||
if (!this.u36_1.equals(tmp0_other_with_cast.u36_1)) | ||
return false; | ||
@@ -1392,22 +1392,22 @@ return true; | ||
Y = Y === VOID ? 1.0 : Y; | ||
this.x35_1 = x; | ||
this.y35_1 = y; | ||
this.z35_1 = Y; | ||
this.y35_1 = x; | ||
this.z35_1 = y; | ||
this.a36_1 = Y; | ||
} | ||
protoOf(xyY).a36 = function () { | ||
return 1 - this.x35_1 - this.y35_1; | ||
}; | ||
protoOf(xyY).b36 = function () { | ||
return this.x35_1 * this.z35_1 / this.y35_1; | ||
return 1 - this.y35_1 - this.z35_1; | ||
}; | ||
protoOf(xyY).c36 = function () { | ||
return (1 - this.x35_1 - this.y35_1) * this.z35_1 / this.y35_1; | ||
return this.y35_1 * this.a36_1 / this.z35_1; | ||
}; | ||
protoOf(xyY).d36 = function () { | ||
return (1 - this.y35_1 - this.z35_1) * this.a36_1 / this.z35_1; | ||
}; | ||
protoOf(xyY).toString = function () { | ||
return 'xyY(x=' + this.x35_1 + ', y=' + this.y35_1 + ', Y=' + this.z35_1 + ')'; | ||
return 'xyY(x=' + this.y35_1 + ', y=' + this.z35_1 + ', Y=' + this.a36_1 + ')'; | ||
}; | ||
protoOf(xyY).hashCode = function () { | ||
var result = getNumberHashCode(this.x35_1); | ||
result = imul(result, 31) + getNumberHashCode(this.y35_1) | 0; | ||
var result = getNumberHashCode(this.y35_1); | ||
result = imul(result, 31) + getNumberHashCode(this.z35_1) | 0; | ||
result = imul(result, 31) + getNumberHashCode(this.a36_1) | 0; | ||
return result; | ||
@@ -1421,4 +1421,2 @@ }; | ||
var tmp0_other_with_cast = other instanceof xyY ? other : THROW_CCE(); | ||
if (!equals(this.x35_1, tmp0_other_with_cast.x35_1)) | ||
return false; | ||
if (!equals(this.y35_1, tmp0_other_with_cast.y35_1)) | ||
@@ -1428,26 +1426,28 @@ return false; | ||
return false; | ||
if (!equals(this.a36_1, tmp0_other_with_cast.a36_1)) | ||
return false; | ||
return true; | ||
}; | ||
//region block: post-declaration | ||
protoOf(Companion_2).a33 = from255$default; | ||
protoOf(Companion_2).z32 = invoke$default; | ||
protoOf(Companion_2).e33 = invoke$default_0; | ||
protoOf(SRGB).z32 = invoke$default; | ||
protoOf(SRGB).a34 = invoke; | ||
protoOf(SRGB).e33 = invoke$default_0; | ||
protoOf(Companion_2).b33 = from255$default; | ||
protoOf(Companion_2).a33 = invoke$default; | ||
protoOf(Companion_2).f33 = invoke$default_0; | ||
protoOf(SRGB).a33 = invoke$default; | ||
protoOf(SRGB).b34 = invoke; | ||
protoOf(SRGB).f33 = invoke$default_0; | ||
protoOf(SRGB).j28 = invoke_0; | ||
protoOf(SRGB).b34 = from255; | ||
protoOf(SRGB).a33 = from255$default; | ||
protoOf(BT2020Space).z32 = invoke$default; | ||
protoOf(BT2020Space).a34 = invoke; | ||
protoOf(BT2020Space).e33 = invoke$default_0; | ||
protoOf(SRGB).c34 = from255; | ||
protoOf(SRGB).b33 = from255$default; | ||
protoOf(BT2020Space).a33 = invoke$default; | ||
protoOf(BT2020Space).b34 = invoke; | ||
protoOf(BT2020Space).f33 = invoke$default_0; | ||
protoOf(BT2020Space).j28 = invoke_0; | ||
protoOf(BT2020Space).b34 = from255; | ||
protoOf(BT2020Space).a33 = from255$default; | ||
protoOf(RGBColorSpaceImpl).z32 = invoke$default; | ||
protoOf(RGBColorSpaceImpl).a34 = invoke; | ||
protoOf(RGBColorSpaceImpl).e33 = invoke$default_0; | ||
protoOf(BT2020Space).c34 = from255; | ||
protoOf(BT2020Space).b33 = from255$default; | ||
protoOf(RGBColorSpaceImpl).a33 = invoke$default; | ||
protoOf(RGBColorSpaceImpl).b34 = invoke; | ||
protoOf(RGBColorSpaceImpl).f33 = invoke$default_0; | ||
protoOf(RGBColorSpaceImpl).j28 = invoke_0; | ||
protoOf(RGBColorSpaceImpl).b34 = from255; | ||
protoOf(RGBColorSpaceImpl).a33 = from255$default; | ||
protoOf(RGBColorSpaceImpl).c34 = from255; | ||
protoOf(RGBColorSpaceImpl).b33 = from255$default; | ||
//endregion | ||
@@ -1454,0 +1454,0 @@ //region block: exports |
{ | ||
"name": "@flock/wirespec", | ||
"version": "0.9.9", | ||
"version": "0.9.10", | ||
"main": "wirespec-src-plugin-npm.js", | ||
@@ -5,0 +5,0 @@ "types": "wirespec-src-plugin-npm.d.ts", |
@@ -133,3 +133,3 @@ (function (root, factory) { | ||
var tmp0_let = Companion_getInstance().e46('\\w{1,50}').n46(random); | ||
var tmp0_let = Companion_getInstance().f46('\\w{1,50}').o46(random); | ||
// Inline function 'kotlin.contracts.contract' call | ||
@@ -234,4 +234,4 @@ | ||
tmp$ret$1 = regex.substring(1, tmp0_substring); | ||
var rgxgen = tmp.e46(tmp$ret$1); | ||
return rgxgen.n46(random); | ||
var rgxgen = tmp.f46(tmp$ret$1); | ||
return rgxgen.o46(random); | ||
} | ||
@@ -255,3 +255,3 @@ function generateRefined($this, def, random) { | ||
var type = toList(def.o28_1).g1(index); | ||
return $this.g5i(_this__u8e3s4, type, random); | ||
return $this.h5i(_this__u8e3s4, type, random); | ||
} | ||
@@ -286,11 +286,11 @@ function generateObject(_this__u8e3s4, $this, def, random) { | ||
} | ||
protoOf(Generator).h5i = function (_this__u8e3s4, type, random) { | ||
protoOf(Generator).i5i = function (_this__u8e3s4, type, random) { | ||
var ref = new Custom(removeSuffix(type, '[]'), endsWith(type, '[]'), false); | ||
return this.g5i(_this__u8e3s4, ref, random); | ||
return this.h5i(_this__u8e3s4, ref, random); | ||
}; | ||
protoOf(Generator).i5i = function (_this__u8e3s4, type, random, $super) { | ||
protoOf(Generator).j5i = function (_this__u8e3s4, type, random, $super) { | ||
random = random === VOID ? Default_getInstance() : random; | ||
return $super === VOID ? this.h5i(_this__u8e3s4, type, random) : $super.h5i.call(this, _this__u8e3s4, type, random); | ||
return $super === VOID ? this.i5i(_this__u8e3s4, type, random) : $super.i5i.call(this, _this__u8e3s4, type, random); | ||
}; | ||
protoOf(Generator).g5i = function (_this__u8e3s4, type, random) { | ||
protoOf(Generator).h5i = function (_this__u8e3s4, type, random) { | ||
var def = resolveReference(_this__u8e3s4, this, type); | ||
@@ -297,0 +297,0 @@ var tmp; |
@@ -160,3 +160,3 @@ (function (root, factory) { | ||
var l = function (p0) { | ||
$boundThis.k3q(p0); | ||
$boundThis.l3q(p0); | ||
return Unit_getInstance(); | ||
@@ -170,3 +170,3 @@ }; | ||
} | ||
protoOf(Companion).k42 = function (compile, convert) { | ||
protoOf(Companion).l42 = function (compile, convert) { | ||
return WirespecCli$main$ref(subcommands(new WirespecCli(), [new Compile_0(compile), new Convert_0(convert)])); | ||
@@ -185,24 +185,24 @@ }; | ||
function _get_languages__ojonze($this) { | ||
return $this.k43_1.m3z($this, languages$factory_0()); | ||
return $this.l43_1.n3z($this, languages$factory_0()); | ||
} | ||
function Compile_0(block) { | ||
CommonOptions.call(this); | ||
this.j43_1 = block; | ||
this.k43_1 = multiple(choice(option(this, Options_Language_getInstance().n43_1.slice(), 'Language'), Companion_getInstance().n2b()), VOID, true).o40(this, languages$factory()); | ||
this.k43_1 = block; | ||
this.l43_1 = multiple(choice(option(this, Options_Language_getInstance().o43_1.slice(), 'Language'), Companion_getInstance().n2b()), VOID, true).p40(this, languages$factory()); | ||
} | ||
protoOf(Compile_0).l3q = function () { | ||
protoOf(Compile_0).m3q = function () { | ||
// Inline function 'kotlin.let' call | ||
var tmp0_let = new CompilerArguments(Compile_getInstance(), this.n44(this.m44()), Companion_getInstance_0().o2b(this.o44()), toSet(_get_languages__ojonze(this)), _PackageName___init__impl__s13tbs(this.p44()), this.q44(), this.r44(), this.s44()); | ||
var tmp0_let = new CompilerArguments(Compile_getInstance(), this.o44(this.n44()), Companion_getInstance_0().o2b(this.p44()), toSet(_get_languages__ojonze(this)), _PackageName___init__impl__s13tbs(this.q44()), this.r44(), this.s44(), this.t44()); | ||
// Inline function 'kotlin.contracts.contract' call | ||
this.j43_1(tmp0_let); | ||
this.k43_1(tmp0_let); | ||
}; | ||
function _get_format__qlarck($this) { | ||
return $this.s45_1.m3z($this, format$factory_0()); | ||
return $this.t45_1.n3z($this, format$factory_0()); | ||
} | ||
function _get_languages__ojonze_0($this) { | ||
return $this.t45_1.m3z($this, languages$factory_2()); | ||
return $this.u45_1.n3z($this, languages$factory_2()); | ||
} | ||
function Convert_0(block) { | ||
CommonOptions.call(this); | ||
this.r45_1 = block; | ||
this.s45_1 = block; | ||
var tmp = this; | ||
@@ -228,7 +228,7 @@ // Inline function 'com.github.ajalt.clikt.parameters.types.enum' call | ||
} | ||
tmp.s45_1 = choice_0(tmp0_enum, tmp0_associateByTo, true).s3y(this, format$factory()); | ||
this.t45_1 = multiple(choice(option(this, Options_Language_getInstance().n43_1.slice(), 'Language'), Companion_getInstance().n2b(), VOID, true), listOf(Language_Wirespec_getInstance())).o40(this, languages$factory_1()); | ||
tmp.t45_1 = choice_0(tmp0_enum, tmp0_associateByTo, true).t3y(this, format$factory()); | ||
this.u45_1 = multiple(choice(option(this, Options_Language_getInstance().o43_1.slice(), 'Language'), Companion_getInstance().n2b(), VOID, true), listOf(Language_Wirespec_getInstance())).p40(this, languages$factory_1()); | ||
} | ||
protoOf(Convert_0).l3q = function () { | ||
if (this.m44() == null) | ||
protoOf(Convert_0).m3q = function () { | ||
if (this.n44() == null) | ||
null; | ||
@@ -238,8 +238,8 @@ else { | ||
// Inline function 'kotlin.contracts.contract' call | ||
this.e3q('To convert, please specify a file', VOID, true); | ||
this.f3q('To convert, please specify a file', VOID, true); | ||
} | ||
// Inline function 'kotlin.let' call | ||
var tmp = new Convert(_get_format__qlarck(this)); | ||
var tmp_0 = this.n44(null); | ||
var tmp_1 = Companion_getInstance_0().o2b(this.o44()); | ||
var tmp_0 = this.o44(null); | ||
var tmp_1 = Companion_getInstance_0().o2b(this.p44()); | ||
var tmp$ret$2; | ||
@@ -256,38 +256,38 @@ // Inline function 'kotlin.collections.ifEmpty' call | ||
tmp$ret$2 = tmp_2; | ||
var tmp1_let = new CompilerArguments(tmp, tmp_0, tmp_1, tmp$ret$2, _PackageName___init__impl__s13tbs(this.p44()), this.q44(), this.r44(), this.s44()); | ||
var tmp1_let = new CompilerArguments(tmp, tmp_0, tmp_1, tmp$ret$2, _PackageName___init__impl__s13tbs(this.q44()), this.r44(), this.s44(), this.t44()); | ||
// Inline function 'kotlin.contracts.contract' call | ||
this.r45_1(tmp1_let); | ||
this.s45_1(tmp1_let); | ||
}; | ||
function _get_inputFile__x1bqj($this) { | ||
return $this.f44_1.m3z($this, inputFile$factory_0()); | ||
return $this.g44_1.n3z($this, inputFile$factory_0()); | ||
} | ||
function CommonOptions() { | ||
CliktCommand.call(this); | ||
this.f44_1 = option(this, Options_InputFile_getInstance().n43_1.slice(), 'Input file').o40(this, inputFile$factory()); | ||
this.g44_1 = option(this, Options_InputDir_getInstance().n43_1.slice(), 'Input directory').o40(this, inputDir$factory()); | ||
this.h44_1 = option(this, Options_OutputDir_getInstance().n43_1.slice(), 'Output directory').o40(this, outputDir$factory()); | ||
this.i44_1 = default_0(option(this, Options_PackageName_getInstance().n43_1.slice(), 'Package name'), get_DEFAULT_PACKAGE_STRING()).o40(this, packageName$factory()); | ||
this.j44_1 = flag(option(this, Options_Shared_getInstance().n43_1.slice(), 'Generate shared wirespec code'), [], false).o40(this, shared$factory()); | ||
this.k44_1 = flag(option(this, Options_Strict_getInstance().n43_1.slice(), 'Strict mode'), []).o40(this, strict$factory()); | ||
this.l44_1 = flag(option(this, Options_Debug_getInstance().n43_1.slice(), 'Debug mode'), []).o40(this, debug$factory()); | ||
this.g44_1 = option(this, Options_InputFile_getInstance().o43_1.slice(), 'Input file').p40(this, inputFile$factory()); | ||
this.h44_1 = option(this, Options_InputDir_getInstance().o43_1.slice(), 'Input directory').p40(this, inputDir$factory()); | ||
this.i44_1 = option(this, Options_OutputDir_getInstance().o43_1.slice(), 'Output directory').p40(this, outputDir$factory()); | ||
this.j44_1 = default_0(option(this, Options_PackageName_getInstance().o43_1.slice(), 'Package name'), get_DEFAULT_PACKAGE_STRING()).p40(this, packageName$factory()); | ||
this.k44_1 = flag(option(this, Options_Shared_getInstance().o43_1.slice(), 'Generate shared wirespec code'), [], false).p40(this, shared$factory()); | ||
this.l44_1 = flag(option(this, Options_Strict_getInstance().o43_1.slice(), 'Strict mode'), []).p40(this, strict$factory()); | ||
this.m44_1 = flag(option(this, Options_Debug_getInstance().o43_1.slice(), 'Debug mode'), []).p40(this, debug$factory()); | ||
} | ||
protoOf(CommonOptions).m44 = function () { | ||
return this.g44_1.m3z(this, inputDir$factory_0()); | ||
protoOf(CommonOptions).n44 = function () { | ||
return this.h44_1.n3z(this, inputDir$factory_0()); | ||
}; | ||
protoOf(CommonOptions).o44 = function () { | ||
return this.h44_1.m3z(this, outputDir$factory_0()); | ||
}; | ||
protoOf(CommonOptions).p44 = function () { | ||
return this.i44_1.m3z(this, packageName$factory_0()); | ||
return this.i44_1.n3z(this, outputDir$factory_0()); | ||
}; | ||
protoOf(CommonOptions).q44 = function () { | ||
return this.j44_1.m3z(this, shared$factory_0()); | ||
return this.j44_1.n3z(this, packageName$factory_0()); | ||
}; | ||
protoOf(CommonOptions).r44 = function () { | ||
return this.k44_1.m3z(this, strict$factory_0()); | ||
return this.k44_1.n3z(this, shared$factory_0()); | ||
}; | ||
protoOf(CommonOptions).s44 = function () { | ||
return this.l44_1.m3z(this, debug$factory_0()); | ||
return this.l44_1.n3z(this, strict$factory_0()); | ||
}; | ||
protoOf(CommonOptions).n44 = function (inputDir) { | ||
protoOf(CommonOptions).t44 = function () { | ||
return this.m44_1.n3z(this, debug$factory_0()); | ||
}; | ||
protoOf(CommonOptions).o44 = function (inputDir) { | ||
var tmp; | ||
@@ -350,3 +350,3 @@ if (!(inputDir == null) ? !(_get_inputFile__x1bqj(this) == null) : false) { | ||
Enum.call(this, name, ordinal); | ||
this.n43_1 = flags; | ||
this.o43_1 = flags; | ||
} | ||
@@ -422,3 +422,3 @@ function Options_InputDir_getInstance() { | ||
return getPropertyCallableRef('inputDir', 1, KProperty1, function (receiver) { | ||
return receiver.m44(); | ||
return receiver.n44(); | ||
}, null); | ||
@@ -428,3 +428,3 @@ } | ||
return getPropertyCallableRef('outputDir', 1, KProperty1, function (receiver) { | ||
return receiver.o44(); | ||
return receiver.p44(); | ||
}, null); | ||
@@ -434,3 +434,3 @@ } | ||
return getPropertyCallableRef('packageName', 1, KProperty1, function (receiver) { | ||
return receiver.p44(); | ||
return receiver.q44(); | ||
}, null); | ||
@@ -440,3 +440,3 @@ } | ||
return getPropertyCallableRef('shared', 1, KProperty1, function (receiver) { | ||
return receiver.q44(); | ||
return receiver.r44(); | ||
}, null); | ||
@@ -446,3 +446,3 @@ } | ||
return getPropertyCallableRef('strict', 1, KProperty1, function (receiver) { | ||
return receiver.r44(); | ||
return receiver.s44(); | ||
}, null); | ||
@@ -452,3 +452,3 @@ } | ||
return getPropertyCallableRef('debug', 1, KProperty1, function (receiver) { | ||
return receiver.s44(); | ||
return receiver.t44(); | ||
}, null); | ||
@@ -463,3 +463,3 @@ } | ||
return getPropertyCallableRef('inputDir', 1, KProperty1, function (receiver) { | ||
return receiver.m44(); | ||
return receiver.n44(); | ||
}, null); | ||
@@ -469,3 +469,3 @@ } | ||
return getPropertyCallableRef('outputDir', 1, KProperty1, function (receiver) { | ||
return receiver.o44(); | ||
return receiver.p44(); | ||
}, null); | ||
@@ -475,3 +475,3 @@ } | ||
return getPropertyCallableRef('packageName', 1, KProperty1, function (receiver) { | ||
return receiver.p44(); | ||
return receiver.q44(); | ||
}, null); | ||
@@ -481,3 +481,3 @@ } | ||
return getPropertyCallableRef('shared', 1, KProperty1, function (receiver) { | ||
return receiver.q44(); | ||
return receiver.r44(); | ||
}, null); | ||
@@ -487,3 +487,3 @@ } | ||
return getPropertyCallableRef('strict', 1, KProperty1, function (receiver) { | ||
return receiver.r44(); | ||
return receiver.s44(); | ||
}, null); | ||
@@ -493,3 +493,3 @@ } | ||
return getPropertyCallableRef('debug', 1, KProperty1, function (receiver) { | ||
return receiver.s44(); | ||
return receiver.t44(); | ||
}, null); | ||
@@ -526,3 +526,3 @@ } | ||
// Inline function 'kotlin.contracts.contract' call | ||
tmp.k42(tmp_0, convert$ref())(tmp2_let); | ||
tmp.l42(tmp_0, convert$ref())(tmp2_let); | ||
} | ||
@@ -614,7 +614,7 @@ function compile_0(arguments_0) { | ||
// Inline function 'kotlin.collections.forEach' call | ||
var tmp0_iterator_1 = (new Directory(input.m2b_1)).w45().v(); | ||
var tmp0_iterator_1 = (new Directory(input.m2b_1)).x45().v(); | ||
while (tmp0_iterator_1.w()) { | ||
var element = tmp0_iterator_1.y(); | ||
// Inline function 'community.flock.wirespec.plugin.cli.compile.<anonymous>' call | ||
wirespec(element, languages, packageName, out(element.u45_1, packageName, output), logger); | ||
wirespec(element, languages, packageName, out(element.v45_1, packageName, output), logger); | ||
} | ||
@@ -627,3 +627,3 @@ } else { | ||
// Inline function 'kotlin.contracts.contract' call | ||
wirespec(tmp3_let, languages, packageName, out(tmp3_let.u45_1, packageName, output), logger); | ||
wirespec(tmp3_let, languages, packageName, out(tmp3_let.v45_1, packageName, output), logger); | ||
} else { | ||
@@ -653,3 +653,3 @@ // Inline function 'kotlin.error' call | ||
var result = element.hd(); | ||
var tmp1_safe_receiver = file == null ? null : file.x45(_FileName___init__impl__nzn12e(name)); | ||
var tmp1_safe_receiver = file == null ? null : file.y45(_FileName___init__impl__nzn12e(name)); | ||
var tmp; | ||
@@ -874,4 +874,4 @@ if (tmp1_safe_receiver == null) { | ||
} | ||
protoOf(JavaFile).x45 = function (fileName) { | ||
return new JavaFile(this.u45_1.k2b(VOID, fileName)); | ||
protoOf(JavaFile).y45 = function (fileName) { | ||
return new JavaFile(this.v45_1.k2b(VOID, fileName)); | ||
}; | ||
@@ -881,4 +881,4 @@ function JsonFile(path) { | ||
} | ||
protoOf(JsonFile).x45 = function (fileName) { | ||
return new JsonFile(this.u45_1.k2b(VOID, fileName)); | ||
protoOf(JsonFile).y45 = function (fileName) { | ||
return new JsonFile(this.v45_1.k2b(VOID, fileName)); | ||
}; | ||
@@ -888,4 +888,4 @@ function KotlinFile(path) { | ||
} | ||
protoOf(KotlinFile).x45 = function (fileName) { | ||
return new KotlinFile(this.u45_1.k2b(VOID, fileName)); | ||
protoOf(KotlinFile).y45 = function (fileName) { | ||
return new KotlinFile(this.v45_1.k2b(VOID, fileName)); | ||
}; | ||
@@ -895,4 +895,4 @@ function ScalaFile(path) { | ||
} | ||
protoOf(ScalaFile).x45 = function (fileName) { | ||
return new ScalaFile(this.u45_1.k2b(VOID, fileName)); | ||
protoOf(ScalaFile).y45 = function (fileName) { | ||
return new ScalaFile(this.v45_1.k2b(VOID, fileName)); | ||
}; | ||
@@ -902,4 +902,4 @@ function TypeScriptFile(path) { | ||
} | ||
protoOf(TypeScriptFile).x45 = function (fileName) { | ||
return new TypeScriptFile(this.u45_1.k2b(VOID, fileName)); | ||
protoOf(TypeScriptFile).y45 = function (fileName) { | ||
return new TypeScriptFile(this.v45_1.k2b(VOID, fileName)); | ||
}; | ||
@@ -909,4 +909,4 @@ function WirespecFile(path) { | ||
} | ||
protoOf(WirespecFile).x45 = function (fileName) { | ||
return new WirespecFile(this.u45_1.k2b(VOID, fileName)); | ||
protoOf(WirespecFile).y45 = function (fileName) { | ||
return new WirespecFile(this.v45_1.k2b(VOID, fileName)); | ||
}; | ||
@@ -981,3 +981,3 @@ function cli(args) { | ||
return function (it) { | ||
return new FullFilePath(this$0.v45_1, _FileName___init__impl__nzn12e(it)); | ||
return new FullFilePath(this$0.w45_1, _FileName___init__impl__nzn12e(it)); | ||
}; | ||
@@ -993,6 +993,6 @@ } | ||
function Directory(path) { | ||
this.v45_1 = path; | ||
this.w45_1 = path; | ||
} | ||
protoOf(Directory).w45 = function () { | ||
var tmp = asSequence(iterator(get_fs().readdirSync(this.v45_1, 'utf-8'))); | ||
protoOf(Directory).x45 = function () { | ||
var tmp = asSequence(iterator(get_fs().readdirSync(this.w45_1, 'utf-8'))); | ||
var tmp_0 = map(tmp, Directory$wirespecFiles$lambda); | ||
@@ -1005,11 +1005,11 @@ var tmp_1 = filter(tmp_0, Directory$wirespecFiles$lambda_0); | ||
function File(path) { | ||
this.u45_1 = path; | ||
this.v45_1 = path; | ||
} | ||
protoOf(File).x17 = function () { | ||
// Inline function 'kotlin.js.unsafeCast' call | ||
return get_fs().readFileSync(this.u45_1.toString(), 'utf-8'); | ||
return get_fs().readFileSync(this.v45_1.toString(), 'utf-8'); | ||
}; | ||
protoOf(File).w15 = function (text) { | ||
// Inline function 'kotlin.run' call | ||
var tmp0_run = this.u45_1.k2b(joinToString(split_0(this.u45_1.g2b_1, ['out']), 'out/node')); | ||
var tmp0_run = this.v45_1.k2b(joinToString(split_0(this.v45_1.g2b_1, ['out']), 'out/node')); | ||
// Inline function 'kotlin.contracts.contract' call | ||
@@ -1016,0 +1016,0 @@ // Inline function 'community.flock.wirespec.plugin.cli.io.File.write.<anonymous>' call |
@@ -150,3 +150,3 @@ (function (root, factory) { | ||
// Inline function 'community.flock.wirespec.plugin.npm.generate.<anonymous>' call | ||
tmp$ret$2 = toString(Generator_getInstance().i5i(tmp0_anonymous, type)); | ||
tmp$ret$2 = toString(Generator_getInstance().j5i(tmp0_anonymous, type)); | ||
tmp = new Right(tmp$ret$2); | ||
@@ -153,0 +153,0 @@ } else { |
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is too big to display
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
Sorry, the diff of this file is not supported yet
5725883
89261