 2-dimensional array, i.e. a grayscale image or only one color of a RGB image. All the operations are done on the whole image matrix at once. This is the advantage the PDL module gives to us.</p>

<p>It returns an array of 8 images, for each bit plane one separate image.</p>

<p>Let me give an example: A grayscale pixel has a decimal value of 255. The binary value is <code>0b11111111</code>.</p>

<p>Each bit is masked in the <code>for</code> loop:</p>

<pre><code> Pixel      &amp; Mask       = Bit Plane (ra