⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 gchek.m

📁 这是一个用于语音信号处理的工具箱
💻 M
字号:
% Function : Create a graphical user interface (GUI) to 
%           (1) display the speech and egg data 
%           (2) zoom in on the data
%
% Gchek.m is a call_function executed by "c_pb_gci" on figure(c_win_f).
%

%---------------------------------------------%
% plot the GUIs along with the speech signal  %
%---------------------------------------------%

Gchek_f=figure('Unit','Normalized',...
   'Numbertitle','off',...
   'Color',[.5 .5 .5],...
   'Position',[.32 .45 .67 .45 ], ...
   'Name','GCI Display and Manual Correction');

axes('Position',[.06 .135 .9 .6],'Box','on','Visible','off');
whitebg(Gchek_f,'w');

% get the display signal

clear signal;

signal=speech;

ir0=ir;
lens=length(signal); % the length of the signal

% initial setting
left=1;
right=lens;

% plot the speech signal 


plot((left:right),signal(left:right),'color',LINE_COLOR);
axis([left right min(signal) max(signal) ]);

% provide the zooming and shifting functions

shitf_text=uicontrol('Style','text',...
   'Units','normalized','Position',[0.01 .875 .10 .08],'String','Shift pts:',...
   'BackGroundColor',[0.68 0.68 0.68]);

shift_left=uicontrol('Style','Pushbutton',...
   'Unit','Normalized','Position',[.12 .875 .05 .08],'Visible','off','String','<',...
   'Callback','sf_flag=1;shft');
%callback function [shft.m]

shift_pts=uicontrol('Style','edit', ...
   'Unit','Normalized','Position',[.18 .875 .1 .08],'String',fram_len);

shift_right=uicontrol('Style','Pushbutton',...
   'Unit','Normalized','Position',[.29 .875 .05 .08],'Visible','off',...
   'String','>','Callback','sf_flag=-1;shft');
%callback function [shft.m]

zoom_text=uicontrol('Style','text',...
   'Units','normalized','Position',[.38 .875 .20 .08],'String','Zooming factor :',...
   'BackGroundColor',[.68 .68 .68]);

zoom_zscale=uicontrol('Style','edit',...
   'Units','normalized','Position',[.59 .875 .05 .08],'String','2');

zoom_in=uicontrol('Style','Pushbutton', ...
   'String','Zoom in','Units','normalized','Position',[.69 .875 .13 .08],'Callback', 'Zio=1;zoomio');
%callback function [zoomio.m]

zoom_out=uicontrol('Style','Pushbutton', ...
   'String','Zoom out','Units','normalized','Position',[.84 .875 .13 .08],'Callback', 'Zio=-1;zoomio');
%callback function [zoomio.m]

add_pb=uicontrol('Style','Pushbutton', ...
   'String','Add one gci' ,...
   'Units','normalized','Position',[.15 .76 .2 .08],'BackgroundColor',[.5 .5 .5],...
   'Callback','addgci');
%callback function [addgci.m]

delet_pb=uicontrol('Style','Pushbutton', ...
   'String','Delete one gci' ,...
   'Units','normalized','Position',[.4 .76 .2 .08],'BackgroundColor',[.5 .5 .5],...
   'Callback','delgci');
%callback function [delgci.m]

app_pb=uicontrol('Style','Pushbutton', ...
   'String','Apply' ,...
   'Units','normalized','Position',[.65 .76 .13 .08],'BackgroundColor',[.5 .5 .5],...
   'Visible','off',...
   'Callback','gci=gci0;');

return_pb=uicontrol('Style','Pushbutton',...
   'Units','normalized','Position',[.84 .76 .13 .08],...
   'Callback','close(Pcontour_f);close(Gchek_f);clear right left right_r    left_r gci0 signal lens ir0 lethnow;',...
   'String','Return');

   
%end

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -