- Loads a PDF document from disk synchronously.
- param Path The path of the PDF document. Must be accessible through the stadard filesystem.
- param Password The optional password of the PDF document.
- return A new Document object.
static UPDFDocument* LoadDocumentSync(const FString& Path, const FString& Password, FString& OutError, int32& OutErrorCode);
static UPDFDocument* LoadDocumentSync(const FString& Path, const FString& Password);
- Loads a PDF document from memory synchronously.
- param Data The data of the document.
- param Password The optional password of the PDF document.
- return A new Document object.
static UPDFDocument* LoadDocumentFromMemorySync(const TArray<uint8>& Data, const FString& Password, FString& OutError, int32& OutErrorCode);
- Loads a PDF document from disk asynchronously.
- param Data The data of the PDF document.
- param Password The optional password of the PDF document.
- param Callback The callback called when the document is loaded.
static void LoadDocumentFromMemory(TArray<uint8> Data, FString Password, FLoadPDFDocumentCallback Callback);
static void LoadDocumentFromMemory(TSharedPtr<TArray<uint8>> Data, FString Password, FLoadPDFDocumentCallback Callback);
- Loads a PDF file as a list of textures representing each page in order synchronously.
- param Path The path of the document.
- param Password The password of the document.
- return A texture for each page inside of the PDF file.
static TArray<UTexture2D*> LoadPagesAsTextureSync(const FString& Path, const FString& Password, const FPDFPageParameters& PageParams, FString& OutError, int32& OutErrorCode);
static TArray<UTexture2D*> LoadPagesAsTextureSync(const FString& Path, const FString& Password, const FPDFPageParameters& PageParams);
- Loads a PDF file as a list of textures representing each page in order synchronously.
- param Path The path of the document.
- param Password The password of the document.
- return A texture for each page inside of the PDF file.
static void LoadPagesAsTexture(FString Path, FString Password, FPDFPageParameters PageParams, FLoadPDFPagesCallback Callback);
- Gets the page at the specified index.
- param Index The index of the page we want.
- return The page at the specified index or nullptr if there are none.
class UPDFPage* GetPage(const int32 Index);
- Gets the number of pages in the document.
- return The number of pages in the document.
int32 GetPageCount() const;
- Loads all images in the document as textures.
- return All the images in the document.
TArray<UTexture2D*> LoadImagesAsTexture();