From dec10031c9a1902a1ef6d172e6f4a7b901b8efc5 Mon Sep 17 00:00:00 2001 From: malc Date: Sat, 28 Jan 2012 02:54:48 +0400 Subject: [PATCH] Use proper sliceheight value Hmm.. i'm positive that i've commited this before... --- link.c | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/link.c b/link.c index c8d0d90..17d571b 100644 --- a/link.c +++ b/link.c @@ -161,6 +161,7 @@ struct slice { struct tile { int x, y, w, h; int slicecount; + int sliceheight; fz_pixmap *pixmap; struct slice slices[1]; }; @@ -651,6 +652,7 @@ static struct tile *alloctile (int h) h -= sh; } tile->slicecount = slicecount; + tile->sliceheight = state.sliceheight; return tile; } @@ -1611,9 +1613,9 @@ CAMLprim value ml_drawtile (value args_v, value ptr_v) int slicey, firstslice; struct slice *slice; - firstslice = tiley / state.sliceheight; + firstslice = tiley / tile->sliceheight; slice = &tile->slices[firstslice]; - slicey = tiley % state.sliceheight; + slicey = tiley % tile->sliceheight; while (disph > 0) { int dh; -- 2.11.4.GIT