@Override
    public void setOutput(Object output) {
      super.setOutput(output);
      if (output != null) {
        if (!(output instanceof ImageOutputStream)) {
          throw new
            IllegalArgumentException("output is not an ImageOutputStream");
        }
        this.stream = (ImageOutputStream)output;
        this.stream.setByteOrder(ByteOrder.LITTLE_ENDIAN);
      }
      else {
        this.stream = null;
      }
    }
@Override
    public void setOutput(Object output)