Filter löschen
Filter löschen

Creating Graphical User Interface for a Code

2 Ansichten (letzte 30 Tage)
Pranjal Pathak
Pranjal Pathak am 18 Jul. 2013
Hi,
Here I am adding a simple code:
mx=20; my=5;
[x,y]=meshgrid(-1:2/127:1, -1:2/127:1); circ=sqrt(x.^2+y.^2)<1; H=circ.*(cos((x*pi*mx)+(y*pi*my)))>0;
figure(1) imagesc(H); colormap gray; axis image; axis off
%Fourier Transform z=fft2(H, 512,512); m=fftshift(z); q=abs(m);
figure(2) imagesc(q); colormap gray; axis image; axis off
I have no idea how to make a GUI out of this code so that I have the value of 'mx' and 'my' as input and the figures as output in Matlab. Can anyone help me in this regard?
Thanking You!

Antworten (1)

Chad Gilbert
Chad Gilbert am 18 Jul. 2013
Bearbeitet: Chad Gilbert am 18 Jul. 2013
If you are new to MATLAB GUI programming, your best bet is to use GUIDE. Type 'guide' on the MATLAB command line to begin. There are many tutorials listed here: https://www.mathworks.com/matlabcentral/answers/30070-gui-guide-tutorials
Good luck!

Kategorien

Mehr zu Graphics Object Properties finden Sie in Help Center und File Exchange

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by