Limit charge distance.
Optimize charge calculation.
Fix clipExtent bug.

If a polygon does not intersect with the extent, but has one or more
rings inside the extent, then the extent should be checked to see
whether it is inside the polygon: if so, an additional exterior ring is
generated.

Previously, this check was only made if there were no visible rings at
all.

Fixes an issue noticed in #1453.
Simplify.
Perform winding order check on unrotated polygons.

We remove the rotation step that occurred prior to clipping, so that
clipping processes unrotated polygons.  Note that clip regions are
defined relative to the rotated globe, so clipping now needs a rotation
parameter.

Rather than moving the rotation step so it occurs after clipping, the
rotation occurs as part of clipping, using the rotation parameter to
rotate streamed points.  Alternatively, points could be clipped against
a rotated clip region, and then subsequently rotated as a separate step,
but this seems slightly less efficient.

Fixes #1453.
Simplify.
Prevent tick at t = 0.

This is especially important for a zero-duration transition, where the duration
is actually one millisecond, and we want the only tick to be at t = 1.
Wrap longitudes in d3_geo_rotation.
Optimise.
Consolidate.
Yay τ!
Move benchmark.
Optimize hyperbolic functions.

Not used much, but still an improvement. http://jsperf.com/hyperbolics
Merge remote-tracking branch 'origin/fix-clip-extent' into 3.3.6
Fix clipping bug for complex polygons.

Intersection points are sorted along the clipping region edge relative
to a particular point.  In the case of antimeridian clipping, this point
is the South pole.  Previously, the first intersection was assumed to be
an entering intersection, but this is not always the case.

The fix is to see whether the clip region start point (the point
relative to which sorting occurs) is inside or outside the polygon being
drawn.  If it is inside, then the first intersection point must be
outside, and so forth.

The same applies to d3.geo.clipExtent.  Provision was already made for
this, but this has now been optimised to use a single point instead of
picking one of the four corners.

Another optimisation was to reuse this clip region start point to
determine whether to interpolate all the way around the clip region
edge.  Previously, this was done by testing an arbitrary point in the
clip region.

The above fix seemed to have broken one of the tests, and this has been
fixed by modifying the point-in-polygon routine slightly to handle
points that might lie exactly on the polygon edge.

Finally, I noticed a regression with the recent clipExtent fix, where a
polygon incorrectly being marked as “clean” (no intersections) on a
per-ring instead of per-polygon basis.
Don’t pollute an ordinal scale’s domain.

Fixes #1550. By using the copy of the new scale (which we make anyway for a
snapshot) we avoid polluting the scale’s domain with the old values when using
the scale as the key function for the tick data-join.
Merge remote-tracking branch 'origin/fix-zero-duration-transitions' into 3.3.6
Update dependencies.
Merge branch '3.3.6'
Preserve polygon exterior/interior ring ordering.

According to GeoJSON, the first ring in a polygon should be the
exterior, and subsequent rings should be holes that are inside the
exterior ring.  This fix ensures that the rejoining of clipped segments
preserves these semantics, by generating multiple polygons if necessary
rather than generating all rings within a single polygon as it did
previously.

Fixes #1558.