How to read Audio File into Vector?
조회 수: 74 (최근 30일)
이전 댓글 표시
Hello, I have to read a Audio File (.wav) into a vector.
I know how to plot it:
info = audioinfo('sound.wav');
[y, Fs] = audioread('sound.wav');
t = 0:1/Fs:info.Duration;
t = t(1:end-1);
plot(t,y);
xlabel('Time');
ylabel('Audio Signal');
But this Sript does not read the Audio into a Vector.
I also tried to read every single Sample, but this is to complex and I get error after error. Is there a simple way to do this?
댓글 수: 2
Cris LaPierre
2020년 7월 15일
It would be helpful if you could share the error messages as well as your sound.wav file.
채택된 답변
Sugar Daddy
2020년 7월 15일
편집: Sugar Daddy
2020년 7월 15일
[y, Fs] = audioread('sound.wav');
sound_duration = length(y)/Fs;
t = 0:1/Fs:sound_duration;
t = t(1:end-1);
%%
soundsc(y,Fs);
%%
plot(t,y);
xlabel('Time');
ylabel('Audio Signal');
추가 답변 (2개)
George james
2022년 6월 6일
The help slides is providing the facility for a training program that has been producing high-quality audio. The https://www.resumesplanet.com/linkedin-profile-writing.php is quite a good option to get admission to these training programs.
댓글 수: 0
Charlotte Oliver
2022년 6월 10일
편집: Charlotte Oliver
2022년 6월 10일
there is alot of mistakes in this specific code for the correct program just visit this one https://consumeratings.com/ It will provide you the best code moreover correct your mistakes as well. happy to help you all.
댓글 수: 0
참고 항목
카테고리
Help Center 및 File Exchange에서 Audio and Video Data에 대해 자세히 알아보기
제품
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!