Chain codes are an efficient encoding of binary objects in an image. Use this tag together with [image-processing].
Chain codes, first proposed by Freeman in the early 1960's, encode a binary image object's contour as a set of steps in one of eight directions. The whole object is thus encoded as a sequence of 3-bit values, one for each of the object's contour pixels.