Dear all,
I have a problem (maybe small problem, but I can´t handle it) with SegmentTool. I downloaded zip here https://www.mathworks.com/matlabcentral/fileexchange/38484-segmenttool--an-interactive-gui-for-segmenting-images and I unzipped this folder. But when I write to the Command Window SegmentTool, so I see this error:
Undefined function 'audioread' for input arguments of type 'char'.
Error in SegmentTool (line 133)
[wav,freq] = audioread('notify.wav');
How do I resolve this? Thank you for your answers.

 Respuesta aceptada

Geoff Hayes
Geoff Hayes el 1 de Sept. de 2016

0 votos

Veronika - which version of MATLAB are you using? According to audioread, this method was introduced in R2012b and so you may not have this function if using an earlier version of MATLAB. At the Command Line, type
which audioread -all
to see if you have this function and
ver
to determine your version of MATLAB.

2 comentarios

Veronika
Veronika el 4 de Sept. de 2016
Yes, I have really old version (R2011b). So I don´t have audioread function. I try another version. Thank you for your answer.
Image Analyst
Image Analyst el 4 de Sept. de 2016
Veronika, it appears you didn't see my solution below. Of course using a more modern version is better though.

Iniciar sesión para comentar.

Más respuestas (1)

Image Analyst
Image Analyst el 1 de Sept. de 2016

0 votos

You must have a really old version. Try wavread() instead:
[wav,freq] = wavread('notify.wav');

10 comentarios

Veronika
Veronika el 5 de Sept. de 2016
Yes, I have R2011b version. I tried, what you advised. Variables were loaded into the workspace and no error messages appeared. But I do not know how to proceed.
Image Analyst
Image Analyst el 5 de Sept. de 2016
What do you want to do with it? Geoff and I don't know. You didn't tell us. Why are you reading it in in the first place?
Veronika
Veronika el 5 de Sept. de 2016
I need to do segmentation area of the image and after that create FEM model from this area.
Image Analyst
Image Analyst el 5 de Sept. de 2016
What image? You know you're reading in a wav file, which is a sound file, don't you?
Veronika
Veronika el 5 de Sept. de 2016
That's what I'm not sure. I need to edit the image, so I downloaded SegmentTool. I don´t know why is there mistake about the audio (sound) file.
Image Analyst
Image Analyst el 5 de Sept. de 2016
Well evidently it tries to load and play a sound file. So either replace it with waveread() like I said, or just replace it with
beep();
or simply comment it out. Let me know if that solves the problem.
Geoff Hayes
Geoff Hayes el 5 de Sept. de 2016
Veronika - for some reason, the author of the SegmentTool has included a wave file for notifications (a message indicating that something is happening). If playing this sound is still causing you a problem, then I would remove the three or four lines corresponding to it from the code.
I see that you have started a new question at http://www.mathworks.com/matlabcentral/answers/301959-how-to-start-segmenttool-and-import-image which may explain more clearly what problems you are having with this code.
Veronika
Veronika el 5 de Sept. de 2016
Image Analyst I can´t comment it out or replace it, because it reports: "Access denied".
Geoff Hayes I can´t remove lines, because of "Access denied". My new question relates a newer version (R2016a).
Image Analyst
Image Analyst el 6 de Sept. de 2016
Either you have it open in another program, or you have it saved in a place where you can't edit it, like under the Program Files folder somewhere. Move it to a folder where you do have permission.
Veronika
Veronika el 6 de Sept. de 2016
Ok, so I commented out this two lines:
[wav,freq] = audioread('notify.wav');
notification = audioplayer(wav,freq);
Is it enough? Application is started in order, but some buttons and sliders don´t react and error appeares. So far it does not affect the function of the application.
So far, thank you very much.

Iniciar sesión para comentar.

Categorías

Más información sobre Introduction to Installation and Licensing en Centro de ayuda y File Exchange.

Preguntada:

el 1 de Sept. de 2016

Comentada:

el 6 de Sept. de 2016

Community Treasure Hunt

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

Start Hunting!

Translated by