@rive-app/canvas-advanced-lite 2.29.0 → 2.29.2
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/canvas_advanced.mjs +205 -204
- package/package.json +1 -1
- package/rive.wasm +0 -0
- package/rive_advanced.mjs.d.ts +1 -0
- package/rive_fallback.wasm +0 -0
package/canvas_advanced.mjs
CHANGED
|
@@ -155,26 +155,26 @@ const fa = "createConicGradient createImageData createLinearGradient createPatte
|
|
|
155
155
|
}
|
|
156
156
|
}
|
|
157
157
|
}
|
|
158
|
-
q = new Proxy(q, {get(
|
|
159
|
-
if (
|
|
160
|
-
if (n || (console.error("Cannot render the mesh because the GL Context was lost. Tried to invoke ", v), n = !0), "function" === typeof
|
|
158
|
+
q = new Proxy(q, {get(E, v) {
|
|
159
|
+
if (E.isContextLost()) {
|
|
160
|
+
if (n || (console.error("Cannot render the mesh because the GL Context was lost. Tried to invoke ", v), n = !0), "function" === typeof E[v]) {
|
|
161
161
|
return function() {
|
|
162
162
|
};
|
|
163
163
|
}
|
|
164
164
|
} else {
|
|
165
|
-
return "function" === typeof
|
|
166
|
-
return
|
|
167
|
-
} :
|
|
165
|
+
return "function" === typeof E[v] ? function(...I) {
|
|
166
|
+
return E[v].apply(E, I);
|
|
167
|
+
} : E[v];
|
|
168
168
|
}
|
|
169
|
-
}, set(
|
|
170
|
-
if (
|
|
169
|
+
}, set(E, v, I) {
|
|
170
|
+
if (E.isContextLost()) {
|
|
171
171
|
n || (console.error("Cannot render the mesh because the GL Context was lost. Tried to set property " + v), n = !0);
|
|
172
172
|
} else {
|
|
173
|
-
return
|
|
173
|
+
return E[v] = I, !0;
|
|
174
174
|
}
|
|
175
175
|
},});
|
|
176
176
|
d = Math.min(q.getParameter(q.MAX_RENDERBUFFER_SIZE), q.getParameter(q.MAX_TEXTURE_SIZE));
|
|
177
|
-
function
|
|
177
|
+
function F(E, v, I) {
|
|
178
178
|
v = q.createShader(v);
|
|
179
179
|
q.shaderSource(v, I);
|
|
180
180
|
q.compileShader(v);
|
|
@@ -182,11 +182,11 @@ const fa = "createConicGradient createImageData createLinearGradient createPatte
|
|
|
182
182
|
if (0 < (I || "").length) {
|
|
183
183
|
throw I;
|
|
184
184
|
}
|
|
185
|
-
q.attachShader(
|
|
185
|
+
q.attachShader(E, v);
|
|
186
186
|
}
|
|
187
187
|
g = q.createProgram();
|
|
188
|
-
|
|
189
|
-
|
|
188
|
+
F(g, q.VERTEX_SHADER, "attribute vec2 vertex;\n attribute vec2 uv;\n uniform vec4 mat;\n uniform vec2 translate;\n varying vec2 st;\n void main() {\n st = uv;\n gl_Position = vec4(mat2(mat) * vertex + translate, 0, 1);\n }");
|
|
189
|
+
F(g, q.FRAGMENT_SHADER, "precision highp float;\n uniform sampler2D image;\n varying vec2 st;\n void main() {\n gl_FragColor = texture2D(image, st);\n }");
|
|
190
190
|
q.bindAttribLocation(g, 0, "vertex");
|
|
191
191
|
q.bindAttribLocation(g, 1, "uv");
|
|
192
192
|
q.linkProgram(g);
|
|
@@ -233,7 +233,7 @@ const fa = "createConicGradient createImageData createLinearGradient createPatte
|
|
|
233
233
|
return r;
|
|
234
234
|
};
|
|
235
235
|
const l = new da(8), t = new da(8), w = new da(10), x = new da(10);
|
|
236
|
-
this.Qa = function(g, r, q,
|
|
236
|
+
this.Qa = function(g, r, q, F, E) {
|
|
237
237
|
if (b()) {
|
|
238
238
|
var v = l.push(g), I = t.push(r);
|
|
239
239
|
if (a.canvas) {
|
|
@@ -245,43 +245,43 @@ const fa = "createConicGradient createImageData createLinearGradient createPatte
|
|
|
245
245
|
a.clearColor(0, 0, 0, 0);
|
|
246
246
|
a.clear(a.COLOR_BUFFER_BIT);
|
|
247
247
|
a.enable(a.SCISSOR_TEST);
|
|
248
|
-
q.sort((C,
|
|
249
|
-
v = w.push(
|
|
248
|
+
q.sort((C, Y) => Y.Ba - C.Ba);
|
|
249
|
+
v = w.push(F);
|
|
250
250
|
m != v && (a.bufferData(a.ARRAY_BUFFER, 8 * v, a.DYNAMIC_DRAW), m = v);
|
|
251
251
|
v = 0;
|
|
252
252
|
for (var O of q) {
|
|
253
253
|
a.bufferSubData(a.ARRAY_BUFFER, v, O.ia), v += 4 * O.ia.length;
|
|
254
254
|
}
|
|
255
|
-
console.assert(v == 4 *
|
|
256
|
-
for (var
|
|
257
|
-
a.bufferSubData(a.ARRAY_BUFFER, v,
|
|
255
|
+
console.assert(v == 4 * F);
|
|
256
|
+
for (var Z of q) {
|
|
257
|
+
a.bufferSubData(a.ARRAY_BUFFER, v, Z.Ea), v += 4 * Z.Ea.length;
|
|
258
258
|
}
|
|
259
|
-
console.assert(v == 8 *
|
|
260
|
-
v = x.push(
|
|
259
|
+
console.assert(v == 8 * F);
|
|
260
|
+
v = x.push(E);
|
|
261
261
|
k != v && (a.bufferData(a.ELEMENT_ARRAY_BUFFER, 2 * v, a.DYNAMIC_DRAW), k = v);
|
|
262
262
|
O = 0;
|
|
263
263
|
for (var ia of q) {
|
|
264
264
|
a.bufferSubData(a.ELEMENT_ARRAY_BUFFER, O, ia.indices), O += 2 * ia.indices.length;
|
|
265
265
|
}
|
|
266
|
-
console.assert(O == 2 *
|
|
266
|
+
console.assert(O == 2 * E);
|
|
267
267
|
ia = 0;
|
|
268
|
-
|
|
268
|
+
Z = !0;
|
|
269
269
|
v = O = 0;
|
|
270
270
|
for (const C of q) {
|
|
271
271
|
C.image.da != ia && (a.bindTexture(a.TEXTURE_2D, C.image.ca || null), ia = C.image.da);
|
|
272
|
-
C.hb ? (a.scissor(C.na, I - C.oa - C.va, C.sb, C.va),
|
|
272
|
+
C.hb ? (a.scissor(C.na, I - C.oa - C.va, C.sb, C.va), Z = !0) : Z && (a.scissor(0, I - r, g, r), Z = !1);
|
|
273
273
|
q = 2 / g;
|
|
274
|
-
const
|
|
275
|
-
a.uniform4f(e, C.N[0] * q * C.X, C.N[1] *
|
|
276
|
-
a.uniform2f(f, C.N[4] * q * C.X + q * (C.na - C.fb * C.X) - 1, C.N[5] *
|
|
274
|
+
const Y = -2 / r;
|
|
275
|
+
a.uniform4f(e, C.N[0] * q * C.X, C.N[1] * Y * C.Y, C.N[2] * q * C.X, C.N[3] * Y * C.Y);
|
|
276
|
+
a.uniform2f(f, C.N[4] * q * C.X + q * (C.na - C.fb * C.X) - 1, C.N[5] * Y * C.Y + Y * (C.oa - C.gb * C.Y) + 1);
|
|
277
277
|
a.vertexAttribPointer(0, 2, a.FLOAT, !1, 0, v);
|
|
278
|
-
a.vertexAttribPointer(1, 2, a.FLOAT, !1, 0, v + 4 *
|
|
278
|
+
a.vertexAttribPointer(1, 2, a.FLOAT, !1, 0, v + 4 * F);
|
|
279
279
|
a.drawElements(a.TRIANGLES, C.indices.length, a.UNSIGNED_SHORT, O);
|
|
280
280
|
v += 4 * C.ia.length;
|
|
281
281
|
O += 2 * C.indices.length;
|
|
282
282
|
}
|
|
283
|
-
console.assert(v == 4 *
|
|
284
|
-
console.assert(O == 2 *
|
|
283
|
+
console.assert(v == 4 * F);
|
|
284
|
+
console.assert(O == 2 * E);
|
|
285
285
|
}
|
|
286
286
|
}
|
|
287
287
|
};
|
|
@@ -330,14 +330,14 @@ h.onRuntimeInitialized = function() {
|
|
|
330
330
|
return "rgba(" + ((16711680 & p) >>> 16) + "," + ((65280 & p) >>> 8) + "," + ((255 & p) >>> 0) + "," + ((4278190080 & p) >>> 24) / 255 + ")";
|
|
331
331
|
}
|
|
332
332
|
function c() {
|
|
333
|
-
0 < I.length && (ha.Qa(v.drawWidth(), v.drawHeight(), I, O,
|
|
334
|
-
for (const p of
|
|
333
|
+
0 < I.length && (ha.Qa(v.drawWidth(), v.drawHeight(), I, O, Z), I = [], Z = O = 0, v.reset(512, 512));
|
|
334
|
+
for (const p of E) {
|
|
335
335
|
for (const u of p.u) {
|
|
336
336
|
u();
|
|
337
337
|
}
|
|
338
338
|
p.u = [];
|
|
339
339
|
}
|
|
340
|
-
|
|
340
|
+
E.clear();
|
|
341
341
|
}
|
|
342
342
|
la && la();
|
|
343
343
|
var d = h.RenderPaintStyle;
|
|
@@ -369,28 +369,28 @@ h.onRuntimeInitialized = function() {
|
|
|
369
369
|
this.F = new Path2D();
|
|
370
370
|
}, rewind:function() {
|
|
371
371
|
this.F = new Path2D();
|
|
372
|
-
}, addPath:function(p, u, A,
|
|
373
|
-
var H = this.F,
|
|
372
|
+
}, addPath:function(p, u, A, D, y, B, G) {
|
|
373
|
+
var H = this.F, V = H.addPath;
|
|
374
374
|
p = p.F;
|
|
375
|
-
const
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
|
|
380
|
-
|
|
381
|
-
|
|
382
|
-
|
|
375
|
+
const M = new DOMMatrix();
|
|
376
|
+
M.a = u;
|
|
377
|
+
M.b = A;
|
|
378
|
+
M.c = D;
|
|
379
|
+
M.d = y;
|
|
380
|
+
M.e = B;
|
|
381
|
+
M.f = G;
|
|
382
|
+
V.call(H, p, M);
|
|
383
383
|
}, fillRule:function(p) {
|
|
384
384
|
this.ka = p;
|
|
385
385
|
}, moveTo:function(p, u) {
|
|
386
386
|
this.F.moveTo(p, u);
|
|
387
387
|
}, lineTo:function(p, u) {
|
|
388
388
|
this.F.lineTo(p, u);
|
|
389
|
-
}, cubicTo:function(p, u, A,
|
|
390
|
-
this.F.bezierCurveTo(p, u, A,
|
|
389
|
+
}, cubicTo:function(p, u, A, D, y, B) {
|
|
390
|
+
this.F.bezierCurveTo(p, u, A, D, y, B);
|
|
391
391
|
}, close:function() {
|
|
392
392
|
this.F.closePath();
|
|
393
|
-
},}),
|
|
393
|
+
},}), F = f.extend("CanvasRenderPaint", {color:function(p) {
|
|
394
394
|
this.ma = a(p);
|
|
395
395
|
}, thickness:function(p) {
|
|
396
396
|
this.Ja = p;
|
|
@@ -422,31 +422,31 @@ h.onRuntimeInitialized = function() {
|
|
|
422
422
|
this.Fa = b(p);
|
|
423
423
|
}, clearGradient:function() {
|
|
424
424
|
this.P = null;
|
|
425
|
-
}, linearGradient:function(p, u, A,
|
|
426
|
-
this.P = {Ca:p, Da:u, qa:A, ra:
|
|
427
|
-
}, radialGradient:function(p, u, A,
|
|
428
|
-
this.P = {Ca:p, Da:u, qa:A, ra:
|
|
425
|
+
}, linearGradient:function(p, u, A, D) {
|
|
426
|
+
this.P = {Ca:p, Da:u, qa:A, ra:D, ga:[],};
|
|
427
|
+
}, radialGradient:function(p, u, A, D) {
|
|
428
|
+
this.P = {Ca:p, Da:u, qa:A, ra:D, ga:[], bb:!0,};
|
|
429
429
|
}, addStop:function(p, u) {
|
|
430
430
|
this.P.ga.push({color:p, stop:u,});
|
|
431
431
|
}, completeGradient:function() {
|
|
432
432
|
}, draw:function(p, u, A) {
|
|
433
|
-
let
|
|
434
|
-
var y = this.ma,
|
|
433
|
+
let D = this.Ia;
|
|
434
|
+
var y = this.ma, B = this.P;
|
|
435
435
|
p.globalCompositeOperation = this.Fa;
|
|
436
|
-
if (null !=
|
|
437
|
-
y =
|
|
438
|
-
var
|
|
439
|
-
const
|
|
440
|
-
var H =
|
|
441
|
-
const
|
|
442
|
-
|
|
443
|
-
for (let
|
|
444
|
-
|
|
436
|
+
if (null != B) {
|
|
437
|
+
y = B.Ca;
|
|
438
|
+
var G = B.Da;
|
|
439
|
+
const V = B.qa;
|
|
440
|
+
var H = B.ra;
|
|
441
|
+
const M = B.ga;
|
|
442
|
+
B.bb ? (B = V - y, H -= G, y = p.createRadialGradient(y, G, 0, y, G, Math.sqrt(B * B + H * H))) : y = p.createLinearGradient(y, G, V, H);
|
|
443
|
+
for (let T = 0, N = M.length; T < N; T++) {
|
|
444
|
+
G = M[T], y.addColorStop(G.stop, a(G.color));
|
|
445
445
|
}
|
|
446
446
|
this.ma = y;
|
|
447
447
|
this.P = null;
|
|
448
448
|
}
|
|
449
|
-
switch(
|
|
449
|
+
switch(D) {
|
|
450
450
|
case w:
|
|
451
451
|
p.strokeStyle = y;
|
|
452
452
|
p.lineWidth = this.Ja;
|
|
@@ -458,8 +458,8 @@ h.onRuntimeInitialized = function() {
|
|
|
458
458
|
p.fillStyle = y, p.fill(u, A);
|
|
459
459
|
}
|
|
460
460
|
},});
|
|
461
|
-
const
|
|
462
|
-
let v = null, I = [], O = 0,
|
|
461
|
+
const E = new Set();
|
|
462
|
+
let v = null, I = [], O = 0, Z = 0;
|
|
463
463
|
var ia = h.CanvasRenderer = m.extend("Renderer", {__construct:function(p) {
|
|
464
464
|
this.__parent.__construct.call(this);
|
|
465
465
|
this.D = [1, 0, 0, 1, 0, 0];
|
|
@@ -476,71 +476,72 @@ h.onRuntimeInitialized = function() {
|
|
|
476
476
|
}
|
|
477
477
|
this.D.splice(p);
|
|
478
478
|
this.u.push(this.o.restore.bind(this.o));
|
|
479
|
-
}, transform:function(p, u, A,
|
|
480
|
-
const
|
|
481
|
-
|
|
482
|
-
this.u.push(this.o.transform.bind(this.o, p, u, A,
|
|
479
|
+
}, transform:function(p, u, A, D, y, B) {
|
|
480
|
+
const G = this.D, H = G.length - 6;
|
|
481
|
+
G.splice(H, 6, G[H] * p + G[H + 2] * u, G[H + 1] * p + G[H + 3] * u, G[H] * A + G[H + 2] * D, G[H + 1] * A + G[H + 3] * D, G[H] * y + G[H + 2] * B + G[H + 4], G[H + 1] * y + G[H + 3] * B + G[H + 5]);
|
|
482
|
+
this.u.push(this.o.transform.bind(this.o, p, u, A, D, y, B));
|
|
483
483
|
}, rotate:function(p) {
|
|
484
484
|
const u = Math.sin(p);
|
|
485
485
|
p = Math.cos(p);
|
|
486
486
|
this.transform(p, u, -u, p, 0, 0);
|
|
487
487
|
}, _drawPath:function(p, u) {
|
|
488
488
|
this.u.push(u.draw.bind(u, this.o, p.F, p.ka === x ? "evenodd" : "nonzero"));
|
|
489
|
-
}, _drawRiveImage:function(p, u, A) {
|
|
490
|
-
var
|
|
491
|
-
if (
|
|
492
|
-
var
|
|
489
|
+
}, _drawRiveImage:function(p, u, A, D) {
|
|
490
|
+
var y = p.Ga;
|
|
491
|
+
if (y) {
|
|
492
|
+
var B = this.o, G = b(A);
|
|
493
493
|
this.u.push(function() {
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
494
|
+
B.globalCompositeOperation = G;
|
|
495
|
+
B.globalAlpha = D;
|
|
496
|
+
B.drawImage(y, 0, 0);
|
|
497
|
+
B.globalAlpha = 1;
|
|
498
498
|
});
|
|
499
499
|
}
|
|
500
500
|
}, _getMatrix:function(p) {
|
|
501
501
|
const u = this.D, A = u.length - 6;
|
|
502
|
-
for (let
|
|
503
|
-
p[
|
|
502
|
+
for (let D = 0; 6 > D; ++D) {
|
|
503
|
+
p[D] = u[A + D];
|
|
504
504
|
}
|
|
505
|
-
}, _drawImageMesh:function(p, u, A,
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
505
|
+
}, _drawImageMesh:function(p, u, A, D, y, B, G, H, V, M, T) {
|
|
506
|
+
u = this.o.canvas.width;
|
|
507
|
+
var N = this.o.canvas.height;
|
|
508
|
+
const tb = M - H, ub = T - V;
|
|
509
509
|
H = Math.max(H, 0);
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
510
|
+
V = Math.max(V, 0);
|
|
511
|
+
M = Math.min(M, u);
|
|
512
|
+
T = Math.min(T, N);
|
|
513
|
+
const wa = M - H, xa = T - V;
|
|
514
|
+
console.assert(wa <= Math.min(tb, u));
|
|
514
515
|
console.assert(xa <= Math.min(ub, N));
|
|
515
516
|
if (!(0 >= wa || 0 >= xa)) {
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
var ja = Math.ceil(wa *
|
|
517
|
+
M = wa < tb || xa < ub;
|
|
518
|
+
u = T = 1;
|
|
519
|
+
var ja = Math.ceil(wa * T), ka = Math.ceil(xa * u);
|
|
519
520
|
N = ha.eb();
|
|
520
|
-
ja > N && (
|
|
521
|
-
ka > N && (
|
|
521
|
+
ja > N && (T *= N / ja, ja = N);
|
|
522
|
+
ka > N && (u *= N / ka, ka = N);
|
|
522
523
|
v || (v = new h.DynamicRectanizer(N), v.reset(512, 512));
|
|
523
524
|
N = v.addRect(ja, ka);
|
|
524
|
-
0 > N && (c(),
|
|
525
|
+
0 > N && (c(), E.add(this), N = v.addRect(ja, ka), console.assert(0 <= N));
|
|
525
526
|
var vb = N & 65535, wb = N >> 16;
|
|
526
|
-
I.push({N:this.D.slice(this.D.length - 6), image:p, na:vb, oa:wb, fb:
|
|
527
|
-
O +=
|
|
528
|
-
|
|
529
|
-
var pa = this.o, oc = b(
|
|
527
|
+
I.push({N:this.D.slice(this.D.length - 6), image:p, na:vb, oa:wb, fb:H, gb:V, sb:ja, va:ka, X:T, Y:u, ia:new Float32Array(y), Ea:new Float32Array(B), indices:new Uint16Array(G), hb:M, Ba:p.da << 1 | (M ? 1 : 0),});
|
|
528
|
+
O += y.length;
|
|
529
|
+
Z += G.length;
|
|
530
|
+
var pa = this.o, oc = b(A);
|
|
530
531
|
this.u.push(function() {
|
|
531
532
|
pa.save();
|
|
532
533
|
pa.resetTransform();
|
|
533
534
|
pa.globalCompositeOperation = oc;
|
|
534
|
-
pa.globalAlpha =
|
|
535
|
+
pa.globalAlpha = D;
|
|
535
536
|
const xb = ha.canvas();
|
|
536
|
-
xb && pa.drawImage(xb, vb, wb, ja, ka,
|
|
537
|
+
xb && pa.drawImage(xb, vb, wb, ja, ka, H, V, wa, xa);
|
|
537
538
|
pa.restore();
|
|
538
539
|
});
|
|
539
540
|
}
|
|
540
541
|
}, _clipPath:function(p) {
|
|
541
542
|
this.u.push(this.o.clip.bind(this.o, p.F, p.ka === x ? "evenodd" : "nonzero"));
|
|
542
543
|
}, clear:function() {
|
|
543
|
-
|
|
544
|
+
E.add(this);
|
|
544
545
|
this.u.push(this.o.clearRect.bind(this.o, 0, 0, this.ja.width, this.ja.height));
|
|
545
546
|
}, flush:function() {
|
|
546
547
|
}, translate:function(p, u) {
|
|
@@ -548,25 +549,25 @@ h.onRuntimeInitialized = function() {
|
|
|
548
549
|
},});
|
|
549
550
|
h.makeRenderer = function(p) {
|
|
550
551
|
const u = new ia(p), A = u.o;
|
|
551
|
-
return new Proxy(u, {get(
|
|
552
|
-
if ("function" === typeof
|
|
553
|
-
return function(...
|
|
554
|
-
return
|
|
552
|
+
return new Proxy(u, {get(D, y) {
|
|
553
|
+
if ("function" === typeof D[y]) {
|
|
554
|
+
return function(...B) {
|
|
555
|
+
return D[y].apply(D, B);
|
|
555
556
|
};
|
|
556
557
|
}
|
|
557
558
|
if ("function" === typeof A[y]) {
|
|
558
559
|
if (-1 < fa.indexOf(y)) {
|
|
559
560
|
throw Error("RiveException: Method call to '" + y + "()' is not allowed, as the renderer cannot immediately pass through the return values of any canvas 2d context methods.");
|
|
560
561
|
}
|
|
561
|
-
return function(...
|
|
562
|
-
u.u.push(A[y].bind(A, ...
|
|
562
|
+
return function(...B) {
|
|
563
|
+
u.u.push(A[y].bind(A, ...B));
|
|
563
564
|
};
|
|
564
565
|
}
|
|
565
|
-
return
|
|
566
|
-
}, set(
|
|
566
|
+
return D[y];
|
|
567
|
+
}, set(D, y, B) {
|
|
567
568
|
if (y in A) {
|
|
568
569
|
return u.u.push(() => {
|
|
569
|
-
A[y] =
|
|
570
|
+
A[y] = B;
|
|
570
571
|
}), !0;
|
|
571
572
|
}
|
|
572
573
|
},});
|
|
@@ -575,11 +576,11 @@ h.onRuntimeInitialized = function() {
|
|
|
575
576
|
(new r({R:u})).decode(p);
|
|
576
577
|
};
|
|
577
578
|
h.renderFactory = {makeRenderPaint:function() {
|
|
578
|
-
return new
|
|
579
|
+
return new F();
|
|
579
580
|
}, makeRenderPath:function() {
|
|
580
581
|
return new q();
|
|
581
582
|
}, makeRenderImage:function() {
|
|
582
|
-
let p =
|
|
583
|
+
let p = Y;
|
|
583
584
|
return new r({W:() => {
|
|
584
585
|
p.total++;
|
|
585
586
|
}, R:() => {
|
|
@@ -590,23 +591,23 @@ h.onRuntimeInitialized = function() {
|
|
|
590
591
|
}
|
|
591
592
|
},});
|
|
592
593
|
},};
|
|
593
|
-
let C = h.load,
|
|
594
|
+
let C = h.load, Y = null;
|
|
594
595
|
h.load = function(p, u, A = !0) {
|
|
595
|
-
const
|
|
596
|
-
void 0 !== u &&
|
|
597
|
-
A && (u = new h.CDNFileAssetLoader(),
|
|
596
|
+
const D = new h.FallbackFileAssetLoader();
|
|
597
|
+
void 0 !== u && D.addLoader(u);
|
|
598
|
+
A && (u = new h.CDNFileAssetLoader(), D.addLoader(u));
|
|
598
599
|
return new Promise(function(y) {
|
|
599
|
-
let
|
|
600
|
-
|
|
601
|
-
y(
|
|
600
|
+
let B = null;
|
|
601
|
+
Y = {total:0, loaded:0, ready:function() {
|
|
602
|
+
y(B);
|
|
602
603
|
},};
|
|
603
|
-
|
|
604
|
-
0 ==
|
|
604
|
+
B = C(p, D);
|
|
605
|
+
0 == Y.total && y(B);
|
|
605
606
|
});
|
|
606
607
|
};
|
|
607
608
|
let pc = h.RendererWrapper.prototype.align;
|
|
608
|
-
h.RendererWrapper.prototype.align = function(p, u, A,
|
|
609
|
-
pc.call(this, p, u, A,
|
|
609
|
+
h.RendererWrapper.prototype.align = function(p, u, A, D, y = 1.0) {
|
|
610
|
+
pc.call(this, p, u, A, D, y);
|
|
610
611
|
};
|
|
611
612
|
d = new ca();
|
|
612
613
|
h.requestAnimationFrame = d.requestAnimationFrame.bind(d);
|
|
@@ -646,15 +647,15 @@ var ya;
|
|
|
646
647
|
h.wasmBinary && (ya = h.wasmBinary);
|
|
647
648
|
var noExitRuntime = h.noExitRuntime || !0;
|
|
648
649
|
"object" != typeof WebAssembly && za("no native wasm support detected");
|
|
649
|
-
var Aa, z, Ba = !1, Ca, J, Da, Ea,
|
|
650
|
+
var Aa, z, Ba = !1, Ca, J, Da, Ea, K, L, Fa, Ga;
|
|
650
651
|
function Ha() {
|
|
651
652
|
var b = Aa.buffer;
|
|
652
653
|
h.HEAP8 = Ca = new Int8Array(b);
|
|
653
654
|
h.HEAP16 = Da = new Int16Array(b);
|
|
654
|
-
h.HEAP32 =
|
|
655
|
+
h.HEAP32 = K = new Int32Array(b);
|
|
655
656
|
h.HEAPU8 = J = new Uint8Array(b);
|
|
656
657
|
h.HEAPU16 = Ea = new Uint16Array(b);
|
|
657
|
-
h.HEAPU32 =
|
|
658
|
+
h.HEAPU32 = L = new Uint32Array(b);
|
|
658
659
|
h.HEAPF32 = Fa = new Float32Array(b);
|
|
659
660
|
h.HEAPF64 = Ga = new Float64Array(b);
|
|
660
661
|
}
|
|
@@ -874,10 +875,10 @@ function Eb(b) {
|
|
|
874
875
|
}
|
|
875
876
|
}
|
|
876
877
|
function Fb(b) {
|
|
877
|
-
return this.fromWireType(
|
|
878
|
+
return this.fromWireType(K[b >> 2]);
|
|
878
879
|
}
|
|
879
880
|
var Gb = {}, Hb = {};
|
|
880
|
-
function
|
|
881
|
+
function W(b, a, c) {
|
|
881
882
|
function d(k) {
|
|
882
883
|
k = c(k);
|
|
883
884
|
k.length !== b.length && Ab("Mismatched type converter count");
|
|
@@ -1054,7 +1055,7 @@ var Xb = [], Yb = b => {
|
|
|
1054
1055
|
return d;
|
|
1055
1056
|
};
|
|
1056
1057
|
};
|
|
1057
|
-
function
|
|
1058
|
+
function X(b, a) {
|
|
1058
1059
|
b = U(b);
|
|
1059
1060
|
var c = b.includes("j") ? Zb(b, a) : Yb(a);
|
|
1060
1061
|
"function" != typeof c && Q(`unknown function pointer with signature ${b}: ${a}`);
|
|
@@ -1097,8 +1098,8 @@ function bc(b, a, c, d, e) {
|
|
|
1097
1098
|
Eb(x);
|
|
1098
1099
|
} else {
|
|
1099
1100
|
for (var q = m ? 1 : 2; q < a.length; q++) {
|
|
1100
|
-
var
|
|
1101
|
-
null !== a[q].v && a[q].v(
|
|
1101
|
+
var F = 1 === q ? g : t[q - 2];
|
|
1102
|
+
null !== a[q].v && a[q].v(F);
|
|
1102
1103
|
}
|
|
1103
1104
|
}
|
|
1104
1105
|
g = n ? a[0].fromWireType(r) : void 0;
|
|
@@ -1107,7 +1108,7 @@ function bc(b, a, c, d, e) {
|
|
|
1107
1108
|
}
|
|
1108
1109
|
function cc(b, a) {
|
|
1109
1110
|
for (var c = [], d = 0; d < b; d++) {
|
|
1110
|
-
c.push(
|
|
1111
|
+
c.push(L[a + 4 * d >> 2]);
|
|
1111
1112
|
}
|
|
1112
1113
|
return c;
|
|
1113
1114
|
}
|
|
@@ -1132,7 +1133,7 @@ function fc(b, a, c) {
|
|
|
1132
1133
|
};
|
|
1133
1134
|
case 2:
|
|
1134
1135
|
return function(d) {
|
|
1135
|
-
return this.fromWireType((c ?
|
|
1136
|
+
return this.fromWireType((c ? K : L)[d >> 2]);
|
|
1136
1137
|
};
|
|
1137
1138
|
default:
|
|
1138
1139
|
throw new TypeError("Unknown integer type: " + b);
|
|
@@ -1175,9 +1176,9 @@ function hc(b, a, c) {
|
|
|
1175
1176
|
};
|
|
1176
1177
|
case 2:
|
|
1177
1178
|
return c ? function(d) {
|
|
1178
|
-
return
|
|
1179
|
+
return K[d >> 2];
|
|
1179
1180
|
} : function(d) {
|
|
1180
|
-
return
|
|
1181
|
+
return L[d >> 2];
|
|
1181
1182
|
};
|
|
1182
1183
|
default:
|
|
1183
1184
|
throw new TypeError("Unknown integer type: " + b);
|
|
@@ -1286,7 +1287,7 @@ var ic = (b, a, c, d) => {
|
|
|
1286
1287
|
return a - d;
|
|
1287
1288
|
}, rc = b => 2 * b.length, sc = (b, a) => {
|
|
1288
1289
|
for (var c = 0, d = ""; !(c >= a / 4);) {
|
|
1289
|
-
var e =
|
|
1290
|
+
var e = K[b + 4 * c >> 2];
|
|
1290
1291
|
if (0 == e) {
|
|
1291
1292
|
break;
|
|
1292
1293
|
}
|
|
@@ -1307,13 +1308,13 @@ var ic = (b, a, c, d) => {
|
|
|
1307
1308
|
var m = b.charCodeAt(++e);
|
|
1308
1309
|
f = 65536 + ((f & 1023) << 10) | m & 1023;
|
|
1309
1310
|
}
|
|
1310
|
-
|
|
1311
|
+
K[a >> 2] = f;
|
|
1311
1312
|
a += 4;
|
|
1312
1313
|
if (a + 4 > c) {
|
|
1313
1314
|
break;
|
|
1314
1315
|
}
|
|
1315
1316
|
}
|
|
1316
|
-
|
|
1317
|
+
K[a >> 2] = 0;
|
|
1317
1318
|
return a - d;
|
|
1318
1319
|
}, uc = b => {
|
|
1319
1320
|
for (var a = 0, c = 0; c < b.length; ++c) {
|
|
@@ -1335,7 +1336,7 @@ function yc(b) {
|
|
|
1335
1336
|
}
|
|
1336
1337
|
function zc(b, a) {
|
|
1337
1338
|
for (var c = Array(b), d = 0; d < b; ++d) {
|
|
1338
|
-
c[d] = nb(
|
|
1339
|
+
c[d] = nb(L[a + 4 * d >> 2], "parameter " + d);
|
|
1339
1340
|
}
|
|
1340
1341
|
return c;
|
|
1341
1342
|
}
|
|
@@ -1369,12 +1370,12 @@ var Jc = (b, a, c, d) => {
|
|
|
1369
1370
|
return e(g, r, "0");
|
|
1370
1371
|
}
|
|
1371
1372
|
function m(g, r) {
|
|
1372
|
-
function q(
|
|
1373
|
-
return 0 >
|
|
1373
|
+
function q(E) {
|
|
1374
|
+
return 0 > E ? -1 : 0 < E ? 1 : 0;
|
|
1374
1375
|
}
|
|
1375
|
-
var
|
|
1376
|
-
0 === (
|
|
1377
|
-
return
|
|
1376
|
+
var F;
|
|
1377
|
+
0 === (F = q(g.getFullYear() - r.getFullYear())) && 0 === (F = q(g.getMonth() - r.getMonth())) && (F = q(g.getDate() - r.getDate()));
|
|
1378
|
+
return F;
|
|
1378
1379
|
}
|
|
1379
1380
|
function k(g) {
|
|
1380
1381
|
switch(g.getDay()) {
|
|
@@ -1397,9 +1398,9 @@ var Jc = (b, a, c, d) => {
|
|
|
1397
1398
|
function n(g) {
|
|
1398
1399
|
var r = g.J;
|
|
1399
1400
|
for (g = new Date((new Date(g.K + 1900, 0, 1)).getTime()); 0 < r;) {
|
|
1400
|
-
var q = g.getMonth(),
|
|
1401
|
-
if (r >
|
|
1402
|
-
r -=
|
|
1401
|
+
var q = g.getMonth(), F = (Fc(g.getFullYear()) ? Gc : Hc)[q];
|
|
1402
|
+
if (r > F - g.getDate()) {
|
|
1403
|
+
r -= F - g.getDate() + 1, g.setDate(1), 11 > q ? g.setMonth(q + 1) : (g.setMonth(0), g.setFullYear(g.getFullYear() + 1));
|
|
1403
1404
|
} else {
|
|
1404
1405
|
g.setDate(g.getDate() + r);
|
|
1405
1406
|
break;
|
|
@@ -1410,8 +1411,8 @@ var Jc = (b, a, c, d) => {
|
|
|
1410
1411
|
q = k(q);
|
|
1411
1412
|
return 0 >= m(r, g) ? 0 >= m(q, g) ? g.getFullYear() + 1 : g.getFullYear() : g.getFullYear() - 1;
|
|
1412
1413
|
}
|
|
1413
|
-
var l =
|
|
1414
|
-
d = {qb:
|
|
1414
|
+
var l = K[d + 40 >> 2];
|
|
1415
|
+
d = {qb:K[d >> 2], pb:K[d + 4 >> 2], Z:K[d + 8 >> 2], ha:K[d + 12 >> 2], $:K[d + 16 >> 2], K:K[d + 20 >> 2], C:K[d + 24 >> 2], J:K[d + 28 >> 2], ub:K[d + 32 >> 2], ob:K[d + 36 >> 2], rb:l ? l ? lc(J, l) : "" : ""};
|
|
1415
1416
|
c = c ? lc(J, c) : "";
|
|
1416
1417
|
l = {"%c":"%a %b %d %H:%M:%S %Y", "%D":"%m/%d/%y", "%F":"%Y-%m-%d", "%h":"%b", "%r":"%I:%M:%S %p", "%R":"%H:%M", "%T":"%H:%M:%S", "%x":"%m/%d/%y", "%X":"%H:%M:%S", "%Ec":"%c", "%EC":"%C", "%Ex":"%m/%d/%y", "%EX":"%H:%M:%S", "%Ey":"%y", "%EY":"%Y", "%Od":"%d", "%Oe":"%e", "%OH":"%H", "%OI":"%I", "%Om":"%m", "%OM":"%M", "%OS":"%S", "%Ou":"%u", "%OU":"%U", "%OV":"%V", "%Ow":"%w", "%OW":"%W", "%Oy":"%y",};
|
|
1417
1418
|
for (var t in l) {
|
|
@@ -1633,13 +1634,13 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1633
1634
|
var a = Db[b];
|
|
1634
1635
|
delete Db[b];
|
|
1635
1636
|
var c = a.fa, d = a.H, e = a.sa, f = e.map(m => m.Ya).concat(e.map(m => m.lb));
|
|
1636
|
-
|
|
1637
|
+
W([b], f, m => {
|
|
1637
1638
|
var k = {};
|
|
1638
1639
|
e.forEach((n, l) => {
|
|
1639
1640
|
var t = m[l], w = n.Wa, x = n.Xa, g = m[l + e.length], r = n.kb, q = n.mb;
|
|
1640
|
-
k[n.Sa] = {read:
|
|
1641
|
+
k[n.Sa] = {read:F => t.fromWireType(w(x, F)), write:(F, E) => {
|
|
1641
1642
|
var v = [];
|
|
1642
|
-
r(q,
|
|
1643
|
+
r(q, F, g.toWireType(v, E));
|
|
1643
1644
|
Eb(v);
|
|
1644
1645
|
}};
|
|
1645
1646
|
});
|
|
@@ -1678,7 +1679,7 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1678
1679
|
} else if (2 === c) {
|
|
1679
1680
|
k = Da;
|
|
1680
1681
|
} else if (4 === c) {
|
|
1681
|
-
k =
|
|
1682
|
+
k = K;
|
|
1682
1683
|
} else {
|
|
1683
1684
|
throw new TypeError("Unknown boolean type size: " + a);
|
|
1684
1685
|
}
|
|
@@ -1686,24 +1687,24 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1686
1687
|
}, v:null,});
|
|
1687
1688
|
}, _embind_register_class:function(b, a, c, d, e, f, m, k, n, l, t, w, x) {
|
|
1688
1689
|
t = U(t);
|
|
1689
|
-
f =
|
|
1690
|
-
k && (k =
|
|
1691
|
-
l && (l =
|
|
1692
|
-
x =
|
|
1690
|
+
f = X(e, f);
|
|
1691
|
+
k && (k = X(m, k));
|
|
1692
|
+
l && (l = X(n, l));
|
|
1693
|
+
x = X(w, x);
|
|
1693
1694
|
var g = Ya(t);
|
|
1694
1695
|
Ob(g, function() {
|
|
1695
1696
|
ac(`Cannot construct ${t} due to unbound types`, [d]);
|
|
1696
1697
|
});
|
|
1697
|
-
|
|
1698
|
+
W([b, a, c], d ? [d] : [], function(r) {
|
|
1698
1699
|
r = r[0];
|
|
1699
1700
|
if (d) {
|
|
1700
1701
|
var q = r.h;
|
|
1701
|
-
var
|
|
1702
|
+
var F = q.B;
|
|
1702
1703
|
} else {
|
|
1703
|
-
|
|
1704
|
+
F = Mb.prototype;
|
|
1704
1705
|
}
|
|
1705
1706
|
r = Za(g, function() {
|
|
1706
|
-
if (Object.getPrototypeOf(this) !==
|
|
1707
|
+
if (Object.getPrototypeOf(this) !== E) {
|
|
1707
1708
|
throw new ab("Use 'new' to construct " + t);
|
|
1708
1709
|
}
|
|
1709
1710
|
if (void 0 === v.I) {
|
|
@@ -1715,22 +1716,22 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1715
1716
|
}
|
|
1716
1717
|
return O.apply(this, arguments);
|
|
1717
1718
|
});
|
|
1718
|
-
var
|
|
1719
|
-
r.prototype =
|
|
1720
|
-
var v = new Pb(t, r,
|
|
1719
|
+
var E = Object.create(F, {constructor:{value:r},});
|
|
1720
|
+
r.prototype = E;
|
|
1721
|
+
var v = new Pb(t, r, E, x, q, f, k, l);
|
|
1721
1722
|
v.l && (void 0 === v.l.T && (v.l.T = []), v.l.T.push(v));
|
|
1722
1723
|
q = new Vb(t, v, !0, !1);
|
|
1723
|
-
|
|
1724
|
+
F = new Vb(t + "*", v, !1, !1);
|
|
1724
1725
|
var I = new Vb(t + " const*", v, !1, !0);
|
|
1725
|
-
sb[b] = {pointerType:
|
|
1726
|
+
sb[b] = {pointerType:F, Ka:I};
|
|
1726
1727
|
Wb(g, r);
|
|
1727
|
-
return [q,
|
|
1728
|
+
return [q, F, I];
|
|
1728
1729
|
});
|
|
1729
1730
|
}, _embind_register_class_class_function:function(b, a, c, d, e, f, m) {
|
|
1730
1731
|
var k = cc(c, d);
|
|
1731
1732
|
a = U(a);
|
|
1732
|
-
f =
|
|
1733
|
-
|
|
1733
|
+
f = X(e, f);
|
|
1734
|
+
W([], [b], function(n) {
|
|
1734
1735
|
function l() {
|
|
1735
1736
|
ac(`Cannot call ${t} due to unbound types`, k);
|
|
1736
1737
|
}
|
|
@@ -1739,7 +1740,7 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1739
1740
|
a.startsWith("@@") && (a = Symbol[a.substring(2)]);
|
|
1740
1741
|
var w = n.h.constructor;
|
|
1741
1742
|
void 0 === w[a] ? (l.L = c - 1, w[a] = l) : (Nb(w, a, t), w[a].m[c - 1] = l);
|
|
1742
|
-
|
|
1743
|
+
W([], k, function(x) {
|
|
1743
1744
|
x = bc(t, [x[0], null].concat(x.slice(1)), null, f, m);
|
|
1744
1745
|
void 0 === w[a].m ? (x.L = c - 1, w[a] = x) : w[a].m[c - 1] = x;
|
|
1745
1746
|
if (n.h.T) {
|
|
@@ -1753,8 +1754,8 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1753
1754
|
});
|
|
1754
1755
|
}, _embind_register_class_class_property:function(b, a, c, d, e, f, m, k) {
|
|
1755
1756
|
a = U(a);
|
|
1756
|
-
f =
|
|
1757
|
-
|
|
1757
|
+
f = X(e, f);
|
|
1758
|
+
W([], [b], function(n) {
|
|
1758
1759
|
n = n[0];
|
|
1759
1760
|
var l = `${n.name}.${a}`, t = {get() {
|
|
1760
1761
|
ac(`Cannot access ${l} due to unbound types`, [c]);
|
|
@@ -1765,12 +1766,12 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1765
1766
|
Q(`${l} is a read-only property`);
|
|
1766
1767
|
};
|
|
1767
1768
|
Object.defineProperty(n.h.constructor, a, t);
|
|
1768
|
-
|
|
1769
|
+
W([], [c], function(w) {
|
|
1769
1770
|
w = w[0];
|
|
1770
1771
|
var x = {get() {
|
|
1771
1772
|
return w.fromWireType(f(d));
|
|
1772
1773
|
}, enumerable:!0};
|
|
1773
|
-
k && (k =
|
|
1774
|
+
k && (k = X(m, k), x.set = g => {
|
|
1774
1775
|
var r = [];
|
|
1775
1776
|
k(d, w.toWireType(r, g));
|
|
1776
1777
|
Eb(r);
|
|
@@ -1782,8 +1783,8 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1782
1783
|
});
|
|
1783
1784
|
}, _embind_register_class_constructor:function(b, a, c, d, e, f) {
|
|
1784
1785
|
var m = cc(a, c);
|
|
1785
|
-
e =
|
|
1786
|
-
|
|
1786
|
+
e = X(d, e);
|
|
1787
|
+
W([], [b], function(k) {
|
|
1787
1788
|
k = k[0];
|
|
1788
1789
|
var n = `constructor ${k.name}`;
|
|
1789
1790
|
void 0 === k.h.I && (k.h.I = []);
|
|
@@ -1793,7 +1794,7 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1793
1794
|
k.h.I[a - 1] = () => {
|
|
1794
1795
|
ac(`Cannot construct ${k.name} due to unbound types`, m);
|
|
1795
1796
|
};
|
|
1796
|
-
|
|
1797
|
+
W([], m, function(l) {
|
|
1797
1798
|
l.splice(1, 0, null);
|
|
1798
1799
|
k.h.I[a - 1] = bc(n, l, null, e, f);
|
|
1799
1800
|
return [];
|
|
@@ -1803,8 +1804,8 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1803
1804
|
}, _embind_register_class_function:function(b, a, c, d, e, f, m, k) {
|
|
1804
1805
|
var n = cc(c, d);
|
|
1805
1806
|
a = U(a);
|
|
1806
|
-
f =
|
|
1807
|
-
|
|
1807
|
+
f = X(e, f);
|
|
1808
|
+
W([], [b], function(l) {
|
|
1808
1809
|
function t() {
|
|
1809
1810
|
ac(`Cannot call ${w} due to unbound types`, n);
|
|
1810
1811
|
}
|
|
@@ -1814,7 +1815,7 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1814
1815
|
k && l.h.ya.push(a);
|
|
1815
1816
|
var x = l.h.B, g = x[a];
|
|
1816
1817
|
void 0 === g || void 0 === g.m && g.className !== l.name && g.L === c - 2 ? (t.L = c - 2, t.className = l.name, x[a] = t) : (Nb(x, a, w), x[a].m[c - 2] = t);
|
|
1817
|
-
|
|
1818
|
+
W([], n, function(r) {
|
|
1818
1819
|
r = bc(w, r, l, f, m);
|
|
1819
1820
|
void 0 === x[a].m ? (r.L = c - 2, x[a] = r) : x[a].m[c - 2] = r;
|
|
1820
1821
|
return [];
|
|
@@ -1823,8 +1824,8 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1823
1824
|
});
|
|
1824
1825
|
}, _embind_register_class_property:function(b, a, c, d, e, f, m, k, n, l) {
|
|
1825
1826
|
a = U(a);
|
|
1826
|
-
e =
|
|
1827
|
-
|
|
1827
|
+
e = X(d, e);
|
|
1828
|
+
W([], [b], function(t) {
|
|
1828
1829
|
t = t[0];
|
|
1829
1830
|
var w = `${t.name}.${a}`, x = {get() {
|
|
1830
1831
|
ac(`Cannot access ${w} due to unbound types`, [c, m]);
|
|
@@ -1835,17 +1836,17 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1835
1836
|
Q(w + " is a read-only property");
|
|
1836
1837
|
};
|
|
1837
1838
|
Object.defineProperty(t.h.B, a, x);
|
|
1838
|
-
|
|
1839
|
+
W([], n ? [c, m] : [c], function(g) {
|
|
1839
1840
|
var r = g[0], q = {get() {
|
|
1840
|
-
var
|
|
1841
|
-
return r.fromWireType(e(f,
|
|
1841
|
+
var E = dc(this, t, w + " getter");
|
|
1842
|
+
return r.fromWireType(e(f, E));
|
|
1842
1843
|
}, enumerable:!0};
|
|
1843
1844
|
if (n) {
|
|
1844
|
-
n =
|
|
1845
|
-
var
|
|
1846
|
-
q.set = function(
|
|
1845
|
+
n = X(k, n);
|
|
1846
|
+
var F = g[1];
|
|
1847
|
+
q.set = function(E) {
|
|
1847
1848
|
var v = dc(this, t, w + " setter"), I = [];
|
|
1848
|
-
n(l, v,
|
|
1849
|
+
n(l, v, F.toWireType(I, E));
|
|
1849
1850
|
Eb(I);
|
|
1850
1851
|
};
|
|
1851
1852
|
}
|
|
@@ -1894,11 +1895,11 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1894
1895
|
}, _embind_register_function:function(b, a, c, d, e, f) {
|
|
1895
1896
|
var m = cc(a, c);
|
|
1896
1897
|
b = U(b);
|
|
1897
|
-
e =
|
|
1898
|
+
e = X(d, e);
|
|
1898
1899
|
Ob(b, function() {
|
|
1899
1900
|
ac(`Cannot call ${b} due to unbound types`, m);
|
|
1900
1901
|
}, a - 1);
|
|
1901
|
-
|
|
1902
|
+
W([], m, function(k) {
|
|
1902
1903
|
Wb(b, bc(b, [k[0], null].concat(k.slice(1)), null, e, f), a - 1);
|
|
1903
1904
|
return [];
|
|
1904
1905
|
});
|
|
@@ -1920,7 +1921,7 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1920
1921
|
}, _embind_register_memory_view:function(b, a, c) {
|
|
1921
1922
|
function d(f) {
|
|
1922
1923
|
f >>= 2;
|
|
1923
|
-
var m =
|
|
1924
|
+
var m = L;
|
|
1924
1925
|
return new e(m.buffer, m[f + 1], m[f]);
|
|
1925
1926
|
}
|
|
1926
1927
|
var e = [Int8Array, Uint8Array, Int16Array, Uint16Array, Int32Array, Uint32Array, Float32Array, Float64Array,][a];
|
|
@@ -1930,7 +1931,7 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1930
1931
|
a = U(a);
|
|
1931
1932
|
var c = "std::string" === a;
|
|
1932
1933
|
Ib(b, {name:a, fromWireType:function(d) {
|
|
1933
|
-
var e =
|
|
1934
|
+
var e = L[d >> 2], f = d + 4;
|
|
1934
1935
|
if (c) {
|
|
1935
1936
|
for (var m = f, k = 0; k <= e; ++k) {
|
|
1936
1937
|
var n = f + k;
|
|
@@ -1959,7 +1960,7 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1959
1960
|
f || e instanceof Uint8Array || e instanceof Uint8ClampedArray || e instanceof Int8Array || Q("Cannot pass non-string to std::string");
|
|
1960
1961
|
var m = c && f ? jc(e) : e.length;
|
|
1961
1962
|
var k = Mc(4 + m + 1), n = k + 4;
|
|
1962
|
-
|
|
1963
|
+
L[k >> 2] = m;
|
|
1963
1964
|
if (c && f) {
|
|
1964
1965
|
ic(e, J, n, m + 1);
|
|
1965
1966
|
} else {
|
|
@@ -1989,10 +1990,10 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
1989
1990
|
var m = () => Ea;
|
|
1990
1991
|
var k = 1;
|
|
1991
1992
|
} else {
|
|
1992
|
-
4 === a && (d = sc, e = tc, f = uc, m = () =>
|
|
1993
|
+
4 === a && (d = sc, e = tc, f = uc, m = () => L, k = 2);
|
|
1993
1994
|
}
|
|
1994
1995
|
Ib(b, {name:c, fromWireType:function(n) {
|
|
1995
|
-
for (var l =
|
|
1996
|
+
for (var l = L[n >> 2], t = m(), w, x = n + 4, g = 0; g <= l; ++g) {
|
|
1996
1997
|
var r = n + 4 + g * a;
|
|
1997
1998
|
if (g == l || 0 == t[r >> k]) {
|
|
1998
1999
|
x = d(x, r - x), void 0 === w ? w = x : (w += String.fromCharCode(0), w += x), x = r + a;
|
|
@@ -2003,7 +2004,7 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
2003
2004
|
}, toWireType:function(n, l) {
|
|
2004
2005
|
"string" != typeof l && Q(`Cannot pass non-string to C++ string type ${c}`);
|
|
2005
2006
|
var t = f(l), w = Mc(4 + t + a);
|
|
2006
|
-
|
|
2007
|
+
L[w >> 2] = t >> k;
|
|
2007
2008
|
e(l, w + 4, t + a);
|
|
2008
2009
|
null !== n && n.push(mb, w);
|
|
2009
2010
|
return w;
|
|
@@ -2011,9 +2012,9 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
2011
2012
|
mb(n);
|
|
2012
2013
|
},});
|
|
2013
2014
|
}, _embind_register_value_object:function(b, a, c, d, e, f) {
|
|
2014
|
-
Db[b] = {name:U(a), fa:
|
|
2015
|
+
Db[b] = {name:U(a), fa:X(c, d), H:X(e, f), sa:[],};
|
|
2015
2016
|
}, _embind_register_value_object_field:function(b, a, c, d, e, f, m, k, n, l) {
|
|
2016
|
-
Db[b].sa.push({Sa:U(a), Ya:c, Wa:
|
|
2017
|
+
Db[b].sa.push({Sa:U(a), Ya:c, Wa:X(d, e), Xa:f, lb:m, kb:X(k, n), mb:l,});
|
|
2017
2018
|
}, _embind_register_void:function(b, a) {
|
|
2018
2019
|
a = U(a);
|
|
2019
2020
|
Ib(b, {cb:!0, name:a, argPackAdvance:0, fromWireType:function() {
|
|
@@ -2023,14 +2024,14 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
2023
2024
|
b = R(b);
|
|
2024
2025
|
a = nb(a, "emval::as");
|
|
2025
2026
|
var d = [], e = S(d);
|
|
2026
|
-
|
|
2027
|
+
L[c >> 2] = e;
|
|
2027
2028
|
return a.toWireType(d, b);
|
|
2028
2029
|
}, _emval_call_method:function(b, a, c, d, e) {
|
|
2029
2030
|
b = xc[b];
|
|
2030
2031
|
a = R(a);
|
|
2031
2032
|
c = wc(c);
|
|
2032
2033
|
var f = [];
|
|
2033
|
-
|
|
2034
|
+
L[d >> 2] = S(f);
|
|
2034
2035
|
return b(a, c, f, e);
|
|
2035
2036
|
}, _emval_call_void_method:function(b, a, c, d) {
|
|
2036
2037
|
b = xc[b];
|
|
@@ -2123,7 +2124,7 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
2123
2124
|
var c = 0;
|
|
2124
2125
|
Dc().forEach(function(d, e) {
|
|
2125
2126
|
var f = a + c;
|
|
2126
|
-
e =
|
|
2127
|
+
e = L[b + 4 * e >> 2] = f;
|
|
2127
2128
|
for (f = 0; f < d.length; ++f) {
|
|
2128
2129
|
Ca[e++ >> 0] = d.charCodeAt(f);
|
|
2129
2130
|
}
|
|
@@ -2133,18 +2134,18 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
2133
2134
|
return 0;
|
|
2134
2135
|
}, environ_sizes_get:(b, a) => {
|
|
2135
2136
|
var c = Dc();
|
|
2136
|
-
|
|
2137
|
+
L[b >> 2] = c.length;
|
|
2137
2138
|
var d = 0;
|
|
2138
2139
|
c.forEach(function(e) {
|
|
2139
2140
|
d += e.length + 1;
|
|
2140
2141
|
});
|
|
2141
|
-
|
|
2142
|
+
L[a >> 2] = d;
|
|
2142
2143
|
return 0;
|
|
2143
2144
|
}, fd_close:() => 52, fd_seek:function() {
|
|
2144
2145
|
return 70;
|
|
2145
2146
|
}, fd_write:(b, a, c, d) => {
|
|
2146
2147
|
for (var e = 0, f = 0; f < c; f++) {
|
|
2147
|
-
var m =
|
|
2148
|
+
var m = L[a >> 2], k = L[a + 4 >> 2];
|
|
2148
2149
|
a += 8;
|
|
2149
2150
|
for (var n = 0; n < k; n++) {
|
|
2150
2151
|
var l = J[m + n], t = Ec[b];
|
|
@@ -2152,7 +2153,7 @@ var Nc = {_embind_create_inheriting_constructor:function(b, a, c) {
|
|
|
2152
2153
|
}
|
|
2153
2154
|
e += k;
|
|
2154
2155
|
}
|
|
2155
|
-
|
|
2156
|
+
L[d >> 2] = e;
|
|
2156
2157
|
return 0;
|
|
2157
2158
|
}, strftime_l:(b, a, c, d) => Jc(b, a, c, d)};
|
|
2158
2159
|
(function() {
|
package/package.json
CHANGED
package/rive.wasm
CHANGED
|
Binary file
|
package/rive_advanced.mjs.d.ts
CHANGED
|
@@ -928,6 +928,7 @@ export declare class ViewModelInstanceList extends ViewModelInstanceValue {
|
|
|
928
928
|
removeInstance(vmi: ViewModelInstance): void;
|
|
929
929
|
removeInstanceAt(index: number): void;
|
|
930
930
|
instanceAt(index: number): ViewModelInstance;
|
|
931
|
+
swap(a: number, b: number): ViewModelInstance;
|
|
931
932
|
}
|
|
932
933
|
export declare class ViewModelInstanceAssetImage extends ViewModelInstanceValue {
|
|
933
934
|
value(image: ImageInternal):void;
|
package/rive_fallback.wasm
CHANGED
|
Binary file
|