• 大小: 95KB
    文件类型: .zip
    金币: 1
    下载: 0 次
    发布日期: 2021-05-28
  • 语言: Matlab
  • 标签: MATLAB  GUI  图像处理  

资源简介

一个实例搞定MATLAB GUI界面设计,以图像二值化处理为例。

资源截图

代码片段和文件信息

function varargout = im2bw_args(varargin)
% IM2BW_ARGS MATLAB code for im2bw_args.fig
%      IM2BW_ARGS by itself creates a new IM2BW_ARGS or raises the existing
%      singleton*.
%
%      H = IM2BW_ARGS returns the handle to a new IM2BW_ARGS or the handle to
%      the existing singleton*.
%
%      IM2BW_ARGS(‘CALLBACK‘hobjecteventDatahandles...) calls the local
%      function named CALLBACK in IM2BW_ARGS.M with the given input arguments.
%
%      IM2BW_ARGS(‘Property‘‘Value‘...) creates a new IM2BW_ARGS or raises the
%      existing singleton*.  Starting from the left property value pairs are
%      applied to the GUI before im2bw_args_OpeningFcn gets called.  An
%      unrecognized property name or invalid value makes property application
%      stop.  All inputs are passed to im2bw_args_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 im2bw_args

% Last Modified by GUIDE v2.5 23-Oct-2018 10:10:27

% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct(‘gui_Name‘       mfilename ...
                   ‘gui_Singleton‘  gui_Singleton ...
                   ‘gui_OpeningFcn‘ @im2bw_args_OpeningFcn ...
                   ‘gui_OutputFcn‘  @im2bw_args_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 im2bw_args is made visible.
function im2bw_args_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 im2bw_args (see VARARGIN)
h_zcimage = findobj(‘Tag‘ ‘figure_zcimage‘);
h_zcimage = guihandles(h_zcimage);
setappdata(handles.figure_im2bw ‘h_zcimage‘h_zcimage);


% Choose default command line output for im2bw_args
handles.output = hobject;

% Update handles structure
guidata(hobject handles);

% UIWAIT makes im2bw_args wait for user response (see UIRESUME)
% uiwait(handles.figure_im2bw);


% --- Outputs from this function are returned to the command line.
function varargout = im2bw_args_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;


% --- Exe

 属性            大小     日期    时间   名称
----------- ---------  ---------- -----  ----
     文件       49706  2018-10-23 09:45  MATLAB GUI 图像二值化处理\dog_test.jpg
     文件        6298  2018-10-23 13:56  MATLAB GUI 图像二值化处理\im2bw_args.fig
     文件        4183  2018-10-23 14:52  MATLAB GUI 图像二值化处理\im2bw_args.m
     文件       37862  2018-10-23 17:30  MATLAB GUI 图像二值化处理\zcimage.fig
     文件        9497  2018-10-26 16:35  MATLAB GUI 图像二值化处理\zcimage.m
     目录           0  2018-10-26 16:42  MATLAB GUI 图像二值化处理\

评论

共有 条评论