Methods for choosing and combining colors from a color palette to render an image color tone are disclosed. A set of up to four palette colors are chosen and the weighted factors for combining the chosen palette to render the image color are determined. The weighted factors of the chosen palette colors are ordered according to an ordering criterion or criteria. The color output of a display pixel is the chosen palette color associated with the interval in which the threshold value falls. color data compression may also be achieved by eliminating at least one color from the set of chosen palette colors used to render an image color that fails to exceed a specified threshold value. Also disclosed are methods for designing uniform and non-uniform color palettes.
|
1. A method for rendering an image color comprising the steps of:
selecting a set of up to four chosen palette colors such that the image color lies in a convex hull of the set of up to four chosen palette colors;
assigning weighted factors to each of the chosen palette colors, in the set of up to four chosen palette colors, such that the image color can be represented by a linear combination of the chosen palette colors in proportions given by the weighted factors;
ordering the chosen palette colors, in the set of up to four chosen palette colors, according to an ordering criteria; and
outputting the chosen palette color, from the set of up to four chosen palette colors, that corresponds to the weighted factor that when added to the other weighted factors according the ordering criteria contains or equals a threshold value in a dither matrix.
9. A method for compressing the data representing a image color comprising the steps of:
selecting a set of up to four chosen palette colors such that the image color lies in a convex hull of the set of up to four chosen palette colors;
assigning weighted factors to each of the chosen palette colors, in the set of up to four chosen palette colors, such that the image color can be represented by a linear combination of the chosen palette colors in proportions given by the weighted factors;
identifying a chosen palette color from the set of up to four chosen palette colors to remove from the set of up to four chosen palette colors by comparing at least one weighted factor to a threshold value;
calculating redistributed weighted factors by redistributing the weighted factor of the chosen palette color removed from the set of up to four chosen palette colors to the remaining chosen palette colors in the set of up to four chosen palette colors; and
representing the image color as the linear combination of the remaining chosen palette colors in proportions given by redistributed weighted factors.
2. The method
3. The method of
responsive to two or more of the chosen palette colors, from the set of up to four chosen palette colors, possessing the same first color parameter value, ordering the chosen palette colors, in the set of up to four chosen palette colors, according to at least one additional parameter.
4. The method of
5. The method of
6. The method of
7. The method of
8. A computer readable medium comprising a set of instructions for performing the method of
10. The method of
11. The method of
12. The method of
13. The method of
14. The method of
15. A computer readable medium comprising a set of instructions for performing the method of
|
1. Field of the Invention
The present invention relates generally to the field of imaging processing, and more particularly to rendering color images.
2. Background of the Invention
Display devices, such as printers, cathode ray tubes (CRT), plasma screens, liquid-crystal displays (LCD), and the like render images using small spots, referred to as “picture elements” or “pixels.” At times, an image with a broader range of colors than the device's limited number of basic colors may need to be rendered by the device. Increased color depth may be obtained at the expense of spatial resolution by adding colored noise to the displayed pixels and relying on the human visual system to filter out the noise and perceive a wider range of colors.
One method for creating the appearance of new colors and shades is called “dithering.” Although a number of dithering methods exist, dithering generally involves comparing image pixels values with respective threshold values of a dithering matrix. A dithering matrix, which consists of an array of threshold values, is conceptually overlaid onto the image pixel array. Each of the image pixels is processed by comparing its tonal value to the associated dither matrix value. The output value, i.e., the rendered image or display pixel value, is generated based on the comparison. For example, if the display supports only binary output, the input image pixels may be mapped to output pixels as follows. If the image value equals or exceeds the dither matrix threshold value, the output pixel is illuminated or receives an ink dot (depending on whether the display device is a screen or a printer). Otherwise, it is not illuminated or does not receive an ink dot. Note that if the dither matrix is smaller than the image array, the dither array is tiled (i.e., repeated side-by-side) over the image array in order to cover the entire image array. The described binary dither can be extended to multi-level dither schemes for devices that support multiple output levels at each pixel location.
Although dithering can be an effective method for trading off spatial resolution to improve perceived color depth, there are limits to its use. For example, multi-level dithering for low and medium resolution devices poses problems since the dither noise may easily become unacceptably visible due to insufficient spatial resolution. Furthermore, a direct extension of monochrome multi-level dither techniques to multiple color channels can result in higher noise and visual artifacts arising from dithering between too many palette colors to render a target color and from interference effects between the different or same dither matrices used to dither the different color channels.
Because most color dithering techniques involve dithering each device color coordinate independently, if a display device has n device color coordinates (e.g., for a Red-Green-Blue (RGB) display, n=3, for a Cyan-Magenta-Yellow-Black (CMYK) display, n=4), dithering each device color coordinate independently, by direct extension of monochrome dithering methods, results in using linear combinations of up to 2n palette colors. And, these colors are constrained to be the outer product of the colors along each device color axis, which results in much reduced freedom for choosing the colors that comprise the palette. While increasing the number of colors in a palette reduces dither noise, dithering between a large number of colors from a small color palette, particularly in a low or medium resolution device, typically results in increased perceived noise in the dithered image. Furthermore, since there is limited freedom in choosing the colors that form the palette (since each channel is independently dithered), perpetually significant regions, such as, for example, face tones, cannot be given more bits for smoother representation without significantly sacrificing color quality in other regions of the color gamut.
Accordingly, what is needed are low-noise dithering methods, particularly low-noise dithering methods for use with displays with spatial resolution limits or with color palettes that contain a number of pre-allocated colors.
According to one aspect of the present invention, systems and methods for choosing and combining colors from a color palette to render a color tone are disclosed. In an embodiment, an image color may be rendered by selecting a set of up to four chosen palette colors such that the image color lies in a convex hull of the set of up to four chosen palette colors. The four chosen palette colors are assigned weighted factors such that the image color may be represented by a linear combination of the chosen palette colors in proportions given by the weighted factors. The weighted factors of the chosen palette colors are ordered according to an ordering criterion or criteria. The chosen palette color outputted to a particular display location is the chosen palette color that corresponds to the weighted factor that when added to the other weighted factors according the ordering criteria contains or equals the threshold value as indicated by a dither matrix. That is, the color output of a display pixel is the chosen palette color associated with the interval in which the dither matrix threshold value falls.
According to another aspect of the present invention, systems and methods are disclosed for performing color data compression. In an embodiment, color data compression may also be achieved by eliminating at least one color from the set of chosen palette colors used to render an image color that fails to exceed a specified threshold value.
According to another aspect of the present invention, systems and methods are disclosed for designing a color palette. In an embodiment, a color palette for a device may be designed by defining an acceptable noise level, which may be specified as the maximum allowable distance between a palette color and any color to be rendered. Measurements are collected by uniformly sampling the device color gamut over the device coordinates. Delaunay tetrahedrons of the measurements are constructed, and measurements are iteratively added or deleted to satisfy the acceptable noise level requirement or requirements and to reduce the number of colors in the color palette as determined by a bit budget of a dither.
In an embodiment, the maximum acceptable noise limit may be uniform across the entire color gamut. Alternatively, the maximum acceptable noise limit may vary depending upon the region of color space.
Although the features and advantages of the invention are generally described in this summary section and the following detailed description section in the context of embodiments, it shall be understood that the scope of the invention should not be limited to these particular embodiments. Many additional features and advantages will be apparent to one of ordinary skill in the art in view of the drawings, specification, and claims hereof.
Reference will be made to embodiments of the invention, examples of which may be illustrated in the accompanying figures. These figures are intended to be illustrative, not limiting. Although the invention is generally described in the context of these embodiments, it should be understood that it is not intended to limit the scope of the invention to these particular embodiments.
FIG. (“FIG.”) 1 depicts a method for dithering an image color according to an embodiment of the present invention.
In the following description, for purposes of explanation, specific details are set forth in order to provide an understanding of the invention. It will be apparent, however, to one skilled in the art that the invention can be practiced without these details. One skilled in the art will recognize that embodiments of the present invention, described below, may be performed in a variety of ways and using a variety of means. Those skilled in the art will also recognize additional modifications, applications, and embodiments are within the scope thereof, as are additional fields in which the invention may provide utility. Accordingly, the embodiments described below are illustrative of specific embodiments of the invention and are meant to avoid obscuring the invention.
Reference in the specification to “one embodiment” or “an embodiment” means that a particular feature, structure, characteristic, or function described in connection with the embodiment is included in at least one embodiment of the invention. Furthermore, the appearance of the phrase “in one embodiment,” “in an embodiment,” or the like in various places in the specification are not necessarily all referring to the same embodiment.
1. Generalized Theory for Dithering
The following section sets forth a general theory for dithering independent of the number of color channels used to render a color on the device display. Following this section is a section providing an example to further clarify the present invention and to present alternate embodiments. It should be noted that the examples and embodiments provided herein are for purposes of illustration and shall not be construed to limit the scope of the present invention.
The chosen palette colors in Nbd(c) are ordered 104 according to ordering criteria. The ordering criteria may comprise one or more parameters by which the chosen palette colors may be ordered. In an embodiment, the criteria for ordering the chosen palette colors may be based upon visual sensitivity or perception. The visual sensitivity may depend upon a number of factors, including, but not limited to, the type of display (e.g., whether the display device is additive or subtractive), background color, lightness or luminance, hue, saturation, and the like. In one embodiment, the chosen palette colors are first ordered according to luminance, and if any of the chosen palette colors have equal luminance, those colors may be ordered by saturation, hue, or both. The ordered set of chosen palette colors may be denoted:
{ci: ∈Nbd(c)}
Each of the chosen palette colors in the set of up to four chosen palette colors are assigned 106 weighted factors to render the image color as a linear combination of the chosen palette colors in proportions given by the weighted factors. Since the image color to be rendered lies in the convex hull of the chosen palette colors in Nbd(c), the image color, c, can be represented as a linear combination of these colors. In an embodiment, the linear combination may be obtained by locating in the color space the tetrahedron enclosing the image color and by finding the barycentric coefficients used to express the image color as a linear combination of the tetrahedron's vertices. These barycentric coefficients, bi, represent the proportional amounts of chosen palette colors used to reproduce the image color:
c=ΣNbd(c)bici, where, bi∈[0,1] and Σibi=1
That is, the image color, c, can be rendered by mixing the chosen palette colors, ci, in the proportions given by their weighted factors, bi. One skilled in the art will also recognize that the ranking and ordering of the chosen palette colors may be configured differently depending upon the display conditions, including whether the display is an additive or a subtractive display. Furthermore, one skilled in the art will recognize that certain of the steps illustrated herein may be performed in different orders. For example, the weighted factors may be obtained prior to ordering of the colors.
Having determined and ordered the weighted factors of the chosen palette colors, a single dither matrix may be used to mix the chosen palette colors in the proper proportions. It should be noted that the present invention may be used with dither matrices of various sizes, orientations, and desired pixel or color growth patterns.
The output color for a particular pixel may be obtained as follows. If rmn denotes the rank of the pixel location (m, n) as determined by the dither matrix, and if M and N denote the number of rows and columns of the dither matrix, the ratio, dmn=rmn/(MN), represents the threshold value for that rank and it lies in the range [0,1]. Let
denote the partial sum of the first k weights corresponding to the ordered set of colors belonging to Nbd(c). If {circumflex over (k)} is the smallest value for k for which S
To illustrate further, assume for the purposes of illustration that the ordered chosen palette colors are c1, c2, c3, and c4, being ordered from most significant to least significant color according to the ordering criteria and that the weighted factors for the ordered set of chosen palette colors are respectively, b1, b2, b3, and b4. The color outputted by the dither matrix may be determined according to the following:
c1, where dmn≦b1;
c2, where b1<dmn≦(b1+b2);
c3, where (b1+b2)<dmn≦(b1+b2+b3); and
c4, where (b1+b2+b3)<dmn≦1.
It should be noted that the present invention provides a number of benefits. First, noise is reduced by minimizing the set of colors used to render any given color. That is, the reduced color set is optimal in the sense that no fewer colors from the color palette can be used to render the color with lower noise. Second, because the present invention may use a single dither matrix, it eliminates the problem of dither interference artifacts across multiple color channels. Furthermore, because the present invention may use a single dither matrix, it eliminates the problem of designing separate dither matrices for each color channel to minimize cross-channel dither interference artifacts. In addition, the present invention is amenable to fast implementations, whether implemented in software, hardware, firmware, or any combination thereof. Because embodiments of the present inventions employ a single dither matrix and because dithering involves a simple comparison between the dither matrix threshold values and the ordered weighted factors, the computation resources required to process an image are not substantial. Finally, it should be noted that because chosen palette colors are ordered according to an ordering criterion or criteria, such as lightness, the most critical chosen colors receive the best ranked location. Since the most important chosen colors receive the best rank locations, the present invention promotes visually pleasing renderings.
2. Illustration of the Generalized Theory
The foregoing discussion illustrated embodiments of the present invention in general terms. To aid understanding and to illustrate additional aspects and embodiments of the present invention, a method for rendering an image color according to an embodiment of the present invention is depicted in
In the embodiment, a set of up to four chosen palette colors may be obtained by computing 202 a Delaunay tetrahedralization of the palette colors in Lab space. One skilled in the art will recognize that other color spaces may be used.
Having obtained the set of up to four chosen palette colors, the weighted factors for the chosen palette colors may be obtained. The color to be rendered is located 204 within a tetrahedral volume, face, edge, or vertex, and the barycentric coordinates, bi, of the image color, c 300, are computed 206 within the containing tetrahedron. The image color to be rendered, c 300, may then be mathematically depicted as the linear sum of the chosen palette colors multiplied by their respective weighted factors:
Assume for the sake of illustration that b1=⅛, b2= 5/16, b3= 5/16, and b4=¼. Note that the weighted factors have been chosen to simplify the illustration. Having obtained the weighted factors, the chosen palette colors are ordered 208 according to ordering criteria or criterion. In an embodiment, the criteria for ordering the chosen palette colors may be based upon visual sensitivity. In one embodiment, the chosen palette colors are ordered according to lightness and if any of the chosen palette colors have equal lightness, they are ordered by at least one additional parameter, such as, saturation, hue, or both saturation and hue. Assume, for the purposes of the present example, that the chosen palette colors are ordered c3, c4, c1, and c2, ranging from the most visually sensitive to the least visually sensitive.
Turning to
3. Color Compression
Embodiments of the present may include methods for compressing the color data.
Having obtained the chosen palette colors, ci, and their respective weighted factors, bi, the set of up to 4 chosen palette colors may be reduced 906 by at least one chosen palette color. In one embodiment, if a weighted factor falls below a threshold value, the chosen color associated with that weighted factor may be eliminated from the set of chosen colors. In an alternate embodiment, one or more chosen palette colors may be eliminated based upon their weighted factors. In yet another embodiment, if a color or colors exceed a certain threshold value, the set of chosen palette colors may be reduced by eliminating the other chosen palette colors that do not exceed the threshold value.
With one or more chosen colors eliminated, the eliminated color's or colors' weighted factors may be redistributed 908 to the remaining chosen palette color or colors. In one embodiment, the weighted factor or factors are redistributed in proportion to the remaining chosen colors original weighted factors. The color to be rendered may be represented as the linear combination of the remaining chosen palette color or colors multiplied by its redistributed weighted factor. Having reduced the color set, the color data for rendering the color is also reduced or compressed.
By way of illustration, consider the following two examples. For both examples, assume that four colors, c1-c4, were identified and that the weighted factors are b1-b4, respectively.
Assume for the purpose of this first example that b3 falls below a specified minimum threshold level. To compress the color data, b3 is set to zero, and its weighted factor is redistributed to the remaining chosen colors according to the following:
b1
b2
b4
Accordingly, the color to be rendered may now be represented by the reduced set of information:
c=b1
Assume for the purpose of the second example that b3 is above a specified maximum threshold level. That means, that the color to be rendered is very near the color associated with b3, namely c3. Accordingly, to compress the color data, b1, b2, and b4 are set to zero, and the weighted factor, b3, for the remaining chosen color's, c3, is set to 100%. Accordingly, the image color to be rendered may now be represented by the reduced set of information:
c=c3.
The present invention is not limited to the foregoing examples. One skilled in the art will recognize that other methods for reducing the set of up to four chosen palette colors are within the scope of the present invention. One skilled in the art will also recognize that the data compression methods described in this section may be used to process, transmit, store, and/or render color data.
4. Color Palette Design
The previous sections described the methods for choosing and combining colors chosen from a color palette to render a given color tone. This section sets forth a further aspect of the present invention, namely methods for constructing color good palettes. The present invention provides greater flexibility in the design of color palettes, including custom allocation of bits to different regions of the color gamut.
Alternatively, the maximum allowable distance between a palette color and a color to be rendered may vary depending upon the region of color space. That is, the maximum allowable distance may be smaller near colors representing certain colors, such as, for example, skin tones.
Returning to
The methods described above may be simplified if a three-dimensional color space, for example, RGB color space, is used. In an embodiment, a reasonable palette may be constructed without performing Lab measurements. Instead, the steps described above may be performed directly in the device color space. In another embodiment, a uniformly sampled color palette that yields a uniform Delaunay tetrahedralization with periodic structure may be used to provide significant implementation simplification; however, this embodiment may result in reduced color quality compared to the more general methods described previously.
It should be noted that the present invention is particularly suitable for applications where a large number of device palette colors have already been pre-allocated, for example, to provide accurate reproduction of important colors. Because a number of colors have already been allocated, the freedom to choose the color palette to optimize color error is severely curtailed. In such cases, using the above described methods for low-noise dither generation provides the most pleasing dither for color encoding.
One skilled in the art will recognize that the present invention may be utilized in any number of devices, including but not limited to, computers, printers, displays, monitors, mobile phones, personal data assistants (PDAs), and the like. It should also be noted that the present invention may also be implemented by a program of instructions that can be in the form of software, hardware, firmware, or a combination thereof. In the form of software, the program of instructions may be embodied on a computer readable medium that may be any suitable medium (e.g., device memory) for carrying such instructions including an electromagnetic carrier wave.
While the invention is susceptible to various modifications and alternative forms, a specific example thereof has been shown in the drawings and is herein described in detail. It should be understood, however, that the invention is not to be limited to the particular form disclosed, but to the contrary, the invention is to cover all modifications, equivalents, and alternatives falling within the spirit and scope of the appended claims.
Patent | Priority | Assignee | Title |
10270939, | May 24 2016 | E Ink Corporation | Method for rendering color images |
10467984, | Mar 06 2017 | E Ink Corporation | Method for rendering color images |
10554854, | May 24 2016 | E Ink Corporation | Method for rendering color images |
10771652, | May 24 2016 | E Ink Corporation | Method for rendering color images |
11087644, | Aug 19 2015 | E Ink Corporation | Displays intended for use in architectural applications |
11094288, | Mar 06 2017 | E Ink Corporation | Method and apparatus for rendering color images |
11265443, | May 24 2016 | E Ink Corporation | System for rendering color images |
11527216, | Mar 06 2017 | E Ink Corporation | Method for rendering color images |
7580044, | Nov 03 2004 | Realtek Semiconductor Corp.; Realtek Semiconductor Corp | Method and apparatus for non-linear dithering of images |
8189010, | Dec 16 2008 | KONICA MINOLTA LABORATORY U S A , INC | Systems and methods for color gamut mapping |
9811923, | Sep 24 2015 | SNAPTRACK, INC | Stochastic temporal dithering for color display devices |
Patent | Priority | Assignee | Title |
5732205, | Dec 30 1994 | Intel Corporation | Color conversion using 4.5 bit palette |
6304333, | Aug 19 1998 | HEWLETT-PACKARD DEVELOPMENT COMPANY, L P | Apparatus and method of performing dithering in a simplex in color space |
6496186, | Feb 17 1998 | Oracle America, Inc | Graphics system having a super-sampled sample buffer with generation of output pixels using selective adjustment of filtering for reduced artifacts |
6606166, | Apr 30 1999 | Adobe Inc | Pattern dithering |
6711299, | Mar 11 1997 | UPLOAD TECHNOLOGIES, S A | Wavelet transformation of dithered quantized/reduced color pixels for color bit depth image compression and decompression |
6819793, | Jun 30 2000 | Intel Corporation | Color distribution for texture and image compression |
20030059108, | |||
20040071351, | |||
20050179915, |
Executed on | Assignor | Assignee | Conveyance | Frame | Reel | Doc |
May 09 2005 | EPSON RESEARCH AND DEVELOPMENT, INC | Seiko Epson Corporation | ASSIGNMENT OF ASSIGNORS INTEREST SEE DOCUMENT FOR DETAILS | 016752 | /0360 | |
Jul 07 2005 | BHATTACHARJYA, ANOOP K | EPSON RESEARCH AND DEVELOPMENT, INC | ASSIGNMENT OF ASSIGNORS INTEREST SEE DOCUMENT FOR DETAILS | 016773 | /0341 | |
Jul 08 2005 | Seiko Epson Corporation | (assignment on the face of the patent) | / |
Date | Maintenance Fee Events |
Aug 31 2009 | ASPN: Payor Number Assigned. |
Jul 13 2011 | M1551: Payment of Maintenance Fee, 4th Year, Large Entity. |
Sep 25 2015 | REM: Maintenance Fee Reminder Mailed. |
Feb 12 2016 | EXP: Patent Expired for Failure to Pay Maintenance Fees. |
Date | Maintenance Schedule |
Feb 12 2011 | 4 years fee payment window open |
Aug 12 2011 | 6 months grace period start (w surcharge) |
Feb 12 2012 | patent expiry (for year 4) |
Feb 12 2014 | 2 years to revive unintentionally abandoned end. (for year 4) |
Feb 12 2015 | 8 years fee payment window open |
Aug 12 2015 | 6 months grace period start (w surcharge) |
Feb 12 2016 | patent expiry (for year 8) |
Feb 12 2018 | 2 years to revive unintentionally abandoned end. (for year 8) |
Feb 12 2019 | 12 years fee payment window open |
Aug 12 2019 | 6 months grace period start (w surcharge) |
Feb 12 2020 | patent expiry (for year 12) |
Feb 12 2022 | 2 years to revive unintentionally abandoned end. (for year 12) |