title: How to convert pdf file in to multipagetiff images using pdfBox?
body: <pre><code>document = PDDocument.load(new File(pdfFilename));
  PDFRenderer pdfRenderer = new PDFRenderer(document);
  int pageCounter = 0;
  
  for (PDPage page : document.getPages()) {
  
      BufferedImage bim = pdfRenderer.renderImageWithDPI(pageCounter, 300, ImageType.RGB);
      ImageIOUtil.writeImage(bim, pdfFilename + "-" + (pageCounter++) + ".tif", 300);
  
  }
  </code></pre>
  
  <p>Instead of creating multiple single image how to create multipage image?</p>