3D Animated JavaScript Bézier Curves

A series of points move through the scene with Bézier curves between them.

Each frame, the points to be rendered are projected from their 3D coordinates to 2D screen-space. From these, control points are determined using the algorithm described by Rob Spencer. A faux distance fog is added by decreasing the opacity of lines closer to the back. After rendering, the points have their z-value increased and if they move outside of the viewing area, are reset to the back

The slider adjusts how far the control points are from each point.

Not seeing anything?
This demo requires the HTML5 canvas and support for requestAnimationFrame.