R
Roland
Hello,
I am generating JPGs out of a TIFF from a fax server using JAI - the
problem is the strange dimension of the JPGs.
The TIFF contains for example 2 pages with size 1728 x 2382 (image
info from different image viewer).
The generated JPGs has both the size 1728 x 1131 ! The heigth is
wrong (almost half of original size) and the resulting JPG shows the
original page streched.
I am using the following code:
ImageDecoder dec = ImageCodec.createImageDecoder(
"tiff", new FileSeekableStream(new File(fnTiff)), null);
for (int i = 0; i < dec.getNumPages(); i++) {
RenderedOp op =
JAI.create(
"filestore", dec.decodeAsRenderedImage(i), i + ".jpg", "jpeg");
}
Where is the error? Do I have to define something more?
Any hints are welcome
Bye,
Roland.
I am generating JPGs out of a TIFF from a fax server using JAI - the
problem is the strange dimension of the JPGs.
The TIFF contains for example 2 pages with size 1728 x 2382 (image
info from different image viewer).
The generated JPGs has both the size 1728 x 1131 ! The heigth is
wrong (almost half of original size) and the resulting JPG shows the
original page streched.
I am using the following code:
ImageDecoder dec = ImageCodec.createImageDecoder(
"tiff", new FileSeekableStream(new File(fnTiff)), null);
for (int i = 0; i < dec.getNumPages(); i++) {
RenderedOp op =
JAI.create(
"filestore", dec.decodeAsRenderedImage(i), i + ".jpg", "jpeg");
}
Where is the error? Do I have to define something more?
Any hints are welcome
Bye,
Roland.