Merge pull request #161 from nwin/master

Some fixes
Merge pull request #162 from nwin/master

Be a bit more thrifty with unsafe {}
Remove unwraps in non-testing code
Initial support for interlaced images (still fails on some reference images)
Merge commit '71d3b0d29f8b14bfc885c861902a55a5f376f996'