8.2.3 Cylinder

java.lang.Object

|

+−−javax.media.j3d.SceneGraphObject

|

+−−javax.media.j3d.Node

|

+−−javax.media.j3d.Group

|

+−−com.sun.j3d.utils.geometry.Primitive

|

+−−com.sun.j3d.utils.geometry.Cylinder

The Cylinder Primitive defines a capped cylinder, illustrated in figure 8.5. Cylinder is composed from three Shape3D components: Body, Top disk, and Bottom disk.

Figure 8.5

The Cylinder Primitive

int BODY = 0;

int TOP = 1;

int BOTTOM = 2;

The default number of surfaces created for the body is 15 along the X−axis and 1 along the Y−axis, the disks are created as 15−sided polygons. Again, use the most complex form of the constructor to vary the number of surfaces generated for the cylinder:

public Cylinder(float radius, float height, int primflags, int xdivision, int ydivision, Appearance ap) {

 Impressum und Datenschutz    Copyright ©2018 eir.me Siebel Articles Python Perl 5 Documentation Manuel PHP7 français Java Das PHP7 Handbuch PHP7 Manual English Linux and Unix Jobs