Abstract
This paper introduces novel methods to improve the aesthetic appearance of rendered grayscale digital images on woven fabric by smoothly changing tones and improving the reproducibility of fine details. The methods are based on stepping dithering, a recently developed dithering method for automatically generating jacquard weave patterns for arbitrary given images. The existing stepping dithering method suffers from two problems. The first problem is the visually unappealing repetition of patterns for input images containing low frequency, smooth gradation regions. The second problem is the low reproducibility of small structures with high frequency relative to mask size. This paper proposes new methods for faithfully rendering arbitrary natural images on jacquard fabric by solving the pattern repetition and low reproducibility problems. The new methods combine two approaches. The first problem is addressed by optimizing the distribution of thresholds in dither masks, while the second problem is addressed by adopting a dynamic binarizing process for an appropriate area of the stepping dither mask. The experiments described herein show that the proposed method successfully improves the appearance of the resulting woven fabric.
This paper discusses new methods for rendering natural images on yarn-dyed woven fabric, focusing on representing grayscale images by using two colors of warp and weft yarns. In general, textile designers make use of the interaction between the colors of yarns and the structure of the weave patterns to create graphical images on a fabric.
1
In particular, the jacquard weave technique enables rendering of a graphical design on a fabric by using locally different weave patterns to control the ratio at which warp and weft yarns appear.
2
In most cases, different weave patterns are used to emphasize the difference of appearance among segmented regions.3,4 In contrast, gradually changing weave patterns are sometimes used to render a graded tone on a fabric. The most popular technique for rendering a graded tone on a fabric is called shaded satin, which, as its name suggests, can produce a shaded appearance by tiling basic weave patterns with progressively changing ratios of warp and weft yarns. Using the shaded satin method, grayscale images can be reproduced using yarns of differing brightness, for example, black warp yarns and white weft yarns. A graded tone can be reproduced as a gradual change between two extreme conditions, one of which is dominated by warp yarns and the other by weft yarns, as shown in Figure 1(a).
(a) Seven basic weave patterns used to generate (b) shaded satin exhibiting a graded tone.
While the technique is generalizable, this paper will assume use of black warp yarns and white weft yarns. The shaded satin technique is useful for producing a changing tone, but it is not suitable for creating smooth gradations because the limited number of gradation steps used are easily discerned, as shown in Figure 1(b). To remedy the shortcomings of the shaded satin technique, several methods have been proposed for dividing the steps of shaded satin into a number of further sub-steps. For example, Ng and Zhou proposed a multi-color weaving method capable of expressing millions of colors using a database of gamut weave patterns.5,6 Toyoura et al. presented two customized dithering methods, stepping dithering and extended error diffusion, which can generate weave patterns on the fly to reproduce continuous tones on fabric.7,8 The stepping dithering technique uses a dither mask that consists of carefully arranged threshold values which have an up-and-down stepping structure, as its name suggests. The extended error diffusion method uses the stepping dither mask as thresholds for the conventional error diffusion method, aiming to preserve the fine edges of the input image. While their methods can reproduce graded tones in input images more smoothly than the shaded satin method does, we found that the following two problems can arise when using their methods for generating shading patterns:
Examples of two major problems stemming from existing methods and the results based on the proposed method. Occurrence of artifacts manifesting as annoying, undesirable repeated structures in smooth and flat tone areas, as shown in Figure 2(c)- Low reproducibility of structures with high frequency relative to the mask size, such as the overhead wires in the images in Figure 2.
This paper proposes novel methods to solve these problems by improving stepping dithering. We developed a new method to solve the first problem by optimizing the distribution of threshold values in the dither mask. The second problem is remedied by introducing a dynamical binarizing process which preserves the brightness relation of input pixel values within the carefully selected area while other areas follow the stepping dithering process. Figure 3 compares the results obtained from conventional methods and from the proposed methods. The right-hand images in each row show the Gaussian filtered image to better visualize the artifacts.
Images resulting from conventional methods and the proposed methods (left) and their Gaussian filtered images (right).
In the following sections, we first review the structure of the stepping dither mask and formulate its two major problems. Then, we introduce the two new methods for remedying each problem, and finally, we show the results of experiments to demonstrate the effectiveness of our methods.
Stepping dithering and associated problems
Stepping dither mask
Figure 4 shows the concept of the stepping dithering method.
Example of stepping dithering.
The weaving pattern is generated by binarizing the input image using dither masks. The pixel value of the input image, shown in Figure 4(a), is converted into a binary image, as shown in Figure 4(c), by applying the ordered dithering method using the stepping dither mask shown in Figure 4(b).9 The extended error diffusion method uses the stepping dither mask as a threshold for the error diffusion method.8,10 The threshold values and their position in the stepping dither mask are designed to retain the satin-based structure; all the cells except for those containing a value of zero or 255 have a unique threshold value in order to generate the whole gamut of weave patterns, as shown in Figure 4(d). Although Figure 4 shows only an example of an eight harness satin weave pattern, stepping dithering can be used for all the possible regular satin weave patterns as conventional shaded satin technique can.
Stepping structure and its effect
The stepping dither method alternately places values of zero and 255 at given intervals in each row of the dither mask so that there is at least one intersection of warp and weft yarns within the intervals in the generated fabric. Within the intervals, threshold values increase from zero to 255 or decrease from 250 to zero. This forms the up-and-down stepping structure, as shown in Figure 5. The resulting binary image reproduces the brightness of the input image while restraining the number of intersection points in the weave pattern. Note that this up-and-down stepping structure can retain the symmetry of the input image, in comparison with the one-way-step-shaped structure, as shown in Figure 6.
Images generated using the stepping structured threshold values. Difference between the images resulting from applying an up-and-down-step and a one-way-step structured dither mask.

Slot structure and order unit
To formulate the process of arranging threshold values to form the stepping structures, we introduce the concepts of slot and order unit. As shown in Figure 7(a), a slot
Slots in a stepping dither mask.
As each row contains a single zero and a single 255, an n × n dither mask requires
V0 has a value of zero, Vn( n -2) + 1 has a value of 255, and others have values defined at intervals that are as close to uniform as possible.
As Figure 8 shows, we divide the threshold values into n groups Vi Mapping between slots and threshold values.
Here, oij indicates that the oijth threshold value in the ith threshold group should be set to sij of slot Si, where
Optimizing the order unit to obtain smoothly changing tone
As shown in Figure 3, the conventional digital jacquard weave method results in artifacts in smooth gradation regions. Where do these artifacts come from? Figure 9 depicts how the stepping dither mask induces artifacts.
Relationship between order units and occurrence of artifacts.
The image in Figure 9(a) contains a smooth gradation with brightness values varying from zero to 42. The images in Figures 9(c) and (f) show some wedge-shaped structures or diagonal structures, whereas the input image has no such patterns. Such artifacts are more clearly evident in the Gaussian filtered images shown in Figures 9(d) and (g). Figures 9(b) and (e) depict the threshold values allocated to slot S
1
and their position in the stepping dither mask. In both cases, although the same set of threshold values is adopted, their positions differ owing to the different order units. As shown in Figures 9(b) and (e), order unit
After careful investigation, we found that the causes of artifacts fall into two basic categories. One is the biased distribution of threshold values in the latitudinal and longitudinal directions, as shown in Figures 10(a) and (b), and the other is the proximity of adjacent threshold values along the diagonal alignments, as shown in Figure 10(c). Therefore, the first problem can be solved by searching the optimal order unit that can form the evenly distributed threshold values. This is realized through an optimization process guided with a cost function evaluating the biasness of threshold values in the longitudinal, latitudinal, and diagonal directions.
Typical examples of biased distributions of threshold values.
Improving the stepping dither mask by optimizing the order unit
In order to remedy the first problem, we present a novel method for evaluating and optimizing the order unit. To evaluate a dither mask in terms of how likely it is to cause artifacts, we define a cost function E as
The two energy terms, Ebias and Eproximity, estimate the impact of the two causes described above.
Estimating Ebias
The energy Ebias should reflect the bias of the threshold value distribution in both the longitudinal and latitudinal directions. It is given by the following equation:
Graphical representations of longitudinal, latitudinal, and three-diagonal alignments and cost functions.
Equation (8) calculates the average of the sum by dividing the sum of all order unit values by two. This is reasonable as Loi and Lai are the sums for every
Estimating Eproximity
The energy Eproximity should reflect the proximity of adjacent threshold values in one of the three major diagonal alignments: Ea1, Ea2, and Ea3, as given in equation (9). Ea1, Ea2, and Ea3 are computed via equations (9) through (11) based on the distances d1, d2, and d3 between the threshold values, as shown in Figure 11(c), and the difference of the order unit numbers
In equations (11), oi represents the ith number of an order unit, which is used for assigning the threshold value at row i in a dither mask. The terms
Optimizing E
Given that cost E quantitatively evaluates the likelihood of artifacts, minimizing the cost produces an optimized dither mask:
In minimizing the cost function E, we first list all possible order units. Considering that order units are translational, we set the first element of each order unit to one. After the list is complete, we obtain the best order units via a brute-force search. The order unit should be optimized for each n and m of the dither mask. The process of finding the best order unit is carried out during a preprocessing stage. As described in the following section, once we find the best order unit, we can use it for all the slots during the dithering process.
Applying order units to the stepping dither mask
The optimal order units can be used to create a stepping dither mask with the mapping method shown previously in Figure 8. As Figure 8 illustrates, each slot is mapped to one of the non-overlapping threshold value groups, thereby affecting the binarization of the corresponding brightness ranges; thus, we can achieve the best results for the whole range of a subtly changing tone by using the same optimal order unit for all slots.
Extension with a randomly shuffled order unit
The above described order unit optimization method is designed to prevent the artifacts caused by biased structures in dither masks. A binary image generated by periodically tiled dither masks may, however, present some regularly repeating pattern, even though there may be no artifacts evident in any local areas. Regularly repeating patterns are sometimes desirable as a part of a design, but they can also be considered another type of artifact. To solve this problem, we present another method involving the application of a random process for improving the visual quality of the resulting binary images. First, we use an integral number Translated order unit with shifting degree Ro.
Controlling the dithering process for preserving fine details
Figure 13 shows images generated with different dithering methods and the resulting woven fabric. Despite the occurrence of artifacts in smoothly changing tones, stepping dithering is effective for reproducing changing tone macroscopically in a weave pattern. However, spatially small structures in input images may not be sufficiently preserved, as shown in Figure 13(d); stepping dithering gives priority to preserving the smoothly changing structure of the satin-based weave patterns and the overall brightness of the input image by each dither-mask-sized unit.
Results of our method in comparison with other methods.
The generated images shown in the upper row of Figures 13(b) and (c) better preserve the detailed structures, but they are inadequate for use as weave patterns because of the overly long float of weft yarns (Figures 13(b) and (c)) and the deterioration of the image due to the noisy and irregular surface structure (Figure 13 (c)). In this section, we introduce a novel method that can preserve both fine details and brightness while retaining the satin-based weave pattern, as shown in Figure 13(e).
Basic idea
First, we discuss the reason fine details cannot be preserved with stepping dithering, and then we present the underlying basis of our solution. Figure 14(a) shows a flowchart of the stepping dithering process. The resulting image (Figure 14(a)- Flips of the brightness relation through the dithering process.
However, if we look carefully at the local areas of the image, we see some pixels that are flipped over with regard to the order of the brightness. For example, the area surrounded by the dotted line in Figure 14(b)-
The basic idea underlying our method is to control the binarization process by considering the order of the brightness of the input pixel values only in the appropriate limited target area. The target area is carefully defined to avoid the risk of demolishing the resulting satin-based weave pattern, which contributes to the smooth appearance of the resulting woven fabric. We define the target area using a new concept, the boundary slot, and present the algorithm for the binarization of the corresponding areas.
Boundary slot
As shown in Figure 15(a), applying the repetitive stepping structure of threshold values (Figure 15(a)- Concept of boundary slot.
Here, we focus on slot
Detailed method procedure
The detailed procedure of the proposed method is illustrated in the flowchart in Figure 16(a).
Flowchart of the proposed method.
For each dither-mask-sized block of input image, our method starts by identifying the boundary slot within the stepping dither mask. The process of binarization differs for the boundary slot and the other slots. For the pixels outside of the boundary slots, binarization is done by comparing the pixel value with the threshold range of each slot to preserve the cyclic alternation of the satin-based weave pattern. For the boundary slots, pixels are sorted by the order of brightness, and lower k pixels are set to black so as not to flip the brightness order for individual pixels. The figure k is calculated by the ratio of white pixels over black pixels (
Applying a limitation for the target pixels
Figure 17(e) shows a result obtained by our method using the image in Figure 17(a) as the input image.
Images generated with the proposed method and existing stepping dithering method.
We can see that the fine details of the input image are better preserved via the proposed method than the existing stepping dithering method (Figure 17(b)) and our proposed method for smoothly changing tones (Figures 17(c) and (d)), but the gradations are excessively enhanced. Such an enhancement is sometimes desirable, but it may be against the intention of the designers. The excessive enhancement is mainly caused by the forced white–black pixel ratio at the boundary slots. Our method allows the user to control the degree of enhancement by adjusting a target range for the binarizing process following the brightness order of the pixels (Figure 16(a)-
F
). Figure 18 illustrates the adjusted range.
Adjusted range and example of the processes.
Only the pixels located inside the adjusted range (Figure 18(a)-
B
) are subjected to the binarization following the predefined ratio of white and black pixels. In the example in Figure 18(b), the pixel at the position of slot
Here, S is the standard deviation of all pixel values belonging to the dither-mask-sized unit; a larger target range should be used when the pixel values of the input image have a large deviation to reproduce the fine structure of the input image; n is the size of the dither mask and
Figures 17(f) to (h) show the images resulting from the method for preserving fine details with different values of coefficient Rt used to preserve different amounts of fine detail.
Combining the two proposed methods
We have proposed two methods, one for reproducing fine details and the other for rendering smoothly changing tones. Designers can selectively use these methods considering the trade-off between fine features and gradients. In this section, we propose a comprehensive approach using the two methods in a complementary way. Because the method that is more desirable depends primarily on the amount of change of the pixel value, method selection can be done by calculating the amount of change. Our approach uses two steps. First, two layers of the image, one made by each method, are prepared. Second, a thresholding process provides the decision of which of them should be used. This decision is made pixel by pixel by comparing Ap, the amount of change of the pixel values around a target pixel, and a threshold value, Tp. Here, Tp is empirically assigned a value of six. Ap is calculated as follows:
Here, p(x, y) is the pixel value at pixel(x, y). When Ap has a larger value than Tp, the method for reproducing fine details is adopted. Figure 19 shows an example of images resulting from our methods.
Example of the combined processes.
When different strategies of dithering are applied for adjacent regions, usually artifacts may occur at the boundaries of regions. But, as Figure 19(b) shows, our proposed method could successfully avoid the occurrence of noticeable artifacts for the following reasons. First, our two methods for smooth tones and fine details basically share the same stepping structure of thresholds which are arranged in a satin-based weave pattern in the dither mask. Second, although the method for preserving fine details may bring a different appearance from the smoothly changing satin-based weave pattern, the effect is designed to increase gradually as the complexity of the pixel value variation becomes larger. Third, users are allowed to change the threshold Tp referring to the resulting appearance so as not to make a distinctive difference between the regions of two methods.
Experiments and results
Optimizing the order unit
List of order units with the best costs
Results of fabrication
Weaving specifications of experiment for Figure 20
Weaving specifications of experiment for Figures 21 through 23
Figures 20 through 23 show several samples of woven fabric using the proposed methods. The optimized order units shown in Table 1 are used in our proposed method for smoothly changing tone. Figure 20 is an example that shows our method for smooth tones could be effectively applied to a fabric with a motif which mainly features smooth gradation. Figure 21 shows that our proposed method successfully removed the artifacts in the smooth gradation area and reproduced fine details. Figure 21 also shows examples of images preserving two different levels of fine details generated by varying the coefficient Rt. Figure 22 shows the fine detail reproduced in the low contrast area, focusing on the snowy side of a mountain. Figure 23 shows the samples generated through different sizes of dither masks. Figures 23(b), (c), and (d) show the resulting fabric using different weave repeats, n = 8, 11, and 16, respectively. As these results show, as the size of n increases, the contrast of the black and white area is reinforced. This augmentation of the contrast originates from an increase in the utmost ratio of the warp and weft yarns. Generally, when the size of the weave repeat increases, the structure of the weave becomes flexible, and the possible pick count gets higher. Since a high pick count brings high resolution to a fabric according to the density of the weft yarns, we set the pick count as high as possible in our experiments, as Table 3 indicates. On the other hand, the fine details of the input image are blurred when the weave repeat get larger. The resolution and the contrast of the resulting fabric are in a trade-off relationship when the size of the weave repeat changes. Users can decide the size of n considering the conditions of the fabric in our method to be the same as in the conventional shaded satin technique.
Sample of woven fabric generated using the proposed method and a trial product. Samples of woven fabrics showing improvement in fine detail and smooth tone. Sample woven fabrics showing improvement in fine details with low contrast. Sample woven fabrics generated by varying n, the size of dither mask.



Conclusion
In this paper, we have proposed novel methods for generating jacquard weave patterns that can reproduce both smoothly changing graded tones and fine details without noticeable artifacts. Our experiments confirm that the proposed methods are useful for rendering photographs or other images with both high- and low-frequency areas on woven fabrics. Although the methods proposed in this paper focus on the reproducibility of both smooth change of tones and fine details in grayscale mode, they are a foundation for further development: for instance, multicolor mode, combination with area segmentation, combined use of different weave repeat sizes, and textured patterns.
Footnotes
Declaration of conflicting interests
The authors declared no potential conflicts of interest with respect to the research, authorship, and/or publication of this article.
Funding
The authors disclosed receipt of the following financial support for the research, authorship, and/or publication of this article: This work was partially supported by JSPS KAKENHI (16H05867).
