- On Windows, this can be done using .NET. There happens to be an example of this in a blog post on .NET in MATLAB.
- On a Mac, use the "say" system command:
saying a message in matlab
12 ビュー (過去 30 日間)
古いコメントを表示
1-how can say a message Computerized in matlab? for example
if a=b
saying in Computerized ' a and b are matching'
else
saying in Computerized ' a and b are not matching'
end
2-please tell with which command can run a .mp3 in matlab?
0 件のコメント
採用された回答
Ken Atwell
2011 年 9 月 1 日
You mean have the computer synthesize speech?
system('say "Hello, World!"')
その他の回答 (1 件)
Wayne King
2011 年 9 月 1 日
Hi Mohammed, If you have the DSP System Toolbox, the System object dsp.AudioFileReader can read an MP3 file on Windows. Additionally, there are mp3write and mp3read utilities on the file exchange, but I would recommend that you just store these as vectors since they are not long utterances. Store them as .mat files that you can load when your program starts and then use soundsc() to play them.
It seems a lot of overhead to be reading these files (whether they are mp3, or WAV, etc).
Wayne
参考
カテゴリ
Help Center および File Exchange で Audio I/O and Waveform Generation についてさらに検索
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!