Merged libgd/gd-libgd into master
Fixed memory overrun bug in gdImageScaleTwoPass

_gdContributionsCalc would compute a window size and then adjust
the left and right positions of the window to make a window within
that size.  However, it was storing the values in the struct *before*
it made the adjustment.  This change fixes that.
Merged in suetanvil/gd-libgd/suetanvil (pull request #12)

Fixed memory overrun bug in gdImageScaleTwoPass
Merged libgd/gd-libgd into master
Removed some dead code.

Removed an unused enum type from gd_interpolation.c. This was the
original version of gdInterpolationMethod in gd.h.
More dead code removal.

Missed the typedef.  This patch gets it.
Cleaned up floating-point rescaling code.

These changes improve readability without negatively affecting
correctness or performance.

1) The code to do horizontal and vertical scaling were mostly
identical.  This change merges them.

2) The case where the original and result sizes were identical were
handled inefficiently (and probably incorrectly) by copying the source
to the destination with memcpy.  This change makes a simple copy if
both dimensions are the same (i.e. no resizing is requested) and skips
resizing in the unchanged dimension if only one dimension is
different.

3) Other cleanups: removed dead code, improved variable names, added
assertions to document expections, etc.
Improved testing code

Assertions in gdtest.c do nothing on failure except print a message.
This change also makes them keep a count of failures which can be
retrieved with the function 'gdNumFailures()', making it easy to
return an error status if an assertion condition fails.

Also added gdMaxPixelDiff(), a function to return the largest
difference between two corresponding pixels.  Used to detect pixels
that are similar except for a little color change.
Added a test case for gdImageScaleTwoPass().

This testcase does some basic resizing using bicubic
interpolation and ensures the result is sane.  It does
not verify image quality, just that the functions return
acceptible values.
Bug fix: #92: Bicubic scaling leaves the rightmost and bottom rows black

This turns out to be a simple off-by-one error.

Issue URL: https://bitbucket.org/libgd/gd-libgd/issue/92/bicubic-scaling-leaves-the-rightmost-and
Merged in suetanvil/gd-libgd/suetanvil-dead-code-removal (pull request #13)

Removed some dead code
Merged in suetanvil/gd-libgd/suetanvil-scale-code-cleanup (pull request #14)

Major cleanup of FP scaling code