Quantcast
Channel: Aspose.Pdf Product Family
Viewing all articles
Browse latest Browse all 3131

get Page images

$
0
0
Hello,

I am trying to get the current page images. But it seems that the image list in the resources of the current page holds the images of the whole document and not of the current page.
In the following code, for the attached document, any page will have the same images even one that does not contain any image.
Page page = pdf.getPages().get_Item(pageNb);
                for (int i = 1 ; i <= page.getResources().getImages().size() ; i += 1 ) {
                    FileOutputStream os = new FileOutputStream("/tmp/PDFTests/im" + i + ".jpg");
                    XImage img = page.getResources().getImages().get_Item(i);
                    img.save(os);
                }
thanks,

Camille.

Viewing all articles
Browse latest Browse all 3131

Latest Images

Trending Articles



Latest Images