Hi,

I have a small image processing servlet, that does;

m_Format = "png" in this case.

    private void write( BufferedImage image )
        throws ProcessingException, IOException
    {
        ImageTypeSpecifier its = ImageTypeSpecifier.createFromRenderedImage(
image );
        Iterator writers = ImageIO.getImageWriters( its, m_Format );
        ImageWriter writer = null;
        if( writers.hasNext() )
        {
            writer = (ImageWriter) writers.next();
        }
        if( writer == null )
            throw new ProcessingException( "Unable to find a ImageWriter: " +
m_Format );

        /// And so on....
    }
The effectsStack is basically a set of ImageOp's, mostly used is the Scale.

Now, if I take a 32bpp TIFF and feed it to the routine above, Image I/O won't
find a writer for it, but a 24bpp TIFF is no problem.
(I don't think it matters; prior to the write operation, the TIFF has been
rescaled using java.awt.image raster operations, but the ColorModel from the
incoming BufferedImage is used for the new rescaled image.)


Anyone have a clue why this seems to be the case?


Cheers
Niclas
--
   +------//-------------------+
  / http://www.dpml.net       /
 / http://niclas.hedhman.org /
+------//-------------------+

===========================================================================
To unsubscribe, send email to [EMAIL PROTECTED] and include in the body
of the message "signoff JAVA2D-INTEREST".  For general help, send email to
[EMAIL PROTECTED] and include in the body of the message "help".

Reply via email to