The object of the present invention is to provide a kind of image automatic frame taking method and device thereof, can in preposition scanning, judge file format automatically, thereby directly frame is got file and carried out the scanning of thin portion, to increase scan efficiency.
Another object of the present invention is to provide a kind of image positioning apparatus, file is smooth and convenient to sort to keep, and can scan many parts of files simultaneously.
Another purpose of the present invention is to provide a kind of image automatic frame taking method, utilizes the light signal at image positioning apparatus edge, judges the form of file automatically.
A further object of the present invention is to provide a kind of image automatic frame taking method and device thereof, with the scanning reflection original text and penetrate original text, and can scan many parts of files simultaneously.
The object of the present invention is achieved like this, and a kind of image automatic frame taking method promptly is provided, and it comprises the following steps: that the information and the corresponding frame that store image positioning apparatus get form in comparison list; Read the test point information of document edge; Judge according to described test point information whether described file uses image positioning apparatus; When judging that described file uses image positioning apparatus,, export its corresponding frame and get format information according to the information of described image positioning apparatus; Get format information according to described frame, read the image of described file.
The present invention also provides a kind of image automatic frame taking device, and it comprises: several image positioning apparatus, in order to place file; One checkout gear is in order to the marginal information of output file; Whether one decision maker uses the judgement of image positioning apparatus in order to export described file; One storage device, in order to the output information of the described checkout gear of foundation and the output information of described decision maker, output box is got format information; And an image fetch device, in order to get format information, read the image of described file according to described frame.
The advantage of apparatus of the present invention is that it can effectively improve scan efficiency, especially scans the file of regular size, but its scanning reflection original text not only also can scan and penetrate original text, also can scan many parts of files simultaneously, and keep the smooth of file arrangements.
Below in conjunction with accompanying drawing, embodiments of the invention are described, wherein:
In order to improve scan efficiency, the present invention is directed to file format commonly used, as photo, lantern slide and business card etc., design has the image positioning apparatus of all size, by image positioning apparatus, scanner can directly read the imagery zone that sets fast, and manually frame is not got file.During scanning, as long as file is placed on the image positioning apparatus, choose scan function after, scanner is just got the image that form reads file according to the frame of image positioning apparatus automatically.
Image positioning apparatus of the present invention is a kind of shade with feature, shown in Figure 1A and Figure 1B.Figure 1A is the shade of single trellis, can scan individual file, no matter be to reflect original text or penetrate original text, Figure 1B then is the shade of many trellis, can scan many parts of files, especially lantern slide simultaneously.Image positioning apparatus shown in Figure 1B, the feature that its edge has rescinded angle or hole etc. to be easy to distinguish.The specification of these image positioning apparatus and corresponding frame are got form and are stored in the comparison list, according to the specification of image positioning apparatus, can find out corresponding frame and get form.Judge which kind of specification image positioning apparatus is, must decide according to its feature.
Image automatic frame taking method of the present invention is with reference to flow chart shown in Figure 2, as shown in the figure: step 201: will store image positioning apparatus and corresponding frame thereof and get form and list in the comparison list.Owing to image positioning apparatus is to design according to file specification commonly used, so many kinds are arranged.And every kind of specification all has a corresponding frame to get form, therefore, sets up comparison list according to its specification, but just the required frame of quick search is got form.
Step 202: the edge that detects file.Its main purpose is to seek the light signal of document edge, predicting its specification, and can find out the relative position of file on document platform simultaneously.
Step 203: read the test point of document edge, whether have some feature to judge this test point.Image positioning apparatus has two kinds of basic formats basically: promptly single file-type (shown in Figure 1A) and many parts of file-types (shown in Figure 1B).Because the edge of many parts of file-type image positioning apparatus has some feature, therefore just can declare and know whether this document uses many parts of file-type image positioning apparatus by the light signal of document edge.If the light signal of document edge has feature, then execution in step 204, otherwise execution in step 207.
Step 204: the test point that reads the adjacent both sides of file.
Step 205: judge whether this test point meets the feature that many parts of file-type image positioning apparatus set.Its determination methods reads the information of a, b, c, d and e, f, g, each test point of h please referring to Fig. 3.Because respectively there is a corner cut at the edge of this image positioning apparatus, therefore, if 2 of a, d or e, h be for bright entirely, all the other points represent then that for entirely secretly this document uses image positioning apparatus of the present invention.Certainly, corner cut is a kind of mode of representation feature, expressions such as all right in addition circular hole, square hole.If this test point meets the feature that many parts of file-type image positioning apparatus set, represent that then this document uses many parts of file-type image positioning apparatus, execution in step 206.Otherwise, execution in step 207.
Step 206:, read in the table of comparisons corresponding frame and get form according to the specification of this image positioning apparatus.
Step 207: because the light signal of document edge does not have feature, so, whether use single file-type image positioning apparatus with test this document with having the test point that rim detection algorithm (Edge Detection Algorithm) reads four jiaos of files now.
Step 208: judge whether this test point meets the feature that single file-type image positioning apparatus sets.Its determination methods can be consulted single file-type image positioning apparatus shown in Figure 4, reads information a, b, c and d, e, the f of its two cornerwise test point.If the information that e, b are 2 is for bright entirely, all the other points are dark entirely, represent that then this document uses single file-type image positioning apparatus, execution in step 206.Otherwise, execution in step 209.
Step 209:, then directly utilize the message box of rim detection point to get the edge of file, or use manual frame to get file if when this document does not use image positioning apparatus.
In step 206, be noted that because many parts of file-type image positioning apparatus tolerable files are placed arbitrarily whether have file to have any 3 points in the desirable file frame of detection method on the diagonal in the file frame so must detect earlier before reading.As shown in " L " file frame among Fig. 3, if wherein 3 then represent not place in this document frame file for bright entirely, otherwise, as long as wherein have a bit for dark, just represent to have in this document frame the file existence.As for single file-type image positioning apparatus, whether also must judge before reading information wherein has file to exist, as long as the information by its four jiaos test point and diagonal intersection point is judged, just whether there is file to exist in this document frame as can be known, if its diagonal intersection point is bright, then represent not place in this image positioning apparatus file, otherwise, promptly represent to have in this document frame file to exist.
In sum, image automatic frame taking device of the present invention mainly comprises: several have image positioning apparatus, a storage device, a checkout gear, a decision maker and an image fetch device of feature.During scanning, earlier file is positioned on the specific image positioning apparatus, can places the reflection original text or penetrate original text, also can once place many parts of files.In addition, need that in advance the information of various image positioning apparatus and frame are got form and be stored in this storage device, with convenient inquiry.During scanning, checkout gear is found out the position and the specification of file earlier by the light signal of document edge, the decision maker nationality judges by the feature whether light signal of document edge has setting whether file uses image positioning apparatus then, if have, then storage device is exported its corresponding frame and is got form, image fetch device just can be got form according to this frame and directly read the document image that this frame is got, if do not have, then the user must get file with manual frame with Genius mouse.