-
- s1 = vrml_frame ("scale",[1 2 3],"col",eye (3), "hcol",0.5*[1 1 1]);
s2 = vrml_Background ("skyColor",[3 3 9]/10,"groundColor",[3 8 3]/10);
vrml_browse ([s1,s2]);
We now describe the function
- s = vrml_cyl (x,...)
- that returns VRML code
representing 3D line segments (in fact, cylinders) whose
extremities are [x(:,i),x(:,i+1)], for i in
(x is a a
matrix). Amongst other things, the radius, color and transparency
can be set. Also, spheres centered at each x(:,i) can be
added, and an arrow can be used to indicate the last segment. The
corresponding options are :
- "rad", rad
- The radius of the
cylinders linking each pair of consecutive points.
- "col", col
or
The RGB color(s) of the cylinders.
- "tran", col
- The transparency
of the cylinders.
- "balls"
- Add a spheres around
each x(:,i).
- "arrow"
- Represent the last segment
as an arrow.
Søren Hauberg
2009-06-07