Due to the ease of use and the proliferation of digital devices, the number of print devices (also referred to as printers) in use has increased in recent years. One usual operation in a printer is the scaling of an image to be printed. Scaling, as used herein, refers to the change in the number of pixels and is usually described by the ratio of the number of pixels in the input image to the number of pixels in the output image. For example, if for every three consecutive pixels in a column of the input image there are two consecutive pixels in the corresponding column of the output image, the scaling is referred to as 3:2 scaling.
Scaling is conventionally performed on the input image pixel data onto pixel by pixel basis. In one instance, the input image pixels are individually “windowed” by selecting a small window of the input image pixels that surround the pixel that is being processed for scaling. The pixel data for the pixel in the scaled (output) image is derived from the values of the pixel data of the input image pixel that is being processed and selected ones of the input image pixels located in the “window.”
However, typically, the scaling operation requires extensive computation or arithmetic operations on the pixel data of the pixel being processed and the surrounding pixels. In conventional methods, the window of the input image pixels that surrounds the pixel being processed is small and the computations or arithmetic operations are performed using dedicated hardware or processors and software instructions.
Alternatively, the scaling processing instructions can be described in software. The software can then be embodied into a computer memory in the printer. (Software when used as a permanent part of a device is referred to as “firmware” or “microcode.”) Performing the scaling operation solely using software can be typically slow as compared to using dedicated hardware.
There is therefore a need to provide methods and systems for performing the scaling operations that provide the advantages of both dedicated hardware and of software while avoiding the disadvantages of either a dedicated hardware or software.
One embodiment of the method of this invention includes selecting one pixel from the input image, selecting a pixel neighborhood including a number of pixels on the input image in neighboring the selected pixel, and comparing the pixel neighborhood to a predetermined pattern in order to determine whether the predetermined pattern is present in the pixel neighborhood. If the predetermined pattern is present in the pixel neighborhood, a predetermined scaling algorithm is applied to some of the pixels from the pixel neighborhood and scaled image pixel data is obtained from the application of the predetermined scaling algorithm.
An embodiment of the system of this invention includes a computing component capable of comparing a pixel neighborhood from the input image to a pattern to determine if the pattern is present in the pixel neighborhood and a computer usable medium having computer readable code embodied therein, the computer readable code being capable of causing the computing component to, if the pattern is present in the pixel neighborhood, obtain, from input image data of at least some pixels from the pixel neighborhood, scaled image pixel data by applying a predetermined scaling algorithm.
For a better understanding of the present invention, together with other and further needs thereof, reference is made to the accompanying drawings and detailed description and its scope will be pointed out in the appended claims.
a-2f are schematic pictorial representation of exemplary embodiments of patterns and scaling algorithms;
a, 3b are schematic pictorial representation of exemplary embodiments of patterns for “toner scatter compensation”; and
Unless defined otherwise below, all technical and scientific terms used herein have the same meaning as commonly understood by one of ordinary skill in the art to which this invention belongs. Still, certain terms are defined herein for the sake of clarity.
The following definitions are provided for specific terms that are used in the following written description.
A lookup table (“LUT”), as used herein, refers to a table detailing data for an output image pixel for corresponding input image pixel data. For example, this invention not being limited to this example, if X represents the data for an output image pixel, and A and B represent data for two input image pixels used to obtain X, and if X is given by
X=A*(2/3)+B*(1/3), and
A “Toner scatter compensation” algorithm, as used herein, refers to an algorithm to correct for artifacts caused by toner that is scattered when moisture in the media suddenly vaporizes.
In one embodiment, the “Toner scatter compensation” bottom algorithm replaces the pixel values for the inner pixels in the row preceding the last row that does not completely have all pixel data equal to zero with a reduced pixel value. In an exemplary embodiment, this invention not being limited only to this embodiment, for an input image that has 7 columns and 8 rows (shown below)
In one embodiment of the method for scaling an input image of this invention, the input image is scaled by applying a predetermined scaling algorithm after detection of a specific pattern of pixels. The embodiment of the method of this invention includes recognition of a pattern in a group or neighborhood of pixels from the input image and, after recognition of pattern, applying a predetermined scaling algorithm. The steps in this embodiment of the method of this invention include selecting one pixel from the input image, selecting a pixel neighborhood including a number of pixels on the input image in neighboring the selected pixel, and comparing the pixel neighborhood to a predetermined pattern in order to determine whether the predetermined pattern is present in the pixel neighborhood. If the predetermined pattern is present in the pixel neighborhood, a predetermined scaling algorithm is applied to some of the pixels from the pixel neighborhood and scaled image pixel data is obtained from the application of the predetermined scaling algorithm.
In one instance, the predetermined scaling algorithm includes providing pixel data from at least two pixels in the input image and obtaining, from at least one look-up table, pixel data for at least one pixel in the scaled image.
In many embodiments, scaling down requires multiplying the input pixel data for some of the input pixels by a scaling factor, which can be different for a number of combinations of input pixels. For example, the present invention not being limited to this example, if the scale factor of 0.91 is desired for a single dimension of an image (that is, for every 100 pixels in the dimension to be scaled, the output image has 91 pixels in that dimension), the scaling relationship is given by
O1=0.91*I1+0.09*I2
O2=0.82*I2+0.18*I3
O3=0.73*I3+0.27*I4
for the first of the output pixel:
where O1, O2, O3 are the pixel data for the first three output image pixels, and I1, I2, I3, I4 at the pixel data for the first four input image pixels. There would be 88 more equations for the remaining corresponding 88 output image pixels. For an arbitrary scaling factor, a large number of equations (91 in the above example) will be required.
In many embodiments, the scaling factors can be limited to a finite number of scaling factors of limited extent (such as, but not limited to, 3:2, 4:3, 5:4, 5:3, 6:5). For that finite number of scaling factors of limited extent, the pixel data for the scaled image can be pre-calculated and stored in a lookup table for each scaling factor. A finite number of lookup tables of limited extent can be used to obtain the scaled image for any of the finite number of scaling factors. It should be noted that the scaling function does not have to be linear. A nonlinear scaling function can be used, pre-calculated, and stored in a lookup table. The use of nonlinear scaling functions enables the compensation of printing nonlinearities.
An exemplary neighborhood 10 of pixels, a 5 row and 3 column neighborhood (window) 10 around a pixel of interest 15, “h,” is shown in
X=A*(2/3)+B*(1/3),
Y=C*(2/3)+B*(1/3).
Since the coefficients are the same in both of the above equations, only one lookup table (LUT) can suffice although both lookup tables can be provided. The LUT that provides X from A and B is a given, in one instance (for a two bits per pixel input), herein above.
The left-hand side of
X=A*(3/4)+B*(1/4),
Y=C*(1/2)+B*(1/2),
Z=D*(3/4)+C*(1/4).
Since the coefficients are the same in for both the first and the third of the above equations, two lookup tables (LUTs) can suffice although all three lookup tables can be provided.
Patterns 30, 35, 40, 45 corresponding to 5:4 scaling, 5:3 scaling, 6:5 and 8:7 scaling are shown in
It should be noted that the input pixel neighborhood does not have to be identical to the predetermined pattern. Although the predetermined pattern has to be present in the input pixel neighborhood in order for the scaling algorithm to be applied, pixels in the input pixel neighborhood that are not included in the predetermined pattern will be ignored in the application of the application of the algorithm.
One embodiment of the method of this invention can also be applied to performing a “toner scatter compensation” algorithm on the scaled image. For a “toner scatter compensation” algorithm on the scaled image includes the steps of selecting a pixel neighborhood including a number of pixels in the scaled image neighboring a selected pixel, comparing the pixel neighborhood to a predetermined “toner scatter compensation” pattern and applying a “toner scatter compensation” algorithm to some of the pixels from the scaled image pixel neighborhood.
In one instance, the “toner scatter compensation” algorithm is implemented by means of a lookup table (a “toner scatter compensation” lookup table). The algorithm then includes selecting (providing) pixel data from one or more pixels in the other neighborhood from the scaled image and obtaining, from the “toner scatter compensation” lookup table data, data for a corresponding pixel in the processed scaled image.
It should be noted that, although the above described embodiment of the method of this invention applies the “toner scatter compensation” algorithm to the scaled image pixels, embodiments that apply the “toner scatter compensation” algorithm to image pixels from an arbitrary input image are also within the scope of this invention.
In one instance, in one embodiment of the method of this invention, the pixel neighborhood is first compared to a “toner scatter compensation” pattern. If the “toner scatter compensation” pattern is present in the pixel neighborhood, image data from some or all of the pixels in the pixel neighborhood is processed by applying a “toner scatter compensation” algorithm. After determining whether the “toner scatter compensation” pattern was present in the pixel neighborhood and applying the “toner scatter compensation” algorithm if the pattern was present, a scaled image is obtained by applying a predetermined scaling algorithm to some or all of the pixels from the pixel neighborhood. In some instances, the above embodiment results in lower hardware cost or faster speed.
An embodiment of the system of this invention is shown in
In one instance, the computer readable code, in applying the predetermined scaling algorithm, causes the computing component to select and provide two or more pixels from the pattern in the pixel neighborhood and obtain pixel data for a pixel in the scaled image from a lookup table using as input data for the provided two or more input pixels from the pattern in the pixel neighborhood. In some embodiments, such as, for example, the embodiments shown in
In another instance, the computer readable code is also capable of causing the computing component 110 to select a predetermined pattern. In another instance, the computer readable code is further capable of causing the computing component 110 to compare the pixel neighborhood to the predetermined pattern in order to determine whether the predetermined pattern is present in the pixel neighborhood. In one embodiment, this invention not being limited to this embodiment, the computing component 110 is an application specific integrated circuit (ASIC) and the one or more computer usable media 120 comprises a computer memory such as, but not limited to, a read only memory, ROM, or a random-access memory, RAM. In some embodiments, the one or more computer usable media 120 could be integrated in the same ASIC as the computing component 110. In another embodiment, the computing component 110 is a programmed logic array (PLA) (or a field programmable logic array (FPLA)).
In embodiments utilizing one or more lookup tables, the lookup tables could be stored in the same computer usable medium as the computer readable code or in a separate computer usable medium.
In another embodiment, the computer readable code is also capable of causing the computing component to select one pixel from the scaled image, select another pixel neighborhood including a number of pixels from the scaled image neighboring the one pixel from the scaled image and the one pixel from the scaled image, compare the another pixel neighborhood to another predetermined pattern (a “toner scatter compensation” pattern) in order to determine whether the another predetermined pattern is present in the other pixel neighborhood, and, if the another predetermined pattern is present in the another pixel neighborhood, obtain, from scaled image data for at least some pixels from the another pixel neighborhood, processed scaled image pixel data by applying a “toner scatter compensation” algorithm.
In one instance, applying the “toner scatter compensation” algorithm includes selecting (providing) pixel data from one or more pixels in the other neighborhood from the scaled image and obtaining, from a “toner scatter compensation” lookup table data, data for a corresponding pixel in the processed scaled image. It should be noted that the “toner scatter compensation” lookup table can be stored in the same computer usable medium that has the computer readable code or in a separate computer usable medium. (A lookup table can be described as being included in a data structure.)
In one exemplary embodiment, the “toner scatter compensation” pattern is given by
and the lookup table provides the following processed image pattern
can be implemented with a small (approximately a thousand entries) lookup table. (In one exemplary embodiment, the toner algorithm is applied to the bottom three rows and the input is 1 bit per pixel image.)
It should be noted that although various embodiments of the patterns and scaling algorithms, this invention is not limited to only these patterns and scaling algorithms.
It should be noted that the computing component 110, utilizing computer readable code other than that described above, can be also be used for other applications in a printing device while at the same time providing scaling and “toner scatter” artifact correction when utilized with the computer readable code of this invention. For example, although not a limitation of this invention, the computing component 110 programmed with appropriate computer readable code, can also be used for producing images from lower resolution pixel image data bases on higher resolution output devices.
Elements and components described herein may be further divided into additional components or joined together to form fewer components for performing the same functions.
Each computer program (code) within the scope of the claims below may be implemented in any programming language, such as assembly language, machine language, a high-level procedural programming language, or an object-oriented programming language. The programming language may be a compiled or interpreted programming language.
Each computer program may be implemented in a computer program product tangibly embodied in a computer-readable storage device for execution by a computer processor. Method steps of the invention may be performed by a computer processor executing a program tangibly embodied on a computer-readable medium to perform functions of the invention by operating on input and generating output.
Common forms of computer-readable or usable media include, for example, a floppy disk, a flexible disk, hard disk, magnetic tape, or any other magnetic medium, a CDROM, any other optical medium, punched cards, paper tape, any other physical medium with patterns of holes, a RAM, a PROM, and EPROM, a FLASH-EPROM, any other memory chip or cartridge, a carrier wave, or any other medium from which a computer can read.
Although the invention has been described with respect to various embodiments, it should be realized this invention is also capable of a wide variety of further and other embodiments within the spirit and scope of the appended claims.
Number | Date | Country | |
---|---|---|---|
Parent | 12730954 | Mar 2010 | US |
Child | 13399411 | US | |
Parent | 11254430 | Oct 2005 | US |
Child | 12730954 | US |