summaryrefslogtreecommitdiff
path: root/src/alden/HalfSpace.java
diff options
context:
space:
mode:
authorJesse Morgan <jesse@jesterpm.net>2011-02-12 18:57:14 +0000
committerJesse Morgan <jesse@jesterpm.net>2011-02-12 18:57:14 +0000
commitc663dffc86a7fcec9f05aaf8a107e6200a35c2fa (patch)
tree4642d001dddf0042854c77cafd245b37cb9062ee /src/alden/HalfSpace.java
parent354a7aa455a016ac179d7f027014e6b9c2a2433a (diff)
Added HalfSpaces to the bounds. Fixed collisions and particle emitters. Corrected typo in PlanarPolygonMenuItem. Added removeForce() to world and cleaned up the force adding/removing.
Diffstat (limited to 'src/alden/HalfSpace.java')
-rw-r--r--src/alden/HalfSpace.java28
1 files changed, 0 insertions, 28 deletions
diff --git a/src/alden/HalfSpace.java b/src/alden/HalfSpace.java
deleted file mode 100644
index 6e414fb..0000000
--- a/src/alden/HalfSpace.java
+++ /dev/null
@@ -1,28 +0,0 @@
-package alden;
-
-import javax.vecmath.Vector3f;
-
-@SuppressWarnings("restriction")
-public class HalfSpace extends CollidableObject {
- protected Vector3f normal;
- // Right-hand side of the plane equation: Ax + By + Cz = D
- protected float intercept;
-
- public HalfSpace(Vector3f position, Vector3f normal) {
- super(Float.POSITIVE_INFINITY);
- this.position.set(position);
- this.normal = new Vector3f(normal);
- this.normal.normalize();
- intercept = this.normal.dot(position);
- }
-
-/* public CollisionInfo calculateCollision(Particle particle) {
- if (Math.signum(normal.dot(particle.getPosition()) - intercept) == Math.signum(normal.dot(particle.getPreviousPosition()) - intercept))
- return null;
-
- Vector3f projection = new Vector3f();
- projection.scaleAdd(-1, position, particle.getPosition());
- float penetration = -projection.dot(normal);
- return new CollisionInfo(normal, penetration);
- }*/
-}