plot circle with gradient gray scale color in matlab -



plot circle with gradient gray scale color in matlab -

i want draw circle gradient color in matlab, can't. there 1 can help me?

the sample image can found here

here's 1 approach -

n = 200; %// decides size of image [x,y] = meshgrid(-1:1/n:1, -1:1/n:1) ; nrm = sqrt(x.^2 + y.^2); out = uint8(255*(nrm/min(nrm(:,1)))); %// output image figure, imshow(out) %// show image

output -

if pad output white boundary shown in expect output image, can padarray -

padsize = 50; %// decides boundary width out = padarray(out,[padsize padsize],255);

matlab

Comments

Popular posts from this blog

xslt - DocBook 5 to PDF transform failing with error: "fo:flow" is missing child elements. Required content model: marker* -

mediawiki - How do I insert tables inside infoboxes on Wikia pages? -

Local Service User Logged into Windows -