Path: news.mathworks.com!not-for-mail
From: <HIDDEN>
Newsgroups: comp.soft-sys.matlab
Subject: Re: Lighting help!
Date: Tue, 18 Aug 2009 06:25:20 +0000 (UTC)
Organization: The MathWorks, Inc.
Lines: 33
Message-ID: <h6dhgg$k24$1@fred.mathworks.com>
References: <h68caa$knd$1@fred.mathworks.com>
Reply-To: <HIDDEN>
NNTP-Posting-Host: webapp-05-blr.mathworks.com
Content-Type: text/plain; charset="ISO-8859-1"
Content-Transfer-Encoding: 8bit
X-Trace: fred.mathworks.com 1250576720 20548 172.30.248.35 (18 Aug 2009 06:25:20 GMT)
X-Complaints-To: news@mathworks.com
NNTP-Posting-Date: Tue, 18 Aug 2009 06:25:20 +0000 (UTC)
X-Newsreader: MATLAB Central Newsreader 1477385
Xref: news.mathworks.com comp.soft-sys.matlab:564105


Here is my newest effort.

close gcf
[X,Y,Z] = cylinder([5,5],140);
s = surf(X,Y,Z.*1);

shading interp

axis off

set(gcf,'color','w')
rotate(s,[1,0,0],90)
rotate(s,[0,1,0],90)

a=zeros(255,3);
a(:,2)=transpose(linspace(.5,.7,255));

colormap(a);

r = [7,-.5,1];

light('position',r,'style','loc')

r = [7,.5,1];

light('position',r,'style','loc')

rotate3d

view(90,0)
axis square

Anything better?