Writer.getDefaultWriteParam()
only creates an ImageWriteParam
object, it doesn't link it back to anything else.
I don't see any mechanism in your code for your modified param
object to be subsequently used in the ImageWriter
.
I believe that instead of:
writer.write(bi);
you need to use:
writer.write(null, new IIOImage(bi, null, null), param);
与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…