ExportDocument - Image options

PDF-XChange Viewer SDK for Developer's
(ActiveX and Simple DLL Versions)

Moderators: PDF-XChange Support, Daniel - PDF-XChange, Chris - PDF-XChange, Sean - PDF-XChange, Vasyl - PDF-XChange, Ivan - Tracker Software, Stefan - PDF-XChange

michael wagmann
User
Posts: 7
Joined: Fri Sep 09, 2011 9:21 am

ExportDocument - Image options

Post by michael wagmann »

Hi,

I want to automate a PDF to image (png) export process. I had a look into the FullDemo example (and the documentation) but couldnt find any properties to set options for specific image formats. I am able to set the dpi and file format but I also need to set the color bit depth, i.e. Indexed 8bpp.
Is there any possibility to specify PNG-Options that are available in the ExportDocument dialog when calling the ExportDocument function without GUI?

Regards,
Simon
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19913
Joined: Mon Jan 12, 2009 8:07 am

Re: ExportDocument - Image options

Post by Stefan - PDF-XChange »

Hello Simon,

Have you checked the Simple Viewer DLL SDK as well?
It allows you to render the pages to e.g. a DeviceContext, and then use that raster image data to generate the needed image file format yourself?

I do not think there's a way to control e.g. the bpp values for the Viewer AX export to images methods.

Regards,
Stefan
User avatar
Vasyl - PDF-XChange
Site Admin
Posts: 2448
Joined: Thu Jun 30, 2005 4:11 pm

Re: ExportDocument - Image options

Post by Vasyl - PDF-XChange »

Hi Simon.
Is there any possibility to specify PNG-Options that are available in the ExportDocument dialog when calling the ExportDocument function without GUI?
Only one way exists. You may, like end-user, launch our EU-Viewer, open any pdf, show export-dialog and setup export-to-png options and press OK to remember your new options. Then you may export all viewer's settings to a file. Then you will be able to use this file to load customized settings each time when your program starts(by pdfControl.LoadSettings("...\MyPDFVSettings.dat"), see also pdfControl.SaveSetting(..))).
Sure, end-user will be able to change your custom png-options in UI mode, but no way to prevent it only in Export2Image dialog - you must prevent showing this dialog (by disabling the corresponding UI-command in menu/toolbar).

HTH.
PDF-XChange Co. LTD (Project Developer)

Please archive any files posted to a ZIP, 7z or RAR file or they will be removed and not posted.
michael wagmann
User
Posts: 7
Joined: Fri Sep 09, 2011 9:21 am

Re: ExportDocument - Image options

Post by michael wagmann »

Thanks, that works for me!
User avatar
Stefan - PDF-XChange
Site Admin
Posts: 19913
Joined: Mon Jan 12, 2009 8:07 am

Re: ExportDocument - Image options

Post by Stefan - PDF-XChange »

:)