No description provided.
Bilinear resampling in C
Removed debugging printf
Set bounds correctly, add tests
Thanks for contributing. The build seems to be failing because of long overflows: https://travis-ci.org/wvanbergen/oily_png/builds/4809541
Hmm. Passes on my test machines but they're all 64-bit. I'll check it out.
One tidbit that may have caused this:
ChunkyPNG/OilyPNG use 32bit integers to store pixels. This would normally work fine on 32-bit machines, but a ruby Fixnum uses the first two bits for type information, so in practice a FIxnum only has 30 bits before it overflows to a Bignum.
So when you convert a long back into a Ruby type, it could be both a Fixnum or a Bignum. You may want to play around with ruby.h'sFIX2INT,NUM2INT,FIX2LONG, andNUM2LONG` macros to make it work.
(I didn't actually look at your code to see if this is the problem for you ;)
Store pixels in uint32_t instead of long
Saves space and works on 32-bit systems
Yea, that was it. Thanks for pointing me in the right direction.
Released as version 1.1.0. Thanks for contributing!