diff --git a/vocoder.m b/vocoder.m index 78d027b..17586e2 100644 --- a/vocoder.m +++ b/vocoder.m @@ -1 +1,16 @@ pkg load signal + +modfile = 'modulator22.wav'; +carfile = 'white_periodic.wav'; +outfile = 'vocodedsound.wav' +[modul, sr1] = audioread(modfile); +[carrier, sr2] = audioread(carfile); +if sr1~=sr2, disp('your sampling rates dont match'); end +% the chanvovoder function isn't availiable on Octave and i am not able to find an equivalent function + +y = chanvocoder(carrier, modul, 512, 16, .2); +audiowrite(y,sr1,16,outfile) + +subplot() + +%% on the same figure temporal variation, carrier and output