Skip to content

Commit

Permalink
更新播放延迟的问题
Browse files Browse the repository at this point in the history
  • Loading branch information
Entity-Now committed Jul 9, 2024
1 parent f4b1910 commit 91e8297
Show file tree
Hide file tree
Showing 7 changed files with 3 additions and 3 deletions.
Binary file modified .vs/Edge_tts_sharp/DesignTimeBuild/.dtbcache.v2
Binary file not shown.
Binary file modified .vs/Edge_tts_sharp/v17/.futdcache.v2
Binary file not shown.
Binary file modified .vs/Edge_tts_sharp/v17/.suo
Binary file not shown.
Binary file modified .vs/ProjectEvaluation/edge_tts_sharp.metadata.v7.bin
Binary file not shown.
Binary file modified .vs/ProjectEvaluation/edge_tts_sharp.projects.v7.bin
Binary file not shown.
2 changes: 1 addition & 1 deletion Edge_tts_sharp/Edge_tts_sharp.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@

<!--以下是我们自己添加的-->
<!--版本号,重要性不必多说-->
<Version>1.0.9</Version>
<Version>1.1.0</Version>
<!--添加该配置,在编译时进行打包-->
<GeneratePackageOnBuild>true</GeneratePackageOnBuild>
<!--添加该配置才会生成注释文件,默认无注释-->
Expand Down
4 changes: 2 additions & 2 deletions Edge_tts_sharp/Utils/Audio.cs
Original file line number Diff line number Diff line change
Expand Up @@ -24,7 +24,7 @@ public static async Task PlayToStreamAsync(Stream source, float volume = 1.0f)

while (directSoundOut.PlaybackState == PlaybackState.Playing)
{
Thread.Sleep(10);
Thread.Sleep(1000);
}
}
}
Expand All @@ -49,7 +49,7 @@ public static async Task PlayAudioAsync(string audioPath, float volume = 1.0f)

while (directSoundOut.PlaybackState == PlaybackState.Playing)
{
await Task.Delay(500);
await Task.Delay(1000);
}
}
}
Expand Down

0 comments on commit 91e8297

Please sign in to comment.