
###########################
A3DPDFDocumentExportAsImage
###########################

.. c:function:: A3DStatus A3DPDFDocumentExportAsImage(A3DPDFDocument *pDoc, const A3DInt32 iNumPage, const A3DDouble dScale, const A3DPDFEImageFormat eFormatOut, const A3DUTF8Char *pcOutImgFileName, A3DInt32 *piNbPages)

   .. rst-class:: sig-pretty-signature
   
      | :c:enum:`~A3DStatus` A3DPDFDocumentExportAsImage(:c:type:`~A3DPDFDocument`\ \* **pDoc**\ , *const* :c:type:`~A3DInt32` **iNumPage**\ , *const* :c:type:`~A3DDouble` **dScale**\ , *const* :c:enum:`~A3DPDFEImageFormat` **eFormatOut**\ , *const* :c:type:`~A3DUTF8Char`\ \* **pcOutImgFileName**\ , :c:type:`~A3DInt32`\ \* **piNbPages**\ )
   
   Export a PDF document to image, processing only one page or all pages.
   
   This version is in beta mode and only supported on windows platform.
   
   **Parameters**
   
   
      **pDoc**\ : The Document object to work with.
   
      **iNumPage**\ : The index of the page. The first page is 0. A value of -1 is to convert all pages of the document. If ``iNumPage``\ is specified (not -1), then one image file is generated with the exact name provided in ``pcOutImgFileName``\ . If ``iNumPage``\ is -1, then ``iNbPages``\ image files are generated with names "pcOutImgFileName_i.extension", with 'i' = 0 to iNbPages-1 and 'extension' being the trigram corresponding to the image format ('bmp', 'jpg', 'png', ...). Note that some file images could not exist in case of error. Please always check the existence of the file image before processing it.
   
      **dScale**\ : Scale to be applied to the image. The image generated is of the size of the PDF page (for ex. 612\*792 pixels for a 612\*792 points page). the scale here is applied to the size of the image.
   
      **eFormatOut**\ : Format of the output image.
   
      **pcOutImgFileName**\ : The file name where to save the document. The path (absolute or relative) must be provided (use ".\\" or "./" for the current directory).
   
      **piNbPages**\ : The number of pages in the document. It is useful if -1 is provided to ``iNumPage``\ to process all generated pages.
   
   
   **Returns**
   
   
      A3D_SUCCESS in case of success or an error code
   
   




