This commit is contained in:
John Whitington 2024-09-30 18:26:39 +01:00
parent 4f0346c615
commit 74ce3f9964
3 changed files with 3 additions and 3 deletions

View File

@ -1025,7 +1025,7 @@ let fixdashes s =
let set_input_image f s =
try
let fh = open_in_bin s in
let pdf = Cpdfimage.image_of_input ?subformat:args.subformat ?title:args.title f (Pdfio.input_of_channel fh) in
let pdf = Cpdfimage.image_of_input ?subformat:args.subformat ?title:args.title ~process_struct_tree:args.process_struct_trees f (Pdfio.input_of_channel fh) in
begin try close_in fh with _ -> () end;
args.original_filename <- s;
args.create_objstm <- true;

View File

@ -493,7 +493,7 @@ let obj_of_jbig2_data ?global data =
in
Pdf.Stream {contents = (Pdf.Dictionary d, Pdf.Got data)}, extra
let image_of_input ?subformat ?title fobj i =
let image_of_input ?subformat ?title ~process_struct_tree fobj i =
let pdf, title =
match subformat with
| None -> Pdf.empty (), begin match title with Some x -> x | None -> "" end

View File

@ -25,7 +25,7 @@ val process :
path_to_jbig2enc:string -> path_to_convert:string -> int list -> Pdf.t -> unit
(**/**)
val image_of_input : ?subformat:Cpdfua.subformat -> ?title:string -> (unit -> Pdfio.bytes -> Pdf.pdfobject * (int * Pdf.pdfobject) list) -> Pdfio.input -> Pdf.t
val image_of_input : ?subformat:Cpdfua.subformat -> ?title:string -> process_struct_tree:bool -> (unit -> Pdfio.bytes -> Pdf.pdfobject * (int * Pdf.pdfobject) list) -> Pdfio.input -> Pdf.t
val obj_of_jpeg_data : Pdfio.bytes -> Pdf.pdfobject * (int * Pdf.pdfobject) list
val obj_of_png_data : Pdfio.bytes -> Pdf.pdfobject * (int * Pdf.pdfobject) list
val obj_of_jbig2_data : ?global:Pdfio.bytes -> Pdfio.bytes -> Pdf.pdfobject * (int * Pdf.pdfobject) list