Commit b31a24e1 authored by jwendt's avatar jwendt
Browse files

audiofile resampling and minor bugfix in TTS

parent c587eedc
......@@ -7,6 +7,7 @@
#include <ITAException.h>
#include <ITABufferDataSource.h>
#include <ITASampleFrame.h>
#include <ITAAudioSample.h>
#include <sstream>
#include <assert.h>
......@@ -43,7 +44,8 @@ CVAAudiofileSignalSource::CVAAudiofileSignalSource( const std::string& sFileName
{
m_sbOutBuffer.Init( iBlockLength, true );
ITASampleFrame sfFileBuffer( sFileName );
CITAAudioSample sfFileBuffer(dSampleRate);
sfFileBuffer.LoadWithSampleRateConversion(sFileName);
std::vector< float* > vfBufferPointer;
......
......@@ -420,7 +420,7 @@ void CVATextToSpeechSignalSource::VisemeProcessing(CPRC_abuf * abuf, void * user
VA_INFO("CVATextToSpeechSignalSource", "ERROR: could not retrieve transcription at "+ std::to_string(i));
}
}
data->lastEnd = endTime;
data->lastEnd += endTime;
//we basically append the data in abuf to the data in floatBuffer and on the way convert it from short to float (since that's what we need for the SoundSignal)
std::size_t bufferLength = CPRC_abuf_wav_sz(abuf);
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment