@cruglobal/godtools-shared 1.1.0-SNAPSHOT.1568 → 1.1.0-SNAPSHOT.1570
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 +48 -48
- package/Kermit-kermit.js +10 -10
- package/antlr-kotlin-antlr-kotlin-runtime.js +3137 -3137
- package/colormath-root-colormath.js +1026 -1125
- package/colormath-root-colormath.js.map +1 -1
- package/fluid-locale.js +159 -159
- package/kotlin-js.js +39 -39
- package/kotlin-kotlin-stdlib.js +1734 -1816
- 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-parser-expressions.js +408 -408
- package/kotlin-mpp-godtools-tool-parser-module-parser.js +2284 -2284
- package/kotlin-mpp-godtools-tool-parser-module-state.js +249 -249
- package/kotlin-mpp-godtools-tool-parser-module-state.js.map +1 -1
- package/kotlinx-atomicfu.js +70 -70
- package/kotlinx-atomicfu.js.map +1 -1
- package/kotlinx-coroutines-core.js +3572 -3567
- package/kotlinx-coroutines-core.js.map +1 -1
- package/package.json +1 -1
|
@@ -14,105 +14,102 @@
|
|
|
14
14
|
//region block: imports
|
|
15
15
|
var imul = Math.imul;
|
|
16
16
|
var log2 = Math.log2;
|
|
17
|
-
var protoOf = kotlin_kotlin.$_$.
|
|
18
|
-
var initMetadataForCompanion = kotlin_kotlin.$_$.
|
|
19
|
-
var initMetadataForInterface = kotlin_kotlin.$_$.
|
|
20
|
-
var toString = kotlin_kotlin.$_$.
|
|
17
|
+
var protoOf = kotlin_kotlin.$_$.z6;
|
|
18
|
+
var initMetadataForCompanion = kotlin_kotlin.$_$.l6;
|
|
19
|
+
var initMetadataForInterface = kotlin_kotlin.$_$.n6;
|
|
20
|
+
var toString = kotlin_kotlin.$_$.c7;
|
|
21
21
|
var IllegalArgumentException_init_$Create$ = kotlin_kotlin.$_$.a1;
|
|
22
|
-
var initMetadataForClass = kotlin_kotlin.$_$.
|
|
23
|
-
var emptyMap = kotlin_kotlin.$_$.
|
|
22
|
+
var initMetadataForClass = kotlin_kotlin.$_$.k6;
|
|
23
|
+
var emptyMap = kotlin_kotlin.$_$.q3;
|
|
24
24
|
var VOID = kotlin_kotlin.$_$.d;
|
|
25
|
-
var Companion_instance = kotlin_kotlin.$_$.
|
|
25
|
+
var Companion_instance = kotlin_kotlin.$_$.k2;
|
|
26
26
|
var _Result___init__impl__xyqfz8 = kotlin_kotlin.$_$.y1;
|
|
27
|
-
var createFailure = kotlin_kotlin.$_$.
|
|
27
|
+
var createFailure = kotlin_kotlin.$_$.t9;
|
|
28
28
|
var _Result___get_value__impl__bjfvqg = kotlin_kotlin.$_$.b2;
|
|
29
|
-
var THROW_CCE = kotlin_kotlin.$_$.
|
|
29
|
+
var THROW_CCE = kotlin_kotlin.$_$.n9;
|
|
30
30
|
var _Result___get_isFailure__impl__jpiriv = kotlin_kotlin.$_$.a2;
|
|
31
|
-
var startsWith = kotlin_kotlin.$_$.
|
|
31
|
+
var startsWith = kotlin_kotlin.$_$.l8;
|
|
32
32
|
var Regex_init_$Create$ = kotlin_kotlin.$_$.s;
|
|
33
|
-
var initMetadataForObject = kotlin_kotlin.$_$.
|
|
34
|
-
var endsWith = kotlin_kotlin.$_$.
|
|
35
|
-
var collectionSizeOrDefault = kotlin_kotlin.$_$.
|
|
33
|
+
var initMetadataForObject = kotlin_kotlin.$_$.p6;
|
|
34
|
+
var endsWith = kotlin_kotlin.$_$.x7;
|
|
35
|
+
var collectionSizeOrDefault = kotlin_kotlin.$_$.e3;
|
|
36
36
|
var ArrayList_init_$Create$ = kotlin_kotlin.$_$.g;
|
|
37
|
-
var checkIndexOverflow = kotlin_kotlin.$_$.
|
|
38
|
-
var Unit_instance = kotlin_kotlin.$_$.
|
|
39
|
-
var get_lastIndex = kotlin_kotlin.$_$.
|
|
40
|
-
var dropLast = kotlin_kotlin.$_$.
|
|
41
|
-
var toDouble = kotlin_kotlin.$_$.
|
|
42
|
-
var charSequenceLength = kotlin_kotlin.$_$.
|
|
43
|
-
var coerceIn = kotlin_kotlin.$_$.
|
|
44
|
-
var
|
|
45
|
-
var
|
|
46
|
-
var equals = kotlin_kotlin.$_$.h6;
|
|
37
|
+
var checkIndexOverflow = kotlin_kotlin.$_$.d3;
|
|
38
|
+
var Unit_instance = kotlin_kotlin.$_$.l2;
|
|
39
|
+
var get_lastIndex = kotlin_kotlin.$_$.f4;
|
|
40
|
+
var dropLast = kotlin_kotlin.$_$.w7;
|
|
41
|
+
var toDouble = kotlin_kotlin.$_$.q8;
|
|
42
|
+
var charSequenceLength = kotlin_kotlin.$_$.a6;
|
|
43
|
+
var coerceIn = kotlin_kotlin.$_$.j7;
|
|
44
|
+
var Enum = kotlin_kotlin.$_$.d9;
|
|
45
|
+
var equals = kotlin_kotlin.$_$.d6;
|
|
47
46
|
var StringBuilder_init_$Create$ = kotlin_kotlin.$_$.v;
|
|
48
|
-
var dropLast_0 = kotlin_kotlin.$_$.
|
|
49
|
-
var joinTo = kotlin_kotlin.$_$.
|
|
47
|
+
var dropLast_0 = kotlin_kotlin.$_$.o3;
|
|
48
|
+
var joinTo = kotlin_kotlin.$_$.d4;
|
|
50
49
|
var UByte__toString_impl_v72jg = kotlin_kotlin.$_$.e2;
|
|
51
|
-
var numberToInt = kotlin_kotlin.$_$.
|
|
52
|
-
var roundToInt = kotlin_kotlin.$_$.
|
|
50
|
+
var numberToInt = kotlin_kotlin.$_$.x6;
|
|
51
|
+
var roundToInt = kotlin_kotlin.$_$.d7;
|
|
53
52
|
var _Char___init__impl__6a9atx = kotlin_kotlin.$_$.t1;
|
|
54
|
-
var padStart = kotlin_kotlin.$_$.
|
|
55
|
-
var charArrayOf = kotlin_kotlin.$_$.
|
|
56
|
-
var trimEnd = kotlin_kotlin.$_$.
|
|
57
|
-
var isNaN_0 = kotlin_kotlin.$_$.
|
|
58
|
-
var joinTo_0 = kotlin_kotlin.$_$.
|
|
59
|
-
var noWhenBranchMatchedException = kotlin_kotlin.$_$.
|
|
60
|
-
var numberToDouble = kotlin_kotlin.$_$.
|
|
61
|
-
var getStringHashCode = kotlin_kotlin.$_$.
|
|
53
|
+
var padStart = kotlin_kotlin.$_$.f8;
|
|
54
|
+
var charArrayOf = kotlin_kotlin.$_$.y5;
|
|
55
|
+
var trimEnd = kotlin_kotlin.$_$.x8;
|
|
56
|
+
var isNaN_0 = kotlin_kotlin.$_$.v9;
|
|
57
|
+
var joinTo_0 = kotlin_kotlin.$_$.c4;
|
|
58
|
+
var noWhenBranchMatchedException = kotlin_kotlin.$_$.x9;
|
|
59
|
+
var numberToDouble = kotlin_kotlin.$_$.w6;
|
|
60
|
+
var getStringHashCode = kotlin_kotlin.$_$.i6;
|
|
62
61
|
var ArrayList_init_$Create$_0 = kotlin_kotlin.$_$.h;
|
|
63
|
-
var charSequenceGet = kotlin_kotlin.$_$.
|
|
62
|
+
var charSequenceGet = kotlin_kotlin.$_$.z5;
|
|
64
63
|
var toString_0 = kotlin_kotlin.$_$.x1;
|
|
65
64
|
var arrayConcat = kotlin_kotlin.$_$.a;
|
|
66
|
-
var listOf = kotlin_kotlin.$_$.
|
|
67
|
-
var to = kotlin_kotlin.$_$.
|
|
68
|
-
var mapOf = kotlin_kotlin.$_$.
|
|
69
|
-
var withSign = kotlin_kotlin.$_$.
|
|
70
|
-
var
|
|
71
|
-
var
|
|
72
|
-
var
|
|
73
|
-
var
|
|
74
|
-
var
|
|
75
|
-
var
|
|
76
|
-
var
|
|
77
|
-
var
|
|
78
|
-
var
|
|
79
|
-
var
|
|
80
|
-
var
|
|
81
|
-
var
|
|
82
|
-
var contentEquals = kotlin_kotlin.$_$.m3;
|
|
83
|
-
var coerceAtLeast_0 = kotlin_kotlin.$_$.m7;
|
|
65
|
+
var listOf = kotlin_kotlin.$_$.j4;
|
|
66
|
+
var to = kotlin_kotlin.$_$.ca;
|
|
67
|
+
var mapOf = kotlin_kotlin.$_$.l4;
|
|
68
|
+
var withSign = kotlin_kotlin.$_$.e7;
|
|
69
|
+
var trimMargin = kotlin_kotlin.$_$.y8;
|
|
70
|
+
var hashCode = kotlin_kotlin.$_$.j6;
|
|
71
|
+
var coerceAtLeast = kotlin_kotlin.$_$.f7;
|
|
72
|
+
var getNumberHashCode = kotlin_kotlin.$_$.g6;
|
|
73
|
+
var isInterface = kotlin_kotlin.$_$.s6;
|
|
74
|
+
var objectCreate = kotlin_kotlin.$_$.y6;
|
|
75
|
+
var Char = kotlin_kotlin.$_$.a9;
|
|
76
|
+
var toInt = kotlin_kotlin.$_$.u8;
|
|
77
|
+
var numberRangeToNumber = kotlin_kotlin.$_$.t6;
|
|
78
|
+
var slice = kotlin_kotlin.$_$.h8;
|
|
79
|
+
var contentEquals = kotlin_kotlin.$_$.i3;
|
|
80
|
+
var coerceAtLeast_0 = kotlin_kotlin.$_$.h7;
|
|
84
81
|
var _UInt___init__impl__l7qpdl = kotlin_kotlin.$_$.f2;
|
|
85
82
|
var _UInt___get_data__impl__f0vqqw = kotlin_kotlin.$_$.g2;
|
|
86
|
-
var coerceIn_0 = kotlin_kotlin.$_$.
|
|
83
|
+
var coerceIn_0 = kotlin_kotlin.$_$.k7;
|
|
87
84
|
var _UByte___get_data__impl__jof9qr = kotlin_kotlin.$_$.d2;
|
|
88
|
-
var uintToDouble = kotlin_kotlin.$_$.
|
|
89
|
-
var toByte = kotlin_kotlin.$_$.
|
|
85
|
+
var uintToDouble = kotlin_kotlin.$_$.ea;
|
|
86
|
+
var toByte = kotlin_kotlin.$_$.a7;
|
|
90
87
|
var _UByte___init__impl__g9hnc4 = kotlin_kotlin.$_$.c2;
|
|
91
|
-
var UInt = kotlin_kotlin.$_$.
|
|
88
|
+
var UInt = kotlin_kotlin.$_$.p9;
|
|
92
89
|
var UInt__hashCode_impl_z2mhuw = kotlin_kotlin.$_$.h2;
|
|
93
90
|
//endregion
|
|
94
91
|
//region block: pre-declaration
|
|
95
92
|
initMetadataForCompanion(Companion);
|
|
96
93
|
function toHSL() {
|
|
97
|
-
return this.
|
|
94
|
+
return this.c1m().d1m();
|
|
98
95
|
}
|
|
99
96
|
function toXYZ() {
|
|
100
|
-
return this.
|
|
97
|
+
return this.c1m().j1m();
|
|
101
98
|
}
|
|
102
99
|
function toLAB() {
|
|
103
|
-
return this.
|
|
100
|
+
return this.j1m().k1m();
|
|
104
101
|
}
|
|
105
102
|
function toLCHab() {
|
|
106
|
-
return this.
|
|
103
|
+
return this.k1m().q1m();
|
|
107
104
|
}
|
|
108
105
|
function toHWB() {
|
|
109
|
-
return this.
|
|
106
|
+
return this.c1m().w1m();
|
|
110
107
|
}
|
|
111
108
|
function toOklab() {
|
|
112
|
-
return this.
|
|
109
|
+
return this.j1m().x1m();
|
|
113
110
|
}
|
|
114
111
|
function toOklch() {
|
|
115
|
-
return this.
|
|
112
|
+
return this.x1m().y1m();
|
|
116
113
|
}
|
|
117
114
|
initMetadataForInterface(Color, 'Color');
|
|
118
115
|
initMetadataForClass(ColorComponentInfo, 'ColorComponentInfo');
|
|
@@ -131,7 +128,7 @@
|
|
|
131
128
|
initMetadataForClass(ICtCp, 'ICtCp', VOID, VOID, [Color]);
|
|
132
129
|
initMetadataForObject(PqNonlinearity, 'PqNonlinearity');
|
|
133
130
|
function invoke(l, a, b, alpha) {
|
|
134
|
-
return this.
|
|
131
|
+
return this.e1o(numberToDouble(l), numberToDouble(a), numberToDouble(b), numberToDouble(alpha));
|
|
135
132
|
}
|
|
136
133
|
initMetadataForInterface(LABColorSpace, 'LABColorSpace', VOID, VOID, [WhitePointColorSpace]);
|
|
137
134
|
initMetadataForCompanion(Companion_2, VOID, [LABColorSpace]);
|
|
@@ -150,14 +147,14 @@
|
|
|
150
147
|
initMetadataForClass(GammaTransferFunctions, 'GammaTransferFunctions');
|
|
151
148
|
initMetadataForObject(LinearTransferFunctions, 'LinearTransferFunctions');
|
|
152
149
|
function invoke_0(r, g, b, alpha) {
|
|
153
|
-
return this.
|
|
150
|
+
return this.e1o(numberToDouble(r), numberToDouble(g), numberToDouble(b), numberToDouble(alpha));
|
|
154
151
|
}
|
|
155
152
|
function from255(r, g, b, alpha) {
|
|
156
|
-
return this.
|
|
153
|
+
return this.e1o(r / 255.0, g / 255.0, b / 255.0, alpha / 255.0);
|
|
157
154
|
}
|
|
158
155
|
function from255$default(r, g, b, alpha, $super) {
|
|
159
156
|
alpha = alpha === VOID ? 255 : alpha;
|
|
160
|
-
return $super === VOID ? this.
|
|
157
|
+
return $super === VOID ? this.i1q(r, g, b, alpha) : from255(r, g, b, alpha);
|
|
161
158
|
}
|
|
162
159
|
function invoke_1(hex) {
|
|
163
160
|
var tmp = parseHex(validateHex(hex), 0);
|
|
@@ -173,7 +170,7 @@
|
|
|
173
170
|
} else {
|
|
174
171
|
tmp_2 = 255;
|
|
175
172
|
}
|
|
176
|
-
return this.
|
|
173
|
+
return this.i1q(tmp, tmp_0, tmp_1, tmp_2);
|
|
177
174
|
}
|
|
178
175
|
initMetadataForInterface(RGBColorSpace, 'RGBColorSpace', VOID, VOID, [WhitePointColorSpace]);
|
|
179
176
|
initMetadataForCompanion(Companion_6, VOID, [RGBColorSpace]);
|
|
@@ -190,11 +187,11 @@
|
|
|
190
187
|
initMetadataForCompanion(Companion_7);
|
|
191
188
|
initMetadataForClass(RGBInt, 'RGBInt', VOID, VOID, [Color]);
|
|
192
189
|
function invoke_2(x, y, z, alpha) {
|
|
193
|
-
return this.
|
|
190
|
+
return this.e1o(numberToDouble(x), numberToDouble(y), numberToDouble(z), numberToDouble(alpha));
|
|
194
191
|
}
|
|
195
192
|
function invoke$default(x, y, z, alpha, $super) {
|
|
196
193
|
alpha = alpha === VOID ? 1.0 : alpha;
|
|
197
|
-
return $super === VOID ? this.
|
|
194
|
+
return $super === VOID ? this.d1r(x, y, z, alpha) : invoke_2(x, y, z, alpha);
|
|
198
195
|
}
|
|
199
196
|
initMetadataForInterface(XYZColorSpace, 'XYZColorSpace', VOID, VOID, [WhitePointColorSpace]);
|
|
200
197
|
initMetadataForCompanion(Companion_8, VOID, [XYZColorSpace]);
|
|
@@ -212,16 +209,16 @@
|
|
|
212
209
|
function Color() {
|
|
213
210
|
}
|
|
214
211
|
function convertTo(_this__u8e3s4, space) {
|
|
215
|
-
return space.
|
|
212
|
+
return space.d1n(_this__u8e3s4);
|
|
216
213
|
}
|
|
217
214
|
function ColorComponentInfo(name, isPolar, min, max) {
|
|
218
|
-
this.
|
|
219
|
-
this.
|
|
220
|
-
this.
|
|
221
|
-
this.
|
|
215
|
+
this.e1n_1 = name;
|
|
216
|
+
this.f1n_1 = isPolar;
|
|
217
|
+
this.g1n_1 = min;
|
|
218
|
+
this.h1n_1 = max;
|
|
222
219
|
// Inline function 'kotlin.require' call
|
|
223
220
|
// Inline function 'kotlin.contracts.contract' call
|
|
224
|
-
if (!(this.
|
|
221
|
+
if (!(this.g1n_1 <= this.h1n_1)) {
|
|
225
222
|
// Inline function 'com.github.ajalt.colormath.ColorComponentInfo.<anonymous>' call
|
|
226
223
|
var message = 'min must be less than or equal to max';
|
|
227
224
|
throw IllegalArgumentException_init_$Create$(toString(message));
|
|
@@ -242,7 +239,7 @@
|
|
|
242
239
|
}
|
|
243
240
|
function parseOrNull(_this__u8e3s4, color_0, customColorSpaces) {
|
|
244
241
|
customColorSpaces = customColorSpaces === VOID ? emptyMap() : customColorSpaces;
|
|
245
|
-
var keywordColor = CssColors_getInstance().
|
|
242
|
+
var keywordColor = CssColors_getInstance().l1n_1.k2(color_0);
|
|
246
243
|
var tmp;
|
|
247
244
|
if (!(keywordColor == null)) {
|
|
248
245
|
tmp = keywordColor;
|
|
@@ -253,7 +250,7 @@
|
|
|
253
250
|
try {
|
|
254
251
|
// Inline function 'kotlin.Companion.success' call
|
|
255
252
|
// Inline function 'com.github.ajalt.colormath.parseOrNull.<anonymous>' call
|
|
256
|
-
var value = Companion_getInstance_6().
|
|
253
|
+
var value = Companion_getInstance_6().d1o(color_0);
|
|
257
254
|
tmp_0 = _Result___init__impl__xyqfz8(value);
|
|
258
255
|
} catch ($p) {
|
|
259
256
|
var tmp_1;
|
|
@@ -276,7 +273,7 @@
|
|
|
276
273
|
}
|
|
277
274
|
tmp = tmp_2;
|
|
278
275
|
} else {
|
|
279
|
-
var tmp0_safe_receiver = PATTERNS_getInstance().
|
|
276
|
+
var tmp0_safe_receiver = PATTERNS_getInstance().s1n_1.pc(color_0);
|
|
280
277
|
var tmp_4;
|
|
281
278
|
if (tmp0_safe_receiver == null) {
|
|
282
279
|
tmp_4 = null;
|
|
@@ -286,10 +283,10 @@
|
|
|
286
283
|
// Inline function 'com.github.ajalt.colormath.parseOrNull.<anonymous>' call
|
|
287
284
|
tmp_4 = rgb(tmp0_safe_receiver);
|
|
288
285
|
}
|
|
289
|
-
var
|
|
286
|
+
var tmp0_elvis_lhs = tmp_4;
|
|
290
287
|
var tmp_5;
|
|
291
|
-
if (
|
|
292
|
-
var tmp1_safe_receiver = PATTERNS_getInstance().
|
|
288
|
+
if (tmp0_elvis_lhs == null) {
|
|
289
|
+
var tmp1_safe_receiver = PATTERNS_getInstance().t1n_1.pc(color_0);
|
|
293
290
|
var tmp_6;
|
|
294
291
|
if (tmp1_safe_receiver == null) {
|
|
295
292
|
tmp_6 = null;
|
|
@@ -301,143 +298,143 @@
|
|
|
301
298
|
}
|
|
302
299
|
tmp_5 = tmp_6;
|
|
303
300
|
} else {
|
|
304
|
-
tmp_5 =
|
|
301
|
+
tmp_5 = tmp0_elvis_lhs;
|
|
305
302
|
}
|
|
306
|
-
var
|
|
303
|
+
var tmp1_elvis_lhs = tmp_5;
|
|
307
304
|
var tmp_7;
|
|
308
|
-
if (
|
|
309
|
-
var
|
|
305
|
+
if (tmp1_elvis_lhs == null) {
|
|
306
|
+
var tmp2_safe_receiver = PATTERNS_getInstance().u1n_1.pc(color_0);
|
|
310
307
|
var tmp_8;
|
|
311
|
-
if (
|
|
308
|
+
if (tmp2_safe_receiver == null) {
|
|
312
309
|
tmp_8 = null;
|
|
313
310
|
} else {
|
|
314
311
|
// Inline function 'kotlin.let' call
|
|
315
312
|
// Inline function 'kotlin.contracts.contract' call
|
|
316
313
|
// Inline function 'com.github.ajalt.colormath.parseOrNull.<anonymous>' call
|
|
317
|
-
tmp_8 = hsl(
|
|
314
|
+
tmp_8 = hsl(tmp2_safe_receiver);
|
|
318
315
|
}
|
|
319
316
|
tmp_7 = tmp_8;
|
|
320
317
|
} else {
|
|
321
|
-
tmp_7 =
|
|
318
|
+
tmp_7 = tmp1_elvis_lhs;
|
|
322
319
|
}
|
|
323
|
-
var
|
|
320
|
+
var tmp2_elvis_lhs = tmp_7;
|
|
324
321
|
var tmp_9;
|
|
325
|
-
if (
|
|
326
|
-
var
|
|
322
|
+
if (tmp2_elvis_lhs == null) {
|
|
323
|
+
var tmp3_safe_receiver = PATTERNS_getInstance().v1n_1.pc(color_0);
|
|
327
324
|
var tmp_10;
|
|
328
|
-
if (
|
|
325
|
+
if (tmp3_safe_receiver == null) {
|
|
329
326
|
tmp_10 = null;
|
|
330
327
|
} else {
|
|
331
328
|
// Inline function 'kotlin.let' call
|
|
332
329
|
// Inline function 'kotlin.contracts.contract' call
|
|
333
330
|
// Inline function 'com.github.ajalt.colormath.parseOrNull.<anonymous>' call
|
|
334
|
-
tmp_10 = hsl(
|
|
331
|
+
tmp_10 = hsl(tmp3_safe_receiver);
|
|
335
332
|
}
|
|
336
333
|
tmp_9 = tmp_10;
|
|
337
334
|
} else {
|
|
338
|
-
tmp_9 =
|
|
335
|
+
tmp_9 = tmp2_elvis_lhs;
|
|
339
336
|
}
|
|
340
|
-
var
|
|
337
|
+
var tmp3_elvis_lhs = tmp_9;
|
|
341
338
|
var tmp_11;
|
|
342
|
-
if (
|
|
343
|
-
var
|
|
339
|
+
if (tmp3_elvis_lhs == null) {
|
|
340
|
+
var tmp4_safe_receiver = PATTERNS_getInstance().w1n_1.pc(color_0);
|
|
344
341
|
var tmp_12;
|
|
345
|
-
if (
|
|
342
|
+
if (tmp4_safe_receiver == null) {
|
|
346
343
|
tmp_12 = null;
|
|
347
344
|
} else {
|
|
348
345
|
// Inline function 'kotlin.let' call
|
|
349
346
|
// Inline function 'kotlin.contracts.contract' call
|
|
350
347
|
// Inline function 'com.github.ajalt.colormath.parseOrNull.<anonymous>' call
|
|
351
|
-
tmp_12 = lab(
|
|
348
|
+
tmp_12 = lab(tmp4_safe_receiver);
|
|
352
349
|
}
|
|
353
350
|
tmp_11 = tmp_12;
|
|
354
351
|
} else {
|
|
355
|
-
tmp_11 =
|
|
352
|
+
tmp_11 = tmp3_elvis_lhs;
|
|
356
353
|
}
|
|
357
|
-
var
|
|
354
|
+
var tmp4_elvis_lhs = tmp_11;
|
|
358
355
|
var tmp_13;
|
|
359
|
-
if (
|
|
360
|
-
var
|
|
356
|
+
if (tmp4_elvis_lhs == null) {
|
|
357
|
+
var tmp5_safe_receiver = PATTERNS_getInstance().x1n_1.pc(color_0);
|
|
361
358
|
var tmp_14;
|
|
362
|
-
if (
|
|
359
|
+
if (tmp5_safe_receiver == null) {
|
|
363
360
|
tmp_14 = null;
|
|
364
361
|
} else {
|
|
365
362
|
// Inline function 'kotlin.let' call
|
|
366
363
|
// Inline function 'kotlin.contracts.contract' call
|
|
367
364
|
// Inline function 'com.github.ajalt.colormath.parseOrNull.<anonymous>' call
|
|
368
|
-
tmp_14 = lch(
|
|
365
|
+
tmp_14 = lch(tmp5_safe_receiver);
|
|
369
366
|
}
|
|
370
367
|
tmp_13 = tmp_14;
|
|
371
368
|
} else {
|
|
372
|
-
tmp_13 =
|
|
369
|
+
tmp_13 = tmp4_elvis_lhs;
|
|
373
370
|
}
|
|
374
|
-
var
|
|
371
|
+
var tmp5_elvis_lhs = tmp_13;
|
|
375
372
|
var tmp_15;
|
|
376
|
-
if (
|
|
377
|
-
var
|
|
373
|
+
if (tmp5_elvis_lhs == null) {
|
|
374
|
+
var tmp6_safe_receiver = PATTERNS_getInstance().y1n_1.pc(color_0);
|
|
378
375
|
var tmp_16;
|
|
379
|
-
if (
|
|
376
|
+
if (tmp6_safe_receiver == null) {
|
|
380
377
|
tmp_16 = null;
|
|
381
378
|
} else {
|
|
382
379
|
// Inline function 'kotlin.let' call
|
|
383
380
|
// Inline function 'kotlin.contracts.contract' call
|
|
384
381
|
// Inline function 'com.github.ajalt.colormath.parseOrNull.<anonymous>' call
|
|
385
|
-
tmp_16 = hwb(
|
|
382
|
+
tmp_16 = hwb(tmp6_safe_receiver);
|
|
386
383
|
}
|
|
387
384
|
tmp_15 = tmp_16;
|
|
388
385
|
} else {
|
|
389
|
-
tmp_15 =
|
|
386
|
+
tmp_15 = tmp5_elvis_lhs;
|
|
390
387
|
}
|
|
391
|
-
var
|
|
388
|
+
var tmp6_elvis_lhs = tmp_15;
|
|
392
389
|
var tmp_17;
|
|
393
|
-
if (
|
|
394
|
-
var
|
|
390
|
+
if (tmp6_elvis_lhs == null) {
|
|
391
|
+
var tmp7_safe_receiver = PATTERNS_getInstance().z1n_1.pc(color_0);
|
|
395
392
|
var tmp_18;
|
|
396
|
-
if (
|
|
393
|
+
if (tmp7_safe_receiver == null) {
|
|
397
394
|
tmp_18 = null;
|
|
398
395
|
} else {
|
|
399
396
|
// Inline function 'kotlin.let' call
|
|
400
397
|
// Inline function 'kotlin.contracts.contract' call
|
|
401
398
|
// Inline function 'com.github.ajalt.colormath.parseOrNull.<anonymous>' call
|
|
402
|
-
tmp_18 = oklab(
|
|
399
|
+
tmp_18 = oklab(tmp7_safe_receiver);
|
|
403
400
|
}
|
|
404
401
|
tmp_17 = tmp_18;
|
|
405
402
|
} else {
|
|
406
|
-
tmp_17 =
|
|
403
|
+
tmp_17 = tmp6_elvis_lhs;
|
|
407
404
|
}
|
|
408
|
-
var
|
|
405
|
+
var tmp7_elvis_lhs = tmp_17;
|
|
409
406
|
var tmp_19;
|
|
410
|
-
if (
|
|
411
|
-
var
|
|
407
|
+
if (tmp7_elvis_lhs == null) {
|
|
408
|
+
var tmp8_safe_receiver = PATTERNS_getInstance().a1o_1.pc(color_0);
|
|
412
409
|
var tmp_20;
|
|
413
|
-
if (
|
|
410
|
+
if (tmp8_safe_receiver == null) {
|
|
414
411
|
tmp_20 = null;
|
|
415
412
|
} else {
|
|
416
413
|
// Inline function 'kotlin.let' call
|
|
417
414
|
// Inline function 'kotlin.contracts.contract' call
|
|
418
415
|
// Inline function 'com.github.ajalt.colormath.parseOrNull.<anonymous>' call
|
|
419
|
-
tmp_20 = oklch(
|
|
416
|
+
tmp_20 = oklch(tmp8_safe_receiver);
|
|
420
417
|
}
|
|
421
418
|
tmp_19 = tmp_20;
|
|
422
419
|
} else {
|
|
423
|
-
tmp_19 =
|
|
420
|
+
tmp_19 = tmp7_elvis_lhs;
|
|
424
421
|
}
|
|
425
|
-
var
|
|
422
|
+
var tmp8_elvis_lhs = tmp_19;
|
|
426
423
|
var tmp_21;
|
|
427
|
-
if (
|
|
428
|
-
var
|
|
424
|
+
if (tmp8_elvis_lhs == null) {
|
|
425
|
+
var tmp9_safe_receiver = PATTERNS_getInstance().b1o_1.pc(color_0);
|
|
429
426
|
var tmp_22;
|
|
430
|
-
if (
|
|
427
|
+
if (tmp9_safe_receiver == null) {
|
|
431
428
|
tmp_22 = null;
|
|
432
429
|
} else {
|
|
433
430
|
// Inline function 'kotlin.let' call
|
|
434
431
|
// Inline function 'kotlin.contracts.contract' call
|
|
435
432
|
// Inline function 'com.github.ajalt.colormath.parseOrNull.<anonymous>' call
|
|
436
|
-
tmp_22 = color(
|
|
433
|
+
tmp_22 = color(tmp9_safe_receiver, customColorSpaces);
|
|
437
434
|
}
|
|
438
435
|
tmp_21 = tmp_22;
|
|
439
436
|
} else {
|
|
440
|
-
tmp_21 =
|
|
437
|
+
tmp_21 = tmp8_elvis_lhs;
|
|
441
438
|
}
|
|
442
439
|
tmp = tmp_21;
|
|
443
440
|
}
|
|
@@ -445,22 +442,22 @@
|
|
|
445
442
|
}
|
|
446
443
|
function PATTERNS() {
|
|
447
444
|
PATTERNS_instance = this;
|
|
448
|
-
this.
|
|
449
|
-
this.
|
|
450
|
-
this.
|
|
451
|
-
this.
|
|
452
|
-
this.
|
|
453
|
-
this.
|
|
454
|
-
this.
|
|
455
|
-
this.
|
|
456
|
-
this.
|
|
457
|
-
this.
|
|
458
|
-
this.
|
|
459
|
-
this.
|
|
460
|
-
this.
|
|
461
|
-
this.
|
|
462
|
-
this.
|
|
463
|
-
this.
|
|
445
|
+
this.m1n_1 = '[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?';
|
|
446
|
+
this.n1n_1 = '(?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?)';
|
|
447
|
+
this.o1n_1 = '[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?';
|
|
448
|
+
this.p1n_1 = '\\s*(?:/\\s*([+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))?\\s*';
|
|
449
|
+
this.q1n_1 = '\\s*(?:,\\s*([+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))?\\s*';
|
|
450
|
+
this.r1n_1 = '(?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?(?:deg|grad|rad|turn)?)';
|
|
451
|
+
this.s1n_1 = Regex_init_$Create$('rgba?\\(((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s*(?:/\\s*([+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))?\\s*\\)');
|
|
452
|
+
this.t1n_1 = Regex_init_$Create$('rgba?\\(((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s*,\\s*((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s*,\\s*((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s*(?:,\\s*([+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))?\\s*\\)');
|
|
453
|
+
this.u1n_1 = Regex_init_$Create$('hsla?\\(((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?(?:deg|grad|rad|turn)?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s*(?:/\\s*([+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))?\\s*\\)');
|
|
454
|
+
this.v1n_1 = Regex_init_$Create$('hsla?\\(((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?(?:deg|grad|rad|turn)?))\\s*,\\s*((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s*,\\s*((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s*(?:,\\s*([+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))?\\s*\\)');
|
|
455
|
+
this.w1n_1 = Regex_init_$Create$('lab\\(((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s*(?:/\\s*([+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))?\\s*\\)');
|
|
456
|
+
this.x1n_1 = Regex_init_$Create$('lch\\(((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?(?:deg|grad|rad|turn)?))\\s*(?:/\\s*([+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))?\\s*\\)');
|
|
457
|
+
this.y1n_1 = Regex_init_$Create$('hwb\\(((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?(?:deg|grad|rad|turn)?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s*(?:/\\s*([+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))?\\s*\\)');
|
|
458
|
+
this.z1n_1 = Regex_init_$Create$('oklab\\(((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s*(?:/\\s*([+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))?\\s*\\)');
|
|
459
|
+
this.a1o_1 = Regex_init_$Create$('oklch\\(((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?(?:deg|grad|rad|turn)?))\\s*(?:/\\s*([+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))?\\s*\\)');
|
|
460
|
+
this.b1o_1 = Regex_init_$Create$('color\\(([\\w\\-]+)\\s+((?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?)(?:\\s+(?:none|[+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))*)\\s*(?:/\\s*([+-]?(?:\\d+|\\d*\\.\\d+)(?:[eE][+-]?\\d+)?%?))?\\s*\\)');
|
|
464
461
|
}
|
|
465
462
|
var PATTERNS_instance;
|
|
466
463
|
function PATTERNS_getInstance() {
|
|
@@ -469,88 +466,88 @@
|
|
|
469
466
|
return PATTERNS_instance;
|
|
470
467
|
}
|
|
471
468
|
function rgb(match) {
|
|
472
|
-
var r = percentOrNumber(match.
|
|
473
|
-
var g = percentOrNumber(match.
|
|
474
|
-
var b = percentOrNumber(match.
|
|
475
|
-
var a = alpha(match.
|
|
469
|
+
var r = percentOrNumber(match.nd().o(1), Companion_getInstance_6().j1n().o(0).h1n_1);
|
|
470
|
+
var g = percentOrNumber(match.nd().o(2), Companion_getInstance_6().j1n().o(1).h1n_1);
|
|
471
|
+
var b = percentOrNumber(match.nd().o(3), Companion_getInstance_6().j1n().o(2).h1n_1);
|
|
472
|
+
var a = alpha(match.nd().o(4));
|
|
476
473
|
var tmp;
|
|
477
|
-
if (endsWith(match.
|
|
478
|
-
tmp = Companion_getInstance_6().
|
|
474
|
+
if (endsWith(match.nd().o(1), '%')) {
|
|
475
|
+
tmp = Companion_getInstance_6().e1o(r, g, b, a);
|
|
479
476
|
} else {
|
|
480
|
-
tmp = Companion_getInstance_6().
|
|
477
|
+
tmp = Companion_getInstance_6().e1o(r / 255.0, g / 255.0, b / 255.0, a);
|
|
481
478
|
}
|
|
482
479
|
return tmp;
|
|
483
480
|
}
|
|
484
481
|
function hsl(match) {
|
|
485
|
-
var h = hue(match.
|
|
486
|
-
var s = percentOrNumber(match.
|
|
487
|
-
var l = percentOrNumber(match.
|
|
488
|
-
var a = alpha(match.
|
|
482
|
+
var h = hue(match.nd().o(1));
|
|
483
|
+
var s = percentOrNumber(match.nd().o(2), Companion_getInstance_0().f1o_1.o(1).h1n_1);
|
|
484
|
+
var l = percentOrNumber(match.nd().o(3), Companion_getInstance_0().f1o_1.o(2).h1n_1);
|
|
485
|
+
var a = alpha(match.nd().o(4));
|
|
489
486
|
return new HSL(h, s, l, a);
|
|
490
487
|
}
|
|
491
488
|
function lab(match) {
|
|
492
|
-
var l = percentOrNumber(match.
|
|
493
|
-
var a = percentOrNumber(match.
|
|
494
|
-
var b = percentOrNumber(match.
|
|
495
|
-
var alpha_0 = alpha(match.
|
|
496
|
-
return LABColorSpaces_getInstance().
|
|
489
|
+
var l = percentOrNumber(match.nd().o(1), Companion_getInstance_2().j1n().o(0).h1n_1);
|
|
490
|
+
var a = percentOrNumber(match.nd().o(2), Companion_getInstance_2().j1n().o(1).h1n_1);
|
|
491
|
+
var b = percentOrNumber(match.nd().o(3), Companion_getInstance_2().j1n().o(2).h1n_1);
|
|
492
|
+
var alpha_0 = alpha(match.nd().o(4));
|
|
493
|
+
return LABColorSpaces_getInstance().i1o_1.e1o(l, a, b, alpha_0);
|
|
497
494
|
}
|
|
498
495
|
function lch(match) {
|
|
499
|
-
var l = percentOrNumber(match.
|
|
500
|
-
var c = percentOrNumber(match.
|
|
501
|
-
var h = hue(match.
|
|
502
|
-
var a = alpha(match.
|
|
503
|
-
return LCHabColorSpaces_getInstance().
|
|
496
|
+
var l = percentOrNumber(match.nd().o(1), Companion_getInstance_3().j1n().o(0).h1n_1);
|
|
497
|
+
var c = percentOrNumber(match.nd().o(2), Companion_getInstance_3().j1n().o(1).h1n_1);
|
|
498
|
+
var h = hue(match.nd().o(3));
|
|
499
|
+
var a = alpha(match.nd().o(4));
|
|
500
|
+
return LCHabColorSpaces_getInstance().l1o_1.e1o(l, c, h, a);
|
|
504
501
|
}
|
|
505
502
|
function hwb(match) {
|
|
506
|
-
var h = hue(match.
|
|
507
|
-
var w = percentOrNumber(match.
|
|
508
|
-
var b = percentOrNumber(match.
|
|
509
|
-
var a = alpha(match.
|
|
503
|
+
var h = hue(match.nd().o(1));
|
|
504
|
+
var w = percentOrNumber(match.nd().o(2), Companion_getInstance_1().m1o_1.o(1).h1n_1);
|
|
505
|
+
var b = percentOrNumber(match.nd().o(3), Companion_getInstance_1().m1o_1.o(2).h1n_1);
|
|
506
|
+
var a = alpha(match.nd().o(4));
|
|
510
507
|
return new HWB(h, w, b, a);
|
|
511
508
|
}
|
|
512
509
|
function oklab(match) {
|
|
513
|
-
var l = percentOrNumber(match.
|
|
514
|
-
var a = percentOrNumber(match.
|
|
515
|
-
var b = percentOrNumber(match.
|
|
516
|
-
var alpha_0 = alpha(match.
|
|
510
|
+
var l = percentOrNumber(match.nd().o(1), Companion_getInstance_4().n1o_1.o(0).h1n_1);
|
|
511
|
+
var a = percentOrNumber(match.nd().o(2), Companion_getInstance_4().n1o_1.o(1).h1n_1);
|
|
512
|
+
var b = percentOrNumber(match.nd().o(3), Companion_getInstance_4().n1o_1.o(2).h1n_1);
|
|
513
|
+
var alpha_0 = alpha(match.nd().o(4));
|
|
517
514
|
return new Oklab(l, a, b, alpha_0);
|
|
518
515
|
}
|
|
519
516
|
function oklch(match) {
|
|
520
|
-
var l = percentOrNumber(match.
|
|
521
|
-
var c = percentOrNumber(match.
|
|
522
|
-
var h = hue(match.
|
|
523
|
-
var a = alpha(match.
|
|
517
|
+
var l = percentOrNumber(match.nd().o(1), Companion_getInstance_5().o1o_1.o(0).h1n_1);
|
|
518
|
+
var c = percentOrNumber(match.nd().o(2), Companion_getInstance_5().o1o_1.o(1).h1n_1);
|
|
519
|
+
var h = hue(match.nd().o(3));
|
|
520
|
+
var a = alpha(match.nd().o(4));
|
|
524
521
|
return new Oklch(l, c, h, a);
|
|
525
522
|
}
|
|
526
523
|
function color(match, customColorSpaces) {
|
|
527
|
-
var name = match.
|
|
524
|
+
var name = match.nd().o(1);
|
|
528
525
|
var tmp;
|
|
529
526
|
switch (name) {
|
|
530
527
|
case 'srgb':
|
|
531
528
|
tmp = SRGB_getInstance();
|
|
532
529
|
break;
|
|
533
530
|
case 'srgb-linear':
|
|
534
|
-
tmp = RGBColorSpaces_getInstance().
|
|
531
|
+
tmp = RGBColorSpaces_getInstance().q1o_1;
|
|
535
532
|
break;
|
|
536
533
|
case 'display-p3':
|
|
537
|
-
tmp = RGBColorSpaces_getInstance().
|
|
534
|
+
tmp = RGBColorSpaces_getInstance().z1o_1;
|
|
538
535
|
break;
|
|
539
536
|
case 'a98-rgb':
|
|
540
|
-
tmp = RGBColorSpaces_getInstance().
|
|
537
|
+
tmp = RGBColorSpaces_getInstance().v1o_1;
|
|
541
538
|
break;
|
|
542
539
|
case 'prophoto-rgb':
|
|
543
|
-
tmp = RGBColorSpaces_getInstance().
|
|
540
|
+
tmp = RGBColorSpaces_getInstance().a1p_1;
|
|
544
541
|
break;
|
|
545
542
|
case 'rec2020':
|
|
546
|
-
tmp = RGBColorSpaces_getInstance().
|
|
543
|
+
tmp = RGBColorSpaces_getInstance().w1o_1;
|
|
547
544
|
break;
|
|
548
545
|
case 'xyz':
|
|
549
546
|
case 'xyz-d50':
|
|
550
|
-
tmp = XYZColorSpaces_getInstance().
|
|
547
|
+
tmp = XYZColorSpaces_getInstance().c1p_1;
|
|
551
548
|
break;
|
|
552
549
|
case 'xyz-d65':
|
|
553
|
-
tmp = XYZColorSpaces_getInstance().
|
|
550
|
+
tmp = XYZColorSpaces_getInstance().b1p_1;
|
|
554
551
|
break;
|
|
555
552
|
default:
|
|
556
553
|
var tmp$ret$1;
|
|
@@ -568,22 +565,22 @@
|
|
|
568
565
|
tmp$ret$1 = null;
|
|
569
566
|
}
|
|
570
567
|
|
|
571
|
-
var
|
|
572
|
-
tmp =
|
|
568
|
+
var tmp10_safe_receiver = tmp$ret$1;
|
|
569
|
+
tmp = tmp10_safe_receiver == null ? null : tmp10_safe_receiver.h2();
|
|
573
570
|
break;
|
|
574
571
|
}
|
|
575
|
-
var
|
|
572
|
+
var tmp0_elvis_lhs = tmp;
|
|
576
573
|
var tmp_0;
|
|
577
|
-
if (
|
|
574
|
+
if (tmp0_elvis_lhs == null) {
|
|
578
575
|
return null;
|
|
579
576
|
} else {
|
|
580
|
-
tmp_0 =
|
|
577
|
+
tmp_0 = tmp0_elvis_lhs;
|
|
581
578
|
}
|
|
582
579
|
var space = tmp_0;
|
|
583
580
|
// Inline function 'kotlin.collections.mapIndexed' call
|
|
584
581
|
// Inline function 'kotlin.text.split' call
|
|
585
|
-
var this_0 = match.
|
|
586
|
-
var this_1 = Regex_init_$Create$('\\s+').
|
|
582
|
+
var this_0 = match.nd().o(2);
|
|
583
|
+
var this_1 = Regex_init_$Create$('\\s+').vc(this_0, 0);
|
|
587
584
|
// Inline function 'kotlin.collections.mapIndexedTo' call
|
|
588
585
|
var destination = ArrayList_init_$Create$(collectionSizeOrDefault(this_1, 10));
|
|
589
586
|
var index = 0;
|
|
@@ -594,12 +591,12 @@
|
|
|
594
591
|
var tmp1 = index;
|
|
595
592
|
index = tmp1 + 1 | 0;
|
|
596
593
|
var i = checkIndexOverflow(tmp1);
|
|
597
|
-
var tmp$ret$3 = percentOrNumber(item, space.
|
|
594
|
+
var tmp$ret$3 = percentOrNumber(item, space.j1n().o(i).h1n_1);
|
|
598
595
|
destination.e(tmp$ret$3);
|
|
599
596
|
}
|
|
600
597
|
var values = destination;
|
|
601
598
|
var tmp_1 = 0;
|
|
602
|
-
var tmp_2 = space.
|
|
599
|
+
var tmp_2 = space.j1n().m();
|
|
603
600
|
var tmp_3 = new Float32Array(tmp_2);
|
|
604
601
|
while (tmp_1 < tmp_2) {
|
|
605
602
|
var tmp_4 = tmp_1;
|
|
@@ -616,8 +613,8 @@
|
|
|
616
613
|
tmp_1 = tmp_1 + 1 | 0;
|
|
617
614
|
}
|
|
618
615
|
var components = tmp_3;
|
|
619
|
-
components[get_lastIndex(components)] = alpha(match.
|
|
620
|
-
return space.
|
|
616
|
+
components[get_lastIndex(components)] = alpha(match.nd().o(3));
|
|
617
|
+
return space.k1n(components);
|
|
621
618
|
}
|
|
622
619
|
function percentOrNumber(str, max) {
|
|
623
620
|
var tmp;
|
|
@@ -748,40 +745,40 @@
|
|
|
748
745
|
while (tmp0_iterator.k()) {
|
|
749
746
|
var element = tmp0_iterator.l();
|
|
750
747
|
// Inline function 'com.github.ajalt.colormath.formatCssStringOrNull.<anonymous>' call
|
|
751
|
-
if (equals(element.h2(), _this__u8e3s4.
|
|
748
|
+
if (equals(element.h2(), _this__u8e3s4.b1m())) {
|
|
752
749
|
tmp$ret$1 = element;
|
|
753
750
|
break $l$block;
|
|
754
751
|
}
|
|
755
752
|
}
|
|
756
753
|
tmp$ret$1 = null;
|
|
757
754
|
}
|
|
758
|
-
var
|
|
759
|
-
var
|
|
755
|
+
var tmp11_safe_receiver = tmp$ret$1;
|
|
756
|
+
var tmp12_safe_receiver = tmp11_safe_receiver == null ? null : tmp11_safe_receiver.g2();
|
|
760
757
|
var tmp;
|
|
761
|
-
if (
|
|
758
|
+
if (tmp12_safe_receiver == null) {
|
|
762
759
|
tmp = null;
|
|
763
760
|
} else {
|
|
764
761
|
// Inline function 'kotlin.let' call
|
|
765
762
|
// Inline function 'kotlin.contracts.contract' call
|
|
766
763
|
// Inline function 'com.github.ajalt.colormath.formatCssStringOrNull.<anonymous>' call
|
|
767
|
-
tmp = renderFn(_this__u8e3s4,
|
|
764
|
+
tmp = renderFn(_this__u8e3s4, tmp12_safe_receiver, unitsPercent, alphaPercent, renderAlpha);
|
|
768
765
|
}
|
|
769
|
-
var
|
|
766
|
+
var tmp0_elvis_lhs = tmp;
|
|
770
767
|
var tmp_0;
|
|
771
|
-
if (
|
|
768
|
+
if (tmp0_elvis_lhs == null) {
|
|
772
769
|
var tmp_1;
|
|
773
770
|
if (_this__u8e3s4 instanceof RGB) {
|
|
774
|
-
var
|
|
775
|
-
tmp_1 = equals(
|
|
771
|
+
var tmp14_subject = _this__u8e3s4.i1m_1;
|
|
772
|
+
tmp_1 = equals(tmp14_subject, SRGB_getInstance()) ? renderSRGB(_this__u8e3s4, legacyFormat, legacyName, unitsPercent, alphaPercent, renderAlpha) : equals(tmp14_subject, RGBColorSpaces_getInstance().z1o_1) ? renderFn(_this__u8e3s4, 'display-p3', unitsPercent, alphaPercent, renderAlpha) : equals(tmp14_subject, RGBColorSpaces_getInstance().v1o_1) ? renderFn(_this__u8e3s4, 'a98-rgb', unitsPercent, alphaPercent, renderAlpha) : equals(tmp14_subject, RGBColorSpaces_getInstance().a1p_1) ? renderFn(_this__u8e3s4, 'prophoto-rgb', unitsPercent, alphaPercent, renderAlpha) : equals(tmp14_subject, RGBColorSpaces_getInstance().w1o_1) ? renderFn(_this__u8e3s4, 'rec2020', unitsPercent, alphaPercent, renderAlpha) : equals(tmp14_subject, RGBColorSpaces_getInstance().q1o_1) ? renderFn(_this__u8e3s4, 'srgb-linear', unitsPercent, alphaPercent, renderAlpha) : null;
|
|
776
773
|
} else {
|
|
777
774
|
if (_this__u8e3s4 instanceof HSL) {
|
|
778
775
|
tmp_1 = renderHsl(_this__u8e3s4, legacyFormat, legacyName, hueUnit, alphaPercent, renderAlpha);
|
|
779
776
|
} else {
|
|
780
777
|
if (_this__u8e3s4 instanceof LAB) {
|
|
781
|
-
tmp_1 = renderLab(convertTo(_this__u8e3s4, LABColorSpaces_getInstance().
|
|
778
|
+
tmp_1 = renderLab(convertTo(_this__u8e3s4, LABColorSpaces_getInstance().i1o_1), alphaPercent, renderAlpha);
|
|
782
779
|
} else {
|
|
783
780
|
if (_this__u8e3s4 instanceof LCHab) {
|
|
784
|
-
tmp_1 = renderLCH(convertTo(_this__u8e3s4, LCHabColorSpaces_getInstance().
|
|
781
|
+
tmp_1 = renderLCH(convertTo(_this__u8e3s4, LCHabColorSpaces_getInstance().l1o_1), hueUnit, alphaPercent, renderAlpha);
|
|
785
782
|
} else {
|
|
786
783
|
if (_this__u8e3s4 instanceof HWB) {
|
|
787
784
|
tmp_1 = renderHWB(_this__u8e3s4, hueUnit, alphaPercent, renderAlpha);
|
|
@@ -793,7 +790,7 @@
|
|
|
793
790
|
tmp_1 = renderOklch(_this__u8e3s4, hueUnit, alphaPercent, renderAlpha);
|
|
794
791
|
} else {
|
|
795
792
|
if (_this__u8e3s4 instanceof XYZ) {
|
|
796
|
-
tmp_1 = _this__u8e3s4.
|
|
793
|
+
tmp_1 = _this__u8e3s4.p1m_1.i1n().equals(Illuminant_getInstance().j1p_1) ? renderFn(_this__u8e3s4, 'xyz-d65', unitsPercent, alphaPercent, renderAlpha) : renderFn(_this__u8e3s4.d1p(XYZColorSpaces_getInstance().c1p_1), 'xyz', unitsPercent, alphaPercent, renderAlpha);
|
|
797
794
|
} else {
|
|
798
795
|
tmp_1 = null;
|
|
799
796
|
}
|
|
@@ -806,7 +803,7 @@
|
|
|
806
803
|
}
|
|
807
804
|
tmp_0 = tmp_1;
|
|
808
805
|
} else {
|
|
809
|
-
tmp_0 =
|
|
806
|
+
tmp_0 = tmp0_elvis_lhs;
|
|
810
807
|
}
|
|
811
808
|
return tmp_0;
|
|
812
809
|
}
|
|
@@ -817,40 +814,40 @@
|
|
|
817
814
|
var this_0 = StringBuilder_init_$Create$();
|
|
818
815
|
// Inline function 'kotlin.contracts.contract' call
|
|
819
816
|
// Inline function 'com.github.ajalt.colormath.renderFn.<anonymous>' call
|
|
820
|
-
this_0.
|
|
821
|
-
var tmp = dropLast_0(_this__u8e3s4.
|
|
817
|
+
this_0.k8('color(').k8(name).k8(' ');
|
|
818
|
+
var tmp = dropLast_0(_this__u8e3s4.u5(), 1);
|
|
822
819
|
joinTo(tmp, this_0, ' ', VOID, VOID, VOID, VOID, renderFn$lambda(unitsPercent));
|
|
823
|
-
this_0.
|
|
824
|
-
this_0.
|
|
820
|
+
this_0.k8(renderAlpha(_this__u8e3s4, false, renderAlpha_0, alphaPercent));
|
|
821
|
+
this_0.k8(')');
|
|
825
822
|
return this_0.toString();
|
|
826
823
|
}
|
|
827
824
|
function get_dashName(_this__u8e3s4) {
|
|
828
825
|
// Inline function 'kotlin.text.lowercase' call
|
|
829
826
|
// Inline function 'kotlin.text.replace' call
|
|
830
|
-
var this_0 = _this__u8e3s4.
|
|
827
|
+
var this_0 = _this__u8e3s4.b1m().q2();
|
|
831
828
|
// Inline function 'kotlin.js.asDynamic' call
|
|
832
|
-
return '--' + Regex_init_$Create$('\\W').
|
|
829
|
+
return '--' + Regex_init_$Create$('\\W').qc(this_0, '-').toLowerCase();
|
|
833
830
|
}
|
|
834
831
|
function renderSRGB(_this__u8e3s4, commas, namedRgba, rgbPercent, alphaPercent, renderAlpha) {
|
|
835
|
-
return renderColorFn(_this__u8e3s4, namedRgba ? 'rgba' : 'rgb', [rgbPercent ? render(_this__u8e3s4.
|
|
832
|
+
return renderColorFn(_this__u8e3s4, namedRgba ? 'rgba' : 'rgb', [rgbPercent ? render(_this__u8e3s4.e1m_1, true) : UByte__toString_impl_v72jg(_RGBInt___get_r__impl__dulq0e(_this__u8e3s4.m1p())), rgbPercent ? render(_this__u8e3s4.f1m_1, true) : UByte__toString_impl_v72jg(_RGBInt___get_g__impl__o93c71(_this__u8e3s4.m1p())), rgbPercent ? render(_this__u8e3s4.g1m_1, true) : UByte__toString_impl_v72jg(_RGBInt___get_b__impl__m772ua(_this__u8e3s4.m1p()))], alphaPercent, renderAlpha, commas);
|
|
836
833
|
}
|
|
837
834
|
function renderHsl(_this__u8e3s4, commas, namedHsla, hueUnit, alphaPercent, renderAlpha) {
|
|
838
|
-
return renderColorFn(_this__u8e3s4, namedHsla ? 'hsla' : 'hsl', [renderHue(_this__u8e3s4, hueUnit), render(_this__u8e3s4.
|
|
835
|
+
return renderColorFn(_this__u8e3s4, namedHsla ? 'hsla' : 'hsl', [renderHue(_this__u8e3s4, hueUnit), render(_this__u8e3s4.o1p_1, true), render(_this__u8e3s4.p1p_1, true)], alphaPercent, renderAlpha, commas);
|
|
839
836
|
}
|
|
840
837
|
function renderLab(_this__u8e3s4, alphaPercent, renderAlpha) {
|
|
841
|
-
return renderColorFn(_this__u8e3s4, 'lab', [render(_this__u8e3s4.
|
|
838
|
+
return renderColorFn(_this__u8e3s4, 'lab', [render(_this__u8e3s4.r1m_1 / 100, true), render(_this__u8e3s4.s1m_1), render(_this__u8e3s4.t1m_1)], alphaPercent, renderAlpha);
|
|
842
839
|
}
|
|
843
840
|
function renderLCH(_this__u8e3s4, hueUnit, alphaPercent, renderAlpha) {
|
|
844
|
-
return renderColorFn(_this__u8e3s4, 'lch', [render(_this__u8e3s4.
|
|
841
|
+
return renderColorFn(_this__u8e3s4, 'lch', [render(_this__u8e3s4.r1p_1 / 100, true), render(_this__u8e3s4.s1p_1), renderHue(_this__u8e3s4, hueUnit)], alphaPercent, renderAlpha);
|
|
845
842
|
}
|
|
846
843
|
function renderHWB(_this__u8e3s4, hueUnit, alphaPercent, renderAlpha) {
|
|
847
|
-
return renderColorFn(_this__u8e3s4, 'hwb', [renderHue(_this__u8e3s4, hueUnit), render(_this__u8e3s4.
|
|
844
|
+
return renderColorFn(_this__u8e3s4, 'hwb', [renderHue(_this__u8e3s4, hueUnit), render(_this__u8e3s4.x1p_1, true), render(_this__u8e3s4.y1p_1, true)], alphaPercent, renderAlpha);
|
|
848
845
|
}
|
|
849
846
|
function renderOklab(_this__u8e3s4, alphaPercent, renderAlpha) {
|
|
850
|
-
return renderColorFn(_this__u8e3s4, 'oklab', [render(_this__u8e3s4.
|
|
847
|
+
return renderColorFn(_this__u8e3s4, 'oklab', [render(_this__u8e3s4.z1m_1, true), render(_this__u8e3s4.a1n_1), render(_this__u8e3s4.b1n_1)], alphaPercent, renderAlpha);
|
|
851
848
|
}
|
|
852
849
|
function renderOklch(_this__u8e3s4, hueUnit, alphaPercent, renderAlpha) {
|
|
853
|
-
return renderColorFn(_this__u8e3s4, 'oklch', [render(_this__u8e3s4.
|
|
850
|
+
return renderColorFn(_this__u8e3s4, 'oklch', [render(_this__u8e3s4.a1q_1, true), render(_this__u8e3s4.b1q_1), renderHue(_this__u8e3s4, hueUnit)], alphaPercent, renderAlpha);
|
|
854
851
|
}
|
|
855
852
|
function render(_this__u8e3s4, percent, precision) {
|
|
856
853
|
percent = percent === VOID ? false : percent;
|
|
@@ -877,8 +874,8 @@
|
|
|
877
874
|
}
|
|
878
875
|
function renderAlpha(_this__u8e3s4, commas, renderAlpha, alphaPercent) {
|
|
879
876
|
var tmp;
|
|
880
|
-
if (renderAlpha.equals(RenderCondition_ALWAYS_getInstance()) || (renderAlpha.equals(RenderCondition_AUTO_getInstance()) && !isNaN_0(_this__u8e3s4.
|
|
881
|
-
tmp = (commas ? ', ' : ' / ') + render(nanToOne(_this__u8e3s4.
|
|
877
|
+
if (renderAlpha.equals(RenderCondition_ALWAYS_getInstance()) || (renderAlpha.equals(RenderCondition_AUTO_getInstance()) && !isNaN_0(_this__u8e3s4.a1m()) && !(_this__u8e3s4.a1m() === 1.0))) {
|
|
878
|
+
tmp = (commas ? ', ' : ' / ') + render(nanToOne(_this__u8e3s4.a1m()), alphaPercent);
|
|
882
879
|
} else {
|
|
883
880
|
tmp = '';
|
|
884
881
|
}
|
|
@@ -893,24 +890,24 @@
|
|
|
893
890
|
// Inline function 'kotlin.contracts.contract' call
|
|
894
891
|
// Inline function 'com.github.ajalt.colormath.renderColorFn.<anonymous>' call
|
|
895
892
|
var sep = commas ? ', ' : ' ';
|
|
896
|
-
this_0.
|
|
893
|
+
this_0.k8(name).k8('(');
|
|
897
894
|
joinTo_0(components, this_0, sep);
|
|
898
|
-
this_0.
|
|
899
|
-
this_0.
|
|
895
|
+
this_0.k8(renderAlpha(_this__u8e3s4, commas, renderAlpha_0, alphaPercent));
|
|
896
|
+
this_0.k8(')');
|
|
900
897
|
return this_0.toString();
|
|
901
898
|
}
|
|
902
899
|
function renderHue(_this__u8e3s4, hueUnit) {
|
|
903
900
|
var tmp;
|
|
904
|
-
if (isNaN_0(_this__u8e3s4.
|
|
901
|
+
if (isNaN_0(_this__u8e3s4.e1q())) {
|
|
905
902
|
tmp = 'none';
|
|
906
903
|
} else {
|
|
907
904
|
var tmp_0;
|
|
908
905
|
switch (hueUnit.p2_1) {
|
|
909
906
|
case 0:
|
|
910
|
-
tmp_0 = render(_this__u8e3s4.
|
|
907
|
+
tmp_0 = render(_this__u8e3s4.e1q());
|
|
911
908
|
break;
|
|
912
909
|
case 1:
|
|
913
|
-
tmp_0 = render(_this__u8e3s4.
|
|
910
|
+
tmp_0 = render(_this__u8e3s4.e1q()) + 'deg';
|
|
914
911
|
break;
|
|
915
912
|
case 2:
|
|
916
913
|
tmp_0 = render(hueAsRad(_this__u8e3s4)) + 'rad';
|
|
@@ -947,27 +944,27 @@
|
|
|
947
944
|
return AngleUnit_AUTO_instance;
|
|
948
945
|
}
|
|
949
946
|
function hueOr(_this__u8e3s4, whenNaN) {
|
|
950
|
-
return isNaN_0(_this__u8e3s4.
|
|
947
|
+
return isNaN_0(_this__u8e3s4.e1q()) ? numberToDouble(whenNaN) : _this__u8e3s4.e1q();
|
|
951
948
|
}
|
|
952
949
|
function hueAsRad(_this__u8e3s4) {
|
|
953
|
-
return degToRad(_this__u8e3s4.
|
|
950
|
+
return degToRad(_this__u8e3s4.e1q());
|
|
954
951
|
}
|
|
955
952
|
function hueAsGrad(_this__u8e3s4) {
|
|
956
|
-
return degToGrad(_this__u8e3s4.
|
|
953
|
+
return degToGrad(_this__u8e3s4.e1q());
|
|
957
954
|
}
|
|
958
955
|
function hueAsTurns(_this__u8e3s4) {
|
|
959
|
-
return degToTurns(_this__u8e3s4.
|
|
956
|
+
return degToTurns(_this__u8e3s4.e1q());
|
|
960
957
|
}
|
|
961
958
|
function WhitePoint(name, chromaticity) {
|
|
962
|
-
this.
|
|
963
|
-
this.
|
|
959
|
+
this.f1q_1 = name;
|
|
960
|
+
this.g1q_1 = chromaticity;
|
|
964
961
|
}
|
|
965
962
|
protoOf(WhitePoint).toString = function () {
|
|
966
|
-
return this.
|
|
963
|
+
return this.f1q_1;
|
|
967
964
|
};
|
|
968
965
|
protoOf(WhitePoint).hashCode = function () {
|
|
969
|
-
var result = getStringHashCode(this.
|
|
970
|
-
result = imul(result, 31) + this.
|
|
966
|
+
var result = getStringHashCode(this.f1q_1);
|
|
967
|
+
result = imul(result, 31) + this.g1q_1.hashCode() | 0;
|
|
971
968
|
return result;
|
|
972
969
|
};
|
|
973
970
|
protoOf(WhitePoint).equals = function (other) {
|
|
@@ -976,22 +973,22 @@
|
|
|
976
973
|
if (!(other instanceof WhitePoint))
|
|
977
974
|
return false;
|
|
978
975
|
var tmp0_other_with_cast = other instanceof WhitePoint ? other : THROW_CCE();
|
|
979
|
-
if (!(this.
|
|
976
|
+
if (!(this.f1q_1 === tmp0_other_with_cast.f1q_1))
|
|
980
977
|
return false;
|
|
981
|
-
if (!this.
|
|
978
|
+
if (!this.g1q_1.equals(tmp0_other_with_cast.g1q_1))
|
|
982
979
|
return false;
|
|
983
980
|
return true;
|
|
984
981
|
};
|
|
985
982
|
function Illuminant() {
|
|
986
983
|
Illuminant_instance = this;
|
|
987
|
-
this.
|
|
988
|
-
this.
|
|
989
|
-
this.
|
|
990
|
-
this.
|
|
991
|
-
this.
|
|
992
|
-
this.
|
|
993
|
-
this.
|
|
994
|
-
this.
|
|
984
|
+
this.e1p_1 = new WhitePoint('A', xyY_init_$Create$(0.44758, 0.40745));
|
|
985
|
+
this.f1p_1 = new WhitePoint('B', xyY_init_$Create$(0.34842, 0.35161));
|
|
986
|
+
this.g1p_1 = new WhitePoint('C', xyY_init_$Create$(0.31006, 0.31616));
|
|
987
|
+
this.h1p_1 = new WhitePoint('D50', xyY_init_$Create$(0.3457, 0.3585));
|
|
988
|
+
this.i1p_1 = new WhitePoint('D55', xyY_init_$Create$(0.33243, 0.34744));
|
|
989
|
+
this.j1p_1 = new WhitePoint('D65', xyY_init_$Create$(0.3127, 0.329));
|
|
990
|
+
this.k1p_1 = new WhitePoint('D75', xyY_init_$Create$(0.29903, 0.31488));
|
|
991
|
+
this.l1p_1 = new WhitePoint('E', xyY_init_$Create$(1.0 / 3.0, 1.0 / 3.0));
|
|
995
992
|
}
|
|
996
993
|
var Illuminant_instance;
|
|
997
994
|
function Illuminant_getInstance() {
|
|
@@ -1071,29 +1068,17 @@
|
|
|
1071
1068
|
return CAT02_LMS_TO_XYZ;
|
|
1072
1069
|
}
|
|
1073
1070
|
var CAT02_LMS_TO_XYZ;
|
|
1074
|
-
function get_CIE_E() {
|
|
1075
|
-
return CIE_E;
|
|
1076
|
-
}
|
|
1077
|
-
var CIE_E;
|
|
1078
|
-
function get_CIE_K() {
|
|
1079
|
-
return CIE_K;
|
|
1080
|
-
}
|
|
1081
|
-
var CIE_K;
|
|
1082
|
-
function get_CIE_E_times_K() {
|
|
1083
|
-
return CIE_E_times_K;
|
|
1084
|
-
}
|
|
1085
|
-
var CIE_E_times_K;
|
|
1086
1071
|
var properties_initialized_Constants_kt_w4w61t;
|
|
1087
1072
|
function _init_properties_Constants_kt__atb1ur() {
|
|
1088
1073
|
if (!properties_initialized_Constants_kt_w4w61t) {
|
|
1089
1074
|
properties_initialized_Constants_kt_w4w61t = true;
|
|
1090
|
-
CAT02_XYZ_TO_LMS = _Matrix___init__impl__q3kp4w_0(0.7328, 0.4296, -0.1624, -0.7036, 1.6975, 0.0061, 0.003, 0.0136, 0.9834);
|
|
1075
|
+
CAT02_XYZ_TO_LMS = _Matrix___init__impl__q3kp4w_0(+0.7328, +0.4296, -0.1624, -0.7036, +1.6975, +0.0061, +0.003, +0.0136, +0.9834);
|
|
1091
1076
|
CAT02_LMS_TO_XYZ = inverse(get_CAT02_XYZ_TO_LMS());
|
|
1092
1077
|
}
|
|
1093
1078
|
}
|
|
1094
1079
|
function CssColors() {
|
|
1095
1080
|
CssColors_instance = this;
|
|
1096
|
-
this.
|
|
1081
|
+
this.l1n_1 = mapOf([to('black', Companion_getInstance_6().h1q(0, 0, 0)), to('silver', Companion_getInstance_6().h1q(192, 192, 192)), to('gray', Companion_getInstance_6().h1q(128, 128, 128)), to('white', Companion_getInstance_6().h1q(255, 255, 255)), to('maroon', Companion_getInstance_6().h1q(128, 0, 0)), to('red', Companion_getInstance_6().h1q(255, 0, 0)), to('purple', Companion_getInstance_6().h1q(128, 0, 128)), to('fuchsia', Companion_getInstance_6().h1q(255, 0, 255)), to('green', Companion_getInstance_6().h1q(0, 128, 0)), to('lime', Companion_getInstance_6().h1q(0, 255, 0)), to('olive', Companion_getInstance_6().h1q(128, 128, 0)), to('yellow', Companion_getInstance_6().h1q(255, 255, 0)), to('navy', Companion_getInstance_6().h1q(0, 0, 128)), to('blue', Companion_getInstance_6().h1q(0, 0, 255)), to('teal', Companion_getInstance_6().h1q(0, 128, 128)), to('aqua', Companion_getInstance_6().h1q(0, 255, 255)), to('orange', Companion_getInstance_6().h1q(255, 165, 0)), to('aliceblue', Companion_getInstance_6().h1q(240, 248, 255)), to('antiquewhite', Companion_getInstance_6().h1q(250, 235, 215)), to('aquamarine', Companion_getInstance_6().h1q(127, 255, 212)), to('azure', Companion_getInstance_6().h1q(240, 255, 255)), to('beige', Companion_getInstance_6().h1q(245, 245, 220)), to('bisque', Companion_getInstance_6().h1q(255, 228, 196)), to('blanchedalmond', Companion_getInstance_6().h1q(255, 235, 205)), to('blueviolet', Companion_getInstance_6().h1q(138, 43, 226)), to('brown', Companion_getInstance_6().h1q(165, 42, 42)), to('burlywood', Companion_getInstance_6().h1q(222, 184, 135)), to('cadetblue', Companion_getInstance_6().h1q(95, 158, 160)), to('chartreuse', Companion_getInstance_6().h1q(127, 255, 0)), to('chocolate', Companion_getInstance_6().h1q(210, 105, 30)), to('coral', Companion_getInstance_6().h1q(255, 127, 80)), to('cornflowerblue', Companion_getInstance_6().h1q(100, 149, 237)), to('cornsilk', Companion_getInstance_6().h1q(255, 248, 220)), to('crimson', Companion_getInstance_6().h1q(220, 20, 60)), to('cyan', Companion_getInstance_6().h1q(0, 255, 255)), to('darkblue', Companion_getInstance_6().h1q(0, 0, 139)), to('darkcyan', Companion_getInstance_6().h1q(0, 139, 139)), to('darkgoldenrod', Companion_getInstance_6().h1q(184, 134, 11)), to('darkgray', Companion_getInstance_6().h1q(169, 169, 169)), to('darkgreen', Companion_getInstance_6().h1q(0, 100, 0)), to('darkgrey', Companion_getInstance_6().h1q(169, 169, 169)), to('darkkhaki', Companion_getInstance_6().h1q(189, 183, 107)), to('darkmagenta', Companion_getInstance_6().h1q(139, 0, 139)), to('darkolivegreen', Companion_getInstance_6().h1q(85, 107, 47)), to('darkorange', Companion_getInstance_6().h1q(255, 140, 0)), to('darkorchid', Companion_getInstance_6().h1q(153, 50, 204)), to('darkred', Companion_getInstance_6().h1q(139, 0, 0)), to('darksalmon', Companion_getInstance_6().h1q(233, 150, 122)), to('darkseagreen', Companion_getInstance_6().h1q(143, 188, 143)), to('darkslateblue', Companion_getInstance_6().h1q(72, 61, 139)), to('darkslategray', Companion_getInstance_6().h1q(47, 79, 79)), to('darkslategrey', Companion_getInstance_6().h1q(47, 79, 79)), to('darkturquoise', Companion_getInstance_6().h1q(0, 206, 209)), to('darkviolet', Companion_getInstance_6().h1q(148, 0, 211)), to('deeppink', Companion_getInstance_6().h1q(255, 20, 147)), to('deepskyblue', Companion_getInstance_6().h1q(0, 191, 255)), to('dimgray', Companion_getInstance_6().h1q(105, 105, 105)), to('dimgrey', Companion_getInstance_6().h1q(105, 105, 105)), to('dodgerblue', Companion_getInstance_6().h1q(30, 144, 255)), to('firebrick', Companion_getInstance_6().h1q(178, 34, 34)), to('floralwhite', Companion_getInstance_6().h1q(255, 250, 240)), to('forestgreen', Companion_getInstance_6().h1q(34, 139, 34)), to('gainsboro', Companion_getInstance_6().h1q(220, 220, 220)), to('ghostwhite', Companion_getInstance_6().h1q(248, 248, 255)), to('gold', Companion_getInstance_6().h1q(255, 215, 0)), to('goldenrod', Companion_getInstance_6().h1q(218, 165, 32)), to('greenyellow', Companion_getInstance_6().h1q(173, 255, 47)), to('grey', Companion_getInstance_6().h1q(128, 128, 128)), to('honeydew', Companion_getInstance_6().h1q(240, 255, 240)), to('hotpink', Companion_getInstance_6().h1q(255, 105, 180)), to('indianred', Companion_getInstance_6().h1q(205, 92, 92)), to('indigo', Companion_getInstance_6().h1q(75, 0, 130)), to('ivory', Companion_getInstance_6().h1q(255, 255, 240)), to('khaki', Companion_getInstance_6().h1q(240, 230, 140)), to('lavender', Companion_getInstance_6().h1q(230, 230, 250)), to('lavenderblush', Companion_getInstance_6().h1q(255, 240, 245)), to('lawngreen', Companion_getInstance_6().h1q(124, 252, 0)), to('lemonchiffon', Companion_getInstance_6().h1q(255, 250, 205)), to('lightblue', Companion_getInstance_6().h1q(173, 216, 230)), to('lightcoral', Companion_getInstance_6().h1q(240, 128, 128)), to('lightcyan', Companion_getInstance_6().h1q(224, 255, 255)), to('lightgoldenrodyellow', Companion_getInstance_6().h1q(250, 250, 210)), to('lightgray', Companion_getInstance_6().h1q(211, 211, 211)), to('lightgreen', Companion_getInstance_6().h1q(144, 238, 144)), to('lightgrey', Companion_getInstance_6().h1q(211, 211, 211)), to('lightpink', Companion_getInstance_6().h1q(255, 182, 193)), to('lightsalmon', Companion_getInstance_6().h1q(255, 160, 122)), to('lightseagreen', Companion_getInstance_6().h1q(32, 178, 170)), to('lightskyblue', Companion_getInstance_6().h1q(135, 206, 250)), to('lightslategray', Companion_getInstance_6().h1q(119, 136, 153)), to('lightslategrey', Companion_getInstance_6().h1q(119, 136, 153)), to('lightsteelblue', Companion_getInstance_6().h1q(176, 196, 222)), to('lightyellow', Companion_getInstance_6().h1q(255, 255, 224)), to('limegreen', Companion_getInstance_6().h1q(50, 205, 50)), to('linen', Companion_getInstance_6().h1q(250, 240, 230)), to('magenta', Companion_getInstance_6().h1q(255, 0, 255)), to('mediumaquamarine', Companion_getInstance_6().h1q(102, 205, 170)), to('mediumblue', Companion_getInstance_6().h1q(0, 0, 205)), to('mediumorchid', Companion_getInstance_6().h1q(186, 85, 211)), to('mediumpurple', Companion_getInstance_6().h1q(147, 112, 219)), to('mediumseagreen', Companion_getInstance_6().h1q(60, 179, 113)), to('mediumslateblue', Companion_getInstance_6().h1q(123, 104, 238)), to('mediumspringgreen', Companion_getInstance_6().h1q(0, 250, 154)), to('mediumturquoise', Companion_getInstance_6().h1q(72, 209, 204)), to('mediumvioletred', Companion_getInstance_6().h1q(199, 21, 133)), to('midnightblue', Companion_getInstance_6().h1q(25, 25, 112)), to('mintcream', Companion_getInstance_6().h1q(245, 255, 250)), to('mistyrose', Companion_getInstance_6().h1q(255, 228, 225)), to('moccasin', Companion_getInstance_6().h1q(255, 228, 181)), to('navajowhite', Companion_getInstance_6().h1q(255, 222, 173)), to('oldlace', Companion_getInstance_6().h1q(253, 245, 230)), to('olivedrab', Companion_getInstance_6().h1q(107, 142, 35)), to('orangered', Companion_getInstance_6().h1q(255, 69, 0)), to('orchid', Companion_getInstance_6().h1q(218, 112, 214)), to('palegoldenrod', Companion_getInstance_6().h1q(238, 232, 170)), to('palegreen', Companion_getInstance_6().h1q(152, 251, 152)), to('paleturquoise', Companion_getInstance_6().h1q(175, 238, 238)), to('palevioletred', Companion_getInstance_6().h1q(219, 112, 147)), to('papayawhip', Companion_getInstance_6().h1q(255, 239, 213)), to('peachpuff', Companion_getInstance_6().h1q(255, 218, 185)), to('peru', Companion_getInstance_6().h1q(205, 133, 63)), to('pink', Companion_getInstance_6().h1q(255, 192, 203)), to('plum', Companion_getInstance_6().h1q(221, 160, 221)), to('powderblue', Companion_getInstance_6().h1q(176, 224, 230)), to('rosybrown', Companion_getInstance_6().h1q(188, 143, 143)), to('royalblue', Companion_getInstance_6().h1q(65, 105, 225)), to('saddlebrown', Companion_getInstance_6().h1q(139, 69, 19)), to('salmon', Companion_getInstance_6().h1q(250, 128, 114)), to('sandybrown', Companion_getInstance_6().h1q(244, 164, 96)), to('seagreen', Companion_getInstance_6().h1q(46, 139, 87)), to('seashell', Companion_getInstance_6().h1q(255, 245, 238)), to('sienna', Companion_getInstance_6().h1q(160, 82, 45)), to('skyblue', Companion_getInstance_6().h1q(135, 206, 235)), to('slateblue', Companion_getInstance_6().h1q(106, 90, 205)), to('slategray', Companion_getInstance_6().h1q(112, 128, 144)), to('slategrey', Companion_getInstance_6().h1q(112, 128, 144)), to('snow', Companion_getInstance_6().h1q(255, 250, 250)), to('springgreen', Companion_getInstance_6().h1q(0, 255, 127)), to('steelblue', Companion_getInstance_6().h1q(70, 130, 180)), to('tan', Companion_getInstance_6().h1q(210, 180, 140)), to('thistle', Companion_getInstance_6().h1q(216, 191, 216)), to('tomato', Companion_getInstance_6().h1q(255, 99, 71)), to('turquoise', Companion_getInstance_6().h1q(64, 224, 208)), to('violet', Companion_getInstance_6().h1q(238, 130, 238)), to('wheat', Companion_getInstance_6().h1q(245, 222, 179)), to('whitesmoke', Companion_getInstance_6().h1q(245, 245, 245)), to('yellowgreen', Companion_getInstance_6().h1q(154, 205, 50)), to('rebeccapurple', Companion_getInstance_6().h1q(102, 51, 153)), to('transparent', Companion_getInstance_6().i1q(0, 0, 0, 0))]);
|
|
1097
1082
|
}
|
|
1098
1083
|
var CssColors_instance;
|
|
1099
1084
|
function CssColors_getInstance() {
|
|
@@ -1127,10 +1112,10 @@
|
|
|
1127
1112
|
return degToRad_0(_this__u8e3s4);
|
|
1128
1113
|
}
|
|
1129
1114
|
function radToDeg_0(_this__u8e3s4) {
|
|
1130
|
-
return _this__u8e3s4 * 180.0 /
|
|
1115
|
+
return _this__u8e3s4 * 180.0 / 3.141592653589793;
|
|
1131
1116
|
}
|
|
1132
1117
|
function degToRad_0(_this__u8e3s4) {
|
|
1133
|
-
return _this__u8e3s4 *
|
|
1118
|
+
return _this__u8e3s4 * 3.141592653589793 / 180.0;
|
|
1134
1119
|
}
|
|
1135
1120
|
function gradToDeg(_this__u8e3s4) {
|
|
1136
1121
|
return _this__u8e3s4 * 0.9;
|
|
@@ -1179,22 +1164,22 @@
|
|
|
1179
1164
|
function Matrix__equals_impl_g5p8p9($this, other) {
|
|
1180
1165
|
if (!(other instanceof Matrix))
|
|
1181
1166
|
return false;
|
|
1182
|
-
var tmp0_other_with_cast = other instanceof Matrix ? other.
|
|
1167
|
+
var tmp0_other_with_cast = other instanceof Matrix ? other.j1q_1 : THROW_CCE();
|
|
1183
1168
|
if (!equals($this, tmp0_other_with_cast))
|
|
1184
1169
|
return false;
|
|
1185
1170
|
return true;
|
|
1186
1171
|
}
|
|
1187
1172
|
function Matrix(rowMajor) {
|
|
1188
|
-
this.
|
|
1173
|
+
this.j1q_1 = rowMajor;
|
|
1189
1174
|
}
|
|
1190
1175
|
protoOf(Matrix).toString = function () {
|
|
1191
|
-
return Matrix__toString_impl_l0abk0(this.
|
|
1176
|
+
return Matrix__toString_impl_l0abk0(this.j1q_1);
|
|
1192
1177
|
};
|
|
1193
1178
|
protoOf(Matrix).hashCode = function () {
|
|
1194
|
-
return Matrix__hashCode_impl_s9ntm9(this.
|
|
1179
|
+
return Matrix__hashCode_impl_s9ntm9(this.j1q_1);
|
|
1195
1180
|
};
|
|
1196
1181
|
protoOf(Matrix).equals = function (other) {
|
|
1197
|
-
return Matrix__equals_impl_g5p8p9(this.
|
|
1182
|
+
return Matrix__equals_impl_g5p8p9(this.j1q_1, other);
|
|
1198
1183
|
};
|
|
1199
1184
|
function inverse(_this__u8e3s4, inPlace) {
|
|
1200
1185
|
inPlace = inPlace === VOID ? false : inPlace;
|
|
@@ -1275,21 +1260,21 @@
|
|
|
1275
1260
|
}
|
|
1276
1261
|
function Companion_0() {
|
|
1277
1262
|
Companion_instance_1 = this;
|
|
1278
|
-
this.
|
|
1263
|
+
this.f1o_1 = polarComponentInfo('HSL', 0.0, 1.0);
|
|
1279
1264
|
}
|
|
1280
1265
|
protoOf(Companion_0).q2 = function () {
|
|
1281
1266
|
return 'HSL';
|
|
1282
1267
|
};
|
|
1283
|
-
protoOf(Companion_0).
|
|
1284
|
-
return this.
|
|
1268
|
+
protoOf(Companion_0).j1n = function () {
|
|
1269
|
+
return this.f1o_1;
|
|
1285
1270
|
};
|
|
1286
|
-
protoOf(Companion_0).
|
|
1287
|
-
return color.
|
|
1271
|
+
protoOf(Companion_0).d1n = function (color) {
|
|
1272
|
+
return color.d1m();
|
|
1288
1273
|
};
|
|
1289
|
-
protoOf(Companion_0).
|
|
1274
|
+
protoOf(Companion_0).k1n = function (components) {
|
|
1290
1275
|
// Inline function 'com.github.ajalt.colormath.internal.doCreate' call
|
|
1291
1276
|
// Inline function 'com.github.ajalt.colormath.internal.withValidComps' call
|
|
1292
|
-
var size = this.
|
|
1277
|
+
var size = this.j1n().m();
|
|
1293
1278
|
// Inline function 'kotlin.require' call
|
|
1294
1279
|
var containsLower = size - 1 | 0;
|
|
1295
1280
|
var containsArg = components.length;
|
|
@@ -1335,53 +1320,53 @@
|
|
|
1335
1320
|
function HSL(h, s, l, alpha) {
|
|
1336
1321
|
Companion_getInstance_0();
|
|
1337
1322
|
alpha = alpha === VOID ? 1.0 : alpha;
|
|
1338
|
-
this.
|
|
1339
|
-
this.
|
|
1340
|
-
this.
|
|
1341
|
-
this.
|
|
1323
|
+
this.n1p_1 = h;
|
|
1324
|
+
this.o1p_1 = s;
|
|
1325
|
+
this.p1p_1 = l;
|
|
1326
|
+
this.q1p_1 = alpha;
|
|
1342
1327
|
}
|
|
1343
|
-
protoOf(HSL).
|
|
1344
|
-
return this.
|
|
1328
|
+
protoOf(HSL).e1q = function () {
|
|
1329
|
+
return this.n1p_1;
|
|
1345
1330
|
};
|
|
1346
|
-
protoOf(HSL).
|
|
1347
|
-
return this.
|
|
1331
|
+
protoOf(HSL).a1m = function () {
|
|
1332
|
+
return this.q1p_1;
|
|
1348
1333
|
};
|
|
1349
|
-
protoOf(HSL).
|
|
1334
|
+
protoOf(HSL).b1m = function () {
|
|
1350
1335
|
return Companion_getInstance_0();
|
|
1351
1336
|
};
|
|
1352
|
-
protoOf(HSL).
|
|
1353
|
-
if (this.
|
|
1354
|
-
return Companion_getInstance_6().
|
|
1337
|
+
protoOf(HSL).c1m = function () {
|
|
1338
|
+
if (this.o1p_1 < 1.0E-7)
|
|
1339
|
+
return Companion_getInstance_6().e1o(this.p1p_1, this.p1p_1, this.p1p_1, this.q1p_1);
|
|
1355
1340
|
var h = normalizeDeg_0(hueOr(this, 0)) / 30.0;
|
|
1356
|
-
var s = this.
|
|
1357
|
-
var l = this.
|
|
1358
|
-
return SRGB_getInstance().
|
|
1341
|
+
var s = this.o1p_1;
|
|
1342
|
+
var l = this.p1p_1;
|
|
1343
|
+
return SRGB_getInstance().e1o(toSRGB$f(h, s, l, 0), toSRGB$f(h, s, l, 8), toSRGB$f(h, s, l, 4), this.q1p_1);
|
|
1359
1344
|
};
|
|
1360
|
-
protoOf(HSL).
|
|
1345
|
+
protoOf(HSL).d1m = function () {
|
|
1361
1346
|
return this;
|
|
1362
1347
|
};
|
|
1363
|
-
protoOf(HSL).
|
|
1348
|
+
protoOf(HSL).u5 = function () {
|
|
1364
1349
|
// Inline function 'kotlin.floatArrayOf' call
|
|
1365
|
-
return new Float32Array([this.
|
|
1350
|
+
return new Float32Array([this.n1p_1, this.o1p_1, this.p1p_1, this.q1p_1]);
|
|
1366
1351
|
};
|
|
1367
|
-
protoOf(HSL).
|
|
1352
|
+
protoOf(HSL).l1q = function (h, s, l, alpha) {
|
|
1368
1353
|
return new HSL(h, s, l, alpha);
|
|
1369
1354
|
};
|
|
1370
|
-
protoOf(HSL).
|
|
1371
|
-
h = h === VOID ? this.
|
|
1372
|
-
s = s === VOID ? this.
|
|
1373
|
-
l = l === VOID ? this.
|
|
1374
|
-
alpha = alpha === VOID ? this.
|
|
1375
|
-
return $super === VOID ? this.
|
|
1355
|
+
protoOf(HSL).m1q = function (h, s, l, alpha, $super) {
|
|
1356
|
+
h = h === VOID ? this.n1p_1 : h;
|
|
1357
|
+
s = s === VOID ? this.o1p_1 : s;
|
|
1358
|
+
l = l === VOID ? this.p1p_1 : l;
|
|
1359
|
+
alpha = alpha === VOID ? this.q1p_1 : alpha;
|
|
1360
|
+
return $super === VOID ? this.l1q(h, s, l, alpha) : $super.l1q.call(this, h, s, l, alpha);
|
|
1376
1361
|
};
|
|
1377
1362
|
protoOf(HSL).toString = function () {
|
|
1378
|
-
return 'HSL(h=' + this.
|
|
1363
|
+
return 'HSL(h=' + this.n1p_1 + ', s=' + this.o1p_1 + ', l=' + this.p1p_1 + ', alpha=' + this.q1p_1 + ')';
|
|
1379
1364
|
};
|
|
1380
1365
|
protoOf(HSL).hashCode = function () {
|
|
1381
|
-
var result = getNumberHashCode(this.
|
|
1382
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1383
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1384
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1366
|
+
var result = getNumberHashCode(this.n1p_1);
|
|
1367
|
+
result = imul(result, 31) + getNumberHashCode(this.o1p_1) | 0;
|
|
1368
|
+
result = imul(result, 31) + getNumberHashCode(this.p1p_1) | 0;
|
|
1369
|
+
result = imul(result, 31) + getNumberHashCode(this.q1p_1) | 0;
|
|
1385
1370
|
return result;
|
|
1386
1371
|
};
|
|
1387
1372
|
protoOf(HSL).equals = function (other) {
|
|
@@ -1390,33 +1375,33 @@
|
|
|
1390
1375
|
if (!(other instanceof HSL))
|
|
1391
1376
|
return false;
|
|
1392
1377
|
var tmp0_other_with_cast = other instanceof HSL ? other : THROW_CCE();
|
|
1393
|
-
if (!equals(this.
|
|
1378
|
+
if (!equals(this.n1p_1, tmp0_other_with_cast.n1p_1))
|
|
1394
1379
|
return false;
|
|
1395
|
-
if (!equals(this.
|
|
1380
|
+
if (!equals(this.o1p_1, tmp0_other_with_cast.o1p_1))
|
|
1396
1381
|
return false;
|
|
1397
|
-
if (!equals(this.
|
|
1382
|
+
if (!equals(this.p1p_1, tmp0_other_with_cast.p1p_1))
|
|
1398
1383
|
return false;
|
|
1399
|
-
if (!equals(this.
|
|
1384
|
+
if (!equals(this.q1p_1, tmp0_other_with_cast.q1p_1))
|
|
1400
1385
|
return false;
|
|
1401
1386
|
return true;
|
|
1402
1387
|
};
|
|
1403
1388
|
function Companion_1() {
|
|
1404
1389
|
Companion_instance_2 = this;
|
|
1405
|
-
this.
|
|
1390
|
+
this.m1o_1 = polarComponentInfo('HWB', 0.0, 1.0);
|
|
1406
1391
|
}
|
|
1407
1392
|
protoOf(Companion_1).q2 = function () {
|
|
1408
1393
|
return 'HWB';
|
|
1409
1394
|
};
|
|
1410
|
-
protoOf(Companion_1).
|
|
1411
|
-
return this.
|
|
1395
|
+
protoOf(Companion_1).j1n = function () {
|
|
1396
|
+
return this.m1o_1;
|
|
1412
1397
|
};
|
|
1413
|
-
protoOf(Companion_1).
|
|
1414
|
-
return color.
|
|
1398
|
+
protoOf(Companion_1).d1n = function (color) {
|
|
1399
|
+
return color.w1m();
|
|
1415
1400
|
};
|
|
1416
|
-
protoOf(Companion_1).
|
|
1401
|
+
protoOf(Companion_1).k1n = function (components) {
|
|
1417
1402
|
// Inline function 'com.github.ajalt.colormath.internal.doCreate' call
|
|
1418
1403
|
// Inline function 'com.github.ajalt.colormath.internal.withValidComps' call
|
|
1419
|
-
var size = this.
|
|
1404
|
+
var size = this.j1n().m();
|
|
1420
1405
|
// Inline function 'kotlin.require' call
|
|
1421
1406
|
var containsLower = size - 1 | 0;
|
|
1422
1407
|
var containsArg = components.length;
|
|
@@ -1451,28 +1436,28 @@
|
|
|
1451
1436
|
function HWB(h, w, b, alpha) {
|
|
1452
1437
|
Companion_getInstance_1();
|
|
1453
1438
|
alpha = alpha === VOID ? 1.0 : alpha;
|
|
1454
|
-
this.
|
|
1455
|
-
this.
|
|
1456
|
-
this.
|
|
1457
|
-
this.
|
|
1439
|
+
this.w1p_1 = h;
|
|
1440
|
+
this.x1p_1 = w;
|
|
1441
|
+
this.y1p_1 = b;
|
|
1442
|
+
this.z1p_1 = alpha;
|
|
1458
1443
|
}
|
|
1459
|
-
protoOf(HWB).
|
|
1460
|
-
return this.
|
|
1444
|
+
protoOf(HWB).e1q = function () {
|
|
1445
|
+
return this.w1p_1;
|
|
1461
1446
|
};
|
|
1462
|
-
protoOf(HWB).
|
|
1463
|
-
return this.
|
|
1447
|
+
protoOf(HWB).a1m = function () {
|
|
1448
|
+
return this.z1p_1;
|
|
1464
1449
|
};
|
|
1465
|
-
protoOf(HWB).
|
|
1450
|
+
protoOf(HWB).b1m = function () {
|
|
1466
1451
|
return Companion_getInstance_1();
|
|
1467
1452
|
};
|
|
1468
|
-
protoOf(HWB).
|
|
1469
|
-
var h = this.
|
|
1470
|
-
var w = this.
|
|
1471
|
-
var b = this.
|
|
1472
|
-
var a = this.
|
|
1453
|
+
protoOf(HWB).c1m = function () {
|
|
1454
|
+
var h = this.w1p_1 / 60.0;
|
|
1455
|
+
var w = this.x1p_1;
|
|
1456
|
+
var b = this.y1p_1;
|
|
1457
|
+
var a = this.z1p_1;
|
|
1473
1458
|
if (w + b >= 1) {
|
|
1474
1459
|
var gray = w / (w + b);
|
|
1475
|
-
return Companion_getInstance_6().
|
|
1460
|
+
return Companion_getInstance_6().e1o(gray, gray, gray, a);
|
|
1476
1461
|
}
|
|
1477
1462
|
var v = 1 - b;
|
|
1478
1463
|
var i = numberToInt(h);
|
|
@@ -1480,34 +1465,34 @@
|
|
|
1480
1465
|
var n = w + f * (v - w);
|
|
1481
1466
|
switch (i) {
|
|
1482
1467
|
case 1:
|
|
1483
|
-
return Companion_getInstance_6().
|
|
1468
|
+
return Companion_getInstance_6().e1o(n, v, w, a);
|
|
1484
1469
|
case 2:
|
|
1485
|
-
return Companion_getInstance_6().
|
|
1470
|
+
return Companion_getInstance_6().e1o(w, v, n, a);
|
|
1486
1471
|
case 3:
|
|
1487
|
-
return Companion_getInstance_6().
|
|
1472
|
+
return Companion_getInstance_6().e1o(w, n, v, a);
|
|
1488
1473
|
case 4:
|
|
1489
|
-
return Companion_getInstance_6().
|
|
1474
|
+
return Companion_getInstance_6().e1o(n, w, v, a);
|
|
1490
1475
|
case 5:
|
|
1491
|
-
return Companion_getInstance_6().
|
|
1476
|
+
return Companion_getInstance_6().e1o(v, w, n, a);
|
|
1492
1477
|
default:
|
|
1493
|
-
return Companion_getInstance_6().
|
|
1478
|
+
return Companion_getInstance_6().e1o(v, n, w, a);
|
|
1494
1479
|
}
|
|
1495
1480
|
};
|
|
1496
|
-
protoOf(HWB).
|
|
1481
|
+
protoOf(HWB).w1m = function () {
|
|
1497
1482
|
return this;
|
|
1498
1483
|
};
|
|
1499
|
-
protoOf(HWB).
|
|
1484
|
+
protoOf(HWB).u5 = function () {
|
|
1500
1485
|
// Inline function 'kotlin.floatArrayOf' call
|
|
1501
|
-
return new Float32Array([this.
|
|
1486
|
+
return new Float32Array([this.w1p_1, this.x1p_1, this.y1p_1, this.z1p_1]);
|
|
1502
1487
|
};
|
|
1503
1488
|
protoOf(HWB).toString = function () {
|
|
1504
|
-
return 'HWB(h=' + this.
|
|
1489
|
+
return 'HWB(h=' + this.w1p_1 + ', w=' + this.x1p_1 + ', b=' + this.y1p_1 + ', alpha=' + this.z1p_1 + ')';
|
|
1505
1490
|
};
|
|
1506
1491
|
protoOf(HWB).hashCode = function () {
|
|
1507
|
-
var result = getNumberHashCode(this.
|
|
1508
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1509
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1510
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1492
|
+
var result = getNumberHashCode(this.w1p_1);
|
|
1493
|
+
result = imul(result, 31) + getNumberHashCode(this.x1p_1) | 0;
|
|
1494
|
+
result = imul(result, 31) + getNumberHashCode(this.y1p_1) | 0;
|
|
1495
|
+
result = imul(result, 31) + getNumberHashCode(this.z1p_1) | 0;
|
|
1511
1496
|
return result;
|
|
1512
1497
|
};
|
|
1513
1498
|
protoOf(HWB).equals = function (other) {
|
|
@@ -1516,13 +1501,13 @@
|
|
|
1516
1501
|
if (!(other instanceof HWB))
|
|
1517
1502
|
return false;
|
|
1518
1503
|
var tmp0_other_with_cast = other instanceof HWB ? other : THROW_CCE();
|
|
1519
|
-
if (!equals(this.
|
|
1504
|
+
if (!equals(this.w1p_1, tmp0_other_with_cast.w1p_1))
|
|
1520
1505
|
return false;
|
|
1521
|
-
if (!equals(this.
|
|
1506
|
+
if (!equals(this.x1p_1, tmp0_other_with_cast.x1p_1))
|
|
1522
1507
|
return false;
|
|
1523
|
-
if (!equals(this.
|
|
1508
|
+
if (!equals(this.y1p_1, tmp0_other_with_cast.y1p_1))
|
|
1524
1509
|
return false;
|
|
1525
|
-
if (!equals(this.
|
|
1510
|
+
if (!equals(this.z1p_1, tmp0_other_with_cast.z1p_1))
|
|
1526
1511
|
return false;
|
|
1527
1512
|
return true;
|
|
1528
1513
|
};
|
|
@@ -1564,51 +1549,47 @@
|
|
|
1564
1549
|
var ICTCP_LMS_TO_XYZ;
|
|
1565
1550
|
function ICtCp() {
|
|
1566
1551
|
}
|
|
1567
|
-
protoOf(ICtCp).
|
|
1568
|
-
var fo = RGBColorSpaces_getInstance().
|
|
1552
|
+
protoOf(ICtCp).r1q = function () {
|
|
1553
|
+
var fo = RGBColorSpaces_getInstance().w1o_1.s1q();
|
|
1569
1554
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
1570
1555
|
var this_0 = get_ICTCP_ICTCP_to_LMS();
|
|
1571
|
-
var v0 = this.
|
|
1572
|
-
var v1 = this.
|
|
1573
|
-
var v2 = this.
|
|
1556
|
+
var v0 = this.n1q_1;
|
|
1557
|
+
var v1 = this.o1q_1;
|
|
1558
|
+
var v2 = this.p1q_1;
|
|
1574
1559
|
// Inline function 'com.github.ajalt.colormath.model.ICtCp.toBT2020.<anonymous>' call
|
|
1575
1560
|
var l = Matrix__get_impl_xogbpk(this_0, 0, 0) * v0 + Matrix__get_impl_xogbpk(this_0, 1, 0) * v1 + Matrix__get_impl_xogbpk(this_0, 2, 0) * v2;
|
|
1576
1561
|
var m = Matrix__get_impl_xogbpk(this_0, 0, 1) * v0 + Matrix__get_impl_xogbpk(this_0, 1, 1) * v1 + Matrix__get_impl_xogbpk(this_0, 2, 1) * v2;
|
|
1577
1562
|
var s = Matrix__get_impl_xogbpk(this_0, 0, 2) * v0 + Matrix__get_impl_xogbpk(this_0, 1, 2) * v1 + Matrix__get_impl_xogbpk(this_0, 2, 2) * v2;
|
|
1578
1563
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
1579
1564
|
var this_1 = get_ICTCP_LMS_to_RGB();
|
|
1580
|
-
var v0_0 = PqNonlinearity_instance.
|
|
1581
|
-
var v1_0 = PqNonlinearity_instance.
|
|
1582
|
-
var v2_0 = PqNonlinearity_instance.
|
|
1565
|
+
var v0_0 = PqNonlinearity_instance.b1r(l);
|
|
1566
|
+
var v1_0 = PqNonlinearity_instance.b1r(m);
|
|
1567
|
+
var v2_0 = PqNonlinearity_instance.b1r(s);
|
|
1583
1568
|
// Inline function 'com.github.ajalt.colormath.model.ICtCp.toBT2020.<anonymous>.<anonymous>' call
|
|
1584
1569
|
var r = Matrix__get_impl_xogbpk(this_1, 0, 0) * v0_0 + Matrix__get_impl_xogbpk(this_1, 1, 0) * v1_0 + Matrix__get_impl_xogbpk(this_1, 2, 0) * v2_0;
|
|
1585
1570
|
var g = Matrix__get_impl_xogbpk(this_1, 0, 1) * v0_0 + Matrix__get_impl_xogbpk(this_1, 1, 1) * v1_0 + Matrix__get_impl_xogbpk(this_1, 2, 1) * v2_0;
|
|
1586
1571
|
var b = Matrix__get_impl_xogbpk(this_1, 0, 2) * v0_0 + Matrix__get_impl_xogbpk(this_1, 1, 2) * v1_0 + Matrix__get_impl_xogbpk(this_1, 2, 2) * v2_0;
|
|
1587
|
-
return RGBColorSpaces_getInstance().
|
|
1572
|
+
return RGBColorSpaces_getInstance().w1o_1.e1o(fo.c1r(r), fo.c1r(g), fo.c1r(b), this.q1q_1);
|
|
1588
1573
|
};
|
|
1589
1574
|
function PqNonlinearity() {
|
|
1590
|
-
this.
|
|
1591
|
-
this.
|
|
1592
|
-
this.
|
|
1593
|
-
this.
|
|
1594
|
-
this.
|
|
1595
|
-
this.
|
|
1596
|
-
this.
|
|
1597
|
-
this.
|
|
1598
|
-
}
|
|
1599
|
-
protoOf(PqNonlinearity).
|
|
1575
|
+
this.t1q_1 = 0.1593017578125;
|
|
1576
|
+
this.u1q_1 = 78.84375;
|
|
1577
|
+
this.v1q_1 = 0.8359375;
|
|
1578
|
+
this.w1q_1 = 18.8515625;
|
|
1579
|
+
this.x1q_1 = 18.6875;
|
|
1580
|
+
this.y1q_1 = 10000.0;
|
|
1581
|
+
this.z1q_1 = 6.277394636015326;
|
|
1582
|
+
this.a1r_1 = 0.012683313515655966;
|
|
1583
|
+
}
|
|
1584
|
+
protoOf(PqNonlinearity).b1r = function (x) {
|
|
1600
1585
|
var vp = spow(x, 0.012683313515655966);
|
|
1601
1586
|
var n = coerceAtLeast(vp - 0.8359375, 0.0);
|
|
1602
|
-
var
|
|
1603
|
-
var l = spow_0(tmp, 6.277394636015326);
|
|
1587
|
+
var l = spow_0(n / (18.8515625 - 18.6875 * vp), 6.277394636015326);
|
|
1604
1588
|
return 10000.0 * l;
|
|
1605
1589
|
};
|
|
1606
|
-
protoOf(PqNonlinearity).
|
|
1607
|
-
var
|
|
1608
|
-
|
|
1609
|
-
var tmp_0 = 0.8359375 + 18.8515625 * yp;
|
|
1610
|
-
var tmp_1 = tmp_0 / (1.0 + 18.6875 * yp);
|
|
1611
|
-
return spow_0(tmp_1, 78.84375);
|
|
1590
|
+
protoOf(PqNonlinearity).c1r = function (x) {
|
|
1591
|
+
var yp = spow_0(x / 10000.0, 0.1593017578125);
|
|
1592
|
+
return spow_0((0.8359375 + 18.8515625 * yp) / (1.0 + 18.6875 * yp), 78.84375);
|
|
1612
1593
|
};
|
|
1613
1594
|
var PqNonlinearity_instance;
|
|
1614
1595
|
function PqNonlinearity_getInstance() {
|
|
@@ -1630,34 +1611,34 @@
|
|
|
1630
1611
|
}
|
|
1631
1612
|
function Companion_2() {
|
|
1632
1613
|
Companion_instance_3 = this;
|
|
1633
|
-
this.
|
|
1614
|
+
this.g1o_1 = LABColorSpaces_getInstance().h1o_1;
|
|
1634
1615
|
}
|
|
1635
|
-
protoOf(Companion_2).
|
|
1636
|
-
return this.
|
|
1616
|
+
protoOf(Companion_2).e1o = function (l, a, b, alpha) {
|
|
1617
|
+
return this.g1o_1.e1o(l, a, b, alpha);
|
|
1637
1618
|
};
|
|
1638
|
-
protoOf(Companion_2).
|
|
1639
|
-
return this.
|
|
1619
|
+
protoOf(Companion_2).d1r = function (l, a, b, alpha) {
|
|
1620
|
+
return this.g1o_1.d1r(l, a, b, alpha);
|
|
1640
1621
|
};
|
|
1641
|
-
protoOf(Companion_2).
|
|
1642
|
-
return this.
|
|
1622
|
+
protoOf(Companion_2).d1n = function (color) {
|
|
1623
|
+
return this.g1o_1.d1n(color);
|
|
1643
1624
|
};
|
|
1644
|
-
protoOf(Companion_2).
|
|
1645
|
-
return this.
|
|
1625
|
+
protoOf(Companion_2).k1n = function (components) {
|
|
1626
|
+
return this.g1o_1.k1n(components);
|
|
1646
1627
|
};
|
|
1647
|
-
protoOf(Companion_2).
|
|
1648
|
-
return this.
|
|
1628
|
+
protoOf(Companion_2).i1n = function () {
|
|
1629
|
+
return this.g1o_1.i1n();
|
|
1649
1630
|
};
|
|
1650
|
-
protoOf(Companion_2).
|
|
1651
|
-
return this.
|
|
1631
|
+
protoOf(Companion_2).q2 = function () {
|
|
1632
|
+
return this.g1o_1.q2();
|
|
1652
1633
|
};
|
|
1653
|
-
protoOf(Companion_2).
|
|
1654
|
-
return this.
|
|
1634
|
+
protoOf(Companion_2).j1n = function () {
|
|
1635
|
+
return this.g1o_1.j1n();
|
|
1655
1636
|
};
|
|
1656
1637
|
protoOf(Companion_2).equals = function (other) {
|
|
1657
|
-
return equals(LABColorSpaces_getInstance().
|
|
1638
|
+
return equals(LABColorSpaces_getInstance().h1o_1, other);
|
|
1658
1639
|
};
|
|
1659
1640
|
protoOf(Companion_2).hashCode = function () {
|
|
1660
|
-
return hashCode(LABColorSpaces_getInstance().
|
|
1641
|
+
return hashCode(LABColorSpaces_getInstance().h1o_1);
|
|
1661
1642
|
};
|
|
1662
1643
|
var Companion_instance_3;
|
|
1663
1644
|
function Companion_getInstance_2() {
|
|
@@ -1667,34 +1648,34 @@
|
|
|
1667
1648
|
}
|
|
1668
1649
|
function LAB(l, a, b, alpha, space) {
|
|
1669
1650
|
Companion_getInstance_2();
|
|
1670
|
-
this.
|
|
1671
|
-
this.
|
|
1672
|
-
this.
|
|
1673
|
-
this.
|
|
1674
|
-
this.
|
|
1675
|
-
}
|
|
1676
|
-
protoOf(LAB).
|
|
1677
|
-
return this.
|
|
1678
|
-
};
|
|
1679
|
-
protoOf(LAB).
|
|
1680
|
-
return this.
|
|
1681
|
-
};
|
|
1682
|
-
protoOf(LAB).
|
|
1683
|
-
return this.
|
|
1684
|
-
};
|
|
1685
|
-
protoOf(LAB).
|
|
1686
|
-
var xyzSpace = XYZColorSpace_0(this.
|
|
1687
|
-
if (this.
|
|
1688
|
-
return xyzSpace.
|
|
1689
|
-
var fy = (this.
|
|
1690
|
-
var fz = fy - this.
|
|
1691
|
-
var fx = this.
|
|
1651
|
+
this.r1m_1 = l;
|
|
1652
|
+
this.s1m_1 = a;
|
|
1653
|
+
this.t1m_1 = b;
|
|
1654
|
+
this.u1m_1 = alpha;
|
|
1655
|
+
this.v1m_1 = space;
|
|
1656
|
+
}
|
|
1657
|
+
protoOf(LAB).a1m = function () {
|
|
1658
|
+
return this.u1m_1;
|
|
1659
|
+
};
|
|
1660
|
+
protoOf(LAB).b1m = function () {
|
|
1661
|
+
return this.v1m_1;
|
|
1662
|
+
};
|
|
1663
|
+
protoOf(LAB).c1m = function () {
|
|
1664
|
+
return this.r1m_1 === 0.0 ? Companion_getInstance_6().e1o(0.0, 0.0, 0.0, this.u1m_1) : this.j1m().c1m();
|
|
1665
|
+
};
|
|
1666
|
+
protoOf(LAB).j1m = function () {
|
|
1667
|
+
var xyzSpace = XYZColorSpace_0(this.v1m_1.i1n());
|
|
1668
|
+
if (this.r1m_1 === 0.0)
|
|
1669
|
+
return xyzSpace.e1r(0.0, 0.0, 0.0);
|
|
1670
|
+
var fy = (this.r1m_1 + 16) / 116.0;
|
|
1671
|
+
var fz = fy - this.t1m_1 / 200.0;
|
|
1672
|
+
var fx = this.s1m_1 / 500.0 + fy;
|
|
1692
1673
|
var tmp;
|
|
1693
|
-
if (this.
|
|
1674
|
+
if (this.r1m_1 > 8.0) {
|
|
1694
1675
|
// Inline function 'kotlin.math.pow' call
|
|
1695
1676
|
tmp = Math.pow(fy, 3);
|
|
1696
1677
|
} else {
|
|
1697
|
-
tmp = this.
|
|
1678
|
+
tmp = this.r1m_1 / 903.2962962962963;
|
|
1698
1679
|
}
|
|
1699
1680
|
var yr = tmp;
|
|
1700
1681
|
// Inline function 'kotlin.let' call
|
|
@@ -1702,20 +1683,20 @@
|
|
|
1702
1683
|
// Inline function 'kotlin.contracts.contract' call
|
|
1703
1684
|
// Inline function 'com.github.ajalt.colormath.model.LAB.toXYZ.<anonymous>' call
|
|
1704
1685
|
var it = Math.pow(fz, 3);
|
|
1705
|
-
var zr = it >
|
|
1686
|
+
var zr = it > 0.008856451679035631 ? it : (116 * fz - 16) / 903.2962962962963;
|
|
1706
1687
|
// Inline function 'kotlin.let' call
|
|
1707
1688
|
// Inline function 'kotlin.math.pow' call
|
|
1708
1689
|
// Inline function 'kotlin.contracts.contract' call
|
|
1709
1690
|
// Inline function 'com.github.ajalt.colormath.model.LAB.toXYZ.<anonymous>' call
|
|
1710
1691
|
var it_0 = Math.pow(fx, 3);
|
|
1711
|
-
var xr = it_0 >
|
|
1712
|
-
var wp = this.
|
|
1713
|
-
return xyzSpace.
|
|
1692
|
+
var xr = it_0 > 0.008856451679035631 ? it_0 : (116 * fx - 16) / 903.2962962962963;
|
|
1693
|
+
var wp = this.v1m_1.i1n().g1q_1;
|
|
1694
|
+
return xyzSpace.d1r(xr * wp.i1r(), yr * wp.h1r_1, zr * wp.j1r(), this.u1m_1);
|
|
1714
1695
|
};
|
|
1715
|
-
protoOf(LAB).
|
|
1696
|
+
protoOf(LAB).q1m = function () {
|
|
1716
1697
|
// Inline function 'com.github.ajalt.colormath.internal.toPolarModel' call
|
|
1717
|
-
var a = this.
|
|
1718
|
-
var b = this.
|
|
1698
|
+
var a = this.s1m_1;
|
|
1699
|
+
var b = this.t1m_1;
|
|
1719
1700
|
// Inline function 'kotlin.math.sqrt' call
|
|
1720
1701
|
var x = a * a + b * b;
|
|
1721
1702
|
var c = Math.sqrt(x);
|
|
@@ -1730,24 +1711,24 @@
|
|
|
1730
1711
|
var h = tmp;
|
|
1731
1712
|
// Inline function 'com.github.ajalt.colormath.model.LAB.toLCHab.<anonymous>' call
|
|
1732
1713
|
var h_0 = normalizeDeg_0(h);
|
|
1733
|
-
return LCHabColorSpace_0(this.
|
|
1714
|
+
return LCHabColorSpace_0(this.v1m_1.i1n()).e1o(this.r1m_1, c, h_0, this.u1m_1);
|
|
1734
1715
|
};
|
|
1735
|
-
protoOf(LAB).
|
|
1716
|
+
protoOf(LAB).k1m = function () {
|
|
1736
1717
|
return this;
|
|
1737
1718
|
};
|
|
1738
|
-
protoOf(LAB).
|
|
1719
|
+
protoOf(LAB).u5 = function () {
|
|
1739
1720
|
// Inline function 'kotlin.floatArrayOf' call
|
|
1740
|
-
return new Float32Array([this.
|
|
1721
|
+
return new Float32Array([this.r1m_1, this.s1m_1, this.t1m_1, this.u1m_1]);
|
|
1741
1722
|
};
|
|
1742
1723
|
protoOf(LAB).toString = function () {
|
|
1743
|
-
return 'LAB(l=' + this.
|
|
1724
|
+
return 'LAB(l=' + this.r1m_1 + ', a=' + this.s1m_1 + ', b=' + this.t1m_1 + ', alpha=' + this.u1m_1 + ', space=' + toString(this.v1m_1) + ')';
|
|
1744
1725
|
};
|
|
1745
1726
|
protoOf(LAB).hashCode = function () {
|
|
1746
|
-
var result = getNumberHashCode(this.
|
|
1747
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1748
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1749
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1750
|
-
result = imul(result, 31) + hashCode(this.
|
|
1727
|
+
var result = getNumberHashCode(this.r1m_1);
|
|
1728
|
+
result = imul(result, 31) + getNumberHashCode(this.s1m_1) | 0;
|
|
1729
|
+
result = imul(result, 31) + getNumberHashCode(this.t1m_1) | 0;
|
|
1730
|
+
result = imul(result, 31) + getNumberHashCode(this.u1m_1) | 0;
|
|
1731
|
+
result = imul(result, 31) + hashCode(this.v1m_1) | 0;
|
|
1751
1732
|
return result;
|
|
1752
1733
|
};
|
|
1753
1734
|
protoOf(LAB).equals = function (other) {
|
|
@@ -1756,27 +1737,27 @@
|
|
|
1756
1737
|
if (!(other instanceof LAB))
|
|
1757
1738
|
return false;
|
|
1758
1739
|
var tmp0_other_with_cast = other instanceof LAB ? other : THROW_CCE();
|
|
1759
|
-
if (!equals(this.
|
|
1740
|
+
if (!equals(this.r1m_1, tmp0_other_with_cast.r1m_1))
|
|
1760
1741
|
return false;
|
|
1761
|
-
if (!equals(this.
|
|
1742
|
+
if (!equals(this.s1m_1, tmp0_other_with_cast.s1m_1))
|
|
1762
1743
|
return false;
|
|
1763
|
-
if (!equals(this.
|
|
1744
|
+
if (!equals(this.t1m_1, tmp0_other_with_cast.t1m_1))
|
|
1764
1745
|
return false;
|
|
1765
|
-
if (!equals(this.
|
|
1746
|
+
if (!equals(this.u1m_1, tmp0_other_with_cast.u1m_1))
|
|
1766
1747
|
return false;
|
|
1767
|
-
if (!equals(this.
|
|
1748
|
+
if (!equals(this.v1m_1, tmp0_other_with_cast.v1m_1))
|
|
1768
1749
|
return false;
|
|
1769
1750
|
return true;
|
|
1770
1751
|
};
|
|
1771
1752
|
function LABColorSpace() {
|
|
1772
1753
|
}
|
|
1773
1754
|
function LABColorSpace_0(whitePoint) {
|
|
1774
|
-
return whitePoint.equals(Illuminant_getInstance().
|
|
1755
|
+
return whitePoint.equals(Illuminant_getInstance().j1p_1) ? LABColorSpaces_getInstance().h1o_1 : whitePoint.equals(Illuminant_getInstance().h1p_1) ? LABColorSpaces_getInstance().i1o_1 : new LABColorSpaceImpl(whitePoint);
|
|
1775
1756
|
}
|
|
1776
1757
|
function LABColorSpaces() {
|
|
1777
1758
|
LABColorSpaces_instance = this;
|
|
1778
|
-
this.
|
|
1779
|
-
this.
|
|
1759
|
+
this.h1o_1 = new LABColorSpaceImpl(Illuminant_getInstance().j1p_1);
|
|
1760
|
+
this.i1o_1 = new LABColorSpaceImpl(Illuminant_getInstance().h1p_1);
|
|
1780
1761
|
}
|
|
1781
1762
|
var LABColorSpaces_instance;
|
|
1782
1763
|
function LABColorSpaces_getInstance() {
|
|
@@ -1785,37 +1766,37 @@
|
|
|
1785
1766
|
return LABColorSpaces_instance;
|
|
1786
1767
|
}
|
|
1787
1768
|
function LABColorSpaceImpl(whitePoint) {
|
|
1788
|
-
this.
|
|
1789
|
-
this.
|
|
1769
|
+
this.k1r_1 = whitePoint;
|
|
1770
|
+
this.l1r_1 = threeComponentInfo('L', 0.0, 100.0, 'A', -128.0, 128.0, 'B', -128.0, 128.0);
|
|
1790
1771
|
}
|
|
1791
|
-
protoOf(LABColorSpaceImpl).
|
|
1792
|
-
return this.
|
|
1772
|
+
protoOf(LABColorSpaceImpl).i1n = function () {
|
|
1773
|
+
return this.k1r_1;
|
|
1793
1774
|
};
|
|
1794
1775
|
protoOf(LABColorSpaceImpl).q2 = function () {
|
|
1795
1776
|
return 'LAB';
|
|
1796
1777
|
};
|
|
1797
|
-
protoOf(LABColorSpaceImpl).
|
|
1798
|
-
return this.
|
|
1778
|
+
protoOf(LABColorSpaceImpl).j1n = function () {
|
|
1779
|
+
return this.l1r_1;
|
|
1799
1780
|
};
|
|
1800
|
-
protoOf(LABColorSpaceImpl).
|
|
1781
|
+
protoOf(LABColorSpaceImpl).d1n = function (color) {
|
|
1801
1782
|
// Inline function 'com.github.ajalt.colormath.internal.adaptToThis' call
|
|
1802
1783
|
var tmp;
|
|
1803
|
-
var tmp_0 = color.
|
|
1804
|
-
var
|
|
1805
|
-
var
|
|
1806
|
-
if ((
|
|
1784
|
+
var tmp_0 = color.b1m();
|
|
1785
|
+
var tmp17_safe_receiver = isInterface(tmp_0, WhitePointColorSpace) ? tmp_0 : null;
|
|
1786
|
+
var tmp0_elvis_lhs = tmp17_safe_receiver == null ? null : tmp17_safe_receiver.i1n();
|
|
1787
|
+
if ((tmp0_elvis_lhs == null ? Illuminant_getInstance().j1p_1 : tmp0_elvis_lhs).equals(this.i1n())) {
|
|
1807
1788
|
// Inline function 'com.github.ajalt.colormath.model.LABColorSpaceImpl.convert.<anonymous>' call
|
|
1808
|
-
tmp = color.
|
|
1789
|
+
tmp = color.k1m();
|
|
1809
1790
|
} else {
|
|
1810
1791
|
// Inline function 'com.github.ajalt.colormath.model.LABColorSpaceImpl.convert.<anonymous>' call
|
|
1811
|
-
tmp = color.
|
|
1792
|
+
tmp = color.j1m().d1p(XYZColorSpace_0(this.i1n())).k1m();
|
|
1812
1793
|
}
|
|
1813
1794
|
return tmp;
|
|
1814
1795
|
};
|
|
1815
|
-
protoOf(LABColorSpaceImpl).
|
|
1796
|
+
protoOf(LABColorSpaceImpl).k1n = function (components) {
|
|
1816
1797
|
// Inline function 'com.github.ajalt.colormath.internal.doCreate' call
|
|
1817
1798
|
// Inline function 'com.github.ajalt.colormath.internal.withValidComps' call
|
|
1818
|
-
var size = this.
|
|
1799
|
+
var size = this.j1n().m();
|
|
1819
1800
|
// Inline function 'kotlin.require' call
|
|
1820
1801
|
var containsLower = size - 1 | 0;
|
|
1821
1802
|
var containsArg = components.length;
|
|
@@ -1839,21 +1820,21 @@
|
|
|
1839
1820
|
tmp = 1.0;
|
|
1840
1821
|
}
|
|
1841
1822
|
var p3 = tmp;
|
|
1842
|
-
return this.
|
|
1823
|
+
return this.e1o(p0, p1, p2, p3);
|
|
1843
1824
|
};
|
|
1844
1825
|
protoOf(LABColorSpaceImpl).toString = function () {
|
|
1845
|
-
return 'LABColorSpace(' + this.
|
|
1826
|
+
return 'LABColorSpace(' + this.k1r_1.toString() + ')';
|
|
1846
1827
|
};
|
|
1847
|
-
protoOf(LABColorSpaceImpl).
|
|
1828
|
+
protoOf(LABColorSpaceImpl).e1o = function (l, a, b, alpha) {
|
|
1848
1829
|
return new LAB(l, a, b, alpha, this);
|
|
1849
1830
|
};
|
|
1850
1831
|
protoOf(LABColorSpaceImpl).hashCode = function () {
|
|
1851
|
-
return this.
|
|
1832
|
+
return this.k1r_1.hashCode();
|
|
1852
1833
|
};
|
|
1853
1834
|
protoOf(LABColorSpaceImpl).equals = function (other) {
|
|
1854
1835
|
var tmp;
|
|
1855
1836
|
if (!(other == null) ? isInterface(other, LABColorSpace) : false) {
|
|
1856
|
-
tmp = this.
|
|
1837
|
+
tmp = this.k1r_1.equals(other.i1n());
|
|
1857
1838
|
} else {
|
|
1858
1839
|
tmp = false;
|
|
1859
1840
|
}
|
|
@@ -1861,31 +1842,31 @@
|
|
|
1861
1842
|
};
|
|
1862
1843
|
function Companion_3() {
|
|
1863
1844
|
Companion_instance_4 = this;
|
|
1864
|
-
this.
|
|
1845
|
+
this.j1o_1 = LCHabColorSpaces_getInstance().k1o_1;
|
|
1865
1846
|
}
|
|
1866
|
-
protoOf(Companion_3).
|
|
1867
|
-
return this.
|
|
1847
|
+
protoOf(Companion_3).e1o = function (l, c, h, alpha) {
|
|
1848
|
+
return this.j1o_1.e1o(l, c, h, alpha);
|
|
1868
1849
|
};
|
|
1869
|
-
protoOf(Companion_3).
|
|
1870
|
-
return this.
|
|
1850
|
+
protoOf(Companion_3).d1n = function (color) {
|
|
1851
|
+
return this.j1o_1.d1n(color);
|
|
1871
1852
|
};
|
|
1872
|
-
protoOf(Companion_3).
|
|
1873
|
-
return this.
|
|
1853
|
+
protoOf(Companion_3).k1n = function (components) {
|
|
1854
|
+
return this.j1o_1.k1n(components);
|
|
1874
1855
|
};
|
|
1875
|
-
protoOf(Companion_3).
|
|
1876
|
-
return this.
|
|
1856
|
+
protoOf(Companion_3).i1n = function () {
|
|
1857
|
+
return this.j1o_1.i1n();
|
|
1877
1858
|
};
|
|
1878
|
-
protoOf(Companion_3).
|
|
1879
|
-
return this.
|
|
1859
|
+
protoOf(Companion_3).q2 = function () {
|
|
1860
|
+
return this.j1o_1.q2();
|
|
1880
1861
|
};
|
|
1881
|
-
protoOf(Companion_3).
|
|
1882
|
-
return this.
|
|
1862
|
+
protoOf(Companion_3).j1n = function () {
|
|
1863
|
+
return this.j1o_1.j1n();
|
|
1883
1864
|
};
|
|
1884
1865
|
protoOf(Companion_3).equals = function (other) {
|
|
1885
|
-
return equals(LCHabColorSpaces_getInstance().
|
|
1866
|
+
return equals(LCHabColorSpaces_getInstance().k1o_1, other);
|
|
1886
1867
|
};
|
|
1887
1868
|
protoOf(Companion_3).hashCode = function () {
|
|
1888
|
-
return hashCode(LCHabColorSpaces_getInstance().
|
|
1869
|
+
return hashCode(LCHabColorSpaces_getInstance().k1o_1);
|
|
1889
1870
|
};
|
|
1890
1871
|
var Companion_instance_4;
|
|
1891
1872
|
function Companion_getInstance_3() {
|
|
@@ -1895,55 +1876,55 @@
|
|
|
1895
1876
|
}
|
|
1896
1877
|
function LCHab(l, c, h, alpha, space) {
|
|
1897
1878
|
Companion_getInstance_3();
|
|
1898
|
-
this.
|
|
1899
|
-
this.
|
|
1900
|
-
this.
|
|
1901
|
-
this.
|
|
1902
|
-
this.
|
|
1879
|
+
this.r1p_1 = l;
|
|
1880
|
+
this.s1p_1 = c;
|
|
1881
|
+
this.t1p_1 = h;
|
|
1882
|
+
this.u1p_1 = alpha;
|
|
1883
|
+
this.v1p_1 = space;
|
|
1903
1884
|
}
|
|
1904
|
-
protoOf(LCHab).
|
|
1905
|
-
return this.
|
|
1885
|
+
protoOf(LCHab).e1q = function () {
|
|
1886
|
+
return this.t1p_1;
|
|
1906
1887
|
};
|
|
1907
|
-
protoOf(LCHab).
|
|
1908
|
-
return this.
|
|
1888
|
+
protoOf(LCHab).a1m = function () {
|
|
1889
|
+
return this.u1p_1;
|
|
1909
1890
|
};
|
|
1910
|
-
protoOf(LCHab).
|
|
1911
|
-
return this.
|
|
1891
|
+
protoOf(LCHab).b1m = function () {
|
|
1892
|
+
return this.v1p_1;
|
|
1912
1893
|
};
|
|
1913
|
-
protoOf(LCHab).
|
|
1914
|
-
return this.
|
|
1894
|
+
protoOf(LCHab).c1m = function () {
|
|
1895
|
+
return this.k1m().c1m();
|
|
1915
1896
|
};
|
|
1916
|
-
protoOf(LCHab).
|
|
1917
|
-
return this.
|
|
1897
|
+
protoOf(LCHab).j1m = function () {
|
|
1898
|
+
return this.k1m().j1m();
|
|
1918
1899
|
};
|
|
1919
|
-
protoOf(LCHab).
|
|
1900
|
+
protoOf(LCHab).k1m = function () {
|
|
1920
1901
|
// Inline function 'com.github.ajalt.colormath.internal.fromPolarModel' call
|
|
1921
|
-
var c = this.
|
|
1922
|
-
var h = this.
|
|
1902
|
+
var c = this.s1p_1;
|
|
1903
|
+
var h = this.t1p_1;
|
|
1923
1904
|
var hDegrees = isNaN_0(h) ? 0.0 : degToRad(h);
|
|
1924
1905
|
// Inline function 'kotlin.math.cos' call
|
|
1925
1906
|
var a = c * Math.cos(hDegrees);
|
|
1926
1907
|
// Inline function 'kotlin.math.sin' call
|
|
1927
1908
|
var b = c * Math.sin(hDegrees);
|
|
1928
1909
|
// Inline function 'com.github.ajalt.colormath.model.LCHab.toLAB.<anonymous>' call
|
|
1929
|
-
return LABColorSpace_0(this.
|
|
1910
|
+
return LABColorSpace_0(this.v1p_1.i1n()).e1o(this.r1p_1, a, b, this.u1p_1);
|
|
1930
1911
|
};
|
|
1931
|
-
protoOf(LCHab).
|
|
1912
|
+
protoOf(LCHab).q1m = function () {
|
|
1932
1913
|
return this;
|
|
1933
1914
|
};
|
|
1934
|
-
protoOf(LCHab).
|
|
1915
|
+
protoOf(LCHab).u5 = function () {
|
|
1935
1916
|
// Inline function 'kotlin.floatArrayOf' call
|
|
1936
|
-
return new Float32Array([this.
|
|
1917
|
+
return new Float32Array([this.r1p_1, this.s1p_1, this.t1p_1, this.u1p_1]);
|
|
1937
1918
|
};
|
|
1938
1919
|
protoOf(LCHab).toString = function () {
|
|
1939
|
-
return 'LCHab(l=' + this.
|
|
1920
|
+
return 'LCHab(l=' + this.r1p_1 + ', c=' + this.s1p_1 + ', h=' + this.t1p_1 + ', alpha=' + this.u1p_1 + ', space=' + toString(this.v1p_1) + ')';
|
|
1940
1921
|
};
|
|
1941
1922
|
protoOf(LCHab).hashCode = function () {
|
|
1942
|
-
var result = getNumberHashCode(this.
|
|
1943
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1944
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1945
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
1946
|
-
result = imul(result, 31) + hashCode(this.
|
|
1923
|
+
var result = getNumberHashCode(this.r1p_1);
|
|
1924
|
+
result = imul(result, 31) + getNumberHashCode(this.s1p_1) | 0;
|
|
1925
|
+
result = imul(result, 31) + getNumberHashCode(this.t1p_1) | 0;
|
|
1926
|
+
result = imul(result, 31) + getNumberHashCode(this.u1p_1) | 0;
|
|
1927
|
+
result = imul(result, 31) + hashCode(this.v1p_1) | 0;
|
|
1947
1928
|
return result;
|
|
1948
1929
|
};
|
|
1949
1930
|
protoOf(LCHab).equals = function (other) {
|
|
@@ -1952,27 +1933,27 @@
|
|
|
1952
1933
|
if (!(other instanceof LCHab))
|
|
1953
1934
|
return false;
|
|
1954
1935
|
var tmp0_other_with_cast = other instanceof LCHab ? other : THROW_CCE();
|
|
1955
|
-
if (!equals(this.
|
|
1936
|
+
if (!equals(this.r1p_1, tmp0_other_with_cast.r1p_1))
|
|
1956
1937
|
return false;
|
|
1957
|
-
if (!equals(this.
|
|
1938
|
+
if (!equals(this.s1p_1, tmp0_other_with_cast.s1p_1))
|
|
1958
1939
|
return false;
|
|
1959
|
-
if (!equals(this.
|
|
1940
|
+
if (!equals(this.t1p_1, tmp0_other_with_cast.t1p_1))
|
|
1960
1941
|
return false;
|
|
1961
|
-
if (!equals(this.
|
|
1942
|
+
if (!equals(this.u1p_1, tmp0_other_with_cast.u1p_1))
|
|
1962
1943
|
return false;
|
|
1963
|
-
if (!equals(this.
|
|
1944
|
+
if (!equals(this.v1p_1, tmp0_other_with_cast.v1p_1))
|
|
1964
1945
|
return false;
|
|
1965
1946
|
return true;
|
|
1966
1947
|
};
|
|
1967
1948
|
function LCHabColorSpace() {
|
|
1968
1949
|
}
|
|
1969
1950
|
function LCHabColorSpace_0(whitePoint) {
|
|
1970
|
-
return whitePoint.equals(Illuminant_getInstance().
|
|
1951
|
+
return whitePoint.equals(Illuminant_getInstance().j1p_1) ? LCHabColorSpaces_getInstance().k1o_1 : whitePoint.equals(Illuminant_getInstance().h1p_1) ? LCHabColorSpaces_getInstance().l1o_1 : new LCHabColorSpaceImpl(whitePoint);
|
|
1971
1952
|
}
|
|
1972
1953
|
function LCHabColorSpaces() {
|
|
1973
1954
|
LCHabColorSpaces_instance = this;
|
|
1974
|
-
this.
|
|
1975
|
-
this.
|
|
1955
|
+
this.k1o_1 = new LCHabColorSpaceImpl(Illuminant_getInstance().j1p_1);
|
|
1956
|
+
this.l1o_1 = new LCHabColorSpaceImpl(Illuminant_getInstance().h1p_1);
|
|
1976
1957
|
}
|
|
1977
1958
|
var LCHabColorSpaces_instance;
|
|
1978
1959
|
function LCHabColorSpaces_getInstance() {
|
|
@@ -1981,37 +1962,37 @@
|
|
|
1981
1962
|
return LCHabColorSpaces_instance;
|
|
1982
1963
|
}
|
|
1983
1964
|
function LCHabColorSpaceImpl(whitePoint) {
|
|
1984
|
-
this.
|
|
1985
|
-
this.
|
|
1965
|
+
this.m1r_1 = whitePoint;
|
|
1966
|
+
this.n1r_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)]);
|
|
1986
1967
|
}
|
|
1987
|
-
protoOf(LCHabColorSpaceImpl).
|
|
1988
|
-
return this.
|
|
1968
|
+
protoOf(LCHabColorSpaceImpl).i1n = function () {
|
|
1969
|
+
return this.m1r_1;
|
|
1989
1970
|
};
|
|
1990
1971
|
protoOf(LCHabColorSpaceImpl).q2 = function () {
|
|
1991
1972
|
return 'LCHab';
|
|
1992
1973
|
};
|
|
1993
|
-
protoOf(LCHabColorSpaceImpl).
|
|
1994
|
-
return this.
|
|
1974
|
+
protoOf(LCHabColorSpaceImpl).j1n = function () {
|
|
1975
|
+
return this.n1r_1;
|
|
1995
1976
|
};
|
|
1996
|
-
protoOf(LCHabColorSpaceImpl).
|
|
1977
|
+
protoOf(LCHabColorSpaceImpl).d1n = function (color) {
|
|
1997
1978
|
// Inline function 'com.github.ajalt.colormath.internal.adaptToThis' call
|
|
1998
1979
|
var tmp;
|
|
1999
|
-
var tmp_0 = color.
|
|
2000
|
-
var
|
|
2001
|
-
var
|
|
2002
|
-
if ((
|
|
1980
|
+
var tmp_0 = color.b1m();
|
|
1981
|
+
var tmp17_safe_receiver = isInterface(tmp_0, WhitePointColorSpace) ? tmp_0 : null;
|
|
1982
|
+
var tmp0_elvis_lhs = tmp17_safe_receiver == null ? null : tmp17_safe_receiver.i1n();
|
|
1983
|
+
if ((tmp0_elvis_lhs == null ? Illuminant_getInstance().j1p_1 : tmp0_elvis_lhs).equals(this.i1n())) {
|
|
2003
1984
|
// Inline function 'com.github.ajalt.colormath.model.LCHabColorSpaceImpl.convert.<anonymous>' call
|
|
2004
|
-
tmp = color.
|
|
1985
|
+
tmp = color.q1m();
|
|
2005
1986
|
} else {
|
|
2006
1987
|
// Inline function 'com.github.ajalt.colormath.model.LCHabColorSpaceImpl.convert.<anonymous>' call
|
|
2007
|
-
tmp = color.
|
|
1988
|
+
tmp = color.j1m().d1p(XYZColorSpace_0(this.i1n())).q1m();
|
|
2008
1989
|
}
|
|
2009
1990
|
return tmp;
|
|
2010
1991
|
};
|
|
2011
|
-
protoOf(LCHabColorSpaceImpl).
|
|
1992
|
+
protoOf(LCHabColorSpaceImpl).k1n = function (components) {
|
|
2012
1993
|
// Inline function 'com.github.ajalt.colormath.internal.doCreate' call
|
|
2013
1994
|
// Inline function 'com.github.ajalt.colormath.internal.withValidComps' call
|
|
2014
|
-
var size = this.
|
|
1995
|
+
var size = this.j1n().m();
|
|
2015
1996
|
// Inline function 'kotlin.require' call
|
|
2016
1997
|
var containsLower = size - 1 | 0;
|
|
2017
1998
|
var containsArg = components.length;
|
|
@@ -2035,21 +2016,21 @@
|
|
|
2035
2016
|
tmp = 1.0;
|
|
2036
2017
|
}
|
|
2037
2018
|
var p3 = tmp;
|
|
2038
|
-
return this.
|
|
2019
|
+
return this.e1o(p0, p1, p2, p3);
|
|
2039
2020
|
};
|
|
2040
2021
|
protoOf(LCHabColorSpaceImpl).toString = function () {
|
|
2041
|
-
return 'LCHabColorSpace(' + this.
|
|
2022
|
+
return 'LCHabColorSpace(' + this.m1r_1.toString() + ')';
|
|
2042
2023
|
};
|
|
2043
|
-
protoOf(LCHabColorSpaceImpl).
|
|
2024
|
+
protoOf(LCHabColorSpaceImpl).e1o = function (l, c, h, alpha) {
|
|
2044
2025
|
return new LCHab(l, c, h, alpha, this);
|
|
2045
2026
|
};
|
|
2046
2027
|
protoOf(LCHabColorSpaceImpl).hashCode = function () {
|
|
2047
|
-
return this.
|
|
2028
|
+
return this.m1r_1.hashCode();
|
|
2048
2029
|
};
|
|
2049
2030
|
protoOf(LCHabColorSpaceImpl).equals = function (other) {
|
|
2050
2031
|
var tmp;
|
|
2051
2032
|
if (!(other == null) ? isInterface(other, LCHabColorSpace) : false) {
|
|
2052
|
-
tmp = this.
|
|
2033
|
+
tmp = this.m1r_1.equals(other.i1n());
|
|
2053
2034
|
} else {
|
|
2054
2035
|
tmp = false;
|
|
2055
2036
|
}
|
|
@@ -2057,21 +2038,21 @@
|
|
|
2057
2038
|
};
|
|
2058
2039
|
function Companion_4() {
|
|
2059
2040
|
Companion_instance_5 = this;
|
|
2060
|
-
this.
|
|
2041
|
+
this.n1o_1 = threeComponentInfo('l', 0.0, 1.0, 'a', -0.4, 0.4, 'b', -0.4, 0.4);
|
|
2061
2042
|
}
|
|
2062
2043
|
protoOf(Companion_4).q2 = function () {
|
|
2063
2044
|
return 'Oklab';
|
|
2064
2045
|
};
|
|
2065
|
-
protoOf(Companion_4).
|
|
2066
|
-
return this.
|
|
2046
|
+
protoOf(Companion_4).j1n = function () {
|
|
2047
|
+
return this.n1o_1;
|
|
2067
2048
|
};
|
|
2068
|
-
protoOf(Companion_4).
|
|
2069
|
-
return color.
|
|
2049
|
+
protoOf(Companion_4).d1n = function (color) {
|
|
2050
|
+
return color.x1m();
|
|
2070
2051
|
};
|
|
2071
|
-
protoOf(Companion_4).
|
|
2052
|
+
protoOf(Companion_4).k1n = function (components) {
|
|
2072
2053
|
// Inline function 'com.github.ajalt.colormath.internal.doCreate' call
|
|
2073
2054
|
// Inline function 'com.github.ajalt.colormath.internal.withValidComps' call
|
|
2074
|
-
var size = this.
|
|
2055
|
+
var size = this.j1n().m();
|
|
2075
2056
|
// Inline function 'kotlin.require' call
|
|
2076
2057
|
var containsLower = size - 1 | 0;
|
|
2077
2058
|
var containsArg = components.length;
|
|
@@ -2114,45 +2095,45 @@
|
|
|
2114
2095
|
function Oklab(l, a, b, alpha) {
|
|
2115
2096
|
Companion_getInstance_4();
|
|
2116
2097
|
alpha = alpha === VOID ? 1.0 : alpha;
|
|
2117
|
-
this.
|
|
2118
|
-
this.
|
|
2119
|
-
this.
|
|
2120
|
-
this.
|
|
2098
|
+
this.z1m_1 = l;
|
|
2099
|
+
this.a1n_1 = a;
|
|
2100
|
+
this.b1n_1 = b;
|
|
2101
|
+
this.c1n_1 = alpha;
|
|
2121
2102
|
}
|
|
2122
|
-
protoOf(Oklab).
|
|
2123
|
-
return this.
|
|
2103
|
+
protoOf(Oklab).a1m = function () {
|
|
2104
|
+
return this.c1n_1;
|
|
2124
2105
|
};
|
|
2125
|
-
protoOf(Oklab).
|
|
2106
|
+
protoOf(Oklab).b1m = function () {
|
|
2126
2107
|
return Companion_getInstance_4();
|
|
2127
2108
|
};
|
|
2128
|
-
protoOf(Oklab).
|
|
2109
|
+
protoOf(Oklab).c1m = function () {
|
|
2129
2110
|
// Inline function 'com.github.ajalt.colormath.model.Oklab.calculateConeResponse' call
|
|
2130
|
-
var ll = this.
|
|
2131
|
-
var mm = this.
|
|
2132
|
-
var ss = this.
|
|
2111
|
+
var ll = this.z1m_1 + 0.3963377774 * this.a1n_1 + 0.2158037573 * this.b1n_1;
|
|
2112
|
+
var mm = this.z1m_1 - 0.1055613458 * this.a1n_1 - 0.0638541728 * this.b1n_1;
|
|
2113
|
+
var ss = this.z1m_1 - 0.0894841775 * this.a1n_1 - 1.291485548 * this.b1n_1;
|
|
2133
2114
|
var l = ll * ll * ll;
|
|
2134
2115
|
var m = mm * mm * mm;
|
|
2135
2116
|
var s = ss * ss * ss;
|
|
2136
|
-
var r = 4.0767416621 * l - 3.3077115913 * m + 0.2309699292 * s;
|
|
2117
|
+
var r = +4.0767416621 * l - 3.3077115913 * m + 0.2309699292 * s;
|
|
2137
2118
|
var g = -1.2684380046 * l + 2.6097574011 * m - 0.3413193965 * s;
|
|
2138
2119
|
var b = -0.0041960863 * l - 0.7034186147 * m + 1.707614701 * s;
|
|
2139
|
-
var f = Companion_getInstance_6().
|
|
2140
|
-
return Companion_getInstance_6().
|
|
2120
|
+
var f = Companion_getInstance_6().s1q();
|
|
2121
|
+
return Companion_getInstance_6().e1o(f.c1r(r), f.c1r(g), f.c1r(b), this.c1n_1);
|
|
2141
2122
|
};
|
|
2142
|
-
protoOf(Oklab).
|
|
2123
|
+
protoOf(Oklab).j1m = function () {
|
|
2143
2124
|
// Inline function 'com.github.ajalt.colormath.model.Oklab.calculateConeResponse' call
|
|
2144
|
-
var ll = this.
|
|
2145
|
-
var mm = this.
|
|
2146
|
-
var ss = this.
|
|
2125
|
+
var ll = this.z1m_1 + 0.3963377774 * this.a1n_1 + 0.2158037573 * this.b1n_1;
|
|
2126
|
+
var mm = this.z1m_1 - 0.1055613458 * this.a1n_1 - 0.0638541728 * this.b1n_1;
|
|
2127
|
+
var ss = this.z1m_1 - 0.0894841775 * this.a1n_1 - 1.291485548 * this.b1n_1;
|
|
2147
2128
|
var l = ll * ll * ll;
|
|
2148
2129
|
var m = mm * mm * mm;
|
|
2149
2130
|
var s = ss * ss * ss;
|
|
2150
|
-
return Companion_getInstance_8().
|
|
2131
|
+
return Companion_getInstance_8().d1r(+1.2270138511 * l - 0.5577999807 * m + 0.281256149 * s, -0.0405801784 * l + 1.1122568696 * m - 0.0716766787 * s, -0.0763812845 * l - 0.4214819784 * m + 1.5861632204 * s, this.c1n_1);
|
|
2151
2132
|
};
|
|
2152
|
-
protoOf(Oklab).
|
|
2133
|
+
protoOf(Oklab).y1m = function () {
|
|
2153
2134
|
// Inline function 'com.github.ajalt.colormath.internal.toPolarModel' call
|
|
2154
|
-
var a = this.
|
|
2155
|
-
var b = this.
|
|
2135
|
+
var a = this.a1n_1;
|
|
2136
|
+
var b = this.b1n_1;
|
|
2156
2137
|
// Inline function 'kotlin.math.sqrt' call
|
|
2157
2138
|
var x = a * a + b * b;
|
|
2158
2139
|
var c = Math.sqrt(x);
|
|
@@ -2167,23 +2148,23 @@
|
|
|
2167
2148
|
var h = tmp;
|
|
2168
2149
|
// Inline function 'com.github.ajalt.colormath.model.Oklab.toOklch.<anonymous>' call
|
|
2169
2150
|
var h_0 = normalizeDeg_0(h);
|
|
2170
|
-
return new Oklch(this.
|
|
2151
|
+
return new Oklch(this.z1m_1, c, h_0, this.c1n_1);
|
|
2171
2152
|
};
|
|
2172
|
-
protoOf(Oklab).
|
|
2153
|
+
protoOf(Oklab).x1m = function () {
|
|
2173
2154
|
return this;
|
|
2174
2155
|
};
|
|
2175
|
-
protoOf(Oklab).
|
|
2156
|
+
protoOf(Oklab).u5 = function () {
|
|
2176
2157
|
// Inline function 'kotlin.floatArrayOf' call
|
|
2177
|
-
return new Float32Array([this.
|
|
2158
|
+
return new Float32Array([this.z1m_1, this.a1n_1, this.b1n_1, this.c1n_1]);
|
|
2178
2159
|
};
|
|
2179
2160
|
protoOf(Oklab).toString = function () {
|
|
2180
|
-
return 'Oklab(l=' + this.
|
|
2161
|
+
return 'Oklab(l=' + this.z1m_1 + ', a=' + this.a1n_1 + ', b=' + this.b1n_1 + ', alpha=' + this.c1n_1 + ')';
|
|
2181
2162
|
};
|
|
2182
2163
|
protoOf(Oklab).hashCode = function () {
|
|
2183
|
-
var result = getNumberHashCode(this.
|
|
2184
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2185
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2186
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2164
|
+
var result = getNumberHashCode(this.z1m_1);
|
|
2165
|
+
result = imul(result, 31) + getNumberHashCode(this.a1n_1) | 0;
|
|
2166
|
+
result = imul(result, 31) + getNumberHashCode(this.b1n_1) | 0;
|
|
2167
|
+
result = imul(result, 31) + getNumberHashCode(this.c1n_1) | 0;
|
|
2187
2168
|
return result;
|
|
2188
2169
|
};
|
|
2189
2170
|
protoOf(Oklab).equals = function (other) {
|
|
@@ -2192,33 +2173,33 @@
|
|
|
2192
2173
|
if (!(other instanceof Oklab))
|
|
2193
2174
|
return false;
|
|
2194
2175
|
var tmp0_other_with_cast = other instanceof Oklab ? other : THROW_CCE();
|
|
2195
|
-
if (!equals(this.
|
|
2176
|
+
if (!equals(this.z1m_1, tmp0_other_with_cast.z1m_1))
|
|
2196
2177
|
return false;
|
|
2197
|
-
if (!equals(this.
|
|
2178
|
+
if (!equals(this.a1n_1, tmp0_other_with_cast.a1n_1))
|
|
2198
2179
|
return false;
|
|
2199
|
-
if (!equals(this.
|
|
2180
|
+
if (!equals(this.b1n_1, tmp0_other_with_cast.b1n_1))
|
|
2200
2181
|
return false;
|
|
2201
|
-
if (!equals(this.
|
|
2182
|
+
if (!equals(this.c1n_1, tmp0_other_with_cast.c1n_1))
|
|
2202
2183
|
return false;
|
|
2203
2184
|
return true;
|
|
2204
2185
|
};
|
|
2205
2186
|
function Companion_5() {
|
|
2206
2187
|
Companion_instance_6 = this;
|
|
2207
|
-
this.
|
|
2188
|
+
this.o1o_1 = componentInfoList([new ColorComponentInfo('l', false, 0.0, 1.0), new ColorComponentInfo('c', false, 0.0, 0.4), new ColorComponentInfo('h', true, 0.0, 360.0)]);
|
|
2208
2189
|
}
|
|
2209
2190
|
protoOf(Companion_5).q2 = function () {
|
|
2210
2191
|
return 'Oklch';
|
|
2211
2192
|
};
|
|
2212
|
-
protoOf(Companion_5).
|
|
2213
|
-
return this.
|
|
2193
|
+
protoOf(Companion_5).j1n = function () {
|
|
2194
|
+
return this.o1o_1;
|
|
2214
2195
|
};
|
|
2215
|
-
protoOf(Companion_5).
|
|
2216
|
-
return color.
|
|
2196
|
+
protoOf(Companion_5).d1n = function (color) {
|
|
2197
|
+
return color.y1m();
|
|
2217
2198
|
};
|
|
2218
|
-
protoOf(Companion_5).
|
|
2199
|
+
protoOf(Companion_5).k1n = function (components) {
|
|
2219
2200
|
// Inline function 'com.github.ajalt.colormath.internal.doCreate' call
|
|
2220
2201
|
// Inline function 'com.github.ajalt.colormath.internal.withValidComps' call
|
|
2221
|
-
var size = this.
|
|
2202
|
+
var size = this.j1n().m();
|
|
2222
2203
|
// Inline function 'kotlin.require' call
|
|
2223
2204
|
var containsLower = size - 1 | 0;
|
|
2224
2205
|
var containsArg = components.length;
|
|
@@ -2253,53 +2234,53 @@
|
|
|
2253
2234
|
function Oklch(l, c, h, alpha) {
|
|
2254
2235
|
Companion_getInstance_5();
|
|
2255
2236
|
alpha = alpha === VOID ? 1.0 : alpha;
|
|
2256
|
-
this.
|
|
2257
|
-
this.
|
|
2258
|
-
this.
|
|
2259
|
-
this.
|
|
2237
|
+
this.a1q_1 = l;
|
|
2238
|
+
this.b1q_1 = c;
|
|
2239
|
+
this.c1q_1 = h;
|
|
2240
|
+
this.d1q_1 = alpha;
|
|
2260
2241
|
}
|
|
2261
|
-
protoOf(Oklch).
|
|
2262
|
-
return this.
|
|
2242
|
+
protoOf(Oklch).e1q = function () {
|
|
2243
|
+
return this.c1q_1;
|
|
2263
2244
|
};
|
|
2264
|
-
protoOf(Oklch).
|
|
2265
|
-
return this.
|
|
2245
|
+
protoOf(Oklch).a1m = function () {
|
|
2246
|
+
return this.d1q_1;
|
|
2266
2247
|
};
|
|
2267
|
-
protoOf(Oklch).
|
|
2248
|
+
protoOf(Oklch).b1m = function () {
|
|
2268
2249
|
return Companion_getInstance_5();
|
|
2269
2250
|
};
|
|
2270
|
-
protoOf(Oklch).
|
|
2271
|
-
return this.
|
|
2251
|
+
protoOf(Oklch).c1m = function () {
|
|
2252
|
+
return this.x1m().c1m();
|
|
2272
2253
|
};
|
|
2273
|
-
protoOf(Oklch).
|
|
2274
|
-
return this.
|
|
2254
|
+
protoOf(Oklch).j1m = function () {
|
|
2255
|
+
return this.x1m().j1m();
|
|
2275
2256
|
};
|
|
2276
|
-
protoOf(Oklch).
|
|
2257
|
+
protoOf(Oklch).x1m = function () {
|
|
2277
2258
|
// Inline function 'com.github.ajalt.colormath.internal.fromPolarModel' call
|
|
2278
|
-
var c = this.
|
|
2279
|
-
var h = this.
|
|
2259
|
+
var c = this.b1q_1;
|
|
2260
|
+
var h = this.c1q_1;
|
|
2280
2261
|
var hDegrees = isNaN_0(h) ? 0.0 : degToRad(h);
|
|
2281
2262
|
// Inline function 'kotlin.math.cos' call
|
|
2282
2263
|
var a = c * Math.cos(hDegrees);
|
|
2283
2264
|
// Inline function 'kotlin.math.sin' call
|
|
2284
2265
|
var b = c * Math.sin(hDegrees);
|
|
2285
2266
|
// Inline function 'com.github.ajalt.colormath.model.Oklch.toOklab.<anonymous>' call
|
|
2286
|
-
return new Oklab(this.
|
|
2267
|
+
return new Oklab(this.a1q_1, a, b, this.d1q_1);
|
|
2287
2268
|
};
|
|
2288
|
-
protoOf(Oklch).
|
|
2269
|
+
protoOf(Oklch).y1m = function () {
|
|
2289
2270
|
return this;
|
|
2290
2271
|
};
|
|
2291
|
-
protoOf(Oklch).
|
|
2272
|
+
protoOf(Oklch).u5 = function () {
|
|
2292
2273
|
// Inline function 'kotlin.floatArrayOf' call
|
|
2293
|
-
return new Float32Array([this.
|
|
2274
|
+
return new Float32Array([this.a1q_1, this.b1q_1, this.c1q_1, this.d1q_1]);
|
|
2294
2275
|
};
|
|
2295
2276
|
protoOf(Oklch).toString = function () {
|
|
2296
|
-
return 'Oklch(l=' + this.
|
|
2277
|
+
return 'Oklch(l=' + this.a1q_1 + ', c=' + this.b1q_1 + ', h=' + this.c1q_1 + ', alpha=' + this.d1q_1 + ')';
|
|
2297
2278
|
};
|
|
2298
2279
|
protoOf(Oklch).hashCode = function () {
|
|
2299
|
-
var result = getNumberHashCode(this.
|
|
2300
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2301
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2302
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2280
|
+
var result = getNumberHashCode(this.a1q_1);
|
|
2281
|
+
result = imul(result, 31) + getNumberHashCode(this.b1q_1) | 0;
|
|
2282
|
+
result = imul(result, 31) + getNumberHashCode(this.c1q_1) | 0;
|
|
2283
|
+
result = imul(result, 31) + getNumberHashCode(this.d1q_1) | 0;
|
|
2303
2284
|
return result;
|
|
2304
2285
|
};
|
|
2305
2286
|
protoOf(Oklch).equals = function (other) {
|
|
@@ -2308,30 +2289,30 @@
|
|
|
2308
2289
|
if (!(other instanceof Oklch))
|
|
2309
2290
|
return false;
|
|
2310
2291
|
var tmp0_other_with_cast = other instanceof Oklch ? other : THROW_CCE();
|
|
2311
|
-
if (!equals(this.
|
|
2292
|
+
if (!equals(this.a1q_1, tmp0_other_with_cast.a1q_1))
|
|
2312
2293
|
return false;
|
|
2313
|
-
if (!equals(this.
|
|
2294
|
+
if (!equals(this.b1q_1, tmp0_other_with_cast.b1q_1))
|
|
2314
2295
|
return false;
|
|
2315
|
-
if (!equals(this.
|
|
2296
|
+
if (!equals(this.c1q_1, tmp0_other_with_cast.c1q_1))
|
|
2316
2297
|
return false;
|
|
2317
|
-
if (!equals(this.
|
|
2298
|
+
if (!equals(this.d1q_1, tmp0_other_with_cast.d1q_1))
|
|
2318
2299
|
return false;
|
|
2319
2300
|
return true;
|
|
2320
2301
|
};
|
|
2321
2302
|
function GammaTransferFunctions(gamma) {
|
|
2322
|
-
this.
|
|
2303
|
+
this.p1r_1 = gamma;
|
|
2323
2304
|
}
|
|
2324
|
-
protoOf(GammaTransferFunctions).
|
|
2325
|
-
return spow(x, this.
|
|
2305
|
+
protoOf(GammaTransferFunctions).b1r = function (x) {
|
|
2306
|
+
return spow(x, this.p1r_1);
|
|
2326
2307
|
};
|
|
2327
|
-
protoOf(GammaTransferFunctions).
|
|
2328
|
-
return spow(x, 1.0 / this.
|
|
2308
|
+
protoOf(GammaTransferFunctions).c1r = function (x) {
|
|
2309
|
+
return spow(x, 1.0 / this.p1r_1);
|
|
2329
2310
|
};
|
|
2330
2311
|
protoOf(GammaTransferFunctions).toString = function () {
|
|
2331
|
-
return 'GammaTransferFunctions(gamma=' + this.
|
|
2312
|
+
return 'GammaTransferFunctions(gamma=' + this.p1r_1 + ')';
|
|
2332
2313
|
};
|
|
2333
2314
|
protoOf(GammaTransferFunctions).hashCode = function () {
|
|
2334
|
-
return getNumberHashCode(this.
|
|
2315
|
+
return getNumberHashCode(this.p1r_1);
|
|
2335
2316
|
};
|
|
2336
2317
|
protoOf(GammaTransferFunctions).equals = function (other) {
|
|
2337
2318
|
if (this === other)
|
|
@@ -2339,16 +2320,16 @@
|
|
|
2339
2320
|
if (!(other instanceof GammaTransferFunctions))
|
|
2340
2321
|
return false;
|
|
2341
2322
|
var tmp0_other_with_cast = other instanceof GammaTransferFunctions ? other : THROW_CCE();
|
|
2342
|
-
if (!equals(this.
|
|
2323
|
+
if (!equals(this.p1r_1, tmp0_other_with_cast.p1r_1))
|
|
2343
2324
|
return false;
|
|
2344
2325
|
return true;
|
|
2345
2326
|
};
|
|
2346
2327
|
function LinearTransferFunctions() {
|
|
2347
2328
|
}
|
|
2348
|
-
protoOf(LinearTransferFunctions).
|
|
2329
|
+
protoOf(LinearTransferFunctions).b1r = function (x) {
|
|
2349
2330
|
return x;
|
|
2350
2331
|
};
|
|
2351
|
-
protoOf(LinearTransferFunctions).
|
|
2332
|
+
protoOf(LinearTransferFunctions).c1r = function (x) {
|
|
2352
2333
|
return x;
|
|
2353
2334
|
};
|
|
2354
2335
|
var LinearTransferFunctions_instance;
|
|
@@ -2359,49 +2340,49 @@
|
|
|
2359
2340
|
}
|
|
2360
2341
|
function Companion_6() {
|
|
2361
2342
|
Companion_instance_7 = this;
|
|
2362
|
-
this.
|
|
2343
|
+
this.c1o_1 = RGBColorSpaces_getInstance().p1o_1;
|
|
2363
2344
|
}
|
|
2364
|
-
protoOf(Companion_6).
|
|
2365
|
-
return this.
|
|
2345
|
+
protoOf(Companion_6).e1o = function (r, g, b, alpha) {
|
|
2346
|
+
return this.c1o_1.e1o(r, g, b, alpha);
|
|
2366
2347
|
};
|
|
2367
|
-
protoOf(Companion_6).
|
|
2368
|
-
return this.
|
|
2348
|
+
protoOf(Companion_6).d1r = function (r, g, b, alpha) {
|
|
2349
|
+
return this.c1o_1.d1r(r, g, b, alpha);
|
|
2369
2350
|
};
|
|
2370
|
-
protoOf(Companion_6).
|
|
2371
|
-
return this.
|
|
2351
|
+
protoOf(Companion_6).d1o = function (hex) {
|
|
2352
|
+
return this.c1o_1.d1o(hex);
|
|
2372
2353
|
};
|
|
2373
|
-
protoOf(Companion_6).
|
|
2374
|
-
return this.
|
|
2354
|
+
protoOf(Companion_6).i1q = function (r, g, b, alpha) {
|
|
2355
|
+
return this.c1o_1.i1q(r, g, b, alpha);
|
|
2375
2356
|
};
|
|
2376
|
-
protoOf(Companion_6).
|
|
2377
|
-
return this.
|
|
2357
|
+
protoOf(Companion_6).d1n = function (color) {
|
|
2358
|
+
return this.c1o_1.d1n(color);
|
|
2378
2359
|
};
|
|
2379
|
-
protoOf(Companion_6).
|
|
2380
|
-
return this.
|
|
2360
|
+
protoOf(Companion_6).k1n = function (components) {
|
|
2361
|
+
return this.c1o_1.k1n(components);
|
|
2381
2362
|
};
|
|
2382
|
-
protoOf(Companion_6).
|
|
2383
|
-
return this.
|
|
2363
|
+
protoOf(Companion_6).s1q = function () {
|
|
2364
|
+
return this.c1o_1.s1q();
|
|
2384
2365
|
};
|
|
2385
|
-
protoOf(Companion_6).
|
|
2386
|
-
return this.
|
|
2366
|
+
protoOf(Companion_6).q1r = function () {
|
|
2367
|
+
return this.c1o_1.q1r();
|
|
2387
2368
|
};
|
|
2388
|
-
protoOf(Companion_6).
|
|
2389
|
-
return this.
|
|
2369
|
+
protoOf(Companion_6).r1r = function () {
|
|
2370
|
+
return this.c1o_1.r1r();
|
|
2390
2371
|
};
|
|
2391
|
-
protoOf(Companion_6).
|
|
2392
|
-
return this.
|
|
2372
|
+
protoOf(Companion_6).i1n = function () {
|
|
2373
|
+
return this.c1o_1.i1n();
|
|
2393
2374
|
};
|
|
2394
|
-
protoOf(Companion_6).
|
|
2395
|
-
return this.
|
|
2375
|
+
protoOf(Companion_6).q2 = function () {
|
|
2376
|
+
return this.c1o_1.q2();
|
|
2396
2377
|
};
|
|
2397
|
-
protoOf(Companion_6).
|
|
2398
|
-
return this.
|
|
2378
|
+
protoOf(Companion_6).j1n = function () {
|
|
2379
|
+
return this.c1o_1.j1n();
|
|
2399
2380
|
};
|
|
2400
2381
|
protoOf(Companion_6).equals = function (other) {
|
|
2401
|
-
return equals(RGBColorSpaces_getInstance().
|
|
2382
|
+
return equals(RGBColorSpaces_getInstance().p1o_1, other);
|
|
2402
2383
|
};
|
|
2403
2384
|
protoOf(Companion_6).hashCode = function () {
|
|
2404
|
-
return hashCode(RGBColorSpaces_getInstance().
|
|
2385
|
+
return hashCode(RGBColorSpaces_getInstance().p1o_1);
|
|
2405
2386
|
};
|
|
2406
2387
|
var Companion_instance_7;
|
|
2407
2388
|
function Companion_getInstance_6() {
|
|
@@ -2411,117 +2392,93 @@
|
|
|
2411
2392
|
}
|
|
2412
2393
|
function RGB(r, g, b, alpha, space) {
|
|
2413
2394
|
Companion_getInstance_6();
|
|
2414
|
-
this.
|
|
2415
|
-
this.
|
|
2416
|
-
this.
|
|
2417
|
-
this.
|
|
2418
|
-
this.
|
|
2395
|
+
this.e1m_1 = r;
|
|
2396
|
+
this.f1m_1 = g;
|
|
2397
|
+
this.g1m_1 = b;
|
|
2398
|
+
this.h1m_1 = alpha;
|
|
2399
|
+
this.i1m_1 = space;
|
|
2419
2400
|
}
|
|
2420
|
-
protoOf(RGB).
|
|
2421
|
-
return this.
|
|
2401
|
+
protoOf(RGB).a1m = function () {
|
|
2402
|
+
return this.h1m_1;
|
|
2422
2403
|
};
|
|
2423
|
-
protoOf(RGB).
|
|
2424
|
-
return this.
|
|
2404
|
+
protoOf(RGB).b1m = function () {
|
|
2405
|
+
return this.i1m_1;
|
|
2425
2406
|
};
|
|
2426
|
-
protoOf(RGB).
|
|
2407
|
+
protoOf(RGB).m1p = function () {
|
|
2427
2408
|
// Inline function 'com.github.ajalt.colormath.model.RGB.toSRGB' call
|
|
2428
2409
|
// Inline function 'com.github.ajalt.colormath.model.RGB.toRGBInt.<anonymous>' call
|
|
2429
|
-
var $this$toSRGB = this.
|
|
2430
|
-
return _RGBInt___init__impl__lqova7_1($this$toSRGB.
|
|
2410
|
+
var $this$toSRGB = this.s1r(SRGB_getInstance());
|
|
2411
|
+
return _RGBInt___init__impl__lqova7_1($this$toSRGB.e1m_1, $this$toSRGB.f1m_1, $this$toSRGB.g1m_1, nanToOne($this$toSRGB.h1m_1));
|
|
2431
2412
|
};
|
|
2432
|
-
protoOf(RGB).
|
|
2433
|
-
var f = SRGB_getInstance().
|
|
2434
|
-
return equals(this.
|
|
2413
|
+
protoOf(RGB).s1r = function (space) {
|
|
2414
|
+
var f = SRGB_getInstance().s1q();
|
|
2415
|
+
return equals(this.i1m_1, space) ? this : equals(this.i1m_1, SRGB_getInstance()) && equals(space, RGBColorSpaces_getInstance().q1o_1) ? space.e1o(f.b1r(this.e1m_1), f.b1r(this.f1m_1), f.b1r(this.g1m_1), this.h1m_1) : equals(this.i1m_1, RGBColorSpaces_getInstance().q1o_1) && equals(space, SRGB_getInstance()) ? space.e1o(f.c1r(this.e1m_1), f.c1r(this.f1m_1), f.c1r(this.g1m_1), this.h1m_1) : this.j1m().u1r(space);
|
|
2435
2416
|
};
|
|
2436
|
-
protoOf(RGB).
|
|
2417
|
+
protoOf(RGB).d1m = function () {
|
|
2437
2418
|
var tmp$ret$3;
|
|
2438
2419
|
$l$block: {
|
|
2439
2420
|
// Inline function 'com.github.ajalt.colormath.model.RGB.srgbHueMinMaxChroma' call
|
|
2440
2421
|
// Inline function 'com.github.ajalt.colormath.model.RGB.toSRGB' call
|
|
2441
|
-
var $this$toSRGB = this.
|
|
2442
|
-
var r = $this$toSRGB.
|
|
2443
|
-
var g = $this$toSRGB.
|
|
2444
|
-
var b = $this$toSRGB.
|
|
2422
|
+
var $this$toSRGB = this.s1r(SRGB_getInstance());
|
|
2423
|
+
var r = $this$toSRGB.e1m_1;
|
|
2424
|
+
var g = $this$toSRGB.f1m_1;
|
|
2425
|
+
var b = $this$toSRGB.g1m_1;
|
|
2445
2426
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
2446
2427
|
var min = Math.min(r, g, b);
|
|
2447
2428
|
// Inline function 'kotlin.comparisons.maxOf' call
|
|
2448
2429
|
var max = Math.max(r, g, b);
|
|
2449
2430
|
var chroma = max - min;
|
|
2450
|
-
var
|
|
2451
|
-
if (chroma < 1.0E-7) {
|
|
2452
|
-
tmp = NaN;
|
|
2453
|
-
} else if (r === max) {
|
|
2454
|
-
tmp = (g - b) / chroma;
|
|
2455
|
-
} else if (g === max) {
|
|
2456
|
-
tmp = 2 + (b - r) / chroma;
|
|
2457
|
-
} else if (b === max) {
|
|
2458
|
-
tmp = 4 + (r - g) / chroma;
|
|
2459
|
-
} else {
|
|
2460
|
-
tmp = 0.0;
|
|
2461
|
-
}
|
|
2462
|
-
var h = tmp * 60;
|
|
2431
|
+
var h = (chroma < 1.0E-7 ? NaN : r === max ? (g - b) / chroma : g === max ? 2 + (b - r) / chroma : b === max ? 4 + (r - g) / chroma : 0.0) * 60;
|
|
2463
2432
|
// Inline function 'com.github.ajalt.colormath.model.RGB.toHSL.<anonymous>' call
|
|
2464
2433
|
var h_0 = normalizeDeg(h);
|
|
2465
2434
|
var l = (min + max) / 2.0;
|
|
2466
2435
|
var s = max === min ? 0.0 : l <= 0.5 ? chroma / (max + min) : chroma / (2 - max - min);
|
|
2467
|
-
tmp$ret$3 = new HSL(h_0, s, l, this.
|
|
2436
|
+
tmp$ret$3 = new HSL(h_0, s, l, this.h1m_1);
|
|
2468
2437
|
break $l$block;
|
|
2469
2438
|
}
|
|
2470
2439
|
return tmp$ret$3;
|
|
2471
2440
|
};
|
|
2472
|
-
protoOf(RGB).
|
|
2473
|
-
var f = this.
|
|
2441
|
+
protoOf(RGB).j1m = function () {
|
|
2442
|
+
var f = this.i1m_1.s1q();
|
|
2474
2443
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
2475
|
-
var this_0 = _Matrix___init__impl__q3kp4w(this.
|
|
2476
|
-
var v0 = f.
|
|
2477
|
-
var v1 = f.
|
|
2478
|
-
var v2 = f.
|
|
2444
|
+
var this_0 = _Matrix___init__impl__q3kp4w(this.i1m_1.q1r());
|
|
2445
|
+
var v0 = f.b1r(this.e1m_1);
|
|
2446
|
+
var v1 = f.b1r(this.f1m_1);
|
|
2447
|
+
var v2 = f.b1r(this.g1m_1);
|
|
2479
2448
|
// Inline function 'com.github.ajalt.colormath.model.RGB.toXYZ.<anonymous>' call
|
|
2480
2449
|
var x = Matrix__get_impl_xogbpk(this_0, 0, 0) * v0 + Matrix__get_impl_xogbpk(this_0, 1, 0) * v1 + Matrix__get_impl_xogbpk(this_0, 2, 0) * v2;
|
|
2481
2450
|
var y = Matrix__get_impl_xogbpk(this_0, 0, 1) * v0 + Matrix__get_impl_xogbpk(this_0, 1, 1) * v1 + Matrix__get_impl_xogbpk(this_0, 2, 1) * v2;
|
|
2482
2451
|
var z = Matrix__get_impl_xogbpk(this_0, 0, 2) * v0 + Matrix__get_impl_xogbpk(this_0, 1, 2) * v1 + Matrix__get_impl_xogbpk(this_0, 2, 2) * v2;
|
|
2483
|
-
return XYZColorSpace_0(this.
|
|
2452
|
+
return XYZColorSpace_0(this.i1m_1.i1n()).e1o(x, y, z, this.h1m_1);
|
|
2484
2453
|
};
|
|
2485
|
-
protoOf(RGB).
|
|
2454
|
+
protoOf(RGB).w1m = function () {
|
|
2486
2455
|
var tmp$ret$3;
|
|
2487
2456
|
$l$block: {
|
|
2488
2457
|
// Inline function 'com.github.ajalt.colormath.model.RGB.srgbHueMinMaxChroma' call
|
|
2489
2458
|
// Inline function 'com.github.ajalt.colormath.model.RGB.toSRGB' call
|
|
2490
|
-
var $this$toSRGB = this.
|
|
2491
|
-
var r = $this$toSRGB.
|
|
2492
|
-
var g = $this$toSRGB.
|
|
2493
|
-
var b = $this$toSRGB.
|
|
2459
|
+
var $this$toSRGB = this.s1r(SRGB_getInstance());
|
|
2460
|
+
var r = $this$toSRGB.e1m_1;
|
|
2461
|
+
var g = $this$toSRGB.f1m_1;
|
|
2462
|
+
var b = $this$toSRGB.g1m_1;
|
|
2494
2463
|
// Inline function 'kotlin.comparisons.minOf' call
|
|
2495
2464
|
var min = Math.min(r, g, b);
|
|
2496
2465
|
// Inline function 'kotlin.comparisons.maxOf' call
|
|
2497
2466
|
var max = Math.max(r, g, b);
|
|
2498
2467
|
var chroma = max - min;
|
|
2499
|
-
var
|
|
2500
|
-
if (chroma < 1.0E-7) {
|
|
2501
|
-
tmp = NaN;
|
|
2502
|
-
} else if (r === max) {
|
|
2503
|
-
tmp = (g - b) / chroma;
|
|
2504
|
-
} else if (g === max) {
|
|
2505
|
-
tmp = 2 + (b - r) / chroma;
|
|
2506
|
-
} else if (b === max) {
|
|
2507
|
-
tmp = 4 + (r - g) / chroma;
|
|
2508
|
-
} else {
|
|
2509
|
-
tmp = 0.0;
|
|
2510
|
-
}
|
|
2511
|
-
var h = tmp * 60;
|
|
2468
|
+
var h = (chroma < 1.0E-7 ? NaN : r === max ? (g - b) / chroma : g === max ? 2 + (b - r) / chroma : b === max ? 4 + (r - g) / chroma : 0.0) * 60;
|
|
2512
2469
|
// Inline function 'com.github.ajalt.colormath.model.RGB.toHWB.<anonymous>' call
|
|
2513
2470
|
var hue = normalizeDeg(h);
|
|
2514
|
-
tmp$ret$3 = new HWB(hue, min, 1.0 - max, this.
|
|
2471
|
+
tmp$ret$3 = new HWB(hue, min, 1.0 - max, this.h1m_1);
|
|
2515
2472
|
break $l$block;
|
|
2516
2473
|
}
|
|
2517
2474
|
return tmp$ret$3;
|
|
2518
2475
|
};
|
|
2519
|
-
protoOf(RGB).
|
|
2520
|
-
if (!equals(this.
|
|
2521
|
-
return this.
|
|
2522
|
-
var r = this.
|
|
2523
|
-
var g = this.
|
|
2524
|
-
var b = this.
|
|
2476
|
+
protoOf(RGB).x1m = function () {
|
|
2477
|
+
if (!equals(this.i1m_1, RGBColorSpaces_getInstance().p1o_1))
|
|
2478
|
+
return this.j1m().x1m();
|
|
2479
|
+
var r = this.i1m_1.s1q().b1r(this.e1m_1);
|
|
2480
|
+
var g = this.i1m_1.s1q().b1r(this.f1m_1);
|
|
2481
|
+
var b = this.i1m_1.s1q().b1r(this.g1m_1);
|
|
2525
2482
|
var l = 0.4122214708 * r + 0.5363325363 * g + 0.0514459929 * b;
|
|
2526
2483
|
var m = 0.2119034982 * r + 0.6806995451 * g + 0.1073969566 * b;
|
|
2527
2484
|
var s = 0.0883024619 * r + 0.2817188376 * g + 0.6299787005 * b;
|
|
@@ -2531,24 +2488,24 @@
|
|
|
2531
2488
|
var mm = Math.cbrt(m);
|
|
2532
2489
|
// Inline function 'kotlin.math.cbrt' call
|
|
2533
2490
|
var ss = Math.cbrt(s);
|
|
2534
|
-
return Oklab_init_$Create$(0.21045426 * ll + 0.7936178 * mm - 0.004072047 * ss, 1.9779985 * ll - 2.4285922 * mm + 0.4505937 * ss, 0.025904037 * ll + 0.78277177 * mm - 0.80867577 * ss, this.
|
|
2491
|
+
return Oklab_init_$Create$(0.21045426 * ll + 0.7936178 * mm - 0.004072047 * ss, 1.9779985 * ll - 2.4285922 * mm + 0.4505937 * ss, 0.025904037 * ll + 0.78277177 * mm - 0.80867577 * ss, this.h1m_1);
|
|
2535
2492
|
};
|
|
2536
|
-
protoOf(RGB).
|
|
2537
|
-
return this.
|
|
2493
|
+
protoOf(RGB).c1m = function () {
|
|
2494
|
+
return this.s1r(RGBColorSpaces_getInstance().p1o_1);
|
|
2538
2495
|
};
|
|
2539
|
-
protoOf(RGB).
|
|
2496
|
+
protoOf(RGB).u5 = function () {
|
|
2540
2497
|
// Inline function 'kotlin.floatArrayOf' call
|
|
2541
|
-
return new Float32Array([this.
|
|
2498
|
+
return new Float32Array([this.e1m_1, this.f1m_1, this.g1m_1, this.h1m_1]);
|
|
2542
2499
|
};
|
|
2543
2500
|
protoOf(RGB).toString = function () {
|
|
2544
|
-
return 'RGB(r=' + this.
|
|
2501
|
+
return 'RGB(r=' + this.e1m_1 + ', g=' + this.f1m_1 + ', b=' + this.g1m_1 + ', alpha=' + this.h1m_1 + ', space=' + toString(this.i1m_1) + ')';
|
|
2545
2502
|
};
|
|
2546
2503
|
protoOf(RGB).hashCode = function () {
|
|
2547
|
-
var result = getNumberHashCode(this.
|
|
2548
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2549
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2550
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
2551
|
-
result = imul(result, 31) + hashCode(this.
|
|
2504
|
+
var result = getNumberHashCode(this.e1m_1);
|
|
2505
|
+
result = imul(result, 31) + getNumberHashCode(this.f1m_1) | 0;
|
|
2506
|
+
result = imul(result, 31) + getNumberHashCode(this.g1m_1) | 0;
|
|
2507
|
+
result = imul(result, 31) + getNumberHashCode(this.h1m_1) | 0;
|
|
2508
|
+
result = imul(result, 31) + hashCode(this.i1m_1) | 0;
|
|
2552
2509
|
return result;
|
|
2553
2510
|
};
|
|
2554
2511
|
protoOf(RGB).equals = function (other) {
|
|
@@ -2557,15 +2514,15 @@
|
|
|
2557
2514
|
if (!(other instanceof RGB))
|
|
2558
2515
|
return false;
|
|
2559
2516
|
var tmp0_other_with_cast = other instanceof RGB ? other : THROW_CCE();
|
|
2560
|
-
if (!equals(this.
|
|
2517
|
+
if (!equals(this.e1m_1, tmp0_other_with_cast.e1m_1))
|
|
2561
2518
|
return false;
|
|
2562
|
-
if (!equals(this.
|
|
2519
|
+
if (!equals(this.f1m_1, tmp0_other_with_cast.f1m_1))
|
|
2563
2520
|
return false;
|
|
2564
|
-
if (!equals(this.
|
|
2521
|
+
if (!equals(this.g1m_1, tmp0_other_with_cast.g1m_1))
|
|
2565
2522
|
return false;
|
|
2566
|
-
if (!equals(this.
|
|
2523
|
+
if (!equals(this.h1m_1, tmp0_other_with_cast.h1m_1))
|
|
2567
2524
|
return false;
|
|
2568
|
-
if (!equals(this.
|
|
2525
|
+
if (!equals(this.i1m_1, tmp0_other_with_cast.i1m_1))
|
|
2569
2526
|
return false;
|
|
2570
2527
|
return true;
|
|
2571
2528
|
};
|
|
@@ -2665,18 +2622,18 @@
|
|
|
2665
2622
|
return ACES_AP1_B;
|
|
2666
2623
|
}
|
|
2667
2624
|
var ACES_AP1_B;
|
|
2668
|
-
function RGBColorSpaces$SRGB$lambda($this
|
|
2669
|
-
return it.
|
|
2625
|
+
function RGBColorSpaces$SRGB$lambda($this$RGBColorSpaceImpl, it) {
|
|
2626
|
+
return it.c1m();
|
|
2670
2627
|
}
|
|
2671
|
-
function RGBColorSpaces$BT2020$lambda($this
|
|
2628
|
+
function RGBColorSpaces$BT2020$lambda($this$RGBColorSpaceImpl, color) {
|
|
2672
2629
|
var tmp;
|
|
2673
2630
|
if (color instanceof RGB) {
|
|
2674
|
-
tmp = color.
|
|
2631
|
+
tmp = color.s1r($this$RGBColorSpaceImpl);
|
|
2675
2632
|
} else {
|
|
2676
2633
|
if (color instanceof ICtCp) {
|
|
2677
|
-
tmp = color.
|
|
2634
|
+
tmp = color.r1q();
|
|
2678
2635
|
} else {
|
|
2679
|
-
tmp = color.
|
|
2636
|
+
tmp = color.j1m().u1r($this$RGBColorSpaceImpl);
|
|
2680
2637
|
}
|
|
2681
2638
|
}
|
|
2682
2639
|
return tmp;
|
|
@@ -2684,29 +2641,29 @@
|
|
|
2684
2641
|
function RGBColorSpaces() {
|
|
2685
2642
|
RGBColorSpaces_instance = this;
|
|
2686
2643
|
var tmp = this;
|
|
2687
|
-
var tmp_0 = Illuminant_getInstance().
|
|
2644
|
+
var tmp_0 = Illuminant_getInstance().j1p_1;
|
|
2688
2645
|
var tmp_1 = SRGBTransferFunctions_instance;
|
|
2689
2646
|
var tmp_2 = get_SRGB_R();
|
|
2690
2647
|
var tmp_3 = get_SRGB_G();
|
|
2691
2648
|
var tmp_4 = get_SRGB_B();
|
|
2692
|
-
tmp.
|
|
2693
|
-
this.
|
|
2694
|
-
this.
|
|
2695
|
-
this.
|
|
2696
|
-
this.
|
|
2697
|
-
this.
|
|
2698
|
-
this.
|
|
2649
|
+
tmp.p1o_1 = new RGBColorSpaceImpl('sRGB', tmp_0, tmp_1, tmp_2, tmp_3, tmp_4, RGBColorSpaces$SRGB$lambda);
|
|
2650
|
+
this.q1o_1 = RGBColorSpace_0('Linear sRGB', Illuminant_getInstance().j1p_1, LinearTransferFunctions_instance, get_SRGB_R(), get_SRGB_G(), get_SRGB_B());
|
|
2651
|
+
this.r1o_1 = RGBColorSpace_0('ACES2065-1', get_ACES_WHITE_POINT(), LinearTransferFunctions_instance, get_ACES_AP0_R(), get_ACES_AP0_G(), get_ACES_AP0_B());
|
|
2652
|
+
this.s1o_1 = RGBColorSpace_0('ACEScc', get_ACES_WHITE_POINT(), ACESccTransferFunctions_getInstance(), get_ACES_AP1_R(), get_ACES_AP1_G(), get_ACES_AP1_B());
|
|
2653
|
+
this.t1o_1 = RGBColorSpace_0('ACEScct', get_ACES_WHITE_POINT(), ACEScctTransferFunctions_getInstance(), get_ACES_AP1_R(), get_ACES_AP1_G(), get_ACES_AP1_B());
|
|
2654
|
+
this.u1o_1 = RGBColorSpace_0('ACEScg', get_ACES_WHITE_POINT(), LinearTransferFunctions_instance, get_ACES_AP1_R(), get_ACES_AP1_G(), get_ACES_AP1_B());
|
|
2655
|
+
this.v1o_1 = RGBColorSpace_0('Adobe RGB', Illuminant_getInstance().j1p_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));
|
|
2699
2656
|
var tmp_5 = this;
|
|
2700
|
-
var tmp_6 = Illuminant_getInstance().
|
|
2657
|
+
var tmp_6 = Illuminant_getInstance().j1p_1;
|
|
2701
2658
|
var tmp_7 = BT2020TransferFunctions_getInstance();
|
|
2702
2659
|
var tmp_8 = xyY_init_$Create$(0.708, 0.292);
|
|
2703
2660
|
var tmp_9 = xyY_init_$Create$(0.17, 0.797);
|
|
2704
2661
|
var tmp_10 = xyY_init_$Create$(0.131, 0.046);
|
|
2705
|
-
tmp_5.
|
|
2706
|
-
this.
|
|
2707
|
-
this.
|
|
2708
|
-
this.
|
|
2709
|
-
this.
|
|
2662
|
+
tmp_5.w1o_1 = new RGBColorSpaceImpl('BT.2020', tmp_6, tmp_7, tmp_8, tmp_9, tmp_10, RGBColorSpaces$BT2020$lambda);
|
|
2663
|
+
this.x1o_1 = RGBColorSpace_0('BT.709', Illuminant_getInstance().j1p_1, BT709TransferFunctions_getInstance(), xyY_init_$Create$(0.64, 0.33), xyY_init_$Create$(0.3, 0.6), xyY_init_$Create$(0.15, 0.06));
|
|
2664
|
+
this.y1o_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));
|
|
2665
|
+
this.z1o_1 = RGBColorSpace_0('Display P3', Illuminant_getInstance().j1p_1, SRGBTransferFunctions_instance, xyY_init_$Create$(0.68, 0.32), xyY_init_$Create$(0.265, 0.69), xyY_init_$Create$(0.15, 0.06));
|
|
2666
|
+
this.a1p_1 = RGBColorSpace_0('ROMM RGB', Illuminant_getInstance().h1p_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));
|
|
2710
2667
|
}
|
|
2711
2668
|
var RGBColorSpaces_instance;
|
|
2712
2669
|
function RGBColorSpaces_getInstance() {
|
|
@@ -2716,49 +2673,49 @@
|
|
|
2716
2673
|
}
|
|
2717
2674
|
function SRGB() {
|
|
2718
2675
|
SRGB_instance = this;
|
|
2719
|
-
this.
|
|
2676
|
+
this.k1q_1 = RGBColorSpaces_getInstance().p1o_1;
|
|
2720
2677
|
}
|
|
2721
|
-
protoOf(SRGB).
|
|
2722
|
-
return this.
|
|
2678
|
+
protoOf(SRGB).e1o = function (r, g, b, alpha) {
|
|
2679
|
+
return this.k1q_1.e1o(r, g, b, alpha);
|
|
2723
2680
|
};
|
|
2724
|
-
protoOf(SRGB).
|
|
2725
|
-
return this.
|
|
2681
|
+
protoOf(SRGB).d1r = function (r, g, b, alpha) {
|
|
2682
|
+
return this.k1q_1.d1r(r, g, b, alpha);
|
|
2726
2683
|
};
|
|
2727
|
-
protoOf(SRGB).
|
|
2728
|
-
return this.
|
|
2684
|
+
protoOf(SRGB).d1o = function (hex) {
|
|
2685
|
+
return this.k1q_1.d1o(hex);
|
|
2729
2686
|
};
|
|
2730
|
-
protoOf(SRGB).
|
|
2731
|
-
return this.
|
|
2687
|
+
protoOf(SRGB).i1q = function (r, g, b, alpha) {
|
|
2688
|
+
return this.k1q_1.i1q(r, g, b, alpha);
|
|
2732
2689
|
};
|
|
2733
|
-
protoOf(SRGB).
|
|
2734
|
-
return this.
|
|
2690
|
+
protoOf(SRGB).d1n = function (color) {
|
|
2691
|
+
return this.k1q_1.d1n(color);
|
|
2735
2692
|
};
|
|
2736
|
-
protoOf(SRGB).
|
|
2737
|
-
return this.
|
|
2693
|
+
protoOf(SRGB).k1n = function (components) {
|
|
2694
|
+
return this.k1q_1.k1n(components);
|
|
2738
2695
|
};
|
|
2739
|
-
protoOf(SRGB).
|
|
2740
|
-
return this.
|
|
2696
|
+
protoOf(SRGB).s1q = function () {
|
|
2697
|
+
return this.k1q_1.s1q();
|
|
2741
2698
|
};
|
|
2742
|
-
protoOf(SRGB).
|
|
2743
|
-
return this.
|
|
2699
|
+
protoOf(SRGB).q1r = function () {
|
|
2700
|
+
return this.k1q_1.q1r();
|
|
2744
2701
|
};
|
|
2745
|
-
protoOf(SRGB).
|
|
2746
|
-
return this.
|
|
2702
|
+
protoOf(SRGB).r1r = function () {
|
|
2703
|
+
return this.k1q_1.r1r();
|
|
2747
2704
|
};
|
|
2748
|
-
protoOf(SRGB).
|
|
2749
|
-
return this.
|
|
2705
|
+
protoOf(SRGB).i1n = function () {
|
|
2706
|
+
return this.k1q_1.i1n();
|
|
2750
2707
|
};
|
|
2751
|
-
protoOf(SRGB).
|
|
2752
|
-
return this.
|
|
2708
|
+
protoOf(SRGB).q2 = function () {
|
|
2709
|
+
return this.k1q_1.q2();
|
|
2753
2710
|
};
|
|
2754
|
-
protoOf(SRGB).
|
|
2755
|
-
return this.
|
|
2711
|
+
protoOf(SRGB).j1n = function () {
|
|
2712
|
+
return this.k1q_1.j1n();
|
|
2756
2713
|
};
|
|
2757
2714
|
protoOf(SRGB).equals = function (other) {
|
|
2758
|
-
return equals(RGBColorSpaces_getInstance().
|
|
2715
|
+
return equals(RGBColorSpaces_getInstance().p1o_1, other);
|
|
2759
2716
|
};
|
|
2760
2717
|
protoOf(SRGB).hashCode = function () {
|
|
2761
|
-
return hashCode(RGBColorSpaces_getInstance().
|
|
2718
|
+
return hashCode(RGBColorSpaces_getInstance().p1o_1);
|
|
2762
2719
|
};
|
|
2763
2720
|
protoOf(SRGB).toString = function () {
|
|
2764
2721
|
return 'sRGB';
|
|
@@ -2770,36 +2727,36 @@
|
|
|
2770
2727
|
return SRGB_instance;
|
|
2771
2728
|
}
|
|
2772
2729
|
function RGBColorSpaceImpl(name, whitePoint, transferFunctions, r, g, b, convertImpl) {
|
|
2773
|
-
this.
|
|
2774
|
-
this.
|
|
2775
|
-
this.
|
|
2776
|
-
this.
|
|
2777
|
-
this.
|
|
2778
|
-
this.
|
|
2779
|
-
this.
|
|
2780
|
-
this.
|
|
2781
|
-
this.
|
|
2782
|
-
this.
|
|
2730
|
+
this.v1r_1 = name;
|
|
2731
|
+
this.w1r_1 = whitePoint;
|
|
2732
|
+
this.x1r_1 = transferFunctions;
|
|
2733
|
+
this.y1r_1 = r;
|
|
2734
|
+
this.z1r_1 = g;
|
|
2735
|
+
this.a1s_1 = b;
|
|
2736
|
+
this.b1s_1 = convertImpl;
|
|
2737
|
+
this.c1s_1 = zeroOneComponentInfo('RGB');
|
|
2738
|
+
this.d1s_1 = _Matrix___get_rowMajor__impl__vmgxkq(rgbToXyzMatrix(this.w1r_1, this.y1r_1, this.z1r_1, this.a1s_1));
|
|
2739
|
+
this.e1s_1 = _Matrix___get_rowMajor__impl__vmgxkq(inverse(_Matrix___init__impl__q3kp4w(this.d1s_1)));
|
|
2783
2740
|
}
|
|
2784
2741
|
protoOf(RGBColorSpaceImpl).q2 = function () {
|
|
2785
|
-
return this.
|
|
2742
|
+
return this.v1r_1;
|
|
2786
2743
|
};
|
|
2787
|
-
protoOf(RGBColorSpaceImpl).
|
|
2788
|
-
return this.
|
|
2744
|
+
protoOf(RGBColorSpaceImpl).i1n = function () {
|
|
2745
|
+
return this.w1r_1;
|
|
2789
2746
|
};
|
|
2790
|
-
protoOf(RGBColorSpaceImpl).
|
|
2791
|
-
return this.
|
|
2747
|
+
protoOf(RGBColorSpaceImpl).s1q = function () {
|
|
2748
|
+
return this.x1r_1;
|
|
2792
2749
|
};
|
|
2793
|
-
protoOf(RGBColorSpaceImpl).
|
|
2794
|
-
return this.
|
|
2750
|
+
protoOf(RGBColorSpaceImpl).j1n = function () {
|
|
2751
|
+
return this.c1s_1;
|
|
2795
2752
|
};
|
|
2796
|
-
protoOf(RGBColorSpaceImpl).
|
|
2797
|
-
return this.
|
|
2753
|
+
protoOf(RGBColorSpaceImpl).d1n = function (color) {
|
|
2754
|
+
return this.b1s_1(this, color);
|
|
2798
2755
|
};
|
|
2799
|
-
protoOf(RGBColorSpaceImpl).
|
|
2756
|
+
protoOf(RGBColorSpaceImpl).k1n = function (components) {
|
|
2800
2757
|
// Inline function 'com.github.ajalt.colormath.internal.doCreate' call
|
|
2801
2758
|
// Inline function 'com.github.ajalt.colormath.internal.withValidComps' call
|
|
2802
|
-
var size = this.
|
|
2759
|
+
var size = this.j1n().m();
|
|
2803
2760
|
// Inline function 'kotlin.require' call
|
|
2804
2761
|
var containsLower = size - 1 | 0;
|
|
2805
2762
|
var containsArg = components.length;
|
|
@@ -2823,18 +2780,18 @@
|
|
|
2823
2780
|
tmp = 1.0;
|
|
2824
2781
|
}
|
|
2825
2782
|
var p3 = tmp;
|
|
2826
|
-
return this.
|
|
2783
|
+
return this.e1o(p0, p1, p2, p3);
|
|
2827
2784
|
};
|
|
2828
|
-
protoOf(RGBColorSpaceImpl).
|
|
2829
|
-
return this.
|
|
2785
|
+
protoOf(RGBColorSpaceImpl).q1r = function () {
|
|
2786
|
+
return this.d1s_1;
|
|
2830
2787
|
};
|
|
2831
|
-
protoOf(RGBColorSpaceImpl).
|
|
2832
|
-
return this.
|
|
2788
|
+
protoOf(RGBColorSpaceImpl).r1r = function () {
|
|
2789
|
+
return this.e1s_1;
|
|
2833
2790
|
};
|
|
2834
2791
|
protoOf(RGBColorSpaceImpl).toString = function () {
|
|
2835
|
-
return this.
|
|
2792
|
+
return this.v1r_1;
|
|
2836
2793
|
};
|
|
2837
|
-
protoOf(RGBColorSpaceImpl).
|
|
2794
|
+
protoOf(RGBColorSpaceImpl).e1o = function (r, g, b, alpha) {
|
|
2838
2795
|
return new RGB(r, g, b, alpha, this);
|
|
2839
2796
|
};
|
|
2840
2797
|
protoOf(RGBColorSpaceImpl).equals = function (other) {
|
|
@@ -2842,42 +2799,42 @@
|
|
|
2842
2799
|
return true;
|
|
2843
2800
|
if (!(!(other == null) ? isInterface(other, RGBColorSpace) : false))
|
|
2844
2801
|
return false;
|
|
2845
|
-
if (!(this.
|
|
2802
|
+
if (!(this.v1r_1 === other.q2()))
|
|
2846
2803
|
return false;
|
|
2847
|
-
if (!this.
|
|
2804
|
+
if (!this.w1r_1.equals(other.i1n()))
|
|
2848
2805
|
return false;
|
|
2849
|
-
if (!equals(this.
|
|
2806
|
+
if (!equals(this.x1r_1, other.s1q()))
|
|
2850
2807
|
return false;
|
|
2851
2808
|
if (other instanceof RGBColorSpaceImpl) {
|
|
2852
|
-
if (!this.
|
|
2809
|
+
if (!this.y1r_1.equals(other.y1r_1))
|
|
2853
2810
|
return false;
|
|
2854
|
-
if (!this.
|
|
2811
|
+
if (!this.z1r_1.equals(other.z1r_1))
|
|
2855
2812
|
return false;
|
|
2856
|
-
if (!this.
|
|
2813
|
+
if (!this.a1s_1.equals(other.a1s_1))
|
|
2857
2814
|
return false;
|
|
2858
2815
|
} else {
|
|
2859
|
-
if (!contentEquals(this.
|
|
2816
|
+
if (!contentEquals(this.d1s_1, other.q1r()))
|
|
2860
2817
|
return false;
|
|
2861
|
-
if (!contentEquals(this.
|
|
2818
|
+
if (!contentEquals(this.e1s_1, other.r1r()))
|
|
2862
2819
|
return false;
|
|
2863
2820
|
}
|
|
2864
2821
|
return true;
|
|
2865
2822
|
};
|
|
2866
2823
|
protoOf(RGBColorSpaceImpl).hashCode = function () {
|
|
2867
|
-
var result = getStringHashCode(this.
|
|
2868
|
-
result = imul(31, result) + this.
|
|
2869
|
-
result = imul(31, result) + hashCode(this.
|
|
2870
|
-
result = imul(31, result) + this.
|
|
2871
|
-
result = imul(31, result) + this.
|
|
2872
|
-
result = imul(31, result) + this.
|
|
2824
|
+
var result = getStringHashCode(this.v1r_1);
|
|
2825
|
+
result = imul(31, result) + this.w1r_1.hashCode() | 0;
|
|
2826
|
+
result = imul(31, result) + hashCode(this.x1r_1) | 0;
|
|
2827
|
+
result = imul(31, result) + this.y1r_1.hashCode() | 0;
|
|
2828
|
+
result = imul(31, result) + this.z1r_1.hashCode() | 0;
|
|
2829
|
+
result = imul(31, result) + this.a1s_1.hashCode() | 0;
|
|
2873
2830
|
return result;
|
|
2874
2831
|
};
|
|
2875
2832
|
function SRGBTransferFunctions() {
|
|
2876
2833
|
}
|
|
2877
|
-
protoOf(SRGBTransferFunctions).
|
|
2834
|
+
protoOf(SRGBTransferFunctions).c1r = function (x) {
|
|
2878
2835
|
return x <= 0.0031308 ? x * 12.92 : 1.055 * spow(x, 1 / 2.4) - 0.055;
|
|
2879
2836
|
};
|
|
2880
|
-
protoOf(SRGBTransferFunctions).
|
|
2837
|
+
protoOf(SRGBTransferFunctions).b1r = function (x) {
|
|
2881
2838
|
return x <= 0.04045 ? x / 12.92 : spow_0((x + 0.055) / 1.055, 2.4);
|
|
2882
2839
|
};
|
|
2883
2840
|
var SRGBTransferFunctions_instance;
|
|
@@ -2890,39 +2847,30 @@
|
|
|
2890
2847
|
}
|
|
2891
2848
|
function ACESccTransferFunctions() {
|
|
2892
2849
|
ACESccTransferFunctions_instance = this;
|
|
2893
|
-
this.
|
|
2894
|
-
this.
|
|
2895
|
-
this.
|
|
2850
|
+
this.f1s_1 = 3.0517578125E-5;
|
|
2851
|
+
this.g1s_1 = 1.52587890625E-5;
|
|
2852
|
+
this.h1s_1 = -0.3013698630136986;
|
|
2896
2853
|
var tmp = this;
|
|
2897
2854
|
// Inline function 'kotlin.math.log2' call
|
|
2898
|
-
tmp.
|
|
2855
|
+
tmp.i1s_1 = (log2(65504.0) + 9.72) / 17.52;
|
|
2899
2856
|
}
|
|
2900
|
-
protoOf(ACESccTransferFunctions).
|
|
2857
|
+
protoOf(ACESccTransferFunctions).b1r = function (x) {
|
|
2901
2858
|
var tmp;
|
|
2902
|
-
|
|
2903
|
-
|
|
2904
|
-
if (
|
|
2905
|
-
|
|
2906
|
-
|
|
2907
|
-
tmp = (
|
|
2859
|
+
if (x <= -0.3013698630136986) {
|
|
2860
|
+
tmp = (spow_0(2.0, x * 17.52 - 9.72) - 1.52587890625E-5) * 2.0;
|
|
2861
|
+
} else if (x < this.i1s_1) {
|
|
2862
|
+
// Inline function 'kotlin.math.pow' call
|
|
2863
|
+
var x_0 = x * 17.52 - 9.72;
|
|
2864
|
+
tmp = Math.pow(2.0, x_0);
|
|
2908
2865
|
} else {
|
|
2909
|
-
|
|
2910
|
-
// Inline function 'kotlin.math.pow' call
|
|
2911
|
-
var x_0 = x * 17.52 - 9.72;
|
|
2912
|
-
tmp = Math.pow(2.0, x_0);
|
|
2913
|
-
} else {
|
|
2914
|
-
tmp = 65504.0;
|
|
2915
|
-
}
|
|
2866
|
+
tmp = 65504.0;
|
|
2916
2867
|
}
|
|
2917
2868
|
return tmp;
|
|
2918
2869
|
};
|
|
2919
|
-
protoOf(ACESccTransferFunctions).
|
|
2870
|
+
protoOf(ACESccTransferFunctions).c1r = function (x) {
|
|
2920
2871
|
var tmp;
|
|
2921
|
-
|
|
2922
|
-
ACESccTransferFunctions_getInstance();
|
|
2923
|
-
if (tmp_0 < 3.0517578125E-5) {
|
|
2872
|
+
if (x < 3.0517578125E-5) {
|
|
2924
2873
|
// Inline function 'kotlin.math.log2' call
|
|
2925
|
-
ACESccTransferFunctions_getInstance();
|
|
2926
2874
|
var x_0 = 1.52587890625E-5 + coerceAtLeast_0(x, 0.0) / 2.0;
|
|
2927
2875
|
tmp = (log2(x_0) + 9.72) / 17.52;
|
|
2928
2876
|
} else {
|
|
@@ -2939,20 +2887,17 @@
|
|
|
2939
2887
|
}
|
|
2940
2888
|
function ACEScctTransferFunctions() {
|
|
2941
2889
|
ACEScctTransferFunctions_instance = this;
|
|
2942
|
-
this.
|
|
2943
|
-
this.
|
|
2890
|
+
this.j1s_1 = 10.5402377416545;
|
|
2891
|
+
this.k1s_1 = 0.0729055341958355;
|
|
2944
2892
|
var tmp = this;
|
|
2945
2893
|
// Inline function 'kotlin.math.log2' call
|
|
2946
|
-
tmp.
|
|
2894
|
+
tmp.l1s_1 = (log2(65504.0) + 9.72) / 17.52;
|
|
2947
2895
|
}
|
|
2948
|
-
protoOf(ACEScctTransferFunctions).
|
|
2896
|
+
protoOf(ACEScctTransferFunctions).b1r = function (x) {
|
|
2949
2897
|
var tmp;
|
|
2950
2898
|
if (x <= 0.155251141552511) {
|
|
2951
|
-
|
|
2952
|
-
|
|
2953
|
-
ACEScctTransferFunctions_getInstance();
|
|
2954
|
-
tmp = tmp_0 / 10.5402377416545;
|
|
2955
|
-
} else if (x < this.r1s_1) {
|
|
2899
|
+
tmp = (x - 0.0729055341958355) / 10.5402377416545;
|
|
2900
|
+
} else if (x < this.l1s_1) {
|
|
2956
2901
|
// Inline function 'kotlin.math.pow' call
|
|
2957
2902
|
var x_0 = x * 17.52 - 9.72;
|
|
2958
2903
|
tmp = Math.pow(2.0, x_0);
|
|
@@ -2961,13 +2906,10 @@
|
|
|
2961
2906
|
}
|
|
2962
2907
|
return tmp;
|
|
2963
2908
|
};
|
|
2964
|
-
protoOf(ACEScctTransferFunctions).
|
|
2909
|
+
protoOf(ACEScctTransferFunctions).c1r = function (x) {
|
|
2965
2910
|
var tmp;
|
|
2966
2911
|
if (x < 0.0078125) {
|
|
2967
|
-
|
|
2968
|
-
var tmp_0 = 10.5402377416545 * x;
|
|
2969
|
-
ACEScctTransferFunctions_getInstance();
|
|
2970
|
-
tmp = tmp_0 + 0.0729055341958355;
|
|
2912
|
+
tmp = 10.5402377416545 * x + 0.0729055341958355;
|
|
2971
2913
|
} else {
|
|
2972
2914
|
// Inline function 'kotlin.math.log2' call
|
|
2973
2915
|
tmp = (log2(x) + 9.72) / 17.52;
|
|
@@ -2982,41 +2924,17 @@
|
|
|
2982
2924
|
}
|
|
2983
2925
|
function BT2020TransferFunctions() {
|
|
2984
2926
|
BT2020TransferFunctions_instance = this;
|
|
2985
|
-
this.
|
|
2986
|
-
this.
|
|
2927
|
+
this.m1s_1 = 1.0993;
|
|
2928
|
+
this.n1s_1 = 0.0181;
|
|
2987
2929
|
var tmp = this;
|
|
2988
|
-
BT2020TransferFunctions_getInstance();
|
|
2989
2930
|
// Inline function 'kotlin.math.pow' call
|
|
2990
|
-
|
|
2991
|
-
var tmp_0 = 1.0993 * Math.pow(0.0181, 0.45);
|
|
2992
|
-
BT2020TransferFunctions_getInstance();
|
|
2993
|
-
tmp.u1s_1 = tmp_0 - (1.0993 - 1);
|
|
2931
|
+
tmp.o1s_1 = 1.0993 * Math.pow(0.0181, 0.45) - (1.0993 - 1);
|
|
2994
2932
|
}
|
|
2995
|
-
protoOf(BT2020TransferFunctions).
|
|
2996
|
-
|
|
2997
|
-
if (x < this.u1s_1) {
|
|
2998
|
-
tmp = x / 4.5;
|
|
2999
|
-
} else {
|
|
3000
|
-
BT2020TransferFunctions_getInstance();
|
|
3001
|
-
var tmp_0 = x + (1.0993 - 1);
|
|
3002
|
-
BT2020TransferFunctions_getInstance();
|
|
3003
|
-
tmp = spow_0(tmp_0 / 1.0993, 1 / 0.45);
|
|
3004
|
-
}
|
|
3005
|
-
return numberToDouble(tmp);
|
|
2933
|
+
protoOf(BT2020TransferFunctions).b1r = function (x) {
|
|
2934
|
+
return numberToDouble(x < this.o1s_1 ? x / 4.5 : spow_0((x + (1.0993 - 1)) / 1.0993, 1 / 0.45));
|
|
3006
2935
|
};
|
|
3007
|
-
protoOf(BT2020TransferFunctions).
|
|
3008
|
-
|
|
3009
|
-
var tmp_0 = x;
|
|
3010
|
-
BT2020TransferFunctions_getInstance();
|
|
3011
|
-
if (tmp_0 < 0.0181) {
|
|
3012
|
-
tmp = 4.5 * x;
|
|
3013
|
-
} else {
|
|
3014
|
-
BT2020TransferFunctions_getInstance();
|
|
3015
|
-
var tmp_1 = 1.0993 * spow(x, 0.45);
|
|
3016
|
-
BT2020TransferFunctions_getInstance();
|
|
3017
|
-
tmp = tmp_1 - (1.0993 - 1);
|
|
3018
|
-
}
|
|
3019
|
-
return tmp;
|
|
2936
|
+
protoOf(BT2020TransferFunctions).c1r = function (x) {
|
|
2937
|
+
return x < 0.0181 ? 4.5 * x : 1.0993 * spow(x, 0.45) - (1.0993 - 1);
|
|
3020
2938
|
};
|
|
3021
2939
|
var BT2020TransferFunctions_instance;
|
|
3022
2940
|
function BT2020TransferFunctions_getInstance() {
|
|
@@ -3026,12 +2944,12 @@
|
|
|
3026
2944
|
}
|
|
3027
2945
|
function BT709TransferFunctions() {
|
|
3028
2946
|
BT709TransferFunctions_instance = this;
|
|
3029
|
-
this.
|
|
2947
|
+
this.p1s_1 = 1.099 * spow_0(0.018, 0.45) - 0.099;
|
|
3030
2948
|
}
|
|
3031
|
-
protoOf(BT709TransferFunctions).
|
|
3032
|
-
return numberToDouble(x < this.
|
|
2949
|
+
protoOf(BT709TransferFunctions).b1r = function (x) {
|
|
2950
|
+
return numberToDouble(x < this.p1s_1 ? x / 4.5 : spow_0((x + 0.099) / 1.099, 1 / 0.45));
|
|
3033
2951
|
};
|
|
3034
|
-
protoOf(BT709TransferFunctions).
|
|
2952
|
+
protoOf(BT709TransferFunctions).c1r = function (x) {
|
|
3035
2953
|
return x < 0.018 ? 4.5 * x : 1.099 * spow(x, 0.45) - 0.099;
|
|
3036
2954
|
};
|
|
3037
2955
|
var BT709TransferFunctions_instance;
|
|
@@ -3041,27 +2959,13 @@
|
|
|
3041
2959
|
return BT709TransferFunctions_instance;
|
|
3042
2960
|
}
|
|
3043
2961
|
function ROMMTransferFunctions() {
|
|
3044
|
-
this.
|
|
2962
|
+
this.q1s_1 = 0.001953;
|
|
3045
2963
|
}
|
|
3046
|
-
protoOf(ROMMTransferFunctions).
|
|
3047
|
-
|
|
3048
|
-
var tmp_0 = x;
|
|
3049
|
-
if (tmp_0 < 16 * 0.001953) {
|
|
3050
|
-
tmp = x / 16.0;
|
|
3051
|
-
} else {
|
|
3052
|
-
tmp = spow(x, 1.8);
|
|
3053
|
-
}
|
|
3054
|
-
return tmp;
|
|
2964
|
+
protoOf(ROMMTransferFunctions).b1r = function (x) {
|
|
2965
|
+
return x < 16 * 0.001953 ? x / 16.0 : spow(x, 1.8);
|
|
3055
2966
|
};
|
|
3056
|
-
protoOf(ROMMTransferFunctions).
|
|
3057
|
-
|
|
3058
|
-
var tmp_0 = x;
|
|
3059
|
-
if (tmp_0 < 0.001953) {
|
|
3060
|
-
tmp = x * 16.0;
|
|
3061
|
-
} else {
|
|
3062
|
-
tmp = spow(x, 1.0 / 1.8);
|
|
3063
|
-
}
|
|
3064
|
-
return tmp;
|
|
2967
|
+
protoOf(ROMMTransferFunctions).c1r = function (x) {
|
|
2968
|
+
return x < 0.001953 ? x * 16.0 : spow(x, 1.0 / 1.8);
|
|
3065
2969
|
};
|
|
3066
2970
|
var ROMMTransferFunctions_instance;
|
|
3067
2971
|
function ROMMTransferFunctions_getInstance() {
|
|
@@ -3069,26 +2973,26 @@
|
|
|
3069
2973
|
}
|
|
3070
2974
|
function rgbToXyzMatrix(whitePoint, r, g, b) {
|
|
3071
2975
|
_init_properties_RGBColorSpaces_kt__nc9fsz();
|
|
3072
|
-
var primaries = _Matrix___init__impl__q3kp4w_0(r.
|
|
3073
|
-
var wp = whitePoint.
|
|
2976
|
+
var primaries = _Matrix___init__impl__q3kp4w_0(r.f1r_1, g.f1r_1, b.f1r_1, r.g1r_1, g.g1r_1, b.g1r_1, r.r1s(), g.r1s(), b.r1s());
|
|
2977
|
+
var wp = whitePoint.g1q_1;
|
|
3074
2978
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
3075
2979
|
var this_0 = inverse(primaries);
|
|
3076
|
-
var v0 = wp.
|
|
3077
|
-
var v1 = wp.
|
|
3078
|
-
var v2 = wp.
|
|
2980
|
+
var v0 = wp.i1r();
|
|
2981
|
+
var v1 = wp.h1r_1;
|
|
2982
|
+
var v2 = wp.j1r();
|
|
3079
2983
|
// Inline function 'com.github.ajalt.colormath.model.rgbToXyzMatrix.<anonymous>' call
|
|
3080
2984
|
var x = Matrix__get_impl_xogbpk(this_0, 0, 0) * v0 + Matrix__get_impl_xogbpk(this_0, 1, 0) * v1 + Matrix__get_impl_xogbpk(this_0, 2, 0) * v2;
|
|
3081
2985
|
var y = Matrix__get_impl_xogbpk(this_0, 0, 1) * v0 + Matrix__get_impl_xogbpk(this_0, 1, 1) * v1 + Matrix__get_impl_xogbpk(this_0, 2, 1) * v2;
|
|
3082
2986
|
var z = Matrix__get_impl_xogbpk(this_0, 0, 2) * v0 + Matrix__get_impl_xogbpk(this_0, 1, 2) * v1 + Matrix__get_impl_xogbpk(this_0, 2, 2) * v2;
|
|
3083
2987
|
return dotDiagonal(primaries, x, y, z);
|
|
3084
2988
|
}
|
|
3085
|
-
function RGBColorSpace$lambda($this
|
|
2989
|
+
function RGBColorSpace$lambda($this$RGBColorSpaceImpl, color) {
|
|
3086
2990
|
_init_properties_RGBColorSpaces_kt__nc9fsz();
|
|
3087
2991
|
var tmp;
|
|
3088
2992
|
if (color instanceof RGB) {
|
|
3089
|
-
tmp = color.
|
|
2993
|
+
tmp = color.s1r($this$RGBColorSpaceImpl);
|
|
3090
2994
|
} else {
|
|
3091
|
-
tmp = color.
|
|
2995
|
+
tmp = color.j1m().u1r($this$RGBColorSpaceImpl);
|
|
3092
2996
|
}
|
|
3093
2997
|
return tmp;
|
|
3094
2998
|
}
|
|
@@ -3116,24 +3020,24 @@
|
|
|
3116
3020
|
}
|
|
3117
3021
|
function Companion_7() {
|
|
3118
3022
|
Companion_instance_8 = this;
|
|
3119
|
-
this.
|
|
3023
|
+
this.s1s_1 = threeComponentInfo('R', 0.0, 255.0, 'G', 0.0, 255.0, 'B', 0.0, 255.0);
|
|
3120
3024
|
}
|
|
3121
3025
|
protoOf(Companion_7).q2 = function () {
|
|
3122
3026
|
return 'RGBInt';
|
|
3123
3027
|
};
|
|
3124
|
-
protoOf(Companion_7).
|
|
3125
|
-
return this.
|
|
3028
|
+
protoOf(Companion_7).j1n = function () {
|
|
3029
|
+
return this.s1s_1;
|
|
3126
3030
|
};
|
|
3127
|
-
protoOf(Companion_7).
|
|
3128
|
-
return color.
|
|
3031
|
+
protoOf(Companion_7).t1s = function (color) {
|
|
3032
|
+
return color.c1m().m1p();
|
|
3129
3033
|
};
|
|
3130
|
-
protoOf(Companion_7).
|
|
3131
|
-
return new RGBInt(this.
|
|
3034
|
+
protoOf(Companion_7).d1n = function (color) {
|
|
3035
|
+
return new RGBInt(this.t1s(color));
|
|
3132
3036
|
};
|
|
3133
|
-
protoOf(Companion_7).
|
|
3037
|
+
protoOf(Companion_7).u1s = function (components) {
|
|
3134
3038
|
// Inline function 'com.github.ajalt.colormath.internal.doCreate' call
|
|
3135
3039
|
// Inline function 'com.github.ajalt.colormath.internal.withValidComps' call
|
|
3136
|
-
var size = this.
|
|
3040
|
+
var size = this.j1n().m();
|
|
3137
3041
|
// Inline function 'kotlin.require' call
|
|
3138
3042
|
var containsLower = size - 1 | 0;
|
|
3139
3043
|
var containsArg = components.length;
|
|
@@ -3160,8 +3064,8 @@
|
|
|
3160
3064
|
var a = tmp;
|
|
3161
3065
|
return _RGBInt___init__impl__lqova7_0(numberToInt(r), numberToInt(g), numberToInt(b), numberToInt(a));
|
|
3162
3066
|
};
|
|
3163
|
-
protoOf(Companion_7).
|
|
3164
|
-
return new RGBInt(this.
|
|
3067
|
+
protoOf(Companion_7).k1n = function (components) {
|
|
3068
|
+
return new RGBInt(this.u1s(components));
|
|
3165
3069
|
};
|
|
3166
3070
|
var Companion_instance_8;
|
|
3167
3071
|
function Companion_getInstance_7() {
|
|
@@ -3293,7 +3197,7 @@
|
|
|
3293
3197
|
return (_UByte___get_data__impl__jof9qr(this_0) & 255) / 255.0;
|
|
3294
3198
|
}
|
|
3295
3199
|
function RGBInt__toSRGB_impl_m0acyy($this) {
|
|
3296
|
-
return Companion_getInstance_6().
|
|
3200
|
+
return Companion_getInstance_6().e1o(_RGBInt___get_redFloat__impl__lnt6cx($this), _RGBInt___get_greenFloat__impl__opq1mn($this), _RGBInt___get_blueFloat__impl__jt6mw2($this), _RGBInt___get_alpha__impl__yl2tay($this));
|
|
3297
3201
|
}
|
|
3298
3202
|
function RGBInt__toArray_impl_73rlu9($this) {
|
|
3299
3203
|
// Inline function 'kotlin.floatArrayOf' call
|
|
@@ -3332,65 +3236,65 @@
|
|
|
3332
3236
|
function RGBInt__equals_impl_qmmpmc($this, other) {
|
|
3333
3237
|
if (!(other instanceof RGBInt))
|
|
3334
3238
|
return false;
|
|
3335
|
-
if (!($this === (other instanceof RGBInt ? other.
|
|
3239
|
+
if (!($this === (other instanceof RGBInt ? other.t1r_1 : THROW_CCE())))
|
|
3336
3240
|
return false;
|
|
3337
3241
|
return true;
|
|
3338
3242
|
}
|
|
3339
3243
|
function RGBInt(argb) {
|
|
3340
3244
|
Companion_getInstance_7();
|
|
3341
|
-
this.
|
|
3245
|
+
this.t1r_1 = argb;
|
|
3342
3246
|
}
|
|
3343
|
-
protoOf(RGBInt).
|
|
3344
|
-
return _RGBInt___get_alpha__impl__yl2tay(this.
|
|
3247
|
+
protoOf(RGBInt).a1m = function () {
|
|
3248
|
+
return _RGBInt___get_alpha__impl__yl2tay(this.t1r_1);
|
|
3345
3249
|
};
|
|
3346
|
-
protoOf(RGBInt).
|
|
3347
|
-
return _RGBInt___get_space__impl__emgnsy(this.
|
|
3250
|
+
protoOf(RGBInt).b1m = function () {
|
|
3251
|
+
return _RGBInt___get_space__impl__emgnsy(this.t1r_1);
|
|
3348
3252
|
};
|
|
3349
|
-
protoOf(RGBInt).
|
|
3350
|
-
return RGBInt__toSRGB_impl_m0acyy(this.
|
|
3253
|
+
protoOf(RGBInt).c1m = function () {
|
|
3254
|
+
return RGBInt__toSRGB_impl_m0acyy(this.t1r_1);
|
|
3351
3255
|
};
|
|
3352
|
-
protoOf(RGBInt).
|
|
3353
|
-
return RGBInt__toArray_impl_73rlu9(this.
|
|
3256
|
+
protoOf(RGBInt).u5 = function () {
|
|
3257
|
+
return RGBInt__toArray_impl_73rlu9(this.t1r_1);
|
|
3354
3258
|
};
|
|
3355
3259
|
protoOf(RGBInt).toString = function () {
|
|
3356
|
-
return RGBInt__toString_impl_cf5r29(this.
|
|
3260
|
+
return RGBInt__toString_impl_cf5r29(this.t1r_1);
|
|
3357
3261
|
};
|
|
3358
3262
|
protoOf(RGBInt).hashCode = function () {
|
|
3359
|
-
return RGBInt__hashCode_impl_y6bnv4(this.
|
|
3263
|
+
return RGBInt__hashCode_impl_y6bnv4(this.t1r_1);
|
|
3360
3264
|
};
|
|
3361
3265
|
protoOf(RGBInt).equals = function (other) {
|
|
3362
|
-
return RGBInt__equals_impl_qmmpmc(this.
|
|
3266
|
+
return RGBInt__equals_impl_qmmpmc(this.t1r_1, other);
|
|
3363
3267
|
};
|
|
3364
3268
|
function Companion_8() {
|
|
3365
3269
|
Companion_instance_9 = this;
|
|
3366
|
-
this.
|
|
3270
|
+
this.o1r_1 = XYZColorSpaces_getInstance().b1p_1;
|
|
3367
3271
|
}
|
|
3368
|
-
protoOf(Companion_8).
|
|
3369
|
-
return this.
|
|
3272
|
+
protoOf(Companion_8).e1o = function (x, y, z, alpha) {
|
|
3273
|
+
return this.o1r_1.e1o(x, y, z, alpha);
|
|
3370
3274
|
};
|
|
3371
|
-
protoOf(Companion_8).
|
|
3372
|
-
return this.
|
|
3275
|
+
protoOf(Companion_8).d1r = function (x, y, z, alpha) {
|
|
3276
|
+
return this.o1r_1.d1r(x, y, z, alpha);
|
|
3373
3277
|
};
|
|
3374
|
-
protoOf(Companion_8).
|
|
3375
|
-
return this.
|
|
3278
|
+
protoOf(Companion_8).d1n = function (color) {
|
|
3279
|
+
return this.o1r_1.d1n(color);
|
|
3376
3280
|
};
|
|
3377
|
-
protoOf(Companion_8).
|
|
3378
|
-
return this.
|
|
3281
|
+
protoOf(Companion_8).k1n = function (components) {
|
|
3282
|
+
return this.o1r_1.k1n(components);
|
|
3379
3283
|
};
|
|
3380
|
-
protoOf(Companion_8).
|
|
3381
|
-
return this.
|
|
3284
|
+
protoOf(Companion_8).i1n = function () {
|
|
3285
|
+
return this.o1r_1.i1n();
|
|
3382
3286
|
};
|
|
3383
|
-
protoOf(Companion_8).
|
|
3384
|
-
return this.
|
|
3287
|
+
protoOf(Companion_8).q2 = function () {
|
|
3288
|
+
return this.o1r_1.q2();
|
|
3385
3289
|
};
|
|
3386
|
-
protoOf(Companion_8).
|
|
3387
|
-
return this.
|
|
3290
|
+
protoOf(Companion_8).j1n = function () {
|
|
3291
|
+
return this.o1r_1.j1n();
|
|
3388
3292
|
};
|
|
3389
3293
|
protoOf(Companion_8).hashCode = function () {
|
|
3390
|
-
return hashCode(XYZColorSpaces_getInstance().
|
|
3294
|
+
return hashCode(XYZColorSpaces_getInstance().b1p_1);
|
|
3391
3295
|
};
|
|
3392
3296
|
protoOf(Companion_8).equals = function (other) {
|
|
3393
|
-
return equals(XYZColorSpaces_getInstance().
|
|
3297
|
+
return equals(XYZColorSpaces_getInstance().b1p_1, other);
|
|
3394
3298
|
};
|
|
3395
3299
|
var Companion_instance_9;
|
|
3396
3300
|
function Companion_getInstance_8() {
|
|
@@ -3399,125 +3303,125 @@
|
|
|
3399
3303
|
return Companion_instance_9;
|
|
3400
3304
|
}
|
|
3401
3305
|
function adaptToM($this, space, m, mi) {
|
|
3402
|
-
if (space.
|
|
3306
|
+
if (space.i1n().equals($this.p1m_1.i1n()))
|
|
3403
3307
|
return $this;
|
|
3404
|
-
var transform = chromaticAdaptationMatrix(space, $this.
|
|
3308
|
+
var transform = chromaticAdaptationMatrix(space, $this.p1m_1.i1n().g1q_1, m, mi);
|
|
3405
3309
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
3406
|
-
var v0 = $this.
|
|
3407
|
-
var v1 = $this.
|
|
3408
|
-
var v2 = $this.
|
|
3310
|
+
var v0 = $this.l1m_1;
|
|
3311
|
+
var v1 = $this.m1m_1;
|
|
3312
|
+
var v2 = $this.n1m_1;
|
|
3409
3313
|
// Inline function 'com.github.ajalt.colormath.model.XYZ.adaptToM.<anonymous>' call
|
|
3410
3314
|
var xx = Matrix__get_impl_xogbpk(transform, 0, 0) * v0 + Matrix__get_impl_xogbpk(transform, 1, 0) * v1 + Matrix__get_impl_xogbpk(transform, 2, 0) * v2;
|
|
3411
3315
|
var yy = Matrix__get_impl_xogbpk(transform, 0, 1) * v0 + Matrix__get_impl_xogbpk(transform, 1, 1) * v1 + Matrix__get_impl_xogbpk(transform, 2, 1) * v2;
|
|
3412
3316
|
var zz = Matrix__get_impl_xogbpk(transform, 0, 2) * v0 + Matrix__get_impl_xogbpk(transform, 1, 2) * v1 + Matrix__get_impl_xogbpk(transform, 2, 2) * v2;
|
|
3413
|
-
return space.
|
|
3317
|
+
return space.e1o(xx, yy, zz, $this.o1m_1);
|
|
3414
3318
|
}
|
|
3415
3319
|
function toLAB$f(t) {
|
|
3416
3320
|
var tmp;
|
|
3417
|
-
if (t >
|
|
3321
|
+
if (t > 0.008856451679035631) {
|
|
3418
3322
|
// Inline function 'kotlin.math.cbrt' call
|
|
3419
3323
|
tmp = Math.cbrt(t);
|
|
3420
3324
|
} else {
|
|
3421
|
-
tmp = (t *
|
|
3325
|
+
tmp = (t * 903.2962962962963 + 16) / 116;
|
|
3422
3326
|
}
|
|
3423
3327
|
return tmp;
|
|
3424
3328
|
}
|
|
3425
3329
|
function XYZ(x, y, z, alpha, space) {
|
|
3426
3330
|
Companion_getInstance_8();
|
|
3427
|
-
this.
|
|
3428
|
-
this.
|
|
3429
|
-
this.
|
|
3430
|
-
this.
|
|
3431
|
-
this.
|
|
3331
|
+
this.l1m_1 = x;
|
|
3332
|
+
this.m1m_1 = y;
|
|
3333
|
+
this.n1m_1 = z;
|
|
3334
|
+
this.o1m_1 = alpha;
|
|
3335
|
+
this.p1m_1 = space;
|
|
3432
3336
|
}
|
|
3433
|
-
protoOf(XYZ).
|
|
3434
|
-
return this.
|
|
3337
|
+
protoOf(XYZ).a1m = function () {
|
|
3338
|
+
return this.o1m_1;
|
|
3435
3339
|
};
|
|
3436
|
-
protoOf(XYZ).
|
|
3437
|
-
return this.
|
|
3340
|
+
protoOf(XYZ).b1m = function () {
|
|
3341
|
+
return this.p1m_1;
|
|
3438
3342
|
};
|
|
3439
|
-
protoOf(XYZ).
|
|
3343
|
+
protoOf(XYZ).d1p = function (space) {
|
|
3440
3344
|
return adaptToM(this, space, get_CAT02_XYZ_TO_LMS(), get_CAT02_LMS_TO_XYZ());
|
|
3441
3345
|
};
|
|
3442
|
-
protoOf(XYZ).
|
|
3443
|
-
var
|
|
3444
|
-
var x =
|
|
3445
|
-
var y =
|
|
3446
|
-
var z =
|
|
3447
|
-
var f = space.
|
|
3346
|
+
protoOf(XYZ).u1r = function (space) {
|
|
3347
|
+
var _destruct__k2r9zo = this.d1p(XYZColorSpace_0(space.i1n()));
|
|
3348
|
+
var x = _destruct__k2r9zo.lf();
|
|
3349
|
+
var y = _destruct__k2r9zo.mf();
|
|
3350
|
+
var z = _destruct__k2r9zo.v1s();
|
|
3351
|
+
var f = space.s1q();
|
|
3448
3352
|
// Inline function 'com.github.ajalt.colormath.internal.dot' call
|
|
3449
|
-
var this_0 = _Matrix___init__impl__q3kp4w(space.
|
|
3353
|
+
var this_0 = _Matrix___init__impl__q3kp4w(space.r1r());
|
|
3450
3354
|
// Inline function 'com.github.ajalt.colormath.model.XYZ.toRGB.<anonymous>' call
|
|
3451
3355
|
var r = 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;
|
|
3452
3356
|
var g = 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;
|
|
3453
3357
|
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;
|
|
3454
|
-
return space.
|
|
3358
|
+
return space.e1o(f.c1r(r), f.c1r(g), f.c1r(b), this.o1m_1);
|
|
3455
3359
|
};
|
|
3456
|
-
protoOf(XYZ).
|
|
3457
|
-
return this.
|
|
3360
|
+
protoOf(XYZ).c1m = function () {
|
|
3361
|
+
return this.u1r(RGBColorSpaces_getInstance().p1o_1);
|
|
3458
3362
|
};
|
|
3459
|
-
protoOf(XYZ).
|
|
3460
|
-
var fx = toLAB$f(this.
|
|
3461
|
-
var fy = toLAB$f(this.
|
|
3462
|
-
var fz = toLAB$f(this.
|
|
3363
|
+
protoOf(XYZ).k1m = function () {
|
|
3364
|
+
var fx = toLAB$f(this.l1m_1 / this.p1m_1.i1n().g1q_1.i1r());
|
|
3365
|
+
var fy = toLAB$f(this.m1m_1 / this.p1m_1.i1n().g1q_1.h1r_1);
|
|
3366
|
+
var fz = toLAB$f(this.n1m_1 / this.p1m_1.i1n().g1q_1.j1r());
|
|
3463
3367
|
var l = 116 * fy - 16;
|
|
3464
3368
|
var a = 500 * (fx - fy);
|
|
3465
3369
|
var b = 200 * (fy - fz);
|
|
3466
|
-
return LABColorSpace_0(this.
|
|
3370
|
+
return LABColorSpace_0(this.p1m_1.i1n()).d1r(l, a, b, this.o1m_1);
|
|
3467
3371
|
};
|
|
3468
|
-
protoOf(XYZ).
|
|
3372
|
+
protoOf(XYZ).x1m = function () {
|
|
3469
3373
|
// Inline function 'com.github.ajalt.colormath.model.XYZ.toD65' call
|
|
3470
3374
|
var tmp;
|
|
3471
|
-
if (equals(this.
|
|
3472
|
-
var l = 0.8189330101 * this.
|
|
3473
|
-
var m = 0.0329845436 * this.
|
|
3474
|
-
var s = 0.0482003018 * this.
|
|
3375
|
+
if (equals(this.p1m_1, XYZColorSpaces_getInstance().b1p_1)) {
|
|
3376
|
+
var l = +0.8189330101 * this.l1m_1 + 0.3618667424 * this.m1m_1 - 0.1288597137 * this.n1m_1;
|
|
3377
|
+
var m = +0.0329845436 * this.l1m_1 + 0.9293118715 * this.m1m_1 + 0.0361456387 * this.n1m_1;
|
|
3378
|
+
var s = +0.0482003018 * this.l1m_1 + 0.2643662691 * this.m1m_1 + 0.633851707 * this.n1m_1;
|
|
3475
3379
|
// Inline function 'kotlin.math.cbrt' call
|
|
3476
3380
|
var ll = Math.cbrt(l);
|
|
3477
3381
|
// Inline function 'kotlin.math.cbrt' call
|
|
3478
3382
|
var mm = Math.cbrt(m);
|
|
3479
3383
|
// Inline function 'kotlin.math.cbrt' call
|
|
3480
3384
|
var ss = Math.cbrt(s);
|
|
3481
|
-
return Oklab_init_$Create$(0.2104542553 * ll + 0.793617785 * mm - 0.0040720468 * ss, 1.9779984951 * ll - 2.428592205 * mm + 0.4505937099 * ss, 0.0259040371 * ll + 0.7827717662 * mm - 0.808675766 * ss, this.
|
|
3385
|
+
return Oklab_init_$Create$(+0.2104542553 * ll + 0.793617785 * mm - 0.0040720468 * ss, +1.9779984951 * ll - 2.428592205 * mm + 0.4505937099 * ss, +0.0259040371 * ll + 0.7827717662 * mm - 0.808675766 * ss, this.o1m_1);
|
|
3482
3386
|
} else {
|
|
3483
|
-
var $this$toD65 = this.
|
|
3484
|
-
var l_0 = 0.8189330101 * $this$toD65.
|
|
3485
|
-
var m_0 = 0.0329845436 * $this$toD65.
|
|
3486
|
-
var s_0 = 0.0482003018 * $this$toD65.
|
|
3387
|
+
var $this$toD65 = this.d1p(XYZColorSpaces_getInstance().b1p_1);
|
|
3388
|
+
var l_0 = +0.8189330101 * $this$toD65.l1m_1 + 0.3618667424 * $this$toD65.m1m_1 - 0.1288597137 * $this$toD65.n1m_1;
|
|
3389
|
+
var m_0 = +0.0329845436 * $this$toD65.l1m_1 + 0.9293118715 * $this$toD65.m1m_1 + 0.0361456387 * $this$toD65.n1m_1;
|
|
3390
|
+
var s_0 = +0.0482003018 * $this$toD65.l1m_1 + 0.2643662691 * $this$toD65.m1m_1 + 0.633851707 * $this$toD65.n1m_1;
|
|
3487
3391
|
// Inline function 'kotlin.math.cbrt' call
|
|
3488
3392
|
var ll_0 = Math.cbrt(l_0);
|
|
3489
3393
|
// Inline function 'kotlin.math.cbrt' call
|
|
3490
3394
|
var mm_0 = Math.cbrt(m_0);
|
|
3491
3395
|
// Inline function 'kotlin.math.cbrt' call
|
|
3492
3396
|
var ss_0 = Math.cbrt(s_0);
|
|
3493
|
-
return Oklab_init_$Create$(0.2104542553 * ll_0 + 0.793617785 * mm_0 - 0.0040720468 * ss_0, 1.9779984951 * ll_0 - 2.428592205 * mm_0 + 0.4505937099 * ss_0, 0.0259040371 * ll_0 + 0.7827717662 * mm_0 - 0.808675766 * ss_0, $this$toD65.
|
|
3397
|
+
return Oklab_init_$Create$(+0.2104542553 * ll_0 + 0.793617785 * mm_0 - 0.0040720468 * ss_0, +1.9779984951 * ll_0 - 2.428592205 * mm_0 + 0.4505937099 * ss_0, +0.0259040371 * ll_0 + 0.7827717662 * mm_0 - 0.808675766 * ss_0, $this$toD65.o1m_1);
|
|
3494
3398
|
}
|
|
3495
3399
|
};
|
|
3496
|
-
protoOf(XYZ).
|
|
3400
|
+
protoOf(XYZ).j1m = function () {
|
|
3497
3401
|
return this;
|
|
3498
3402
|
};
|
|
3499
|
-
protoOf(XYZ).
|
|
3403
|
+
protoOf(XYZ).u5 = function () {
|
|
3500
3404
|
// Inline function 'kotlin.floatArrayOf' call
|
|
3501
|
-
return new Float32Array([this.
|
|
3405
|
+
return new Float32Array([this.l1m_1, this.m1m_1, this.n1m_1, this.o1m_1]);
|
|
3502
3406
|
};
|
|
3503
|
-
protoOf(XYZ).
|
|
3504
|
-
return this.
|
|
3407
|
+
protoOf(XYZ).lf = function () {
|
|
3408
|
+
return this.l1m_1;
|
|
3505
3409
|
};
|
|
3506
|
-
protoOf(XYZ).
|
|
3507
|
-
return this.
|
|
3410
|
+
protoOf(XYZ).mf = function () {
|
|
3411
|
+
return this.m1m_1;
|
|
3508
3412
|
};
|
|
3509
|
-
protoOf(XYZ).
|
|
3510
|
-
return this.
|
|
3413
|
+
protoOf(XYZ).v1s = function () {
|
|
3414
|
+
return this.n1m_1;
|
|
3511
3415
|
};
|
|
3512
3416
|
protoOf(XYZ).toString = function () {
|
|
3513
|
-
return 'XYZ(x=' + this.
|
|
3417
|
+
return 'XYZ(x=' + this.l1m_1 + ', y=' + this.m1m_1 + ', z=' + this.n1m_1 + ', alpha=' + this.o1m_1 + ', space=' + toString(this.p1m_1) + ')';
|
|
3514
3418
|
};
|
|
3515
3419
|
protoOf(XYZ).hashCode = function () {
|
|
3516
|
-
var result = getNumberHashCode(this.
|
|
3517
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
3518
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
3519
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
3520
|
-
result = imul(result, 31) + hashCode(this.
|
|
3420
|
+
var result = getNumberHashCode(this.l1m_1);
|
|
3421
|
+
result = imul(result, 31) + getNumberHashCode(this.m1m_1) | 0;
|
|
3422
|
+
result = imul(result, 31) + getNumberHashCode(this.n1m_1) | 0;
|
|
3423
|
+
result = imul(result, 31) + getNumberHashCode(this.o1m_1) | 0;
|
|
3424
|
+
result = imul(result, 31) + hashCode(this.p1m_1) | 0;
|
|
3521
3425
|
return result;
|
|
3522
3426
|
};
|
|
3523
3427
|
protoOf(XYZ).equals = function (other) {
|
|
@@ -3526,27 +3430,27 @@
|
|
|
3526
3430
|
if (!(other instanceof XYZ))
|
|
3527
3431
|
return false;
|
|
3528
3432
|
var tmp0_other_with_cast = other instanceof XYZ ? other : THROW_CCE();
|
|
3529
|
-
if (!equals(this.
|
|
3433
|
+
if (!equals(this.l1m_1, tmp0_other_with_cast.l1m_1))
|
|
3530
3434
|
return false;
|
|
3531
|
-
if (!equals(this.
|
|
3435
|
+
if (!equals(this.m1m_1, tmp0_other_with_cast.m1m_1))
|
|
3532
3436
|
return false;
|
|
3533
|
-
if (!equals(this.
|
|
3437
|
+
if (!equals(this.n1m_1, tmp0_other_with_cast.n1m_1))
|
|
3534
3438
|
return false;
|
|
3535
|
-
if (!equals(this.
|
|
3439
|
+
if (!equals(this.o1m_1, tmp0_other_with_cast.o1m_1))
|
|
3536
3440
|
return false;
|
|
3537
|
-
if (!equals(this.
|
|
3441
|
+
if (!equals(this.p1m_1, tmp0_other_with_cast.p1m_1))
|
|
3538
3442
|
return false;
|
|
3539
3443
|
return true;
|
|
3540
3444
|
};
|
|
3541
3445
|
function XYZColorSpace() {
|
|
3542
3446
|
}
|
|
3543
3447
|
function XYZColorSpace_0(whitePoint) {
|
|
3544
|
-
return whitePoint.equals(Illuminant_getInstance().
|
|
3448
|
+
return whitePoint.equals(Illuminant_getInstance().j1p_1) ? XYZColorSpaces_getInstance().b1p_1 : whitePoint.equals(Illuminant_getInstance().h1p_1) ? XYZColorSpaces_getInstance().c1p_1 : new XYZColorSpaceImpl(whitePoint);
|
|
3545
3449
|
}
|
|
3546
3450
|
function XYZColorSpaces() {
|
|
3547
3451
|
XYZColorSpaces_instance = this;
|
|
3548
|
-
this.
|
|
3549
|
-
this.
|
|
3452
|
+
this.b1p_1 = new XYZColorSpaceImpl(Illuminant_getInstance().j1p_1);
|
|
3453
|
+
this.c1p_1 = new XYZColorSpaceImpl(Illuminant_getInstance().h1p_1);
|
|
3550
3454
|
}
|
|
3551
3455
|
var XYZColorSpaces_instance;
|
|
3552
3456
|
function XYZColorSpaces_getInstance() {
|
|
@@ -3557,31 +3461,31 @@
|
|
|
3557
3461
|
function chromaticAdaptationMatrix(_this__u8e3s4, srcWp, xyzToLms, lmsToXyz) {
|
|
3558
3462
|
xyzToLms = xyzToLms === VOID ? get_CAT02_XYZ_TO_LMS() : xyzToLms;
|
|
3559
3463
|
lmsToXyz = lmsToXyz === VOID ? get_CAT02_LMS_TO_XYZ() : lmsToXyz;
|
|
3560
|
-
var dstWp = _this__u8e3s4.
|
|
3561
|
-
var src = dot_0(xyzToLms, srcWp.
|
|
3562
|
-
var dst = dot_0(xyzToLms, dstWp.
|
|
3464
|
+
var dstWp = _this__u8e3s4.i1n().g1q_1;
|
|
3465
|
+
var src = dot_0(xyzToLms, srcWp.i1r(), srcWp.h1r_1, srcWp.j1r());
|
|
3466
|
+
var dst = dot_0(xyzToLms, dstWp.i1r(), dstWp.h1r_1, dstWp.j1r());
|
|
3563
3467
|
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);
|
|
3564
3468
|
}
|
|
3565
3469
|
function XYZColorSpaceImpl(whitePoint) {
|
|
3566
|
-
this.
|
|
3567
|
-
this.
|
|
3470
|
+
this.w1s_1 = whitePoint;
|
|
3471
|
+
this.x1s_1 = zeroOneComponentInfo('XYZ');
|
|
3568
3472
|
}
|
|
3569
|
-
protoOf(XYZColorSpaceImpl).
|
|
3570
|
-
return this.
|
|
3473
|
+
protoOf(XYZColorSpaceImpl).i1n = function () {
|
|
3474
|
+
return this.w1s_1;
|
|
3571
3475
|
};
|
|
3572
3476
|
protoOf(XYZColorSpaceImpl).q2 = function () {
|
|
3573
3477
|
return 'XYZ';
|
|
3574
3478
|
};
|
|
3575
|
-
protoOf(XYZColorSpaceImpl).
|
|
3576
|
-
return this.
|
|
3479
|
+
protoOf(XYZColorSpaceImpl).j1n = function () {
|
|
3480
|
+
return this.x1s_1;
|
|
3577
3481
|
};
|
|
3578
|
-
protoOf(XYZColorSpaceImpl).
|
|
3579
|
-
return color.
|
|
3482
|
+
protoOf(XYZColorSpaceImpl).d1n = function (color) {
|
|
3483
|
+
return color.j1m().d1p(this);
|
|
3580
3484
|
};
|
|
3581
|
-
protoOf(XYZColorSpaceImpl).
|
|
3485
|
+
protoOf(XYZColorSpaceImpl).k1n = function (components) {
|
|
3582
3486
|
// Inline function 'com.github.ajalt.colormath.internal.doCreate' call
|
|
3583
3487
|
// Inline function 'com.github.ajalt.colormath.internal.withValidComps' call
|
|
3584
|
-
var size = this.
|
|
3488
|
+
var size = this.j1n().m();
|
|
3585
3489
|
// Inline function 'kotlin.require' call
|
|
3586
3490
|
var containsLower = size - 1 | 0;
|
|
3587
3491
|
var containsArg = components.length;
|
|
@@ -3605,21 +3509,21 @@
|
|
|
3605
3509
|
tmp = 1.0;
|
|
3606
3510
|
}
|
|
3607
3511
|
var p3 = tmp;
|
|
3608
|
-
return this.
|
|
3512
|
+
return this.e1o(p0, p1, p2, p3);
|
|
3609
3513
|
};
|
|
3610
3514
|
protoOf(XYZColorSpaceImpl).toString = function () {
|
|
3611
|
-
return 'XYZColorSpace(' + this.
|
|
3515
|
+
return 'XYZColorSpace(' + this.w1s_1.toString() + ')';
|
|
3612
3516
|
};
|
|
3613
|
-
protoOf(XYZColorSpaceImpl).
|
|
3517
|
+
protoOf(XYZColorSpaceImpl).e1o = function (x, y, z, alpha) {
|
|
3614
3518
|
return new XYZ(x, y, z, alpha, this);
|
|
3615
3519
|
};
|
|
3616
3520
|
protoOf(XYZColorSpaceImpl).hashCode = function () {
|
|
3617
|
-
return this.
|
|
3521
|
+
return this.w1s_1.hashCode();
|
|
3618
3522
|
};
|
|
3619
3523
|
protoOf(XYZColorSpaceImpl).equals = function (other) {
|
|
3620
3524
|
var tmp;
|
|
3621
3525
|
if (!(other == null) ? isInterface(other, XYZColorSpace) : false) {
|
|
3622
|
-
tmp = this.
|
|
3526
|
+
tmp = this.w1s_1.equals(other.i1n());
|
|
3623
3527
|
} else {
|
|
3624
3528
|
tmp = false;
|
|
3625
3529
|
}
|
|
@@ -3635,26 +3539,26 @@
|
|
|
3635
3539
|
}
|
|
3636
3540
|
function xyY(x, y, Y) {
|
|
3637
3541
|
Y = Y === VOID ? 1.0 : Y;
|
|
3638
|
-
this.
|
|
3639
|
-
this.
|
|
3640
|
-
this.
|
|
3542
|
+
this.f1r_1 = x;
|
|
3543
|
+
this.g1r_1 = y;
|
|
3544
|
+
this.h1r_1 = Y;
|
|
3641
3545
|
}
|
|
3642
|
-
protoOf(xyY).
|
|
3643
|
-
return 1 - this.
|
|
3546
|
+
protoOf(xyY).r1s = function () {
|
|
3547
|
+
return 1 - this.f1r_1 - this.g1r_1;
|
|
3644
3548
|
};
|
|
3645
|
-
protoOf(xyY).
|
|
3646
|
-
return this.
|
|
3549
|
+
protoOf(xyY).i1r = function () {
|
|
3550
|
+
return this.f1r_1 * this.h1r_1 / this.g1r_1;
|
|
3647
3551
|
};
|
|
3648
|
-
protoOf(xyY).
|
|
3649
|
-
return (1 - this.
|
|
3552
|
+
protoOf(xyY).j1r = function () {
|
|
3553
|
+
return (1 - this.f1r_1 - this.g1r_1) * this.h1r_1 / this.g1r_1;
|
|
3650
3554
|
};
|
|
3651
3555
|
protoOf(xyY).toString = function () {
|
|
3652
|
-
return 'xyY(x=' + this.
|
|
3556
|
+
return 'xyY(x=' + this.f1r_1 + ', y=' + this.g1r_1 + ', Y=' + this.h1r_1 + ')';
|
|
3653
3557
|
};
|
|
3654
3558
|
protoOf(xyY).hashCode = function () {
|
|
3655
|
-
var result = getNumberHashCode(this.
|
|
3656
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
3657
|
-
result = imul(result, 31) + getNumberHashCode(this.
|
|
3559
|
+
var result = getNumberHashCode(this.f1r_1);
|
|
3560
|
+
result = imul(result, 31) + getNumberHashCode(this.g1r_1) | 0;
|
|
3561
|
+
result = imul(result, 31) + getNumberHashCode(this.h1r_1) | 0;
|
|
3658
3562
|
return result;
|
|
3659
3563
|
};
|
|
3660
3564
|
protoOf(xyY).equals = function (other) {
|
|
@@ -3663,73 +3567,70 @@
|
|
|
3663
3567
|
if (!(other instanceof xyY))
|
|
3664
3568
|
return false;
|
|
3665
3569
|
var tmp0_other_with_cast = other instanceof xyY ? other : THROW_CCE();
|
|
3666
|
-
if (!equals(this.
|
|
3570
|
+
if (!equals(this.f1r_1, tmp0_other_with_cast.f1r_1))
|
|
3667
3571
|
return false;
|
|
3668
|
-
if (!equals(this.
|
|
3572
|
+
if (!equals(this.g1r_1, tmp0_other_with_cast.g1r_1))
|
|
3669
3573
|
return false;
|
|
3670
|
-
if (!equals(this.
|
|
3574
|
+
if (!equals(this.h1r_1, tmp0_other_with_cast.h1r_1))
|
|
3671
3575
|
return false;
|
|
3672
3576
|
return true;
|
|
3673
3577
|
};
|
|
3674
3578
|
//region block: post-declaration
|
|
3675
|
-
protoOf(HSL).
|
|
3676
|
-
protoOf(HSL).
|
|
3677
|
-
protoOf(HSL).
|
|
3678
|
-
protoOf(HSL).
|
|
3679
|
-
protoOf(HSL).
|
|
3680
|
-
protoOf(HSL).
|
|
3681
|
-
protoOf(HWB).
|
|
3682
|
-
protoOf(HWB).
|
|
3683
|
-
protoOf(HWB).
|
|
3684
|
-
protoOf(HWB).
|
|
3685
|
-
protoOf(HWB).
|
|
3686
|
-
protoOf(HWB).
|
|
3687
|
-
protoOf(LAB).
|
|
3688
|
-
protoOf(LAB).
|
|
3689
|
-
protoOf(LAB).
|
|
3690
|
-
protoOf(LAB).
|
|
3691
|
-
protoOf(LABColorSpaceImpl).
|
|
3692
|
-
protoOf(LCHab).
|
|
3693
|
-
protoOf(LCHab).
|
|
3694
|
-
protoOf(LCHab).
|
|
3695
|
-
protoOf(LCHab).
|
|
3696
|
-
protoOf(Oklab).
|
|
3697
|
-
protoOf(Oklab).
|
|
3698
|
-
protoOf(Oklab).
|
|
3699
|
-
protoOf(Oklab).
|
|
3700
|
-
protoOf(Oklch).
|
|
3701
|
-
protoOf(Oklch).
|
|
3702
|
-
protoOf(Oklch).
|
|
3703
|
-
protoOf(Oklch).
|
|
3704
|
-
protoOf(Companion_6).
|
|
3705
|
-
protoOf(RGB).
|
|
3706
|
-
protoOf(RGB).
|
|
3707
|
-
protoOf(RGB).
|
|
3708
|
-
protoOf(SRGB).
|
|
3709
|
-
protoOf(RGBColorSpaceImpl).
|
|
3710
|
-
protoOf(RGBColorSpaceImpl).
|
|
3711
|
-
protoOf(RGBColorSpaceImpl).
|
|
3712
|
-
protoOf(RGBColorSpaceImpl).
|
|
3713
|
-
protoOf(RGBInt).
|
|
3714
|
-
protoOf(RGBInt).
|
|
3715
|
-
protoOf(RGBInt).
|
|
3716
|
-
protoOf(RGBInt).
|
|
3717
|
-
protoOf(RGBInt).
|
|
3718
|
-
protoOf(RGBInt).
|
|
3719
|
-
protoOf(RGBInt).
|
|
3720
|
-
protoOf(Companion_8).
|
|
3721
|
-
protoOf(XYZ).
|
|
3722
|
-
protoOf(XYZ).
|
|
3723
|
-
protoOf(XYZ).
|
|
3724
|
-
protoOf(XYZ).
|
|
3725
|
-
protoOf(XYZColorSpaceImpl).
|
|
3726
|
-
protoOf(XYZColorSpaceImpl).
|
|
3579
|
+
protoOf(HSL).j1m = toXYZ;
|
|
3580
|
+
protoOf(HSL).k1m = toLAB;
|
|
3581
|
+
protoOf(HSL).q1m = toLCHab;
|
|
3582
|
+
protoOf(HSL).w1m = toHWB;
|
|
3583
|
+
protoOf(HSL).x1m = toOklab;
|
|
3584
|
+
protoOf(HSL).y1m = toOklch;
|
|
3585
|
+
protoOf(HWB).d1m = toHSL;
|
|
3586
|
+
protoOf(HWB).j1m = toXYZ;
|
|
3587
|
+
protoOf(HWB).k1m = toLAB;
|
|
3588
|
+
protoOf(HWB).q1m = toLCHab;
|
|
3589
|
+
protoOf(HWB).x1m = toOklab;
|
|
3590
|
+
protoOf(HWB).y1m = toOklch;
|
|
3591
|
+
protoOf(LAB).d1m = toHSL;
|
|
3592
|
+
protoOf(LAB).w1m = toHWB;
|
|
3593
|
+
protoOf(LAB).x1m = toOklab;
|
|
3594
|
+
protoOf(LAB).y1m = toOklch;
|
|
3595
|
+
protoOf(LABColorSpaceImpl).d1r = invoke;
|
|
3596
|
+
protoOf(LCHab).d1m = toHSL;
|
|
3597
|
+
protoOf(LCHab).w1m = toHWB;
|
|
3598
|
+
protoOf(LCHab).x1m = toOklab;
|
|
3599
|
+
protoOf(LCHab).y1m = toOklch;
|
|
3600
|
+
protoOf(Oklab).d1m = toHSL;
|
|
3601
|
+
protoOf(Oklab).k1m = toLAB;
|
|
3602
|
+
protoOf(Oklab).q1m = toLCHab;
|
|
3603
|
+
protoOf(Oklab).w1m = toHWB;
|
|
3604
|
+
protoOf(Oklch).d1m = toHSL;
|
|
3605
|
+
protoOf(Oklch).k1m = toLAB;
|
|
3606
|
+
protoOf(Oklch).q1m = toLCHab;
|
|
3607
|
+
protoOf(Oklch).w1m = toHWB;
|
|
3608
|
+
protoOf(Companion_6).h1q = from255$default;
|
|
3609
|
+
protoOf(RGB).k1m = toLAB;
|
|
3610
|
+
protoOf(RGB).q1m = toLCHab;
|
|
3611
|
+
protoOf(RGB).y1m = toOklch;
|
|
3612
|
+
protoOf(SRGB).h1q = from255$default;
|
|
3613
|
+
protoOf(RGBColorSpaceImpl).d1r = invoke_0;
|
|
3614
|
+
protoOf(RGBColorSpaceImpl).d1o = invoke_1;
|
|
3615
|
+
protoOf(RGBColorSpaceImpl).i1q = from255;
|
|
3616
|
+
protoOf(RGBColorSpaceImpl).h1q = from255$default;
|
|
3617
|
+
protoOf(RGBInt).d1m = toHSL;
|
|
3618
|
+
protoOf(RGBInt).j1m = toXYZ;
|
|
3619
|
+
protoOf(RGBInt).k1m = toLAB;
|
|
3620
|
+
protoOf(RGBInt).q1m = toLCHab;
|
|
3621
|
+
protoOf(RGBInt).w1m = toHWB;
|
|
3622
|
+
protoOf(RGBInt).x1m = toOklab;
|
|
3623
|
+
protoOf(RGBInt).y1m = toOklch;
|
|
3624
|
+
protoOf(Companion_8).e1r = invoke$default;
|
|
3625
|
+
protoOf(XYZ).d1m = toHSL;
|
|
3626
|
+
protoOf(XYZ).q1m = toLCHab;
|
|
3627
|
+
protoOf(XYZ).w1m = toHWB;
|
|
3628
|
+
protoOf(XYZ).y1m = toOklch;
|
|
3629
|
+
protoOf(XYZColorSpaceImpl).d1r = invoke_2;
|
|
3630
|
+
protoOf(XYZColorSpaceImpl).e1r = invoke$default;
|
|
3727
3631
|
//endregion
|
|
3728
3632
|
//region block: init
|
|
3729
3633
|
Companion_instance_0 = new Companion();
|
|
3730
|
-
CIE_E = 0.008856451679035631;
|
|
3731
|
-
CIE_K = 903.2962962962963;
|
|
3732
|
-
CIE_E_times_K = 8.0;
|
|
3733
3634
|
PqNonlinearity_instance = new PqNonlinearity();
|
|
3734
3635
|
LinearTransferFunctions_instance = new LinearTransferFunctions();
|
|
3735
3636
|
SRGBTransferFunctions_instance = new SRGBTransferFunctions();
|