Disclosed herein is a method for decompressing compressed data. First,
a table is prepared in which the number of bits, consecutively present to the right
of the certain bit and having the same color as the certain bit, is listed. Then,
a predetermined number of reference data bits is taken from a reference line. Next,
the table is searched with both the reference data bits and a position of an attentional
bit in the data bits, in order to detect the number of bits of the same color as
the attentional bit which are consecutively present to the right of the attentional
bit. Thereafter, a pixel, right away from the attentional bit by a distance equal
to the addition of 1 and the detected number of bits, is found as a color-changed
pixel on the reference line. The compressed data is decoded based on the position
of the found color-changed pixel.