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

📄 yasuo.asv

📁 数字图像处理
💻 ASV
字号:
function varargout = yasuo(varargin)%YASUO M-file for yasuo.fig%      YASUO, by itself, creates a new YASUO or raises the existing%      singleton*.%%      H = YASUO returns the handle to a new YASUO or the handle to%      the existing singleton*.%%      YASUO('Property','Value',...) creates a new YASUO using the%      given property value pairs. Unrecognized properties are passed via%      varargin to yasuo_OpeningFcn.  This calling syntax produces a%      warning when there is an existing singleton*.%%      YASUO('CALLBACK') and YASUO('CALLBACK',hObject,...) call the%      local function named CALLBACK in YASUO.M with the given input%      arguments.%%      *See GUI Options on GUIDE's Tools menu.  Choose "GUI allows only one%      instance to run (singleton)".%% See also: GUIDE, GUIDATA, GUIHANDLES% Edit the above text to modify the response to help yasuo% Last Modified by GUIDE v2.5 04-Jun-2008 17:10:07% Begin initialization code - DO NOT EDITgui_Singleton = 1;gui_State = struct('gui_Name',       mfilename, ...                   'gui_Singleton',  gui_Singleton, ...                   'gui_OpeningFcn', @yasuo_OpeningFcn, ...                   'gui_OutputFcn',  @yasuo_OutputFcn, ...                   'gui_LayoutFcn',  [], ...                   'gui_Callback',   []);if nargin && ischar(varargin{1})   gui_State.gui_Callback = str2func(varargin{1});endif nargout    [varargout{1:nargout}] = gui_mainfcn(gui_State, varargin{:});else    gui_mainfcn(gui_State, varargin{:});end% End initialization code - DO NOT EDIT% --- Executes just before yasuo is made visible.function yasuo_OpeningFcn(hObject, eventdata, handles, varargin)% This function has no output args, see OutputFcn.% hObject    handle to figure% eventdata  reserved - to be defined in a future version of MATLAB% handles    structure with handles and user data (see GUIDATA)% varargin   unrecognized PropertyName/PropertyValue pairs from the%            command line (see VARARGIN)% Choose default command line output for yasuohandles.output = hObject;% Update handles structureguidata(hObject, handles);% UIWAIT makes yasuo wait for user response (see UIRESUME)% uiwait(handles.figure1);% --- Outputs from this function are returned to the command line.function varargout = yasuo_OutputFcn(hObject, eventdata, handles)% varargout  cell array for returning output args (see VARARGOUT);% hObject    handle to figure% eventdata  reserved - to be defined in a future version of MATLAB% handles    structure with handles and user data (see GUIDATA)% Get default command line output from handles structurevarargout{1} = handles.output;% --- Executes on button press in pushbutton1.function pushbutton1_Callback(hObject, eventdata, handles)% hObject    handle to pushbutton1 (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    structure with handles and user data (see GUIDATA);;wname='haar';lev=3;[c,s]=wavedec2(X,lev,wname);alpha=1.5;m=3.5*prod(s(1,:));[thr,nkeep]=wdcbm2(c,s,alpha,m);xd=wdencmp('lvd',c,s,wname,lev,thr,'h');%colormap(pink(nbc));figure(1);subplot(1,2,1);imsh(wcodemat(X,nbc));title('原始信号');subplot(1,2,2);image(wcodemat(xd,nbc));title('压缩后的信号');% --- Executes on button press in pushbutton2.function pushbutton2_Callback(hObject, eventdata, handles)% hObject    handle to pushbutton2 (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    structure with handles and user data (see GUIDATA)open yasuo11% --- Executes on button press in pushbutton3.function pushbutton3_Callback(hObject, eventdata, handles)% hObject    handle to pushbutton3 (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    structure with handles and user data (see GUIDATA)load julia;nbc=size(map,1);wname='haar';lev=3;[c,s]=wavedec2(X,lev,wname);[thr,nkeep]=ddencmp('cmp','wv',X);xd=wdencmp('gbl',c,s,wname,lev,thr,'s',1);colormap(pink(nbc));figure(1);subplot(1,2,1);image(wcodemat(X,nbc));title('原始信号');subplot(1,2,2);image(wcodemat(xd,nbc));title('压缩后的信号');% --- Executes on button press in pushbutton4.function pushbutton4_Callback(hObject, eventdata, handles)% hObject    handle to pushbutton4 (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    structure with handles and user data (see GUIDATA)open yysuo% --- Executes on button press in pushbutton5.function pushbutton5_Callback(hObject, eventdata, handles)% hObject    handle to pushbutton5 (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    structure with handles and user data (see GUIDATA)load mask;nbc=size(map,1);[thr,sorh,keepapp,crit]=ddencmp('cmp','wp',X);[xc,treed,perf0,perfl2]=wpdencmp(X,sorh,3,'db3',crit,thr,keepapp);figure(1);subplot(211);colormap(pink(nbc));image(wcodemat(X,nbc));title('原始图像');subplot(212);image(wcodemat(xc,nbc));title('压缩后的图像');% --- Executes on button press in pushbutton6.function pushbutton6_Callback(hObject, eventdata, handles)% hObject    handle to pushbutton6 (see GCBO)% eventdata  reserved - to be defined in a future version of MATLAB% handles    structure with handles and user data (see GUIDATA)open 

⌨️ 快捷键说明

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