Add local MeloTTS support
This commit is contained in:
@@ -55,6 +55,15 @@ export class RealtimeSegmenter {
|
||||
}
|
||||
}
|
||||
|
||||
reset(): void {
|
||||
this.pendingSamples.splice(0, this.pendingSamples.length);
|
||||
this.preRoll.splice(0, this.preRoll.length);
|
||||
this.speech.splice(0, this.speech.length);
|
||||
this.speechActive = false;
|
||||
this.speechCandidateFrames = 0;
|
||||
this.silenceFrames = 0;
|
||||
}
|
||||
|
||||
private processFrame(frame: Int16Array): void {
|
||||
let peak = 0;
|
||||
for (const sample of frame) {
|
||||
|
||||
Reference in New Issue
Block a user