void PDF2PPT::exec() { QString command = "pdftoppm"; QStringList args; args << "-jpeg"; if (getStopPage() > 0) { if (getStartPage() == 0) this->setStartPage("1"); args << "-f" << QString::number(getStartPage()) << "-l" << QString::number(getStopPage()); } args << "-rx" << "600" << "-ry" << "600" << this->getSourcePDF(); setOutputPrefix(getOutputDir().append("page")); args << getOutputPrefix(); setOutputExtension("jpg"); execInternal(command, args); }
void GhostScr::exec() { QString command = "gs"; QStringList args; args << "-SDEVICE=jpeg" << "-r1200x1200" << "-sPAPERSIZE=letter" << "-dNOPAUSE" << "-dBATCH"; if ((!getStopPage().isEmpty()) || (getStopPage().toInt() > 0)) { if (getStartPage().toInt() == 0) this->setStartPage("1"); args << QString("-dFirstPage=").append(getStartPage()) << QString("-dLastPage=").append(getStopPage()); } if (!getOutputDir().endsWith("/")) setOutputDir(getOutputDir().append('/')); setOutputPrefix(getOutputDir().append("page")); args << QString("-sOutputFile=").append(getOutputPrefix()).append("_%04d.jpg"); args << "--" << this->getSourcePDF(); setOutputExtension("jpg"); execInternal(command, args); }
virtual void initialise(size_t id) { ID = id; setOutputPrefix(std::string("Interaction[")+intName+std::string("]")); }