ImageEn, unit imageenio




function TImageEnIO.LoadFromStreamPDF(Stream: TStream; Width: Integer = -1; Height: Integer = -1; Password: string = ''): Boolean;


Loads a PDF from a stream into the attached TImageEnView or TIEBitmap using either the TIEMiscPluginsImageMagick plug-in or the WPViewPDF commercial plug-in.
The result will be false if an error is encountered, e.g. the file in the stream is not PDF format or a PDF plug-in is not found(Aborting will be true).

If you are using the WPViewPDF commercial plug-in, you can optionally specify a size to load the PDF file and/or a password.

- PDF files are documents without specified pixel dimensions, so the Dpi is used to calculate image dimensions based on the page size of the PDF.
- Use ImageIndex to specify which page of the PDF file to load
- LoadFromStreamPDF does not reset the position of the stream, so you may need to first call Stream.Position := 0;