Midterm Project

Music's Time Domain Analysis

What the program can do?

The program has 5 parts:

1. The import file

2. Stop Button

3. The button to adjust playing speed

4.The graphs to analyse music by time domain

5. Just play and analyse the music's one side



By using this program, we can see what happened about the music on time domain and listen what difference of the stereo volume's two side.

What is the main idea?

clear sound;

melody_matching=get(handles.popupmenu1,'Value');

switch melody_matching

case 1

clear sound;

case 2

[y,hz] = audioread('O Fortuna.mp3');

sound(y,hz);

time = (1 : length(y) ) / hz;

plot(handles.axes1,time,y(:,1),'b');

plot(handles.axes2,time,y(:,2),'r');

plot(handles.axes3,time,y);

case 3, case 4, case 5, case 6 is all like case 2;

end

The Pop-up Menu is the most important thing for this GUI and program.


At first we must "clear sound" to make sure there won't be any sound when playing program.

"melody_matching" help us to take out what is now in the pop-up menu.


Case 1 in matrix just have nothing. But from case 2 on we should take out the music be chosen. So, 3, 4, 5, 6 is almost the same thing but just chang file name.


Then we could adjust hz to make music be different, and we also can just listen or plot one side's volume by using code "y(:,n)".

Resource

S_S_midterm_project.rar