swift-text-emboss-cli icon indicating copy to clipboard operation
swift-text-emboss-cli copied to clipboard

Support multipage PDFs

Open samhenrigold opened this issue 2 years ago • 1 comments

Multipage PDF support would be a game changer for me. In a Node script I'm writing, I have to split PDFs into individual images and run the OCR utility over each page. This introduces a fair amount of hanging while my computer has to render each page in the background before passing it to text-cli.

samhenrigold avatar Apr 29 '22 22:04 samhenrigold

That's an interesting idea. Adding links / notes-to-self in advance of figuring out how much work this would be:

  • https://developer.apple.com/documentation/pdfkit
  • https://developer.apple.com/documentation/pdfkit/pdfpage
  • https://www.hackingwithswift.com/example-code/libraries/how-to-extract-text-from-a-pdf-using-pdfkit
  • https://www.hackingwithswift.com/example-code/core-graphics/how-to-render-a-pdf-to-an-image

thisisaaronland avatar Apr 29 '22 22:04 thisisaaronland