Alright, I think I understand now.
I had assumed the PdfImportedPage obtained via the line
"tmpWriter.GetImportedPage(new PdfReader("test.pdf"), 1);" would be completely
'self-contained'
Thanks for this explanation. And I will have a look into getting your book.
> Date: Wed, 30 Sep 2009 08:27:20 +0200
> From: [email protected]
> To: [email protected]
> Subject: Re: [iText-questions] Importing a PDF as an Image object
>
> Y Fang wrote:
> > In other words, it is rather unclear (and still is) why the Image
> > produced by the following method:
> [1]
> > PdfImportedPage page = tmpWriter.GetImportedPage(new
> > PdfReader("test.pdf"), 1);
> > Image image = Image.GetInstance(page);
>
> > is somehow different to the Image produced by this method.
> [2]
> > Image image = Image.GetInstance("image.jpg");
>
> [2] is a raster image: bits and bytes that are self contained.
> In PDF lingo: an image XObject
> [1] is a stream of PDF syntax + resources such as fonts, images,...
> In PDF lingo: it's a form XObject
>
> With [2], you have all the necessary data in the Image object.
> With [1] all resources that are referred to from the content stream
> are copied to the Writer (tmpWriter) when you do getImportedPage().
> The Image obtained with Image.getInstance(page) isn't self contained.
> It needs the resources that are already copied to tmpWriter when
> invoking getImportedPage().
>
> The difference between an image XObject and a form XObject is
> explained in the book: chapter 10. That's a chapter that isn't
> available for free, so you might want to buy the book anyway.
> --
> This answer is provided by 1T3XT BVBA
> http://www.1t3xt.com/ - http://www.1t3xt.info
>
> ------------------------------------------------------------------------------
> Come build with us! The BlackBerry® Developer Conference in SF, CA
> is the only developer event you need to attend this year. Jumpstart your
> developing skills, take BlackBerry mobile applications to market and stay
> ahead of the curve. Join us from November 9-12, 2009. Register now!
> http://p.sf.net/sfu/devconf
> _______________________________________________
> iText-questions mailing list
> [email protected]
> https://lists.sourceforge.net/lists/listinfo/itext-questions
>
> Buy the iText book: http://www.1t3xt.com/docs/book.php
> Check the site with examples before you ask questions:
> http://www.1t3xt.info/examples/
> You can also search the keywords list: http://1t3xt.info/tutorials/keywords/
_________________________________________________________________
POP access for Hotmail is here! Click here to find out more
http://windowslive.ninemsn.com.au/article.aspx?id=802246------------------------------------------------------------------------------
Come build with us! The BlackBerry® Developer Conference in SF, CA
is the only developer event you need to attend this year. Jumpstart your
developing skills, take BlackBerry mobile applications to market and stay
ahead of the curve. Join us from November 9-12, 2009. Register now!
http://p.sf.net/sfu/devconf
_______________________________________________
iText-questions mailing list
[email protected]
https://lists.sourceforge.net/lists/listinfo/itext-questions
Buy the iText book: http://www.1t3xt.com/docs/book.php
Check the site with examples before you ask questions:
http://www.1t3xt.info/examples/
You can also search the keywords list: http://1t3xt.info/tutorials/keywords/