From 1579fb0241b9b8f45da72f5d1c6ea98c115ae449 Mon Sep 17 00:00:00 2001 From: handa Date: Tue, 17 Jan 2006 07:15:01 +0000 Subject: [PATCH] (main): Use gdImageCreateTrueColor and gdImageAlphaBlending only if HAVE_GD is 2 or the greater. --- example/mdump.c | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/example/mdump.c b/example/mdump.c index f64d249..97ee4d4 100644 --- a/example/mdump.c +++ b/example/mdump.c @@ -720,7 +720,11 @@ main (int argc, char **argv) } } +#if HAVE_GD > 1 image = gdImageCreateTrueColor (paper_width, paper_height); +#else + image = gdImageCreate (paper_width, paper_height); +#endif from = 0; page_index = 1; @@ -737,7 +741,9 @@ main (int argc, char **argv) else bg_rgb = gdImageColorAllocate (image, 255, 255, 255); gdImageColorTransparent (image, bg_rgb); +#if HAVE_GD > 1 gdImageAlphaBlending (image, 0); +#endif } else { -- 1.7.10.4