Could you elaborate on that? I don't recall ever having to deal with those
things when I worked on images. I just used the add function on the document
object and it worked fine. Then again, I was only adding them to new
documents, and not replacing an existing image.
-R
On Wed, Nov 26, 2008 at
you also need to rewrite the entire Image dictionary as well with new
values for colorspace, etc.
Leonard
On Nov 25, 2008, at 7:02 PM, Rick Carback wrote:
Klas,
You should be able to read the bytes and convert them.
Something like this should work (written on the fly, there might be
mist
oops, forgot k++; in that for loop.
-R
On Tue, Nov 25, 2008 at 1:02 PM, Rick Carback <[EMAIL PROTECTED]> wrote:
> Klas,
>
> You should be able to read the bytes and convert them.
>
> Something like this should work (written on the fly, there might be
> mistakes):
>
> Image i = ...
> byte[] b = i
Klas,
You should be able to read the bytes and convert them.
Something like this should work (written on the fly, there might be
mistakes):
Image i = ...
byte[] b = i.getRawData();
byte[] grayscale = new byte[b.length%3];
int k = 0;
for (int j = 0; j < b.length; j+=3) {
//Y = 0.3*R + 0.59*G +
There has been no reply to my question 5 days ago on converting a PDF
containing an image with RGB color
to grayscale. Am I correct to assume that there is no easy way to do
this using iText?
Cheers,
Klas
-
This SF.Net ema
I have a pdf template containing a grayscale image. The pdf is supplied
from an external source and is typically created
by exporting as PDF from Adobe Illustrator, inDesign or similar tool.
I use iText to import the image and then add text to create a PDF which
is later sent to a printing press