如何使用NAudio对语音段串联应用平滑?

时间:2011-10-29 13:04:36

标签: algorithm text-to-speech naudio smoothing

我正在进行语音段连接以产生最终语音(测试到语音任务),我想在这些段上应用平滑以使最终结果更自然。 这种情况下最好的平滑技术是什么?以及如何使用NAudio库

应用它

P.S: 我需要一个示例代码或任何教程来在wav上应用任何平滑技术

1 个答案:

答案 0 :(得分:0)

当你淡入另一边时,将一边淡出。尝试线性淡化和对数。

编辑:以下是您可能需要采取的步骤:

我们将调用第一个剪辑C1和第二个剪辑C2。调用剪辑长度tC1和tC2。您正试图以平滑的方式组合它们。首先确定您希望淡入淡出持续多长时间。这可能是几毫秒。也许从200毫秒开始。把这个称为tFade。

1. Do the fade-out on the end of C1.
2. Do the fade-in on the start of C2.
3. Pad the end of C1 with tC2-tFade of silence
4. Pad the start of C2 with tC1-tFade of silence
5. Add the padded clips together (at this point, they are the same length: tC1+tC2-tFade)