changing from wavread to audioread

11 visualizaciones (últimos 30 días)
Andrew Mitchell
Andrew Mitchell el 10 de Feb. de 2016
Respondida: Walter Roberson el 10 de Feb. de 2016
My colleague has written a program on an older version of Matlab which involves reading in .wav file. In the older version, this would have been handled with wavread, but in R2015b it needs to be handled with audioread. I think I've mostly sorted the changes needed, but one is catching me up.
Basically, what is the audioread equivalent to:
siz = wavread(filename, 'size'

Respuestas (1)

Walter Roberson
Walter Roberson el 10 de Feb. de 2016
You can use audioinfo and extract TotalSamples and NumChannels .
But typically you just read the entire file and take size() of the data afterwards. Not always, but that is the most common approach.

Community Treasure Hunt

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

Start Hunting!

Translated by