17.01.2015 Views

Basic Digital Audio Effects

Basic Digital Audio Effects

Basic Digital Audio Effects

SHOW MORE
SHOW LESS

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

Shelving Filter EQ MATLAB Example (Cont.)<br />

The following script shelving eg.m illustrates how we use the shelving<br />

filter function to filter:<br />

infile = ’acoustic.wav’;<br />

% read in wav sample<br />

[ x, Fs, N ] = wavread(infile);<br />

CM0268<br />

MATLAB<br />

DSP<br />

GRAPHICS<br />

347<br />

%set Parameters for Shelving Filter<br />

% Change these to experiment with filter<br />

G = 4; fcb = 300; Q = 3; type = ’Base_Shelf’;<br />

[b a] = shelving(G, fcb, Fs, Q, type);<br />

yb = filter(b,a, x);<br />

% write output wav files<br />

wavwrite(yb, Fs, N, ’out_bassshelf.wav’);<br />

% plot the original and equalised waveforms<br />

figure(1), hold on;<br />

plot(yb,’b’);<br />

plot(x,’r’);<br />

title(’Bass Shelf Filter Equalised Signal’);<br />

1<br />

◭◭<br />

◮◮<br />

◭<br />

◮<br />

Back<br />

Close

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!