Convert audio to 8kHz before feeding it to WebRTC for VAC
This prevents false positives at the beginning of the audio stream. Fixes issue #52.
This commit is contained in:
parent
10632576bd
commit
a723942f22
|
@ -3,6 +3,7 @@
|
|||
## Unreleased
|
||||
|
||||
* **Added** basic support for non-English recordings through phonetic recognition ([issue #45](https://github.com/DanielSWolf/rhubarb-lip-sync/issues/45)).
|
||||
* **Fixed** a bug that resulted in unwanted mouth movement at beginning of a recording ([issue #53](https://github.com/DanielSWolf/rhubarb-lip-sync/issues/53)).
|
||||
* **Fixed** a bug that prevented the progress bar from reaching 100% ([issue #48](https://github.com/DanielSWolf/rhubarb-lip-sync/issues/48)).
|
||||
|
||||
## Version 1.8.0
|
||||
|
|
|
@ -83,7 +83,7 @@ JoiningBoundedTimeline<void> detectVoiceActivity(
|
|||
) {
|
||||
// Prepare audio for VAD
|
||||
const unique_ptr<AudioClip> audioClip = inputAudioClip.clone()
|
||||
| resample(16000)
|
||||
| resample(8000) // Convert to the internal sampling rate of WebRTC
|
||||
| removeDcOffset();
|
||||
|
||||
JoiningBoundedTimeline<void> activity(audioClip->getTruncatedRange());
|
||||
|
|
Loading…
Reference in New Issue