[Image processing] Based on matlab image RGB three-color synthesis and separation [including Matlab source code 401]

1. Introduction

Based on matlab image RGB three-color synthesis and separation

Second, the source code

function varargout = rgb1(varargin)
% RGB1 M-file for rgb1.fig
%      RGB1, by itself, creates a new RGB1 or raises the existing
%      singleton*.
%
%      H = RGB1 returns the handle to a new RGB1 or the handle to
%      the existing singleton*.
%
%      RGB1('CALLBACK',hObject,eventData,handles,...) calls the local
%      function named CALLBACK in RGB1.M with the given input arguments.
%
%      RGB1('Property','Value',...) creates a new RGB1 or raises the
%      existing singleton*.  Starting from the left, property value pairs are
%      applied to the GUI before rgb1_OpeningFunction gets called.  An
%      unrecognized property name or invalid value makes property application
%      stop.  All inputs are passed to rgb1_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

% Copyright 2002-2003 The MathWorks, Inc.

% Edit the above text to modify the response to help rgb1

% Last Modified by GUIDE v2.5 17-Dec-2008 10:31:18

% Begin initialization code - DO NOT EDIT
gui_Singleton = 1;
gui_State = struct('gui_Name',       mfilename, ...
                   'gui_Singleton',  gui_Singleton, ...
                   'gui_OpeningFcn', @rgb1_OpeningFcn, ...
                   'gui_OutputFcn',  @rgb1_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 rgb1 is made visible.
function rgb1_OpeningFcn(hObject, eventdata, handles, varargin)
A=imread('aa.jpg');
axes(handles.axes1);
imshow(A);

% 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 rgb1 (see VARARGIN)

% Choose default command line output for rgb1
handles.output = hObject;

% Update handles structure
guidata(hObject, handles);

% UIWAIT makes rgb1 wait for user response (see UIRESUME)
% uiwait(handles.figure1);


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


% --- Executes on selection change in popupmenu1.
function popupmenu1_Callback(hObject, eventdata, handles)
global A;
val=get(hObject,'value');
if(val==1)
    A=imread('aa.jpg');
elseif(val==2)
    A=imread('a.jpg');
elseif(val==3)
    A=imread('b.jpg');
end
axes(handles.axes1);
imshow(A);
% hObject    handle to popupmenu1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    structure with handles and user data (see GUIDATA)

% Hints: contents = get(hObject,'String') returns popupmenu1 contents as cell array
%        contents{
    
    get(hObject,'Value')} returns selected item from popupmenu1


% --- Executes during object creation, after setting all properties.
function popupmenu1_CreateFcn(hObject, eventdata, handles)
% hObject    handle to popupmenu1 (see GCBO)
% eventdata  reserved - to be defined in a future version of MATLAB
% handles    empty - handles not created until after all CreateFcns called

% Hint: popupmenu controls usually have a white background on Windows.
%       See ISPC and COMPUTER.
if ispc
    set(hObject,'BackgroundColor','white');
else
    set(hObject,'BackgroundColor',get(0,'defaultUicontrolBackgroundColor'));
end

Three, running results

Insert picture description here

Insert picture description here

Insert picture description here

Four, remarks

Complete code or writing add QQ 1564658423 past review
>>>>>>
[Signal processing] matlab HMM-based sleep detection [including Matlab source code 050]
[Signal processing] based on matlab CDR noise and reverberation suppression [including Matlab Source code 051]
[Signal processing] based on matlab least squares method to solve the sparse signal recovery problem [including Matlab source code 052]
[Signal processing] Matlab wavelet transform-based audio watermark embedding and extraction [including Matlab source code 053]
[Signal processing] based on Matlab ICA algorithm signal separation [Including Matlab source code 054]
[Signal processing] Pulse rate archive of pulse signals based on matlab GUI interface [Including Matlab source code 237]
[Signal processing] Virtual signal generator based on matlab GUI interface (various Waveform) [Contains Matlab source code 271 period]
[Signal processing] Matlab GUI interface signal generator-based electronic keyboard [Contains Matlab source code 272]
[Signal processing] Matlab-based digital keyboard design and implementation [Contains Matlab source code 273]
[Radar Communication] Matlab-based radar digital signal processing [including Matlab source code 281]
[Radar communication] Matlab linear frequency modulation (LFM) pulse compression radar simulation [including Matlab source code 283]
[Radar communication] Based on mtatlab range Doppler (RD ), CS, RM algorithm for airborne radar imaging [including Matlab source code 284]
[Radar Communication] "Modern Radar System Analysis and Design" major task [including Matlab source code 285]
[Signal processing] based on matlab GUI voice signal integrated processing Platform [including Matlab source code 290 period]
[Signal processing] based on matlab GUI voice signal acquisition [including Matlab source code 291]
[Signal processing] based on matlab GUI voice amplitude modulation [including Matlab source code 292]
[Signal processing] based on matlab GUI voice synthesis [including Matlab source code 293]
[Signal processing] based on matlab GUI voice fundamental frequency recognition [including Matlab source code 294]
[Signal processing] based on matlab GUI voice signal encryption and decryption [including Matlab source code 295]
[Signal processing] based on matlab wavelet transform voice enhancement [including Matlab Source code 296]
[Signal processing] based on matlab GUI voice Fourier transform noise reduction and mixing [Include Matlab source code 297]
[Signal processing] Based on matlab GUI Wiener filter voice enhancement [Include Matlab source code 298]
[Audio processing] Based on Matlab GUI voice signal processing 2 [including Matlab source code 299]
[Radar communication] based on matlab GUI radar positioning [including Matlab source code 302]
[Radar communication] based on matlab GUI radar pulse compression [including Matlab source code 303]
[Radar communication] Radar positioning simulation based on matlab GUI [including Matlab source code 304]
[Radar communication] Based on matlab SVM to identify radar data [including Matlab source code 305] ## Title
[Edge detection] Sub-pixel edge detection based on matlab interpolation [including Matlab source code 306 Issue]
[Pattern Recognition] Bayesian Minimum Error Rate Handwritten Digit Recognition Based on Matlab GUI [Including Matlab Source Code 308 Issue]
[Pattern recognition] based on matlab PCA handwritten digit recognition [including Matlab source code 309]
[Pattern recognition] based on matlab feature matching English printed character recognition [including Matlab source code 310]
[ Pattern recognition] based on matlab knowledge base handwritten digital recognition [ Include Matlab source code 311]
[Pattern recognition] Matlab-based bank card digital recognition [Include Matlab source code 312]
[Image recognition] Based on matlab expression detection [Include Matlab source code 317]
[Image detection] Based on matlab LSD straight line detection [Include Matlab source code 318]
[image fusion] infrared and visible light fusion and registration algorithm [including Matlab source code 319]
[image recognition] based on matlab frame difference method fall detection [including Matlab source code 320]
[image recognition] based on matlab combination BCOSFIRE filter for wall crack recognition [Including Matlab source code 321]
[Pattern recognition] Matlab median filtering and binarization based fall detection [Including Matlab source code 344]
[Image steganography] Image steganography based on matlab DCT [Include Matlab source code 365 period]
[Image steganography] Image steganography extraction based on matlab LSB [Include Matlab source code 366 period]
[Image steganography] JPEG image steganography based on matlab Gaussian model [Include Matlab source code period 367]
[Image Steganography] based on matlab image adaptive steganography algorithm wow [including Matlab source code 368 period]
[Pattern recognition] based on matlab GUI SVM and PCA face recognition [including Matlab source code 369 period]
[Video recognition] based on matlab trajectory method behavior recognition [including Matlab source code 375]
[Pattern recognition] based on matlab GUI HSV and RGB model fruit classification [including Matlab source code 380]
[Image processing] based on matlab GUI digital image processing platform [including Matlab source code 381]
[Image segmentation] Matlab-based retinal image segmentation [With Matlab source code 382]
[Pattern recognition] Matlab k-means clustering-based gesture recognition [Matlab source code 386]
[Image processing] Based on Hough transform Human eye iris location [Include Matlab source code 387]
[Image processing] Matlab Kalman filter based target tracking [Matlab source code 388 included]
[Image segmentation] Based on matlab GAC level set method to achieve image segmentation [Matlab source code 389 included]
[Image segmentation] Image segmentation based on matlab watershed algorithm [Including Matlab source code 390]
[Image denoising] Image denoising based on wavelet transform [Including Matlab source code 391]
[Image fusion] Image fusion based on matlab wavelet transform [Including Matlab source code issue 392]
[image recognition] based on matlab image recognition object count [including Matlab source code 393]
[image enhancement] based on matlab fuzzy set image enhancement [including Matlab source code 394]
[image retrieval] based on the integrated features of matlab GUI Image retrieval [including Matlab source code 395]

Guess you like

Origin blog.csdn.net/TIQCmatlab/article/details/114126826