简体   繁体   中英

How to convert a PDF to a PNG in IOS programmatically

I am developing an iPhone application to display large image(s) and PDF(s). The PDF and images are available for web downloading or through iTunes importing.

I am using a tiling approach where after the download/import a set of PNG/JPEG tiles are programmatically generated and saved to the iPhone.

Looking previous questions I found a way to do tiling for large images, but it does not work with PDF files?

I wonder if it is possible to convert the PDF file into a PNG/JPEG before running the tiling routine, or if there are better approaches to do this.

您可以创建图像对象,为图像创建图形上下文,在图像的图形上下文中呈现PDF页面,然后保存图像。

The technical post webpages of this site follow the CC BY-SA 4.0 protocol. If you need to reprint, please indicate the site URL or the original address.Any question please contact:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM