From 4f7fbefa78f6b08fe340f4acb38c617384d88647 Mon Sep 17 00:00:00 2001 From: Robin Watts Date: Wed, 25 Feb 2015 00:27:20 +0000 Subject: Text device; collect matrix and bbox for images too. We were not filling in the matrix and bbox fields for images collected as part of the text extraction device. Fixed here. --- source/fitz/stext-device.c | 6 ++++++ 1 file changed, 6 insertions(+) (limited to 'source') diff --git a/source/fitz/stext-device.c b/source/fitz/stext-device.c index 3213406e..da8a63f0 100644 --- a/source/fitz/stext-device.c +++ b/source/fitz/stext-device.c @@ -862,6 +862,12 @@ fz_text_fill_image_mask(fz_context *ctx, fz_device *dev, fz_image *img, const fz block->cspace = fz_keep_colorspace(ctx, cspace); if (cspace) memcpy(block->colors, color, sizeof(block->colors[0])*cspace->n); + block->mat = *ctm; + block->bbox.x0 = 0; + block->bbox.y0 = 0; + block->bbox.x1 = 1; + block->bbox.y1 = 1; + fz_transform_rect(&block->bbox, ctm); page->len++; } -- cgit v1.2.3