Package com.lightcrafts.media.jai.codec

Examples of com.lightcrafts.media.jai.codec.TIFFEncodeParam


    }

    public TIFFImageEncoder(OutputStream output, ImageEncodeParam param) {
  super(output, param);
  if (this.param == null) {
      this.param = new TIFFEncodeParam();
  }
    }
View Full Code Here


     * Encodes a RenderedImage and writes the output to the
     * OutputStream associated with this ImageEncoder.
     */
    public void encode(RenderedImage im) throws IOException {
        // Get the encoding parameters.
        TIFFEncodeParam encodeParam = (TIFFEncodeParam)param;

        // Set the byte order flag before any data are written.
        isLittleEndian = encodeParam.getLittleEndian();

        // Write the file header (8 bytes).
        writeFileHeader();

  Iterator iter = encodeParam.getExtraImages();
  if(iter != null) {
            int ifdOffset = 8;
      RenderedImage nextImage = im;
            TIFFEncodeParam nextParam = encodeParam;
            boolean hasNext;
            do {
                hasNext = iter.hasNext();
                ifdOffset = encode(nextImage, nextParam, ifdOffset, !hasNext);
          if(hasNext) {
View Full Code Here

TOP

Related Classes of com.lightcrafts.media.jai.codec.TIFFEncodeParam

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.