您好,欢迎光临本网站![请登录][注册会员]  
文件名称: matlab图像处理
  所属分类: Java
  开发工具:
  文件大小: 37kb
  下载次数: 0
  上传时间: 2014-04-24
  提 供 者: mzy0****
 详细说明: function varargout = Applicazione(varargin) % APPLICAZIONE M-file for Applicazione.fig % APPLICAZIONE, by itself, creates a new APPLICAZIONE or raises the existing % singleton*. % % H = APPLICAZIONE returns the handle to a new APPLICAZIONE or the handle to % the existing singleton*. % % APPLICAZIONE('CALLBACK',hObject,eventData,handles,...) calls the local % function named CALLBACK in APPLICAZIONE.M with the given input arguments. % % APPLICAZIONE('Property','Value',...) creates a new APPLICAZI ONE or raises the % existing singleton*. Starting from the left, property value pairs are % applied to the GUI before Applicazione_OpeningFunction gets called. An % unrecognized property name or invalid value makes property application % stop. All inputs are passed to Applicazione_OpeningFcn via varargin. % % *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 Applicazione % Last Modified by GUIDE v2.5 04-Jan-2007 18:09:14 % Begin initialization code - DO NOT EDIT gui_Singleton = 1; gui_State = struct('gui_Name', mfilename, ... 'gui_Singleton', gui_Singleton, ... 'gui_OpeningFcn', @Applicazione_OpeningFcn, ... 'gui_OutputFcn', @Applicazione_OutputFcn, ... 'gui_LayoutFcn', [] , ... 'gui_Callback', []); if nargin && ischar(varargin{1}) gui_State.gui_Callback = str2func(varargin{1}); end if 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 Applicazione is made visible. function Applicazione_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 command line arguments to Applicazione (see VARARGIN) % Choose default command line output for Applicazione handles.output = hObject; handles.ImmagineCorrente=0; % Update handles structure guidata(hObject, handles); % UIWAIT makes Applicazione wait for user response (see UIRESUME) % uiwait(handles.figure1); % --- Outputs from this function are returned to the command line. function varargout = Applicazione_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 structure varargout{1} = handles.output; % -------------------------------------------------------------------- function MenuFileApri_Callback(hObject, eventdata, handles) % hObject handle to MenuFileApri (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) [NomeFileImmagine PercorsoFileImmagine]=uigetfile({ '*.jpeg;*.jpg', 'Immagine JPEG (*.jpg, *.jpeg)'; '*.bmp', 'Immagine BMP (*.bmp)'},'MultiSelect','off'); if ~isequal(PercorsoFileImmagine,0) && ~isequal(NomeFileImmagine,0) PathCompletoImmagine=strcat(PercorsoFileImmagine,NomeFileImmagine); Immagine=imread(PathCompletoImmagine); handles.ImmagineCorrente=Immagine; guidata(hObject,handles); imtool(Immagine); end % -------------------------------------------------------------------- function MenuFileEsci_Callback(hObject, eventdata, handles) % hObject handle to MenuFileEsci (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) Risposta = ConfermaUscita(); switch lower(Risposta) case 'no' case 'si' delete(handles.figure1) end % -------------------------------------------------------------------- function MenuEditInterpola_Callback(hObject, eventdata, handles) % hObject handle to MenuEditInterpola (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % -------------------------------------------------------------------- function MenuEditInterpolaReplicazione_Callback(hObject, eventdata, handles) % hObject handle to MenuEditInterpolaReplicazione (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) tic; Replicazione=ControlloCentrale(handles.ImmagineCorrente,handles.Zoom,'Replicazione'); Tempo=toc; imtool(Replicazione); set(handles.TempoReplicazione,'String',['Replicazione: ' num2str(Tempo) 's']); guidata(hObject,handles); % -------------------------------------------------------------------- function MenuEditInterpolaBilineare_Callback(hObject, eventdata, handles) % hObject handle to MenuEditInterpolaBilineare (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) tic; Bilineare=ControlloCentrale(handles.ImmagineCorrente,handles.Zoom,'Bilineare'); Tempo=toc; imtool(Bilineare); set(handles.TempoBilineare,'String',['Bilineare: ' num2str(Tempo) 's']); guidata(hObject,handles); % -------------------------------------------------------------------- function MenuEditInterpolaBicubica_Callback(hObject, eventdata, handles) % hObject handle to MenuEditInterpolaBicubica (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) tic; Bicubica=ControlloCentrale(handles.ImmagineCorrente,handles.Zoom,'Bicubica'); Tempo=toc; imtool(Bicubica); set(handles.TempoBicubica,'String',['Bicubica: ' num2str(Tempo) 's']); guidata(hObject,handles); % -------------------------------------------------------------------- function MenuHelpAbout_Callback(hObject, eventdata, handles) % hObject handle to MenuHelpAbout (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) msgbox('Programma creato dallo studente Salvo Danilo Giuffrida, B05/000145, per il seminario di Analisi Numerica, A.A. 2006/2007, relativo all''interpolazione per lo zooming di immagini digitali','Informazioni','Help','createMode') % -------------------------------------------------------------------- function MenuFile_Callback(hObject, eventdata, handles) % hObject handle to MenuFile (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % -------------------------------------------------------------------- function MenuEdit_Callback(hObject, eventdata, handles) % hObject handle to MenuEdit (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) if handles.ImmagineCorrente==0 set(handles.MenuEditInterpola,'Enable','off'); else set(handles.MenuEditInterpola,'Enable','on'); end guidata(hObject, handles); % -------------------------------------------------------------------- function MenuHelp_Callback(hObject, eventdata, handles) % hObject handle to MenuHelp (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % --- Executes during object creation, after setting all properties. function SliderZoom_CreateFcn(hObject, eventdata, handles) % hObject handle to SliderZoom (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles empty - handles not created until after all CreateFcns called % Hint: slider controls usually have a light gray background. if isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor')) set(hObject,'BackgroundColor',[.9 .9 .9]); end handles.Zoom=get(hObject,'Value'); guidata(hObject,handles); % --- Executes on slider movement. function SliderZoom_Callback(hObject, eventdata, handles) % hObject handle to SliderZoom (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % Hints: get(hObject,'Value') returns position of slider % get(hObject,'Min') and get(hObject,'Max') to determine range of slider NuovoZoom=get(hObject,'Value'); handles.Zoom=NuovoZoom; set(handles.ValoreZoom,'String',num2str(NuovoZoom)); guidata(hObject,handles); % -------------------------------------------------------------------- function MenuEditInterpolaTutti_Callback(hObject, eventdata, handles) % hObject handle to MenuEditInterpolaTutti (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) MenuEditInterpolaReplicazione_Callback(hObject, eventdata, handles); MenuEditInterpolaBilineare_Callback(hObject, eventdata, handles); MenuEditInterpolaBicubica_Callback(hObject, eventdata, handles); function ValoreZoom_Callback(hObject, eventdata, handles) % hObject handle to ValoreZoom (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % Hints: get(hObject,'String') returns contents of ValoreZoom as text % str2double(get(hObject,'String')) returns contents of ValoreZoom as a double NuovoValore=str2num(get(hObject,'String')); LimiteMin=get(handles.SliderZoom,'Min'); LimiteMax=get(handles.SliderZoom,'Max'); if NuovoValore>=LimiteMin && NuovoValore<=LimiteMax set(handles.SliderZoom,'Value',str2num(get(hObject,'String'))); else handles.Zoom=NuovoValore; end guidata(hObject,handles); % --- Executes during object creation, after setting all properties. function ValoreZoom_CreateFcn(hObject, eventdata, handles) % hObject handle to ValoreZoom (see GCBO) % eventdata reserved - to be defined in a future version of MATLAB % handles empty - handles not created until after all CreateFcns called % Hint: edit controls usually have a white background on Windows. % See ISPC and COMPUTER. if ispc && isequal(get(hObject,'BackgroundColor'), get(0,'defaultUicontrolBackgroundColor')) set(hObject,'BackgroundColor','white'); end ...展开收缩
(系统自动生成,下载前可以参看下载内容)

下载文件列表

相关说明

  • 本站资源为会员上传分享交流与学习,如有侵犯您的权益,请联系我们删除.
  • 本站是交换下载平台,提供交流渠道,下载内容来自于网络,除下载问题外,其它问题请自行百度
  • 本站已设置防盗链,请勿用迅雷、QQ旋风等多线程下载软件下载资源,下载后用WinRAR最新版进行解压.
  • 如果您发现内容无法下载,请稍后再次尝试;或者到消费记录里找到下载记录反馈给我们.
  • 下载后发现下载的内容跟说明不相乎,请到消费记录里找到下载记录反馈给我们,经确认后退回积分.
  • 如下载前有疑问,可以通过点击"提供者"的名字,查看对方的联系方式,联系对方咨询.
 相关搜索: matlab
 输入关键字,在本站1000多万海量源码库中尽情搜索: