| From | Sent On | Attachments |
|---|
| Subject: | Re: RE: [JAI-IMAGEIO] Rotating pages in TIFF files | |
|---|---|---|
| From: | jai-...@javadesktop.org (jai-...@javadesktop.org) | |
| Date: | Feb 14, 2008 2:11:36 pm | |
| List: | net.java.dev.jai-imageio.interest | |
Refine Search
| From | Sent On | Attachments |
|---|---|---|
| jai-...@javadesktop.org | Apr 10, 2007 3:03 pm | |
| Brian Burkhalter | Apr 10, 2007 4:50 pm | |
| Nidel, Mike | Feb 14, 2008 1:29 pm | |
| jai-...@javadesktop.org | Feb 14, 2008 1:32 pm | |
| Nidel, Mike | Feb 14, 2008 2:08 pm | |
| jai-...@javadesktop.org | Feb 14, 2008 2:11 pm | |
| jai-...@javadesktop.org | Feb 15, 2008 8:38 am | |
| jai-...@javadesktop.org | Feb 20, 2008 10:38 am |
| Subject: | Re: RE: [JAI-IMAGEIO] Rotating pages in TIFF files | |
|---|---|---|
| From: | jai-...@javadesktop.org (jai-...@javadesktop.org) | |
| Date: | Feb 14, 2008 2:11:36 pm | |
| List: | net.java.dev.jai-imageio.interest | |
So I'll try this tomorow, I don't know if it will work.
PlanarImage pi = null;//JAI.create("fileload", filename); ImageInputStream input = null; try{ File fileInput = new File(filename); input = ImageIO.createImageInputStream(fileInput); pi = JAI.create("stream", input); } catch (Exception e){ e.printStackTrace(); }
and
TIFFEncodeParam param = new TIFFEncodeParam(); param.setCompression(TIFFEncodeParam.COMPRESSION_GROUP4); param.setLittleEndian(false); // Intel
pb.addSource(pi); pb.add(rotOp); pb.add(param);
RenderedImage src0 = JAI.create("transpose", pb);
//L'image est sauvegardé après la rotation try{ param = new TIFFEncodeParam(); param.setCompression(TIFFEncodeParam.COMPRESSION_GROUP4); pb = new ParameterBlock(); pb.addSource(src0); pb.add("r"+filename).add("tiff").add(param); //RenderedOp op = JAI.create("filestore", pb); RenderedOp op = JAI.create("encode", pb); op.dispose(); pi.dispose(); input.close(); } catch (Exception er){ er.printStackTrace(); } [Message sent by forum member 'dnlfrc' (dnlfrc)]

