summaryrefslogtreecommitdiff
path: root/source/tools/murun.c
diff options
context:
space:
mode:
authorTor Andersson <tor.andersson@artifex.com>2016-06-23 12:33:30 +0200
committerRobin Watts <robin.watts@artifex.com>2016-06-23 16:10:29 +0100
commitcf7b2cbbfe6192fbf697237735ab45bc951304e4 (patch)
treeeac1231a33e79e7f8afa99d63e203b8fededecc4 /source/tools/murun.c
parent38ffc7fefeadb87929c2006d1e91394a516c3c9d (diff)
downloadmupdf-cf7b2cbbfe6192fbf697237735ab45bc951304e4.tar.xz
Update JNI code. Take explicit alpha argument in toPixmap functions.
Diffstat (limited to 'source/tools/murun.c')
-rw-r--r--source/tools/murun.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/source/tools/murun.c b/source/tools/murun.c
index 5315a4f3..1f2f5e5f 100644
--- a/source/tools/murun.c
+++ b/source/tools/murun.c
@@ -1457,10 +1457,11 @@ static void ffi_Page_toPixmap(js_State *J)
fz_page *page = js_touserdata(J, 0, "fz_page");
fz_matrix ctm = ffi_tomatrix(J, 1);
fz_colorspace *colorspace = js_touserdata(J, 2, "fz_colorspace");
+ int alpha = js_toboolean(J, 3);
fz_pixmap *pixmap;
fz_try(ctx)
- pixmap = fz_new_pixmap_from_page(ctx, page, &ctm, colorspace);
+ pixmap = fz_new_pixmap_from_page(ctx, page, &ctm, colorspace, alpha);
fz_catch(ctx)
rethrow(J);
@@ -3100,7 +3101,7 @@ int murun_main(int argc, char **argv)
{
jsB_propfun(J, "Page.bound", ffi_Page_bound, 0);
jsB_propfun(J, "Page.run", ffi_Page_run, 2);
- jsB_propfun(J, "Page.toPixmap", ffi_Page_toPixmap, 1);
+ jsB_propfun(J, "Page.toPixmap", ffi_Page_toPixmap, 3);
jsB_propfun(J, "Page.toDisplayList", ffi_Page_toDisplayList, 0);
jsB_propfun(J, "Page.search", ffi_Page_search, 0);
}