Skip to content

Commit

Permalink
Minie: comments
Browse files Browse the repository at this point in the history
  • Loading branch information
stephengold committed Sep 10, 2018
1 parent 97b4acc commit 6d3a5de
Show file tree
Hide file tree
Showing 4 changed files with 18 additions and 26 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -66,7 +66,7 @@ public abstract class CollisionShape implements Savable {
*/
final protected Vector3f scale = new Vector3f(1f, 1f, 1f);
/**
* collision margin (in physics-world units, ≥0, default=0)
* collision margin (in physics-space units, ≥0, default=0)
*/
protected float margin = 0f;

Expand Down Expand Up @@ -116,7 +116,7 @@ public Vector3f getScale() {
/**
* Read the collision margin for this shape.
*
* @return the margin distance (in physics-world units, ≥0)
* @return the margin distance (in physics-space units, ≥0)
*/
public float getMargin() {
return getMargin(objectId);
Expand All @@ -131,7 +131,7 @@ public float getMargin() {
* Note that if the shape is shared (between collision objects and/or
* compound shapes) changes can have unintended consequences.
*
* @param margin the desired margin distance (in physics-world units, ≥0,
* @param margin the desired margin distance (in physics-space units, ≥0,
* default=0)
*/
public void setMargin(float margin) {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -68,14 +68,10 @@ public SimplexCollisionShape() {
/**
* Instantiate a tetrahedral collision shape based on the specified points.
*
* @param point1 the world coordinates of 1st point (not null, alias
* created) TODO
* @param point2 the world coordinates of 2nd point (not null, alias
* created) TODO
* @param point3 the world coordinates of 3rd point (not null, alias
* created) TODO
* @param point4 the world coordinates of 4th point (not null, alias
* created) TODO
* @param point1 the coordinates of 1st point (not null, alias created) TODO
* @param point2 the coordinates of 2nd point (not null, alias created) TODO
* @param point3 the coordinates of 3rd point (not null, alias created) TODO
* @param point4 the coordinates of 4th point (not null, alias created) TODO
*/
public SimplexCollisionShape(Vector3f point1, Vector3f point2,
Vector3f point3, Vector3f point4) {
Expand All @@ -89,12 +85,9 @@ public SimplexCollisionShape(Vector3f point1, Vector3f point2,
/**
* Instantiate a triangular collision shape based on the specified points.
*
* @param point1 the world coordinates of 1st point (not null, alias
* created) TODO
* @param point2 the world coordinates of 2nd point (not null, alias
* created) TODO
* @param point3 the world coordinates of 3rd point (not null, alias
* created) TODO
* @param point1 the coordinates of 1st point (not null, alias created) TODO
* @param point2 the coordinates of 2nd point (not null, alias created) TODO
* @param point3 the coordinates of 3rd point (not null, alias created) TODO
*/
public SimplexCollisionShape(Vector3f point1, Vector3f point2,
Vector3f point3) {
Expand All @@ -107,10 +100,8 @@ public SimplexCollisionShape(Vector3f point1, Vector3f point2,
/**
* Instantiate a line-segment collision shape based on the specified points.
*
* @param point1 the world coordinates of 1st point (not null, alias
* created) TODO
* @param point2 the world coordinates of 2nd point (not null, alias
* created) TODO
* @param point1 the coordinates of 1st point (not null, alias created) TODO
* @param point2 the coordinates of 2nd point (not null, alias created) TODO
*/
public SimplexCollisionShape(Vector3f point1, Vector3f point2) {
vector1 = point1;
Expand All @@ -121,8 +112,7 @@ public SimplexCollisionShape(Vector3f point1, Vector3f point2) {
/**
* Instantiate a point collision shape based on the specified points.
*
* @param point1 the world coordinates of point (not null, alias created)
* TODO
* @param point1 the coordinates of point (not null, alias created) TODO
*/
public SimplexCollisionShape(Vector3f point1) {
vector1 = point1;
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -164,7 +164,8 @@ public void setApplyPhysicsLocal(boolean applyPhysicsLocal) {
/**
* Access whichever spatial translation corresponds to the physics location.
*
* @return the pre-existing coordinate vector (not null) TODO
* @return the pre-existing location vector (in physics-space coordinates,
* not null) TODO
*/
protected Vector3f getSpatialTranslation() {
if (MySpatial.isIgnoringTransforms(spatial)) {
Expand All @@ -179,7 +180,8 @@ protected Vector3f getSpatialTranslation() {
/**
* Access whichever spatial rotation corresponds to the physics rotation.
*
* @return the pre-existing quaternion (not null)
* @return the pre-existing quaternion (in physics-space coordinates, not
* null)
*/
protected Quaternion getSpatialRotation() {
if (MySpatial.isIgnoringTransforms(spatial)) {
Expand Down
2 changes: 1 addition & 1 deletion Minie/src/main/java/jme3utilities/minie/MyShape.java
Original file line number Diff line number Diff line change
Expand Up @@ -476,7 +476,7 @@ public static CollisionShape setRadius(CollisionShape oldShape,
* Compute the volume of a closed collision shape.
*
* @param shape (not null, unaffected)
* @return the volume in cubic physics-world units (≥0)
* @return the volume in cubic physics-space units (≥0)
*/
public static float volume(CollisionShape shape) {
Vector3f scale = shape.getScale();
Expand Down

0 comments on commit 6d3a5de

Please sign in to comment.