资源描述:
《简单数字图像处理系统.doc》由会员上传分享,免费在线阅读,更多相关内容在教育资源-天天文库。
1、数字图像课程设计简单数字图像处理系统functionvarargout=untitled(varargin)%Begininitializationcode-DONOTEDITgui_Singleton=1;gui_State=struct('gui_Name',mfilename,...'gui_Singleton',gui_Singleton,...'gui_OpeningFcn',@untitled_OpeningFcn,...'gui_OutputFcn',@untitled_OutputFcn,...'gui_LayoutFcn',[]
2、,...'gui_Callback',[]);ifnargin&&ischar(varargin{1})gui_State.gui_Callback=str2func(varargin{1});endifnargout[varargout{1:nargout}]=gui_mainfcn(gui_State,varargin{:});elsegui_mainfcn(gui_State,varargin{:});end%Endinitializationcode-DONOTEDIT%---Executesjustbeforeuntitledismad
3、evisible.functionuntitled_OpeningFcn(hObject,eventdata,handles,varargin)%界面初始化函数setappdata(handles.figure1,'I',0);%Thisfunctionhasnooutputargs,seeOutputFcn.%hObjecthandletofigure%eventdatareserved-tobedefinedinafutureversionofMATLAB%handlesstructurewithhandlesanduserdata(seeG
4、UIDATA)%varargincommandlineargumentstountitled(seeVARARGIN)%Choosedefaultcommandlineoutputforuntitledhandles.output=hObject;%Updatehandlesstructureguidata(hObject,handles);%UIWAITmakesuntitledwaitforuserresponse(seeUIRESUME)%uiwait(handles.figure1);%---Outputsfromthisfunction
5、arereturnedtothecommandline.functionvarargout=untitled_OutputFcn(hObject,eventdata,handles)%界面输出函数%varargoutcellarrayforreturningoutputargs(seeVARARGOUT);%hObjecthandletofigure%eventdatareserved-tobedefinedinafutureversionofMATLAB%handlesstructurewithhandlesanduserdata(seeGUI
6、DATA)%Getdefaultcommandlineoutputfromhandlesstructurevarargout{1}=handles.output;%--------------------------------------------------------------------functionm_file_Callback(hObject,eventdata,handles)%hObjecthandletom_file(seeGCBO)%eventdatareserved-tobedefinedinafutureversio
7、nofMATLAB%handlesstructurewithhandlesanduserdata(seeGUIDATA)%--------------------------------------------------------------------functionmy_file_open_Callback(hObject,eventdata,handles)globalI;[FileName,PathName]=uigetfile('*.bmp;*.jpg;*.tiff;*.gif');%弹出对话框得到打开的路径I=imread(str
8、cat(PathName,FileName));%打开得到的路径下的文件imshow(I)setappdata(handles.figu