1. Technical Field
The present invention relates to a skew correction apparatus and method and, more particularly, to a skew correction apparatus and method which enhances transmission efficiency or recognition efficiency in facsimile transmissions or optical character recognition processes by correcting the format of the copy which is input and read in a skewed condition.
2. Related Art
Today, various types of image processors conduct data processing on specific data using image data read from a copy. As image processors, facsimiles transmit read image data to a remote user through a network, scanners read and store image data, and optical character readers (OCRs) read data and recognize characters in the data. In using such image processors, a copy which is read in skewed condition may cause many problems. This will be discussed hereinafter in the context of using facsimiles.
The transmission procedures of a common facsimile can be explained briefly, as follows. The scanner of the facsimile reads the paper inserted by user(s), converts any image data obtained from that reading to binary image data, and provides the resulting image data to a central processing unit of the facsimile. The central processing unit then temporarily stores the binary image data in memory. Then, the central processing unit performs coding and compression on the binary image data according to a coding method (for example, MH, MR, or MMR) which follows International Telegraph and Telephone Consultative Committee (CCITT) Groups 1-4. The compressed binary image data is known as a facsimile message. The central processing unit then transmits the facsimile message to the corresponding facsimile through a telephone line according to key inputs of the user(s).
In a conventional method for correcting the skewed copy, procedures for calculating a skew angle are complicated and take a considerable amount of time. In addition, additional memory and a high performance central processing unit are required to rotate the image of the copy based on the calculated angle, which increases the cost of adapting to a common facsimile device.
Accordingly, it is an object of the present invention to reduce cost by performing corrections of a skew angle using a low cost processor through a simplified skew correction procedure without complicated operation, that is, by calculating a skew angle or rotating an image on a copy in accordance with the calculated skew angle.
According to an aspect of the present invention, there is provided a skew correction apparatus in an image processor for reading data on a one-page copy and for performing image processing. The skew correction apparatus includes: a read data storing unit for storing data read from the one-page copy; a counter for counting the number of pixels in a main-scanning direction until copy discriminating data are met, starting from two spots of the data stored in the read data storing unit in a sub-scanning direction; a lookup table data storing unit for storing skew correction data corresponding to a difference between the number of pixels of the two spots in the main-scanning direction; and a processing unit for correcting skew by sensing a skew direction of the copy according to a selected rule using the difference between the number of pixels, and reading by line units the changed coordinates from the read data storing unit according to the skew correction data stored in the lookup table data storing unit.
Preferably, the lookup table data includes: a difference between the number of pixels of the two spots in the main-scanning direction; a pixel interval for determining the number of pixels to be read in the main-scanning direction from the data stored in the read data storing unit according to the difference between the number of pixels; a number of repetition times for determining the number of times of reading, in the main-scanning direction at the pixel intervals, the data stored in the read data storing unit corresponding to the coordinates changed one sub-scanning line before or after.
According to another aspect of the present invention, there is provided a skew correction method for correcting a one-page copy read and stored in skewed condition. The method includes the steps of: counting the number of pixels in a main-scanning direction until copy discriminating data are met, starting from two spots of the read data in a sub-scanning direction; sensing a skew direction of the copy using the counted number of pixels; reading skew correction data corresponding to the difference between the number of pixels of the two spots in the main-scanning direction; and correcting the skew by reading, in the main-scanning direction, the changed coordinates by line units with respect to all lines in the sub-scanning direction of the copy according to the skew correction data and skew direction.
Preferably, the step of sensing a skew direction senses the skew direction as xe2x80x9crightxe2x80x9d when the value obtained by subtracting the number of pixels at a second spot in the sub-scanning direction from those at a first spot in the sub-scanning direction is larger than xe2x80x9c0xe2x80x9d. The step of sensing a skew direction senses the skew direction as xe2x80x9cleftxe2x80x9d when the value obtained by subtracting the number of pixels at the second spot in the sub-scanning direction from those at the first spot in the sub-scanning direction is smaller than xe2x80x9c0xe2x80x9d.
Preferably, the skew correction data include: a pixel interval for determining the number of pixels to be read in the main-scanning direction from the data stored in the read data storing unit according to the difference between the number of pixels of the two spots in the main-scanning direction; the number of repetition times for determining the number of repeated readings, in the main-scanning direction at pixel intervals of the data stored in the read data storing unit corresponding to the coordinates changed one sub-scanning line before or after.
Preferably, the step of correcting the skew corrects the skew by reading a pixel corresponding to the coordinates where the number of pixels in the main-scanning direction moved one sub-scanning line along the skew direction during repetition of said pixel interval if the number of times of repeat is xe2x80x9c0xe2x80x9d, and by repeatedly reading said pixel interval according to the number of times of reading and reading the pixel corresponding to the coordinates where the number of pixels in main-scanning direction moved one sub-scanning line along the skew direction if the number of times of repeat is other than xe2x80x9c0xe2x80x9d, and the number of times of repetition+1 reads the pixel corresponding to the coordinates where the number of pixels moved one sub-scanning line along the skew direction during running of the pixel interval+1.
Preferably, the coordinates are those of the position where lines in the sub-scanning direction are decreased by one if the skew direction is left, and are those of the position where lines in the sub-scanning direction are increased by one if the skew direction is right.
USPTO Backgrounds
USPTO Backgrounds