Friday, December 5, 2014

Gray-level images



In this series dedicated to digital image, gray level images are the most common images used in ImageJ.


1. Introduction

Gray-level images - unlike the binary [Link] - contain shades of gray from black to white as shown in Fig. 1A,B and must not be mistaken with the binary image of Fig. 1C.

Fig. 1: Examples of images. From Top to Bottom: A,B) Gray-level images. C) This image only contains Black and White colors. It is a binary image.

2. Bits per pixel and Dynamic range

In photography, the dynamic range [Wikipedia] corresponds to the luminance of the scene and is captured/converted by the digital camera. The limits of luminance range - that is the number of shades available in the digital image - is directly related to the number of bits allocated per pixel: 8, 16, and 32 bits.

Just take the example of the 8-bit image where each pixel is defined by one byte ( 8 bits). Thus, the minimum value is ...

00000000 = 0

... and the maximum is ...

11111111 = 1x27+1x26+1x25+1x24+1x23+1x22+1x21+1x20 = 28-1 = 255

In this case, we have a maximum of 256 (from 0 to 255) different shades  in a 8-bit image . For a scientific image, this is rather limited because most of the CCD or CMOS camera work with 12- or 16-bits precision. Thus, in a scientific project, we are working with 16-bits images with 65536 (216 from 0 to 65535) shades of gray.
Note: I have another post describing the 8-bit, 16-bit and 32-bit images [Link]

[TODO: Image with 8-bit, 4-bit, 3-bit, etc...]

3. Other crazybiocomputing posts

Further readings are available in ...
  • Digital Image Series  [Link]
  • Image Processing TOC [Link]


No comments:

Post a Comment