Skip to content

Instantly share code, notes, and snippets.

@webmonch
Last active August 29, 2015 14:06
Show Gist options
  • Save webmonch/568d6f1e57428754f9d3 to your computer and use it in GitHub Desktop.
Save webmonch/568d6f1e57428754f9d3 to your computer and use it in GitHub Desktop.
ImageMagick pdf to images
#include <Magick++.h>
using namespace Magick;
....
vector<Image> imageList;
readImages( &imageList, "FAX.PDF" );
for (int i = 0; i < imageList.size(); i++) {
stringstream fileName;
fileName << "FAX" << i << ".tiff";
imageList[i].write(fileName.str());
}
//http://www.cplusplus.com/forum/general/46259/
//https://code.google.com/p/pdf2image/
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment