Skip to content

Commit

Permalink
rm LoadWav2Char for clients
Browse files Browse the repository at this point in the history
  • Loading branch information
lyblsgo committed Jan 23, 2024
1 parent a11eff3 commit 8ec8c07
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 8 deletions.
5 changes: 1 addition & 4 deletions runtime/websocket/bin/funasr-wss-client-2pass.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -192,10 +192,7 @@ class WebsocketClient {
funasr::Audio audio(1);
int32_t sampling_rate = audio_fs;
std::string wav_format = "pcm";
if (funasr::IsTargetFile(wav_path.c_str(), "wav")) {
if (!audio.LoadWav(wav_path.c_str(), &sampling_rate, false))
return;
} else if (funasr::IsTargetFile(wav_path.c_str(), "pcm")) {
if (funasr::IsTargetFile(wav_path.c_str(), "pcm")) {
if (!audio.LoadPcmwav(wav_path.c_str(), &sampling_rate, false)) return;
} else {
wav_format = "others";
Expand Down
5 changes: 1 addition & 4 deletions runtime/websocket/bin/funasr-wss-client.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -193,10 +193,7 @@ class WebsocketClient {
funasr::Audio audio(1);
int32_t sampling_rate = audio_fs;
std::string wav_format = "pcm";
if (funasr::IsTargetFile(wav_path.c_str(), "wav")) {
if (!audio.LoadWav(wav_path.c_str(), &sampling_rate, false))
return;
} else if(funasr::IsTargetFile(wav_path.c_str(), "pcm")){
if(funasr::IsTargetFile(wav_path.c_str(), "pcm")){
if (!audio.LoadPcmwav(wav_path.c_str(), &sampling_rate, false))
return ;
}else{
Expand Down

0 comments on commit 8ec8c07

Please sign in to comment.