title: How to split single pdf page in half vertically using ghostscript
body: <p>I have a pdf in landscape orientation and is a "Page Spread". </p>
  
  <ol>
  <li><p>I need to split the page in half vertically in the middle. </p>
  
  <p>I used this setting to cut the pdf in half: <em>this one gets the left part of the page</em></p>
  
  <pre><code>"C:\Program Files (x86)\gs\gs9.10\bin\gswin32c.exe" -o output.pdf 
  -sDEVICE=pdfwrite -dNOPAUSE -dBATCH -dSAFER -dSubsetFonts=true -dEmbedAllFonts=true -g 750x1085 -c  
  "&lt;&lt;/BeginPage{0.95 0.96 scale 20 22 translate}&gt;&gt; setpagedevice" "&lt;&lt;/PageOffset [0 0]&gt;&gt; setpagedevice"  -f input.pdf
  </code></pre></li>
  <li><p>The above command works fine. My problem now is I need to set the Mediabox, Cropbox, Bleedbox, Trimbox, and artbox similar to the size of the splitted page. In the instance above; it should be 750x1085.</p>
  
  <p>What should be the correct command/settings to run on GS so that the Mediabox, Cropbox, Bleedbox, Trimbox and artbox has the same sizes?</p></li>
  </ol>
  
  <p><strong>UPDATE</strong><br>
  This is a sample of the PDF file I'm trying to cut in half:
  <a href="https://drive.google.com/file/d/0B0yFP7C9-dxJMXd2dy1fdFp4QVU/edit?usp=sharing" rel="nofollow">PDF FILE TO SPLIT</a>  </p>
  
  <p>I am now using /PAGE pdfmark and this is the command I'm trying to use:  </p>
  
  <pre><code>     "C:\Program Files (x86)\gs\gs9.10\bin\gswin32c.exe" -o output.pdf -sDEVICE=pdfwrite -dNOPAUSE -dBATCH 
      -dSAFER -dUseCropbox -dSubsetFonts=true -dEmbedAllFonts=true -g7500x10850 
      -c "[/CropBox [0 0 750 1085] /PAGES pdfmark" 
      "[/MediaBox [0 0 750 1085] /PAGES pdfmark" 
      "[/TrimBox [0 0 750 1085] /PAGES pdfmark" 
      "[/BleedBox [0 0 750 1085] /PAGES pdfmark"
      "[/ArtBox [0 0 750 1085] /PAGES pdfmark" 
      "&lt;&lt;/BeginPage{0.95 0.96 scale 20 22 translate}&gt;&gt; setpagedevice" 
      "&lt;&lt;/PageOffset [0 0]&gt;&gt; setpagedevice" 
      -f input.pdf
  </code></pre>
  
  <p>I still can't achieve setting the Cropbox, MediaBox, TrimBox, BleedBox, ArtBox with the same size.</p>
  
  <p>What should be the correct settings for the command?</p>