[scilab-Users] Plot3d1 with spheres in diffrent colors, how?
Calixte
calixte.denizet at scilab-enterprises.com
Sun Jan 29 20:31:50 CET 2012
On 29/01/2012 20:06, Constellation Athome wrote:
> Hi there,
Hi,
In taking the example given in plot3d.html, you can make something like:
deff("[x,y,z]=sph(alp,tet)",["x=r*cos(alp).*cos(tet)+orig(1)*ones(tet)";..
"y=r*cos(alp).*sin(tet)+orig(2)*ones(tet)";..
"z=r*sin(alp)+orig(3)*ones(tet)"]);
r=1; orig=[0 0 0];
[xx,yy,zz]=eval3dp(sph,linspace(-%pi/2,%pi/2,40),linspace(0,%pi*2,20));
clf();
plot3d(xx,yy,zz)
plot3d(xx,yy,zz + 2.5)
a=gca();
a.children(1).color_mode = 3;
a.children(2).color_mode = 5;
You should have a look at:
http://help.scilab.org/docs/5.3.3/en_US/surface_properties.html
Regards,
Calixte
>
> I would like to give each sphere in my plot3d1 plot a different color
> so that I can distinguish them better.
> I played around with
> http://help.scilab.org/docs/5.3.3/en_US/plot3d.html but couldn't find
> a way to change it to rgb colours or whatever, to have a red, a green
> and another colour.
>
> It would be great, if you could help me.
> And another question is, how to add opacity so that they will be
> translucent.
>
> Thanks in advance,
>
> Andreas
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.scilab.org/pipermail/users/attachments/20120129/b102ab89/attachment.htm>
More information about the users
mailing list