diff options
author | sakamoto <sakamoto@pkgsrc.org> | 2000-07-08 15:22:31 +0000 |
---|---|---|
committer | sakamoto <sakamoto@pkgsrc.org> | 2000-07-08 15:22:31 +0000 |
commit | e5dc7ec9fd81e30f6320ea6dd820d1597af79f94 (patch) | |
tree | 0f22ddebdfa547acc15937ef9db18311516c5f97 /converters | |
parent | 5182fe9eff20824bd08dd3646b3d4dabb3f48e9a (diff) | |
download | pkgsrc-e5dc7ec9fd81e30f6320ea6dd820d1597af79f94.tar.gz |
patch for new CreateImage API of ImageMagick-5.x.
Diffstat (limited to 'converters')
-rw-r--r-- | converters/psiconv/files/patch-sum | 3 | ||||
-rw-r--r-- | converters/psiconv/patches/patch-ad | 30 |
2 files changed, 32 insertions, 1 deletions
diff --git a/converters/psiconv/files/patch-sum b/converters/psiconv/files/patch-sum index c666901402d..330d0865b40 100644 --- a/converters/psiconv/files/patch-sum +++ b/converters/psiconv/files/patch-sum @@ -1,5 +1,6 @@ -$NetBSD: patch-sum,v 1.1.1.1 1999/12/06 01:58:07 sakamoto Exp $ +$NetBSD: patch-sum,v 1.2 2000/07/08 15:22:31 sakamoto Exp $ MD5 (patch-aa) = 23f3cbab1ce7b131bec872f5ae5240f4 MD5 (patch-ab) = 5372b58da6a1ff32909e989e8f83f19b MD5 (patch-ac) = 33e9d2066f929bde5e18efef161ae40a +MD5 (patch-ad) = bc5ab4cbd3332c332a4bd96100f21d39 diff --git a/converters/psiconv/patches/patch-ad b/converters/psiconv/patches/patch-ad new file mode 100644 index 00000000000..213368f0278 --- /dev/null +++ b/converters/psiconv/patches/patch-ad @@ -0,0 +1,30 @@ +$NetBSD: patch-ad,v 1.1 2000/07/08 15:22:32 sakamoto Exp $ + +--- psiconv/gen_image.c.orig Sat Dec 4 09:46:15 1999 ++++ psiconv/gen_image.c Sat Jul 8 18:49:11 2000 +@@ -33,8 +33,23 @@ + static Image *get_paint_data_section(psiconv_paint_data_section sec) + { + Image *image; +- image = CreateImage(sec->xsize,sec->ysize,sec->red,sec->green, +- sec->blue,NULL); ++ float *pixel, *p, *red, *green, *blue; ++ int x,y; ++ ++ red = sec->red; ++ green = sec->green; ++ blue = sec->blue; ++ p = pixel = malloc(sec->xsize * sec->ysize * 3 * sizeof(float)); ++ for (y = 0; y < sec->ysize; y++) { ++ for (x = 0; x < sec->xsize; x++) { ++ *p++ = *red++; ++ *p++ = *green++; ++ *p++ = *blue++; ++ } ++ } ++ image = CreateImage(sec->xsize,sec->ysize,"RGB",FloatPixel,pixel); ++ free(pixel); ++ + return image; + } + |