You can create your own PDF viewer using iText, you can get images for a specific page and just display this image as a scroll.
But to use this approach, you will need to implement an effective cache and set a threshold for certain pages that will be executed upon initial launch and gradually.
Here is a link to help you:
public void makeImageFromPDF throws DocumentException, IOException { String INPUTFILE = Environment.getExternalStorageDirectory() .getAbsolutePath()+"/YOUR_DIRECTORY/inputFile.pdf"; String OUTPUTFILE = Environment.getExternalStorageDirectory() .getAbsolutePath()+"/YOUR_DIRECTORY/outputFile.pdf"; Document document = new Document(); PdfWriter writer = PdfWriter.getInstance(document, new FileOutputStream(OUTPUTFILE)); document.open(); PdfReader reader = new PdfReader(INPUTFILE); int n = reader.getNumberOfPages(); PdfImportedPage page;
You can also use this link as a link:
Reading a pdf file using the iText library
Hope this helps.
source share