public void setOutput8BitGray(boolean output8BitGray) {
        this.output8BitGray = output8BitGray;
    }
If set, grayscale images with a bit depth less than 8
(1, 2, or 4) will be output in 8 bit form.  The output values
will occupy the full 8-bit range.  For example, gray values
0, 1, 2, and 3 of a 2-bit image will be output as
0, 85, 170, and 255.

<p> The decoding of non-grayscale images and grayscale images
with a bit depth of 8 or 16 are unaffected by this setting.

<p> The default is not to perform expansion.  Grayscale images
with a depth of 1, 2, or 4 bits will be represented using
a <code>MultiPixelPackedSampleModel</code> and an
<code>IndexColorModel</code>.
plugins/svg-plugin/batik-codec-fix/src/main/java/org/apache/batik/ext/awt/image/codec/png/PNGDecodeParam.java