< Zurück | Inhalt | Weiter >

8.2.4 Sphere

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.Sphere


The Sphere Primitive defines a sphere with 15 divisions in both the X− and Y−axes, illustrated in figures 8.6 through 8.8. Use the most customizable form of the constructor to vary the number of surfaces created for the Sphere:


public Sphere(float radius, int primflags, int divisions, Appearance ap)


image


Figure 8.6

image

The Sphere Primitive (low resolution)


Figure 8.7


image

The Sphere Primitive (high resolution)


Figure 8.8


Sphere Primitive with an applied texture image of the Earth