My Code can not read recorded audio file.

3 ビュー (過去 30 日間)
Abdullah Alsuhaymi
Abdullah Alsuhaymi 2019 年 6 月 7 日
回答済み: Geoff Hayes 2019 年 6 月 9 日
Hello,
I work on Matlab app designer
and my app can do the following:
1- Record sound using microphon.
2-Play the recorded sound.
3-Save the recorded sound as .ogg file but when I try to turn on the saved audio file which format is .ogg file inside or outside the matlab it does not work?
what is the problem with my code?why this is happining?
this is my code so simple
a = audiorecorder (8000,16,1);
record(a,60);
b=getaudiodata(a);
sound(b);
save('Soundfile.ogg');

回答 (1 件)

Geoff Hayes
Geoff Hayes 2019 年 6 月 9 日
Abdullah - try using audiowrite to save your audio data to a file with an ogg extension. I think that your code is using save which is not applicable for the purpose you are intending.

カテゴリ

Help Center および File ExchangeAudio and Video Data についてさらに検索

タグ

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by