Color2Hatch: conversion of color to hatching for low-cost printing

In this paper, we propose Color2Hatch, a decolorization method for business/presentation graphics. In Color2Hatch, each region represented as a closed path and uniformly colored in scalable vector graphics (SVG) is converted to a region hatched in black and white. From the characteristics of business graphics, the hatching patterns are designed to represent mainly the hue in the region; additionally, lightness and saturation can also be reflected. To discriminate subtle differences between colors, attached short line segments, zigzag lines, and wave lines are used in hatching by analogy to a clock. Compared with the existing decolorization methods, for example, grayscale conversion and texturing, our method is superior in the discrimination of regions, suitable for low-cost black and white printing that meets real-world needs.


Introduction
Printing on paper remains an important medium for communication despite the recent development of electronic devices; for example, smartphones and tablets, and even now, printing in black and white (B/W) are widely used. To include color figures and graphs in B/W printing, they should be converted to black and white.
A standard method for B/W conversion is color-to-grayscale conversion via a lightness channel. However, with this standard method, chromatic information is entirely ignored, and thus, information in the original figures/graphs is often lost.
To make the B/W conversion more robust and usable even for low-quality printing, this study focuses on hatching, a technique of drawing parallel lines in close proximity to represent shading effects.
In this paper, we propose a conversion method from color in scalable vector graphics (SVG) figures to new extended hatching, representing color differences very well. While conventional hatching with parallel straight lines is inadequate for a variety of colors, our extended hatching with, e.g., lightning-like zigzag lines, can represent the differences in the original color even if the original tone is mostly lost. This paper is organized as follows: Sect. 2 overviews the background of the study with related research. Section 3 provides an overview of the proposed approach. Section 4 elaborates on our approach and introduces some variations in our approach. The experiments are presented in Sect. 5, and Sect. 6 discusses the printing cost savings compared with existing methods, the limitations of our method, its applications, and its relation to visualization. Finally, Sect. 7 concludes the paper with some comments on future work.

Background and related work
To display color images on monochrome devices, the images are conventionally converted to grayscale images by lightness. For example, in ITU-R Recommendation BT.601, 1 3 YUV (typical YUV), luma (gamma-corrected luminance) Y' is given by: where R′, G′, and B′ are the red, green, and blue signals.
However, with this standard method, chromatic information is entirely ignored, and thus, colors of similar lightness are indistinguishable even if their hues are distinguishable.
To preserve or enhance contrasts between colors of similar lightness, many authors have proposed decolorization methods. Bala and Braun [1] assigned distinct gray values to colors in business graphics. Gooch et al. [2] optimized the modulation of source lightness differences to reflect the gap in chrominance. Rasche et al. [3] extended the decolorization problem to reduce the gamut dimensions for colordeficient viewers. Grundenland and Dedgson [4] improved decolorization efficiency. Smith et al. [5] and Kuhn et al. [6] proposed other fast conversion methods. According to Gestalt principles, Wu et al. [7] decomposed the input image into soft segments, and Ji et al. [8] considered the boundary instead of segmentation. Cui et al. [9] used ISOMAP, a nonlinear dimensionality reduction method, and Zhu et al. [10] applied Broadbent's filter model of attention to the color-togray conversion. Recently, efficiency and contrast preserving properties have been improved (e.g., [11][12][13][14]).
Another approach for color-to-monochrome conversion is texturing. Roetling encoded eight basic colors as textures from unique RGB texture patterns for B/W dot printing [15]. Harrington mapped colors to visible B/W textures, where similar colors were mapped to similar textures [16,17], and Bai et al. [18] improved the texture patterns. Queiroz and Braun [19] proposed a reversible method in which colors are mapped to gray textures and the color information is recovered from the texture. Guss used distinct line directions for RGB and represented colors using B/W textures [20].
In our view, neither of the above two approaches, grayscale conversion and texturing, are in practical use, particularly for low-cost B/W printing. Both these approaches rely on high-quality printing, where shading representation and pixel-by-pixel on/off should be accurate. These properties are not expected for conventional B/W printing.
There are two types of color images: pictorial images and business/presentation graphics images [17]. This study focuses on the latter, and we assume that each region in the image is uniformly colored. In color business graphics, hue plays a major role in discriminating regions, compared with lightness and saturation. Even if the image is converted to B/W, each colored area should be identifiable, as in color. The existing methods of grayscale conversion and texturing are inappropriate for this purpose.
We then focus on hatching. Hatching is an artistic technique for drawing closely spaced parallel lines. It is visually clear and superior in discriminating between regions. Existing hatching techniques in graphics community mainly reflect shapes, contours, shading, etc. (e.g., [21][22][23]). In technical drawings, the material of a part is indicated by hatching [24]. To the best of our knowledge, conversion from color to hatching has not yet been proposed. As discussed above, hue is most critical in color business/ presentation graphics and can be mapped to the direction of hatching lines (Fig. 1). If the difference between the hues of the two regions is large, discrimination is easy. For similar colors, however, the direction of the hatching lines is not sufficient for discriminating many regions.
In this study, we propose a conversion method from color to hatching, where even regions of similar colors are identifiable.

Overview
To improve the discriminability between hatching patterns from similar colors (hues), we focused on clocks (timepieces). Analog clocks display time according to the directions of their hands in 12 h. If they have only a single hand, the displayed time is ambiguous. Clocks usually have two hands: long (minute) hand and short (hour) hand, and the pair of hands enables us to identify time accurately in 12 h. This analogy can be applied to hatching.
We supposed that input images were in SVG format [25], where each region, for example a country in a world map or a slice in a pie chart, is represented as a closed path and colored uniformly. We then filled each region with a hatching pattern corresponding to its original color.
As discussed in the previous section, the hue of a region can be represented by the direction of the hatching lines (Fig. 2b). However, it is inappropriate for discriminating similar hues, such as a single-hand clock.
By analogy to a clock, attaching short line segments to hatching lines greatly improves the discriminability between similarly colored regions (Fig. 2c). By modifying

Methods
The color of each region is first converted to a triplet of hue, saturation, and lightness. By default, we used CIELAB, and the hue (angle) and saturation/chroma were obtained using the cylindrical model. Other color models, such as HSV and HSL, can also be applied.
Each region (interior of the closed path) was tiled with a tilted hatching pattern. The hatching pattern and its tilt (rotation) angle were obtained from the hue of the region, as described below.

Simple hatching pattern
In this study, a hatching pattern is a rectangle whose topleft corner is the origin of the coordinate system, and the bottom-right corner is W hatch , H hatch . In our simple hatching pattern, a straight line was drawn vertically in the center to prevent overlapping with the border of the pattern (Fig. 3). W hatch is determined by lightness if hatching reflects the lightness of the region color, as discussed in Subsection 4.6. H hatch is typically equal to W hatch .

Pattern angle
The above hatching pattern was rotated and laid over the region to represent the hue of the source color of the region. The simple hatching pattern rotated by 180° is the same as the original pattern, and then, our pattern rotation angle pattern is given by where Hue is the hue angle of the source color ( 0 ≤ Hue < 360 ). Figure 1 shows a pair of sample color pie charts and their simple hatching images.

Segment attached hatching
As discussed in Sect. 2, simple hatching is weak in discriminating between regions of similar colors in the source image. By analogy to a clock, we attach short line segments to a simple hatching pattern (Fig. 4). The pattern angle, corresponding to the direction of (parallel) lines, roughly represents the hue, and the angle between the line and the attached segment, short , shows subtle differences between hues. In other words, pattern and short correspond to the hour and minute hands in a clock, respectively.
The short segment angle short is given by pattern = Hue 2 OE is a period of short , which is determined so that the directions of the main hatching lines can be discriminated between and + OE , and ⌊x⌋ is a floor of x . In a clock, OE corresponds to 30° (angle for an hour) of the hour hand. Figure 2c shows the segment attached to the hatching of the colored region in Fig. 2a.

Zigzag hatching
Modifying the geometry in the above hatching pattern yielded some variational hatching patterns. In zigzag hatching (Fig. 2d), zigzag lines replace straight lines in simple hatching to clarify subtle differences between similar colors.
Let l long and l short be lengths of segments where l short < l long , and the short segment angle short is the same as The zigzag angle zigzag is then given by Two segments of lengths l long and l short form an included angle zigzag , as shown in Fig. 5. From the law of cosines, the height of the Zigzag hatching pattern H zigzag is given by The width of the pattern W zigzag is determined by lightness if the hatching is reflected by the lightness of the region color, as discussed in Subsection 4.6.
Note that the intersection point of the two segments is placed on the left side if 0 ≤ short < 90 (Fig. 5a), and on the right if 90 ≤ short < 180 (Fig. 5b).

Wave hatching
Smoothly connecting the endpoints of the two segments in zigzag hatching yields wave hatching (Fig. 2e). Suppose that the intersection point (and also the endpoints) of the two segments in zigzag hatching is x 2 , y 2 , and the other endpoints of the short and long segments are x 1 , y 1 and x 3 , y 3 , respectively (see Fig. 5). Then, we draw two cubic Bézier curves. One has four control points: x 1 , y 1 , x 1 , y 2 , x 2 , y 1 , and x 2 , y 2 , and the control points of the other are x 2 , y 2 , x 2 , 2y 2 , x 3 , y 3 − y 2 , and x 3 , y 3 (Fig. 6).
Similar to zigzag hatching, the curves are drawn on the left side if 0 ≤ short < 90 (Fig. 6a), and on the right if 90 ≤ short < 180 (Fig. 6b).

Mapping lightness to intervals between lines
The representation of hue has been discussed thus far in this section, and this subsection focuses on lightness. From our hatching mechanism, where rectangular hatching patterns are laid over regions, lightness is controlled by the interval between hatching lines, and the interval is equal to the width of the hatching pattern W hatch . Any positive monotonically increasing function can be mapped from the lightness value of a region to its W hatch . We then use where W min is the minimum interval between hatching lines such that the hatching direction is identifiable, L′ is the lightness normalized to 0 ≤ L ′ ≤ 1 , and p is an arbitrary parameter. Figure 7 compares a sample pie chart composed of slices of similar hue and different lightness values and its simple hatching result.

Mapping saturation to dashed lines
If required, the proposed method represents saturation via dashed lines. From the saturation S′, normalized to 0 ≤ S ′ ≤ 1 , the lengths of the stroke and the break are where the base length L base is usually used as W hatch . Figure 8 compares a sample pie chart composed of slices of different saturations and its simple hatching result.

Results
We implemented a color-to-hatching conversion system. Figure 2 illustrates the hatching patterns with a source color. Figure 9 shows how our hatching clarifies the differences  Figures 11 and 12 compare our hatching and Color-2Gray [2] results converted from a map of subprefectures on Hokkaido Island in Japan (Fig. 10).
To mimic a low-cost B/W printing process, the images in Figs. 11 and 12 were printed on a laser printer (Canon LBP7200CN), photocopied by an electrostatic copier (Xerox ApeosPort-IV 4471) and then scanned (Canon CanoScan LiDE 400) (Fig. 13). In Fig. 14, a stencil printer (Riso Kagaku Risograph RZ770) replaces the copier. The features of hatching survive, and the regions are still discriminable even in low-cost B/W printing.
From these results, Color2Hatch can clarify subtle differences in the color of regions compared with the existing methods, as discussed in Sect. 2. In addition, the results of the proposed method do not appear dark; in other words, they consume much less ink/toner in printing. This reduces the printing cost, as discussed in the next section.

Printing cost savings
In this section, we compare the printing costs of our method with those of existing printing methods. Both mass printing and small quantity printing with PC printers are discussed below.

Mass printing
A printing price list for estimation is the price of mass printing, by a printing company. The printing price 1 is proportional to the number of color inks in both sheet-fed printing and rotary printing, and color materials are usually printed with four types of ink (C(cyan), M(magenta), Y(yellow), and K(black)) [26]. If color images are translated to our hatched representation, the printing cost is reduced by one-fourth.

Small quantity printing
We often use PC printers such as laser or inkjet printers for small quantity printing, and most of the printing cost of these printers is that of toners and inks.
Laser printers. A laser printer prints an image by transferring and fixing the toner (powdered ink) to a paper, and four types of toners (CMYK) are used in color laser printers. Although accurately predicting toner usage is an ongoing research problem [27], we make a simple estimation of toner usage based on its area coverage. The color shades are represented by the quantity of the toner fixed on a paper, and the relation between the area coverage of the toner and lightness is represented by a tone reproduction curve. In our estimation, from the real tone reproduction curve of a color laser printer [28], we model a simple tone reproduction curve, as shown below (Fig. 13): where c is the area coverage of the toner ( 0 ≤ c ≤ 100 ), and L * is the lightness ( 0 ≤ L * ≤ 100).
To map an RGB color to the quantity of the four types of toner, we first convert RGB to CMYK. Although the current color printing devices/drivers usually use 3D LUT for RGB-CMYK conversion, our estimation uses a simple conversion method, which was used in early color printers [29]. The conversion method from (R, G, B) is ( 0 ≤ R, G, B ≤ 255): Step 1. C 1 , M 1 , and Y 1 are obtained as.
Step 2. K is obtained as.
Step 3. C 2 , M 2 , and Y 2 are obtained as.
The resultant C 2 , M 2 , Y 2 , K is then used to obtain the toner quantities matching the toner reproduction curve. Table 1 compares the quantity of the toner in color printing, grayscale printing, and our hatching for a few sample colors. 2 We suppose that our hatching uses segment-attached hatching, where the length of the short segments is half of W hatch (and H hatch ), the width of the long/short segments is one-tenth that of W hatch , the long/short segments are in pure black, and lightness and saturation are not considered in hatching. As presented in Table 1, except for light colors (e.g., yellow), our hatching method consumes much less toner than color printing and grayscale printing, even if the price difference between black (K) toner and color (cyan, magenta and yellow (CMY)) toners is not taken into consideration.
Inkjet printers. An inkjet printer prints an image by propelling droplets of ink onto paper, and four types of ink (cyan, magenta, yellow and black (CMYK)) are used in typical color inkjet printers. 3 Similar to laser printers, the shades of colors are represented by the quantity of ink on a paper, and it is controlled by halftoning, for example, Bayer dithering or error-diffusion methods. Assuming the ink has a tone reproduction curve similar to that shown in Fig. 15, the estimation in Table 1 is valid for inkjet printers, and our hatching method has a cost advantage.
Note that the above estimations of toner/ink consumption are based on simple assumptions and ignore many factors in the real world, for example the order of toners/inks, the overlapping of dots, dot gain, etc.

Limitations
In our current method, there is still much room for improvement. As shown in Figs. 10,11,12, to identify the color (or its corresponding hatching) of a region, each region should be considerably larger in our method.
One of the problems lies in the design of the shape of zigzag hatching and wave hatching. In the current design, a discontinuity exists when short = 90 . This may result in two different shapes from the same color because of, for example, round-off errors.
Another problem is the lack of representation of achromatic colors. A simple solution is to convert achromatic colors (colors whose saturation is below a threshold) to another type of hatching, for example cross-hatching.

Applications
Many printers have a B/W button, and/or their driver windows have a toggle switch between color printing and B/W printing. They enable us to print color documents instantly in grayscale. Their printer output, however, is in conventional grayscale and has the problem discussed in Sect. 2.
If a printer receives page description language commands and also has our Color2Hatch functions in its firmware, pages with uniformly colored regions can be properly hatched in B/W printing. For example, in a page described by Postscript [31], regions surrounded by a closed path are hatched instead of being filled with a color. This is an extended/enforced version of the existing B/W button and achieves better discriminability and toner saving.
Our Color2Hatch can be applied to electronic and conventional papers. Compared to liquid crystal displays, electronic papers are superior in terms of high readability and low power consumption. To achieve high readability, however, many electronic paper devices are monochrome, and their users have difficulty reading color materials. If an electronic paper device has Color2Hatch functions, it can  convert color materials to hatched representations in B/W. This will improve the availability and usefulness of electronic paper devices.

Relation to visualization
Our method is related to glyph-based visualization [32]. As shown in Fig. 11, the segment attached hatching integrated with dashed lines appears to be an iconographic display of multidimensional data [33]. This is reasonable considering that color is a kind of multidimensional data. Based on hatching, however, our alignment of icons/glyphs is regular and appropriate for representing the uniform color of each region.

Conclusions
We proposed a novel decolorization method for color business graphics in vector format. Unlike the existing grayscale conversion and texturing methods, our Color2Hatch method is visually clear, provides greater distinguishability, and meets real-world needs even for low-cost printing. Our approach to robust conversion from color to hatching will be useful for saving the printing costs associated with preparation and setup.
One interesting problem is to match the difference (distance) of the two colors and their corresponding hatching from a cognitive perspective. Future work will be applied to non-uniformly colored regions.
We hope that document processors and/or printing systems in the future can instantly prepare B/W printing data from color documents.

Conflict of interest
The authors have no conflicts of interest to declare relevant to the contents of this article.
Open Access This article is licensed under a Creative Commons Attribution 4.0 International License, which permits use, sharing, adaptation, distribution and reproduction in any medium or format, as long as you give appropriate credit to the original author(s) and the source, provide a link to the Creative Commons licence, and indicate if changes were made. The images or other third party material in this article are included in the article's Creative Commons licence, unless indicated otherwise in a credit line to the material. If material is not included in the article's Creative Commons licence and your intended use is not permitted by statutory regulation or exceeds the permitted use, you will need to obtain permission directly from the copyright holder. To view a copy of this licence, visit http:// creat iveco mmons. org/ licen ses/ by/4. 0/.