Merge from main (#113)

This commit is contained in:
kwaroran
2023-05-26 20:30:43 +09:00
committed by GitHub
2 changed files with 1 additions and 4 deletions

View File

@@ -495,7 +495,7 @@
<select class="bg-transparent input-text mt-2 mb-4 text-gray-200 appearance-none text-sm" bind:value={currentChar.data.ttsSpeech}>
{#await getVOICEVOXVoices() then voices}
{#each voices as voice}
<option value={voice.id} class="bg-darkbg appearance-none">{voice.name}</option>
<option value={voice.id} class="bg-darkbg appearance-none" selected={currentChar.data.ttsSpeech === voice.id}>{voice.name}</option>
{/each}
{/await}
</select>

View File

@@ -61,7 +61,6 @@ export async function sayTTS(character:character,text:string) {
}
case "VOICEVOX": {
const jpText = await translateVox(text)
console.log(jpText);
const audioContext = new AudioContext();
const query = await fetch(`${db.voicevoxUrl}/audio_query?text=${jpText}&speaker=${character.ttsSpeech}`, {
method: 'POST',
@@ -81,8 +80,6 @@ export async function sayTTS(character:character,text:string) {
outputStereo: queryJson.outputStereo,
kana: queryJson.kana,
}
console.log(JSON.stringify(bodyData))
console.log (bodyData)
const getVoice = await fetch(`${db.voicevoxUrl}/synthesis?speaker=${character.ttsSpeech}`, {
method: 'POST',
headers: { "Content-Type": "application/json"},