From 54d9746182fae9493c9fadc1619769c9fe2a6098 Mon Sep 17 00:00:00 2001 From: Jean-Marc Zucconi Date: Sat, 23 Jun 2001 00:03:24 +0000 Subject: [PATCH] FIx a bug with the -tile option. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit PR: ports/28245 Submitted by: RĂ©mi Guyomarch --- x11/xloadimage/Makefile | 1 + x11/xloadimage/files/patch-tile | 31 +++++++++++++++++++++++++++++++ 2 files changed, 32 insertions(+) create mode 100644 x11/xloadimage/files/patch-tile diff --git a/x11/xloadimage/Makefile b/x11/xloadimage/Makefile index 5d472ff8bc2b..6f79966fd043 100644 --- a/x11/xloadimage/Makefile +++ b/x11/xloadimage/Makefile @@ -7,6 +7,7 @@ VERSION= 4.1 REVISION= 6 +PORTREVISION= 1 PORTNAME= xloadimage PORTVERSION= ${VERSION}.${REVISION} diff --git a/x11/xloadimage/files/patch-tile b/x11/xloadimage/files/patch-tile new file mode 100644 index 000000000000..69beacda33d6 --- /dev/null +++ b/x11/xloadimage/files/patch-tile @@ -0,0 +1,31 @@ +--- merge.c~ Thu Oct 21 22:28:39 1993 ++++ merge.c Mon Jun 18 02:23:58 2001 +@@ -244,6 +244,7 @@ + int x, y; + unsigned int width, height, verbose; + { Image *base, *tmp; ++ int nx, ny; + + if (verbose) { + printf(" Tiling..."); +@@ -259,16 +260,14 @@ + else + base = newTrueImage(width, height); + +- while (x < base->width) { +- while(y < base->height) { +- tmp = merge(base, image, x, y, 0); ++ for (nx = x; nx < base->width; nx += image->width) { ++ for(ny = y; ny < base->height; ny += image->height) { ++ tmp = merge(base, image, nx, ny, 0); + if (tmp != base) { + freeImage(base); + base = tmp; + } +- y += image->width; + } +- x += image->width; + } + printf("done.\n"); + return(base); +