diff options
author | Tor Andersson <tor.andersson@artifex.com> | 2018-07-05 14:44:48 +0200 |
---|---|---|
committer | Tor Andersson <tor.andersson@artifex.com> | 2018-07-06 13:54:49 +0200 |
commit | 7cb9579804102ea39ef76d237144b57331766df1 (patch) | |
tree | bc485caac64ce1b4e36018075ea51064c3a0dd81 /source/pdf/pdf-shade.c | |
parent | cd2ae94337aa32e54f6a89945c2069024aad6d12 (diff) | |
download | mupdf-7cb9579804102ea39ef76d237144b57331766df1.tar.xz |
Add pdf_dict_get_rect and pdf_dict_get_matrix helpers.
Diffstat (limited to 'source/pdf/pdf-shade.c')
-rw-r--r-- | source/pdf/pdf-shade.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/source/pdf/pdf-shade.c b/source/pdf/pdf-shade.c index 13c1ebc8..970a2ed1 100644 --- a/source/pdf/pdf-shade.c +++ b/source/pdf/pdf-shade.c @@ -69,7 +69,7 @@ pdf_load_function_based_shading(fz_context *ctx, pdf_document *doc, fz_shade *sh y1 = pdf_array_get_real(ctx, obj, 3); } - shade->u.f.matrix = pdf_to_matrix(ctx, pdf_dict_get(ctx, dict, PDF_NAME(Matrix))); + shade->u.f.matrix = pdf_dict_get_matrix(ctx, dict, PDF_NAME(Matrix)); shade->u.f.xdivs = FUNSEGS; shade->u.f.ydivs = FUNSEGS; shade->u.f.fn_vals = fz_malloc(ctx, (FUNSEGS+1)*(FUNSEGS+1)*n*sizeof(float)); @@ -442,8 +442,7 @@ pdf_load_shading(fz_context *ctx, pdf_document *doc, pdf_obj *dict) /* Type 2 pattern dictionary */ if (pdf_dict_get(ctx, dict, PDF_NAME(PatternType))) { - obj = pdf_dict_get(ctx, dict, PDF_NAME(Matrix)); - mat = pdf_to_matrix(ctx, obj); + mat = pdf_dict_get_matrix(ctx, dict, PDF_NAME(Matrix)); obj = pdf_dict_get(ctx, dict, PDF_NAME(ExtGState)); if (obj) |