pelornero wrote:1. Can I create a PDF file from the all pages I've just created in the code above using magick image code?
If they all fit into memory at the same time:
pelornero wrote:2. Can I apply this type of code (the code from the 1st post) to a multiple page PDF file? I'm sick of spliting the PDF in multiple JPEG, run the code, combine them back in PDF>
IM is a raster processor. When it reads a PDF, it rasterizes each page to a raster (pixel) image. When it writes a PDF, every page will be a single raster image. So what you want is probably a bad idea. But IM can do it
Any command with "+clone" almost certainly assumes it is working on a single image, not multiple images. You can re-write the command to work on multiple images but PDF pages tend to be large, too large to fit an entire rasterized document in memory. So it is usually better to split the PDF into pages, process each page, then combine them.