?? speechpreprocess.m
字號:
%Name: Yan Diqun
%Context: Data Information Hiding
%Project: Least Significant Bit
global bitstream LengthOfBitstream speech
%yandiqun=m_sequence(4,3);
%保密語音G.729A壓縮編碼
%!coder nbu.pcm nbu.bit
%將保密語音轉(zhuǎn)化為bit流文件
[speechfilename]=uigetfile('*.wav');
[audio,fs,wmode,fidx]=readwav(speechfilename,'r');
speech=audio+128;
%length_of_bitstream=length(speech);
figure(1);
plot(speech);
yLabel('Original Speech');
axis tight;
for i=1:length(speech)
temp(i,:)=bitget(speech(i),[1:8]);
end;
bitstream=temp';
bitstream=bitstream(:);
%BCH糾錯編碼
bitstream=encode(bitstream,7,4,'bch');
LengthOfBitstream=floor(length(bitstream));
%index=find(bitstream==0);
%bitstream(index)=-1;
?? 快捷鍵說明
復制代碼
Ctrl + C
搜索代碼
Ctrl + F
全屏模式
F11
切換主題
Ctrl + Shift + D
顯示快捷鍵
?
增大字號
Ctrl + =
減小字號
Ctrl + -