@inupedia/spotlight-vue 0.8.6 → 0.9.0
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/dist/assets/spotlight-vue.css +1 -1
- package/dist/avatar/speech/live2dTtsPlayback.d.ts +15 -2
- package/dist/avatar/speech/live2dTtsPlayback.d.ts.map +1 -1
- package/dist/avatar/speech/live2dTtsPlayback.js +77 -15
- package/dist/avatar/speech/spotlightSpeech.d.ts.map +1 -1
- package/dist/avatar/speech/spotlightSpeech.js +44 -36
- package/dist/avatar/spine/live2dApp.d.ts +3 -0
- package/dist/avatar/spine/live2dApp.d.ts.map +1 -1
- package/dist/avatar/spine/live2dApp.js +30 -18
- package/dist/avatar/spine/spineAvatar.d.ts +4 -0
- package/dist/avatar/spine/spineAvatar.d.ts.map +1 -1
- package/dist/avatar/spine/spineAvatar.js +114 -83
- package/dist/avatar/spine/spineLipSync.d.ts +1 -0
- package/dist/avatar/spine/spineLipSync.d.ts.map +1 -1
- package/dist/avatar/spine/spineLipSync.js +41 -36
- package/dist/avatar/voice/avatarDirector.d.ts +8 -0
- package/dist/avatar/voice/avatarDirector.d.ts.map +1 -0
- package/dist/avatar/voice/avatarDirector.js +6 -0
- package/dist/avatar/voice/config.d.ts +5 -0
- package/dist/avatar/voice/config.d.ts.map +1 -0
- package/dist/avatar/voice/config.js +5 -0
- package/dist/avatar/voice/panelHidePolicy.d.ts +6 -0
- package/dist/avatar/voice/panelHidePolicy.d.ts.map +1 -0
- package/dist/avatar/voice/panelHidePolicy.js +6 -0
- package/dist/avatar/voice/voiceSession.d.ts +5 -0
- package/dist/avatar/voice/voiceSession.d.ts.map +1 -0
- package/dist/avatar/voice/voiceSession.js +14 -0
- package/dist/components/Live2dPanel.vue.d.ts.map +1 -1
- package/dist/components/Live2dPanel.vue.js +2 -2
- package/dist/components/SpotlightShell.vue.d.ts.map +1 -1
- package/dist/components/SpotlightShell.vue.js +1 -1
- package/dist/components/SpotlightShell2.vue.js +290 -200
- package/dist/config.d.ts +3 -0
- package/dist/config.d.ts.map +1 -1
- package/dist/index.d.ts +1 -0
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +24 -22
- package/dist/mountShell.d.ts.map +1 -1
- package/dist/mountShell.js +13 -10
- package/dist/plugin.js +1 -1
- package/dist/remote/audio.d.ts.map +1 -1
- package/dist/remote/audio.js +19 -18
- package/dist/remote/runPipeline.d.ts +1 -0
- package/dist/remote/runPipeline.d.ts.map +1 -1
- package/dist/remote/runPipeline.js +83 -96
- package/dist/store/live2dSpeechStore.d.ts +2 -2
- package/dist/store/memoryPreferenceStore.d.ts +1 -1
- package/dist/store/runtime/types.d.ts +1 -1
- package/dist/store/runtime/types.d.ts.map +1 -1
- package/dist/store/spotlightStore.d.ts +10 -10
- package/package.json +3 -3
|
@@ -1,100 +1,131 @@
|
|
|
1
|
-
import { Application as
|
|
2
|
-
import { Spine as
|
|
3
|
-
import { buildWavEnvelope as
|
|
4
|
-
import { resolveAvatarSkeletonUrl as
|
|
5
|
-
const
|
|
6
|
-
let
|
|
7
|
-
function
|
|
8
|
-
|
|
9
|
-
}
|
|
10
|
-
let
|
|
11
|
-
function
|
|
12
|
-
|
|
13
|
-
}
|
|
14
|
-
let
|
|
15
|
-
function
|
|
16
|
-
if (!
|
|
17
|
-
const i =
|
|
18
|
-
if (!
|
|
19
|
-
const
|
|
20
|
-
|
|
21
|
-
}
|
|
22
|
-
function C() {
|
|
23
|
-
if (!t || !c || !s || s.ended) return;
|
|
24
|
-
const e = s.currentTime * 1e3, n = E(c, e);
|
|
25
|
-
H(_, O(n));
|
|
1
|
+
import { Application as _, Assets as E } from "pixi.js";
|
|
2
|
+
import { Spine as C } from "@pixi-spine/all-3.8";
|
|
3
|
+
import { buildWavEnvelope as D, envelopeLevelAt as H, mouthAttachmentForLevel as M, MOUTH_SLOT as b } from "./spineLipSync.js";
|
|
4
|
+
import { resolveAvatarSkeletonUrl as z } from "../config.js";
|
|
5
|
+
const h = "idle", v = "hello", k = "mouth_smile";
|
|
6
|
+
let I;
|
|
7
|
+
function V(t) {
|
|
8
|
+
I = t;
|
|
9
|
+
}
|
|
10
|
+
let S = !1, p = null;
|
|
11
|
+
function O() {
|
|
12
|
+
p != null && (window.clearTimeout(p), p = null);
|
|
13
|
+
}
|
|
14
|
+
let o = null, e = null, a = null, A = null, w = !1, f = !1, c = null, d = null, r = null, u = null;
|
|
15
|
+
function U(t, n) {
|
|
16
|
+
if (!e) return;
|
|
17
|
+
const i = e.skeleton, l = i.findSlot(t);
|
|
18
|
+
if (!l) return;
|
|
19
|
+
const s = i.getAttachment(l.data.index, n);
|
|
20
|
+
l.setAttachment(s ?? null);
|
|
26
21
|
}
|
|
27
|
-
function
|
|
28
|
-
|
|
22
|
+
function N() {
|
|
23
|
+
if (!e) return;
|
|
24
|
+
if (r) {
|
|
25
|
+
const i = new Uint8Array(r.fftSize);
|
|
26
|
+
r.getByteTimeDomainData(i);
|
|
27
|
+
let l = 0;
|
|
28
|
+
for (const y of i) {
|
|
29
|
+
const m = (y - 128) / 128;
|
|
30
|
+
l += m * m;
|
|
31
|
+
}
|
|
32
|
+
const s = Math.min(1, Math.sqrt(l / i.length) * 4);
|
|
33
|
+
U(b, M(s));
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
if (!c || !d) return;
|
|
37
|
+
const t = d(), n = H(c, t);
|
|
38
|
+
U(b, M(n));
|
|
39
|
+
}
|
|
40
|
+
function T() {
|
|
41
|
+
e?.state.hasAnimation(k) && e.state.setAnimation(1, k, !0);
|
|
29
42
|
}
|
|
30
43
|
function L() {
|
|
31
|
-
|
|
32
|
-
}
|
|
33
|
-
function
|
|
34
|
-
|
|
35
|
-
}
|
|
36
|
-
function
|
|
37
|
-
if (!
|
|
38
|
-
|
|
39
|
-
const
|
|
40
|
-
|
|
41
|
-
const n =
|
|
42
|
-
|
|
43
|
-
|
|
44
|
+
e && e.state.setEmptyAnimation(1, 0);
|
|
45
|
+
}
|
|
46
|
+
function R() {
|
|
47
|
+
e && (e.state.hasAnimation(h) && e.state.setAnimation(0, h, !0), T());
|
|
48
|
+
}
|
|
49
|
+
function X() {
|
|
50
|
+
if (!e?.state.hasAnimation(v) || S) return;
|
|
51
|
+
O(), S = !0;
|
|
52
|
+
const t = e.state;
|
|
53
|
+
t.setAnimation(0, v, !1), t.hasAnimation(h) && t.addAnimation(0, h, !0, 0), f ? L() : T(), e.update(0);
|
|
54
|
+
const n = t.data.skeletonData.findAnimation(v), i = n ? (n.duration + 0.15) * 1e3 : 2500;
|
|
55
|
+
p = window.setTimeout(() => {
|
|
56
|
+
S = !1, p = null;
|
|
44
57
|
}, i);
|
|
45
58
|
}
|
|
46
|
-
function N() {
|
|
47
|
-
if (!t || A) return;
|
|
48
|
-
const e = t.update.bind(t);
|
|
49
|
-
t.update = (n) => {
|
|
50
|
-
e(n), !(!m || !c || !s) && (C(), e(0));
|
|
51
|
-
}, A = !0;
|
|
52
|
-
}
|
|
53
|
-
const R = "shuidi_17";
|
|
54
59
|
function W() {
|
|
55
|
-
if (!
|
|
56
|
-
const
|
|
57
|
-
e
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
const
|
|
60
|
+
if (!e || w) return;
|
|
61
|
+
const t = e.update.bind(e);
|
|
62
|
+
e.update = (n) => {
|
|
63
|
+
t(n), f && (!r && (!c || !d) || (N(), t(0)));
|
|
64
|
+
}, w = !0;
|
|
65
|
+
}
|
|
66
|
+
const B = "shuidi_17";
|
|
67
|
+
function G() {
|
|
68
|
+
if (!e) return;
|
|
69
|
+
const t = e.skeleton.findSlot(B);
|
|
70
|
+
t && t.setAttachment(null);
|
|
71
|
+
}
|
|
72
|
+
function x() {
|
|
73
|
+
if (!e || !a) return;
|
|
74
|
+
const { clientWidth: t, clientHeight: n } = a;
|
|
75
|
+
if (t <= 0 || n <= 0) return;
|
|
76
|
+
e.scale.set(1), e.position.set(0, 0), e.update(0);
|
|
77
|
+
const i = e.getLocalBounds();
|
|
65
78
|
if (i.width <= 0 || i.height <= 0) return;
|
|
66
|
-
const
|
|
67
|
-
|
|
79
|
+
const l = 0.9, s = Math.min(t * l / i.width, n * l / i.height), y = i.x + i.width / 2, m = i.y + i.height / 2;
|
|
80
|
+
e.scale.set(s), e.position.set(t / 2 - y * s, n / 2 - m * s);
|
|
68
81
|
}
|
|
69
|
-
async function
|
|
70
|
-
if (
|
|
71
|
-
|
|
82
|
+
async function Y() {
|
|
83
|
+
if (a = document.getElementById("live2d-container"), !a || o) return;
|
|
84
|
+
o = new _({
|
|
72
85
|
backgroundAlpha: 0,
|
|
73
86
|
antialias: !0,
|
|
74
|
-
resizeTo:
|
|
75
|
-
}),
|
|
76
|
-
const
|
|
77
|
-
|
|
87
|
+
resizeTo: a
|
|
88
|
+
}), a.appendChild(o.view);
|
|
89
|
+
const t = await E.load(z(I));
|
|
90
|
+
e = new C(t.spineData), e.autoUpdate = !0, W(), o.stage.addChild(e), G(), R(), e.update(0), x(), A = new ResizeObserver(() => x()), A.observe(a);
|
|
78
91
|
}
|
|
79
|
-
function
|
|
80
|
-
|
|
92
|
+
function Z() {
|
|
93
|
+
P(), O(), S = !1, A?.disconnect(), A = null, w = !1, e && o && (o.stage.removeChild(e), e.destroy({ children: !0 }), e = null), o && (o.destroy(!0, { children: !0, texture: !0, baseTexture: !0 }), o = null), a = null, E.reset();
|
|
81
94
|
}
|
|
82
|
-
function
|
|
83
|
-
|
|
95
|
+
function q(t, n) {
|
|
96
|
+
e && (g(), d = t, c = n, L(), f = !0, e.update(0));
|
|
97
|
+
}
|
|
98
|
+
function F(t, n) {
|
|
99
|
+
q(() => t.currentTime * 1e3, n);
|
|
100
|
+
}
|
|
101
|
+
function $(t) {
|
|
102
|
+
if (!e) return;
|
|
103
|
+
g(), d = null, c = null;
|
|
104
|
+
const n = new AudioContext(), i = n.createMediaStreamSource(t), l = n.createAnalyser();
|
|
105
|
+
l.fftSize = 1024, i.connect(l), u = n, r = l, n.resume(), L(), f = !0, e.update(0);
|
|
106
|
+
}
|
|
107
|
+
async function ee() {
|
|
108
|
+
u?.state === "suspended" && await u.resume();
|
|
109
|
+
}
|
|
110
|
+
function g() {
|
|
111
|
+
r = null, u && (u.close(), u = null);
|
|
84
112
|
}
|
|
85
|
-
async function
|
|
86
|
-
const i = await
|
|
87
|
-
|
|
113
|
+
async function te(t, n) {
|
|
114
|
+
const i = await D(n);
|
|
115
|
+
F(t, i);
|
|
88
116
|
}
|
|
89
|
-
function
|
|
90
|
-
|
|
117
|
+
function P() {
|
|
118
|
+
f = !1, c = null, d = null, g(), T(), e?.update(0);
|
|
91
119
|
}
|
|
92
120
|
export {
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
q as
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
121
|
+
F as bindSpineLipSyncToAudio,
|
|
122
|
+
te as bindSpineLipSyncToAudioUrl,
|
|
123
|
+
q as bindSpineLipSyncToClock,
|
|
124
|
+
$ as bindSpineLipSyncToMediaStream,
|
|
125
|
+
V as configureSpineAvatar,
|
|
126
|
+
X as playSpineHello,
|
|
127
|
+
ee as resumeSpineLipSyncAudio,
|
|
128
|
+
Y as startSpineAvatar,
|
|
129
|
+
Z as stopSpineAvatar,
|
|
130
|
+
P as stopSpineLipSync
|
|
100
131
|
};
|
|
@@ -7,6 +7,7 @@ export type WavEnvelope = {
|
|
|
7
7
|
levels: number[];
|
|
8
8
|
};
|
|
9
9
|
export declare function buildWavEnvelope(wavUrl: string): Promise<WavEnvelope>;
|
|
10
|
+
export declare function wavEnvelopeFromAudioBuffer(audioBuffer: AudioBuffer): WavEnvelope;
|
|
10
11
|
export declare function buildWavEnvelopeFromBlob(blob: Blob): Promise<WavEnvelope>;
|
|
11
12
|
export declare function envelopeLevelAt(envelope: WavEnvelope, elapsedMs: number): number;
|
|
12
13
|
export declare function mouthAttachmentForLevel(level: number): string;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"spineLipSync.d.ts","sourceRoot":"","sources":["../../../src/avatar/spine/spineLipSync.ts"],"names":[],"mappings":"AAAA,0CAA0C;AAC1C,eAAO,MAAM,UAAU,aAAa,CAAC;AACrC,eAAO,MAAM,WAAW,aAAa,CAAC;AACtC,eAAO,MAAM,iBAAiB,2DAA4D,CAAC;AAI3F,MAAM,MAAM,WAAW,GAAG;IACxB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,MAAM,EAAE,CAAC;CAClB,CAAC;AAEF,wBAAsB,gBAAgB,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC,CAG3E;AAED,wBAAsB,wBAAwB,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,WAAW,CAAC,
|
|
1
|
+
{"version":3,"file":"spineLipSync.d.ts","sourceRoot":"","sources":["../../../src/avatar/spine/spineLipSync.ts"],"names":[],"mappings":"AAAA,0CAA0C;AAC1C,eAAO,MAAM,UAAU,aAAa,CAAC;AACrC,eAAO,MAAM,WAAW,aAAa,CAAC;AACtC,eAAO,MAAM,iBAAiB,2DAA4D,CAAC;AAI3F,MAAM,MAAM,WAAW,GAAG;IACxB,UAAU,EAAE,MAAM,CAAC;IACnB,MAAM,EAAE,MAAM,EAAE,CAAC;CAClB,CAAC;AAEF,wBAAsB,gBAAgB,CAAC,MAAM,EAAE,MAAM,GAAG,OAAO,CAAC,WAAW,CAAC,CAG3E;AAED,wBAAgB,0BAA0B,CAAC,WAAW,EAAE,WAAW,GAAG,WAAW,CAqBhF;AAED,wBAAsB,wBAAwB,CAAC,IAAI,EAAE,IAAI,GAAG,OAAO,CAAC,WAAW,CAAC,CAS/E;AAED,wBAAgB,eAAe,CAC7B,QAAQ,EAAE,WAAW,EACrB,SAAS,EAAE,MAAM,GAChB,MAAM,CAKR;AAED,wBAAgB,uBAAuB,CAAC,KAAK,EAAE,MAAM,GAAG,MAAM,CAO7D"}
|
|
@@ -1,47 +1,52 @@
|
|
|
1
|
-
const
|
|
2
|
-
async function
|
|
3
|
-
const
|
|
4
|
-
return
|
|
1
|
+
const m = "shuidi_0", l = ["shuidi_3", "shuidi_2", "shuidi_1", "shuidi_0"];
|
|
2
|
+
async function _(t) {
|
|
3
|
+
const n = await fetch(t);
|
|
4
|
+
return d(await n.blob());
|
|
5
5
|
}
|
|
6
|
-
|
|
7
|
-
const
|
|
8
|
-
|
|
9
|
-
const
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
const f = s[l];
|
|
15
|
-
h += f * f;
|
|
16
|
-
}
|
|
17
|
-
i.push(Math.sqrt(h / (u - o)));
|
|
6
|
+
function f(t) {
|
|
7
|
+
const n = t.getChannelData(0), e = t.sampleRate, a = Math.max(1, Math.floor(e * 50 / 1e3)), s = [];
|
|
8
|
+
for (let o = 0; o < n.length; o += a) {
|
|
9
|
+
const c = Math.min(o + a, n.length);
|
|
10
|
+
let r = 0;
|
|
11
|
+
for (let i = o; i < c; i += 1) {
|
|
12
|
+
const u = n[i];
|
|
13
|
+
r += u * u;
|
|
18
14
|
}
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
15
|
+
s.push(Math.sqrt(r / (c - o)));
|
|
16
|
+
}
|
|
17
|
+
const h = Math.max(...s, 1e-4);
|
|
18
|
+
return {
|
|
19
|
+
durationMs: t.duration * 1e3,
|
|
20
|
+
levels: s.map((o) => Math.min(1, o / h))
|
|
21
|
+
};
|
|
22
|
+
}
|
|
23
|
+
async function d(t) {
|
|
24
|
+
const n = await t.arrayBuffer(), e = new AudioContext();
|
|
25
|
+
try {
|
|
26
|
+
const a = await e.decodeAudioData(n.slice(0));
|
|
27
|
+
return f(a);
|
|
24
28
|
} finally {
|
|
25
|
-
|
|
29
|
+
e.close();
|
|
26
30
|
}
|
|
27
31
|
}
|
|
28
|
-
function
|
|
29
|
-
if (
|
|
30
|
-
const
|
|
31
|
-
return
|
|
32
|
+
function M(t, n) {
|
|
33
|
+
if (n < 0) return 0;
|
|
34
|
+
const e = Math.floor(n / 50);
|
|
35
|
+
return e >= t.levels.length ? 0 : t.levels[e] ?? 0;
|
|
32
36
|
}
|
|
33
37
|
function v(t) {
|
|
34
|
-
const
|
|
35
|
-
|
|
36
|
-
Math.floor(
|
|
38
|
+
const n = Math.max(0, Math.min(1, t)), e = Math.min(
|
|
39
|
+
l.length - 1,
|
|
40
|
+
Math.floor(n * l.length)
|
|
37
41
|
);
|
|
38
|
-
return
|
|
42
|
+
return l[e];
|
|
39
43
|
}
|
|
40
44
|
export {
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
v as mouthAttachmentForLevel
|
|
45
|
+
l as MOUTH_OPEN_LEVELS,
|
|
46
|
+
m as MOUTH_SLOT,
|
|
47
|
+
_ as buildWavEnvelope,
|
|
48
|
+
d as buildWavEnvelopeFromBlob,
|
|
49
|
+
M as envelopeLevelAt,
|
|
50
|
+
v as mouthAttachmentForLevel,
|
|
51
|
+
f as wavEnvelopeFromAudioBuffer
|
|
47
52
|
};
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { SpotlightVoicePhase } from "@inupedia/spotlight-protocol";
|
|
2
|
+
export declare function directorPhaseFromTurn(input: {
|
|
3
|
+
loading: boolean;
|
|
4
|
+
speaking: boolean;
|
|
5
|
+
toolRunning: boolean;
|
|
6
|
+
interrupted?: boolean;
|
|
7
|
+
}): SpotlightVoicePhase;
|
|
8
|
+
//# sourceMappingURL=avatarDirector.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"avatarDirector.d.ts","sourceRoot":"","sources":["../../../src/avatar/voice/avatarDirector.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,mBAAmB,EAAE,MAAM,8BAA8B,CAAC;AAExE,wBAAgB,qBAAqB,CAAC,KAAK,EAAE;IAC3C,OAAO,EAAE,OAAO,CAAC;IACjB,QAAQ,EAAE,OAAO,CAAC;IAClB,WAAW,EAAE,OAAO,CAAC;IACrB,WAAW,CAAC,EAAE,OAAO,CAAC;CACvB,GAAG,mBAAmB,CAMtB"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import { type InjectionKey } from "vue";
|
|
2
|
+
import type { SpotlightVoiceConfig } from "@inupedia/spotlight-protocol";
|
|
3
|
+
export declare const SPOTLIGHT_VOICE_CONFIG_KEY: InjectionKey<SpotlightVoiceConfig>;
|
|
4
|
+
export declare function useSpotlightVoiceConfig(): SpotlightVoiceConfig;
|
|
5
|
+
//# sourceMappingURL=config.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../../src/avatar/voice/config.ts"],"names":[],"mappings":"AAAA,OAAO,EAAU,KAAK,YAAY,EAAE,MAAM,KAAK,CAAC;AAChD,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AAEzE,eAAO,MAAM,0BAA0B,EAAE,YAAY,CAAC,oBAAoB,CACxC,CAAC;AAEnC,wBAAgB,uBAAuB,IAAI,oBAAoB,CAE9D"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"panelHidePolicy.d.ts","sourceRoot":"","sources":["../../../src/avatar/voice/panelHidePolicy.ts"],"names":[],"mappings":"AAAA,uFAAuF;AACvF,wBAAgB,2BAA2B,CAAC,KAAK,EAAE;IACjD,OAAO,EAAE,OAAO,CAAC;IACjB,aAAa,EAAE,MAAM,CAAC;CACvB,GAAG,OAAO,CAEV"}
|
|
@@ -0,0 +1,5 @@
|
|
|
1
|
+
import type { SpotlightVoiceConfig } from "@inupedia/spotlight-protocol";
|
|
2
|
+
export declare function unlockVoicePlayback(): Promise<void>;
|
|
3
|
+
export declare function describeMicrophoneError(error: unknown): string;
|
|
4
|
+
export declare function voiceConfigEnabled(config?: SpotlightVoiceConfig): boolean;
|
|
5
|
+
//# sourceMappingURL=voiceSession.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"voiceSession.d.ts","sourceRoot":"","sources":["../../../src/avatar/voice/voiceSession.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,oBAAoB,EAAE,MAAM,8BAA8B,CAAC;AAEzE,wBAAsB,mBAAmB,IAAI,OAAO,CAAC,IAAI,CAAC,CAWzD;AAED,wBAAgB,uBAAuB,CAAC,KAAK,EAAE,OAAO,GAAG,MAAM,CAgB9D;AAED,wBAAgB,kBAAkB,CAAC,MAAM,CAAC,EAAE,oBAAoB,GAAG,OAAO,CAEzE"}
|
|
@@ -0,0 +1,14 @@
|
|
|
1
|
+
async function e() {
|
|
2
|
+
const o = globalThis.AudioContext ?? globalThis.webkitAudioContext;
|
|
3
|
+
if (!o) return;
|
|
4
|
+
const t = new o();
|
|
5
|
+
try {
|
|
6
|
+
t.state === "suspended" && await t.resume();
|
|
7
|
+
} finally {
|
|
8
|
+
await t.close().catch(() => {
|
|
9
|
+
});
|
|
10
|
+
}
|
|
11
|
+
}
|
|
12
|
+
export {
|
|
13
|
+
e as unlockVoicePlayback
|
|
14
|
+
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"Live2dPanel.vue.d.ts","sourceRoot":"","sources":["../../src/components/Live2dPanel.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"Live2dPanel.vue.d.ts","sourceRoot":"","sources":["../../src/components/Live2dPanel.vue"],"names":[],"mappings":"AA6bA,KAAK,WAAW,GAAG;IACf,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,UAAU,CAAC,EAAE,MAAM,CAAC;CACrB,CAAC;AA8PJ,QAAA,MAAM,YAAY;;;;;;;;;mBAhQE,OAAO;gBACV,MAAM;6EAmQrB,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./Live2dPanel2.vue.js";
|
|
2
2
|
/* empty css */
|
|
3
|
-
import
|
|
4
|
-
const m = /* @__PURE__ */
|
|
3
|
+
import t from "../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
+
const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-ca5091e3"]]);
|
|
5
5
|
export {
|
|
6
6
|
m as default
|
|
7
7
|
};
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"SpotlightShell.vue.d.ts","sourceRoot":"","sources":["../../src/components/SpotlightShell.vue"],"names":[],"mappings":"
|
|
1
|
+
{"version":3,"file":"SpotlightShell.vue.d.ts","sourceRoot":"","sources":["../../src/components/SpotlightShell.vue"],"names":[],"mappings":"AA00BA,KAAK,WAAW,GAAG;IAAE,aAAa,CAAC,EAAE,OAAO,CAAA;CAAE,CAAC;AAqyB/C,QAAA,MAAM,YAAY;mBAryBmB,OAAO;6EAwyB1C,CAAC;wBACkB,OAAO,YAAY;AAAxC,wBAAyC"}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import o from "./SpotlightShell2.vue.js";
|
|
2
2
|
/* empty css */
|
|
3
3
|
import t from "../_virtual/_plugin-vue_export-helper.js";
|
|
4
|
-
const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-
|
|
4
|
+
const m = /* @__PURE__ */ t(o, [["__scopeId", "data-v-826535e7"]]);
|
|
5
5
|
export {
|
|
6
6
|
m as default
|
|
7
7
|
};
|