Anti-aliasing printing method and device, storage medium and scanner

Through high-resolution scanning and anti-aliasing processing, images suitable for printing are generated, which solves the problem of jagged image edges in scanners and improves printing effects, especially in office documents.

CN118769731AActive Publication Date: 2024-10-15GUANGZHOU ZHONO ELECTRONICS TECH CO LTD
View PDF 4 Cites 0 Cited by

Patent Information

Application Number
CN202410924819.0
Authority / Receiving Office
CN · China
Patent Type
Applications(China)
Current Assignee / Owner
Filing Date
2024-07-10
Publication Date
2024-10-15
Estimated Expiration
2044-07-10

AI Technical Summary

Technical Problem

Existing scanners are prone to jagged image edges during the scanning process, resulting in poor printing results. Especially in scenarios with many table elements in office documents, the low sampling accuracy and angle difference of CIS result in obvious jagged edges.

Method used

By scanning the target document at high resolution, a high-resolution first image is obtained, and anti-aliasing and downsampling are performed on it to generate a second image suitable for printing, thereby reducing aliasing in printed files.

Benefits of technology

It effectively reduces the aliasing phenomenon in the scanned image, improves the printing effect, especially in office documents, and reduces the aliasing problem caused by CIS accuracy and angle differences.

✦ Generated by Eureka AI based on patent content.

Smart Images

  • Figure CN118769731A_ABST
    Figure CN118769731A_ABST
Patent Text Reader

Abstract

The invention provides an anti-aliasing printing method and device, a storage medium and a scanner, and relates to the field of office equipment. Wherein the scanner scans a target document to obtain a first image of the target document; according to the first image, a second image of the target document is obtained, and the resolution ratio of the first image is higher than that of the second image; and controlling the printer to answer the second image to obtain a printed file of the target document. Therefore, due to the fact that the sawtooth phenomenon can be reduced through the high scanning resolution, the target document is scanned with the high resolution, the first image with few sawteeth is obtained, and then the resolution of the first image is reduced to obtain the second image suitable for printing. In this way, the sawtooth phenomenon in the printed file is reduced.
Need to check novelty before this filing date? Find Prior Art

Description

Technical Field

[0001] The present application relates to the field of office equipment, and in particular to an anti-aliasing printing method, device, storage medium and scanner. Background Art

[0002] At present, with the popularization of automated office, scanners are widely used in modern office scenes. Therefore, printers integrated with scanners have become mainstream products in the printer market. Combined with the scanning function, the printer can directly transfer the paper document into a document or output it to the host computer in image format after scanning, combining functionality and ease of use. Current consumer-grade scanners usually use CMOS (Complementary Metal-Oxide-Semiconductor) image sensors as optical / electrical devices, hereinafter referred to as CIS (CMOS Image Sensor). The scanner generates a light source to illuminate the image, and the generated reflected light signal is converted by the CIS into an analog electrical signal, and then converted into a digital signal through an A / D converter, that is, the grayscale and RGB information of the image.

[0003] The CIS sensors are distributed in a two-dimensional matrix or vector structure (similar to the pixels on the screen, one vector is one column). When scanning a document, it moves relative to the document being scanned, and completes the image scanning through multiple sampling. The electrical signal generated by CIS is in the form of a matrix, and the sampling resolution depends on the parameters of CIS. Therefore, the sampling accuracy of the sensor directly determines the scanning quality. Currently, the sampling accuracy of the integrated scanners in printers on the market is mostly 600DPI or 1200DPI.

[0004] However, it has been found in practice that in many scanning scenarios, the scanned image has jagged edges, resulting in poor final printing results. Summary of the invention

[0005] In order to overcome at least one of the deficiencies in the prior art, the present application provides an anti-aliasing printing method, device, storage medium and scanner, specifically including:

[0006] In a first aspect, the present application provides an anti-aliasing printing method, applied to a scanner, the method comprising:

[0007] Scanning a target document to obtain a first image of the target document;

[0008] Obtaining a second image of the target document according to the first image, wherein a resolution of the first image is higher than a resolution of the second image;

[0009] Controlling a printer to print the second image to obtain a print file of the target document.

[0010] In conjunction with an optional implementation manner of the first aspect, obtaining a second image of the target document according to the first image includes:

[0011] The first image is downsampled to obtain the second image.

[0012] In conjunction with an optional implementation manner of the first aspect, obtaining a second image of the target document according to the first image includes:

[0013] Performing anti-aliasing processing on the first image to obtain an optimized first image;

[0014] The optimized first image is downsampled to obtain the second image.

[0015] In combination with an optional implementation manner of the first aspect, performing anti-aliasing processing on the first image to obtain an optimized first image includes:

[0016] identifying pattern edges in the first image;

[0017] For each edge pixel located at the edge of the pattern, determining adjacent pixels located within a preset range of the edge pixel;

[0018] Merging the pixel value of the edge pixel with the pixel value of the adjacent pixel to obtain an optimized edge pixel;

[0019] The optimized first image is obtained according to each optimized edge pixel.

[0020] In combination with an optional implementation manner of the first aspect, the scanner includes an image sensor for scanning a document and capable of rotating, and scanning the target document to obtain a first image of the target document includes:

[0021] Controlling the image sensor to rotate so as to keep the target document in the same orientation;

[0022] The image sensor is kept in the placement orientation and the target document is scanned to obtain a first image of the target document.

[0023] In combination with an optional implementation manner of the first aspect, controlling the image sensor to rotate so as to maintain a consistent placement orientation of the target document includes:

[0024] Acquire a deflection angle of the target document, wherein the deflection angle represents an angle between a placement orientation of the target document and a standard orientation;

[0025] The image sensor is controlled to rotate the deflection angle in a direction close to the target document, so that the orientation of the image sensor is consistent with the placement orientation of the target document.

[0026] In combination with an optional implementation manner of the first aspect, the scanner includes a first processor and a second processor; the first image is each partial scanned image of the target document, and obtaining the second image of the target document according to the first image includes:

[0027] Performing anti-aliasing processing on the local scanned image by the first processor to obtain an optimized local scanned image;

[0028] Downsampling the optimized local scan image by the second processor to obtain a downsampled local scan image;

[0029] The downsampled local scanned image is used as the second image.

[0030] In a second aspect, the present application further provides an anti-aliasing printing device, applied to a scanner, the device comprising:

[0031] A document scanning module, used for scanning a target document to obtain a first image of the target document;

[0032] An image optimization module, configured to obtain a second image of the target document based on the first image, wherein a resolution of the first image is higher than a resolution of the second image;

[0033] The document printing module is used to control the printer to process the second image to obtain a print file of the target document.

[0034] In conjunction with the optional implementation manner of the second aspect, the image optimization module is further specifically used for:

[0035] The first image is downsampled to obtain the second image.

[0036] In conjunction with the optional implementation manner of the second aspect, the image optimization module is further specifically used for:

[0037] Performing anti-aliasing processing on the first image to obtain an optimized first image;

[0038] The optimized first image is downsampled to obtain the second image.

[0039] In conjunction with the optional implementation manner of the second aspect, the image optimization module is further specifically used for:

[0040] identifying pattern edges in the first image;

[0041] For each edge pixel located at the edge of the pattern, determining adjacent pixels located within a preset range of the edge pixel;

[0042] Merging the pixel value of the edge pixel with the pixel value of the adjacent pixel to obtain an optimized edge pixel;

[0043] The optimized first image is obtained according to each optimized edge pixel.

[0044] In conjunction with an optional implementation manner of the second aspect, the scanner includes a rotatable image sensor for scanning a document, and the document scanning module is further specifically configured to:

[0045] Controlling the image sensor to rotate so as to keep the target document in the same orientation;

[0046] The image sensor is kept in the placement orientation and the target document is scanned to obtain a first image of the target document.

[0047] In conjunction with the optional implementation manner of the second aspect, the document scanning module is further specifically used for:

[0048] Acquire a deflection angle of the target document, wherein the deflection angle represents an angle between a placement orientation of the target document and a standard orientation;

[0049] The image sensor is controlled to rotate the deflection angle in a direction close to the target document, so that the orientation of the image sensor is consistent with the placement orientation of the target document.

[0050] In conjunction with an optional implementation manner of the second aspect, the scanner includes a first processor and a second processor; the first image is each partial scanned image of the target document, and the image optimization module is further specifically used for:

[0051] Performing anti-aliasing processing on the local scanned image by the first processor to obtain an optimized local scanned image;

[0052] Downsampling the optimized local scan image by the second processor to obtain a downsampled local scan image;

[0053] The downsampled local scanned image is used as the second image.

[0054] In a third aspect, the present application further provides a storage medium, wherein the storage medium stores a computer program, and when the computer program is executed by a processor, the anti-aliasing printing method is implemented.

[0055] In a fourth aspect, the present application further provides a scanner, comprising a processor and a memory, wherein the memory stores a computer program, and when the computer program is executed by the processor, the anti-aliasing printing method is implemented.

[0056] Compared with the prior art, this application has the following beneficial effects:

[0057] The present application provides an anti-aliasing printing method, device, storage medium and scanner. The scanner scans a target document to obtain a first image of the target document; based on the first image, a second image of the target document is obtained, wherein the resolution of the first image is higher than the resolution of the second image; the printer is controlled to scan the second image to obtain a printed file of the target document. In this way, since a higher scanning resolution can reduce the aliasing phenomenon, the target document is scanned at a higher resolution to obtain a first image with less aliasing, and then the resolution of the first image is reduced to obtain a second image suitable for printing. In this way, the aliasing phenomenon in the printed file is reduced. BRIEF DESCRIPTION OF THE DRAWINGS

[0058] In order to more clearly illustrate the technical solutions of the embodiments of the present application, the drawings required for use in the embodiments will be briefly introduced below. It should be understood that the following drawings only show certain embodiments of the present application and therefore should not be regarded as limiting the scope. For ordinary technicians in this field, other related drawings can be obtained based on these drawings without paying creative work.

[0059] Figure 1 A flowchart of an anti-aliasing printing method provided in an embodiment of the present application;

[0060] Figure 2 A schematic diagram of the deflection angle provided in the embodiment of the present application;

[0061] Figure 3 A schematic diagram of the rotation of an image sensor provided in an embodiment of the present application;

[0062] Figure 4 A schematic diagram of a local scan image provided in an embodiment of the present application;

[0063] Figure 5 A schematic diagram of the structure of a scanner provided in an embodiment of the present application;

[0064] Figure 6 A schematic diagram of the structure of an anti-aliasing printing device provided in an embodiment of the present application.

[0065] Icons: 11 - image sensor; 12 - target document; 21 - processor; 22 - memory; 23 - system bus; 31 - document scanning module; 32 - image optimization module; 33 - document printing module. DETAILED DESCRIPTION

[0066] In order to make the purpose, technical solution and advantages of the embodiments of the present application clearer, the technical solution in the embodiments of the present application will be clearly and completely described below in conjunction with the drawings in the embodiments of the present application. Obviously, the described embodiments are part of the embodiments of the present application, rather than all the embodiments. The components of the embodiments of the present application described and shown in the drawings here can be arranged and designed in various different configurations.

[0067] Therefore, the following detailed description of the embodiments of the present application provided in the accompanying drawings is not intended to limit the scope of the present application for which protection is sought, but merely represents selected embodiments of the present application. Based on the embodiments in the present application, all other embodiments obtained by ordinary technicians in the field without creative work are within the scope of protection of the present application.

[0068] It should be noted that similar reference numerals and letters denote similar items in the following drawings, and therefore, once an item is defined in one drawing, further definition and explanation thereof is not required in subsequent drawings.

[0069] In the description of the present application, it should be noted that the terms "first", "second", "third", etc. are only used to distinguish the description and cannot be understood as indicating or implying relative importance. In addition, the terms "comprise", "include" or any other variants thereof are intended to cover non-exclusive inclusion, so that a process, method, article or device including a series of elements includes not only those elements, but also includes other elements not explicitly listed, or also includes elements inherent to such process, method, article or device. In the absence of further restrictions, an element defined by the sentence "comprises a ..." does not exclude the presence of other identical elements in the process, method, article or device including the element.

[0070] Based on the above statement, as introduced in the background technology, in many scanning scenarios, there is a problem of jagged edges in the scanned image, which makes the final printing effect poor. For this phenomenon, after a large number of experiments, it was found that the frequency of jagged edges in the scanned images of office documents is much higher than that of non-office documents. The reason for this phenomenon is that table elements are widely used in office documents and occupy a huge and important content in office documents. If there is a small angle difference between the CIS and the document, it will cause jagged features to appear in the long line segments in the scanned image, and the obviousness of the jagged edges is related to the CIS sampling accuracy and the horizontal angle between the straight edge and the sensor, and the lower the CIS accuracy, the more obvious the jagged edges.

[0071] Based on the discovery of the above technical problems, the inventors have proposed the following technical solutions to solve or improve the above problems through creative work. It should be noted that the defects in the solutions in the above prior art are the results obtained by the inventors after practice and careful research. Therefore, the discovery process of the above problems and the solutions proposed in the embodiments of the present application for the above problems below should all be the contributions made by the inventors to the present application in the process of invention and creation, and should not be understood as technical contents known to those skilled in the art.

[0072] In view of the above findings, the present embodiment provides an anti-aliasing printing method. In the method, a scanner scans a target document to obtain a first image of the target document; based on the first image, a second image of the target document is obtained, wherein the resolution of the first image is higher than the resolution of the second image; and a printer is controlled to scan the second image to obtain a printed file of the target document. In this way, since a higher scanning resolution can reduce the aliasing phenomenon, the target document is scanned at a higher resolution to obtain a first image with less aliasing, and then the resolution of the first image is reduced to obtain a second image suitable for printing. In this way, the aliasing phenomenon in the printed file is reduced.

[0073] To make the solution provided by this embodiment clearer, Figure 1 Each step of the method is described in detail. However, it should be understood that the operations of the flowchart may not be implemented in order, and steps without logical contextual relationships may be reversed in order or implemented simultaneously. In addition, those skilled in the art may add one or more other operations to the flowchart, or remove one or more operations from the flowchart under the guidance of the content of this application. Figure 1 As shown, the method includes:

[0074] S1, scanning a target document to obtain a first image of the target document.

[0075] In this embodiment, the target document is a document to be printed, which may include a text document, a graphic document, a business card, etc. Among them, the text document may include a report, a contract, an invoice, a receipt, etc. The graphic document may include a photo, a picture, a chart, etc.

[0076] In addition, assuming that the sampling precision supported by the scanner includes 600 DPI and 1200 DPI, the target document is scanned with the higher 1200 DPI to obtain the first image. In this way, the target document is scanned with the highest resolution possible, so that the scanned first image has less jaggedness.

[0077] In addition, given that the cause of aliasing in the scanned image is that when there is a small angle difference between the CIS and the document, the long line segments in the scanned image will have aliased features, and the degree of aliasing is related to the CIS sampling accuracy and the horizontal angle between the straight edge and the sensor. Based on this finding, the scanner of this embodiment also includes an image sensor for scanning documents and capable of rotation, and the angle of the image sensor is adjusted to reduce the generation of aliasing. Therefore, this embodiment also provides the following optional implementation of step S1:

[0078] S1-1, controlling the image sensor to rotate so as to keep the orientation of the target document consistent.

[0079] In this regard, it should be noted that the operating steps of a scanner usually include the following steps: first, place the target document to be scanned on the glass plate of the scanner and make sure it is facing down; then, set the resolution, color mode and other settings on the scanner; next, start the scanner's scanning program, which can usually be operated through the buttons on the scanner or the software on the computer; during the scanning process, the scanner's light tube will move to capture the image of the target document; after the scan is completed, the scanned image can be obtained.

[0080] Among them, when preparing to place the target document on the glass plate of the scanner for scanning, the ideal operation is to place the front of the target document face down and ensure that their edges are aligned parallel to the reference lines provided on the scanner glass plate. Such placement can ensure that the scanned image is clear and correct, and avoid image skew or distortion. However, in actual operation, due to the flatness and curvature of the document itself or slight errors made by the user when placing it, the placement orientation of the target document may not be completely consistent with the ideal standard orientation. This may cause the target document to have a small angle deflection when scanning. Although the angle of this deflection is usually small, perhaps within a few degrees, it may still affect the final scanning result, especially in application scenarios with high requirements for image quality.

[0081] The orientation of the image sensor in the initial state is consistent with the standard orientation, which results in a horizontal angle between the straight edge in the document and the sensor. Figure 2As shown, the orientation of the image sensor 11 is consistent with the standard orientation, but the target document 12 has a certain deflection angle θ from the standard orientation. Therefore, in this embodiment, based on the image sensor 11 that can rotate horizontally, the scanner obtains the deflection angle of the target document 12, wherein the deflection angle represents the angle between the placement orientation of the target document 12 and the standard orientation; the image sensor 11 is controlled to rotate the deflection angle in the direction close to the target document 12, so that the orientation of the image sensor 11 is consistent with the placement orientation of the target document 12. In this way, the aliasing caused by the angle difference between the CIS and the document is reduced.

[0082] It is worth emphasizing that when scanning a target document, both high-resolution scanning and adjusting the image sensor angle can be used simultaneously, or one of the two measures can be selected and used alone. In this embodiment, the specific combination of these two strategies is not limited.

[0083] S1-2, keep the image sensor in the placement direction, and scan the target document to obtain a first image of the target document.

[0084] Continue with Figure 2 Take the image sensor and target document in as an example. Figure 3 As shown, Figure 2 The image sensor 11 in the scanner is rotated by a corresponding deflection angle θ in a direction close to the target document 12, so that the image sensor 11 and the target document 12 are placed in the same orientation. Then, the scanner maintains the current orientation of the image sensor 11 and scans the target document 12 in a preset scanning direction until the entire target document 12 is scanned, thereby obtaining a first image of the target document 12.

[0085] Continue to see Figure 1 , based on the first image obtained in the above embodiment, the method further includes:

[0086] S2, obtaining a second image of the target document according to the first image.

[0087] The resolution of the first image is higher than the resolution of the second image.

[0088] As an optional implementation provided by this embodiment, the scanner can directly downsample the first image to obtain the second image. It should be noted that there are many mature downsampling processing algorithms, which will not be described in detail in this embodiment. For example, the method of downsampling the first image can be a classic bilinear interpolation image scaling algorithm.

[0089] As another optional implementation provided by this embodiment, in order to further improve the image quality of the second image, before downsampling the first image, the first image is subjected to anti-aliasing processing, so that the edge aliasing in the second image can be further reduced. Therefore, this embodiment also provides the following implementation of step S2:

[0090] S2-1, performing anti-aliasing processing on the first image to obtain an optimized first image.

[0091] In this embodiment, the so-called anti-aliasing process is mainly achieved by mixing the pixels at the edge with the pixels around it to reduce the grayscale difference of the edge of the pattern, thereby achieving the effect of eliminating aliasing. In a specific implementation, the scanner identifies the edge of the pattern in the first image; for each edge pixel located at the edge of the pattern, the adjacent pixels located within a preset range of the edge pixel are determined; the pixel value of the edge pixel is merged with the pixel value of the adjacent pixel to obtain an optimized edge pixel; and the optimized first image is obtained based on each optimized edge pixel.

[0092] Exemplarily, the scanner can gradually traverse the first image with a window of size 2×2, perform edge detection, and identify the pattern edge in the first image. The pattern edge here can be a table edge, a text edge, etc. in the first image. The edge types include U-type, L-type, and Z-type edges. For a longer Z-type edge, it can be decomposed into multiple L-type edges. For each edge pixel located at the edge of the pattern, its pixel value is weighted with the pixel values ​​of the surrounding pixels to obtain the pixel value of the edge pixel. In this way, the grayscale difference of the edge of the graphic is reduced, so that the jagged edges in the image are not too obvious.

[0093] Based on the optimized first image obtained by anti-aliasing processing, step S2 further includes:

[0094] S2-2, downsampling the optimized first image to obtain a second image.

[0095] In this way, the optimized first image is downsampled to a second image suitable for printing. Figure 1 Based on the second image, the anti-aliasing printing method provided by this embodiment further includes:

[0096] S3, controlling the printer to print the second image to obtain a print file of the target document.

[0097] Exemplarily, the scanner sends the second image to the printer so that the printer processes the second image.

[0098] In addition, the scanner in this embodiment may also include a first processor and a second processor. When scanning the target document, if the two can run in parallel, the scanning efficiency can be greatly improved. In practice, it is found that if the first image is a complete scanned image of the target document, it means that it is necessary to wait until the target document is scanned before the obtained first image can be optimized. Therefore, in order to make full use of the computing power of the first processor and the second processor, the first image in this embodiment can be each partial scanned image of the target document. It should be noted that, under normal circumstances, the size of the target document is much larger than the size of the image sensor in the scanner, which requires controlling the image sensor to scan the target document multiple times until the entire target document is scanned. Each time a part of the target document is scanned, a partial scanned image of the target document can be obtained. For example, Figure 4 As shown, in this embodiment, the target document 12 can be scanned line by line along the scanning direction by the image sensor, and the image obtained by scanning each line is used as a partial scan image. It should be noted that Figure 4 The scanning path shown is only an example provided by this embodiment. Of course, the target document can also be scanned through other scanning paths as long as the scanning of the entire target document can be completed.

[0099] In order to improve processing efficiency, the target document is scanned by the first processor, and the scanned partial image is anti-aliased and then handed over to the second processor for downsampling. While the second processor is downsampling the line scan image, the first processor continues to scan the target document and anti-aliased the scanned partial image. In this way, the image acquisition operation, anti-aliasing operation and downsampling operation can be performed simultaneously, thereby improving the scanning efficiency. In a specific implementation, the scanner can perform anti-aliasing on the partial scan image through the first processor to obtain an optimized partial scan image; downsample the optimized partial scan image through the second processor to obtain a downsampled partial scan image; and use the downsampled partial scan image as the second image.

[0100] For example, Figure 5 As shown, it is assumed that the scanner includes CIS, AD converter, 2 processors (named CPU0 and CPU1 respectively) and memory (including RAM and ROM). Each processor is an ARM processor and has its own L1 cache. There is a 16KB L2 cache between the two processors. The two processors run at the same time, and the data flow direction between the processors is: CIS->AD converter->RAM->CPU0->L2Cache / RAM->CPU1->printer. The specific process is as follows:

[0101] CPU0 controls CIS to scan the target document and sends a line of scanning signals to ADC. After ADC converts the scanning signal into a line of partial scanning image, it generates an interrupt signal, so that CPU0 reads a line of partial scanning image from ADC and stores it in RAM. CPU0 then performs anti-aliasing processing on a line of partial scanning image and stores the optimized partial scanning image obtained by anti-aliasing processing in L2Cache. When a line of partial scanning image processing is completed, CPU0 initiates communication or interruption to CPU1, and CPU1 obtains a line of partial scanning image from L2Cache and scales it through a dual interpolation algorithm. The scaled data can be stored in RAM / ROM by CPU1 or directly output to the printer for printing.

[0102] Based on the same inventive concept as the anti-aliasing printing method provided in this embodiment, this embodiment also provides an anti-aliasing printing device, which includes at least one software function module that can be stored in a memory or fixed in an electronic device in the form of software. The processor in the electronic device is used to execute the executable module stored in the memory. For example, the software function module and computer program included in the anti-aliasing printing device. Please refer to Figure 6 , from the functional point of view, the anti-aliasing printing device may include:

[0103] The document scanning module 31 is used to scan the target document to obtain a first image of the target document;

[0104] An image optimization module 32, configured to obtain a second image of the target document based on the first image, wherein a resolution of the first image is higher than a resolution of the second image;

[0105] The document printing module 33 is used to control the printer to print the second image to obtain a print file of the target document.

[0106] In this embodiment, the document scanning module 31 is used to implement Figure 1 In step S1, the image optimization module 32 is used to implement Figure 1 In S2, the document printing module 33 is used to implement Figure 1 For detailed description of the above modules, please refer to the specific implementation of the corresponding steps. In addition, it should be noted that, in view of the same inventive concept as the anti-aliasing printing method, the above modules can also be used to implement other steps or sub-steps of the method, which will not be described in detail in this embodiment.

[0107] In addition, the functional modules in the various embodiments of the present application may be integrated together to form an independent part, or each module may exist separately, or two or more modules may be integrated to form an independent part.

[0108] It should also be understood that if the above implementation is implemented in the form of a software function module and sold or used as an independent product, it can be stored in a computer-readable storage medium. Based on this understanding, the technical solution of the present application, or the part that contributes to the prior art, or the part of the technical solution, can be embodied in the form of a software product, which is stored in a storage medium and includes several instructions for a computer device (which can be a personal computer, a server, or a network device, etc.) to perform all or part of the steps of the method described in each embodiment of the present application.

[0109] Therefore, this embodiment further provides a storage medium, which is a computer-readable storage medium. The storage medium stores a computer program, and when the computer program is executed by a processor, the anti-aliasing printing method provided in this embodiment is implemented. Among them, the storage medium can be a U disk, a mobile hard disk, a read-only memory (ROM), a random access memory (RAM), a disk or an optical disk, etc., which can store program codes.

[0110] This embodiment provides a scanner for implementing the above anti-aliasing printing. Figure 5 The scanner may include a processor 21 and a memory 22. In addition, the memory 22 stores a computer program, and the processor implements the anti-aliasing printing method provided in this embodiment by reading and executing the computer program corresponding to the above implementation in the memory 22.

[0111] Continue to see Figure 5 The memory 22, the processor 21 and possible other components are electrically connected directly or indirectly via a system bus 23 to achieve data transmission or interaction.

[0112] The memory 22 may be an information recording device based on any electronic, magnetic, optical or other physical principle, for recording execution instructions, data, etc. In some embodiments, the memory 22 may be, but is not limited to, a volatile memory, a non-volatile memory, a storage drive, etc.

[0113] In some embodiments, the volatile memory may be a random access memory (RAM); in some embodiments, the non-volatile memory may be a read-only memory (ROM), a programmable read-only memory (PROM), an erasable programmable read-only memory (EPROM), an electrically erasable read-only memory (EEPROM), a flash memory, etc.; in some embodiments, the storage drive may be a disk drive, a solid-state drive, any type of storage disk (such as a CD, a DVD, etc.), or a similar storage medium, or a combination thereof, etc.

[0114] The processor 21 may be an integrated circuit chip having a signal processing capability, and the processor may include one or more processing cores (e.g., a single-core processor or a multi-core processor). By way of example only, the processor may include a central processing unit (CPU), an application specific integrated circuit (ASIC), an application specific instruction set processor (ASIP), a graphics processing unit (GPU), a physical processing unit (PPU), a digital signal processor (DSP), a field programmable gate array (FPGA), a programmable logic device (PLD), a controller, a microcontroller unit, a reduced instruction set computer (RISC), or a microprocessor, or any combination thereof.

[0115] Understandably, Figure 5 The structure shown is for illustration only. The scanner may also have Figure 5 More or fewer components than shown, or with Figure 5The components shown in FIG5 can be implemented by hardware, software or a combination thereof. For example, the scanner can also include direct memory access (DMA), a printer interface, a communication unit, an AD converter, etc.

[0116] The printer interface is used for printer communication, so that the image scanned by the scanner can be sent to the printer through the printer interface.

[0117] AD converter is used to convert analog signal (Analog Signal) into digital signal (Digital Signal). Here, "AD" stands for "Analog to Digital". In electronic devices and computer systems, analog signals are everywhere, such as sound, temperature, light, pressure, etc., but computers process digital signals, so AD converters are needed to convert these signals into digital signals. In this embodiment, the AD converter is used to convert the light signal collected by the image sensor into a digital signal.

[0118] Direct memory access allows computer hardware subsystems (such as hard drives, graphics cards, network interface cards, etc.) to directly access system memory to read or write data without the intervention of the central processing unit (CPU). This can significantly improve the efficiency of data transfer because DMA reduces the burden on the CPU, allowing the CPU to handle other tasks instead of being busy with the details of data transfer.

[0119] A communication unit for sending and receiving data through a network. In some embodiments, the network may include a wired network, a wireless network, a fiber optic network, a telecommunication network, an intranet, the Internet, a local area network (LAN), a wide area network (WAN), a wireless local area network (WLAN), a metropolitan area network (MAN), a wide area network (WAN), a public switched telephone network (PSTN), a Bluetooth network, a ZigBee network, or a near field communication (NFC) network, or any combination thereof. In some embodiments, the network may include one or more network access points. For example, the network may include a wired or wireless network access point, such as a base station and / or a network switching node, through which one or more components of the service request processing system may be connected to the network to exchange data and / or information.

[0120] It should be understood that the apparatus and method disclosed in the above-mentioned embodiments can also be implemented in other ways. The apparatus embodiments described above are merely schematic. For example, the flowcharts and block diagrams in the accompanying drawings show the possible architecture, functions and operations of the apparatus, methods and computer program products according to the multiple embodiments of the present application. In this regard, each box in the flowchart or block diagram can represent a module, a program segment or a part of a code, and the module, a program segment or a part of a code contains one or more executable instructions for implementing the specified logical function. It should also be noted that in some alternative implementations, the functions marked in the box can also occur in a different order from the order marked in the accompanying drawings. For example, two consecutive boxes can actually be executed substantially in parallel, and they can sometimes be executed in the opposite order, depending on the functions involved. It should also be noted that each box in the block diagram and / or the flowchart, and the combination of boxes in the block diagram and / or the flowchart can be implemented with a dedicated hardware-based system that performs a specified function or action, or can be implemented with a combination of dedicated hardware and computer instructions.

[0121] The above are only various implementations of the present application, but the protection scope of the present application is not limited thereto. Any person skilled in the art who is familiar with the present technical field can easily think of changes or substitutions within the technical scope disclosed in the present application, which should be included in the protection scope of the present application. Therefore, the protection scope of the present application should be based on the protection scope of the claims.

Claims

1. An anti-aliasing printing method, characterized in that: Applied to a scanner, the method comprises: Scanning a target document to obtain a first image of the target document; Obtaining a second image of the target document according to the first image, wherein a resolution of the first image is higher than a resolution of the second image; Controlling a printer to print the second image to obtain a print file of the target document.

2. The anti-aliasing printing method according to claim 1, characterized in that: The step of obtaining a second image of the target document according to the first image includes: The first image is downsampled to obtain the second image.

3. The anti-aliasing printing method according to claim 1, characterized in that: The step of obtaining a second image of the target document according to the first image includes: Performing anti-aliasing processing on the first image to obtain an optimized first image; The optimized first image is downsampled to obtain the second image.

4. The anti-aliasing printing method according to claim 3, characterized in that: The step of performing anti-aliasing processing on the first image to obtain an optimized first image includes: identifying pattern edges in the first image; For each edge pixel located at the edge of the pattern, determining adjacent pixels located within a preset range of the edge pixel; Merging the pixel value of the edge pixel with the pixel value of the adjacent pixel to obtain an optimized edge pixel; The optimized first image is obtained according to each optimized edge pixel.

5. The anti-aliasing printing method according to claim 1, characterized in that: The scanner includes a rotatable image sensor for scanning a document, and scanning a target document to obtain a first image of the target document includes: Controlling the image sensor to rotate so as to keep the target document in the same orientation; The image sensor is kept in the placement orientation and the target document is scanned to obtain a first image of the target document.

6. The anti-aliasing printing method according to claim 5, characterized in that: The controlling the image sensor to rotate so as to keep the target document in the same orientation comprises: Acquire a deflection angle of the target document, wherein the deflection angle represents an angle between a placement orientation of the target document and a standard orientation; The image sensor is controlled to rotate the deflection angle in a direction close to the target document, so that the orientation of the image sensor is consistent with the placement orientation of the target document.

7. The anti-aliasing printing method according to claim 1, characterized in that: The scanner includes a first processor and a second processor; the first image is each partial scanned image of the target document, and obtaining the second image of the target document according to the first image includes: Performing anti-aliasing processing on the local scanned image by the first processor to obtain an optimized local scanned image; Downsampling the optimized local scan image by the second processor to obtain a downsampled local scan image; The downsampled local scanned image is used as the second image.

8. An anti-aliasing printing device, characterized in that: Applied to a scanner, the device comprises: A document scanning module, used for scanning a target document to obtain a first image of the target document; An image optimization module, configured to obtain a second image of the target document based on the first image, wherein a resolution of the first image is higher than a resolution of the second image; The document printing module is used to control the printer to process the second image to obtain a print file of the target document.

9. A storage medium, characterized in that: The storage medium stores a computer program, and when the computer program is executed by a processor, the anti-aliasing printing method according to any one of claims 1 to 7 is implemented.

10. A scanner, characterized in that: The scanner includes a processor and a memory, wherein the memory stores a computer program, and when the computer program is executed by the processor, the anti-aliasing printing method according to any one of claims 1 to 7 is implemented.

Citation Information

Patent Citations

  • Text printing method and system and storage medium

    CN110502194A

  • Image anti-aliasing processing method and electronic equipment

    CN113837955A

  • Method for detecting file scanned image rotating angle and pantographic ratio

    CN1776715A

  • Image scanning method

    US20040036926A1