- edited description
gdimagestringft_bbox test fails on old Enterprise Linux 5 build
Issue #72
new
1/ configure minor issue.
libvpx is not found because old version provides "libvpx" instead of "vpx"
Workaround
export LIBVPX_CFLAGS=$(pkg-config libvpx --cflags)
export LIBVPX_LIBS=$(pkg-config libvpx --libs)
Would be great to have this managed, but not important as a workaround exists.
2/ test results
...
(491, 364) (613, 313) (602, 288) (481, 338) expected, but (491, 364) (613, 314) (602, 288) (480, 339)
FAIL: gdimagestringft/gdimagestringft_bbox
...
============================================================
1 of 91 tests failed
Please report to https://bitbucket.org/libgd/gd-libgd/issues
============================================================
Not a big issue, workaround:
export XFAIL_TESTS=gdimagestringft/gdimagestringft_bbox
Comments (8)
-
reporter -
Account Deleted Could you try the first issue with 5b96783 (and fix if still broken :)).
-
reporter -
Account Deleted And I smell double -> int rounding issue here again.
-
Account Deleted Remi,
could you this patch or try some variants of retyping on different places :) :
diff --git a/src/gdft.c b/src/gdft.c index 30f3440..d694854 100644 --- a/src/gdft.c +++ b/src/gdft.c @@ -1067,7 +1067,7 @@ BGD_DECLARE(char *) gdImageStringFTEx (gdImage * im, int *brect, int fg, char *f if (ch == '\n') { /* 2.0.13: reset penf.x. Christopher J. Grayce */ penf.x = 0; - penf.y += linespace * ptsize * 64 * METRIC_RES / 72; + penf.y += (FT_Pos)(linespace * ptsize * 64 * METRIC_RES / 72); penf.y &= ~63; /* round down to 1/METRIC_RES */ previous = 0; /* clear kerning flag */ next++; @@ -1276,8 +1276,8 @@ BGD_DECLARE(char *) gdImageStringFTEx (gdImage * im, int *brect, int fg, char *f /* position rounded down to nearest pixel at current dpi (the estimate was rounded up to next 1/METRIC_RES, so this should fit) */ gdft_draw_bitmap (tc_cache, im, fg, bm->bitmap, - (int)(x + (penf.x * cos_a + penf.y * sin_a)*hdpi/(METRIC_RES*64) + bm->left), - (int)(y - (penf.x * sin_a - penf.y * cos_a)*vdpi/(METRIC_RES*64) - bm->top)); + (int)(x + (int)((double)penf.x * cos_a + (double)penf.y * sin_a) * hdpi / (METRIC_RES * 64) + bm->left), + (int)(y - (int)((double)penf.x * sin_a - (double)penf.y * cos_a) * vdpi / (METRIC_RES * 64) - bm->top)); FT_Done_Glyph (image); }
-
reporter Same result. But I don't think it worth trying to fix this as the problem could be in the very old freetype version used.
-
- changed title to gdimagestringft_bbox build fails on old Enterprise Linux 5 build
-
- changed title to gdimagestringft_bbox test fails on old Enterprise Linux 5 build
- Log in to comment