mirror of
https://github.com/SillyTavern/SillyTavern.git
synced 2025-06-05 21:59:27 +02:00
Add / Update talking lips animations
This commit is contained in:
@ -9,6 +9,7 @@ import { SystemTtsProvider } from './system.js'
|
||||
import { NovelTtsProvider } from './novel.js'
|
||||
import { power_user } from '../../power-user.js'
|
||||
import { rvcVoiceConversion } from "../rvc/index.js"
|
||||
export { talkingAnimation };
|
||||
|
||||
const UPDATE_INTERVAL = 1000
|
||||
|
||||
@ -177,6 +178,7 @@ function talkingAnimation(switchValue) {
|
||||
// Handle the error here or simply ignore it to prevent logging
|
||||
}
|
||||
}
|
||||
updateUiAudioPlayState()
|
||||
}
|
||||
|
||||
function resetTtsPlayback() {
|
||||
@ -305,10 +307,8 @@ function updateUiAudioPlayState() {
|
||||
// Give user feedback that TTS is active by setting the stop icon if processing or playing
|
||||
if (!audioElement.paused || isTtsProcessing()) {
|
||||
img = 'fa-solid fa-stop-circle extensionsMenuExtensionButton'
|
||||
talkingAnimation(true)
|
||||
} else {
|
||||
img = 'fa-solid fa-circle-play extensionsMenuExtensionButton'
|
||||
talkingAnimation(false)
|
||||
}
|
||||
$('#tts_media_control').attr('class', img);
|
||||
} else {
|
||||
@ -345,6 +345,7 @@ function completeCurrentAudioJob() {
|
||||
audioQueueProcessorReady = true
|
||||
currentAudioJob = null
|
||||
lastAudioPosition = 0
|
||||
talkingAnimation(false) //stop lip animation
|
||||
// updateUiPlayState();
|
||||
}
|
||||
|
||||
|
Reference in New Issue
Block a user