www.pudn.com > dspproject.rar > woman_man.m, change:2016-10-17,size:467b


[x,fs,bits] =wavread('woman.wav'); 
%sound(x,fs,bits);                 %对语音信号进行回放 
x0=x(:,1);                       %读入的x矩阵有两列,取第1列 
Fs=2*fs;                           %采样频率 
N=length(x0);                       %语音信号的长度 
t=0:1/fs:(N-1)/fs; 
%女声转换为男声% 
y1=voice(x0,1.5);                %调整voice()第2个参数转换音调,>1降调,<1升调,y1为x转换后的声音 
sound(y1,fs); 
wavwrite(y1,fs,'bianshen.wav'); 
[x,ft]=wavread('bianshen.wav');