1. An image processing apparatus comprising: a reader configured for reading data of each pixel of a binarized image; a plurality of matrix modules configured for performing filtering operations comprising swelling operation and shrinking operation to the data based on a control signal, the plurality of matrix modules serially connected, and a first one of the series being connected to the reader; a selector configured for selecting one of the plurality of matrix modules based on the control signal and outputting filtered results from the selected one of the plurality of matrix modules; and a controller configured for generating the control signal, the control signal comprising at least one upper bit for controlling the selector to select one of the plurality of matrix modules and at lest one lower bit for controlling the corresponding matrix module to perform swelling operation or shrinking operation correspondingly; wherein the at least one upper bit compose a binary-coded decimal code for identifying each matrix module, and each bit of the at least one lower bits is used to control a corresponding matrix module to perform the swelling operation or shrinking operation correspondingly; the number of the plurality of matrix modules is 8, and the control signal has eleven bits in a SSS,XXXX,XXXX format, and the SSS is read by the selector to select one of the plurality of matrix modules, and each X is used to control a corresponding one of the plurality of matrix modules to perform the filtering operation.