Physics | Code Zealot

Browsing the archives for the Physics tag

dyn4j Project Setup Video

in Game Development, General, Java, Physics

I finally got some time to create my first How-To video for the dyn4j project.  The first video describes how to setup a Java project in Eclipse to use dyn4j.  It’s short and hopefully to the point.

2 Comments

Contact Points Using Clipping

in Collision Detection, Game Development, Physics

Many have asked “How do I get the contact points from GJK?” or similar on the SAT, GJK, and EPA posts. I’ve finally got around to creating a post on this topic. Contact point generation is a vital piece of many applications and is usually the next step after collision detection. Generating good contact points […]

35 Comments

Prismatic Constraint

in Constrained Dynamics, Game Development, Physics

The next equality constraint we will derive is the prismatic constraint. A prismatic constraint is like the line constraint except it does not allow rotation about the anchor point. A prismatic constraint constraints the linear motion of the bodies along a line. An example of a prismatic joint is the slide of a semi-automatic pistol. […]

7 Comments

Line Constraint

in Constrained Dynamics, Game Development, Physics

The next equality constraint we will derive is the line constraint. A line constraint is like a prismatic constraint (which will most likely be the next post) except allows rotation about the anchor point. A prismatic constraint constraints the linear motion of the bodies along a line. An example of a prismatic joint might be […]

5 Comments

Weld Constraint

in Constrained Dynamics, Game Development, Physics

The next equality constraint we will derive is the weld constraint. A weld constraint can be used to join two bodies at an anchor point in which the bodies must move and rotate together (all DOF are constrained). This post will differ slightly from the previous posts. A weld joint is basically a revolute joint […]

4 Comments

Angle Constraint

in Constrained Dynamics, Game Development, Physics

The next equality constraint we will derive is the angle constraint. An angle constraint can be used to join two bodies forcing them to have the same rotation. This particular constraint will be added to other constraints (in later posts) to form more complex constraints.

8 Comments

Pulley Constraint

in Constrained Dynamics, Game Development, Physics

The next equality constraint we will derive is the pulley constraint. A pulley constraint can be used to join two bodies at a fixed distance. In addition, the constraint can be used to simulate a block-and-tackle.

7 Comments

Max Distance Constraint

in Constrained Dynamics, Game Development, Physics

As a follow up post to the Distance Constraint post, we can also create a maximum distance constraint using the same solution we found in the Distance Constraint post. The previous solution created a fixed length distance constraint which forced a pair of bodies to be a given length apart. We can simply add an […]

4 Comments

Distance Constraint

in Constrained Dynamics, Game Development, Physics

The next equality constraint we will derive is the distance constraint. A distance constraint can be used to join two bodies at a fixed distance. It can also be used as a spring between two bodies.

6 Comments

Point-to-Point Constraint

in Constrained Dynamics, Game Development, Physics

As the first entry after the Equality Constraints post, we will perform the derivation of the Point-to-Point constraint, which models a Revolute Joint, in 2D.

17 Comments