From 209f30bee3121bbae32799b0bbb10f5e6db4158c Mon Sep 17 00:00:00 2001 From: Tor Andersson Date: Wed, 11 Jan 2012 23:26:49 +0100 Subject: Hide glyph cache in context. --- ios/main.m | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'ios') diff --git a/ios/main.m b/ios/main.m index 612ca6b2..582d4e88 100644 --- a/ios/main.m +++ b/ios/main.m @@ -16,7 +16,6 @@ #define SEARCH_W (width - GAP - 170) static dispatch_queue_t queue; -static fz_glyph_cache *glyphcache = NULL; static float screenScale = 1; static fz_context *ctx = NULL; @@ -219,7 +218,7 @@ static UIImage *renderPage(struct document *doc, int number, CGSize screenSize) pix = fz_new_pixmap_with_rect(ctx, fz_device_rgb, bbox); fz_clear_pixmap_with_color(pix, 255); - dev = fz_new_draw_device(ctx, glyphcache, pix); + dev = fz_new_draw_device(ctx, pix); draw_page(doc, number, dev, ctm, NULL); fz_free_device(dev); @@ -256,7 +255,7 @@ static UIImage *renderTile(struct document *doc, int number, CGSize screenSize, pix = fz_new_pixmap_with_rect(ctx, fz_device_rgb, bbox); fz_clear_pixmap_with_color(pix, 255); - dev = fz_new_draw_device(ctx, glyphcache, pix); + dev = fz_new_draw_device(ctx, pix); draw_page(doc, number, dev, ctm, NULL); fz_free_device(dev); @@ -1388,8 +1387,6 @@ static UIImage *renderTile(struct document *doc, int number, CGSize screenSize, // use at most 128M for resource cache ctx = fz_new_context(NULL, 128<<20); - glyphcache = fz_new_glyph_cache(ctx); - screenScale = [[UIScreen mainScreen] scale]; library = [[MuLibraryController alloc] initWithStyle: UITableViewStylePlain]; -- cgit v1.2.3