function varargout = NSSD(varargin) % NSSD MATLAB code for NSSD.

fig % NSSD, by itself, creates a new NSSD or raises the existing % singleton*. % % H = NSSD returns the handle to a new NSSD or the handle to % the existing singleton*. % % NSSD('CALLBACK',hObject,eventData,handles,...) calls the local % function named CALLBACK in NSSD.M with the given input arguments. % % NSSD('Property','Value',...) creates a new NSSD or raises the % existing singleton*. Starting from the left, property value pairs are % applied to the GUI before NSSD_OpeningFcn gets called. An % unrecognized property name or invalid value makes property application % stop. All inputs are passed to NSSD_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 NSSD % Last Modified by GUIDE v2.5 21-Nov-2012 02:46:16 % Begin initialization code - DO NOT EDIT gui_Singleton = 1; gui_State = struct('gui_Name', mfilename, ... 'gui_Singleton', gui_Singleton, ... 'gui_OpeningFcn', @NSSD_OpeningFcn, ... 'gui_OutputFcn', @NSSD_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 NSSD is made visible. function NSSD_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 NSSD (see VARARGIN) % Choose default command line output for NSSD handles.output = hObject; % Update handles structure guidata(hObject, handles);

nssd1 =sum(sum(arg2))/(400*600).nssd1). imshow(L). set(handles.jpg').pathname]=uigetfile('*.gif. ita1= rgb2gray(ita). handles) % hObject handle to pushbutton2 (see GCBO) % eventdata reserved .Executes on button press in pushbutton2. axes(handles. eventdata.'string'. [in.to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) L=rgb2gray(J).jpg.png').map] = imread('argentina.jpg').B. ind=imresize(in. eventdata. function varargout = NSSD_OutputFcn(hObject.image2).map] = imread('italia.jpeg.[400 600]). difference2=imabsdiff(ita1. ita=imresize(it. ind1= rgb2gray(ind).[400 600]). arg2=difference1. rudd=imread('Rudd.A.image1). function pushbutton2_Callback(hObject. % --.*.filename]). axes(handles. [it. set(handles.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. handles) % varargout cell array for returning output args (see VARARGOUT). arg1= rgb2gray(arg). % --.to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) [filename. difference1=imabsdiff(arg1.Executes on button press in pushbutton1.*. function pushbutton1_Callback(hObject.image4). [ar.png').figure1).'string'.output.L).jpg').% UIWAIT makes NSSD wait for user response (see UIRESUME) % uiwait(handles.[400 600]). I=imread([pathname.*. J=imresize(I. eventdata. ita2=difference2.L).Outputs from this function are returned to the command line. axes(handles.handles). % --. %guidata(hObject. . % hObject handle to figure % eventdata reserved . handles) % hObject handle to pushbutton1 (see GCBO) % eventdata reserved .[400 600]).^2.^2.nssd2). imshow(I). imshow(rudd). arg=imresize(ar.map] = imread('india. nssd2 =sum(sum(ita2))/(400*600).

hasil.'string'. . elseif (nssd2==min1) rata=(nssd1+nssd3+nssd4+nssd5)/4. elseif ((nssd3==min1 && (rata-nssd3) >= nssd3)) axes(handles.F.'string'. set(handles.image3).'Italia').'string'.map] = imread('japan.C.[400 600]). else rata=(nssd1+nssd2+nssd3+nssd4)/4. kor=imresize(ko.'string'.jpg').nssd4).L). set(handles.difference3=imabsdiff(ind1. elseif ((nssd2==min1 && (rata-nssd2) >= nssd2)) axes(handles.^2. imshow(difference1). jap2=difference4.image3). set(handles.'string'. min1=min(mn). difference4=imabsdiff(jap1.'string'. elseif (nssd4==min1) rata=(nssd1+nssd2+nssd3+nssd5)/4. set(handles.rata).map] = imread('korea. if (nssd1==min1) rata=(nssd2+nssd3+nssd4+nssd5)/4. set(handles. set(handles.F.nssd3). jap1= rgb2gray(jap). imshow(difference3).^2. nssd5 =sum(sum(kor2))/(400*600). mn=[nssd1 nssd2 nssd3 nssd4 nssd5].'string'. kor2=difference5.[400 600]). %rata=(nssd1+nssd2+nssd3+nssd4+nssd5)/5.'string'. [ja.F.rata). kor1= rgb2gray(kor).rata). set(handles.E. set(handles.D.hasil. jap=imresize(ja.L). nssd4 =sum(sum(jap2))/(400*600).'string'. imshow(difference2).'India').L).image3).rata). nssd3 =sum(sum(ind2))/(400*600). difference5=imabsdiff(kor1.F.'string'. end if ((nssd1==min1 && (rata-nssd1) >= nssd1)) axes(handles. elseif (nssd3==min1) rata=(nssd1+nssd2+nssd4+nssd5)/4. set(handles.nssd5). [ko.'Argentina').^2. set(handles.hasil.'string'. ind2=difference3. set(handles.F.jpg').rata).

if ispc && isequal(get(hObject. elseif ((nssd5==min1 && (rata-nssd5) >= nssd5)) axes(handles.Executes during object creation.handles not created until after all CreateFcns called % Hint: edit controls usually have a white background on Windows.image3).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.'BackgroundColor'.'string'.'South Korea'). % See ISPC and COMPUTER. % See ISPC and COMPUTER.'String')) returns contents of F as a double % --. get(0. eventdata.'white').Executes during object creation. handles) % hObject handle to E (see GCBO) % eventdata reserved .'String') returns contents of F as text % str2double(get(hObject. after setting all properties. imshow(difference4). eventdata. else set(handles.'defaultUicontrolBackgr oundColor')) set(hObject.hasil. eventdata.image3). end function E_Callback(hObject.'not found'). end . end function F_Callback(hObject.'white').'BackgroundColor'.'defaultUicontrolBackgr oundColor')) set(hObject. after setting all properties. if ispc && isequal(get(hObject. function E_CreateFcn(hObject.to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % Hints: get(hObject.to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % Hints: get(hObject.'BackgroundColor').hasil.'BackgroundColor'). set(handles.elseif ((nssd4==min1 && (rata-nssd4) >= nssd4)) axes(handles.'string'. handles) % hObject handle to F (see GCBO) % eventdata reserved .'String') returns contents of E as text % str2double(get(hObject. handles) % hObject handle to F (see GCBO) % eventdata reserved . set(handles.'String')) returns contents of E as a double % --.'string'. get(0.to be defined in a future version of MATLAB % handles empty .'Japan'). function F_CreateFcn(hObject.hasil. handles) % hObject handle to E (see GCBO) % eventdata reserved . eventdata. imshow(difference5).

handles) % hObject handle to C (see GCBO) % eventdata reserved .'BackgroundColor'.Executes during object creation.'BackgroundColor'.'String') returns contents of C as text % str2double(get(hObject. eventdata. handles) % hObject handle to C (see GCBO) % eventdata reserved . after setting all properties.to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % Hints: get(hObject. % See ISPC and COMPUTER.'white'). handles) % hObject handle to B (see GCBO) % eventdata reserved .handles not created until after all CreateFcns called % Hint: edit controls usually have a white background on Windows. eventdata.handles not created until after all CreateFcns called % Hint: edit controls usually have a white background on Windows. end function B_Callback(hObject. if ispc && isequal(get(hObject. end function C_Callback(hObject.to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % Hints: get(hObject. get(0.to be defined in a future version of MATLAB % handles empty . eventdata.to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % Hints: get(hObject.function D_Callback(hObject.'String')) returns contents of D as a double % --.'String') returns contents of D as text % str2double(get(hObject.Executes during object creation. get(0.'BackgroundColor').to be defined in a future version of MATLAB % handles empty . function D_CreateFcn(hObject. if ispc && isequal(get(hObject. handles) % hObject handle to D (see GCBO) % eventdata reserved . % See ISPC and COMPUTER.'defaultUicontrolBackgr oundColor')) set(hObject.'BackgroundColor'). eventdata. function C_CreateFcn(hObject.'String')) returns contents of B as a double .'white').'defaultUicontrolBackgr oundColor')) set(hObject. after setting all properties. eventdata.'String')) returns contents of C as a double % --.'String') returns contents of B as text % str2double(get(hObject. handles) % hObject handle to D (see GCBO) % eventdata reserved .

handles) % hObject handle to B (see GCBO) % eventdata reserved .'white'). end function A_Callback(hObject.to be defined in a future version of MATLAB % handles empty . after setting all properties. if ispc && isequal(get(hObject.'BackgroundColor').'String')) returns contents of A as a double % --. handles) % hObject handle to hasil (see GCBO) % eventdata reserved .'BackgroundColor'.'BackgroundColor'.'BackgroundColor'). get(0.'String') returns contents of A as text % str2double(get(hObject. handles) % hObject handle to hasil (see GCBO) % eventdata reserved .Executes during object creation.to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % Hints: get(hObject.'defaultUicontrolBackgr oundColor')) set(hObject. eventdata.'defaultUicontrolBackgr oundColor')) set(hObject. end function hasil_Callback(hObject. end . eventdata.Executes during object creation.to be defined in a future version of MATLAB % handles empty . handles) % hObject handle to A (see GCBO) % eventdata reserved .handles not created until after all CreateFcns called % Hint: edit controls usually have a white background on Windows. if ispc && isequal(get(hObject.handles not created until after all CreateFcns called % Hint: edit controls usually have a white background on Windows. % See ISPC and COMPUTER. % See ISPC and COMPUTER. get(0.to be defined in a future version of MATLAB % handles empty .% --. function B_CreateFcn(hObject.to be defined in a future version of MATLAB % handles structure with handles and user data (see GUIDATA) % Hints: get(hObject.'BackgroundColor').'defaultUicontrolBackgr oundColor')) set(hObject. function A_CreateFcn(hObject. function hasil_CreateFcn(hObject. eventdata. if ispc && isequal(get(hObject.'String')) returns contents of hasil as a double % --. eventdata. get(0.'String') returns contents of hasil as text % str2double(get(hObject.'BackgroundColor'. after setting all properties.Executes during object creation. eventdata. after setting all properties.handles not created until after all CreateFcns called % Hint: edit controls usually have a white background on Windows.'white'). % See ISPC and COMPUTER.'white'). handles) % hObject handle to A (see GCBO) % eventdata reserved .

Sign up to vote on this title
UsefulNot useful