Issues

Issue #49 resolved

bmp_im2im failed test

Remi Collet
created an issue

./bmp/bmp_im2im pixels changed: 9766

From code.background should be red. bmp_im2im_src.bmp background color Red bmp_im2im_dstc.bmp background color Blue

Everywhere, color order is Blue, Green, Red, except in load_palette.

Proposal

--- src/gd_bmp.c    2013-04-21 19:12:29.361789089 +0200
+++ /dev/shm/BUILD/gd-2.1.0/src/gd_bmp.c    2013-04-22 13:59:01.008208467 +0200
@@ -749,9 +749,9 @@ static int bmp_read_palette(gdImagePtr i

    for (i = 0; i < count; i++) {
        if (
-           !gdGetByte(&r, infile) ||
-           !gdGetByte(&g, infile) ||
            !gdGetByte(&b, infile) ||
+           !gdGetByte(&g, infile) ||
+           !gdGetByte(&r, infile) ||
            (read_four && !gdGetByte(&z, infile))
        ) {
            return 1;

This make test ok, and ..;dst.bmp background is also Red.

Comments (3)

  1. Log in to comment