Dome.java: Updated javadoc to explain effect of parameters and to distinguish between use as SkyDome, pyramid, or cone. Renamed inverted boolean.

git-svn-id: https://jmonkeyengine.googlecode.com/svn/trunk@8040 75d07b2b-3a1a-0410-a2c5-0572b91ccdca
3.0
roo..li 13 years ago
parent d6574a8cc7
commit 3877740cd8
  1. 48
      engine/src/core/com/jme3/scene/shape/Dome.java

@ -70,15 +70,14 @@ public class Dome extends Mesh {
} }
/** /**
* Constructs a dome with center at the origin. For details, see the other * Constructs a dome for use as a SkyDome. The SkyDome is centered at the origin
* constructor. * and only visible from the inside.
*
* @param name
* Name of dome.
* @param planes * @param planes
* The number of planes along the Z-axis. * The number of planes along the Z-axis. Must be >= 2.
* Influences how round the arch of the dome is.
* @param radialSamples * @param radialSamples
* The samples along the radial. * The number of samples along the radial.
* Influences how round the base of the dome is.
* @param radius * @param radius
* Radius of the dome. * Radius of the dome.
* @see #Dome(java.lang.String, com.jme.math.Vector3f, int, int, float) * @see #Dome(java.lang.String, com.jme.math.Vector3f, int, int, float)
@ -88,17 +87,19 @@ public class Dome extends Mesh {
} }
/** /**
* Constructs a dome. All geometry data buffers are updated automatically. * Constructs a dome visible from the inside, e.g. for use as a SkyDome.
* Both planes and radialSamples increase the quality of the generated dome. * All geometry data buffers are updated automatically. <br>
* For a cone, set planes=2. For a pyramid, set radialSamples=4 and planes=2.
* Increasing planes and radialSamples increase the quality of the dome.
* *
* @param name
* Name of the dome.
* @param center * @param center
* Center of the dome. * Center of the dome.
* @param planes * @param planes
* The number of planes along the Z-axis. * The number of planes along the Z-axis. Must be >= 2.
* Influences how round the arch of the dome is.
* @param radialSamples * @param radialSamples
* The number of samples along the radial. * The number of samples along the radial.
* Influences how round the base of the dome is.
* @param radius * @param radius
* The radius of the dome. * The radius of the dome.
*/ */
@ -109,25 +110,30 @@ public class Dome extends Mesh {
} }
/** /**
* Constructs a dome. All geometry data buffers are updated automatically. * Constructs a dome. Use this constructor for half-sphere, pyramids, or cones.
* Both planes and radialSamples increase the quality of the generated dome. * All geometry data buffers are updated automatically. <br>
* For a cone, set planes=2. For a pyramid, set radialSamples=4 and planes=2.
* Setting higher values for planes and radialSamples increases
* the quality of the half-sphere.
* *
* @param center * @param center
* Center of the dome. * Center of the dome.
* @param planes * @param planes
* The number of planes along the Z-axis. * The number of planes along the Z-axis. Must be >= 2.
* Influences how round the arch of the dome is.
* @param radialSamples * @param radialSamples
* The number of samples along the radial. * The number of samples along the radial.
* Influences how round the base of the dome is.
* @param radius * @param radius
* The radius of the dome. * The radius of the dome.
* @param outsideView * @param insideView
* If true, the triangles will be connected for a view outside of * If true, the dome is only visible from the inside, like a SkyDome.
* the dome. * If false, the dome is only visible from the outside.
*/ */
public Dome(Vector3f center, int planes, int radialSamples, public Dome(Vector3f center, int planes, int radialSamples,
float radius, boolean outsideView) { float radius, boolean insideView) {
super(); super();
updateGeometry(center, planes, radialSamples, radius, outsideView); updateGeometry(center, planes, radialSamples, radius, insideView);
} }
public Vector3f getCenter() { public Vector3f getCenter() {

Loading…
Cancel
Save