@cruglobal/godtools-shared 1.3.2-SNAPSHOT.2206 → 1.3.2-SNAPSHOT.2210
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Kermit-kermit-core.js +49 -49
- package/Kermit-kermit-core.js.map +1 -1
- package/Kermit-kermit.js +8 -8
- package/antlr-kotlin-antlr-kotlin-runtime.js +3114 -3114
- package/antlr-kotlin-antlr-kotlin-runtime.js.map +1 -1
- package/colormath-root-colormath.js +617 -617
- package/colormath-root-colormath.js.map +1 -1
- package/fluid-locale.js +153 -153
- package/fluid-locale.js.map +1 -1
- package/kotlin-kotlin-stdlib.js +2100 -2062
- package/kotlin-kotlin-stdlib.js.map +1 -1
- package/kotlin-mpp-godtools-tool-parser-module-common.js +3 -3
- package/kotlin-mpp-godtools-tool-parser-module-common.js.map +1 -1
- package/kotlin-mpp-godtools-tool-parser-module-parser-base.js +54 -54
- package/kotlin-mpp-godtools-tool-parser-module-parser-expressions.js +603 -605
- package/kotlin-mpp-godtools-tool-parser-module-parser-expressions.js.map +1 -1
- package/kotlin-mpp-godtools-tool-parser-module-parser.js +2773 -2773
- package/kotlin-mpp-godtools-tool-parser-module-parser.js.map +1 -1
- package/kotlin-mpp-godtools-tool-parser-module-renderer-state.js +473 -477
- package/kotlin-mpp-godtools-tool-parser-module-renderer-state.js.map +1 -1
- package/kotlin-mpp-godtools-tool-parser-publishing-npm.d.ts +405 -317
- package/kotlinx-atomicfu.js +21 -21
- package/kotlinx-coroutines-core.js +2836 -2843
- package/kotlinx-coroutines-core.js.map +1 -1
- package/package.json +1 -1
|
@@ -14,72 +14,72 @@
|
|
|
14
14
|
//region block: imports
|
|
15
15
|
var imul = Math.imul;
|
|
16
16
|
var log2 = Math.log2;
|
|
17
|
-
var protoOf = kotlin_kotlin.$_$.
|
|
18
|
-
var initMetadataForInterface = kotlin_kotlin.$_$.
|
|
19
|
-
var toString = kotlin_kotlin.$_$.
|
|
17
|
+
var protoOf = kotlin_kotlin.$_$.k7;
|
|
18
|
+
var initMetadataForInterface = kotlin_kotlin.$_$.y6;
|
|
19
|
+
var toString = kotlin_kotlin.$_$.m7;
|
|
20
20
|
var IllegalArgumentException_init_$Create$ = kotlin_kotlin.$_$.a1;
|
|
21
21
|
var Unit_instance = kotlin_kotlin.$_$.l2;
|
|
22
|
-
var initMetadataForClass = kotlin_kotlin.$_$.
|
|
23
|
-
var Enum = kotlin_kotlin.$_$.
|
|
22
|
+
var initMetadataForClass = kotlin_kotlin.$_$.v6;
|
|
23
|
+
var Enum = kotlin_kotlin.$_$.k9;
|
|
24
24
|
var VOID = kotlin_kotlin.$_$.b;
|
|
25
25
|
var emptyMap = kotlin_kotlin.$_$.n3;
|
|
26
|
-
var equals = kotlin_kotlin.$_$.
|
|
26
|
+
var equals = kotlin_kotlin.$_$.o6;
|
|
27
27
|
var StringBuilder_init_$Create$ = kotlin_kotlin.$_$.t;
|
|
28
28
|
var dropLast = kotlin_kotlin.$_$.l3;
|
|
29
29
|
var joinTo = kotlin_kotlin.$_$.a4;
|
|
30
30
|
var Regex_init_$Create$ = kotlin_kotlin.$_$.q;
|
|
31
31
|
var UByte__toString_impl_v72jg = kotlin_kotlin.$_$.d2;
|
|
32
|
-
var numberToInt = kotlin_kotlin.$_$.
|
|
33
|
-
var roundToInt = kotlin_kotlin.$_$.
|
|
32
|
+
var numberToInt = kotlin_kotlin.$_$.i7;
|
|
33
|
+
var roundToInt = kotlin_kotlin.$_$.n7;
|
|
34
34
|
var _Char___init__impl__6a9atx = kotlin_kotlin.$_$.t1;
|
|
35
|
-
var padStart = kotlin_kotlin.$_$.
|
|
36
|
-
var charArrayOf = kotlin_kotlin.$_$.
|
|
37
|
-
var trimEnd = kotlin_kotlin.$_$.
|
|
38
|
-
var isNaN_0 = kotlin_kotlin.$_$.
|
|
35
|
+
var padStart = kotlin_kotlin.$_$.o8;
|
|
36
|
+
var charArrayOf = kotlin_kotlin.$_$.i6;
|
|
37
|
+
var trimEnd = kotlin_kotlin.$_$.f9;
|
|
38
|
+
var isNaN_0 = kotlin_kotlin.$_$.ca;
|
|
39
39
|
var joinTo_0 = kotlin_kotlin.$_$.z3;
|
|
40
|
-
var noWhenBranchMatchedException = kotlin_kotlin.$_$.
|
|
41
|
-
var numberToDouble = kotlin_kotlin.$_$.
|
|
42
|
-
var getStringHashCode = kotlin_kotlin.$_$.
|
|
43
|
-
var THROW_CCE = kotlin_kotlin.$_$.
|
|
44
|
-
var initMetadataForObject = kotlin_kotlin.$_$.
|
|
40
|
+
var noWhenBranchMatchedException = kotlin_kotlin.$_$.ea;
|
|
41
|
+
var numberToDouble = kotlin_kotlin.$_$.h7;
|
|
42
|
+
var getStringHashCode = kotlin_kotlin.$_$.t6;
|
|
43
|
+
var THROW_CCE = kotlin_kotlin.$_$.u9;
|
|
44
|
+
var initMetadataForObject = kotlin_kotlin.$_$.a7;
|
|
45
45
|
var arrayConcat = kotlin_kotlin.$_$.a;
|
|
46
46
|
var listOf = kotlin_kotlin.$_$.f4;
|
|
47
47
|
var ArrayList_init_$Create$ = kotlin_kotlin.$_$.f;
|
|
48
|
-
var charSequenceLength = kotlin_kotlin.$_$.
|
|
49
|
-
var charSequenceGet = kotlin_kotlin.$_$.
|
|
48
|
+
var charSequenceLength = kotlin_kotlin.$_$.l6;
|
|
49
|
+
var charSequenceGet = kotlin_kotlin.$_$.k6;
|
|
50
50
|
var toString_0 = kotlin_kotlin.$_$.x1;
|
|
51
|
-
var withSign = kotlin_kotlin.$_$.
|
|
52
|
-
var trimMargin = kotlin_kotlin.$_$.
|
|
53
|
-
var hashCode = kotlin_kotlin.$_$.
|
|
54
|
-
var initMetadataForCompanion = kotlin_kotlin.$_$.
|
|
55
|
-
var coerceAtLeast = kotlin_kotlin.$_$.
|
|
56
|
-
var getNumberHashCode = kotlin_kotlin.$_$.
|
|
57
|
-
var isInterface = kotlin_kotlin.$_$.
|
|
51
|
+
var withSign = kotlin_kotlin.$_$.o7;
|
|
52
|
+
var trimMargin = kotlin_kotlin.$_$.g9;
|
|
53
|
+
var hashCode = kotlin_kotlin.$_$.u6;
|
|
54
|
+
var initMetadataForCompanion = kotlin_kotlin.$_$.w6;
|
|
55
|
+
var coerceAtLeast = kotlin_kotlin.$_$.p7;
|
|
56
|
+
var getNumberHashCode = kotlin_kotlin.$_$.r6;
|
|
57
|
+
var isInterface = kotlin_kotlin.$_$.d7;
|
|
58
58
|
var contentEquals = kotlin_kotlin.$_$.f3;
|
|
59
|
-
var coerceAtLeast_0 = kotlin_kotlin.$_$.
|
|
59
|
+
var coerceAtLeast_0 = kotlin_kotlin.$_$.r7;
|
|
60
60
|
var _UInt___init__impl__l7qpdl = kotlin_kotlin.$_$.e2;
|
|
61
61
|
var _UInt___get_data__impl__f0vqqw = kotlin_kotlin.$_$.f2;
|
|
62
|
-
var coerceIn = kotlin_kotlin.$_$.
|
|
62
|
+
var coerceIn = kotlin_kotlin.$_$.t7;
|
|
63
63
|
var _UByte___get_data__impl__jof9qr = kotlin_kotlin.$_$.c2;
|
|
64
64
|
var uintToDouble = kotlin_kotlin.$_$.ka;
|
|
65
|
-
var toByte = kotlin_kotlin.$_$.
|
|
65
|
+
var toByte = kotlin_kotlin.$_$.l7;
|
|
66
66
|
var _UByte___init__impl__g9hnc4 = kotlin_kotlin.$_$.b2;
|
|
67
|
-
var UInt = kotlin_kotlin.$_$.
|
|
67
|
+
var UInt = kotlin_kotlin.$_$.w9;
|
|
68
68
|
var UInt__hashCode_impl_z2mhuw = kotlin_kotlin.$_$.g2;
|
|
69
|
-
var objectCreate = kotlin_kotlin.$_$.
|
|
69
|
+
var objectCreate = kotlin_kotlin.$_$.j7;
|
|
70
70
|
//endregion
|
|
71
71
|
//region block: pre-declaration
|
|
72
72
|
function toHSL() {
|
|
73
|
-
return this.
|
|
73
|
+
return this.i2w().j2w();
|
|
74
74
|
}
|
|
75
75
|
function toXYZ() {
|
|
76
|
-
return this.
|
|
76
|
+
return this.i2w().p2w();
|
|
77
77
|
}
|
|
78
78
|
function toLAB() {
|
|
79
|
-
return this.
|
|
79
|
+
return this.p2w().q2w();
|
|
80
80
|
}
|
|
81
81
|
function toLCHab() {
|
|
82
|
-
return this.
|
|
82
|
+
return this.q2w().w2w();
|
|
83
83
|
}
|
|
84
84
|
initMetadataForInterface(Color, 'Color');
|
|
85
85
|
initMetadataForClass(ColorComponentInfo, 'ColorComponentInfo');
|
|
@@ -96,7 +96,7 @@
|
|
|
96
96
|
initMetadataForClass(ICtCp, 'ICtCp', VOID, VOID, [Color]);
|
|
97
97
|
initMetadataForObject(PqNonlinearity, 'PqNonlinearity');
|
|
98
98
|
function invoke(l, a, b, alpha) {
|
|
99
|
-
return this.
|
|
99
|
+
return this.h2z(numberToDouble(l), numberToDouble(a), numberToDouble(b), numberToDouble(alpha));
|
|
100
100
|
}
|
|
101
101
|
initMetadataForInterface(LABColorSpace, 'LABColorSpace', VOID, VOID, [WhitePointColorSpace]);
|
|
102
102
|
initMetadataForCompanion(Companion_0, VOID, [LABColorSpace]);
|
|
@@ -111,7 +111,7 @@
|
|
|
111
111
|
initMetadataForClass(Oklab, 'Oklab', VOID, VOID, [Color]);
|
|
112
112
|
initMetadataForClass(Oklch, 'Oklch', VOID, VOID, [Color]);
|
|
113
113
|
function invoke_0(r, g, b, alpha) {
|
|
114
|
-
return this.
|
|
114
|
+
return this.h2z(numberToDouble(r), numberToDouble(g), numberToDouble(b), numberToDouble(alpha));
|
|
115
115
|
}
|
|
116
116
|
initMetadataForInterface(RGBColorSpace, 'RGBColorSpace', VOID, VOID, [WhitePointColorSpace]);
|
|
117
117
|
initMetadataForCompanion(Companion_2, VOID, [RGBColorSpace]);
|
|
@@ -130,11 +130,11 @@
|
|
|
130
130
|
initMetadataForCompanion(Companion_3);
|
|
131
131
|
initMetadataForClass(RGBInt, 'RGBInt', VOID, VOID, [Color]);
|
|
132
132
|
function invoke_1(x, y, z, alpha) {
|
|
133
|
-
return this.
|
|
133
|
+
return this.h2z(numberToDouble(x), numberToDouble(y), numberToDouble(z), numberToDouble(alpha));
|
|
134
134
|
}
|
|
135
135
|
function invoke$default(x, y, z, alpha, $super) {
|
|
136
136
|
alpha = alpha === VOID ? 1.0 : alpha;
|
|
137
|
-
return $super === VOID ? this.
|
|
137
|
+
return $super === VOID ? this.c30(x, y, z, alpha) : invoke_1(x, y, z, alpha);
|
|
138
138
|
}
|
|
139
139
|
initMetadataForInterface(XYZColorSpace, 'XYZColorSpace', VOID, VOID, [WhitePointColorSpace]);
|
|
140
140
|
initMetadataForCompanion(Companion_4, VOID, [XYZColorSpace]);
|
|
@@ -146,15 +146,15 @@
|
|
|
146
146
|
function Color() {
|
|
147
147
|
}
|
|
148
148
|
function convertTo(_this__u8e3s4, space) {
|
|
149
|
-
return space.
|
|
149
|
+
return space.c2x(_this__u8e3s4);
|
|
150
150
|
}
|
|
151
151
|
function ColorComponentInfo(name, isPolar, min, max) {
|
|
152
|
-
this.
|
|
153
|
-
this.
|
|
154
|
-
this.
|
|
155
|
-
this.
|
|
152
|
+
this.d2x_1 = name;
|
|
153
|
+
this.e2x_1 = isPolar;
|
|
154
|
+
this.f2x_1 = min;
|
|
155
|
+
this.g2x_1 = max;
|
|
156
156
|
// Inline function 'kotlin.require' call
|
|
157
|
-
if (!(this.
|
|
157
|
+
if (!(this.f2x_1 <= this.g2x_1)) {
|
|
158
158
|
var message = 'min must be less than or equal to max';
|
|
159
159
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
160
160
|
}
|
|
@@ -214,14 +214,14 @@
|
|
|
214
214
|
legacyName = legacyName === VOID ? false : legacyName;
|
|
215
215
|
legacyFormat = legacyFormat === VOID ? false : legacyFormat;
|
|
216
216
|
customColorSpaces = customColorSpaces === VOID ? emptyMap() : customColorSpaces;
|
|
217
|
-
var tmp0 = customColorSpaces.
|
|
217
|
+
var tmp0 = customColorSpaces.r1();
|
|
218
218
|
var tmp$ret$1;
|
|
219
219
|
$l$block: {
|
|
220
220
|
// Inline function 'kotlin.collections.firstOrNull' call
|
|
221
221
|
var _iterator__ex2g4s = tmp0.l();
|
|
222
222
|
while (_iterator__ex2g4s.m()) {
|
|
223
223
|
var element = _iterator__ex2g4s.n();
|
|
224
|
-
if (equals(element.
|
|
224
|
+
if (equals(element.k1(), _this__u8e3s4.h2w())) {
|
|
225
225
|
tmp$ret$1 = element;
|
|
226
226
|
break $l$block;
|
|
227
227
|
}
|
|
@@ -229,7 +229,7 @@
|
|
|
229
229
|
tmp$ret$1 = null;
|
|
230
230
|
}
|
|
231
231
|
var tmp0_safe_receiver = tmp$ret$1;
|
|
232
|
-
var tmp1_safe_receiver = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.
|
|
232
|
+
var tmp1_safe_receiver = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.j1();
|
|
233
233
|
var tmp;
|
|
234
234
|
if (tmp1_safe_receiver == null) {
|
|
235
235
|
tmp = null;
|
|
@@ -242,17 +242,17 @@
|
|
|
242
242
|
if (tmp2_elvis_lhs == null) {
|
|
243
243
|
var tmp_1;
|
|
244
244
|
if (_this__u8e3s4 instanceof RGB) {
|
|
245
|
-
var tmp4_subject = _this__u8e3s4.
|
|
246
|
-
tmp_1 = equals(tmp4_subject, SRGB_getInstance()) ? renderSRGB(_this__u8e3s4, legacyFormat, legacyName, unitsPercent, alphaPercent, renderAlpha) : equals(tmp4_subject, RGBColorSpaces_getInstance().
|
|
245
|
+
var tmp4_subject = _this__u8e3s4.o2w_1;
|
|
246
|
+
tmp_1 = equals(tmp4_subject, SRGB_getInstance()) ? renderSRGB(_this__u8e3s4, legacyFormat, legacyName, unitsPercent, alphaPercent, renderAlpha) : equals(tmp4_subject, RGBColorSpaces_getInstance().h2y_1) ? renderFn(_this__u8e3s4, 'display-p3', unitsPercent, alphaPercent, renderAlpha) : equals(tmp4_subject, RGBColorSpaces_getInstance().d2y_1) ? renderFn(_this__u8e3s4, 'a98-rgb', unitsPercent, alphaPercent, renderAlpha) : equals(tmp4_subject, RGBColorSpaces_getInstance().i2y_1) ? renderFn(_this__u8e3s4, 'prophoto-rgb', unitsPercent, alphaPercent, renderAlpha) : equals(tmp4_subject, RGBColorSpaces_getInstance().e2y_1) ? renderFn(_this__u8e3s4, 'rec2020', unitsPercent, alphaPercent, renderAlpha) : equals(tmp4_subject, RGBColorSpaces_getInstance().y2x_1) ? renderFn(_this__u8e3s4, 'srgb-linear', unitsPercent, alphaPercent, renderAlpha) : null;
|
|
247
247
|
} else {
|
|
248
248
|
if (_this__u8e3s4 instanceof HSL) {
|
|
249
249
|
tmp_1 = renderHsl(_this__u8e3s4, legacyFormat, legacyName, hueUnit, alphaPercent, renderAlpha);
|
|
250
250
|
} else {
|
|
251
251
|
if (_this__u8e3s4 instanceof LAB) {
|
|
252
|
-
tmp_1 = renderLab(convertTo(_this__u8e3s4, LABColorSpaces_getInstance().
|
|
252
|
+
tmp_1 = renderLab(convertTo(_this__u8e3s4, LABColorSpaces_getInstance().w2x_1), alphaPercent, renderAlpha);
|
|
253
253
|
} else {
|
|
254
254
|
if (_this__u8e3s4 instanceof LCHab) {
|
|
255
|
-
tmp_1 = renderLCH(convertTo(_this__u8e3s4, LCHabColorSpaces_getInstance().
|
|
255
|
+
tmp_1 = renderLCH(convertTo(_this__u8e3s4, LCHabColorSpaces_getInstance().u2x_1), hueUnit, alphaPercent, renderAlpha);
|
|
256
256
|
} else {
|
|
257
257
|
if (_this__u8e3s4 instanceof HWB) {
|
|
258
258
|
tmp_1 = renderHWB(_this__u8e3s4, hueUnit, alphaPercent, renderAlpha);
|
|
@@ -264,7 +264,7 @@
|
|
|
264
264
|
tmp_1 = renderOklch(_this__u8e3s4, hueUnit, alphaPercent, renderAlpha);
|
|
265
265
|
} else {
|
|
266
266
|
if (_this__u8e3s4 instanceof XYZ) {
|
|
267
|
-
tmp_1 = _this__u8e3s4.
|
|
267
|
+
tmp_1 = _this__u8e3s4.v2w_1.h2x().equals(Illuminant_getInstance().q2x_1) ? renderFn(_this__u8e3s4, 'xyz-d65', unitsPercent, alphaPercent, renderAlpha) : renderFn(_this__u8e3s4.k2x(XYZColorSpaces_getInstance().j2x_1), 'xyz', unitsPercent, alphaPercent, renderAlpha);
|
|
268
268
|
} else {
|
|
269
269
|
tmp_1 = null;
|
|
270
270
|
}
|
|
@@ -285,40 +285,40 @@
|
|
|
285
285
|
// Inline function 'kotlin.text.buildString' call
|
|
286
286
|
// Inline function 'kotlin.apply' call
|
|
287
287
|
var this_0 = StringBuilder_init_$Create$();
|
|
288
|
-
this_0.
|
|
289
|
-
var tmp = dropLast(_this__u8e3s4.
|
|
288
|
+
this_0.c7('color(').c7(name).c7(' ');
|
|
289
|
+
var tmp = dropLast(_this__u8e3s4.l4(), 1);
|
|
290
290
|
joinTo(tmp, this_0, ' ', VOID, VOID, VOID, VOID, renderFn$lambda(unitsPercent));
|
|
291
|
-
this_0.
|
|
292
|
-
this_0.
|
|
291
|
+
this_0.c7(renderAlpha(_this__u8e3s4, false, renderAlpha_0, alphaPercent));
|
|
292
|
+
this_0.c7(')');
|
|
293
293
|
return this_0.toString();
|
|
294
294
|
}
|
|
295
295
|
function get_dashName(_this__u8e3s4) {
|
|
296
|
-
var tmp0 = _this__u8e3s4.
|
|
296
|
+
var tmp0 = _this__u8e3s4.h2w().v1();
|
|
297
297
|
// Inline function 'kotlin.text.replace' call
|
|
298
298
|
// Inline function 'kotlin.text.lowercase' call
|
|
299
299
|
// Inline function 'kotlin.js.asDynamic' call
|
|
300
|
-
return '--' + Regex_init_$Create$('\\W').
|
|
300
|
+
return '--' + Regex_init_$Create$('\\W').ab(tmp0, '-').toLowerCase();
|
|
301
301
|
}
|
|
302
302
|
function renderSRGB(_this__u8e3s4, commas, namedRgba, rgbPercent, alphaPercent, renderAlpha) {
|
|
303
|
-
return renderColorFn(_this__u8e3s4, namedRgba ? 'rgba' : 'rgb', [rgbPercent ? render(_this__u8e3s4.
|
|
303
|
+
return renderColorFn(_this__u8e3s4, namedRgba ? 'rgba' : 'rgb', [rgbPercent ? render(_this__u8e3s4.k2w_1, true) : UByte__toString_impl_v72jg(_RGBInt___get_r__impl__dulq0e(_this__u8e3s4.j2y())), rgbPercent ? render(_this__u8e3s4.l2w_1, true) : UByte__toString_impl_v72jg(_RGBInt___get_g__impl__o93c71(_this__u8e3s4.j2y())), rgbPercent ? render(_this__u8e3s4.m2w_1, true) : UByte__toString_impl_v72jg(_RGBInt___get_b__impl__m772ua(_this__u8e3s4.j2y()))], alphaPercent, renderAlpha, commas);
|
|
304
304
|
}
|
|
305
305
|
function renderHsl(_this__u8e3s4, commas, namedHsla, hueUnit, alphaPercent, renderAlpha) {
|
|
306
|
-
return renderColorFn(_this__u8e3s4, namedHsla ? 'hsla' : 'hsl', [renderHue(_this__u8e3s4, hueUnit), render(_this__u8e3s4.
|
|
306
|
+
return renderColorFn(_this__u8e3s4, namedHsla ? 'hsla' : 'hsl', [renderHue(_this__u8e3s4, hueUnit), render(_this__u8e3s4.l2y_1, true), render(_this__u8e3s4.m2y_1, true)], alphaPercent, renderAlpha, commas);
|
|
307
307
|
}
|
|
308
308
|
function renderLab(_this__u8e3s4, alphaPercent, renderAlpha) {
|
|
309
|
-
return renderColorFn(_this__u8e3s4, 'lab', [render(_this__u8e3s4.
|
|
309
|
+
return renderColorFn(_this__u8e3s4, 'lab', [render(_this__u8e3s4.x2w_1 / 100, true), render(_this__u8e3s4.y2w_1), render(_this__u8e3s4.z2w_1)], alphaPercent, renderAlpha);
|
|
310
310
|
}
|
|
311
311
|
function renderLCH(_this__u8e3s4, hueUnit, alphaPercent, renderAlpha) {
|
|
312
|
-
return renderColorFn(_this__u8e3s4, 'lch', [render(_this__u8e3s4.
|
|
312
|
+
return renderColorFn(_this__u8e3s4, 'lch', [render(_this__u8e3s4.o2y_1 / 100, true), render(_this__u8e3s4.p2y_1), renderHue(_this__u8e3s4, hueUnit)], alphaPercent, renderAlpha);
|
|
313
313
|
}
|
|
314
314
|
function renderHWB(_this__u8e3s4, hueUnit, alphaPercent, renderAlpha) {
|
|
315
|
-
return renderColorFn(_this__u8e3s4, 'hwb', [renderHue(_this__u8e3s4, hueUnit), render(_this__u8e3s4.
|
|
315
|
+
return renderColorFn(_this__u8e3s4, 'hwb', [renderHue(_this__u8e3s4, hueUnit), render(_this__u8e3s4.t2y_1, true), render(_this__u8e3s4.u2y_1, true)], alphaPercent, renderAlpha);
|
|
316
316
|
}
|
|
317
317
|
function renderOklab(_this__u8e3s4, alphaPercent, renderAlpha) {
|
|
318
|
-
return renderColorFn(_this__u8e3s4, 'oklab', [render(_this__u8e3s4.
|
|
318
|
+
return renderColorFn(_this__u8e3s4, 'oklab', [render(_this__u8e3s4.v2y_1, true), render(_this__u8e3s4.w2y_1), render(_this__u8e3s4.x2y_1)], alphaPercent, renderAlpha);
|
|
319
319
|
}
|
|
320
320
|
function renderOklch(_this__u8e3s4, hueUnit, alphaPercent, renderAlpha) {
|
|
321
|
-
return renderColorFn(_this__u8e3s4, 'oklch', [render(_this__u8e3s4.
|
|
321
|
+
return renderColorFn(_this__u8e3s4, 'oklch', [render(_this__u8e3s4.y2y_1, true), render(_this__u8e3s4.z2y_1), renderHue(_this__u8e3s4, hueUnit)], alphaPercent, renderAlpha);
|
|
322
322
|
}
|
|
323
323
|
function render(_this__u8e3s4, percent, precision) {
|
|
324
324
|
percent = percent === VOID ? false : percent;
|
|
@@ -345,8 +345,8 @@
|
|
|
345
345
|
}
|
|
346
346
|
function renderAlpha(_this__u8e3s4, commas, renderAlpha, alphaPercent) {
|
|
347
347
|
var tmp;
|
|
348
|
-
if (renderAlpha.equals(RenderCondition_ALWAYS_getInstance()) || (renderAlpha.equals(RenderCondition_AUTO_getInstance()) && !isNaN_0(_this__u8e3s4.
|
|
349
|
-
tmp = (commas ? ', ' : ' / ') + render(nanToOne(_this__u8e3s4.
|
|
348
|
+
if (renderAlpha.equals(RenderCondition_ALWAYS_getInstance()) || (renderAlpha.equals(RenderCondition_AUTO_getInstance()) && !isNaN_0(_this__u8e3s4.g2w()) && !(_this__u8e3s4.g2w() === 1.0))) {
|
|
349
|
+
tmp = (commas ? ', ' : ' / ') + render(nanToOne(_this__u8e3s4.g2w()), alphaPercent);
|
|
350
350
|
} else {
|
|
351
351
|
tmp = '';
|
|
352
352
|
}
|
|
@@ -358,24 +358,24 @@
|
|
|
358
358
|
// Inline function 'kotlin.apply' call
|
|
359
359
|
var this_0 = StringBuilder_init_$Create$();
|
|
360
360
|
var sep = commas ? ', ' : ' ';
|
|
361
|
-
this_0.
|
|
361
|
+
this_0.c7(name).c7('(');
|
|
362
362
|
joinTo_0(components, this_0, sep);
|
|
363
|
-
this_0.
|
|
364
|
-
this_0.
|
|
363
|
+
this_0.c7(renderAlpha(_this__u8e3s4, commas, renderAlpha_0, alphaPercent));
|
|
364
|
+
this_0.c7(')');
|
|
365
365
|
return this_0.toString();
|
|
366
366
|
}
|
|
367
367
|
function renderHue(_this__u8e3s4, hueUnit) {
|
|
368
368
|
var tmp;
|
|
369
|
-
if (isNaN_0(_this__u8e3s4.
|
|
369
|
+
if (isNaN_0(_this__u8e3s4.a2z())) {
|
|
370
370
|
tmp = 'none';
|
|
371
371
|
} else {
|
|
372
372
|
var tmp_0;
|
|
373
|
-
switch (hueUnit.
|
|
373
|
+
switch (hueUnit.u1_1) {
|
|
374
374
|
case 0:
|
|
375
|
-
tmp_0 = render(_this__u8e3s4.
|
|
375
|
+
tmp_0 = render(_this__u8e3s4.a2z());
|
|
376
376
|
break;
|
|
377
377
|
case 1:
|
|
378
|
-
tmp_0 = render(_this__u8e3s4.
|
|
378
|
+
tmp_0 = render(_this__u8e3s4.a2z()) + 'deg';
|
|
379
379
|
break;
|
|
380
380
|
case 2:
|
|
381
381
|
tmp_0 = render(hueAsRad(_this__u8e3s4)) + 'rad';
|
|
@@ -412,27 +412,27 @@
|
|
|
412
412
|
return AngleUnit_AUTO_instance;
|
|
413
413
|
}
|
|
414
414
|
function hueAsRad(_this__u8e3s4) {
|
|
415
|
-
return degToRad(_this__u8e3s4.
|
|
415
|
+
return degToRad(_this__u8e3s4.a2z());
|
|
416
416
|
}
|
|
417
417
|
function hueAsGrad(_this__u8e3s4) {
|
|
418
|
-
return degToGrad(_this__u8e3s4.
|
|
418
|
+
return degToGrad(_this__u8e3s4.a2z());
|
|
419
419
|
}
|
|
420
420
|
function hueAsTurns(_this__u8e3s4) {
|
|
421
|
-
return degToTurns(_this__u8e3s4.
|
|
421
|
+
return degToTurns(_this__u8e3s4.a2z());
|
|
422
422
|
}
|
|
423
423
|
function hueOr(_this__u8e3s4, whenNaN) {
|
|
424
|
-
return isNaN_0(_this__u8e3s4.
|
|
424
|
+
return isNaN_0(_this__u8e3s4.a2z()) ? numberToDouble(whenNaN) : _this__u8e3s4.a2z();
|
|
425
425
|
}
|
|
426
426
|
function WhitePoint(name, chromaticity) {
|
|
427
|
-
this.
|
|
428
|
-
this.
|
|
427
|
+
this.b2z_1 = name;
|
|
428
|
+
this.c2z_1 = chromaticity;
|
|
429
429
|
}
|
|
430
430
|
protoOf(WhitePoint).toString = function () {
|
|
431
|
-
return this.
|
|
431
|
+
return this.b2z_1;
|
|
432
432
|
};
|
|
433
433
|
protoOf(WhitePoint).hashCode = function () {
|
|
434
|
-
var result = getStringHashCode(this.
|
|
435
|
-
result = imul(result, 31) + this.
|
|
434
|
+
var result = getStringHashCode(this.b2z_1);
|
|
435
|
+
result = imul(result, 31) + this.c2z_1.hashCode() | 0;
|
|
436
436
|
return result;
|
|
437
437
|
};
|
|
438
438
|
protoOf(WhitePoint).equals = function (other) {
|
|
@@ -441,22 +441,22 @@
|
|
|
441
441
|
if (!(other instanceof WhitePoint))
|
|
442
442
|
return false;
|
|
443
443
|
var tmp0_other_with_cast = other instanceof WhitePoint ? other : THROW_CCE();
|
|
444
|
-
if (!(this.
|
|
444
|
+
if (!(this.b2z_1 === tmp0_other_with_cast.b2z_1))
|
|
445
445
|
return false;
|
|
446
|
-
if (!this.
|
|
446
|
+
if (!this.c2z_1.equals(tmp0_other_with_cast.c2z_1))
|
|
447
447
|
return false;
|
|
448
448
|
return true;
|
|
449
449
|
};
|
|
450
450
|
function Illuminant() {
|
|
451
451
|
Illuminant_instance = this;
|
|
452
|
-
this.
|
|
453
|
-
this.
|
|
454
|
-
this.
|
|
455
|
-
this.
|
|
456
|
-
this.
|
|
457
|
-
this.
|
|
458
|
-
this.
|
|
459
|
-
this.
|
|
452
|
+
this.l2x_1 = new WhitePoint('A', xyY_init_$Create$(0.44758, 0.40745));
|
|
453
|
+
this.m2x_1 = new WhitePoint('B', xyY_init_$Create$(0.34842, 0.35161));
|
|
454
|
+
this.n2x_1 = new WhitePoint('C', xyY_init_$Create$(0.31006, 0.31616));
|
|
455
|
+
this.o2x_1 = new WhitePoint('D50', xyY_init_$Create$(0.3457, 0.3585));
|
|
456
|
+
this.p2x_1 = new WhitePoint('D55', xyY_init_$Create$(0.33243, 0.34744));
|
|
457
|
+
this.q2x_1 = new WhitePoint('D65', xyY_init_$Create$(0.3127, 0.329));
|
|
458
|
+
this.r2x_1 = new WhitePoint('D75', xyY_init_$Create$(0.29903, 0.31488));
|
|
459
|
+
this.s2x_1 = new WhitePoint('E', xyY_init_$Create$(1.0 / 3.0, 1.0 / 3.0));
|
|
460
460
|
}
|
|
461
461
|
var Illuminant_instance;
|
|
462
462
|
function Illuminant_getInstance() {
|
|
@@ -488,7 +488,7 @@
|
|
|
488
488
|
this_0.h(tmp$ret$0);
|
|
489
489
|
}
|
|
490
490
|
this_0.h(get_alphaInfo());
|
|
491
|
-
return this_0.
|
|
491
|
+
return this_0.g2();
|
|
492
492
|
}
|
|
493
493
|
function polarComponentInfo(name, l, r) {
|
|
494
494
|
_init_properties_ColorSpaceUtils_kt__cnwylg();
|
|
@@ -505,7 +505,7 @@
|
|
|
505
505
|
this_0.h(tmp$ret$0);
|
|
506
506
|
}
|
|
507
507
|
this_0.h(get_alphaInfo());
|
|
508
|
-
return this_0.
|
|
508
|
+
return this_0.g2();
|
|
509
509
|
}
|
|
510
510
|
function threeComponentInfo(n1, l1, r1, n2, l2, r2, n3, l3, r3) {
|
|
511
511
|
_init_properties_ColorSpaceUtils_kt__cnwylg();
|
|
@@ -608,22 +608,22 @@
|
|
|
608
608
|
function Matrix__equals_impl_g5p8p9($this, other) {
|
|
609
609
|
if (!(other instanceof Matrix))
|
|
610
610
|
return false;
|
|
611
|
-
var tmp0_other_with_cast = other instanceof Matrix ? other.
|
|
611
|
+
var tmp0_other_with_cast = other instanceof Matrix ? other.d2z_1 : THROW_CCE();
|
|
612
612
|
if (!equals($this, tmp0_other_with_cast))
|
|
613
613
|
return false;
|
|
614
614
|
return true;
|
|
615
615
|
}
|
|
616
616
|
function Matrix(rowMajor) {
|
|
617
|
-
this.
|
|
617
|
+
this.d2z_1 = rowMajor;
|
|
618
618
|
}
|
|
619
619
|
protoOf(Matrix).toString = function () {
|
|
620
|
-
return Matrix__toString_impl_l0abk0(this.
|
|
620
|
+
return Matrix__toString_impl_l0abk0(this.d2z_1);
|
|
621
621
|
};
|
|
622
622
|
protoOf(Matrix).hashCode = function () {
|
|
623
|
-
return Matrix__hashCode_impl_s9ntm9(this.
|
|
623
|
+
return Matrix__hashCode_impl_s9ntm9(this.d2z_1);
|
|
624
624
|
};
|
|
625
625
|
protoOf(Matrix).equals = function (other) {
|
|
626
|
-
return Matrix__equals_impl_g5p8p9(this.
|
|
626
|
+
return Matrix__equals_impl_g5p8p9(this.d2z_1, other);
|
|
627
627
|
};
|
|
628
628
|
function inverse(_this__u8e3s4, inPlace) {
|
|
629
629
|
inPlace = inPlace === VOID ? false : inPlace;
|
|
@@ -701,22 +701,22 @@
|
|
|
701
701
|
function Vector__equals_impl_hy6igl($this, other) {
|
|
702
702
|
if (!(other instanceof Vector))
|
|
703
703
|
return false;
|
|
704
|
-
var tmp0_other_with_cast = other instanceof Vector ? other.
|
|
704
|
+
var tmp0_other_with_cast = other instanceof Vector ? other.e2z_1 : THROW_CCE();
|
|
705
705
|
if (!equals($this, tmp0_other_with_cast))
|
|
706
706
|
return false;
|
|
707
707
|
return true;
|
|
708
708
|
}
|
|
709
709
|
function Vector(values) {
|
|
710
|
-
this.
|
|
710
|
+
this.e2z_1 = values;
|
|
711
711
|
}
|
|
712
712
|
protoOf(Vector).toString = function () {
|
|
713
|
-
return Vector__toString_impl_hn2ybi(this.
|
|
713
|
+
return Vector__toString_impl_hn2ybi(this.e2z_1);
|
|
714
714
|
};
|
|
715
715
|
protoOf(Vector).hashCode = function () {
|
|
716
|
-
return Vector__hashCode_impl_442yhd(this.
|
|
716
|
+
return Vector__hashCode_impl_442yhd(this.e2z_1);
|
|
717
717
|
};
|
|
718
718
|
protoOf(Vector).equals = function (other) {
|
|
719
|
-
return Vector__equals_impl_hy6igl(this.
|
|
719
|
+
return Vector__equals_impl_hy6igl(this.e2z_1, other);
|
|
720
720
|
};
|
|
721
721
|
function dot_0(_this__u8e3s4, v0, v1, v2) {
|
|
722
722
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
@@ -730,13 +730,13 @@
|
|
|
730
730
|
}
|
|
731
731
|
function Companion() {
|
|
732
732
|
Companion_instance = this;
|
|
733
|
-
this.
|
|
733
|
+
this.f2z_1 = polarComponentInfo('HSL', 0.0, 1.0);
|
|
734
734
|
}
|
|
735
|
-
protoOf(Companion).
|
|
735
|
+
protoOf(Companion).v1 = function () {
|
|
736
736
|
return 'HSL';
|
|
737
737
|
};
|
|
738
|
-
protoOf(Companion).
|
|
739
|
-
return color.
|
|
738
|
+
protoOf(Companion).c2x = function (color) {
|
|
739
|
+
return color.j2w();
|
|
740
740
|
};
|
|
741
741
|
var Companion_instance;
|
|
742
742
|
function Companion_getInstance() {
|
|
@@ -758,53 +758,53 @@
|
|
|
758
758
|
function HSL(h, s, l, alpha) {
|
|
759
759
|
Companion_getInstance();
|
|
760
760
|
alpha = alpha === VOID ? 1.0 : alpha;
|
|
761
|
-
this.
|
|
762
|
-
this.
|
|
763
|
-
this.
|
|
764
|
-
this.
|
|
761
|
+
this.k2y_1 = h;
|
|
762
|
+
this.l2y_1 = s;
|
|
763
|
+
this.m2y_1 = l;
|
|
764
|
+
this.n2y_1 = alpha;
|
|
765
765
|
}
|
|
766
|
-
protoOf(HSL).
|
|
767
|
-
return this.
|
|
766
|
+
protoOf(HSL).a2z = function () {
|
|
767
|
+
return this.k2y_1;
|
|
768
768
|
};
|
|
769
|
-
protoOf(HSL).
|
|
770
|
-
return this.
|
|
769
|
+
protoOf(HSL).g2w = function () {
|
|
770
|
+
return this.n2y_1;
|
|
771
771
|
};
|
|
772
|
-
protoOf(HSL).
|
|
772
|
+
protoOf(HSL).h2w = function () {
|
|
773
773
|
return Companion_getInstance();
|
|
774
774
|
};
|
|
775
|
-
protoOf(HSL).
|
|
776
|
-
if (this.
|
|
777
|
-
return Companion_getInstance_2().
|
|
775
|
+
protoOf(HSL).i2w = function () {
|
|
776
|
+
if (this.l2y_1 < 1.0E-7)
|
|
777
|
+
return Companion_getInstance_2().h2z(this.m2y_1, this.m2y_1, this.m2y_1, this.n2y_1);
|
|
778
778
|
var h = normalizeDeg(hueOr(this, 0)) / 30.0;
|
|
779
|
-
var s = this.
|
|
780
|
-
var l = this.
|
|
781
|
-
return SRGB_getInstance().
|
|
779
|
+
var s = this.l2y_1;
|
|
780
|
+
var l = this.m2y_1;
|
|
781
|
+
return SRGB_getInstance().h2z(toSRGB$f(h, s, l, 0), toSRGB$f(h, s, l, 8), toSRGB$f(h, s, l, 4), this.n2y_1);
|
|
782
782
|
};
|
|
783
|
-
protoOf(HSL).
|
|
783
|
+
protoOf(HSL).j2w = function () {
|
|
784
784
|
return this;
|
|
785
785
|
};
|
|
786
|
-
protoOf(HSL).
|
|
786
|
+
protoOf(HSL).l4 = function () {
|
|
787
787
|
// Inline function 'kotlin.floatArrayOf' call
|
|
788
|
-
return new Float32Array([this.
|
|
788
|
+
return new Float32Array([this.k2y_1, this.l2y_1, this.m2y_1, this.n2y_1]);
|
|
789
789
|
};
|
|
790
|
-
protoOf(HSL).
|
|
790
|
+
protoOf(HSL).j2z = function (h, s, l, alpha) {
|
|
791
791
|
return new HSL(h, s, l, alpha);
|
|
792
792
|
};
|
|
793
|
-
protoOf(HSL).
|
|
794
|
-
h = h === VOID ? this.
|
|
795
|
-
s = s === VOID ? this.
|
|
796
|
-
l = l === VOID ? this.
|
|
797
|
-
alpha = alpha === VOID ? this.
|
|
798
|
-
return $super === VOID ? this.
|
|
793
|
+
protoOf(HSL).k2z = function (h, s, l, alpha, $super) {
|
|
794
|
+
h = h === VOID ? this.k2y_1 : h;
|
|
795
|
+
s = s === VOID ? this.l2y_1 : s;
|
|
796
|
+
l = l === VOID ? this.m2y_1 : l;
|
|
797
|
+
alpha = alpha === VOID ? this.n2y_1 : alpha;
|
|
798
|
+
return $super === VOID ? this.j2z(h, s, l, alpha) : $super.j2z.call(this, h, s, l, alpha);
|
|
799
799
|
};
|
|
800
800
|
protoOf(HSL).toString = function () {
|
|
801
|
-
return 'HSL(h=' + this.
|
|
801
|
+
return 'HSL(h=' + this.k2y_1 + ', s=' + this.l2y_1 + ', l=' + this.m2y_1 + ', alpha=' + this.n2y_1 + ')';
|
|
802
802
|
};
|
|
803
803
|
protoOf(HSL).hashCode = function () {
|
|
804
|
-
var result = getNumberHashCode(this.
|
|
805
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
806
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
807
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
804
|
+
var result = getNumberHashCode(this.k2y_1);
|
|
805
|
+
result = imul(result, 31) + getNumberHashCode(this.l2y_1) | 0;
|
|
806
|
+
result = imul(result, 31) + getNumberHashCode(this.m2y_1) | 0;
|
|
807
|
+
result = imul(result, 31) + getNumberHashCode(this.n2y_1) | 0;
|
|
808
808
|
return result;
|
|
809
809
|
};
|
|
810
810
|
protoOf(HSL).equals = function (other) {
|
|
@@ -813,13 +813,13 @@
|
|
|
813
813
|
if (!(other instanceof HSL))
|
|
814
814
|
return false;
|
|
815
815
|
var tmp0_other_with_cast = other instanceof HSL ? other : THROW_CCE();
|
|
816
|
-
if (!equals(this.
|
|
816
|
+
if (!equals(this.k2y_1, tmp0_other_with_cast.k2y_1))
|
|
817
817
|
return false;
|
|
818
|
-
if (!equals(this.
|
|
818
|
+
if (!equals(this.l2y_1, tmp0_other_with_cast.l2y_1))
|
|
819
819
|
return false;
|
|
820
|
-
if (!equals(this.
|
|
820
|
+
if (!equals(this.m2y_1, tmp0_other_with_cast.m2y_1))
|
|
821
821
|
return false;
|
|
822
|
-
if (!equals(this.
|
|
822
|
+
if (!equals(this.n2y_1, tmp0_other_with_cast.n2y_1))
|
|
823
823
|
return false;
|
|
824
824
|
return true;
|
|
825
825
|
};
|
|
@@ -863,43 +863,43 @@
|
|
|
863
863
|
var ICTCP_LMS_TO_XYZ;
|
|
864
864
|
function ICtCp() {
|
|
865
865
|
}
|
|
866
|
-
protoOf(ICtCp).
|
|
867
|
-
var fo = RGBColorSpaces_getInstance().
|
|
866
|
+
protoOf(ICtCp).p2z = function () {
|
|
867
|
+
var fo = RGBColorSpaces_getInstance().e2y_1.q2z();
|
|
868
868
|
var tmp0 = get_ICTCP_ICTCP_to_LMS();
|
|
869
|
-
var tmp2 = this.
|
|
870
|
-
var tmp4 = this.
|
|
869
|
+
var tmp2 = this.l2z_1;
|
|
870
|
+
var tmp4 = this.m2z_1;
|
|
871
871
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
872
|
-
var v2 = this.
|
|
872
|
+
var v2 = this.n2z_1;
|
|
873
873
|
var tmp0_0 = Matrix__get_impl_xogbpk(tmp0, 0, 0) * tmp2 + Matrix__get_impl_xogbpk(tmp0, 1, 0) * tmp4 + Matrix__get_impl_xogbpk(tmp0, 2, 0) * v2;
|
|
874
874
|
var tmp2_0 = Matrix__get_impl_xogbpk(tmp0, 0, 1) * tmp2 + Matrix__get_impl_xogbpk(tmp0, 1, 1) * tmp4 + Matrix__get_impl_xogbpk(tmp0, 2, 1) * v2;
|
|
875
875
|
var s = Matrix__get_impl_xogbpk(tmp0, 0, 2) * tmp2 + Matrix__get_impl_xogbpk(tmp0, 1, 2) * tmp4 + Matrix__get_impl_xogbpk(tmp0, 2, 2) * v2;
|
|
876
876
|
var tmp0_1 = get_ICTCP_LMS_to_RGB();
|
|
877
|
-
var tmp2_1 = PqNonlinearity_instance.
|
|
878
|
-
var tmp4_0 = PqNonlinearity_instance.
|
|
877
|
+
var tmp2_1 = PqNonlinearity_instance.z2z(tmp0_0);
|
|
878
|
+
var tmp4_0 = PqNonlinearity_instance.z2z(tmp2_0);
|
|
879
879
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
880
|
-
var v2_0 = PqNonlinearity_instance.
|
|
880
|
+
var v2_0 = PqNonlinearity_instance.z2z(s);
|
|
881
881
|
var tmp0_2 = Matrix__get_impl_xogbpk(tmp0_1, 0, 0) * tmp2_1 + Matrix__get_impl_xogbpk(tmp0_1, 1, 0) * tmp4_0 + Matrix__get_impl_xogbpk(tmp0_1, 2, 0) * v2_0;
|
|
882
882
|
var tmp2_2 = Matrix__get_impl_xogbpk(tmp0_1, 0, 1) * tmp2_1 + Matrix__get_impl_xogbpk(tmp0_1, 1, 1) * tmp4_0 + Matrix__get_impl_xogbpk(tmp0_1, 2, 1) * v2_0;
|
|
883
883
|
var b = Matrix__get_impl_xogbpk(tmp0_1, 0, 2) * tmp2_1 + Matrix__get_impl_xogbpk(tmp0_1, 1, 2) * tmp4_0 + Matrix__get_impl_xogbpk(tmp0_1, 2, 2) * v2_0;
|
|
884
|
-
return RGBColorSpaces_getInstance().
|
|
884
|
+
return RGBColorSpaces_getInstance().e2y_1.h2z(fo.a30(tmp0_2), fo.a30(tmp2_2), fo.a30(b), this.o2z_1);
|
|
885
885
|
};
|
|
886
886
|
function PqNonlinearity() {
|
|
887
|
-
this.
|
|
888
|
-
this.
|
|
889
|
-
this.
|
|
890
|
-
this.
|
|
891
|
-
this.
|
|
892
|
-
this.
|
|
893
|
-
this.
|
|
894
|
-
this.
|
|
895
|
-
}
|
|
896
|
-
protoOf(PqNonlinearity).
|
|
887
|
+
this.r2z_1 = 0.1593017578125;
|
|
888
|
+
this.s2z_1 = 78.84375;
|
|
889
|
+
this.t2z_1 = 0.8359375;
|
|
890
|
+
this.u2z_1 = 18.8515625;
|
|
891
|
+
this.v2z_1 = 18.6875;
|
|
892
|
+
this.w2z_1 = 10000.0;
|
|
893
|
+
this.x2z_1 = 6.277394636015326;
|
|
894
|
+
this.y2z_1 = 0.012683313515655966;
|
|
895
|
+
}
|
|
896
|
+
protoOf(PqNonlinearity).z2z = function (x) {
|
|
897
897
|
var vp = spow(x, 0.012683313515655966);
|
|
898
898
|
var n = coerceAtLeast(vp - 0.8359375, 0.0);
|
|
899
899
|
var l = spow_0(n / (18.8515625 - 18.6875 * vp), 6.277394636015326);
|
|
900
900
|
return 10000.0 * l;
|
|
901
901
|
};
|
|
902
|
-
protoOf(PqNonlinearity).
|
|
902
|
+
protoOf(PqNonlinearity).a30 = function (x) {
|
|
903
903
|
var yp = spow_0(x / 10000.0, 0.1593017578125);
|
|
904
904
|
return spow_0((0.8359375 + 18.8515625 * yp) / (1.0 + 18.6875 * yp), 78.84375);
|
|
905
905
|
};
|
|
@@ -923,28 +923,28 @@
|
|
|
923
923
|
}
|
|
924
924
|
function Companion_0() {
|
|
925
925
|
Companion_instance_0 = this;
|
|
926
|
-
this.
|
|
926
|
+
this.b30_1 = LABColorSpaces_getInstance().v2x_1;
|
|
927
927
|
}
|
|
928
928
|
protoOf(Companion_0).equals = function (other) {
|
|
929
|
-
return equals(LABColorSpaces_getInstance().
|
|
929
|
+
return equals(LABColorSpaces_getInstance().v2x_1, other);
|
|
930
930
|
};
|
|
931
931
|
protoOf(Companion_0).hashCode = function () {
|
|
932
|
-
return hashCode(LABColorSpaces_getInstance().
|
|
932
|
+
return hashCode(LABColorSpaces_getInstance().v2x_1);
|
|
933
933
|
};
|
|
934
|
-
protoOf(Companion_0).
|
|
935
|
-
return this.
|
|
934
|
+
protoOf(Companion_0).h2z = function (l, a, b, alpha) {
|
|
935
|
+
return this.b30_1.h2z(l, a, b, alpha);
|
|
936
936
|
};
|
|
937
|
-
protoOf(Companion_0).
|
|
938
|
-
return this.
|
|
937
|
+
protoOf(Companion_0).c30 = function (l, a, b, alpha) {
|
|
938
|
+
return this.b30_1.c30(l, a, b, alpha);
|
|
939
939
|
};
|
|
940
|
-
protoOf(Companion_0).
|
|
941
|
-
return this.
|
|
940
|
+
protoOf(Companion_0).h2x = function () {
|
|
941
|
+
return this.b30_1.h2x();
|
|
942
942
|
};
|
|
943
|
-
protoOf(Companion_0).
|
|
944
|
-
return this.
|
|
943
|
+
protoOf(Companion_0).v1 = function () {
|
|
944
|
+
return this.b30_1.v1();
|
|
945
945
|
};
|
|
946
|
-
protoOf(Companion_0).
|
|
947
|
-
return this.
|
|
946
|
+
protoOf(Companion_0).c2x = function (color) {
|
|
947
|
+
return this.b30_1.c2x(color);
|
|
948
948
|
};
|
|
949
949
|
var Companion_instance_0;
|
|
950
950
|
function Companion_getInstance_0() {
|
|
@@ -954,34 +954,34 @@
|
|
|
954
954
|
}
|
|
955
955
|
function LAB(l, a, b, alpha, space) {
|
|
956
956
|
Companion_getInstance_0();
|
|
957
|
-
this.
|
|
958
|
-
this.
|
|
959
|
-
this.
|
|
960
|
-
this.
|
|
961
|
-
this.
|
|
962
|
-
}
|
|
963
|
-
protoOf(LAB).
|
|
964
|
-
return this.
|
|
965
|
-
};
|
|
966
|
-
protoOf(LAB).
|
|
967
|
-
return this.
|
|
968
|
-
};
|
|
969
|
-
protoOf(LAB).
|
|
970
|
-
return this.
|
|
971
|
-
};
|
|
972
|
-
protoOf(LAB).
|
|
973
|
-
var xyzSpace = XYZColorSpace_0(this.
|
|
974
|
-
if (this.
|
|
975
|
-
return xyzSpace.
|
|
976
|
-
var fy = (this.
|
|
977
|
-
var fz = fy - this.
|
|
978
|
-
var fx = this.
|
|
957
|
+
this.x2w_1 = l;
|
|
958
|
+
this.y2w_1 = a;
|
|
959
|
+
this.z2w_1 = b;
|
|
960
|
+
this.a2x_1 = alpha;
|
|
961
|
+
this.b2x_1 = space;
|
|
962
|
+
}
|
|
963
|
+
protoOf(LAB).g2w = function () {
|
|
964
|
+
return this.a2x_1;
|
|
965
|
+
};
|
|
966
|
+
protoOf(LAB).h2w = function () {
|
|
967
|
+
return this.b2x_1;
|
|
968
|
+
};
|
|
969
|
+
protoOf(LAB).i2w = function () {
|
|
970
|
+
return this.x2w_1 === 0.0 ? Companion_getInstance_2().h2z(0.0, 0.0, 0.0, this.a2x_1) : this.p2w().i2w();
|
|
971
|
+
};
|
|
972
|
+
protoOf(LAB).p2w = function () {
|
|
973
|
+
var xyzSpace = XYZColorSpace_0(this.b2x_1.h2x());
|
|
974
|
+
if (this.x2w_1 === 0.0)
|
|
975
|
+
return xyzSpace.d30(0.0, 0.0, 0.0);
|
|
976
|
+
var fy = (this.x2w_1 + 16) / 116.0;
|
|
977
|
+
var fz = fy - this.z2w_1 / 200.0;
|
|
978
|
+
var fx = this.y2w_1 / 500.0 + fy;
|
|
979
979
|
var tmp;
|
|
980
|
-
if (this.
|
|
980
|
+
if (this.x2w_1 > 8.0) {
|
|
981
981
|
// Inline function 'kotlin.math.pow' call
|
|
982
982
|
tmp = Math.pow(fy, 3);
|
|
983
983
|
} else {
|
|
984
|
-
tmp = this.
|
|
984
|
+
tmp = this.x2w_1 / 903.2962962962963;
|
|
985
985
|
}
|
|
986
986
|
var yr = tmp;
|
|
987
987
|
// Inline function 'kotlin.math.pow' call
|
|
@@ -992,13 +992,13 @@
|
|
|
992
992
|
// Inline function 'kotlin.let' call
|
|
993
993
|
var it_0 = Math.pow(fx, 3);
|
|
994
994
|
var xr = it_0 > 0.008856451679035631 ? it_0 : (116 * fx - 16) / 903.2962962962963;
|
|
995
|
-
var wp = this.
|
|
996
|
-
return xyzSpace.
|
|
995
|
+
var wp = this.b2x_1.h2x().c2z_1;
|
|
996
|
+
return xyzSpace.c30(xr * wp.h30(), yr * wp.g30_1, zr * wp.i30(), this.a2x_1);
|
|
997
997
|
};
|
|
998
|
-
protoOf(LAB).
|
|
999
|
-
var tmp0 = this.
|
|
998
|
+
protoOf(LAB).w2w = function () {
|
|
999
|
+
var tmp0 = this.y2w_1;
|
|
1000
1000
|
// Inline function 'com.github.ajalt.colormath.internal.toPolarModel' call
|
|
1001
|
-
var b = this.
|
|
1001
|
+
var b = this.z2w_1;
|
|
1002
1002
|
// Inline function 'kotlin.math.sqrt' call
|
|
1003
1003
|
var x = tmp0 * tmp0 + b * b;
|
|
1004
1004
|
var c = Math.sqrt(x);
|
|
@@ -1012,24 +1012,24 @@
|
|
|
1012
1012
|
}
|
|
1013
1013
|
var h = tmp;
|
|
1014
1014
|
var h_0 = normalizeDeg(h);
|
|
1015
|
-
return LCHabColorSpace_0(this.
|
|
1015
|
+
return LCHabColorSpace_0(this.b2x_1.h2x()).h2z(this.x2w_1, c, h_0, this.a2x_1);
|
|
1016
1016
|
};
|
|
1017
|
-
protoOf(LAB).
|
|
1017
|
+
protoOf(LAB).q2w = function () {
|
|
1018
1018
|
return this;
|
|
1019
1019
|
};
|
|
1020
|
-
protoOf(LAB).
|
|
1020
|
+
protoOf(LAB).l4 = function () {
|
|
1021
1021
|
// Inline function 'kotlin.floatArrayOf' call
|
|
1022
|
-
return new Float32Array([this.
|
|
1022
|
+
return new Float32Array([this.x2w_1, this.y2w_1, this.z2w_1, this.a2x_1]);
|
|
1023
1023
|
};
|
|
1024
1024
|
protoOf(LAB).toString = function () {
|
|
1025
|
-
return 'LAB(l=' + this.
|
|
1025
|
+
return 'LAB(l=' + this.x2w_1 + ', a=' + this.y2w_1 + ', b=' + this.z2w_1 + ', alpha=' + this.a2x_1 + ', space=' + toString(this.b2x_1) + ')';
|
|
1026
1026
|
};
|
|
1027
1027
|
protoOf(LAB).hashCode = function () {
|
|
1028
|
-
var result = getNumberHashCode(this.
|
|
1029
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1030
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1031
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1032
|
-
result = imul(result, 31) + hashCode(this.
|
|
1028
|
+
var result = getNumberHashCode(this.x2w_1);
|
|
1029
|
+
result = imul(result, 31) + getNumberHashCode(this.y2w_1) | 0;
|
|
1030
|
+
result = imul(result, 31) + getNumberHashCode(this.z2w_1) | 0;
|
|
1031
|
+
result = imul(result, 31) + getNumberHashCode(this.a2x_1) | 0;
|
|
1032
|
+
result = imul(result, 31) + hashCode(this.b2x_1) | 0;
|
|
1033
1033
|
return result;
|
|
1034
1034
|
};
|
|
1035
1035
|
protoOf(LAB).equals = function (other) {
|
|
@@ -1038,15 +1038,15 @@
|
|
|
1038
1038
|
if (!(other instanceof LAB))
|
|
1039
1039
|
return false;
|
|
1040
1040
|
var tmp0_other_with_cast = other instanceof LAB ? other : THROW_CCE();
|
|
1041
|
-
if (!equals(this.
|
|
1041
|
+
if (!equals(this.x2w_1, tmp0_other_with_cast.x2w_1))
|
|
1042
1042
|
return false;
|
|
1043
|
-
if (!equals(this.
|
|
1043
|
+
if (!equals(this.y2w_1, tmp0_other_with_cast.y2w_1))
|
|
1044
1044
|
return false;
|
|
1045
|
-
if (!equals(this.
|
|
1045
|
+
if (!equals(this.z2w_1, tmp0_other_with_cast.z2w_1))
|
|
1046
1046
|
return false;
|
|
1047
|
-
if (!equals(this.
|
|
1047
|
+
if (!equals(this.a2x_1, tmp0_other_with_cast.a2x_1))
|
|
1048
1048
|
return false;
|
|
1049
|
-
if (!equals(this.
|
|
1049
|
+
if (!equals(this.b2x_1, tmp0_other_with_cast.b2x_1))
|
|
1050
1050
|
return false;
|
|
1051
1051
|
return true;
|
|
1052
1052
|
};
|
|
@@ -1054,8 +1054,8 @@
|
|
|
1054
1054
|
}
|
|
1055
1055
|
function LABColorSpaces() {
|
|
1056
1056
|
LABColorSpaces_instance = this;
|
|
1057
|
-
this.
|
|
1058
|
-
this.
|
|
1057
|
+
this.v2x_1 = new LABColorSpaceImpl(Illuminant_getInstance().q2x_1);
|
|
1058
|
+
this.w2x_1 = new LABColorSpaceImpl(Illuminant_getInstance().o2x_1);
|
|
1059
1059
|
}
|
|
1060
1060
|
var LABColorSpaces_instance;
|
|
1061
1061
|
function LABColorSpaces_getInstance() {
|
|
@@ -1064,70 +1064,70 @@
|
|
|
1064
1064
|
return LABColorSpaces_instance;
|
|
1065
1065
|
}
|
|
1066
1066
|
function LABColorSpaceImpl(whitePoint) {
|
|
1067
|
-
this.
|
|
1068
|
-
this.
|
|
1067
|
+
this.j30_1 = whitePoint;
|
|
1068
|
+
this.k30_1 = threeComponentInfo('L', 0.0, 100.0, 'A', -128.0, 128.0, 'B', -128.0, 128.0);
|
|
1069
1069
|
}
|
|
1070
|
-
protoOf(LABColorSpaceImpl).
|
|
1071
|
-
return this.
|
|
1070
|
+
protoOf(LABColorSpaceImpl).h2x = function () {
|
|
1071
|
+
return this.j30_1;
|
|
1072
1072
|
};
|
|
1073
|
-
protoOf(LABColorSpaceImpl).
|
|
1073
|
+
protoOf(LABColorSpaceImpl).v1 = function () {
|
|
1074
1074
|
return 'LAB';
|
|
1075
1075
|
};
|
|
1076
|
-
protoOf(LABColorSpaceImpl).
|
|
1076
|
+
protoOf(LABColorSpaceImpl).c2x = function (color) {
|
|
1077
1077
|
// Inline function 'com.github.ajalt.colormath.internal.adaptToThis' call
|
|
1078
1078
|
var tmp;
|
|
1079
|
-
var tmp_0 = color.
|
|
1079
|
+
var tmp_0 = color.h2w();
|
|
1080
1080
|
var tmp0_safe_receiver = isInterface(tmp_0, WhitePointColorSpace) ? tmp_0 : null;
|
|
1081
|
-
var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.
|
|
1082
|
-
if ((tmp1_elvis_lhs == null ? Illuminant_getInstance().
|
|
1083
|
-
tmp = color.
|
|
1081
|
+
var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.h2x();
|
|
1082
|
+
if ((tmp1_elvis_lhs == null ? Illuminant_getInstance().q2x_1 : tmp1_elvis_lhs).equals(this.h2x())) {
|
|
1083
|
+
tmp = color.q2w();
|
|
1084
1084
|
} else {
|
|
1085
|
-
tmp = color.
|
|
1085
|
+
tmp = color.p2w().k2x(XYZColorSpace_0(this.h2x())).q2w();
|
|
1086
1086
|
}
|
|
1087
1087
|
return tmp;
|
|
1088
1088
|
};
|
|
1089
1089
|
protoOf(LABColorSpaceImpl).toString = function () {
|
|
1090
|
-
return 'LABColorSpace(' + this.
|
|
1090
|
+
return 'LABColorSpace(' + this.j30_1.toString() + ')';
|
|
1091
1091
|
};
|
|
1092
|
-
protoOf(LABColorSpaceImpl).
|
|
1092
|
+
protoOf(LABColorSpaceImpl).h2z = function (l, a, b, alpha) {
|
|
1093
1093
|
return new LAB(l, a, b, alpha, this);
|
|
1094
1094
|
};
|
|
1095
1095
|
protoOf(LABColorSpaceImpl).hashCode = function () {
|
|
1096
|
-
return this.
|
|
1096
|
+
return this.j30_1.hashCode();
|
|
1097
1097
|
};
|
|
1098
1098
|
protoOf(LABColorSpaceImpl).equals = function (other) {
|
|
1099
1099
|
var tmp;
|
|
1100
1100
|
if (!(other == null) ? isInterface(other, LABColorSpace) : false) {
|
|
1101
|
-
tmp = this.
|
|
1101
|
+
tmp = this.j30_1.equals(other.h2x());
|
|
1102
1102
|
} else {
|
|
1103
1103
|
tmp = false;
|
|
1104
1104
|
}
|
|
1105
1105
|
return tmp;
|
|
1106
1106
|
};
|
|
1107
1107
|
function LABColorSpace_0(whitePoint) {
|
|
1108
|
-
return whitePoint.equals(Illuminant_getInstance().
|
|
1108
|
+
return whitePoint.equals(Illuminant_getInstance().q2x_1) ? LABColorSpaces_getInstance().v2x_1 : whitePoint.equals(Illuminant_getInstance().o2x_1) ? LABColorSpaces_getInstance().w2x_1 : new LABColorSpaceImpl(whitePoint);
|
|
1109
1109
|
}
|
|
1110
1110
|
function Companion_1() {
|
|
1111
1111
|
Companion_instance_1 = this;
|
|
1112
|
-
this.
|
|
1112
|
+
this.l30_1 = LCHabColorSpaces_getInstance().t2x_1;
|
|
1113
1113
|
}
|
|
1114
1114
|
protoOf(Companion_1).equals = function (other) {
|
|
1115
|
-
return equals(LCHabColorSpaces_getInstance().
|
|
1115
|
+
return equals(LCHabColorSpaces_getInstance().t2x_1, other);
|
|
1116
1116
|
};
|
|
1117
1117
|
protoOf(Companion_1).hashCode = function () {
|
|
1118
|
-
return hashCode(LCHabColorSpaces_getInstance().
|
|
1118
|
+
return hashCode(LCHabColorSpaces_getInstance().t2x_1);
|
|
1119
1119
|
};
|
|
1120
|
-
protoOf(Companion_1).
|
|
1121
|
-
return this.
|
|
1120
|
+
protoOf(Companion_1).h2z = function (l, c, h, alpha) {
|
|
1121
|
+
return this.l30_1.h2z(l, c, h, alpha);
|
|
1122
1122
|
};
|
|
1123
|
-
protoOf(Companion_1).
|
|
1124
|
-
return this.
|
|
1123
|
+
protoOf(Companion_1).h2x = function () {
|
|
1124
|
+
return this.l30_1.h2x();
|
|
1125
1125
|
};
|
|
1126
|
-
protoOf(Companion_1).
|
|
1127
|
-
return this.
|
|
1126
|
+
protoOf(Companion_1).v1 = function () {
|
|
1127
|
+
return this.l30_1.v1();
|
|
1128
1128
|
};
|
|
1129
|
-
protoOf(Companion_1).
|
|
1130
|
-
return this.
|
|
1129
|
+
protoOf(Companion_1).c2x = function (color) {
|
|
1130
|
+
return this.l30_1.c2x(color);
|
|
1131
1131
|
};
|
|
1132
1132
|
var Companion_instance_1;
|
|
1133
1133
|
function Companion_getInstance_1() {
|
|
@@ -1137,54 +1137,54 @@
|
|
|
1137
1137
|
}
|
|
1138
1138
|
function LCHab(l, c, h, alpha, space) {
|
|
1139
1139
|
Companion_getInstance_1();
|
|
1140
|
-
this.
|
|
1141
|
-
this.
|
|
1142
|
-
this.
|
|
1143
|
-
this.
|
|
1144
|
-
this.
|
|
1140
|
+
this.o2y_1 = l;
|
|
1141
|
+
this.p2y_1 = c;
|
|
1142
|
+
this.q2y_1 = h;
|
|
1143
|
+
this.r2y_1 = alpha;
|
|
1144
|
+
this.s2y_1 = space;
|
|
1145
1145
|
}
|
|
1146
|
-
protoOf(LCHab).
|
|
1147
|
-
return this.
|
|
1146
|
+
protoOf(LCHab).a2z = function () {
|
|
1147
|
+
return this.q2y_1;
|
|
1148
1148
|
};
|
|
1149
|
-
protoOf(LCHab).
|
|
1150
|
-
return this.
|
|
1149
|
+
protoOf(LCHab).g2w = function () {
|
|
1150
|
+
return this.r2y_1;
|
|
1151
1151
|
};
|
|
1152
|
-
protoOf(LCHab).
|
|
1153
|
-
return this.
|
|
1152
|
+
protoOf(LCHab).h2w = function () {
|
|
1153
|
+
return this.s2y_1;
|
|
1154
1154
|
};
|
|
1155
|
-
protoOf(LCHab).
|
|
1156
|
-
return this.
|
|
1155
|
+
protoOf(LCHab).i2w = function () {
|
|
1156
|
+
return this.q2w().i2w();
|
|
1157
1157
|
};
|
|
1158
|
-
protoOf(LCHab).
|
|
1159
|
-
return this.
|
|
1158
|
+
protoOf(LCHab).p2w = function () {
|
|
1159
|
+
return this.q2w().p2w();
|
|
1160
1160
|
};
|
|
1161
|
-
protoOf(LCHab).
|
|
1162
|
-
var tmp0 = this.
|
|
1161
|
+
protoOf(LCHab).q2w = function () {
|
|
1162
|
+
var tmp0 = this.p2y_1;
|
|
1163
1163
|
// Inline function 'com.github.ajalt.colormath.internal.fromPolarModel' call
|
|
1164
|
-
var h = this.
|
|
1164
|
+
var h = this.q2y_1;
|
|
1165
1165
|
var hDegrees = isNaN_0(h) ? 0.0 : degToRad(h);
|
|
1166
1166
|
// Inline function 'kotlin.math.cos' call
|
|
1167
1167
|
var a = tmp0 * Math.cos(hDegrees);
|
|
1168
1168
|
// Inline function 'kotlin.math.sin' call
|
|
1169
1169
|
var b = tmp0 * Math.sin(hDegrees);
|
|
1170
|
-
return LABColorSpace_0(this.
|
|
1170
|
+
return LABColorSpace_0(this.s2y_1.h2x()).h2z(this.o2y_1, a, b, this.r2y_1);
|
|
1171
1171
|
};
|
|
1172
|
-
protoOf(LCHab).
|
|
1172
|
+
protoOf(LCHab).w2w = function () {
|
|
1173
1173
|
return this;
|
|
1174
1174
|
};
|
|
1175
|
-
protoOf(LCHab).
|
|
1175
|
+
protoOf(LCHab).l4 = function () {
|
|
1176
1176
|
// Inline function 'kotlin.floatArrayOf' call
|
|
1177
|
-
return new Float32Array([this.
|
|
1177
|
+
return new Float32Array([this.o2y_1, this.p2y_1, this.q2y_1, this.r2y_1]);
|
|
1178
1178
|
};
|
|
1179
1179
|
protoOf(LCHab).toString = function () {
|
|
1180
|
-
return 'LCHab(l=' + this.
|
|
1180
|
+
return 'LCHab(l=' + this.o2y_1 + ', c=' + this.p2y_1 + ', h=' + this.q2y_1 + ', alpha=' + this.r2y_1 + ', space=' + toString(this.s2y_1) + ')';
|
|
1181
1181
|
};
|
|
1182
1182
|
protoOf(LCHab).hashCode = function () {
|
|
1183
|
-
var result = getNumberHashCode(this.
|
|
1184
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1185
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1186
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1187
|
-
result = imul(result, 31) + hashCode(this.
|
|
1183
|
+
var result = getNumberHashCode(this.o2y_1);
|
|
1184
|
+
result = imul(result, 31) + getNumberHashCode(this.p2y_1) | 0;
|
|
1185
|
+
result = imul(result, 31) + getNumberHashCode(this.q2y_1) | 0;
|
|
1186
|
+
result = imul(result, 31) + getNumberHashCode(this.r2y_1) | 0;
|
|
1187
|
+
result = imul(result, 31) + hashCode(this.s2y_1) | 0;
|
|
1188
1188
|
return result;
|
|
1189
1189
|
};
|
|
1190
1190
|
protoOf(LCHab).equals = function (other) {
|
|
@@ -1193,15 +1193,15 @@
|
|
|
1193
1193
|
if (!(other instanceof LCHab))
|
|
1194
1194
|
return false;
|
|
1195
1195
|
var tmp0_other_with_cast = other instanceof LCHab ? other : THROW_CCE();
|
|
1196
|
-
if (!equals(this.
|
|
1196
|
+
if (!equals(this.o2y_1, tmp0_other_with_cast.o2y_1))
|
|
1197
1197
|
return false;
|
|
1198
|
-
if (!equals(this.
|
|
1198
|
+
if (!equals(this.p2y_1, tmp0_other_with_cast.p2y_1))
|
|
1199
1199
|
return false;
|
|
1200
|
-
if (!equals(this.
|
|
1200
|
+
if (!equals(this.q2y_1, tmp0_other_with_cast.q2y_1))
|
|
1201
1201
|
return false;
|
|
1202
|
-
if (!equals(this.
|
|
1202
|
+
if (!equals(this.r2y_1, tmp0_other_with_cast.r2y_1))
|
|
1203
1203
|
return false;
|
|
1204
|
-
if (!equals(this.
|
|
1204
|
+
if (!equals(this.s2y_1, tmp0_other_with_cast.s2y_1))
|
|
1205
1205
|
return false;
|
|
1206
1206
|
return true;
|
|
1207
1207
|
};
|
|
@@ -1209,8 +1209,8 @@
|
|
|
1209
1209
|
}
|
|
1210
1210
|
function LCHabColorSpaces() {
|
|
1211
1211
|
LCHabColorSpaces_instance = this;
|
|
1212
|
-
this.
|
|
1213
|
-
this.
|
|
1212
|
+
this.t2x_1 = new LCHabColorSpaceImpl(Illuminant_getInstance().q2x_1);
|
|
1213
|
+
this.u2x_1 = new LCHabColorSpaceImpl(Illuminant_getInstance().o2x_1);
|
|
1214
1214
|
}
|
|
1215
1215
|
var LCHabColorSpaces_instance;
|
|
1216
1216
|
function LCHabColorSpaces_getInstance() {
|
|
@@ -1219,44 +1219,44 @@
|
|
|
1219
1219
|
return LCHabColorSpaces_instance;
|
|
1220
1220
|
}
|
|
1221
1221
|
function LCHabColorSpace_0(whitePoint) {
|
|
1222
|
-
return whitePoint.equals(Illuminant_getInstance().
|
|
1222
|
+
return whitePoint.equals(Illuminant_getInstance().q2x_1) ? LCHabColorSpaces_getInstance().t2x_1 : whitePoint.equals(Illuminant_getInstance().o2x_1) ? LCHabColorSpaces_getInstance().u2x_1 : new LCHabColorSpaceImpl(whitePoint);
|
|
1223
1223
|
}
|
|
1224
1224
|
function LCHabColorSpaceImpl(whitePoint) {
|
|
1225
|
-
this.
|
|
1226
|
-
this.
|
|
1225
|
+
this.m30_1 = whitePoint;
|
|
1226
|
+
this.n30_1 = componentInfoList([new ColorComponentInfo('L', false, 0.0, 100.0), new ColorComponentInfo('C', false, 0.0, 150.0), new ColorComponentInfo('H', true, 0.0, 360.0)]);
|
|
1227
1227
|
}
|
|
1228
|
-
protoOf(LCHabColorSpaceImpl).
|
|
1229
|
-
return this.
|
|
1228
|
+
protoOf(LCHabColorSpaceImpl).h2x = function () {
|
|
1229
|
+
return this.m30_1;
|
|
1230
1230
|
};
|
|
1231
|
-
protoOf(LCHabColorSpaceImpl).
|
|
1231
|
+
protoOf(LCHabColorSpaceImpl).v1 = function () {
|
|
1232
1232
|
return 'LCHab';
|
|
1233
1233
|
};
|
|
1234
|
-
protoOf(LCHabColorSpaceImpl).
|
|
1234
|
+
protoOf(LCHabColorSpaceImpl).c2x = function (color) {
|
|
1235
1235
|
// Inline function 'com.github.ajalt.colormath.internal.adaptToThis' call
|
|
1236
1236
|
var tmp;
|
|
1237
|
-
var tmp_0 = color.
|
|
1237
|
+
var tmp_0 = color.h2w();
|
|
1238
1238
|
var tmp0_safe_receiver = isInterface(tmp_0, WhitePointColorSpace) ? tmp_0 : null;
|
|
1239
|
-
var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.
|
|
1240
|
-
if ((tmp1_elvis_lhs == null ? Illuminant_getInstance().
|
|
1241
|
-
tmp = color.
|
|
1239
|
+
var tmp1_elvis_lhs = tmp0_safe_receiver == null ? null : tmp0_safe_receiver.h2x();
|
|
1240
|
+
if ((tmp1_elvis_lhs == null ? Illuminant_getInstance().q2x_1 : tmp1_elvis_lhs).equals(this.h2x())) {
|
|
1241
|
+
tmp = color.w2w();
|
|
1242
1242
|
} else {
|
|
1243
|
-
tmp = color.
|
|
1243
|
+
tmp = color.p2w().k2x(XYZColorSpace_0(this.h2x())).w2w();
|
|
1244
1244
|
}
|
|
1245
1245
|
return tmp;
|
|
1246
1246
|
};
|
|
1247
1247
|
protoOf(LCHabColorSpaceImpl).toString = function () {
|
|
1248
|
-
return 'LCHabColorSpace(' + this.
|
|
1248
|
+
return 'LCHabColorSpace(' + this.m30_1.toString() + ')';
|
|
1249
1249
|
};
|
|
1250
|
-
protoOf(LCHabColorSpaceImpl).
|
|
1250
|
+
protoOf(LCHabColorSpaceImpl).h2z = function (l, c, h, alpha) {
|
|
1251
1251
|
return new LCHab(l, c, h, alpha, this);
|
|
1252
1252
|
};
|
|
1253
1253
|
protoOf(LCHabColorSpaceImpl).hashCode = function () {
|
|
1254
|
-
return this.
|
|
1254
|
+
return this.m30_1.hashCode();
|
|
1255
1255
|
};
|
|
1256
1256
|
protoOf(LCHabColorSpaceImpl).equals = function (other) {
|
|
1257
1257
|
var tmp;
|
|
1258
1258
|
if (!(other == null) ? isInterface(other, LCHabColorSpace) : false) {
|
|
1259
|
-
tmp = this.
|
|
1259
|
+
tmp = this.m30_1.equals(other.h2x());
|
|
1260
1260
|
} else {
|
|
1261
1261
|
tmp = false;
|
|
1262
1262
|
}
|
|
@@ -1268,37 +1268,37 @@
|
|
|
1268
1268
|
}
|
|
1269
1269
|
function Companion_2() {
|
|
1270
1270
|
Companion_instance_2 = this;
|
|
1271
|
-
this.
|
|
1271
|
+
this.g2z_1 = RGBColorSpaces_getInstance().x2x_1;
|
|
1272
1272
|
}
|
|
1273
1273
|
protoOf(Companion_2).equals = function (other) {
|
|
1274
|
-
return equals(RGBColorSpaces_getInstance().
|
|
1274
|
+
return equals(RGBColorSpaces_getInstance().x2x_1, other);
|
|
1275
1275
|
};
|
|
1276
1276
|
protoOf(Companion_2).hashCode = function () {
|
|
1277
|
-
return hashCode(RGBColorSpaces_getInstance().
|
|
1277
|
+
return hashCode(RGBColorSpaces_getInstance().x2x_1);
|
|
1278
1278
|
};
|
|
1279
|
-
protoOf(Companion_2).
|
|
1280
|
-
return this.
|
|
1279
|
+
protoOf(Companion_2).h2z = function (r, g, b, alpha) {
|
|
1280
|
+
return this.g2z_1.h2z(r, g, b, alpha);
|
|
1281
1281
|
};
|
|
1282
|
-
protoOf(Companion_2).
|
|
1283
|
-
return this.
|
|
1282
|
+
protoOf(Companion_2).c30 = function (r, g, b, alpha) {
|
|
1283
|
+
return this.g2z_1.c30(r, g, b, alpha);
|
|
1284
1284
|
};
|
|
1285
|
-
protoOf(Companion_2).
|
|
1286
|
-
return this.
|
|
1285
|
+
protoOf(Companion_2).q2z = function () {
|
|
1286
|
+
return this.g2z_1.q2z();
|
|
1287
1287
|
};
|
|
1288
|
-
protoOf(Companion_2).
|
|
1289
|
-
return this.
|
|
1288
|
+
protoOf(Companion_2).o30 = function () {
|
|
1289
|
+
return this.g2z_1.o30();
|
|
1290
1290
|
};
|
|
1291
|
-
protoOf(Companion_2).
|
|
1292
|
-
return this.
|
|
1291
|
+
protoOf(Companion_2).p30 = function () {
|
|
1292
|
+
return this.g2z_1.p30();
|
|
1293
1293
|
};
|
|
1294
|
-
protoOf(Companion_2).
|
|
1295
|
-
return this.
|
|
1294
|
+
protoOf(Companion_2).h2x = function () {
|
|
1295
|
+
return this.g2z_1.h2x();
|
|
1296
1296
|
};
|
|
1297
|
-
protoOf(Companion_2).
|
|
1298
|
-
return this.
|
|
1297
|
+
protoOf(Companion_2).v1 = function () {
|
|
1298
|
+
return this.g2z_1.v1();
|
|
1299
1299
|
};
|
|
1300
|
-
protoOf(Companion_2).
|
|
1301
|
-
return this.
|
|
1300
|
+
protoOf(Companion_2).c2x = function (color) {
|
|
1301
|
+
return this.g2z_1.c2x(color);
|
|
1302
1302
|
};
|
|
1303
1303
|
var Companion_instance_2;
|
|
1304
1304
|
function Companion_getInstance_2() {
|
|
@@ -1308,36 +1308,36 @@
|
|
|
1308
1308
|
}
|
|
1309
1309
|
function RGB(r, g, b, alpha, space) {
|
|
1310
1310
|
Companion_getInstance_2();
|
|
1311
|
-
this.
|
|
1312
|
-
this.
|
|
1313
|
-
this.
|
|
1314
|
-
this.
|
|
1315
|
-
this.
|
|
1311
|
+
this.k2w_1 = r;
|
|
1312
|
+
this.l2w_1 = g;
|
|
1313
|
+
this.m2w_1 = b;
|
|
1314
|
+
this.n2w_1 = alpha;
|
|
1315
|
+
this.o2w_1 = space;
|
|
1316
1316
|
}
|
|
1317
|
-
protoOf(RGB).
|
|
1318
|
-
return this.
|
|
1317
|
+
protoOf(RGB).g2w = function () {
|
|
1318
|
+
return this.n2w_1;
|
|
1319
1319
|
};
|
|
1320
|
-
protoOf(RGB).
|
|
1321
|
-
return this.
|
|
1320
|
+
protoOf(RGB).h2w = function () {
|
|
1321
|
+
return this.o2w_1;
|
|
1322
1322
|
};
|
|
1323
|
-
protoOf(RGB).
|
|
1323
|
+
protoOf(RGB).j2y = function () {
|
|
1324
1324
|
// Inline function 'com.github.ajalt.colormath.model.RGB.toSRGB' call
|
|
1325
|
-
var $this$toSRGB = this.
|
|
1326
|
-
return _RGBInt___init__impl__lqova7_1($this$toSRGB.
|
|
1325
|
+
var $this$toSRGB = this.q30(SRGB_getInstance());
|
|
1326
|
+
return _RGBInt___init__impl__lqova7_1($this$toSRGB.k2w_1, $this$toSRGB.l2w_1, $this$toSRGB.m2w_1, nanToOne($this$toSRGB.n2w_1));
|
|
1327
1327
|
};
|
|
1328
|
-
protoOf(RGB).
|
|
1329
|
-
var f = SRGB_getInstance().
|
|
1330
|
-
return equals(this.
|
|
1328
|
+
protoOf(RGB).q30 = function (space) {
|
|
1329
|
+
var f = SRGB_getInstance().q2z();
|
|
1330
|
+
return equals(this.o2w_1, space) ? this : equals(this.o2w_1, SRGB_getInstance()) && equals(space, RGBColorSpaces_getInstance().y2x_1) ? space.h2z(f.z2z(this.k2w_1), f.z2z(this.l2w_1), f.z2z(this.m2w_1), this.n2w_1) : equals(this.o2w_1, RGBColorSpaces_getInstance().y2x_1) && equals(space, SRGB_getInstance()) ? space.h2z(f.a30(this.k2w_1), f.a30(this.l2w_1), f.a30(this.m2w_1), this.n2w_1) : this.p2w().s30(space);
|
|
1331
1331
|
};
|
|
1332
|
-
protoOf(RGB).
|
|
1332
|
+
protoOf(RGB).j2w = function () {
|
|
1333
1333
|
var tmp$ret$3;
|
|
1334
1334
|
$l$block: {
|
|
1335
1335
|
// Inline function 'com.github.ajalt.colormath.model.RGB.srgbHueMinMaxChroma' call
|
|
1336
1336
|
// Inline function 'com.github.ajalt.colormath.model.RGB.toSRGB' call
|
|
1337
|
-
var $this$toSRGB = this.
|
|
1338
|
-
var r = $this$toSRGB.
|
|
1339
|
-
var g = $this$toSRGB.
|
|
1340
|
-
var b = $this$toSRGB.
|
|
1337
|
+
var $this$toSRGB = this.q30(SRGB_getInstance());
|
|
1338
|
+
var r = $this$toSRGB.k2w_1;
|
|
1339
|
+
var g = $this$toSRGB.l2w_1;
|
|
1340
|
+
var b = $this$toSRGB.m2w_1;
|
|
1341
1341
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
1342
1342
|
var min = Math.min(r, g, b);
|
|
1343
1343
|
// Inline function 'kotlin.comparisons.maxOf' call
|
|
@@ -1347,39 +1347,39 @@
|
|
|
1347
1347
|
var h_0 = normalizeDeg_0(h);
|
|
1348
1348
|
var l = (min + max) / 2.0;
|
|
1349
1349
|
var s = max === min ? 0.0 : l <= 0.5 ? chroma / (max + min) : chroma / (2 - max - min);
|
|
1350
|
-
tmp$ret$3 = new HSL(h_0, s, l, this.
|
|
1350
|
+
tmp$ret$3 = new HSL(h_0, s, l, this.n2w_1);
|
|
1351
1351
|
break $l$block;
|
|
1352
1352
|
}
|
|
1353
1353
|
return tmp$ret$3;
|
|
1354
1354
|
};
|
|
1355
|
-
protoOf(RGB).
|
|
1356
|
-
var f = this.
|
|
1357
|
-
var tmp0 = _Matrix___init__impl__q3kp4w(this.
|
|
1358
|
-
var tmp2 = f.
|
|
1359
|
-
var tmp4 = f.
|
|
1355
|
+
protoOf(RGB).p2w = function () {
|
|
1356
|
+
var f = this.o2w_1.q2z();
|
|
1357
|
+
var tmp0 = _Matrix___init__impl__q3kp4w(this.o2w_1.o30());
|
|
1358
|
+
var tmp2 = f.z2z(this.k2w_1);
|
|
1359
|
+
var tmp4 = f.z2z(this.l2w_1);
|
|
1360
1360
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
1361
|
-
var v2 = f.
|
|
1361
|
+
var v2 = f.z2z(this.m2w_1);
|
|
1362
1362
|
var tmp0_0 = Matrix__get_impl_xogbpk(tmp0, 0, 0) * tmp2 + Matrix__get_impl_xogbpk(tmp0, 1, 0) * tmp4 + Matrix__get_impl_xogbpk(tmp0, 2, 0) * v2;
|
|
1363
1363
|
var tmp2_0 = Matrix__get_impl_xogbpk(tmp0, 0, 1) * tmp2 + Matrix__get_impl_xogbpk(tmp0, 1, 1) * tmp4 + Matrix__get_impl_xogbpk(tmp0, 2, 1) * v2;
|
|
1364
1364
|
var z = Matrix__get_impl_xogbpk(tmp0, 0, 2) * tmp2 + Matrix__get_impl_xogbpk(tmp0, 1, 2) * tmp4 + Matrix__get_impl_xogbpk(tmp0, 2, 2) * v2;
|
|
1365
|
-
return XYZColorSpace_0(this.
|
|
1365
|
+
return XYZColorSpace_0(this.o2w_1.h2x()).h2z(tmp0_0, tmp2_0, z, this.n2w_1);
|
|
1366
1366
|
};
|
|
1367
|
-
protoOf(RGB).
|
|
1368
|
-
return this.
|
|
1367
|
+
protoOf(RGB).i2w = function () {
|
|
1368
|
+
return this.q30(RGBColorSpaces_getInstance().x2x_1);
|
|
1369
1369
|
};
|
|
1370
|
-
protoOf(RGB).
|
|
1370
|
+
protoOf(RGB).l4 = function () {
|
|
1371
1371
|
// Inline function 'kotlin.floatArrayOf' call
|
|
1372
|
-
return new Float32Array([this.
|
|
1372
|
+
return new Float32Array([this.k2w_1, this.l2w_1, this.m2w_1, this.n2w_1]);
|
|
1373
1373
|
};
|
|
1374
1374
|
protoOf(RGB).toString = function () {
|
|
1375
|
-
return 'RGB(r=' + this.
|
|
1375
|
+
return 'RGB(r=' + this.k2w_1 + ', g=' + this.l2w_1 + ', b=' + this.m2w_1 + ', alpha=' + this.n2w_1 + ', space=' + toString(this.o2w_1) + ')';
|
|
1376
1376
|
};
|
|
1377
1377
|
protoOf(RGB).hashCode = function () {
|
|
1378
|
-
var result = getNumberHashCode(this.
|
|
1379
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1380
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1381
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1382
|
-
result = imul(result, 31) + hashCode(this.
|
|
1378
|
+
var result = getNumberHashCode(this.k2w_1);
|
|
1379
|
+
result = imul(result, 31) + getNumberHashCode(this.l2w_1) | 0;
|
|
1380
|
+
result = imul(result, 31) + getNumberHashCode(this.m2w_1) | 0;
|
|
1381
|
+
result = imul(result, 31) + getNumberHashCode(this.n2w_1) | 0;
|
|
1382
|
+
result = imul(result, 31) + hashCode(this.o2w_1) | 0;
|
|
1383
1383
|
return result;
|
|
1384
1384
|
};
|
|
1385
1385
|
protoOf(RGB).equals = function (other) {
|
|
@@ -1388,32 +1388,32 @@
|
|
|
1388
1388
|
if (!(other instanceof RGB))
|
|
1389
1389
|
return false;
|
|
1390
1390
|
var tmp0_other_with_cast = other instanceof RGB ? other : THROW_CCE();
|
|
1391
|
-
if (!equals(this.
|
|
1391
|
+
if (!equals(this.k2w_1, tmp0_other_with_cast.k2w_1))
|
|
1392
1392
|
return false;
|
|
1393
|
-
if (!equals(this.
|
|
1393
|
+
if (!equals(this.l2w_1, tmp0_other_with_cast.l2w_1))
|
|
1394
1394
|
return false;
|
|
1395
|
-
if (!equals(this.
|
|
1395
|
+
if (!equals(this.m2w_1, tmp0_other_with_cast.m2w_1))
|
|
1396
1396
|
return false;
|
|
1397
|
-
if (!equals(this.
|
|
1397
|
+
if (!equals(this.n2w_1, tmp0_other_with_cast.n2w_1))
|
|
1398
1398
|
return false;
|
|
1399
|
-
if (!equals(this.
|
|
1399
|
+
if (!equals(this.o2w_1, tmp0_other_with_cast.o2w_1))
|
|
1400
1400
|
return false;
|
|
1401
1401
|
return true;
|
|
1402
1402
|
};
|
|
1403
1403
|
function GammaTransferFunctions(gamma) {
|
|
1404
|
-
this.
|
|
1404
|
+
this.t30_1 = gamma;
|
|
1405
1405
|
}
|
|
1406
|
-
protoOf(GammaTransferFunctions).
|
|
1407
|
-
return spow(x, this.
|
|
1406
|
+
protoOf(GammaTransferFunctions).z2z = function (x) {
|
|
1407
|
+
return spow(x, this.t30_1);
|
|
1408
1408
|
};
|
|
1409
|
-
protoOf(GammaTransferFunctions).
|
|
1410
|
-
return spow(x, 1.0 / this.
|
|
1409
|
+
protoOf(GammaTransferFunctions).a30 = function (x) {
|
|
1410
|
+
return spow(x, 1.0 / this.t30_1);
|
|
1411
1411
|
};
|
|
1412
1412
|
protoOf(GammaTransferFunctions).toString = function () {
|
|
1413
|
-
return 'GammaTransferFunctions(gamma=' + this.
|
|
1413
|
+
return 'GammaTransferFunctions(gamma=' + this.t30_1 + ')';
|
|
1414
1414
|
};
|
|
1415
1415
|
protoOf(GammaTransferFunctions).hashCode = function () {
|
|
1416
|
-
return getNumberHashCode(this.
|
|
1416
|
+
return getNumberHashCode(this.t30_1);
|
|
1417
1417
|
};
|
|
1418
1418
|
protoOf(GammaTransferFunctions).equals = function (other) {
|
|
1419
1419
|
if (this === other)
|
|
@@ -1421,16 +1421,16 @@
|
|
|
1421
1421
|
if (!(other instanceof GammaTransferFunctions))
|
|
1422
1422
|
return false;
|
|
1423
1423
|
var tmp0_other_with_cast = other instanceof GammaTransferFunctions ? other : THROW_CCE();
|
|
1424
|
-
if (!equals(this.
|
|
1424
|
+
if (!equals(this.t30_1, tmp0_other_with_cast.t30_1))
|
|
1425
1425
|
return false;
|
|
1426
1426
|
return true;
|
|
1427
1427
|
};
|
|
1428
1428
|
function LinearTransferFunctions() {
|
|
1429
1429
|
}
|
|
1430
|
-
protoOf(LinearTransferFunctions).
|
|
1430
|
+
protoOf(LinearTransferFunctions).z2z = function (x) {
|
|
1431
1431
|
return x;
|
|
1432
1432
|
};
|
|
1433
|
-
protoOf(LinearTransferFunctions).
|
|
1433
|
+
protoOf(LinearTransferFunctions).a30 = function (x) {
|
|
1434
1434
|
return x;
|
|
1435
1435
|
};
|
|
1436
1436
|
var LinearTransferFunctions_instance;
|
|
@@ -1491,40 +1491,40 @@
|
|
|
1491
1491
|
var ACES_AP1_B;
|
|
1492
1492
|
function SRGB() {
|
|
1493
1493
|
SRGB_instance = this;
|
|
1494
|
-
this.
|
|
1494
|
+
this.i2z_1 = RGBColorSpaces_getInstance().x2x_1;
|
|
1495
1495
|
}
|
|
1496
1496
|
protoOf(SRGB).equals = function (other) {
|
|
1497
|
-
return equals(RGBColorSpaces_getInstance().
|
|
1497
|
+
return equals(RGBColorSpaces_getInstance().x2x_1, other);
|
|
1498
1498
|
};
|
|
1499
1499
|
protoOf(SRGB).hashCode = function () {
|
|
1500
|
-
return hashCode(RGBColorSpaces_getInstance().
|
|
1500
|
+
return hashCode(RGBColorSpaces_getInstance().x2x_1);
|
|
1501
1501
|
};
|
|
1502
1502
|
protoOf(SRGB).toString = function () {
|
|
1503
1503
|
return 'sRGB';
|
|
1504
1504
|
};
|
|
1505
|
-
protoOf(SRGB).
|
|
1506
|
-
return this.
|
|
1505
|
+
protoOf(SRGB).h2z = function (r, g, b, alpha) {
|
|
1506
|
+
return this.i2z_1.h2z(r, g, b, alpha);
|
|
1507
1507
|
};
|
|
1508
|
-
protoOf(SRGB).
|
|
1509
|
-
return this.
|
|
1508
|
+
protoOf(SRGB).c30 = function (r, g, b, alpha) {
|
|
1509
|
+
return this.i2z_1.c30(r, g, b, alpha);
|
|
1510
1510
|
};
|
|
1511
|
-
protoOf(SRGB).
|
|
1512
|
-
return this.
|
|
1511
|
+
protoOf(SRGB).q2z = function () {
|
|
1512
|
+
return this.i2z_1.q2z();
|
|
1513
1513
|
};
|
|
1514
|
-
protoOf(SRGB).
|
|
1515
|
-
return this.
|
|
1514
|
+
protoOf(SRGB).o30 = function () {
|
|
1515
|
+
return this.i2z_1.o30();
|
|
1516
1516
|
};
|
|
1517
|
-
protoOf(SRGB).
|
|
1518
|
-
return this.
|
|
1517
|
+
protoOf(SRGB).p30 = function () {
|
|
1518
|
+
return this.i2z_1.p30();
|
|
1519
1519
|
};
|
|
1520
|
-
protoOf(SRGB).
|
|
1521
|
-
return this.
|
|
1520
|
+
protoOf(SRGB).h2x = function () {
|
|
1521
|
+
return this.i2z_1.h2x();
|
|
1522
1522
|
};
|
|
1523
|
-
protoOf(SRGB).
|
|
1524
|
-
return this.
|
|
1523
|
+
protoOf(SRGB).v1 = function () {
|
|
1524
|
+
return this.i2z_1.v1();
|
|
1525
1525
|
};
|
|
1526
|
-
protoOf(SRGB).
|
|
1527
|
-
return this.
|
|
1526
|
+
protoOf(SRGB).c2x = function (color) {
|
|
1527
|
+
return this.i2z_1.c2x(color);
|
|
1528
1528
|
};
|
|
1529
1529
|
var SRGB_instance;
|
|
1530
1530
|
function SRGB_getInstance() {
|
|
@@ -1533,17 +1533,17 @@
|
|
|
1533
1533
|
return SRGB_instance;
|
|
1534
1534
|
}
|
|
1535
1535
|
function RGBColorSpaces$SRGB$lambda($this$RGBColorSpaceImpl, it) {
|
|
1536
|
-
return it.
|
|
1536
|
+
return it.i2w();
|
|
1537
1537
|
}
|
|
1538
1538
|
function RGBColorSpaces$BT2020$lambda($this$RGBColorSpaceImpl, color) {
|
|
1539
1539
|
var tmp;
|
|
1540
1540
|
if (color instanceof RGB) {
|
|
1541
|
-
tmp = color.
|
|
1541
|
+
tmp = color.q30($this$RGBColorSpaceImpl);
|
|
1542
1542
|
} else {
|
|
1543
1543
|
if (color instanceof ICtCp) {
|
|
1544
|
-
tmp = color.
|
|
1544
|
+
tmp = color.p2z();
|
|
1545
1545
|
} else {
|
|
1546
|
-
tmp = color.
|
|
1546
|
+
tmp = color.p2w().s30($this$RGBColorSpaceImpl);
|
|
1547
1547
|
}
|
|
1548
1548
|
}
|
|
1549
1549
|
return tmp;
|
|
@@ -1551,29 +1551,29 @@
|
|
|
1551
1551
|
function RGBColorSpaces() {
|
|
1552
1552
|
RGBColorSpaces_instance = this;
|
|
1553
1553
|
var tmp = this;
|
|
1554
|
-
var tmp_0 = Illuminant_getInstance().
|
|
1554
|
+
var tmp_0 = Illuminant_getInstance().q2x_1;
|
|
1555
1555
|
var tmp_1 = SRGBTransferFunctions_instance;
|
|
1556
1556
|
var tmp_2 = get_SRGB_R();
|
|
1557
1557
|
var tmp_3 = get_SRGB_G();
|
|
1558
1558
|
var tmp_4 = get_SRGB_B();
|
|
1559
|
-
tmp.
|
|
1560
|
-
this.
|
|
1561
|
-
this.
|
|
1562
|
-
this.
|
|
1563
|
-
this.
|
|
1564
|
-
this.
|
|
1565
|
-
this.
|
|
1559
|
+
tmp.x2x_1 = new RGBColorSpaceImpl('sRGB', tmp_0, tmp_1, tmp_2, tmp_3, tmp_4, RGBColorSpaces$SRGB$lambda);
|
|
1560
|
+
this.y2x_1 = RGBColorSpace_0('Linear sRGB', Illuminant_getInstance().q2x_1, LinearTransferFunctions_instance, get_SRGB_R(), get_SRGB_G(), get_SRGB_B());
|
|
1561
|
+
this.z2x_1 = RGBColorSpace_0('ACES2065-1', get_ACES_WHITE_POINT(), LinearTransferFunctions_instance, get_ACES_AP0_R(), get_ACES_AP0_G(), get_ACES_AP0_B());
|
|
1562
|
+
this.a2y_1 = RGBColorSpace_0('ACEScc', get_ACES_WHITE_POINT(), ACESccTransferFunctions_getInstance(), get_ACES_AP1_R(), get_ACES_AP1_G(), get_ACES_AP1_B());
|
|
1563
|
+
this.b2y_1 = RGBColorSpace_0('ACEScct', get_ACES_WHITE_POINT(), ACEScctTransferFunctions_getInstance(), get_ACES_AP1_R(), get_ACES_AP1_G(), get_ACES_AP1_B());
|
|
1564
|
+
this.c2y_1 = RGBColorSpace_0('ACEScg', get_ACES_WHITE_POINT(), LinearTransferFunctions_instance, get_ACES_AP1_R(), get_ACES_AP1_G(), get_ACES_AP1_B());
|
|
1565
|
+
this.d2y_1 = RGBColorSpace_0('Adobe RGB', Illuminant_getInstance().q2x_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));
|
|
1566
1566
|
var tmp_5 = this;
|
|
1567
|
-
var tmp_6 = Illuminant_getInstance().
|
|
1567
|
+
var tmp_6 = Illuminant_getInstance().q2x_1;
|
|
1568
1568
|
var tmp_7 = BT2020TransferFunctions_getInstance();
|
|
1569
1569
|
var tmp_8 = xyY_init_$Create$(0.708, 0.292);
|
|
1570
1570
|
var tmp_9 = xyY_init_$Create$(0.17, 0.797);
|
|
1571
1571
|
var tmp_10 = xyY_init_$Create$(0.131, 0.046);
|
|
1572
|
-
tmp_5.
|
|
1573
|
-
this.
|
|
1574
|
-
this.
|
|
1575
|
-
this.
|
|
1576
|
-
this.
|
|
1572
|
+
tmp_5.e2y_1 = new RGBColorSpaceImpl('BT.2020', tmp_6, tmp_7, tmp_8, tmp_9, tmp_10, RGBColorSpaces$BT2020$lambda);
|
|
1573
|
+
this.f2y_1 = RGBColorSpace_0('BT.709', Illuminant_getInstance().q2x_1, BT709TransferFunctions_getInstance(), xyY_init_$Create$(0.64, 0.33), xyY_init_$Create$(0.3, 0.6), xyY_init_$Create$(0.15, 0.06));
|
|
1574
|
+
this.g2y_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));
|
|
1575
|
+
this.h2y_1 = RGBColorSpace_0('Display P3', Illuminant_getInstance().q2x_1, SRGBTransferFunctions_instance, xyY_init_$Create$(0.68, 0.32), xyY_init_$Create$(0.265, 0.69), xyY_init_$Create$(0.15, 0.06));
|
|
1576
|
+
this.i2y_1 = RGBColorSpace_0('ROMM RGB', Illuminant_getInstance().o2x_1, ROMMTransferFunctions_instance, xyY_init_$Create$(0.7347, 0.2653), xyY_init_$Create$(0.1596, 0.8404), xyY_init_$Create$(0.0366, 1.0E-4));
|
|
1577
1577
|
}
|
|
1578
1578
|
var RGBColorSpaces_instance;
|
|
1579
1579
|
function RGBColorSpaces_getInstance() {
|
|
@@ -1582,39 +1582,39 @@
|
|
|
1582
1582
|
return RGBColorSpaces_instance;
|
|
1583
1583
|
}
|
|
1584
1584
|
function RGBColorSpaceImpl(name, whitePoint, transferFunctions, r, g, b, convertImpl) {
|
|
1585
|
-
this.
|
|
1586
|
-
this.
|
|
1587
|
-
this.
|
|
1588
|
-
this.
|
|
1589
|
-
this.
|
|
1590
|
-
this.
|
|
1591
|
-
this.
|
|
1592
|
-
this.
|
|
1593
|
-
this.
|
|
1594
|
-
this.
|
|
1585
|
+
this.u30_1 = name;
|
|
1586
|
+
this.v30_1 = whitePoint;
|
|
1587
|
+
this.w30_1 = transferFunctions;
|
|
1588
|
+
this.x30_1 = r;
|
|
1589
|
+
this.y30_1 = g;
|
|
1590
|
+
this.z30_1 = b;
|
|
1591
|
+
this.a31_1 = convertImpl;
|
|
1592
|
+
this.b31_1 = zeroOneComponentInfo('RGB');
|
|
1593
|
+
this.c31_1 = _Matrix___get_rowMajor__impl__vmgxkq(rgbToXyzMatrix(this.v30_1, this.x30_1, this.y30_1, this.z30_1));
|
|
1594
|
+
this.d31_1 = _Matrix___get_rowMajor__impl__vmgxkq(inverse(_Matrix___init__impl__q3kp4w(this.c31_1)));
|
|
1595
1595
|
}
|
|
1596
|
-
protoOf(RGBColorSpaceImpl).
|
|
1597
|
-
return this.
|
|
1596
|
+
protoOf(RGBColorSpaceImpl).v1 = function () {
|
|
1597
|
+
return this.u30_1;
|
|
1598
1598
|
};
|
|
1599
|
-
protoOf(RGBColorSpaceImpl).
|
|
1600
|
-
return this.
|
|
1599
|
+
protoOf(RGBColorSpaceImpl).h2x = function () {
|
|
1600
|
+
return this.v30_1;
|
|
1601
1601
|
};
|
|
1602
|
-
protoOf(RGBColorSpaceImpl).
|
|
1603
|
-
return this.
|
|
1602
|
+
protoOf(RGBColorSpaceImpl).q2z = function () {
|
|
1603
|
+
return this.w30_1;
|
|
1604
1604
|
};
|
|
1605
|
-
protoOf(RGBColorSpaceImpl).
|
|
1606
|
-
return this.
|
|
1605
|
+
protoOf(RGBColorSpaceImpl).c2x = function (color) {
|
|
1606
|
+
return this.a31_1(this, color);
|
|
1607
1607
|
};
|
|
1608
|
-
protoOf(RGBColorSpaceImpl).
|
|
1609
|
-
return this.
|
|
1608
|
+
protoOf(RGBColorSpaceImpl).o30 = function () {
|
|
1609
|
+
return this.c31_1;
|
|
1610
1610
|
};
|
|
1611
|
-
protoOf(RGBColorSpaceImpl).
|
|
1612
|
-
return this.
|
|
1611
|
+
protoOf(RGBColorSpaceImpl).p30 = function () {
|
|
1612
|
+
return this.d31_1;
|
|
1613
1613
|
};
|
|
1614
1614
|
protoOf(RGBColorSpaceImpl).toString = function () {
|
|
1615
|
-
return this.
|
|
1615
|
+
return this.u30_1;
|
|
1616
1616
|
};
|
|
1617
|
-
protoOf(RGBColorSpaceImpl).
|
|
1617
|
+
protoOf(RGBColorSpaceImpl).h2z = function (r, g, b, alpha) {
|
|
1618
1618
|
return new RGB(r, g, b, alpha, this);
|
|
1619
1619
|
};
|
|
1620
1620
|
protoOf(RGBColorSpaceImpl).equals = function (other) {
|
|
@@ -1622,42 +1622,42 @@
|
|
|
1622
1622
|
return true;
|
|
1623
1623
|
if (!(!(other == null) ? isInterface(other, RGBColorSpace) : false))
|
|
1624
1624
|
return false;
|
|
1625
|
-
if (!(this.
|
|
1625
|
+
if (!(this.u30_1 === other.v1()))
|
|
1626
1626
|
return false;
|
|
1627
|
-
if (!this.
|
|
1627
|
+
if (!this.v30_1.equals(other.h2x()))
|
|
1628
1628
|
return false;
|
|
1629
|
-
if (!equals(this.
|
|
1629
|
+
if (!equals(this.w30_1, other.q2z()))
|
|
1630
1630
|
return false;
|
|
1631
1631
|
if (other instanceof RGBColorSpaceImpl) {
|
|
1632
|
-
if (!this.
|
|
1632
|
+
if (!this.x30_1.equals(other.x30_1))
|
|
1633
1633
|
return false;
|
|
1634
|
-
if (!this.
|
|
1634
|
+
if (!this.y30_1.equals(other.y30_1))
|
|
1635
1635
|
return false;
|
|
1636
|
-
if (!this.
|
|
1636
|
+
if (!this.z30_1.equals(other.z30_1))
|
|
1637
1637
|
return false;
|
|
1638
1638
|
} else {
|
|
1639
|
-
if (!contentEquals(this.
|
|
1639
|
+
if (!contentEquals(this.c31_1, other.o30()))
|
|
1640
1640
|
return false;
|
|
1641
|
-
if (!contentEquals(this.
|
|
1641
|
+
if (!contentEquals(this.d31_1, other.p30()))
|
|
1642
1642
|
return false;
|
|
1643
1643
|
}
|
|
1644
1644
|
return true;
|
|
1645
1645
|
};
|
|
1646
1646
|
protoOf(RGBColorSpaceImpl).hashCode = function () {
|
|
1647
|
-
var result = getStringHashCode(this.
|
|
1648
|
-
result = imul(31, result) + this.r30_1.hashCode() | 0;
|
|
1649
|
-
result = imul(31, result) + hashCode(this.s30_1) | 0;
|
|
1650
|
-
result = imul(31, result) + this.t30_1.hashCode() | 0;
|
|
1651
|
-
result = imul(31, result) + this.u30_1.hashCode() | 0;
|
|
1647
|
+
var result = getStringHashCode(this.u30_1);
|
|
1652
1648
|
result = imul(31, result) + this.v30_1.hashCode() | 0;
|
|
1649
|
+
result = imul(31, result) + hashCode(this.w30_1) | 0;
|
|
1650
|
+
result = imul(31, result) + this.x30_1.hashCode() | 0;
|
|
1651
|
+
result = imul(31, result) + this.y30_1.hashCode() | 0;
|
|
1652
|
+
result = imul(31, result) + this.z30_1.hashCode() | 0;
|
|
1653
1653
|
return result;
|
|
1654
1654
|
};
|
|
1655
1655
|
function SRGBTransferFunctions() {
|
|
1656
1656
|
}
|
|
1657
|
-
protoOf(SRGBTransferFunctions).
|
|
1657
|
+
protoOf(SRGBTransferFunctions).a30 = function (x) {
|
|
1658
1658
|
return x <= 0.0031308 ? x * 12.92 : 1.055 * spow(x, 1 / 2.4) - 0.055;
|
|
1659
1659
|
};
|
|
1660
|
-
protoOf(SRGBTransferFunctions).
|
|
1660
|
+
protoOf(SRGBTransferFunctions).z2z = function (x) {
|
|
1661
1661
|
return x <= 0.04045 ? x / 12.92 : spow_0((x + 0.055) / 1.055, 2.4);
|
|
1662
1662
|
};
|
|
1663
1663
|
var SRGBTransferFunctions_instance;
|
|
@@ -1670,18 +1670,18 @@
|
|
|
1670
1670
|
}
|
|
1671
1671
|
function ACESccTransferFunctions() {
|
|
1672
1672
|
ACESccTransferFunctions_instance = this;
|
|
1673
|
-
this.
|
|
1674
|
-
this.
|
|
1675
|
-
this.
|
|
1673
|
+
this.e31_1 = 3.0517578125E-5;
|
|
1674
|
+
this.f31_1 = 1.52587890625E-5;
|
|
1675
|
+
this.g31_1 = -0.3013698630136986;
|
|
1676
1676
|
var tmp = this;
|
|
1677
1677
|
// Inline function 'kotlin.math.log2' call
|
|
1678
|
-
tmp.
|
|
1678
|
+
tmp.h31_1 = (log2(65504.0) + 9.72) / 17.52;
|
|
1679
1679
|
}
|
|
1680
|
-
protoOf(ACESccTransferFunctions).
|
|
1680
|
+
protoOf(ACESccTransferFunctions).z2z = function (x) {
|
|
1681
1681
|
var tmp;
|
|
1682
1682
|
if (x <= -0.3013698630136986) {
|
|
1683
1683
|
tmp = (spow_0(2.0, x * 17.52 - 9.72) - 1.52587890625E-5) * 2.0;
|
|
1684
|
-
} else if (x < this.
|
|
1684
|
+
} else if (x < this.h31_1) {
|
|
1685
1685
|
// Inline function 'kotlin.math.pow' call
|
|
1686
1686
|
var x_0 = x * 17.52 - 9.72;
|
|
1687
1687
|
tmp = Math.pow(2.0, x_0);
|
|
@@ -1690,7 +1690,7 @@
|
|
|
1690
1690
|
}
|
|
1691
1691
|
return tmp;
|
|
1692
1692
|
};
|
|
1693
|
-
protoOf(ACESccTransferFunctions).
|
|
1693
|
+
protoOf(ACESccTransferFunctions).a30 = function (x) {
|
|
1694
1694
|
var tmp;
|
|
1695
1695
|
if (x < 3.0517578125E-5) {
|
|
1696
1696
|
// Inline function 'kotlin.math.log2' call
|
|
@@ -1710,17 +1710,17 @@
|
|
|
1710
1710
|
}
|
|
1711
1711
|
function ACEScctTransferFunctions() {
|
|
1712
1712
|
ACEScctTransferFunctions_instance = this;
|
|
1713
|
-
this.
|
|
1714
|
-
this.
|
|
1713
|
+
this.i31_1 = 10.5402377416545;
|
|
1714
|
+
this.j31_1 = 0.0729055341958355;
|
|
1715
1715
|
var tmp = this;
|
|
1716
1716
|
// Inline function 'kotlin.math.log2' call
|
|
1717
|
-
tmp.
|
|
1717
|
+
tmp.k31_1 = (log2(65504.0) + 9.72) / 17.52;
|
|
1718
1718
|
}
|
|
1719
|
-
protoOf(ACEScctTransferFunctions).
|
|
1719
|
+
protoOf(ACEScctTransferFunctions).z2z = function (x) {
|
|
1720
1720
|
var tmp;
|
|
1721
1721
|
if (x <= 0.155251141552511) {
|
|
1722
1722
|
tmp = (x - 0.0729055341958355) / 10.5402377416545;
|
|
1723
|
-
} else if (x < this.
|
|
1723
|
+
} else if (x < this.k31_1) {
|
|
1724
1724
|
// Inline function 'kotlin.math.pow' call
|
|
1725
1725
|
var x_0 = x * 17.52 - 9.72;
|
|
1726
1726
|
tmp = Math.pow(2.0, x_0);
|
|
@@ -1729,7 +1729,7 @@
|
|
|
1729
1729
|
}
|
|
1730
1730
|
return tmp;
|
|
1731
1731
|
};
|
|
1732
|
-
protoOf(ACEScctTransferFunctions).
|
|
1732
|
+
protoOf(ACEScctTransferFunctions).a30 = function (x) {
|
|
1733
1733
|
var tmp;
|
|
1734
1734
|
if (x < 0.0078125) {
|
|
1735
1735
|
tmp = 10.5402377416545 * x + 0.0729055341958355;
|
|
@@ -1747,16 +1747,16 @@
|
|
|
1747
1747
|
}
|
|
1748
1748
|
function BT2020TransferFunctions() {
|
|
1749
1749
|
BT2020TransferFunctions_instance = this;
|
|
1750
|
-
this.
|
|
1751
|
-
this.
|
|
1750
|
+
this.l31_1 = 1.0993;
|
|
1751
|
+
this.m31_1 = 0.0181;
|
|
1752
1752
|
var tmp = this;
|
|
1753
1753
|
// Inline function 'kotlin.math.pow' call
|
|
1754
|
-
tmp.
|
|
1754
|
+
tmp.n31_1 = 1.0993 * Math.pow(0.0181, 0.45) - (1.0993 - 1);
|
|
1755
1755
|
}
|
|
1756
|
-
protoOf(BT2020TransferFunctions).
|
|
1757
|
-
return numberToDouble(x < this.
|
|
1756
|
+
protoOf(BT2020TransferFunctions).z2z = function (x) {
|
|
1757
|
+
return numberToDouble(x < this.n31_1 ? x / 4.5 : spow_0((x + (1.0993 - 1)) / 1.0993, 1 / 0.45));
|
|
1758
1758
|
};
|
|
1759
|
-
protoOf(BT2020TransferFunctions).
|
|
1759
|
+
protoOf(BT2020TransferFunctions).a30 = function (x) {
|
|
1760
1760
|
return x < 0.0181 ? 4.5 * x : 1.0993 * spow(x, 0.45) - (1.0993 - 1);
|
|
1761
1761
|
};
|
|
1762
1762
|
var BT2020TransferFunctions_instance;
|
|
@@ -1767,12 +1767,12 @@
|
|
|
1767
1767
|
}
|
|
1768
1768
|
function BT709TransferFunctions() {
|
|
1769
1769
|
BT709TransferFunctions_instance = this;
|
|
1770
|
-
this.
|
|
1770
|
+
this.o31_1 = 1.099 * spow_0(0.018, 0.45) - 0.099;
|
|
1771
1771
|
}
|
|
1772
|
-
protoOf(BT709TransferFunctions).
|
|
1773
|
-
return numberToDouble(x < this.
|
|
1772
|
+
protoOf(BT709TransferFunctions).z2z = function (x) {
|
|
1773
|
+
return numberToDouble(x < this.o31_1 ? x / 4.5 : spow_0((x + 0.099) / 1.099, 1 / 0.45));
|
|
1774
1774
|
};
|
|
1775
|
-
protoOf(BT709TransferFunctions).
|
|
1775
|
+
protoOf(BT709TransferFunctions).a30 = function (x) {
|
|
1776
1776
|
return x < 0.018 ? 4.5 * x : 1.099 * spow(x, 0.45) - 0.099;
|
|
1777
1777
|
};
|
|
1778
1778
|
var BT709TransferFunctions_instance;
|
|
@@ -1782,12 +1782,12 @@
|
|
|
1782
1782
|
return BT709TransferFunctions_instance;
|
|
1783
1783
|
}
|
|
1784
1784
|
function ROMMTransferFunctions() {
|
|
1785
|
-
this.
|
|
1785
|
+
this.p31_1 = 0.001953;
|
|
1786
1786
|
}
|
|
1787
|
-
protoOf(ROMMTransferFunctions).
|
|
1787
|
+
protoOf(ROMMTransferFunctions).z2z = function (x) {
|
|
1788
1788
|
return x < 16 * 0.001953 ? x / 16.0 : spow(x, 1.8);
|
|
1789
1789
|
};
|
|
1790
|
-
protoOf(ROMMTransferFunctions).
|
|
1790
|
+
protoOf(ROMMTransferFunctions).a30 = function (x) {
|
|
1791
1791
|
return x < 0.001953 ? x * 16.0 : spow(x, 1.0 / 1.8);
|
|
1792
1792
|
};
|
|
1793
1793
|
var ROMMTransferFunctions_instance;
|
|
@@ -1796,13 +1796,13 @@
|
|
|
1796
1796
|
}
|
|
1797
1797
|
function rgbToXyzMatrix(whitePoint, r, g, b) {
|
|
1798
1798
|
_init_properties_RGBColorSpaces_kt__nc9fsz();
|
|
1799
|
-
var primaries = _Matrix___init__impl__q3kp4w_0(r.
|
|
1800
|
-
var wp = whitePoint.
|
|
1799
|
+
var primaries = _Matrix___init__impl__q3kp4w_0(r.e30_1, g.e30_1, b.e30_1, r.f30_1, g.f30_1, b.f30_1, r.q31(), g.q31(), b.q31());
|
|
1800
|
+
var wp = whitePoint.c2z_1;
|
|
1801
1801
|
var tmp0 = inverse(primaries);
|
|
1802
|
-
var tmp2 = wp.
|
|
1803
|
-
var tmp4 = wp.
|
|
1802
|
+
var tmp2 = wp.h30();
|
|
1803
|
+
var tmp4 = wp.g30_1;
|
|
1804
1804
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
1805
|
-
var v2 = wp.
|
|
1805
|
+
var v2 = wp.i30();
|
|
1806
1806
|
var tmp0_0 = Matrix__get_impl_xogbpk(tmp0, 0, 0) * tmp2 + Matrix__get_impl_xogbpk(tmp0, 1, 0) * tmp4 + Matrix__get_impl_xogbpk(tmp0, 2, 0) * v2;
|
|
1807
1807
|
var tmp2_0 = Matrix__get_impl_xogbpk(tmp0, 0, 1) * tmp2 + Matrix__get_impl_xogbpk(tmp0, 1, 1) * tmp4 + Matrix__get_impl_xogbpk(tmp0, 2, 1) * v2;
|
|
1808
1808
|
var z = Matrix__get_impl_xogbpk(tmp0, 0, 2) * tmp2 + Matrix__get_impl_xogbpk(tmp0, 1, 2) * tmp4 + Matrix__get_impl_xogbpk(tmp0, 2, 2) * v2;
|
|
@@ -1812,9 +1812,9 @@
|
|
|
1812
1812
|
_init_properties_RGBColorSpaces_kt__nc9fsz();
|
|
1813
1813
|
var tmp;
|
|
1814
1814
|
if (color instanceof RGB) {
|
|
1815
|
-
tmp = color.
|
|
1815
|
+
tmp = color.q30($this$RGBColorSpaceImpl);
|
|
1816
1816
|
} else {
|
|
1817
|
-
tmp = color.
|
|
1817
|
+
tmp = color.p2w().s30($this$RGBColorSpaceImpl);
|
|
1818
1818
|
}
|
|
1819
1819
|
return tmp;
|
|
1820
1820
|
}
|
|
@@ -1842,16 +1842,16 @@
|
|
|
1842
1842
|
}
|
|
1843
1843
|
function Companion_3() {
|
|
1844
1844
|
Companion_instance_3 = this;
|
|
1845
|
-
this.
|
|
1845
|
+
this.r31_1 = threeComponentInfo('R', 0.0, 255.0, 'G', 0.0, 255.0, 'B', 0.0, 255.0);
|
|
1846
1846
|
}
|
|
1847
|
-
protoOf(Companion_3).
|
|
1847
|
+
protoOf(Companion_3).v1 = function () {
|
|
1848
1848
|
return 'RGBInt';
|
|
1849
1849
|
};
|
|
1850
|
-
protoOf(Companion_3).
|
|
1851
|
-
return color.
|
|
1850
|
+
protoOf(Companion_3).s31 = function (color) {
|
|
1851
|
+
return color.i2w().j2y();
|
|
1852
1852
|
};
|
|
1853
|
-
protoOf(Companion_3).
|
|
1854
|
-
return new RGBInt(this.
|
|
1853
|
+
protoOf(Companion_3).c2x = function (color) {
|
|
1854
|
+
return new RGBInt(this.s31(color));
|
|
1855
1855
|
};
|
|
1856
1856
|
var Companion_instance_3;
|
|
1857
1857
|
function Companion_getInstance_3() {
|
|
@@ -1983,7 +1983,7 @@
|
|
|
1983
1983
|
return (_UByte___get_data__impl__jof9qr(this_0) & 255) / 255.0;
|
|
1984
1984
|
}
|
|
1985
1985
|
function RGBInt__toSRGB_impl_m0acyy($this) {
|
|
1986
|
-
return Companion_getInstance_2().
|
|
1986
|
+
return Companion_getInstance_2().h2z(_RGBInt___get_redFloat__impl__lnt6cx($this), _RGBInt___get_greenFloat__impl__opq1mn($this), _RGBInt___get_blueFloat__impl__jt6mw2($this), _RGBInt___get_alpha__impl__yl2tay($this));
|
|
1987
1987
|
}
|
|
1988
1988
|
function RGBInt__toArray_impl_73rlu9($this) {
|
|
1989
1989
|
// Inline function 'kotlin.UByte.toFloat' call
|
|
@@ -2022,59 +2022,59 @@
|
|
|
2022
2022
|
function RGBInt__equals_impl_qmmpmc($this, other) {
|
|
2023
2023
|
if (!(other instanceof RGBInt))
|
|
2024
2024
|
return false;
|
|
2025
|
-
if (!($this === (other instanceof RGBInt ? other.
|
|
2025
|
+
if (!($this === (other instanceof RGBInt ? other.r30_1 : THROW_CCE())))
|
|
2026
2026
|
return false;
|
|
2027
2027
|
return true;
|
|
2028
2028
|
}
|
|
2029
2029
|
function RGBInt(argb) {
|
|
2030
2030
|
Companion_getInstance_3();
|
|
2031
|
-
this.
|
|
2031
|
+
this.r30_1 = argb;
|
|
2032
2032
|
}
|
|
2033
|
-
protoOf(RGBInt).
|
|
2034
|
-
return _RGBInt___get_alpha__impl__yl2tay(this.
|
|
2033
|
+
protoOf(RGBInt).g2w = function () {
|
|
2034
|
+
return _RGBInt___get_alpha__impl__yl2tay(this.r30_1);
|
|
2035
2035
|
};
|
|
2036
|
-
protoOf(RGBInt).
|
|
2037
|
-
return _RGBInt___get_space__impl__emgnsy(this.
|
|
2036
|
+
protoOf(RGBInt).h2w = function () {
|
|
2037
|
+
return _RGBInt___get_space__impl__emgnsy(this.r30_1);
|
|
2038
2038
|
};
|
|
2039
|
-
protoOf(RGBInt).
|
|
2040
|
-
return RGBInt__toSRGB_impl_m0acyy(this.
|
|
2039
|
+
protoOf(RGBInt).i2w = function () {
|
|
2040
|
+
return RGBInt__toSRGB_impl_m0acyy(this.r30_1);
|
|
2041
2041
|
};
|
|
2042
|
-
protoOf(RGBInt).
|
|
2043
|
-
return RGBInt__toArray_impl_73rlu9(this.
|
|
2042
|
+
protoOf(RGBInt).l4 = function () {
|
|
2043
|
+
return RGBInt__toArray_impl_73rlu9(this.r30_1);
|
|
2044
2044
|
};
|
|
2045
2045
|
protoOf(RGBInt).toString = function () {
|
|
2046
|
-
return RGBInt__toString_impl_cf5r29(this.
|
|
2046
|
+
return RGBInt__toString_impl_cf5r29(this.r30_1);
|
|
2047
2047
|
};
|
|
2048
2048
|
protoOf(RGBInt).hashCode = function () {
|
|
2049
|
-
return RGBInt__hashCode_impl_y6bnv4(this.
|
|
2049
|
+
return RGBInt__hashCode_impl_y6bnv4(this.r30_1);
|
|
2050
2050
|
};
|
|
2051
2051
|
protoOf(RGBInt).equals = function (other) {
|
|
2052
|
-
return RGBInt__equals_impl_qmmpmc(this.
|
|
2052
|
+
return RGBInt__equals_impl_qmmpmc(this.r30_1, other);
|
|
2053
2053
|
};
|
|
2054
2054
|
function Companion_4() {
|
|
2055
2055
|
Companion_instance_4 = this;
|
|
2056
|
-
this.
|
|
2056
|
+
this.t31_1 = XYZColorSpaces_getInstance().i2x_1;
|
|
2057
2057
|
}
|
|
2058
2058
|
protoOf(Companion_4).hashCode = function () {
|
|
2059
|
-
return hashCode(XYZColorSpaces_getInstance().
|
|
2059
|
+
return hashCode(XYZColorSpaces_getInstance().i2x_1);
|
|
2060
2060
|
};
|
|
2061
2061
|
protoOf(Companion_4).equals = function (other) {
|
|
2062
|
-
return equals(XYZColorSpaces_getInstance().
|
|
2062
|
+
return equals(XYZColorSpaces_getInstance().i2x_1, other);
|
|
2063
2063
|
};
|
|
2064
|
-
protoOf(Companion_4).
|
|
2065
|
-
return this.
|
|
2064
|
+
protoOf(Companion_4).h2z = function (x, y, z, alpha) {
|
|
2065
|
+
return this.t31_1.h2z(x, y, z, alpha);
|
|
2066
2066
|
};
|
|
2067
|
-
protoOf(Companion_4).
|
|
2068
|
-
return this.
|
|
2067
|
+
protoOf(Companion_4).c30 = function (x, y, z, alpha) {
|
|
2068
|
+
return this.t31_1.c30(x, y, z, alpha);
|
|
2069
2069
|
};
|
|
2070
|
-
protoOf(Companion_4).
|
|
2071
|
-
return this.
|
|
2070
|
+
protoOf(Companion_4).h2x = function () {
|
|
2071
|
+
return this.t31_1.h2x();
|
|
2072
2072
|
};
|
|
2073
|
-
protoOf(Companion_4).
|
|
2074
|
-
return this.
|
|
2073
|
+
protoOf(Companion_4).v1 = function () {
|
|
2074
|
+
return this.t31_1.v1();
|
|
2075
2075
|
};
|
|
2076
|
-
protoOf(Companion_4).
|
|
2077
|
-
return this.
|
|
2076
|
+
protoOf(Companion_4).c2x = function (color) {
|
|
2077
|
+
return this.t31_1.c2x(color);
|
|
2078
2078
|
};
|
|
2079
2079
|
var Companion_instance_4;
|
|
2080
2080
|
function Companion_getInstance_4() {
|
|
@@ -2083,17 +2083,17 @@
|
|
|
2083
2083
|
return Companion_instance_4;
|
|
2084
2084
|
}
|
|
2085
2085
|
function adaptToM($this, space, m, mi) {
|
|
2086
|
-
if (space.
|
|
2086
|
+
if (space.h2x().equals($this.v2w_1.h2x()))
|
|
2087
2087
|
return $this;
|
|
2088
|
-
var transform = chromaticAdaptationMatrix(space, $this.
|
|
2089
|
-
var tmp2 = $this.
|
|
2090
|
-
var tmp4 = $this.
|
|
2088
|
+
var transform = chromaticAdaptationMatrix(space, $this.v2w_1.h2x().c2z_1, m, mi);
|
|
2089
|
+
var tmp2 = $this.r2w_1;
|
|
2090
|
+
var tmp4 = $this.s2w_1;
|
|
2091
2091
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
2092
|
-
var v2 = $this.
|
|
2092
|
+
var v2 = $this.t2w_1;
|
|
2093
2093
|
var tmp0 = Matrix__get_impl_xogbpk(transform, 0, 0) * tmp2 + Matrix__get_impl_xogbpk(transform, 1, 0) * tmp4 + Matrix__get_impl_xogbpk(transform, 2, 0) * v2;
|
|
2094
2094
|
var tmp2_0 = Matrix__get_impl_xogbpk(transform, 0, 1) * tmp2 + Matrix__get_impl_xogbpk(transform, 1, 1) * tmp4 + Matrix__get_impl_xogbpk(transform, 2, 1) * v2;
|
|
2095
2095
|
var zz = Matrix__get_impl_xogbpk(transform, 0, 2) * tmp2 + Matrix__get_impl_xogbpk(transform, 1, 2) * tmp4 + Matrix__get_impl_xogbpk(transform, 2, 2) * v2;
|
|
2096
|
-
return space.
|
|
2096
|
+
return space.h2z(tmp0, tmp2_0, zz, $this.u2w_1);
|
|
2097
2097
|
}
|
|
2098
2098
|
function toLAB$f(t) {
|
|
2099
2099
|
var tmp;
|
|
@@ -2107,71 +2107,71 @@
|
|
|
2107
2107
|
}
|
|
2108
2108
|
function XYZ(x, y, z, alpha, space) {
|
|
2109
2109
|
Companion_getInstance_4();
|
|
2110
|
-
this.
|
|
2111
|
-
this.
|
|
2112
|
-
this.
|
|
2113
|
-
this.
|
|
2114
|
-
this.
|
|
2110
|
+
this.r2w_1 = x;
|
|
2111
|
+
this.s2w_1 = y;
|
|
2112
|
+
this.t2w_1 = z;
|
|
2113
|
+
this.u2w_1 = alpha;
|
|
2114
|
+
this.v2w_1 = space;
|
|
2115
2115
|
}
|
|
2116
|
-
protoOf(XYZ).
|
|
2117
|
-
return this.
|
|
2116
|
+
protoOf(XYZ).g2w = function () {
|
|
2117
|
+
return this.u2w_1;
|
|
2118
2118
|
};
|
|
2119
|
-
protoOf(XYZ).
|
|
2120
|
-
return this.
|
|
2119
|
+
protoOf(XYZ).h2w = function () {
|
|
2120
|
+
return this.v2w_1;
|
|
2121
2121
|
};
|
|
2122
|
-
protoOf(XYZ).
|
|
2122
|
+
protoOf(XYZ).k2x = function (space) {
|
|
2123
2123
|
return adaptToM(this, space, get_CAT02_XYZ_TO_LMS(), get_CAT02_LMS_TO_XYZ());
|
|
2124
2124
|
};
|
|
2125
|
-
protoOf(XYZ).
|
|
2126
|
-
var _destruct__k2r9zo = this.
|
|
2127
|
-
var x = _destruct__k2r9zo.
|
|
2128
|
-
var y = _destruct__k2r9zo.
|
|
2129
|
-
var z = _destruct__k2r9zo.
|
|
2130
|
-
var f = space.
|
|
2125
|
+
protoOf(XYZ).s30 = function (space) {
|
|
2126
|
+
var _destruct__k2r9zo = this.k2x(XYZColorSpace_0(space.h2x()));
|
|
2127
|
+
var x = _destruct__k2r9zo.rd();
|
|
2128
|
+
var y = _destruct__k2r9zo.sd();
|
|
2129
|
+
var z = _destruct__k2r9zo.u31();
|
|
2130
|
+
var f = space.q2z();
|
|
2131
2131
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
2132
|
-
var this_0 = _Matrix___init__impl__q3kp4w(space.
|
|
2132
|
+
var this_0 = _Matrix___init__impl__q3kp4w(space.p30());
|
|
2133
2133
|
var tmp0 = Matrix__get_impl_xogbpk(this_0, 0, 0) * x + Matrix__get_impl_xogbpk(this_0, 1, 0) * y + Matrix__get_impl_xogbpk(this_0, 2, 0) * z;
|
|
2134
2134
|
var tmp2 = Matrix__get_impl_xogbpk(this_0, 0, 1) * x + Matrix__get_impl_xogbpk(this_0, 1, 1) * y + Matrix__get_impl_xogbpk(this_0, 2, 1) * z;
|
|
2135
2135
|
var b = Matrix__get_impl_xogbpk(this_0, 0, 2) * x + Matrix__get_impl_xogbpk(this_0, 1, 2) * y + Matrix__get_impl_xogbpk(this_0, 2, 2) * z;
|
|
2136
|
-
return space.
|
|
2136
|
+
return space.h2z(f.a30(tmp0), f.a30(tmp2), f.a30(b), this.u2w_1);
|
|
2137
2137
|
};
|
|
2138
|
-
protoOf(XYZ).
|
|
2139
|
-
return this.
|
|
2138
|
+
protoOf(XYZ).i2w = function () {
|
|
2139
|
+
return this.s30(RGBColorSpaces_getInstance().x2x_1);
|
|
2140
2140
|
};
|
|
2141
|
-
protoOf(XYZ).
|
|
2142
|
-
var fx = toLAB$f(this.
|
|
2143
|
-
var fy = toLAB$f(this.
|
|
2144
|
-
var fz = toLAB$f(this.
|
|
2141
|
+
protoOf(XYZ).q2w = function () {
|
|
2142
|
+
var fx = toLAB$f(this.r2w_1 / this.v2w_1.h2x().c2z_1.h30());
|
|
2143
|
+
var fy = toLAB$f(this.s2w_1 / this.v2w_1.h2x().c2z_1.g30_1);
|
|
2144
|
+
var fz = toLAB$f(this.t2w_1 / this.v2w_1.h2x().c2z_1.i30());
|
|
2145
2145
|
var l = 116 * fy - 16;
|
|
2146
2146
|
var a = 500 * (fx - fy);
|
|
2147
2147
|
var b = 200 * (fy - fz);
|
|
2148
|
-
return LABColorSpace_0(this.
|
|
2148
|
+
return LABColorSpace_0(this.v2w_1.h2x()).c30(l, a, b, this.u2w_1);
|
|
2149
2149
|
};
|
|
2150
|
-
protoOf(XYZ).
|
|
2150
|
+
protoOf(XYZ).p2w = function () {
|
|
2151
2151
|
return this;
|
|
2152
2152
|
};
|
|
2153
|
-
protoOf(XYZ).
|
|
2153
|
+
protoOf(XYZ).l4 = function () {
|
|
2154
2154
|
// Inline function 'kotlin.floatArrayOf' call
|
|
2155
|
-
return new Float32Array([this.
|
|
2155
|
+
return new Float32Array([this.r2w_1, this.s2w_1, this.t2w_1, this.u2w_1]);
|
|
2156
2156
|
};
|
|
2157
|
-
protoOf(XYZ).
|
|
2158
|
-
return this.
|
|
2157
|
+
protoOf(XYZ).rd = function () {
|
|
2158
|
+
return this.r2w_1;
|
|
2159
2159
|
};
|
|
2160
|
-
protoOf(XYZ).
|
|
2161
|
-
return this.
|
|
2160
|
+
protoOf(XYZ).sd = function () {
|
|
2161
|
+
return this.s2w_1;
|
|
2162
2162
|
};
|
|
2163
|
-
protoOf(XYZ).
|
|
2164
|
-
return this.
|
|
2163
|
+
protoOf(XYZ).u31 = function () {
|
|
2164
|
+
return this.t2w_1;
|
|
2165
2165
|
};
|
|
2166
2166
|
protoOf(XYZ).toString = function () {
|
|
2167
|
-
return 'XYZ(x=' + this.
|
|
2167
|
+
return 'XYZ(x=' + this.r2w_1 + ', y=' + this.s2w_1 + ', z=' + this.t2w_1 + ', alpha=' + this.u2w_1 + ', space=' + toString(this.v2w_1) + ')';
|
|
2168
2168
|
};
|
|
2169
2169
|
protoOf(XYZ).hashCode = function () {
|
|
2170
|
-
var result = getNumberHashCode(this.
|
|
2171
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2172
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2173
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2174
|
-
result = imul(result, 31) + hashCode(this.
|
|
2170
|
+
var result = getNumberHashCode(this.r2w_1);
|
|
2171
|
+
result = imul(result, 31) + getNumberHashCode(this.s2w_1) | 0;
|
|
2172
|
+
result = imul(result, 31) + getNumberHashCode(this.t2w_1) | 0;
|
|
2173
|
+
result = imul(result, 31) + getNumberHashCode(this.u2w_1) | 0;
|
|
2174
|
+
result = imul(result, 31) + hashCode(this.v2w_1) | 0;
|
|
2175
2175
|
return result;
|
|
2176
2176
|
};
|
|
2177
2177
|
protoOf(XYZ).equals = function (other) {
|
|
@@ -2180,15 +2180,15 @@
|
|
|
2180
2180
|
if (!(other instanceof XYZ))
|
|
2181
2181
|
return false;
|
|
2182
2182
|
var tmp0_other_with_cast = other instanceof XYZ ? other : THROW_CCE();
|
|
2183
|
-
if (!equals(this.
|
|
2183
|
+
if (!equals(this.r2w_1, tmp0_other_with_cast.r2w_1))
|
|
2184
2184
|
return false;
|
|
2185
|
-
if (!equals(this.
|
|
2185
|
+
if (!equals(this.s2w_1, tmp0_other_with_cast.s2w_1))
|
|
2186
2186
|
return false;
|
|
2187
|
-
if (!equals(this.
|
|
2187
|
+
if (!equals(this.t2w_1, tmp0_other_with_cast.t2w_1))
|
|
2188
2188
|
return false;
|
|
2189
|
-
if (!equals(this.
|
|
2189
|
+
if (!equals(this.u2w_1, tmp0_other_with_cast.u2w_1))
|
|
2190
2190
|
return false;
|
|
2191
|
-
if (!equals(this.
|
|
2191
|
+
if (!equals(this.v2w_1, tmp0_other_with_cast.v2w_1))
|
|
2192
2192
|
return false;
|
|
2193
2193
|
return true;
|
|
2194
2194
|
};
|
|
@@ -2196,8 +2196,8 @@
|
|
|
2196
2196
|
}
|
|
2197
2197
|
function XYZColorSpaces() {
|
|
2198
2198
|
XYZColorSpaces_instance = this;
|
|
2199
|
-
this.
|
|
2200
|
-
this.
|
|
2199
|
+
this.i2x_1 = new XYZColorSpaceImpl(Illuminant_getInstance().q2x_1);
|
|
2200
|
+
this.j2x_1 = new XYZColorSpaceImpl(Illuminant_getInstance().o2x_1);
|
|
2201
2201
|
}
|
|
2202
2202
|
var XYZColorSpaces_instance;
|
|
2203
2203
|
function XYZColorSpaces_getInstance() {
|
|
@@ -2206,42 +2206,42 @@
|
|
|
2206
2206
|
return XYZColorSpaces_instance;
|
|
2207
2207
|
}
|
|
2208
2208
|
function XYZColorSpace_0(whitePoint) {
|
|
2209
|
-
return whitePoint.equals(Illuminant_getInstance().
|
|
2209
|
+
return whitePoint.equals(Illuminant_getInstance().q2x_1) ? XYZColorSpaces_getInstance().i2x_1 : whitePoint.equals(Illuminant_getInstance().o2x_1) ? XYZColorSpaces_getInstance().j2x_1 : new XYZColorSpaceImpl(whitePoint);
|
|
2210
2210
|
}
|
|
2211
2211
|
function chromaticAdaptationMatrix(_this__u8e3s4, srcWp, xyzToLms, lmsToXyz) {
|
|
2212
2212
|
xyzToLms = xyzToLms === VOID ? get_CAT02_XYZ_TO_LMS() : xyzToLms;
|
|
2213
2213
|
lmsToXyz = lmsToXyz === VOID ? get_CAT02_LMS_TO_XYZ() : lmsToXyz;
|
|
2214
|
-
var dstWp = _this__u8e3s4.
|
|
2215
|
-
var src = dot_0(xyzToLms, srcWp.
|
|
2216
|
-
var dst = dot_0(xyzToLms, dstWp.
|
|
2214
|
+
var dstWp = _this__u8e3s4.h2x().c2z_1;
|
|
2215
|
+
var src = dot_0(xyzToLms, srcWp.h30(), srcWp.g30_1, srcWp.i30());
|
|
2216
|
+
var dst = dot_0(xyzToLms, dstWp.h30(), dstWp.g30_1, dstWp.i30());
|
|
2217
2217
|
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);
|
|
2218
2218
|
}
|
|
2219
2219
|
function XYZColorSpaceImpl(whitePoint) {
|
|
2220
|
-
this.
|
|
2221
|
-
this.
|
|
2220
|
+
this.v31_1 = whitePoint;
|
|
2221
|
+
this.w31_1 = zeroOneComponentInfo('XYZ');
|
|
2222
2222
|
}
|
|
2223
|
-
protoOf(XYZColorSpaceImpl).
|
|
2224
|
-
return this.
|
|
2223
|
+
protoOf(XYZColorSpaceImpl).h2x = function () {
|
|
2224
|
+
return this.v31_1;
|
|
2225
2225
|
};
|
|
2226
|
-
protoOf(XYZColorSpaceImpl).
|
|
2226
|
+
protoOf(XYZColorSpaceImpl).v1 = function () {
|
|
2227
2227
|
return 'XYZ';
|
|
2228
2228
|
};
|
|
2229
|
-
protoOf(XYZColorSpaceImpl).
|
|
2230
|
-
return color.
|
|
2229
|
+
protoOf(XYZColorSpaceImpl).c2x = function (color) {
|
|
2230
|
+
return color.p2w().k2x(this);
|
|
2231
2231
|
};
|
|
2232
2232
|
protoOf(XYZColorSpaceImpl).toString = function () {
|
|
2233
|
-
return 'XYZColorSpace(' + this.
|
|
2233
|
+
return 'XYZColorSpace(' + this.v31_1.toString() + ')';
|
|
2234
2234
|
};
|
|
2235
|
-
protoOf(XYZColorSpaceImpl).
|
|
2235
|
+
protoOf(XYZColorSpaceImpl).h2z = function (x, y, z, alpha) {
|
|
2236
2236
|
return new XYZ(x, y, z, alpha, this);
|
|
2237
2237
|
};
|
|
2238
2238
|
protoOf(XYZColorSpaceImpl).hashCode = function () {
|
|
2239
|
-
return this.
|
|
2239
|
+
return this.v31_1.hashCode();
|
|
2240
2240
|
};
|
|
2241
2241
|
protoOf(XYZColorSpaceImpl).equals = function (other) {
|
|
2242
2242
|
var tmp;
|
|
2243
2243
|
if (!(other == null) ? isInterface(other, XYZColorSpace) : false) {
|
|
2244
|
-
tmp = this.
|
|
2244
|
+
tmp = this.v31_1.equals(other.h2x());
|
|
2245
2245
|
} else {
|
|
2246
2246
|
tmp = false;
|
|
2247
2247
|
}
|
|
@@ -2257,26 +2257,26 @@
|
|
|
2257
2257
|
}
|
|
2258
2258
|
function xyY(x, y, Y) {
|
|
2259
2259
|
Y = Y === VOID ? 1.0 : Y;
|
|
2260
|
-
this.
|
|
2261
|
-
this.
|
|
2262
|
-
this.
|
|
2260
|
+
this.e30_1 = x;
|
|
2261
|
+
this.f30_1 = y;
|
|
2262
|
+
this.g30_1 = Y;
|
|
2263
2263
|
}
|
|
2264
|
-
protoOf(xyY).
|
|
2265
|
-
return 1 - this.
|
|
2264
|
+
protoOf(xyY).q31 = function () {
|
|
2265
|
+
return 1 - this.e30_1 - this.f30_1;
|
|
2266
2266
|
};
|
|
2267
|
-
protoOf(xyY).
|
|
2268
|
-
return this.
|
|
2267
|
+
protoOf(xyY).h30 = function () {
|
|
2268
|
+
return this.e30_1 * this.g30_1 / this.f30_1;
|
|
2269
2269
|
};
|
|
2270
|
-
protoOf(xyY).
|
|
2271
|
-
return (1 - this.
|
|
2270
|
+
protoOf(xyY).i30 = function () {
|
|
2271
|
+
return (1 - this.e30_1 - this.f30_1) * this.g30_1 / this.f30_1;
|
|
2272
2272
|
};
|
|
2273
2273
|
protoOf(xyY).toString = function () {
|
|
2274
|
-
return 'xyY(x=' + this.
|
|
2274
|
+
return 'xyY(x=' + this.e30_1 + ', y=' + this.f30_1 + ', Y=' + this.g30_1 + ')';
|
|
2275
2275
|
};
|
|
2276
2276
|
protoOf(xyY).hashCode = function () {
|
|
2277
|
-
var result = getNumberHashCode(this.
|
|
2278
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2279
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2277
|
+
var result = getNumberHashCode(this.e30_1);
|
|
2278
|
+
result = imul(result, 31) + getNumberHashCode(this.f30_1) | 0;
|
|
2279
|
+
result = imul(result, 31) + getNumberHashCode(this.g30_1) | 0;
|
|
2280
2280
|
return result;
|
|
2281
2281
|
};
|
|
2282
2282
|
protoOf(xyY).equals = function (other) {
|
|
@@ -2285,33 +2285,33 @@
|
|
|
2285
2285
|
if (!(other instanceof xyY))
|
|
2286
2286
|
return false;
|
|
2287
2287
|
var tmp0_other_with_cast = other instanceof xyY ? other : THROW_CCE();
|
|
2288
|
-
if (!equals(this.
|
|
2288
|
+
if (!equals(this.e30_1, tmp0_other_with_cast.e30_1))
|
|
2289
2289
|
return false;
|
|
2290
|
-
if (!equals(this.
|
|
2290
|
+
if (!equals(this.f30_1, tmp0_other_with_cast.f30_1))
|
|
2291
2291
|
return false;
|
|
2292
|
-
if (!equals(this.
|
|
2292
|
+
if (!equals(this.g30_1, tmp0_other_with_cast.g30_1))
|
|
2293
2293
|
return false;
|
|
2294
2294
|
return true;
|
|
2295
2295
|
};
|
|
2296
2296
|
//region block: post-declaration
|
|
2297
|
-
protoOf(HSL).
|
|
2298
|
-
protoOf(HSL).
|
|
2299
|
-
protoOf(HSL).
|
|
2300
|
-
protoOf(LAB).
|
|
2301
|
-
protoOf(LABColorSpaceImpl).
|
|
2302
|
-
protoOf(LCHab).
|
|
2303
|
-
protoOf(RGB).
|
|
2304
|
-
protoOf(RGB).
|
|
2305
|
-
protoOf(RGBColorSpaceImpl).
|
|
2306
|
-
protoOf(RGBInt).
|
|
2307
|
-
protoOf(RGBInt).
|
|
2308
|
-
protoOf(RGBInt).
|
|
2309
|
-
protoOf(RGBInt).
|
|
2310
|
-
protoOf(Companion_4).
|
|
2311
|
-
protoOf(XYZ).
|
|
2312
|
-
protoOf(XYZ).
|
|
2313
|
-
protoOf(XYZColorSpaceImpl).
|
|
2314
|
-
protoOf(XYZColorSpaceImpl).
|
|
2297
|
+
protoOf(HSL).p2w = toXYZ;
|
|
2298
|
+
protoOf(HSL).q2w = toLAB;
|
|
2299
|
+
protoOf(HSL).w2w = toLCHab;
|
|
2300
|
+
protoOf(LAB).j2w = toHSL;
|
|
2301
|
+
protoOf(LABColorSpaceImpl).c30 = invoke;
|
|
2302
|
+
protoOf(LCHab).j2w = toHSL;
|
|
2303
|
+
protoOf(RGB).q2w = toLAB;
|
|
2304
|
+
protoOf(RGB).w2w = toLCHab;
|
|
2305
|
+
protoOf(RGBColorSpaceImpl).c30 = invoke_0;
|
|
2306
|
+
protoOf(RGBInt).j2w = toHSL;
|
|
2307
|
+
protoOf(RGBInt).p2w = toXYZ;
|
|
2308
|
+
protoOf(RGBInt).q2w = toLAB;
|
|
2309
|
+
protoOf(RGBInt).w2w = toLCHab;
|
|
2310
|
+
protoOf(Companion_4).d30 = invoke$default;
|
|
2311
|
+
protoOf(XYZ).j2w = toHSL;
|
|
2312
|
+
protoOf(XYZ).w2w = toLCHab;
|
|
2313
|
+
protoOf(XYZColorSpaceImpl).c30 = invoke_1;
|
|
2314
|
+
protoOf(XYZColorSpaceImpl).d30 = invoke$default;
|
|
2315
2315
|
//endregion
|
|
2316
2316
|
//region block: init
|
|
2317
2317
|
PqNonlinearity_instance = new PqNonlinearity();
|