diff options
-rw-r--r-- | include/mupdf/fitz/compressed-buffer.h | 33 | ||||
-rw-r--r-- | source/pdf/pdf-image.c | 4 | ||||
-rw-r--r-- | source/pdf/pdf-stream.c | 1 |
3 files changed, 19 insertions, 19 deletions
diff --git a/include/mupdf/fitz/compressed-buffer.h b/include/mupdf/fitz/compressed-buffer.h index fce3be29..a3269d1b 100644 --- a/include/mupdf/fitz/compressed-buffer.h +++ b/include/mupdf/fitz/compressed-buffer.h @@ -18,20 +18,25 @@ fz_stream *fz_open_image_decomp_stream(fz_context *ctx, fz_stream *, fz_compress enum { FZ_IMAGE_UNKNOWN = 0, - FZ_IMAGE_JPEG = 1, - FZ_IMAGE_JPX = 2, - FZ_IMAGE_FAX = 3, - FZ_IMAGE_JBIG2 = 4, - FZ_IMAGE_RAW = 5, - FZ_IMAGE_RLD = 6, - FZ_IMAGE_FLATE = 7, - FZ_IMAGE_LZW = 8, - FZ_IMAGE_PNG = 9, - FZ_IMAGE_TIFF = 10, - FZ_IMAGE_JXR = 11, - FZ_IMAGE_GIF = 12, - FZ_IMAGE_BMP = 13, - FZ_IMAGE_PNM = 14, + + /* Uncompressed samples */ + FZ_IMAGE_RAW, + + /* Compressed samples */ + FZ_IMAGE_FAX, + FZ_IMAGE_FLATE, + FZ_IMAGE_LZW, + FZ_IMAGE_RLD, + + /* Full image formats */ + FZ_IMAGE_BMP, + FZ_IMAGE_GIF, + FZ_IMAGE_JPEG, + FZ_IMAGE_JPX, + FZ_IMAGE_JXR, + FZ_IMAGE_PNG, + FZ_IMAGE_PNM, + FZ_IMAGE_TIFF, }; struct fz_compression_params_s diff --git a/source/pdf/pdf-image.c b/source/pdf/pdf-image.c index 48aba958..7c8f2925 100644 --- a/source/pdf/pdf-image.c +++ b/source/pdf/pdf-image.c @@ -417,10 +417,6 @@ pdf_add_image(fz_context *ctx, pdf_document *doc, fz_image *image, int mask) pdf_dict_put_drop(ctx, imobj, PDF_NAME_DamagedRowsBeforeError, pdf_new_int(ctx, doc, cp->u.fax.damaged_rows_before_error)); pdf_dict_put_drop(ctx, imobj, PDF_NAME_Filter, PDF_NAME_CCITTFaxDecode); break; - case FZ_IMAGE_JBIG2: - /* FIXME - jbig2globals */ - cp->type = FZ_IMAGE_UNKNOWN; - break; case FZ_IMAGE_FLATE: if (cp->u.flate.columns) pdf_dict_put_drop(ctx, imobj, PDF_NAME_Columns, pdf_new_int(ctx, doc, cp->u.flate.columns)); diff --git a/source/pdf/pdf-stream.c b/source/pdf/pdf-stream.c index 39f85b0b..b6645eca 100644 --- a/source/pdf/pdf-stream.c +++ b/source/pdf/pdf-stream.c @@ -534,7 +534,6 @@ can_reuse_buffer(fz_context *ctx, pdf_xref_entry *entry, fz_compression_params * build_compression_params(ctx, f, p, params); return (params->type == FZ_IMAGE_RAW) ? 0 : 1; - } static fz_buffer * |