Skip to content

Commit

Permalink
Merge pull request mmorise#28 from brunexgeek/init_fix
Browse files Browse the repository at this point in the history
Fix initialization at 'GetTemporalParametersForTimeBase' function
  • Loading branch information
mmorise authored Apr 2, 2017
2 parents 30d52ab + e5572d6 commit c80d74a
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion src/synthesis.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -186,7 +186,8 @@ static void GetTemporalParametersForTimeBase(const double *f0, int f0_length,
double *coarse_time_axis, double *coarse_f0, double *coarse_vuv) {
for (int i = 0; i < y_length; ++i)
time_axis[i] = i / static_cast<double>(fs);
for (int i = 0; i < f0_length; ++i)
// the array 'coarse_time_axis' is supposed to have 'f0_length + 1' positions
for (int i = 0; i <= f0_length; ++i)
coarse_time_axis[i] = i * frame_period;
for (int i = 0; i < f0_length; ++i)
coarse_f0[i] = f0[i];
Expand Down

0 comments on commit c80d74a

Please sign in to comment.