fix miniz encoder - closes #1560
improve png comparison tests