A method of compressing a document includes: acquiring an image of the
document, the image represented by pixels; segmenting the image into
Mixed Raster Content (MRC) planes including a foreground plane (12) that
receives a first portion of the pixels, a background plane (14) that
receives a second portion of the pixels, and a selector plane (16) that
identifies which of the foreground and background planes the pixels
belong to; identifying a geometric shape in at least one of the MRC
planes; determining if the identified geometric shape has a substantially
uniform color; and, replacing the identified shape when it is determined
to have a substantially uniform color with a vector graphic
representation of the geometric shape.