- Author / Uploaded
- Daniel L. Lau
- Gonzalo R. Arce

*1,692*
*477*
*81MB*

*Pages 669*
*Page size 486 x 720 pts*
*Year 2011*

Modern Digital Second Edition

Daniel L. Lau and Gonzalo R. Arce

Boca Raton London New York

CRC Press is an imprint of the Taylor & Francis Group, an informa business

© 2008 by Taylor & Francis Group, LLC

CRC Press Taylor & Francis Group 6000 Broken Sound Parkway NW, Suite 300 Boca Raton, FL 33487‑2742 © 2008 by Taylor & Francis Group, LLC CRC Press is an imprint of Taylor & Francis Group, an Informa business No claim to original U.S. Government works Printed in the United States of America on acid‑free paper 10 9 8 7 6 5 4 3 2 1 International Standard Book Number‑13: 978‑1‑4200‑4753‑0 (Hardcover) This book contains information obtained from authentic and highly regarded sources Reasonable efforts have been made to publish reliable data and information, but the author and publisher cannot assume responsibility for the valid‑ ity of all materials or the consequences of their use. The Authors and Publishers have attempted to trace the copyright holders of all material reproduced in this publication and apologize to copyright holders if permission to publish in this form has not been obtained. If any copyright material has not been acknowledged please write and let us know so we may rectify in any future reprint Except as permitted under U.S. Copyright Law, no part of this book may be reprinted, reproduced, transmitted, or uti‑ lized in any form by any electronic, mechanical, or other means, now known or hereafter invented, including photocopy‑ ing, microfilming, and recording, or in any information storage or retrieval system, without written permission from the publishers. For permission to photocopy or use material electronically from this work, please access www.copyright.com (http:// www.copyright.com/) or contact the Copyright Clearance Center, Inc. (CCC) 222 Rosewood Drive, Danvers, MA 01923, 978‑750‑8400. CCC is a not‑for‑profit organization that provides licenses and registration for a variety of users. For orga‑ nizations that have been granted a photocopy license by the CCC, a separate system of payment has been arranged. Trademark Notice: Product or corporate names may be trademarks or registered trademarks, and are used only for identification and explanation without intent to infringe. Library of Congress Cataloging‑in‑Publication Data Lau, Daniel L. Modern digital halftoning / Daniel L. Lau and Gonzalo R. Arce. ‑‑ 2nd ed. p. cm. Includes bibliographical references and index. ISBN 978‑1‑4200‑4753‑0 (alk. paper) 1. Image processing‑‑Digital techniques. 2. Color computer printers. I. Arce, Gonzalo R. II. Title. TA1637.L38 2008 621.36’7‑‑dc22 Visit the Taylor & Francis Web site at http://www.taylorandfrancis.com and the CRC Press Web site at http://www.crcpress.com

© 2008 by Taylor & Francis Group, LLC

2008008944

Preface Halftoning is the process of converting a continuous-tone photograph into a binary pattern of printed and not printed dots and has been the subject of over 120 years of research and development. As a means of quantifying this work, a search of the U.S. Patent and Trademark oﬃce reveals a total of 1,433 issued patents with the phrase “halftoning,” or “halftone,” inside its abstract dating back to 1976, the earliest searchable year. Searching the published patent applications reveals another 674 applications in review, 136 published in 2006 alone. So in other words even after 120 years, there are still numerous discoveries to be made, many of which are believed, at least by their inventors, to be worthy of a patent. Surprisingly, only three scholarly books have been written on the subject with this being the only one to have a second edition. The ﬁrst book, Robert Ulichney’s, “Digital Halftoning,” created a revolution in the digital printing industry. At the time, digital halftoning was done primarily using amplitude modulated screening in which varying shades of gray were produced by varying the size of black dots arranged along a regular grid. While not introducing a new technique, Ulichney studied frequency modulated halftoning in which varying shades of gray are produced by varying the spacing between randomly placed, same-sized dots and showed that this alternative screening process (introduced in 1973) reproduced images with much higher spatial resolution. The result of Ulichney’s work, within the research community, was a wealth of new halftoning techniques designed to construct these ideal frequency modulated halftone patterns. One of the more profound developments was blue-noise dither arrays capable of transforming a pixel of a continuous-tone image into a binary halftone pixel with just a single comparator operation. Within the printing industry, the impact of Ulichney’s work was felt in the ink jet market which soon introduced low-cost, four-color printers. v © 2008 by Taylor & Francis Group, LLC

Sadly, ink jet printers are the only devices that have ever really taken advantage of frequency modulated screening because, at high resolutions (2,400+ dpi versus the 300 dpi common in 1991), the ability of a device to print isolated dots reliably is severely tested. Variations in the size and shape of printed dots have drastic and sometimes catastrophic impact on the resulting images. So for many devices, these distortions require the use of robust halftoning techniques that resist the eﬀects of printer distortion. The ﬁrst edition of this book addressed the need for a statistical model deﬁning the ideal characteristics of dither patterns resistant to the eﬀects of printer variations by developing new standards for halftone robustness as well as visibility. Furthermore, that book provided a comprehensive study of what was a new stochastic halftoning model, green-noise, including its desirable attributes for printing. It also closely examined several techniques for producing green-noise and studying them in terms of their visual pleasantness and their computational complexity. Due to the demand for color printers, that book also looked at the application of green-noise to color halftoning environments. With the current trends in halftoning being what they were, green-noise represented the next step in the evolution of digital printing, and today, several commercial implementations of green-noise dither arrays are available. Now since that ﬁrst edition, there have been numerous discoveries and advancements in the ﬁeld that have made the prior edition obsolete. As such, the time seemed right for a update in order to cover the additional topics of stochastic moir´e in color printing, a blue-noise model for multi-toning applications where the target printing device is capable of printing multiple shades of the same color ink, and even an update to the original blue-noise model, which was recently determined to have incorrectly characterized the statistical properties of visual pleasing dither patterns near gray-level 12 . This book even includes a discussion of the unique problems associated with lenticular printing, a means for producing a full-color holographic photograph. Chapter 1 serves as an introduction to those not familiar with the current trends in digital printing. This chapter reviews how halftoning was ﬁrst performed 200 years ago and how things have changed with the introduction of low-cost, high resolution, ink jet printers. This chapter also reviews the pros and cons of the various halftoning techniques. In Chapter 2, we cover the details associated with constructing amplitude modulated dither arrays as a means of reviewing the alternate approach vi © 2008 by Taylor & Francis Group, LLC

to halftoning that was barely referenced in the prior edition. In Chapter 3, the spatial and spectral metrics used to study binary, aperiodic, dither patterns are introduced. These metrics oﬀer a fundamental understanding of the inter-point relationships that may exist for a given point distribution. These metrics will later serve to compare the visual quality of a given halftoning technique. Integrated into this chapter are metrics associated with color halftoning. In Chapter 4, we cover the details associated with various human visual models that have been introduced over the years in the study of digital halftoning. In the prior edition, only a simple spectral model was described. Chapter 5 is a detailed review of the blue-noise model. Using the metrics of Chapter 3, Chapter 5 describes the ideal spatial and spectral characteristics of blue-noise and also compares several techniques for producing blue-noise halftone patterns. Through illustration, the many beneﬁts of blue-noise halftoning are presented, showing that blue-noise is the optimal halftoning method in terms of detail rendition. Now due to the performance gain in computational eﬃciency by employing a blue-noise dither array, Chapter 6 reviews the use and construction of blue-noise dither arrays, adding the technique of direct binary search as a means of producing said arrays. Closing out our coverage of blue-noise halftoning, a modiﬁed blue-noise model is introduced in Chapter 7 intended to correct an error in the original formulation that had dismissed the use of hexagonal sampling grids as being inferior to rectangular when, in other areas of image processing, hexagonal grids were considered superior. This new model proves that, in fact, hexagonal grids are superior for producing dither patterns that minimize halftone textures. In Chapter 8, we detail the technique of direct binary search as a means of directly trying to produce dither patterns that optimize the distribution of printed dots according to the human visual models described in Chapter 4. In the prior edition of this book, direct binary search was only referenced in passing. Beyond blue-noise, Chapter 9 oﬀers a detailed study of the printed dot. Looking at the printed dots of both laser and ink jet printers under high magniﬁcation, variations in dot size and shape are shown to have devastating eﬀects on the resulting tone. Printed images, therefore, suﬀer from great degrees of tonal distortion – appearing, in many cases, far too light or far too dark compared with their original. This chapter also shows that when the resulting tone is predictable, the eﬀects of distortion can be minimized through compensation techniques, but compensation is impractical when variations from printed vii © 2008 by Taylor & Francis Group, LLC

dot to printed dot are high. In these instances, it is only through clustering that distortions can be minimized. Chapter 10 presents green-noise as the halftoning technique that addresses distortions in the printed dot. By clustering pixels in a random fashion, green-noise is able to preserve the beneﬁts aﬀorded by stochastic dot patterns and, at the same time, ensure predictability in the printed tones. In presenting green-noise, a relationship between the gray-level, the number of pixels per cluster, and the average distance between clusters is established. Relying on existing algorithms for producing green-noise, this chapter analyzes several techniques in terms of their spatial and spectral characteristics; furthermore, an algorithm for producing green-noise dither arrays is presented. Chapter 11 introduces a means by which to construct gree-noise dither arrays, while color halftoning with green-noise is presented in Chapter 12. Here, a new framework for clustering pixels of like color is presented. This new framework also oﬀers a way of regulating the overlapping of pixels of diﬀerent colors. Also presented is a technique for constructing color dither arrays. Moving to Chapter 13, we look at the problem of stochastic moir´e, which characterizes the appearance of low-frequency color noise introduced by superimposing aperiodic dither patterns where, prior to this discovery, moir´e was only associated with the periodic patterns of AM halftoning. In this chapter, we predict when stochastic moir´e is its most visible and avoid by introducing varying degrees of clustering in the component dither patterns, showing that there are reasons for using green-noise even in devices that one would otherwise expect to use blue. The topic of multi-toning is described in Chapter 14 where multiple shades of gray are used to represent a continuous-tone image instead of just black and white pixels. Speciﬁcally, this chapter describes a blue-noise model for these multi-level dither patterns that includes details on how to characterize a visually pleasing pattern. This chapter also introduces several means by which optimal multi-tone patterns can be generated. Most important, this chapter derives the optimal distribution of dots across the available levels for producing a given shade of gray. This book is concluded with Chapter 16, but only after reviewing the unique process of lenticular printing in Chapter 15, where multiple images are column-wise spliced together and printed onto the ﬂat side of a lenticular lens array such that, when viewed through the lenticules, viii © 2008 by Taylor & Francis Group, LLC

produces a full-color holographic display. The most well-recognized instance of lenticular printing may be baseball cards of the 1970s which ﬂipped between one of two images as the top of the card was tilted toward or away from the viewer. At that time, images were printed onto paper and then glued to the back of the lens array. Today, digital presses print directly onto the plastic sheets, producing images of much higher visual quality. In total, this new edition includes over 250 pages of new material over its predecessor.

Daniel L. Lau Gonzalo R. Arce

ix © 2008 by Taylor & Francis Group, LLC

Acknowledgement In completing the ﬁrst edition of this text, we would like to acknowledge the assistance of Dr. Shaun Love and his research group at Lexmark International, Dr. Jan P. Allebach at Purdue University, and Murat Meese and his advisor Dr. P. P. Vaidyanathan at the California Institute of Technology. We would also like to acknowledge the National Science Foundation’s ﬁnancial support for much of the research that went into this book under grant CDA-9703088 and the ﬁnancial support of Lexmark International, Inc. A great deal of thanks is also directed to Dr. Neal C. Gallagher for his professional guidance at various stages of this work. In developing the new material for this second edition, we would like to thank Robert Ulichney whose insights into the development of the original blue-noise model were an invaluable contribution to the creation of a modiﬁed blue-noise model, which we describe in this book in relation to hexagonal sampling grids. Also, we wish to thank Alvaro Gonzalez for his work with alpha-stable human visual models and Jan Bacca Rodrguez for his work with digital multi-toning and the introduction of a blue-noise model tailored to dither patterns composed of more than two pixel colors. Lastly, we would also like to thank David Roberts and Trebor Smith for their valuable insights into the world of lenticular printing.

xi © 2008 by Taylor & Francis Group, LLC

Contents 1 Introduction 1.1 AM Digital Halftoning . . . . . . . . . . 1.2 FM Digital Halftoning . . . . . . . . . . 1.3 AM-FM Hybrids . . . . . . . . . . . . . 1.3.1 Why Modern Digital Halftoning? 2 AM 2.1 2.2 2.3 2.4 2.5

Halftoning Dot Shape . . . . . . . . . Screen Angles and Moir´e . Screen Frequency . . . . . Supercells . . . . . . . . . Zero-Angle Dither Arrays

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

. . . . .

3 Stochastic Halftone Analysis 3.1 Point Processes . . . . . . . . . . . . . . 3.2 Spatial Statistics . . . . . . . . . . . . . 3.2.1 Pair Correlation . . . . . . . . . . 3.2.2 Directional Distribution Function 3.3 Spectral Statistics . . . . . . . . . . . . . 3.3.1 Radially Averaged Power Spectral 3.3.2 Anisotropy . . . . . . . . . . . . . 3.4 Color Halftoning . . . . . . . . . . . . . 3.4.1 RGB . . . . . . . . . . . . . . . . 3.4.2 CMY . . . . . . . . . . . . . . . . 3.4.3 CMYK . . . . . . . . . . . . . . . 3.4.4 Color Statistics . . . . . . . . . .

. . . .

. . . . .

. . . .

. . . . .

. . . .

. . . . .

. . . .

. . . . .

. . . .

. . . . .

. . . . . . . . . . . . . . . . . . . . . . . . . Density . . . . . . . . . . . . . . . . . . . . . . . . . . . . . .

. . . .

. . . . .

. . . . . . . . . . . .

. . . .

. . . . .

. . . . . . . . . . . .

. . . .

. . . . .

. . . . . . . . . . . .

. . . .

1 4 5 9 9

. . . . .

21 21 23 31 34 35

. . . . . . . . . . . .

39 39 44 44 46 47 49 52 53 53 59 60 61

4 Halftone Visibility 63 4.1 Campbell’s CSF Model . . . . . . . . . . . . . . . . . . . 67 4.2 N¨as¨anen (Exponential) Model . . . . . . . . . . . . . . . 69 xiii © 2008 by Taylor & Francis Group, LLC

4.3 4.4

Mixed Gaussian Models . . . . . . . . . . . . . . . . . . 70 Alpha-Stable HVS Models . . . . . . . . . . . . . . . . . 72

5 Blue-Noise Dithering 5.1 Spatial and Spectral Characteristics . . 5.1.1 Spatial Statistics . . . . . . . . 5.1.2 Spectral Statistics . . . . . . . . 5.2 Error-diﬀusion . . . . . . . . . . . . . . 5.2.1 Eliminating Unwanted Textures 5.2.2 Edge Enhancement . . . . . . . 6 Blue-Noise Dither Arrays 6.1 Simulated Annealing . . 6.2 Void-and-Cluster . . . . 6.3 BIPPSMA . . . . . . . . 6.4 Dither Pattern Ordering

. . . .

. . . .

. . . .

. . . .

. . . .

. . . .

. . . .

. . . .

. . . . . .

. . . .

. . . . . .

. . . .

. . . . . .

. . . .

. . . . . .

. . . .

. . . . . .

. . . .

. . . . . .

. . . .

. . . . . .

. . . .

. . . . . .

. . . .

77 77 79 80 82 83 113

. . . . . .

. . . . . .

. . . .

129 . 131 . 144 . 150 . 163

7 Direct Binary Search 181 7.1 Halftoning by DBS . . . . . . . . . . . . . . . . . . . . . 181 7.2 Eﬃcient DBS Algorithm . . . . . . . . . . . . . . . . . . 183 7.3 Eﬀect of HVS model . . . . . . . . . . . . . . . . . . . . 196 8 Hexagonal Grid Halftoning 8.1 Spectral Aliasing . . . . . . . . . . . 8.2 Modiﬁed Blue-Noise Model . . . . . . 8.3 Hexagonal Sampling Grids . . . . . . 8.3.1 Hexagonal Grid Dither Arrays 9 Printers: Distortions and Models 9.1 Printer Distortion . . . . . . . . . 9.1.1 Dot-Gain . . . . . . . . . 9.1.2 Dot-Loss . . . . . . . . . . 9.2 Dot Models . . . . . . . . . . . . 9.2.1 Physical Models . . . . . . 9.2.2 Statistical Models . . . . . 9.3 Corrective Measures . . . . . . . 9.3.1 Tone Correction . . . . . . 9.3.2 Mode-Based Halftoning . . 9.3.3 Clustering . . . . . . . . . xiv © 2008 by Taylor & Francis Group, LLC

. . . . . . . . . .

. . . . . . . . . .

. . . .

. . . . . . . . . .

. . . .

. . . . . . . . . .

. . . .

. . . . . . . . . .

. . . .

. . . . . . . . . .

. . . .

. . . . . . . . . .

. . . .

. . . . . . . . . .

. . . .

. . . . . . . . . .

. . . .

. . . . . . . . . .

. . . .

. . . . . . . . . .

. . . .

209 . 211 . 223 . 226 . 233

. . . . . . . . . .

239 . 239 . 240 . 244 . 246 . 248 . 260 . 273 . 273 . 273 . 275

10 Green-Noise Dithering 10.1 Spatial and Spectral Characteristics . . 10.1.1 Spatial Statistics . . . . . . . . 10.1.2 Spectral Statistics . . . . . . . . 10.2 EDODF . . . . . . . . . . . . . . . . . 10.2.1 Eliminating Unwanted Textures 10.2.2 Edge Enhancement . . . . . . . 10.2.3 Adaptive Hysteresis . . . . . . .

. . . . . . .

. . . . . . .

. . . . . . .

11 Green-Noise Masks 11.1 BIPPCCA . . . . . . . . . . . . . . . . . . . 11.1.1 Pattern Robustness Using BIPPCCA 11.1.2 Constructing the Green-Noise Mask . 11.2 Optimal Green-Noise Masks . . . . . . . . .

. . . . . . .

. . . .

. . . . . . .

. . . .

. . . . . . .

. . . .

. . . . . . .

. . . .

. . . . . . .

. . . .

. . . . . . .

283 . 283 . 290 . 292 . 293 . 302 . 335 . 363

. . . .

371 . 372 . 375 . 404 . 409

12 Color Printing 423 12.1 Generalized Error-diﬀusion . . . . . . . . . . . . . . . . . 423 12.2 Multi-Channel Green-Noise Masks . . . . . . . . . . . . . 456 12.2.1 Color BIPPCCA . . . . . . . . . . . . . . . . . . 457 13 Stochastic Moir´ e 13.1 Spatial Analysis of Periodic Moir´e . . 13.2 Spatial Analysis of Aperiodic Moir´e . 13.3 Spectral Analysis of Aperiodic Moir´e 13.4 Minimizing Stochastic Moir´e . . . . . 13.5 Stochastic Moir´e and Green-Noise . .

. . . . .

. . . . .

471 . 474 . 479 . 485 . 501 . 503

14 Multi-Tone Dithering 14.1 Spectral Statistics of Multi-tones . . . . . . . . . . . 14.2 Multi-Tone Blue-Noise Model . . . . . . . . . . . . . 14.3 Blue-Noise Multi-Toning . . . . . . . . . . . . . . . . 14.3.1 Blue-Noise Multi-Toning with Error-Diﬀusion 14.3.2 Multi-Toning with DBS . . . . . . . . . . . . 14.4 Optimization . . . . . . . . . . . . . . . . . . . . . .

. . . . . .

. . . . . .

515 517 521 525 532 532 535

15 Lenticular Halftoning 15.1 Model-Based Error-diﬀusion . . . . 15.2 Iterative Tone Correction . . . . . . 15.2.1 Single-Pass Tone Correction 15.2.2 Correlated Columns . . . .

. . . .

. . . .

559 562 568 572 575

xv © 2008 by Taylor & Francis Group, LLC

. . . .

. . . . .

. . . .

. . . . .

. . . .

. . . . .

. . . .

. . . . .

. . . .

. . . . .

. . . .

. . . . .

. . . .

. . . . .

. . . .

. . . . .

. . . .

. . . .

15.2.3 Detecting Gamut Instabilities . . . . . . . . . . . 578 16 Conclusions

585

Bibliography

589

List of Figures

602

Index

643

xvi © 2008 by Taylor & Francis Group, LLC

Chapter 1 Introduction Digital halftoning refers to the process of converting a continuous-tone image or photograph into a pattern of black and white picture elements (Fig. 1.1) for reproduction by a binary display device such as an ink jet printer, which can only choose to print or not print dots. The human visual, acting like a low-pass ﬁlter, blurs these printed and not printed dots together to create the illusion of continuous shades of gray. Depending on the speciﬁc manner in which dots are distributed, a given display device can produce varying degrees of image ﬁdelity with more or less graininess. According to the human visual system, randomly arranged and isolated dots, properly distributed, should produce images with the highest quality, maintaining sharp edges and other ﬁne details. But at the same time, certain display and printing devices are incapable of reproducing isolated dots consistently from dot to dot and, consequently, introduce printing artifacts that greatly degrade those same details that the dot distribution is designed to preserve. For this reason, many printing devices produce periodic patterns of clustered dots, which are easier to produce consistently across the printed page. So in studying halftoning, the principal goal is to determine what is the optimal distribution of dots for that device and then to produce these patterns in a computationally eﬃcient manner. When analog halftoning was perfected in 1880, continuous-tone, monochrome photographs were reproduced as line drawings authored by highly skilled craftsmen, usually on scratch board. But with halftoning, newspapers and magazines could cheaply reproduce photographs in their publications, making photography a lucrative industry and resulting in a technical revolution in photographic equipment. In terms of photo-lithography, the early halftoning processes (Fig. 1.2) involved 1 © 2008 by Taylor & Francis Group, LLC

CHAPTER 1. INTRODUCTION

2

Figure 1.1: Gray-scale image reproduced as an analog halftone.

© 2008 by Taylor & Francis Group, LLC

3 LITHOGRAPHIC FILM (BEFORE DEVELOPING)

SILK SCREEN

PROJECTOR

LITHOGRAPHIC FILM (AFTER DEVELOPING)

Figure 1.2: The binary halftone obtained by projecting the negative of the original continuous-tone image through a ﬁne silk screen. projecting light from the negative of a continuous-tone photograph through a mesh screen, such as ﬁnely woven silk, onto a photo-sensitive plate. Bright light, as it passes through a pin-hole opening in the silk screen, would form a large, round spot on the plate. Dim light would form a small spot. Light sensitive chemicals coating the plate would then form insoluble dots that varied in size according to the tones of the original photographs. After processing, the plate would have dots where ink was to be printed raised slightly above the rest of the plate. Later versions of the halftoning process employed screens made of glass that were coated, on one side, by an opaque substance [116]. A mesh of parallel and equidistant lines were scratched in the opaque surface. A second mesh of parallel and equidistant lines were then scratched in the opaque surface running perpendicular to the original set. Screens would then diﬀer in the number of lines per inch that had been scratched. While ﬁner screens created better spatial resolutions (detail), the quality of the printing press would limit the ﬁneness of the mesh. Later still, the glass plate mesh was replaced altogether with

© 2008 by Taylor & Francis Group, LLC

CHAPTER 1. INTRODUCTION

4

HALFTONE CELL DOT SHAPE

SCREEN ANGLE (SCREEN FREQUENCY) -1

Figure 1.3: The screen frequency, dot shape, and screen angle for an analog halftone pattern. a ﬂexible piece of processed ﬁlm, placed directly in contact with the unexposed lithographic ﬁlm [28]. This contact screen had direct control of the dot structure (Fig. 1.3) being able to control the screen frequency (the number of lines per inch), the dot shape (the shape of dots as they increase in size from light to dark), and the screen angle (the orientation of lines relative to the positive horizontal axis).

1.1

AM Digital Halftoning

Today, printing is a far more advanced process with the introduction of non-impact printing technologies and the emergence of desktop publishing. Brought on by advancements in the digital computer [28], the photo-mechanical screening process introduced in 1880 has, in many instances, been replaced by digital imagesetters. In some instances, printing is no longer binary as continuous-tone dye-sublimation printers are now readily available but due to their speed and material requirements (special papers and inks), have not reached the wide-spread acceptance of color ink jet or electro-photographic (laser) printers, although dye-sublimation has made a major come back with a consumer market for 4 inch by 6 inch photograph printers. In these digital printers, the halftoning process of projecting a continuous-tone original through a halftone screen has been replaced with a raster image processor (RIP) that converts each pixel of the original image from an intermediate tone directly into a binary dot based upon a pixel-by-pixel comparison of the original image with an array of thresholds (Fig. 1.4). Pixels of the original with intensities greater than their corresponding threshold are turned “on” (printed)

© 2008 by Taylor & Francis Group, LLC

1.2. FM DIGITAL HALFTONING

5

HALFTONED SUB-BLOCK ORIGINAL IMAGE

1

1

1

0

0

0

1

1

1

1

1

0

0

0

1

1

1

0

0

0

0

0

1

1

1

1

0

0

0

0

0

1

1

1

0

0

0

0

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

1

HALFTONED IMAGE

36 32 39 17 11 9 16 15 42 33 39 26 24 21 38 31 54 34 36 38 33 39 40 34 59 50 37 35 35 37 33 41 59 60 53 42 40 41 3 48 9 58 17 27 25 15 7

1

51 56 59 60 59 60 11 61 29 60 38 46 44 36 23 5 41 47 49 55 60 58 19 57 40 58 52 58 56 50 34 13 37 40 41 44 48 48 31 46 48 44 60 64 62 54 42 21

IMAGE SUB-BLOCK

30 47 59 63 61 53 41 20 18 39 51 57 55 49 33 12 10 28 37 45 43 35 22 4 2

8 16 26 24 14 6

0

DITHER ARRAY

Figure 1.4: Digital AM halftoning. in the ﬁnal halftoned image while pixels less than their corresponding thresholds are turned “oﬀ”. For large images, the threshold array is tiled end-to-end until all pixels of the original have a corresponding threshold. When ﬁrst introduced, RIPs imitated the halftone patterns of contact screens by employing clustered-dot ordered dithering, where the threshold array is small (8 × 8, 12 × 12, or 16 × 16) and is composed of consecutive thresholds arranged along a spiral path radiating outward from the array’s center (Fig. 1.5). These arrangements of thresholds result in a single cluster of “on” pixels centered within each tile or cell, forming a regular grid of round dots that vary in size according to tone. These techniques are commonly referred to as amplitude modulated or AM digital halftoning due to their modulating of the size of printed dots. Like contact screens, the resulting patterns vary in their screen frequency, dot shape, and screen angle.

1.2

FM Digital Halftoning

Due to freedoms aﬀorded by digital printers, the idea of printing isolated pixels in an eﬀort to minimize halftone visibility (the visibility of the individual dots to a human viewer) emerged as an alternative to clustered-dot dithering. By maintaining the size of printed dots for all

© 2008 by Taylor & Francis Group, LLC

CHAPTER 1. INTRODUCTION

6 3

9 17 27 25 15 7

1

11 29 38 46 44 36 23 5 19 40 52 58 56 50 34 13 31 48 60 64 62 54 42 21 30 47 59 63 61 53 41 20 18 39 51 57 55 49 33 12 10 28 37 45 43 35 22 4 2

8 16 26 24 14 6

0

Figure 1.5: An 8 × 8 dither array (65 gray-levels). gray-levels as individual pixels, new dispersed-dot halftoning techniques varied, according to tone, the spacing between printed dots, earning the name frequency modulated or FM halftoning. Early FM halftoning techniques were proposed by Bayer [11] and Bryngdahl [15] and produced an ordered arrangement of isolated dots. These techniques, like AM halftoning schemes, quantized each pixel independently of its neighbors (point process) according to a dither array but with consecutive thresholds dispersed as much as possible. The problem associated with these early FM techniques is that, as in the case of Bayer’s dither array (Fig. 1.6), resulting halftoned images (Fig. 1.7) suﬀered from a periodic structure that added an unnatural appearance [123]. For a far better approach to FM halftoning, Floyd and Steinberg [40] proposed the revolutionary error-diﬀusion algorithm (shown in Fig. 1.8 and covered in Chapter 5), an adaptive technique that quantized each pixel according to a statistical analysis of an input pixel and its neighbors (neighborhood process), leading to a stochastic arrangement of printed dots. While this neighborhood process had higher computational complexity, the resulting patterns had apparent spatial resolutions much higher than those achieved by clustered dots (Fig. 1.9); furthermore, as a stochastic patterning of dots, the patterns eliminated the occurrence of the moir´e that was produced by the superimposing of two or more regular patterns. By using FM halftoning schemes, printers maximize their apparent spatial resolution and are relieved of the strict tolerances on screen angles and screen registration. They can also use more and more colors to produce larger color gamuts (the set of achievable colors that can be produced by the printer) [76]. Notably, though, with its associated advantages, FM halftoning has, with few exceptions, only been employed

© 2008 by Taylor & Francis Group, LLC

1.2. FM DIGITAL HALFTONING

7

0 58 14 54 3 57 13 53 32 16 46 30 35 19 45 29 8 48 4 62 11 51 7 61 40 24 36 20 43 27 39 23 2 56 12 52 1 59 15 55 34 18 44 28 33 17 47 31 10 50 6 60 9 49 5 63 42 26 38 22 41 25 37 21

Figure 1.6: An 8 × 8 Bayer’s dither array (65 gray-levels). in ink jet printers. The problem is the increased scrutiny placed on the printer’s ability to print small, isolated dots. Noting Fig. 1.10, the ideal display produces dots that completely cover the sample area associated with a given pixel without overlapping neighboring pixels’ sample areas. By printing all pixels, perfect black can be obtained. In a real printing device, individual printed dots are round and in order to produce perfect black, must be large enough as to cover the entire sample area (Fig. 1.11). By overlapping neighboring sample areas, though, the resulting tone is darker than the fraction of all pixels that are printed. Assuming that dots are printed consistently (small variation in size and shape from printed dot to printed dot), this distortion in tone can be corrected by adjusting the intensity level of the input image before halftoning. The amount of compensation depends on the arrangement of printed dots with dispersed-dot (FM) patterns requiring greater degrees of correction than clustered (AM). Ink jet printers are such a device that prints (approximately) round dots that overlap neighboring pixels (Fig. 1.12). Being able to compensate for distortions introduced by the printing process for any arrangement of dots, ink jet printers can enjoy the beneﬁts associated with FM halftoning. In the electro-photographic printing process, the size and shape of dots varies greatly from printed dot to printed dot (Fig. 1.13) and this variation can only be minimized when dots are grouped together to form clusters. Images printed using isolated dots tend to show severe tonal distortion and exhibit a great deal of variation in tone across the printed page, as illustrated in Fig. 1.14. For this reason, unreliable printing devices such as lithographic presses and laser printers continue to use AM halftoning schemes.

© 2008 by Taylor & Francis Group, LLC

8

CHAPTER 1. INTRODUCTION

Figure 1.7: Gray-scale image halftoned using Bayer’s dither printed at 150 dpi.

© 2008 by Taylor & Francis Group, LLC

1.3. AM-FM HYBRIDS

x [n] +

9

y [n]

Y -

+ x e[n]

b

+ Y y e[n]

Figure 1.8: The error-diﬀusion algorithm.

1.3

AM-FM Hybrids

Now as printers began achieving print resolutions greater than 1, 200 dpi, the limits of FM halftoning were also being reached, just as AM’s was in 1990 before the introduction of low-cost color. Researchers, therefore, begin to look at AM-FM hybrids which produce dot clusters that vary, according to tone, in both their size and spacing [6, 66, 75, 94, 110, 125, 126, 128] (Fig. 1.15). When considering the reproduction of monochrome images, AM-FM hybrids are, in general, capable of producing patterns with lower visibility (higher spatial resolution) compared to AM and, if stochastic, do so without a periodic structure adding an artiﬁcial texture to the printed image. With some amount of clustering, these halftones are easier to print reliably and with little variation in the resulting tone. In the reproduction of color, stochastic hybrids also maintain the same freedom from periodic moir´e associated with FM halftoning.

1.3.1

Why Modern Digital Halftoning?

Since its publishing in 1987, Ulichney’s Digital Halftoning [122] has proven to be the single most unifying book about halftoning research. While a large portion of that book is devoted to AM halftoning, its most signiﬁcant contribution is its description of error-diﬀusion as a generator of blue-noise, visually pleasing halftone patterns composed of randomly placed, isolated dots. Ulichney used the term “blue” as a reference to the spectral content of the random patterns as being composed exclusively of high-frequency spectral components just as blue light is composed exclusively of the high-frequency spectral components of white light. Ulichney further showed that the average distance between same colored dots was directly related to the gray-level of the image before halftoning. In summary, Ulichney’s work tells us when

© 2008 by Taylor & Francis Group, LLC

10

CHAPTER 1. INTRODUCTION

Figure 1.9: Gray-scale image halftoned using Floyd’s and Steinberg’s error-diﬀusion algorithm.

© 2008 by Taylor & Francis Group, LLC

1.3. AM-FM HYBRIDS

(a)

11

(b)

(c)

(d)

Figure 1.10: Clusters of (a) one, (b) two, (c) three, and (d) four printed dots from an ideal printer with the solid lines indicating the border between neighboring output pixels.

(a)

(b)

(c)

(d)

Figure 1.11: Clusters of (a,c) one and (b,d) four printed round dots where the dots of (a) and (b) cover the entire sample area while the dots of (c) and (d) do not cover the corners. one FM halftone is better, visually, than another. It is thanks to the improved image quality produced by blue-noise that ink jet printers are so prevalent today as these printers have directly beneﬁted from the improved spatial resolution aﬀorded by randomly placed, isolated dots. In the decade that followed the publishing of Digital Halftoning, many technological advancements were documented directly addressing the creation of blue-noise. The most notable of which may be introduction of blue-noise dither arrays that convert the pixels of continuoustone images to binary through a pixel-wise comparison of the original pixel with a corresponding pixel in the dither array. A process identical to AM halftoning with the exception that these blue-noise dither arrays are typically much larger (128 × 128 or 256 × 256) as seen in Fig. 1.16. Being a point process operation, blue-noise dither array halfton-

© 2008 by Taylor & Francis Group, LLC

CHAPTER 1. INTRODUCTION

12

(a)

(b)

(c)

(d)

Figure 1.12: Clusters of (a) one, (b) two, (c) three, and (d) four printed dots printed on ink jet printer.

(a)

(b)

(c)

(d)

Figure 1.13: Clusters of (a) one, (b) two, (c) three, and (d) four printed dots printed on a laser printer. ing is far less computationally complex than error-diﬀusion, making it a viable technique for commercial printing applications whose image sizes are orders of magnitude larger than those associated with desktop printers. Now the error-diﬀusion algorithm, itself, has also undergone some major improvements over the past two decade [58]. One of the more profound improvements has been the introduction of threshold modulation, where the threshold used to quantize an input pixel to either one or zero is varied in a given fashion. An early approach to threshold modulation was proposed by Ulichney [122], who suggested adding white-noise to the threshold in order to break up worm patterns and periodic textures (Fig. 1.17). This approach was later shown by Knox [55] to be equivalent to adding low-level white-noise to the original image before halftoning. Another approach to threshold perturbation was later proposed by Eschbach and Knox [34], who suggested varying the threshold by a scalar multiple of the current input pixel. This oper-

© 2008 by Taylor & Francis Group, LLC

1.3. AM-FM HYBRIDS

13

(a)

(b)

(c)

(d)

Figure 1.14: Gray-scale ramps produced by a laser printer using (a) FM halftoning and (b-d) AM halftoning with halftone cells of size 8 × 8, 12 × 12, and 16 × 16 pixels respectively.

© 2008 by Taylor & Francis Group, LLC

14

CHAPTER 1. INTRODUCTION

Figure 1.15: Gray-scale image halftoned using an AM-FM hybrid.

© 2008 by Taylor & Francis Group, LLC

1.3. AM-FM HYBRIDS

15

Figure 1.16: A 128 × 128 blue-noise mask. ation sharpened the resulting halftone pattern, thereby eliminating the need for applying an edge sharpening ﬁlter to the input image prior to halftoning. A completely diﬀerent approach to halftoning, proposed since Ulichney’s book, is Analoui’s and Allebach’s [5] direct binary search (DBS) algorithm. This algorithm iteratively swaps and toggles the binary halftone pattern according to the error between the original continuous-tone image and the binary halftone image as deﬁned by a model of the human visual system. Typically, the human visual system is modeled as a low-pass ﬁlter, and by employing it into the halftoning algorithm, causes same colored dots to be spread as far apart as possible, creating a power spectrum that models blue-noise. While far more computationally complex than even error-diﬀusion, the DBS algorithm’s complexity has greatly diminished since ﬁrst being proposed and may one day challenge error-diﬀusion. Looking back at error-diﬀusion, another innovation or particular importance to halftoning is Pappas’ and Neuhoﬀ’s [96] model-based halftoning, which employs error-diﬀusion in the traditional sense but with the printed dot modeled by a round circle, Fig. 1.11, that overlaps neighboring pixels. This phenomenon of overlapping neighboring pixels, in the printed output, is generally referred to as dot-gain and is typically corrected for by changing the input intensity levels prior to halftoning. Pappas and Neuhoﬀ, by employing a dot model into

© 2008 by Taylor & Francis Group, LLC

CHAPTER 1. INTRODUCTION

16

WORM PATTERNS

PERIODIC TEXTURES

FLOYD-STEINBERG

ULICHNEY

Figure 1.17: A comparison of Floyd’s and Steinberg’s original errordiﬀusion algorithm with Ulichney’s threshold modulated error-diﬀusion algorithm. the halftoning algorithm, directly addressed the problems of printer distortion, where the printer’s ability to print isolated dots reliably (with little variation in the size and/or shape of dots from printed dot to printed dot) aﬀects and sometimes dictates which arrangements of dots, whether dispersed as in FM or clustered as in AM, can or cannot be used. This brings about another very important aspect of halftoning that has surfaced as a direct result of the blue-noise model, that is that even with ten years of technological improvements, blue-noise has made little inroads into electro-photographic printing or digital oﬀset printing. The reason is clear being that blue-noise and FM halftones in general are expensive, if not impossible, to produce consistently across a page, from page to page, or from day to day or even hour to hour. Figure 1.18 illustrates the resulting variation in tone across a page for 7 an error-diﬀused halftone representing gray-level 10 produced by a laser printer set at 1,200 dpi. In this ﬁgure, the average variation in tone along the vertical axis is plot along side a picture of the page, and the average variation in tone along horizontal is plotted below the picture. In order to be reasonably eﬃcient, a process like Pappas’ and Neuhoﬀ’s requires that the statistical characteristics of the printed dot do not

© 2008 by Taylor & Francis Group, LLC

1.3. AM-FM HYBRIDS

17

change either over time or across the page or according to the location of other dots. So a real challenge has come to face researchers as they try to improve the image quality in these types of printers. What they are ﬁnding is that halftoning algorithms that cluster same color pixels together, in a random fashion, hold the key by creating patterns that are easier to produce consistently from page to page and by creating color halftone patterns without moir´e. When ﬁrst published in 2001, the goal of this book was to introduce, in a concise and unifying framework, these modern approaches to digital halftoning. The new model introduced was that of greennoise, a statistical model that described the spatial and spectral characteristics of visually pleasing dither patterns composed of a random arrangement of clustered dots that vary with gray-level in both their spacing apart and their size and shape. The term “green” referred to the mid-frequency only content of corresponding halftone patterns as green light is the mid-frequency component of white. What made green-noise a unifying framework is that it was tunable, describing the ideal characteristics for a range of cluster sizes where small clusters were reserved for reliable printing devices that showed small variation in the size and shape of printed dots and large clusters were reserved for unreliable printing devices. In addition to describing the traits that would determine when one green-noise halftone pattern was better than another, we addressed the problem of computational eﬃciency by introducing the green-noise mask [63], a variation on blue-noise dither arrays for producing greennoise. Like the green-noise model, these new masks were also tunable, making them applicable to a wide range of printing devices. Having blue-noise as a limiting case of green-noise, the green-noise mask construction procedure described could even be applied to constructing the previously invented blue-noise arrays. As a last component to greennoise, the ﬁrst edition of this book addressed green-noise’s application to color printing where the primary task is to reproduce color as accurately as possible without introducing visible moir´e patterns. While color printers were once very expensive and therefore rare, blue-noise has made color printing common place in both homes and oﬃces. For any halftoning research to be noteworthy, it must address color printing, and we showed how green-noise was applied in color printers without introducing moir´e. Now in presenting a second edition of this book, we wanted to broaden the range of topics addressed by including a new chapter focus-

© 2008 by Taylor & Francis Group, LLC

CHAPTER 1. INTRODUCTION

18

10 9

vertical axis (inches)

8 7 6 5 4 3 2 1

resulting tone

0 0.6 0.7 0.8 resulting tone 0.8 0.7 0.6

0

1

2 3 4 5 6 horizontal axis (inches)

7

8

Figure 1.18: The resulting printed page produced by a laser printer at 7 1,200 dpi where the gray-level 10 is produced using error-diﬀusion. The average variations in tone along the horizontal axis and the vertical axis are also shown, plotted alongside and below the picture of the printed page. ing on the prior art of AM dither array construction, deﬁning in greater detail the beneﬁts and challenges associated with irrational screen angles. We have also included a thorough review of the original blue-noise model for hexagonal sampling grids, where we show that the original model was incorrect in its assumptions about distributing minority pix-

© 2008 by Taylor & Francis Group, LLC

1.3. AM-FM HYBRIDS

19

els in areas close to 50% gray. Speciﬁcally, it was determined that near 50% gray, the sampling grid was restricting the placement of printed dots, which was injecting periodic textures into the dot pattern. So by introducing a minimum amount of clustering, a halftone can be produced that accepts a certain amount of low-frequency graininess in exchange for reducing the periodic texture produced by the underlying sampling grid. As such, it is possible to produce visually pleasing dither patterns on hexagonal sampling grids which have a smaller maximum spatial frequency compared to the equivalent rectangular grid. In the area of color halftoning, this edition greatly expands the prior discussion of superimposing component green-noise dither patterns by focusing on the problem of minimizing stochastic moir´e, the aperiodic equivalent of the moir´e produced by superimposing AM halftones. In particular while it is generally accepted that superimposing FM halftones results in a certain amount of color noise, it is the superposition of green-noise dither patterns that results in signiﬁcantly worse amounts of this noise as the frequency content of stochastic moir´e is directly related to the frequency content of the component dither patterns. Given this relationship, stochastic moir´e can be minimized by properly varying the coarseness of the component patterns across colors. Now in a problem closely related to color halftoning, a chapter has been added that focuses on the process of multi-toning and the creation of patterns composed of more than two gray-levels. Speciﬁcally, we address this new area by means of a blue-noise multi-tone model describing, not only the optimal distribution of multi-tone pixels, but also the optimal distributions of the various intensity levels between the component inks. In particular, we look at the change in halftone texture across gray-levels as the concentrations of component inks vary choosing the concentrations that minimize discontinuities in texture as being optimal. And ﬁnally, this book includes an introduction to the lenticular printing problem where multiple images are spatially multiplexed onto the back of a plastic lens array such that, when viewed through the lenses, only one component image is visible depending upon the angle at which the lens arrayed is viewed.

© 2008 by Taylor & Francis Group, LLC

Chapter 2 AM Halftoning As described in the Introduction, amplitude modulated (AM) halftoning is a process of representing varying shades of gray by a regular grid of round dot clusters that vary in size, with dark shades of gray represented by large clusters and light shades by small. This type of halftoning is also generally referred to as periodic, clustered-dot halftoning and is accomplished by means of a dither array whereby pixels are thresholded on a pixel-wise basis with the corresponding entries in the array. Perhaps the best way to describe the construction of these dither arrays for AM screening is in terms of Adobe’s PostScript page description language, which generates dither arrays according to a user deﬁned screen frequency, angle, and spot function, as will be described in the following sections.

2.1

Dot Shape

When characterizing AM screens, dot shape refers to the speciﬁc arrangement of thresholds within the dither array. This ordering dictates how clusters vary in both size and shape according to tone. The shape of dots is most clearly recognizable at gray-level 12 (number of black dots equals the number of white dots), and the most common dot shapes are round, square, and elliptical [23]. Special eﬀect shapes have also been introduced [12, 83]. In PostScript, dot shape is controlled through the user supplied spot function where, initially, pixels of the continuous-tone image, at the printing device’s native resolution, are divided into square tiles with side lengths equal to the inverse of the supplied screen frequency 21 © 2008 by Taylor & Francis Group, LLC

CHAPTER 2. AM HALFTONING

22

Y

+1 +1

-1 y) enc equ n fr ree (sc

-1 y) c n ue freq n e re (sc

X

-1 -1

screen angle

Figure 2.1: Assignment of pixels to a halftone cell as a function of the screen angle and frequency. parameter and oriented at the supplied screen angle (Fig. 2.1). These tiles then form the halftone cells where, inside each cell, pixels are assigned a horizontal (x) and vertical (y) coordinate ranging from −1 at the left and bottom edges of the cell to +1 at the right and top edges in the rotated space. The origin of the cell is then located at its geometric center. Having a unique x and y coordinate, a cost value is assigned to each pixel according to the spot function, which takes a pixel’s x and y coordinates as its input. An example of such a cost function is demonstrated in Fig. 2.3, where we measured the Euclidean distance between a pixel and the cell origin as cost(x, y) = x2 + y 2 ,

(2.1)

for an inverse screen frequency of 10 pixels and a screen angle of 15 degrees. Examples of other possible spot functions include a line screen

© 2008 by Taylor & Francis Group, LLC

´ 2.2. SCREEN ANGLES AND MOIRE

23

as cost(x, y) = x,

(2.2)

cost(x, y) = max(x, y),

(2.3)

a square spot as or even a diamond spot as cost(x, y) = |x| + |y|.

(2.4)

Shown in Fig. 2.2 are demonstrations of the resulting dot shapes. Regardless of the spot function, histogram equalization is then applied to the range of cost values within the cell, such that the pixel with the lowest cost has a threshold value near 0 while the largest cost pixel has a value near 255, assuming 8 bits per pixel gray-scale. All other cost values are assigned in such a way as to have a uniform distribution from 0 to 255. In the case of two or more pixels having the same cost, it is up to the printer manufacturer to decide which pixel is assigned the lower range. In the case of Fig. 2.4, where the resulting dither array from Fig. 2.3 is shown, the angle between the subject pixel and the +x axis was used to break the ties with the smaller angles being assigned the smaller threshold.

2.2

Screen Angles and Moir´ e

The screen angle is the orientation of the screen lines relative to the horizontal axis whose optimal value is a function of the human visual system, where directional artifacts are their least noticeable when oriented along the 45 degrees diagonal [18], as demonstrated in Fig. 2.5. It follows that for monochrome printing, this screen angle should also be 45 degrees. For computational ease, screen angles are typically restricted to rational angles (rise over run equals integer over integer), where each tile is of the same size and shape. Shown in Fig. 2.6 is the division of pixels into a tiling of halftone cells of size 6 × 6 pixels at a rational angle of 9.5 degrees. Note how each tile is identically shaped. Irrational angles create a tiling that requires multiple threshold arrays due to varying tile shapes. Figure 2.7 shows the tiling of cells of size 6 × 6 pixels at an irrational angle of 16.6 degrees where tiles are not identically shaped as indicated by the cells labeled A and B. Using irrational angles requires a raster image processor (RIP) to generate

© 2008 by Taylor & Francis Group, LLC

CHAPTER 2. AM HALFTONING

24

(a) round

(b) square

(c) line

(d) black square

Figure 2.2: Various dot shapes proposed for AM halftoning.

© 2008 by Taylor & Francis Group, LLC

´ 2.2. SCREEN ANGLES AND MOIRE

25

Figure 2.3: Assignment of a cost value to the pixels of a given cell where, within each pixel, an (top) x-coordinate, (center) y-coordinate, and (bottom) cost value are shown.

threshold arrays on the ﬂy to match the size and shape of a particular tile [12]. Given the computational expense of (1) mapping image row and column coordinates m and n into halftone cell coordinates x and y, (2) calculating costs for each pixel within a cell, (3) sorting said pixels from lowest to highest cost, and then (4) equalizing and assigning thresholds within the cell, early PostScript printers required that the user supplied

© 2008 by Taylor & Francis Group, LLC

CHAPTER 2. AM HALFTONING

26

212

221

243

252

205

172

146

151

165

193

231

247

233

181

139

120

96

80

108

127

179

240

195

129

92

73

51

42

61

89

134

203

224

167

110

63

35

25

16

33

70

118

170

214

153

82

44

14

7

4

23

49

94

144

148

101

54

18

0

2

11

40

77

158

210

174

113

66

28

9

21

30

59

106

162

219

198

136

87

56

37

47

68

85

125

191

238

184

122

103

75

99

115

132

186

229

250

226

188

160

155

141

177

200

245

236

217

207

255

Figure 2.4: Assignment of thresholds to the halftone cell of Fig. 2.3, where the angle between the subject pixel and the +x axis was used to break ties. screen frequency and angle parameters correspond to a rational screen angle; otherwise, the print engine would round the supplied parameters to values that do. In this way, each and every halftone cell would be of the same size and shape with identical x- and y-coordinates assigned to corresponding pixels within cells. As such, only for the very ﬁrst cell would the printer derive a threshold matrix, which is then tiled end-to-end for all subsequent cells. In the case of irrational screen angles, halftone cells vary in size and shape from cell to cell, and therefore each cell requires reprocessing. Hence, it was not until the introduction of PostScript Level 2, in 1991 with the emergence of color laser printers, that Adobe added an accurate screen, boolean operator for specifying halftone screens with a value of false telling the processing engine to round oﬀ the frequency and angle to the nearest rational angle, as performed previously. A value of true tells the printer to perform the added computation necessary to maintain the requested screen angle. Now the signiﬁcance of color printing, as the impetus for irrational angles, is that it is only when printing color that a restriction to rational screen angles becomes visually apparent due to the creation

© 2008 by Taylor & Francis Group, LLC

´ 2.2. SCREEN ANGLES AND MOIRE

27

(a) 0 degrees

(b) 30 degrees

(c) 45 degrees

(d) 70 degrees

Figure 2.5: The eﬀects of varying screen angle.

© 2008 by Taylor & Francis Group, LLC

CHAPTER 2. AM HALFTONING

28

Figure 2.6: The tiling of 6 × 6 halftone cells for a rational screen angle of 9.5 degrees.

A

B

Figure 2.7: The tiling of 6 × 6 halftone cells for an irrational screen angle of 16.6 degrees.

© 2008 by Taylor & Francis Group, LLC

´ 2.2. SCREEN ANGLES AND MOIRE

29

(a) 5 degrees

(b) 10 degrees

(c) 15 degrees

(d) 30 degrees

Figure 2.8: The moir´e patterns created by oﬀsetting two AM halftone patterns by (a) 5 degrees , (b) 10 degrees, (c) 15 degrees, and (d) 30 degrees. of moir´e (Fig. 2.8), the periodic interference pattern associated with overlapping two or more regular grids. In color printing, the halftone patterns of cyan, magenta, yellow, and black (CMYK) inks are superimposed with AM patterns, composed of regular grids of printed dots, exhibiting moir´e. While this interference cannot be altogether eliminated, it is through the screen angles 15 degrees , 75 degrees, 0 degrees, and 45 degrees for cyan, magenta, yellow, and black, respectively, that moir´e is minimized, creating a pleasant rosett´e pattern such as the solid

© 2008 by Taylor & Francis Group, LLC

CHAPTER 2. AM HALFTONING

30

Figure 2.9: The solid spot rosett´e pattern created by setting the CMYK channels to screen angles 15 degrees, 75 degrees, 0 degrees, and 45 degrees respectively.

spot rosett´e in Fig. 2.9. Still, the computational complexity of generating a unique dither array for each and every halftone cell, for each component color, is still so high that many printer manufacturers continue to round oﬀ the requested screen angle and frequency to the nearest rational angle. But they do so over more than one halftone cell, constructing a single dither array covering an N × N block of cells such that the conglomerate is, itself, a halftone cell at a rational screen angle while the individual cells are at a potentially irrational screen angle of

screen angle =

(integer number of rows/N ) . (integer number of cols/N )

(2.5)

So while the array does not achieve the inﬁnite precision of an irrational screen angle, it does achieve N times the precision of a rational angle while only incurring N 2 of the computational complexity and memory required to derive the rational angle threshold array. Shown in Figs. 2.10 and 2.11 are two examples of this technique for a 15 degrees screen angle and inverse frequency of 10 pixels for N equal to 2 and 3, where, in the case of Fig. 2.4 and N = 1, rounding oﬀ to the nearest rational angle resulted in a screen angle of 16.6992 degrees and inverse frequency of 10.4403 pixels. Using a 2 × 2 block results in a screen angle of 14.7436 degrees and inverse frequency of 9.8234 pixels, while a 3 × 3 block results in an angle of 15.4222 degrees and inverse frequency of 10.0277 pixels.

© 2008 by Taylor & Francis Group, LLC

2.3. SCREEN FREQUENCY

31 209

215

236

247

220

193

156

135

140

151

188

225

244

255

252

231

172

119

98

77

71

92

124

167

201

179

163

185

206

233

241

204

130

87

50

39

34

55

82

146

199

249

228

169

144

110

104

115

134

174

222

183

114

61

29

7

13

23

66

108

175

238

190

126

83

64

45

61

88

120

195

162

103

45

18

2

0

15

42

100

159

217

153

93

53

24

18

29

51

99

158

177

106

63

21

10

5

26

58

111

180

209

147

69

32

13

0

8

37

75

131

196

143

79

53

31

37

47

85

127

201

239

136

77

40

5

2

10

34

72

139

212

164

122

90

69

74

95

116

170

228

249

155

96

48

26

16

21

56

91

150

214

223

185

148

138

132

154

191

217

244

255

193

118

85

59

42

67

80

123

187

236

244

233

212

207

201

179

163

185

206

233

220

171

128

112

102

107

142

166

225

246

255

246

228

169

147

110

104

115

128

174

222

230

204

182

161

177

198

209

215

236

244

238

187

126

83

67

45

59

88

120

195

252

241

220

193

156

130

138

151

185

225

217

153

93

53

24

18

29

48

96

158

252

231

172

119

98

77

71

92

124

167

212

139

69

34

13

2

5

37

75

134

241

204

135

87

50

37

34

53

82

146

199

136

77

40

8

0

10

32

72

144

209

183

114

61

29

7

10

23

66

108

177

155

99

51

26

16

21

56

91

150

214

162

103

45

18

0

2

15

42

100

159

193

118

85

61

42

64

80

123

190

236

175

106

63

21

13

5

26

58

111

180

220

171

131

112

102

107

142

166

225

249

196

140

79

55

31

39

47

85

127

201

239

230

204

182

161

177

198

164

122

90

69

74

95

116

170

228

249

252

241

223

188

148

143

132

154

191

217

247

233

212

207

255

Figure 2.10: Assignment of thresholds to a 2 × 2 conglomerate of halftone cells with a screen angle of 14.7436 degrees and inverse frequency of 9.8234 pixels.

2.3

Screen Frequency

In AM halftoning, the screen frequency is the number of lines or rows of clustered dots per inch of the resulting halftone pattern. Like the original glass plate screens, the ﬁner screens create patterns with higher spatial resolutions (Fig. 2.12). Depending on the resolution of the printer (measured in dots per inch), screen frequency is limited by the number of unique gray-levels the printer can represent. This relationship is

© 2008 by Taylor & Francis Group, LLC

CHAPTER 2. AM HALFTONING

32

206 216 232 247 221 191 150 142 145 147 183 224 99

79

76

91

189 184 197 223 241 239 198 132

255 249 226 181 127 89

56

38

35

58

86

137 201

249 228 179 145 122 117 130 161 202 229 175 109

63

30

10

12

28

61

107 173

234 244 252 234 182 132 201 173 153 170 188 214 237 213 140

98

93

70

57

72

54

28

23

41

104 150 208 160 62

94

130 178

45

17

0

2

15

48

96

109 171 165 104

53

20

5

7

22

51

102 170

71

73

122 188 234

247 224 178 137 107

96

102 122 158 209 192 124

67

31

7

5

15

44

88

143 193 124

232 183 130

86

61

48

51

59

26

2

0

10

33

80

135 210 155 114

216 147

91

58

28

15

22

40

81

140 195 127

91

158 226 211 163 135 117 119 140 168 209 237 252

206 145

76

35

12

2

5

25

68

119 186 163 101

142

79

38

10

0

7

33

66

117 196 200 153 106

150

99

56

30

17

20

43

84

135 204 239 205 169 148 137 156 176 215 232 242 252 244 205 153 101

89

63

45

53

71

114 163 219 252 244 231 218 215 175 153 163 183 203 222 231 169 106

191 127

221 181 132 109

94

73

112 168 187 119

75

39

18

13

20

52

65

46

36

49

78

85

83

96

43

33

25

40

84

66

68

81

153

112 158 214 244

114 174 236 242 219 204 196 186 195 187 192 213 234 249

111 166 221 247 255 252 239 200 163 127 119 124 140 182 228

104 124 155 211 242 255 255 225 195 136 126 103

75

59

67

98

65

39

26

31

54

93

145

2

7

28

70

122 189

94

113 143 193 218 148

85

46

18

132 179

226 198 175 160 165 193 210 226 236 247 245 205 146

86

66

54

44

74

84

133 212 137

83

36

13

0

5

23

57

117 184

249 239 229 208 171 143 135 158 174 221 235 185 116

76

37

17

24

34

64

123 173 156

96

49

20

10

15

41

72

130 197

255 241 202 150 109

88

80

91

47

27

7

4

14

51

101 151 176 111

78

52

33

44

62

223 161 104

62

44

33

52

78

56

9

0

2

22

42

91

91

80

88

109 150 202 241 255

197 130

72

41

15

10

20

49

96

156 168 118

59

29

19

12

32

71

111 180 230 221 174 158 135 143 171 208 229 239 249

184 117

57

23

2

0

13

36

83

137 207 128

79

69

39

49

61

81

141 200 240 247 236 226 210 193 165 160 175 198 226

189 122

70

28

7

5

18

46

85

148 218 188 138 108

89

99

121 131 190 220 250 255 242 211 155 124 104

145

93

54

31

26

39

65

98

67

59

75

101 153 205 244 247 237 227 215 176 156 137 148 169 205 239 204 135

179 132

114 166 215 165

96

111 176 155 106

160 215 166 114

106 169 231 217 198 178 158 148 170 210 218 231 244 252 219 163 114

45

63

89

84

43

20

17

30

56

99

150

66

33

5

0

10

38

79

142

68

25

7

2

12

35

76

145 206

81

40

22

15

28

58

91

147 216

73

51

48

61

86

130 183 232

83

85

249 234 213 192 187 195 184 194 201 217 239 236 174 114

78

49

36

46

65

252 234 207 166 138 118 116 133 161 209 226 158

91

52

20

13

18

39

75

127 195 140

242 212 156 111

113 154 210 135

80

33

10

0

5

26

59

119 187 168 112

88

68

65

83

232 186 121

73

40

25

32

42

70

123 191 143

169 100

50

22

5

7

20

53

103 164 171 109

151

95

44

15

2

7

31

67

124 192 209 158 122 102

62

41

23

28

54

98

140 213 237 214 188 170 153 173 201

72

57

70

93

132 182 234 252 244 234

47

15

0

2

17

45

93

171 106

60

27

12

10

30

63

108 174 227 202 161 130 117 122 145 179 228 249

199 136

85

88

131 196 237 241 223 197 184 189

176 128

58

35

37

55

90

75

78

98

109 132 181 221

53

96

101 163 186 119

94

71

228 182 140 124 119 127 163 200 239 249 252 247 221 166 111

80

106 153 200 196 117

104 161 223

159 208 150 104

96

127 191

107 137 178 224 247

126 179 224 247 255

222 181 146 143 141 148 189 219 244 229 214 204 255

Figure 2.11: Assignment of thresholds to a 3 × 3 conglomerate of halftone cells with a screen angle of 15.4222 degrees and inverse frequency of 10.0277 pixels. deﬁned as lines per inch = √

resolution of printer (in dpi) , number of unique gray-levels − 1

(2.6)

where, in order to represent 256 gray-levels, the halftone cell needs to have at least 255 pixels, which corresponds to at least a 16 × 16 = 256 pixel halftone cell. For a 600 dots per inch printer, this corresponds to 600/16 = 37.5 cell lines per inch, but this is well within the visible range of human vision imparting a strong, periodic texture onto the

© 2008 by Taylor & Francis Group, LLC

2.3. SCREEN FREQUENCY

33

(a) 20 lpi

(b) 60 lpi

(c) 100 lpi

(d) 140 lpi

Figure 2.12: The eﬀects of varying screen frequency (lpi=lines per inch).

© 2008 by Taylor & Francis Group, LLC

CHAPTER 2. AM HALFTONING

34

Figure 2.13: Two examples of moir´e introduced by the interference between the halftone cells and the sampling grid. printed image. For reference, the best printing devices produce greater than 150 lines per inch – well above what the human visual system can detect at reasonable viewing distances of 10 inches or more. So a trade-oﬀ must be made between the number of unique gray-levels and the resulting screen frequency. In combination with irrational screen angles, high line frequencies can also be problematic due to the introduction of moir´e artifacts caused by the sampling grid as demonstrated in Fig. 2.13 (left), which shows the binary dither pattern representing 25% ink coverage for a screen angle of 10 rise pixels over 39 run pixels across 10 halftone cells. What is visible in Fig. 2.13 is a repeating beat pattern created by the ﬂuctuating cell shape. As a function of the ratio between the cell size variability and the average cell size, this moir´e pattern’s visibility is reduced by increasing the size of cells caused by reducing the screen frequency. Shown in Fig. 2.13 (right) is the equivalent binary dither pattern for an inverse screen frequency twice that of Fig. 2.13 (left), where the larger component cells create a less visible beat pattern having a smaller amplitude.

2.4

Supercells

In order to achieve high screen frequencies on moderate resolution devices, printer manufacturers will resort to halftone supercells that form

© 2008 by Taylor & Francis Group, LLC

2.5. ZERO-ANGLE DITHER ARRAYS

E

I

D F A

35

B H

G C

Figure 2.14: Ordering between sub-cells used to generate a 3 × 3 supercell. conglomerates of halftone sub-cells with consecutive threshold levels assigned across these sub-cells in a periodic or psuedo-random fashion. Speciﬁcally, the traditional technique of assigning a cost measure to each pixel inside a sub-cell is performed as it would be performed for a halftone cell in the prior technique in order to determine the order to which thresholds will be assigned in increasing order. But when assigning speciﬁc thresholds to pixels inside sub-cells, the construction algorithm will assign the ﬁrst threshold level inside sub-cell A, the second threshold inside sub-cell B, the third threshold into sub-cell C, and so on, until each sub-cell has been assigned its ﬁrst threshold. The construction algorithm will then start over, assigning a second threshold to each sub-cell, not necessarily in the same order as during the ﬁrst round. This process is then repeated until every pixel of every sub-cell is associated with a threshold level. The resulting dither array is then histogram equalized, resulting in an array composed of a uniform distribution of threshold levels spanning the range from 0 to 255 where each sub-cell has a uniform distribution but with N 2 the spacing. Using the sub-cell ordering in Fig. 2.14, Fig. 2.15 shows a halftone supercell where we have divided the cell into a 3 × 3 array of equally sized sub-cells.

2.5

Zero-Angle Dither Arrays

Finally, in the application of AM halftone screens in PostScript and other laser printers, manufacturers will minimize the computational

© 2008 by Taylor & Francis Group, LLC

CHAPTER 2. AM HALFTONING

36

241

162

103

172

231

245

166

107

176

235

182

83

44

73

152

240

161

102

171

230

186

88

48

78

157

123

24

4

34

93

181

82

43

72

151

127

28

9

38

97

132

54

14

63

201

121

23

3

33

92

137

58

19

68

206

211

192

113

142

221

131

53

13

62

200

216

196

117

147

225

251

243

164

105

174

233

210

190

112

141

220

255

237

159

100

169

228

184

85

46

76

154

250

242

163

104

173

232

178

80

40

70

149

125

26

7

36

95

183

84

45

74

153

119

21

1

31

90

135

56

16

66

204

124

25

5

35

94

129

50

11

60

198

213

194

115

144

223

134

55

15

65

202

208

188

109

139

218

253

239

160

101

170

229

212

193

114

143

222

247

244

165

106

175

234

179

81

42

71

150

252

236

158

98

167

227

185

86

47

77

155

120

22

2

32

91

177

79

39

69

148

126

27

8

37

96

130

51

12

61

199

118

20

0

30

89

136

57

18

67

205

209

189

111

140

219

128

49

10

59

197

215

195

116

146

224

248

207

187

108

138

217

254

246

Figure 2.15: Assignment of thresholds to a 3 × 3 supercell using the order of Fig. 2.14. complexity associated with screening even further by employing strictly square dither arrays, with no screen angle. As such, the mapping of the input image pixel [m, n] to the dither coordinate [r, s], within an R × R dither array, is achieved by means of a modulo operation r = mod(m, R), and s = mod(n, R).

(2.7) (2.8)

To achieve this goal while still creating halftone cells that mimic a desired screen angle and frequency, a new square dither array can be built from any rational angle halftone cell with a rise of dM pixels over a run of dN . In accordance with Fig. 2.16, the rational angle cell forms a periodic pattern of threshold arrays along both the horizontal and vertical axis, where the bottom left pixel of each period is dN cells along the x axis of the rotated space and −dM cells along the

© 2008 by Taylor & Francis Group, LLC

2.5. ZERO-ANGLE DITHER ARRAYS

ENCY

REQU

ENF SCRE

37

SCREENFREQUENCY

Figure 2.16: Alignment of a (left) rational angle halftone cell with a screen angle of 4 pixels raised to 16 pixels run to a (right) zero-angle dither array of size 16 cells by 16 cells. y axis. The resulting square dither array will have side lengths equal to the square of the inverse screen frequency, measured in pixels. The same is also true when dividing dM and dN by their greatest common denominator such that, in Fig. 2.16, a 16 × 4 shift in cells could also have been a 4 × 1, 8 × 2, or 12 × 3 shift. So, by extracting the square region from Fig. 2.16, it is only this one period that needs to be derived and stored in a printer’s memory. In most cases, this is the dither array that a PostScript printer will use in its default halftoning mode where no halftoning commands have been supplied by the user. Of course, for some screen angles and frequencies, the conglomerate dither array may be quite large, and for this reason, several commercial screen companies have developed sometimes complex tiling schemes involving the intertwining of two or more non-square, non-equal matrices [49] as, for example, depicted in Fig. 2.17.

© 2008 by Taylor & Francis Group, LLC

CHAPTER 2. AM HALFTONING

38

2 dN

2 dM dM+dN dN-dM

dM+dN

dN-dM

Figure 2.17: Tiling pattern used to represent a rational angle dither array with a dM -pixel rise across a dN -pixel run.

© 2008 by Taylor & Francis Group, LLC

Chapter 3 Stochastic Halftone Analysis Stochastic geometry is the area of mathematical research interested in complex geometrical patterns [115]. Some of the problems addressed in this ﬁeld include characterizing the growth of cells in a layer of organic tissue, calculating the average area covered by randomly placed discs of constant size and shape, and characterizing the location of individual trees within a forest [82]. This last problem is an example of a spatial point process [30], which is typically described using point process statistics–metrics developed to describe the location of points in space. While many of the statistics were developed for characterizing points in continuous-space, they are perfectly suited for the study of digital halftone patterns [66] such as those found in FM halftoning, where minority pixels are randomly distributed. In this chapter, we develop the theory of point process statistics and extend them to discrete-space for use in characterizing the spatial arrangement of minority pixels within a binary dither pattern. We will also discuss halftone visibility, showing how a model of the human visual system is used to measure the diﬀerences seen by a human viewer between an original continuous-tone image and a binary halftone.

3.1

Point Processes

The point process Φ is a stochastic model governing the location of events, or points xi , within the space 2 [25]. φ is a sample of Φ and will be written as φ = {xi ∈ 2 : i = 1, . . . , N }. Furthermore, φ(B) is a scalar quantity deﬁned as the number of xi s in the subset B of 39 © 2008 by Taylor & Francis Group, LLC

40

CHAPTER 3. STOCHASTIC HALFTONE ANALYSIS

q

\

xi

B q(B)=6 Figure 3.1: Diagram illustrating the point process Φ, a sample φ of the process, and the scalar quantity φ(B) as a function of the subset B of 2 . 2 . Figure 3.1 illustrates these concepts of a point process. We assume that the point process Φ is simple, meaning that i = j implies xi = xj , which further implies

lim φ(dVx ) =

dVx →0

1 0

for x ∈ φ else,

(3.1)

where dVx is the inﬁnitesimally small volume around x. In terms of a discrete dither pattern, Φ represents a stochastic halftoning process with Ig representing the binary dither pattern after applying Φ to a discrete-space monochrome image of constant gray-level g. In this framework, φ represents the set of minority pixels1 such that φ[n] = 1, for pixel index n, indicates a minority pixel at location n. From its deﬁnition in (3.1), φ(xi ) is a scalar random variable that can be characterized in terms of its moments. We start with the ﬁrst-order moment, the intensity I(x) E{φ(dVx )} . dVx →0 dVx

I(x) = lim

(3.2)

For a point process to be stationary, the statistical characteristics of Φ must be invariant to translation, and if a process is stationary, then 1 The pixel Ig [n] is a minority pixel if Ig [n] = 1 when 0 ≤ g < when 12 ≤ g ≤ 1.

© 2008 by Taylor & Francis Group, LLC

1 2

or Ig [n] = 0

3.1. POINT PROCESSES

41

the intensity is constant for all x ∈ 2 , where I(x) = I is the expected number of points per unit area. Returning to discrete-space, I[n] is related to the gray-level as

I[n] =

g 1−g

for 0 ≤ g < 12 for 12 ≤ g ≤ 1

(3.3)

and represents the unconditional probability that the sample at location n is a minority pixel. Additional insight into Φ can be gained by conditioning the probability distribution of Φ given that a point lies at a given location. The result is a conditional distribution referred to as the Palm distribution [115]. A particular measure under the Palm distribution of Φ is the quantity K(x; y) E{φ(dVx )|y ∈ φ} , dVx →0 E{φ(dVx )}

K(x; y) = lim

(3.4)

the ratio of the expected number of points in dVx under the condition y ∈ φ to the unconditional expected number of points in dVx . Referred to as the reduced second moment measure, K(x; y) may be thought of as the inﬂuence at location x of the point y. That is, is a point at x more or less likely to occur because a point exists at y? The value K(x; y) > 1 indicates that a point is more likely to occur while K(x; y) < 1 indicates that a point is less likely. For stationary processes, K(x; y) may be written as K(r, θ), where r is the distance between x and y while θ is the direction to x from y. For a point process to be isotropic, the statistical characteristics of Φ must be invariant to rotation; therefore, if Φ is also isotropic, then K(x; y) = K(r). In discrete-space, the reduced second moment measure is represented by K[n; m] such that K[n; m] =

E{φ[n]|φ[m] = 1} , E{φ[n]}

(3.5)

the ratio of the conditional expectation that sample n is a minority pixel given that sample m is a minority pixel to the unconditional expectation that n is a minority pixel. To estimate K[n; m] for a stationary point process from a given sample dither pattern, a set of regions of interest or windows surrounding each minority pixel within the dither pattern (Fig. 3.2) is extracted with these windows combined through addition in a pixel-wise fashion. Dividing each resulting pixel by the

© 2008 by Taylor & Francis Group, LLC

42

CHAPTER 3. STOCHASTIC HALFTONE ANALYSIS

undefined region

region of interest

minority pixel

Figure 3.2: A binary dither pattern used to estimate K[n; m] with minority pixels near the edges (light gray) of the pattern excluded from the estimate due to undeﬁned regions (dark gray) in their corresponding windows. ˆ m], with the total number of windows then creates the estimate K[n; center pixel representing the minority pixel m. Because minority pixels near edges of the dither pattern have windows with undeﬁned regions, these minority pixels are left out of the estimate. To illustrate the usefulness of K[n; m], Fig. 3.3 shows three 128 × 128 dither patterns taken from the point processes Φ1 , Φ2 , and Φ3 . Shown alongside each window is its corresponding reduced second moment measure estimate with the black pixel at each estimate’s center indicating the location of the reference minority pixel. In the ﬁrst example, pattern φ1 is a completely random point process with E{φ[n]|φ[m] = 1} = E{φ[n]} for all m and n, that is, the probability of any pixel n being a minority pixel independent of any other pixel, m. The result is a reduced second moment measure that is ﬂat (K1 [n; m] = 1) for all n and m. The second example, φ2 , referred to as a hard core process [115], is one in which there exists some distance r > 0 such that for no two points, o and p (where φ2 [o] = 1 and φ2 [p] = 1), is |o − p| < r. This property results in K2 [n; m] = 0 for |m−n| < r, where, in this instance, r = 3.45 pixels. The ﬁnal example, φ3 , is a clustering process, where the occurrence of a minority pixel at sample m increases the likelihood

© 2008 by Taylor & Francis Group, LLC

3.1. POINT PROCESSES

43

φ1

K1 [n; m]

φ2

K2 [n; m]

φ3

K3 [n; m]

Figure 3.3: The (left) sample patterns and the (right) corresponding reduced second moment measures for completely random, hard core, and clustering point processes.

© 2008 by Taylor & Francis Group, LLC

44

CHAPTER 3. STOCHASTIC HALFTONE ANALYSIS

Figure 3.4: The (left) annular rings with center radius r and radial width Δr used to extract the pair correlation R(r) from the reduced second moment measure K[n; m] and (right) the pixels, shown crosshatched, of K[n; m] that form the annular ring for r = 3 14 pixels and Δr = 12 pixels. of a minority pixel at sample n when |m−n| is small. How small |m−n| needs to be depends on the speciﬁc process, and the resulting K3 [n; m], in this case, is one in which K3 [n; m] > 1 for |m − n| < 3.64 pixels.

3.2

Spatial Statistics

From K[n; m], we can derive two spatial domain statistics by partitioning the spatial domain into a series of annular rings Ry (r) (Fig. 3.4 (left)) with center radius r, width Δr , and centered around pixel m. In this book, the annular ring Ry (r) will be the set {n : r − Δr /2 < |n − m| ≤ r + Δr /2}, where Δr = 1/2 pixels. Demonstrated in Fig. 3.4 (right) are the pixels of K[n; m] that form the annular ring for r = 3 14 pixels.

3.2.1

Pair Correlation

The ﬁrst statistic for stationary and isotropic Φ is the pair correlation R(r), deﬁned as E{φ(Ry (r))|y ∈ φ} R(r) = , (3.6) E{φ(Ry (r))}

© 2008 by Taylor & Francis Group, LLC

PAIR CORRELATION

3.2. SPATIAL STATISTICS

45

2

1

0

0

20

PAIR CORRELATION

RADIAL DISTANCE

2

1

0

0

3.45

20

PAIR CORRELATION

RADIAL DISTANCE

2

1

0

0

3.64

20 RADIAL DISTANCE

Figure 3.5: The pair correlations corresponding to the samples of the point processes (top) Φ1 , (middle) Φ2 , and (bottom) Φ3 .

the inﬂuence that the point at y has at any x in the annular ring Ry (r). Note that for a stationary point process, the unconditional expected number of points in the ring Ry (r) is I · N (Ry (r)) (the intensity times the area of Ry (r)). R(r) is also the average value of K(x; y) in the ring Ry (r), and its usefulness can be seen in the interpretation that maxima of R(r) indicate frequent occurrences of the inter-point distance r while minima of R(r) indicate an inhibition of points at r [115].

© 2008 by Taylor & Francis Group, LLC

46

CHAPTER 3. STOCHASTIC HALFTONE ANALYSIS

Figure 3.5 shows that the pair correlation is a strong indicator of the inter-point relationships for a given dither pattern. Referring back to the point processes Φ1 , Φ2 , and Φ3 of Fig. 3.3, Fig. 3.5 shows the resulting pair correlations for each process. Being a completely random point process, Φ1 has a pair correlation R(r) = 1 for all r, indicating no correlation between minority pixels. In the second example, Φ2 , R(r) = 0 for r < 3.45 is a consequence of the inhibition of points within a distance 3.45 of each other while in Φ3 , the frequent occurrence of the inter-point distances r < 3.64 is indicated by R(r) > 1 in these areas. But as R(r) clearly identiﬁes the clustering behavior of points in Φ3 , its makes no indication of the directional artifacts that occur along the diagonal. This occurs because R(r) assumes, by its deﬁnition, isotropy in Φ. The pair correlation may, therefore, be insuﬃcient, by itself, at describing binary dither patterns uniquely when patterns are allowed and even preferred to be anisotropic.

3.2.2

Directional Distribution Function

As a supplement to R(r) for characterizing stationary but not isotropic Φ, K[n; m] can be used to investigate anisotropy in Φ by deﬁning the directional distribution function Dr1 ,r2 (a) as Dr1 ,r2 (a) =

E {φ(Γam )|y ∈ φ} /N (Γam ) , E {φ(Γm )|y ∈ φ} /N (Γm )

(3.7)

the expected number of points per unit area in a segment, Γam , of the ring Γm = {n : r1 ≤ |n − m| < r2 , m ∈ φ} centered around the point m ∈ φ such that a ≤ (n − m) < a + Δa (Fig. 3.6) to the expected number of points per unit area in Γm itself. Note that for isotropic point patterns, Dr1 ,r2 (a) = 1.0 for all a, and that Dr1 ,r2 (a) > 1.0 indicates a favoring of points at angles near a while Dr1 ,r2 (a) < 1.0 indicates an inhibition of points. Furthermore, the parameters r1 and r2 allow us to look at point distributions for various ranges from a point m, most notably, a near distribution for the range r ∈ [0, r1 ), a far distribution for r ∈ [r1 , ∞), and an overall distribution for r ∈ [0, ∞). In Fig. 3.5, the directional distributions for the near range, r ∈ [0, 4.5), and the intermediate range, r ∈ [4.5, 8.0), are given for each process Φ1 , Φ2 , and Φ3 , with the near range indicated in light gray. The isotropic nature of Φ1 and Φ2 is clearly visible as Dr1 ,r2 (a) = 1 for all a in both ranges. The diagonal artifacts in Φ3 are also clearly visible with D0,4.5 (a) measuring the directional distribution of points within a

© 2008 by Taylor & Francis Group, LLC

3.3. SPECTRAL STATISTICS

K

47

K

Figure 3.6: The (left) division of the spatial ring Γm into the segment Γam and (right) the pixels, shown cross-hatched, of K[n; m] that form the segment for r1 = 2 pixels, r2 = 4 12 pixels, a = 2π , and Δa = 2π . 32 16 cluster and D4.5,8.0 (a) measuring the directional distribution of points relative to neighboring clusters.

3.3

Spectral Statistics

Spectral analysis of a point process was ﬁrst introduced to describe onedimensional processes by Bartlett [9] and then again by Bartlett [10] to study two-dimensional processes. While statistics have been developed based on Bartlett’s work [87], statisticians have relied almost entirely on spatial statistics, such as the pair correlation, due to the intuitive characterizations they oﬀer in describing spatial point processes. Within the signal processing community, though, spectral analysis is a commonly used tool for studying random processes. Spectral analysis was ﬁrst applied to stochastic dither patterns by Ulichney [123] to characterize dither patterns created via errordiﬀusion. To do so, Ulichney developed the radially averaged power spectra along with a measure of anisotropy. Both rely on estimating the power spectrum through Bartlett’s method of averaging periodograms, the magnitude-square of the Fourier transform of the output pattern divided by the sample size, to produce the spectral estimate Pˆ (f ) such

© 2008 by Taylor & Francis Group, LLC

48

CHAPTER 3. STOCHASTIC HALFTONE ANALYSIS / /2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

2

0

/ /2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

2

0

/ /2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

2

0

Figure 3.7: The directional distribution functions corresponding to the samples of the point processes (top) Φ1 , (middle) Φ2 , and (bottom) Φ3 for the near range, r ∈ [0, 4.5) (indicated by light-gray bars), and the intermediate range, r ∈ [4.5, 8.0) (indicated by dark-gray bars).

© 2008 by Taylor & Francis Group, LLC

3.3. SPECTRAL STATISTICS

49

Figure 3.8: The estimated power spectrums for point processes (left) Φ1 , (center) Φ2 , and (right) Φ3 with spectral components with high power shown in white. that

K 1 |DFT2D (φi )|2 Pˆ (f ) = , K i=1 N (φi )

(3.8)

where DFT2D (φ) represents the two-dimensional discrete Fourier transform of the sample φ, N (φ) is the total number of pixels in the sample φ, and K is the total number of periodograms being averaged to form the estimate. In this book, all estimates will be formed using 10 samples of size 256 × 256 pixels.

3.3.1

Radially Averaged Power Spectral Density

Although anisotropies of a dither pattern can be qualitatively observed by studying three-dimensional plots of Pˆ (f ) (Fig. 3.8), partitioning the spectral domain into a series of annular rings R(fρ ) of width Δρ leads to two useful one-dimensional statistics. The ﬁrst statistic is the radially averaged power spectrum density (RAPSD) P (fρ ), deﬁned for discrete Pˆ (f ) as the average power in the annular ring with center radius fρ P (fρ ) =

1 Pˆ (f ), N (R(fρ )) f ∈R(fρ )

(3.9)

where N (R(fρ )) is the number of frequency samples in R(fρ ). Given a rectangular sampling grid where the distances between samples along the horizontal and vertical axes are both equal to some distance D (Fig. 3.9 (left)), the spectral estimate Pˆ (f ) has a maximum horizontal/vertical frequency of (1/2)D−1 pixels per inch (Fig. 3.9 (right)).

© 2008 by Taylor & Francis Group, LLC

50

CHAPTER 3. STOCHASTIC HALFTONE ANALYSIS

Figure 3.9: The (left) sampling grid where the distances between samples along the horizontal and vertical axes are both equal to D and (right) the maximum frequencies are along the vertical and horizontal axes of the spectral estimate Pˆ (f ). √ −1 The maximum radial frequency is then ( – leading to partial √ 2/2)D −1 −1 spectral rings for (1/2)D < fρ ≤ ( 2/2)D as shown in Fig. 3.10 (left). For hexagonal sampling grids, the maximum radial is √ frequency −1 −1 (2/3)D with partial spectral rings in the range (1/ 3)D < fρ ≤ (2/3)D−1 as shown in Fig. 3.10 (right). As will be described in Chapter 8, this issue of partial annuli plays a signiﬁcant role in the generation of digital halftones for hexagonal sampling grids. And for this reason, the partial spectral rings are included in plots of P (fρ ) and will, in this book, be indicated along the horizontal axis. Returning to rectangular grids, Fig. 3.11 shows the RAPSDs of the point processes Φ1 , Φ2 , and Φ3 of Fig. 3.3. Pattern Φ1 , having no correlation between minority pixels, has a power spectrum that is ﬂat for all fρ . It is due to this spectrum, having equal amounts of all frequencies, that Φ1 is referred to as a white-noise process since white light contains equal amounts of all frequencies of the visible light spectrum. White-noise halftoning is accomplished by thresholding a continuous-tone input image with uniformly distributed, uncorrelated noise [123]. The strength of P (fρ ) for Φ1 , σg2 = g(1 − g), is equal to the variance of a single pixel, Ig [n], of the binary dither pattern treated as a random variable (a Bernoulli process [123]). The process Φ2 has a power spectrum that is composed almost exclusively of high-frequency noise. As blue light is the high-frequency

© 2008 by Taylor & Francis Group, LLC

3.3. SPECTRAL STATISTICS

51

PARTIAL ANNULI REGIONS LARGEST COMPLETE ANNULUS

fρ

fρ

0 Δ

1 2

1 2

fρ

0 Δ

1 2 3 3

fρ

Figure 3.10: The annular rings used to divide the power spectrum P (f ) to form P (fρ ) and A(fρ ) for a (left) rectangular and a (right) hexagonal sampling grid. component of the visible light spectrum, halftone patterns like φ2 are referred to as blue-noise dither patterns. Studied in great detail by Ulichney [123, 122], these patterns were originally created using errordiﬀusion, but due to the desirable attributes of blue-noise, several less computationally complex techniques have since been introduced. In Chapter 5, we review many of the beneﬁts of this model. The ﬁnal process, Φ3 , was ﬁrst referred to by Lau et al. [66] as a green-noise dither pattern due to its mid-frequency only content. While blue-noise has several advantages over green with respect to their visual appearances, the failure of some printers to print isolated dots reliably makes green-noise a reasonable alternative to blue. The speciﬁcs of this model are presented in Chapter 10. What Fig. 3.11 shows is that the three processes Φ1 , Φ2 , and Φ3 each have unique spectral characteristics. Using the RAPSD, we can identify these characteristics as, in fact, the RAPSD maintains an intimate link with the spatial domain’s pair correlation. In particular, a frequent occurrence of the inter-point distance r, indicated by maxima in R(r), implies a peak in P (fρ ) for radial frequency fρ = 1/r proportional in magnitude to the peak in R(r), meaning that a larger peak in R(r) leads to a larger peak in P (fρ ). A drawback of this relationship between P (fρ ) and R(r), though, is the failure of P (fρ ), like R(r), to

© 2008 by Taylor & Francis Group, LLC

CHAPTER 3. STOCHASTIC HALFTONE ANALYSIS

52

RAPSD (m2)

3

1 0

0

0.5

0.7071

0.5

0.7071

0.5

0.7071

RADIAL FREQUENCY

RAPSD (m2)

3

1 0

0 RADIAL FREQUENCY

RAPSD (m2)

3

1 0

0 RADIAL FREQUENCY

Figure 3.11: The RAPSDs corresponding to the point processes (top) Φ1 , (middle) Φ2 , and (bottom) Φ3 . identify directional artifacts.

3.3.2

Anisotropy

As a second statistic, introduced by Ulichney [123], is the anisotropy A(fρ ), which is deﬁned as

2 Pˆ (f ) − P (fρ ) 1 A(fρ ) = , N (R(fρ )) − 1 f ∈R(fρ ) P 2 (fρ )

© 2008 by Taylor & Francis Group, LLC

(3.10)

3.4. COLOR HALFTONING

53

the relative variance or the “noise-to-signal” ratio [123] of frequency samples of Pˆ (f ) in R(fρ ). Built on the premise that aperiodic patterns generated in areas of uniform gray are most pleasant when patterns are isotropic, A(fρ ), a measure of how isotropic a dither pattern is, implies that the pattern with lower anisotropy is the visually more pleasing of two if both patterns have identical P (fρ )s. To demonstrate, Fig. 3.12 shows the anisotropy measures in units of decibels (db) for the three point processes. Ulichney has shown that the anisotropy measure of a perfectly isotropic dither pattern is 1 ; therefore, as in the case of Fig. 3.12 and all subsequent plots A(fρ ), K 1 or −10 db should be considered “background noise” (indicated by a 10 dotted line) and not until A(fρ ) > 0 db should directional components be considered strong or noticeable to the human eye. In Fig. 3.12, Φ1 and Φ2 are isotropic while the diagonal artifacts of Φ3 are indicated, in A(fρ ), by strong components at fρ = 0.05, 0.25, and 0.35. Its purpose, to measure the strength of directional artifacts, A(fρ ), does not indicate the direction. It is therefore possible for a dither pattern with strong horizontal artifacts to be indistinguishable according to P (fρ ) and A(fρ ) from a pattern with strong diagonal artifacts. The human eye, being less sensitive to diagonal correlations, may ﬁnd the diﬀerence in appearance far from indistinguishable – making the metrics P (fρ ) and A(fρ ) insuﬃcient, by themselves, at describing anisotropic dither patterns uniquely. We therefore combine all four metrics to oﬀer a more complete description of a stochastic halftone pattern than previously oﬀered.

3.4

Color Halftoning

In understanding the process of color reproduction, it is important to have an understanding of the human visual system and how the eye sees color. Detailed descriptions of this material can be found in Hunt [48], while the following is a brief description of the important aspects of color reproduction.

3.4.1

RGB

Human color vision begins in the eye, where, within the retina, there are two types of light sensitive cells (photo-receptors) responsible for vision. Named for their shapes, these cells are either rods or cones. The rods

© 2008 by Taylor & Francis Group, LLC

CHAPTER 3. STOCHASTIC HALFTONE ANALYSIS

ANISOTROPY

54

10 0 ï10 0

0.5

0.7071

0.5

0.7071

0.5

0.7071

ANISOTROPY

RADIAL FREQUENCY

10 0 ï10 0

ANISOTROPY

RADIAL FREQUENCY

10 0 ï10 0 RADIAL FREQUENCY

Figure 3.12: The anisotropies corresponding to the point processes (top) Φ1 , (middle) Φ2 , and (bottom) Φ3 . are in much higher abundance (125 million versus 7 million) and are responsible for detecting light intensities at low levels of illumination (colorless night vision). The cones are responsible for color vision and can be divided into three subsets: (i) red, (ii) green, and (iii) blue. Shown in Fig. 3.13 are estimates of the relative sensitivity for each subset of cones versus the wavelength of incoming light. The blue cones derive their name from the fact that they are the most sensitive, of the three, to blue light (λ ≈ 440 nm) while green cones are most sensitive to green light (λ ≈ 510 nm) and red most sensitive to red

© 2008 by Taylor & Francis Group, LLC

3.4. COLOR HALFTONING

55

h

h

b

h

g

r

`(h) l(h)

a(h)

h

Figure 3.13: Approximations to the relative sensitivity for the red (ρ(λ)), green (γ(λ)), and blue (β(λ)) cones versus wavelength. light (λ ≈ 650 nm). When the incoming light is focused onto the retina by the eye lens, the light is transformed by the rods and cones into nerve impulses that are sent, via the optic nerve, to and interpreted by the brain. Colors are interpreted by the brain as the sum total of the three cone responses. For a mathematical framework, C will be the continuous vector representing the composition of incoming light, where C(λ) is the strength of light with wavelength λ such that 0 ≤ C(λ) ≤ 1. A special case of C is white light (C = W), where C(λ) = 1 for all λ. Given the relative sensitivity curves, β(λ), γ(λ), and ρ(λ), the cone response to incoming light, C, will be the three-dimensional vector c such that ⎡

⎤

βC ⎥ c = ⎢ ⎣ γC ⎦ , ρC where

(3.11)

βC = γC = ρC =

© 2008 by Taylor & Francis Group, LLC

β(λ)C(λ) dλ,

(3.12)

γ(λ)C(λ) dλ,

(3.13)

ρ(λ)C(λ) dλ,

(3.14)

λ λ λ

56

CHAPTER 3. STOCHASTIC HALFTONE ANALYSIS

are the responses of each subset of cones to the incoming light C. In theory, the brain can be fooled into seeing any color by a linear combination of just the three colors red (R such that R(λ) = 1 for λ = λr , 0 else), green (G such that G(λ) = 1 for λ = λg , 0 else), and blue (B such that B(λ) = 1 for λ = λb , 0 else).2 That is, given the color C with cone response c, an equivalent response can be generated from a linear combination of R, G, and B such that c = rR + gG + bB ⎡ ⎤⎡ ⎤ βR βG βB r ⎥⎢ ⎥ = ⎢ ⎣ γR γG γB ⎦ ⎣ g ⎦ , b ρR ρG ρB where

⎡

⎤

⎡

⎤−1 ⎡

r βR βG βB ⎢ ⎥ ⎢ ⎥ ⎣ g ⎦ = ⎣ γR γG γB ⎦ b ρR ρG ρB

(3.15)

⎤

βC ⎢ ⎥ ⎣ γC ⎦ ρC

(3.16)

is the tri-stimulus RGB value of the color C. Color Triangle Shown in Fig. 3.14 are the r, g, and b values plotted versus λ corresponding to the tri-stimulus values for imitating the cone responses when the incoming light is composed exclusively of the single wavelength λ with unit strength. The curves here have each been scaled separately such that colorless white light is composed of equal amounts of each component (r = g = b). In order to obtain a perfect match between the incoming light and the combination of red, green, and blue light, negative values of r, g, or b in Fig. 3.14 are interpreted as adding an equivalent amount of that component to the incoming light. The data of Fig. 3.14 are also shown in Fig. 3.15, where the tri-stimulus values for each wavelength are shown in three dimensions. As a linear combination of R, G, and B components, increasing the strength of the incoming light by a factor of k increases the tristimulus values such that k c = krR + kgG + kbB.

(3.17)

2 The exact values of λr , λg , and λb depend on the speciﬁc light sources for each color component and will, therefore, be left in general terms.

© 2008 by Taylor & Francis Group, LLC

3.4. COLOR HALFTONING

57

g(h) r(h)

b(h)

h

Figure 3.14: The r, g, and b values versus λ for imitating the cone responses when the incoming light is composed exclusively of the single wavelength λ with unit strength.

0.4 470 0.3 485 400

BLUE

0.2

500 0.1

650 620

0

530 590 560

ï0.1 ï0.1

ï0.1 0

0 0.1

0.1 0.2

0.2 0.3

0.3 0.4

0.4

RED

GREEN

Figure 3.15: The r, g, and b values for imitating the cone responses when the incoming light is composed exclusively of the single wavelength λ with unit strength.

© 2008 by Taylor & Francis Group, LLC

58

CHAPTER 3. STOCHASTIC HALFTONE ANALYSIS

0.4

0.3 k=1

BLUE

0.2

k=0

0.1 k=2 0

ï0.1 ï0.1

ï0.1 0

0 0.1

0.1 0.2

0.2 0.3

0.3 0.4

0.4

RED

GREEN

Figure 3.16: Varying the parameter k is equivalent to moving along a line, projected from the origin, through some point c (indicated by k = 1).

In three dimensions, varying the parameter k is equivalent to moving along a line projected from the origin through the point c (Fig. 3.16). The color c can, therefore, be identiﬁed uniquely by the tri-stimulus values

r˜ = r/(r + b + g), g˜ = g/(r + b + g), and ˜b = b/(r + b + g).

(3.18) (3.19) (3.20)

Geometrically, this new point is obtained by projecting, from the origin, the point c onto the plane r + g + b = 1 (Fig. 3.17). Doing so creates the RGB (red, green, blue) color triangle of Fig. 3.18, where each color of the visual spectrum is plotted versus r˜ and g˜. The third component, ˜b, is obtained as 1 − r˜ − g˜. Indicated by the triangle in Fig. 3.15 is the color gamut or the set of obtainable colors achieved by adding positive amounts of R, G, and B. Colors outside this gamut, which require negative amounts of either component, cannot be imitated.

© 2008 by Taylor & Francis Group, LLC

3.4. COLOR HALFTONING

59

400 470 1.2 485

1

BLUE

0.8

495

0.6 0.4 0.2 650

0

590

530

560

ï0.2 0

0 0.5

0.5 1

1 RED

GREEN

Figure 3.17: Projecting, from the origin, the point c onto the plane r + g + b = 1 creates a two-dimensional mapping of all colors of the visible light spectrum.

3.4.2

CMY

The system of colors formed by combining light (Fig. 3.16) of colors red, green, and blue is referred to as an additive system with the colors R, G, and B referred to as the additive primaries. In digital printing, white paper reﬂects all wavelengths of the incident light. Assuming the incident light is white, combining the inks of cyan, magenta, and yellow, can imitate any color by taking away particular wavelengths from this incident light. This system is referred to as a subtractive system with cyan, magenta and yellow the subtractive primaries. The reason for using cyan (Cn ), magenta (M), and yellow (Y) is that they are the complement colors to red, green, and blue such that, ideally Cn = W − R, M = W − G, Y = W − B,

(3.21) (3.22) (3.23)

where the tri-stimulus CMY values are derived from the RGB values as cn = 1 − r,

© 2008 by Taylor & Francis Group, LLC

(3.24)

CHAPTER 3. STOCHASTIC HALFTONE ANALYSIS

60

G

530

560 495

485

W

590

470

R B Figure 3.18: The RGB color triangle. m = 1 − g, y = 1 − b.

(3.25) (3.26)

We say “ideally” because we are assuming that our inks are the exact complements to red, green, and blue. So by printing cyan ink, we take away, from the incident light, a proportional amount of red light.

3.4.3

CMYK

The color black (K) is, in the ideal case, obtained by combining equal amounts of Cn , M, and Y. As inks are never the perfect complement to R, G, and B, perfect black cannot be obtained. So, by adding a fourth ink, black, to cyan, magenta, and yellow, we obtain the set of

© 2008 by Taylor & Francis Group, LLC

3.4. COLOR HALFTONING

61

process colors CMYK where the conversion from CMY to CMYK is done (in the ideal case) as k = cn,new = mnew = ynew =

min(cn,old , mold , yold ), cn,old − k, mold − k, yold − k.

(3.27) (3.28) (3.29) (3.30)

The exact conversion is dependent on the exact RGB values of each ink. The reader is directed to Hunt [48] for further details. By using this fourth component, printers can produce images with greater contrast and less expense (ﬁnancially) as black inks are less expensive than combining the three inks cyan, magenta, and yellow to form black [24].

3.4.4

Color Statistics

In the case of a color halftone, the monochrome model Ig that must be revised as a dither pattern is now composed of C colors, where, for generality, the quantity C is an arbitrary integer. For RGB and CMYK, where images are composed of the additive colors red, green, and blue or the process colors cyan, magenta, yellow, and black, C = 3 and 4, respectively. So for color images, the halftone pattern Ig is now composed of the monochrome binary dither patterns Ig1 , Ig2 , . . . , IgC , where gi is the gray-level of pattern Igi and φi is the corresponding point process. In this new framework, the quantity Ki,j [n; m] is the reduced second moment measure between colors such that Ki,j [n; m] =

E{φgi [n] | φgj [m] = 1} E{φgi [n]}

(3.31)

is the ratio of the conditional probability that φgi [n] is a minority pixel given that a minority pixel exists at sample m of φgj to the unconditional probability that φgi [n] is a minority pixel [67]. Similar to K[n; m], Ki,j [n; m] = 1 indicates that the locations of minority pixels in colors i and j are uncorrelated. The pair correlation between colors gi and gj follows as E{φgi (Rm (r)) | φgj [m] = 1} Ri,j (r) = , (3.32) E{φgi (Rm (r))}

© 2008 by Taylor & Francis Group, LLC

62

CHAPTER 3. STOCHASTIC HALFTONE ANALYSIS

the ratio of the expected number of minority pixels of color gi located in the ring Rm (r) = {n : r < |n − m| ≤ r + dr} under the condition that φgj [m] is a minority pixel to the unconditional expected number of minority pixels with color gi located in Rm (r).

© 2008 by Taylor & Francis Group, LLC

Chapter 4 Halftone Visibility When reproducing continuous-tone images, halftone visibility refers to the visibility or “notice-ability” of the binary dots when viewing the printed image. The ideal halftoning algorithm is the one that minimizes this visibility. Halftone visibility metrics that give it a scalar cost have, therefore, been employed for comparative studies between halftoning algorithms [22, 81], and in some cases [5, 90] they have even been employed within the halftoning algorithm to decide where and where not to print a dot. Because the eye sees distortions at particular spatial frequencies more so than at others, developing a halftone visibility metric begins with a model of the human visual system (HVS). Having a model of the HVS allows us to measure the distortion seen by a human viewer when representing a continuous-tone image with black and white dots. The distortion as seen by a human viewer between an original continuous-tone image, X, and its binary halftone, Y , is calculated as the mean squared error between the HVS ﬁltered images X and Y (Fig. 4.1). As a demonstration, Fig. 4.2 shows the modeled visual response to the point process samples Φ1 , Φ2 , and Φ3 , where, for this particular HVS model, the visual costs compared to an image composed of a ﬂat shade of gray are 0.0022, 0.0003, and 0.0134 respectively – indicating that Φ2 creates the most accurate illusion of the continuous shade of gray. Relatively simple models of the HVS have proven to be quite successful when applied to algorithms that search for the best possible dot distribution. Digital halftoning techniques including screening algorithms, error-diﬀusion algorithms, and iterative halftoning methods all use, either implicitly or explicitly, a model of the human visual system. In fact, even those methods that are not classiﬁed as model-based, 63 © 2008 by Taylor & Francis Group, LLC

CHAPTER 4. HALFTONE VISIBILITY

64

HVS +

Σ

X

−

Y H

| |2

E

HVS

Figure 4.1: The distortion introduced by halftoning is measured as the mean squared error between the HVS ﬁltered input image, X, and its corresponding HVS ﬁltered halftoned image, Y . because they do not include an explicit HVS block within their block diagram (for example, Bayer’s dither [11]), nevertheless agree with a model that treats the HVS as a low-pass ﬁlter. And not only is a HVS model crucial for the design of almost every halftoning technique, but the shape of the HVS model can also be tuned to yield better texture quality in the obtained dither patterns. Thus, the performance of a given halftoning algorithm can be maximized by properly designing improved HVS models. The selection of HVS models used in digital halftoning leads to diﬀerent output performance, in terms of smoothness, homogeneity, coarseness, and in the appearance of artifacts. One of the objectives in designing an HVS model is to quantify these diﬀerences. In particular, one can look at how the bandwidth and tail characteristics of a particular HVS model aﬀect spectral metrics like the radially averaged power spectral density (described in Chapter 3) of the resulting dither patterns. As such, HVS models have been proposed to oﬀer a quantitative measure of image distortion as seen by a human viewer. In this regard of measuring halftone texture, an HVS model is a linear shift invariant ﬁlter based on the point spread function (PSF) or the contrast sensitivity function (CSF) of the human eye. When the HVS model is proposed based on the eye’s response to stimuli in the spatial domain, the function obtained is the PSF and is derived by the fact that, as stated by Whesteimer [133], under no circumstances are point objects ever actually imaged as points because of several physical and geometrical optical factors. As a result, a point object gives rise to a retinal light distribution that is bell-shaped in cross-section. This distribution is precisely the PSF of the eye and has signiﬁcance not only when the object is a point but whenever it

© 2008 by Taylor & Francis Group, LLC

65

Figure 4.2: The point processes (top) Φ1 , (middle) Φ2 , and (bottom) Φ3 as seen by a human viewer for a given HVS model. is necessary to know the light distribution for a target more complex than a point source of light, since any visual object can be thought of as made up of points. The experimental determination of the eye’s PSF is carried out with the use of instruments designed to measure the entire refractive error of the eye, called “wavefront sensors” or “aberrometers.” Now in the frequency domain, an HVS model is based upon the modulation transfer function (MTF) or the CSF of the human eye, which attempts to characterize a subject’s responsiveness to particular spatial frequencies. As illustrated in Fig. 4.3, associated experiments consist of a sinusoidal grating where the modulation or contrast of the grating can be measured as the ratio between the diﬀerence of the maximum and minimum amounts of light reﬂected by the grating to the sum of the two. The frequency of the grating is varied from lower to higher frequencies in each experiment. For equally spaced particular

© 2008 by Taylor & Francis Group, LLC

CHAPTER 4. HALFTONE VISIBILITY

66

VIEWING ANGLE

1 CYCLE

VIEWING DISTANCE EYE GRATING

Figure 4.3: A sinusoidal grating placed at varying distances from the human eye. frequencies, a subjective measure of the contrast sensed by the human viewer is taken, and the ratio between the real contrast of the image and the contrast resolved by the viewer is used as the contrast sensitivity of the eye for that exact frequency. The sensitivity of the eye is high (near unity) for low frequencies, but as the frequency is increased, the eye starts to fail in detecting the real contrast of the grating, and the sensitivity decays to zero. Taken together, the PSF and the CSF form a Fourier pair, denoted h(x, y) (x, y in inches) in the spatial domain and H(u, v) (u, v in cycles/degree) in the frequency domain. The inverse Fourier transform ¯ x, y¯), with x¯, y¯ in degrees. To convert these anguof H(u, v) yields h(¯ lar units to units on the printed page, notice that a length of x inches when viewed at a distance D inches will subtend an angle of x¯ degrees satisfying x¯ = (180/π)(arctan(x/D)) ≈ (180x)/(πD) (4.1) for x D. Therefore, assuming a printer with resolution R (in dots per inch, dpi), the discrete ﬁlter characterizing the HVS model in the spatial domain will be given by

1802 ¯ 180m 180n h [m, n] = 2 2 h , . π D πRD πRD

(4.2)

The term S ≡ RD in (4.2) is called the scale parameter. Kim and Allebach [54] experimented with diﬀerent values of S in HVS models, as part of their research with direct binary search (an iterative halftoning algorithm described in Chapter 7) and demonstrated why this parameter, which in theory should be determined precisely by the intended viewing distance and printer resolution, in reality serves more as a free

© 2008 by Taylor & Francis Group, LLC

4.1. CAMPBELL’S CSF MODEL

67

Figure 4.4: The contrast sensitivity function of the human visual system. parameter that can be adjusted to yield halftone textures of the desired quality. The behavior of the scale parameter is such that, when the distance or print resolution is increased, the viewer’s visual response sensitivity is reduced by a ﬁxed amount of cycles per degree; therefore, the bandwidth of the HVS ﬁlter in the frequency domain is decreased by an amount proportional to the distance (or resolution) increase. In this scenario, if the viewer observes a printed page from a greater distance, or if the resolution is larger, it is expected that the eye will perceive a better overall impression of the image at the expense of losing the ability to discern the details of the printed dots on the page. That is, the image will appear to the viewer as being more homogeneous. The contrary eﬀect occurs if the distance or the resolution is decreased with the HVS bandwidth increasing and the halftone textures becoming more apparent.

4.1

Campbell’s CSF Model

From the experiments of Fig. 4.3, Campbell et al. [17] proposed modeling the contrast sensitivity function using the one-dimensional equation CSF (fρ ) = k (exp(−2πfρ α) − exp(−2πfρ β))

(4.3)

plotted in Fig. 4.4, where α and β are arbitrary constants, later set by Analoui and Allebach [5] to 0.012 and 0.046, respectively. The parameter k is a constant proportional to the average illumination and is typically set such that maxfρ CSF (fρ ) = 1 (at fρ = fmax = ln(α/β)/[2π(α − β)]). The drop in sensitivity, proposed by this model

© 2008 by Taylor & Francis Group, LLC

CHAPTER 4. HALFTONE VISIBILITY

68

Figure 4.5: The two-dimensional contrast sensitivity function CSF2D (fρ , fθ ) of the human visual system that accounts for the reduced sensitivity of the eye along the diagonal. near DC, corresponds with a sinusoidal grating changing so slowly as to have an imperceptible gradient. For halftoning purposes, this drop is usually ignored with the CSF modeled by CSF (fρ ) deﬁned as

CSF (fρ ) =

CSF (fρ ) , CSF (fmax )

for fρ ≥ fmax

1, else,

(4.4)

which mimics the prior equation in the high-frequency range. Under the assumption that the human visual system is not isotropic, the orientation of the grating should play a role in the sensitivity of the eye to its sinusoidal frequency [18], namely, near odd multiples of 45 degrees. It has been hypothesized that this reduced sensitivity is a consequence of our adaptation to the predominantly horizontal and vertical structures in the natural and man-made worlds. Regardless, a two-dimensional model proposed by Daly [27] of the HVS that describes less sensitivity along diagonals is shown in Fig. 4.5 and is deﬁned by the equation CSF2D (fρ , fθ ) = CSF (

fρ ), 0.15 cos(4fθ ) + 1.35

(4.5)

where fθ is the angle in the spectral plane from the positive horizontal axis to the polar coordinate (fρ , fθ ). Now in contrast to the theory of reduced sensitivity along the diagonals, Allebach [2] reports that, in his own work with direct binary

© 2008 by Taylor & Francis Group, LLC

¨ ANEN ¨ 4.2. NAS (EXPONENTIAL) MODEL

69

search, this practice results in a diagonal texture structure that is undesirably visible. Similar results were reported by Lau and Ulichney [73], who found diagonal correlations problematic at gray-levels near 12 in error-diﬀused halftones, an issue to be discussed in Chapter 8. These observations agree with visual studies that theorize that the reduced 45 degrees sensitivity is based upon visual evaluations where the subject was presented with a single-frequency sinusoidal grating. Mullen [88] goes further and demonstrates that the near-DC behavior of (4.4) is invalid because, in the associated experiments, only a very small number of sinusoidal wave periods were displayed to the viewers at the lowest frequencies. And a number of bars below four or ﬁve is known to reduce sensitivity to these kinds of gratings. As such, it is expected that these models are inadequate in representing the HVS near DC. As such, there is no visual masking where certain spatial frequencies block the HVS’s ability to see other frequencies. In fact, no visual model has been developed that fully explains the HVS’s response to all possible stimuli. Clearly, the HVS is low-pass in nature, but the CSF model does not characterize the HVS completely as it is seen in halftoning.

4.2

N¨ as¨ anen (Exponential) Model

As an alternative model of the human visual system that assumes radial symmetry, the N¨as¨anen model, demonstrated in Fig. 4.6, is a radially symmetric exponential function of the radial frequency, ρ, that has been used extensively in the context of digital halftoning. This model is deﬁned as H (ρ) = exp (−kρ) k 1 h (r) = , 2 (2π) k + r2 3/2

(4.6) (4.7)

2π

where L = 11cd/m2 is the average luminance, and c = 0.525 and d = 3.91 are constants that make the model ﬁt the experimental data [91]. Shown in Fig. 4.7 (top) is a plot of the tail of the frequency response of the N¨as¨anen low-pass model that, due to its radially symmetric shape, is only shown along the diagonal cross-section of the two-dimensional CSF. For this and the following HVS models, Fig. 4.7 shows each model using a scale factor S = RD = 300 dpi × 9.5 in. The logarithmic view of the N¨as¨anen ﬁlter in Fig. 4.7 (bottom) shows the tails decaying

© 2008 by Taylor & Francis Group, LLC

CHAPTER 4. HALFTONE VISIBILITY

70

Figure 4.6: An (left) error-diﬀused halftone image and (right) its corresponding modeled HVS response using the N¨as¨anen exponential model. −3 linearly down √ to approximately 10 at the maximum radial frequency of ρ = 1/ 2. Deﬁning a ﬁlter’s bandwidth as the frequency at which the ﬁlter has decayed to 50% of its maximum amplitude, the N¨as¨anen ﬁlter has a bandwidth of 0.078.

4.3

Mixed Gaussian Models

Although the N¨as¨anen model has proven to be an adequate approximation to the HVS model for iterative halftoning methods like direct binary search, Kim and Allebach [54] proposed a new and richer class of HVS models that oﬀer better halftoning results. These models are based on mixed Gaussian functions whose functional form is

H 2 (ρ) = 2πκ1 σ12 exp −2π 2 σ12 ρ2 + . . .

. . . + 2πκ2 σ22 exp −2π 2 σ22 ρ2

(h ∗ h) (r) = κ1 exp −

© 2008 by Taylor & Francis Group, LLC

r2 2σ12

+ κ2 exp −

r2 , 2σ22

(4.8) (4.9)

4.3. MIXED GAUSSIAN MODELS

71

0.12

0.10

0.08

0.06 Nasanen Mixed Gaussian 1

0.04

0.02

Subgaussian Subgaussian 2

0

Mixed Gaussian 2 1/3

1/2

1/sqrt(2)

RADIAL FREQUENCY 10 0

Mixed Gaussian 1 10 −1

Subgaussian 10 −2 Subgaussian 2 Nasanen Mixed Gaussian 2 10 −3 0

1/2

1/sqrt(2)

RADIAL FREQUENCY

Figure 4.7: Frequency response of N¨as¨anen, mixed Gaussian, and α-SG ﬁlters (top) and their logarithmic view (bottom). where ∗ denotes convolution and the constants κ1 , κ2 , σ1 , and σ2 are determined experimentally. The advantage of these models is that their frequency response in terms of bandwidth and tail weight can be optimized by varying a set of parameters. Such ﬂexibility is not available in the N¨as¨anen exponential model. The diversity attained with mixed Gaussians, however, comes at a penalty: overparametrization. A total of four parameters characterize this model, making the tuning process a rather delicate task. Kim and Allebach could not ﬁnd one single model for direct binary search that worked best for

© 2008 by Taylor & Francis Group, LLC

CHAPTER 4. HALFTONE VISIBILITY

72

Figure 4.8: The modeled HVS responses using the mixed Gaussian models with parameters (left) (κ1 , κ2 , σ1 , σ2 ) = (43.2, 38.7, 0.02, 0.06) and (right) (19.1, 42.7.0.03, 0.06). all tones; therefore, they suggested the use of two diﬀerent Gaussian models that complement each other. The 1st mode has parameters (κ1 , κ2 , σ1 , σ2 ) = (43.2, 38.7, 0.02, 0.06) producing smooth textures but with checkerboard artifacts. Alternately, the 2nd model has parameters (κ1 , κ2 , σ1 , σ2 ) = (19.1, 42.7.0.03, 0.06) and produces a more homogeneous texture, especially in the midtone areas, that is, however, rougher than the previous. Shown in Fig. 4.7 are plots of the spatial and spectral cross-sections of these two parameter sets along with the modeled HVS responses in Fig. 4.8.

4.4

Alpha-Stable HVS Models

The use of alpha-stable functions for HVS modeling was introduced by Gonzalez et al. [45] using the functions for describing alpha-stable random variables [7]. These models are richer than mixed Gaussian models (Gaussian random variables are a sub-family of alpha-stable random variables) and are simpler to characterize having fewer parameters. No-

© 2008 by Taylor & Francis Group, LLC

4.4. ALPHA-STABLE HVS MODELS

73

tably, empirical approximations to the PSF (obtained by measuring the response of the eye to spatial stimuli) were found to have the analytical form of the characteristic function of alpha-stable random variables [133]. Thus, stable models ﬁt well with empirical measurements and, at the same time, oﬀer unique mathematical characteristics that ultimately render visually pleasant halftones. As mentioned before, the work of Whesteimer [133] models the shape of the PSF according to

h(r) = 0.952 exp −2.59 |r|1.36 + 0.048 exp −2.43 |r|1.74 ,

(4.10)

which is close in form to the characteristic function of the alpha-stable distributions. If the PSF of the HVS model has the form of (4.10), its CSF will have algebraic tails [7], hence it might be a good idea to use models whose tails are heavier than those obtained with exponential and mixed Gaussian models. This fact provides the physiological foundation for the use of alpha-stable models to characterize the HVS. Stable distributions describe a rich class of processes that allow heavy tails and skewness in their functions [7]. The class was characterized by L´evy in 1925 [77] and is described by four parameters: an index of stability, α ∈ (0, 2]; a dispersion parameter, γ > 0; a skewness parameter, δ ∈ [−1, 1]; and a location parameter, β ∈ R. The stability parameter α measures the thickness of the tails of the distribution and provides this model with the ﬂexibility needed to characterize a wide range of impulsive processes. The dispersion γ is similar to the variance of the Gaussian distribution. When the skewness parameter is set to δ = 0, the stable distribution is symmetric about the location parameter β. Symmetric stable processes are also referred to as symmetric alpha-stable or simply SαS. In HVS modeling, bivariate SαS distributions are used for characterization, focusing on their subclass, the so-called alpha-sub-Gaussian (α-SG(R)) random vectors [16], whose characteristic function is of the form

1 T α/2 φ(t) = exp − t Rt , (4.11) 2 where t = [x, y]T is a two-dimensional column vector and the matrix R is positive deﬁnite. This characteristic function is used to model the PSF of the HVS, where, in order to guarantee radial symmetry for the ﬁlters, the matrix R is of the form

R=

© 2008 by Taylor & Francis Group, LLC

γ 0 0 γ

,

(4.12)

CHAPTER 4. HALFTONE VISIBILITY

74

Hrholog

10

10

0

−1

alpha 0.95 alpha 1.05

10

alpha 1.15

−2

alpha 1.25 -1/sqrt(2)

-1/2

0

1/2

1/sqrt(2)

RADIAL FREQUENCY

Figure 4.9: Logarithmic view of the frequency response of α-SG ﬁlters. where γ > 0 is the dispersion parameter for the model. With this form of the matrix R and expanding the index of the exponential, the PSF in (4.11) becomes

α/2 1 φ(x, y) = exp − γ α/2 x2 + y 2 . 2

(4.13)

To simplify (4.13) further, the rectangular coordinates can be converted to polar, resulting in

1 φ(r) = exp − γ α/2 rα 2

for r ≥ 0,

(4.14)

with r2 = x2 + y 2 and where α ∈ (0, 2] is the index of stability that determines the heaviness of the model’s tails. For simplicity in the notation, the term 21 γ α/2 in (4.14) is replaced by only one term, which is called γ . Figure 4.9 shows the CSF of alpha-sub-Gaussian HVS models with diﬀerent values of α. The CSF of these models is obtained by sampling the PSF in (4.14), truncating it, and ﬁnding its inverse discrete Fourier transform (IDFT), a procedure that carries no computational burden. Notice that this approximation, based on the IDFT, could not be applied if an alpha-stable probability density function were being sought.

© 2008 by Taylor & Francis Group, LLC

4.4. ALPHA-STABLE HVS MODELS

75

Figure 4.10: The modeled HVS responses using sub-Gaussian models with parameters γ = 27, D = 9.5 in, R = 300 dpi and (left) α = 0.95 or (right) α = 1.05. In alpha-stable models, the parameter γ (as well as the scale parameter S = RD) determines the bandwidth of the ﬁlter and consequently the homogeneity of the halftones. The parameter α controls the heaviness of the tails of the ﬁlter and, hence, the smoothness/coarseness of the dither patterns. Gonzalez et al. [45] found experimentally that a model with a bandwidth around 0.08 produced the homogeneity they sought. They also found that a good point to start, in terms of heaviness of tails, is to have an initial model that satisﬁes H(ρ)|ρ=1/√2 ≈ 10−2 . In the end, they proposed the two models shown in Fig. 4.7, where the starting model is labeled as “α-SG, α = 0.95.” It was generated with constants α = 0.95, γ = 27, D = 9.5 in, and R = 300 dpi. The initial size of the model was N = 101; although, it was possible to truncate it further to obtain a ﬁnal N = 31. From various visual studies relating to halftoning, a second rectiﬁed ﬁlter, plotted in Fig. 4.7 and labeled as “α-SG, α = 1.05,” was found by setting α = 1.05. Both of these ﬁlters are demonstrated in Fig. 4.10.

© 2008 by Taylor & Francis Group, LLC

Chapter 5 Blue-Noise Dithering Blue-noise halftoning, demonstrated in Fig. 5.1, is characterized by a distribution of binary pixels where the minority pixels are spread as homogeneously as possible [123]. Distributing pixels in this manner creates a pattern that is aperiodic, isotropic (radially symmetric) and does not contain any low-frequency spectral components. From our understanding of the human visual system (Chapter 4), it’s not surprising that blue-noise creates the visually optimal arrangement of dots. Halftoning a continuous-tone, discrete-space, monochrome image with blue-noise produces a pattern that, as Ulichney [123] describes, is visually “pleasant” and “does not clash with the structure of an image by adding one of its own, or degrade it by being too ‘noisy’ or uncorrelated.”

5.1

Spatial and Spectral Characteristics

Blue-noise, when applied to an image of constant gray-level g, spreads the minority pixels of the resulting binary image as homogeneously as possible, as shown in Fig. 5.2, such that the pixels are separated by an average distance λb

λb =

√ D/ √ g, for 0 < g ≤ 1/2 D/ 1 − g, for 1/2 < g ≤ 1,

(5.1)

where D is the minimum distance between addressable points on the display. The parameter λb is referred to as the principal wavelength of blue-noise, with its relationship to g justiﬁed by several intuitive properties 77 © 2008 by Taylor & Francis Group, LLC

78

CHAPTER 5. BLUE-NOISE DITHERING

Figure 5.1: Gray-scale image halftoned using blue-noise shown at 150 dot per inch (dpi).

© 2008 by Taylor & Francis Group, LLC

5.1. SPATIAL AND SPECTRAL CHARACTERISTICS

79

Figure 5.2: The distribution of minority pixels in a blue-noise pattern an average distance of λb apart. 1. As the gray value approaches perfect white (g = 0) or perfect black (g = 1), the principal wavelength approaches inﬁnity. That is, the minority pixels become spread inﬁnitely far apart. 2. The principal wavelength decreases symmetrically with equal deviations from black and white toward middle gray (g = 1/2). 3. The square of the wavelength is inversely proportional to the number of minority pixels per unit area. Again we note that the distribution of minority pixels is assumed to be stationary and isotropic.

5.1.1

Spatial Statistics

In light of the nature of blue-noise to isolate minority pixels, we can begin to characterize blue-noise halftones in terms of the pair correlation R(r) by noting that 1. Few or no neighboring pixels lie within a radius of r < λb . 2. For r > λb , the expected number of minority pixels per unit area approaches I with increasing r. 3. The average number of minority pixels within the radius r increases sharply near r = λb .

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

80

(c) (b)

(a)

/

Figure 5.3: The (top) pair correlation of the ideal blue-noise pattern with principal wavelength λb and the (bottom) directional distribution function of the ideal blue-noise pattern in the near range r ∈ [0, 1.5λb ). The resulting pair correlation for blue-noise is therefore of the form in Fig. 5.3 (top), where R(r) shows: (a) a strong inhibition of minority pixels near r = 0, (b) a decreasing correlation of minority pixels with increasing r (limr→∞ R(r) = 1), and (c) a frequent occurrence of the inter-point distance λb , the principal wavelength, indicated by a series of peaks at integer multiples of λb . The principal wavelength is indicated in Fig. 5.3 by a diamond located along the horizontal axis. As an isotropic point process, the ideal Dr1 ,r2 (a) is shown in Fig. 5.3 (bottom) for the near range of r ∈ (0, 1.5λb ], which indicates the directional distribution between nearest neighbors.

5.1.2

Spectral Statistics

Turning to the spectral domain, the spectral characteristics of bluenoise in terms of the radially averaged power spectrum, Pρ (fρ ), are shown in Fig. 5.4 and can be described by three unique features: (a) lit-

© 2008 by Taylor & Francis Group, LLC

5.1. SPATIAL AND SPECTRAL CHARACTERISTICS

81

(c) (b) (a)

Figure 5.4: The (top) RAPSD of the ideal blue-noise pattern with principal frequency fb , and the (bottom) anisotropy of the ideal bluenoise pattern. tle or no low-frequency spectral components; (b) a ﬂat, high-frequency (blue-noise) spectral region; and (c) a spectral peak at cutoﬀ frequency fb , the blue-noise principal frequency, such that √ g/D, for 0 < g ≤ 1/2 (5.2) fb = √ 1 − g/D, for 1/2 < g ≤ 1. As will be the convention in this book, the principal frequency is indicated in Fig. 5.4 (top) by a diamond located along the horizontal axis. Also note that P (fρ ) is plotted in units of σg2 = g(1 − g), the variance of an individual pixel in Ig . The sharpness of the spectral peak in P (fρ ) at the blue-noise principal frequency is aﬀected by the separation between minority pixels, which should have some variation. The wavelengths of this variation should not be signiﬁcantly longer than λb , as this adds low-frequency spectral components to the corresponding dither pattern Ig [123], causing Ig to appear more white than blue. This process is referred to as spectral whitening. Being isotropic, A(fρ ) should be minimized at all fρ , as shown in Fig. 5.4 (bottom), where, based on the estimation of P (f ) (Sec. 3.3), −10db is considered background noise [123].

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

82

Y Y

Figure 5.5: The error-diﬀusion algorithm.

5.2

Error-diﬀusion

In error-diﬀusion (Fig. 5.5), the output pixel y[n] is determined by adjusting and thresholding the input pixel x[n] such that:

y[n] =

1, if (x[n] + xe [n]) ≥ 0 0, else,

(5.3)

where xe [n] is the diﬀused quantization error accumulated during previous iterations as xe [n] =

M i=1

with y e [n] = y[n]−(x[n]+xe [n]) and (5.4) becomes

bi · y e [n − i] M

i=1 bi

(5.4)

= 1. Using vector notation,

xe [n] = bT ye [n]

(5.5)

where b = [b1 , b2 , . . . , bM ]T and ye [n] = [y e [n − 1], y e [n − 2], . . . , y e [n − M ]]T . Shown in Fig. 5.6 are the error weights originally proposed by Floyd and Steinberg [40], and using a left-to-right raster scan, Figs. 5.7 and 5.8 show the resulting monochrome image and gray-scale ramp produced using Floyd’s and Steinberg’s error ﬁlter. For a statistical analysis, Figs. 5.9–5.11 show the corresponding spatial and spectral 1 1 metrics for intensity levels I = 32 , 16 , 18 , 14 , 38 , and 12 . While these results exhibit distinct blue-noise properties, Floyd’s and Steinberg’s error ﬁlter produces disturbing texture shifts or banding at multiples of the 13 and 14 gray-levels [40], where error-diﬀusion “locks” into a regular, stable pattern [56]. The brief transition in these instances occurs as a consequence of the sudden breakup in the regular pattern. The Floyd and Steinberg error ﬁlter also creates disturbing hysteresis artifacts or worm patterns at extreme gray-levels g = 0 and g = 1.

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

3/16

83 • 7/16 5/16 1/16

Figure 5.6: Floyd’s and Steinberg’s proposed error ﬁlter.

5.2.1

Eliminating Unwanted Textures

Since Floyd’s and Steinberg’s ﬁrst paper, many modiﬁcations to the original error-diﬀusion algorithm have been introduced that address the unwanted artifacts of the original algorithm. But while these modiﬁcations eliminate disturbing artifacts at certain gray-levels, many do so at the expense of other levels [56]. A typical problem that occurs is spectral whitening, described earlier, where the variation in average separation distance between minority pixels becomes so great that the pattern starts to resemble the halftone pattern created by white-noise. Modiﬁed Filter Weights In an eﬀort to break up worm patterns in error-diﬀusion, both Jarvis et al. [50] and Stucki [117] introduced 12-element error ﬁlters, as shown in Figs. 5.12 and 5.13, respectively. Shown in Figs. 5.15–5.24 are their corresponding gray-scale ramps, images, and metrics. From their grayscale ramps (Figs. 5.15 and 5.20), it is apparent that both ﬁlters break up worms at extreme gray-levels, but both do so with spectral whitening in the mid-tones [56]. The Jarvis et al. ﬁlter performs especially poorly in the range 1 ≤ I ≤ 12 , where error-diﬀusion creates patterns with a frequent oc4 currence of the inter-point distance 2D, the principal wavelength for I = 14 . This behavior is clearly indicated in the power spectrums of Figs. 5.18 and 5.19, where the RAPSD shows a strong peak at fρ = 12 D−1 . For intensities near 14 , the banding of minority pixels occurs along diagonals, but as the intensity increases toward 12 , minority pixels begin to cluster, forming a coarse pattern at g = 12 . Stucki’s ﬁlter has several problems of its own, although not as severe. Here, dither patterns also exhibit strong spectral components below the principal frequency in the range 14 ≤ I ≤ 12 , with minority pixels exhibiting strong correlations along the diagonals. As the intensity approaches 12 , Stucki’s weights maintain this correlation, resulting in the g = 12 checkerboard pattern also found using Floyd’s and Steinberg’s weights.

© 2008 by Taylor & Francis Group, LLC

84

CHAPTER 5. BLUE-NOISE DITHERING

Figure 5.7: Gray-scale ramp halftoned using Floyd’s and Steinberg’s ﬁlter weights with a left-to-right raster scan.

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

85

Figure 5.8: Gray-scale image halftoned using Floyd’s and Steinberg’s ﬁlter weights with a left-to-right raster scan.

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

86

2 RAPSD

RAPSD

2

1

1

fb 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fb 0

0.5 RADIAL FREQUENCY

2

1

hb 0 0

10 RADIAL DISTANCE

20

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

10 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

20

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.9: Spatial and spectral statistics using Floyd’s and Steinberg’s ﬁlter weights with a left-to-right raster scan for intensity levels (left) 1 1 I = 32 and (right) I = 16 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

87

RAPSD

4

RAPSD

4

1

0.5 RADIAL FREQUENCY

0

0.7071

ANISOTROPY

0

10 0 ï10 0

PAIR CORRELATION

1

fb

0.5 RADIAL FREQUENCY

2

1

hb 0 0

5 RADIAL DISTANCE

10

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.10: Spatial and spectral statistics using Floyd’s and Steinberg’s ﬁlter weights with a left-to-right raster scan for intensity levels (left) I = 18 and (right) I = 14 .

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

88

RAPSD

4

RAPSD

4

1 0.5 RADIAL FREQUENCY

0

0.7071

ANISOTROPY

0

10 0 ï10 0

PAIR CORRELATION

1

fb

0.5 RADIAL FREQUENCY

2

1

hb 0 0

5 RADIAL DISTANCE

10

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.11: Spatial and spectral statistics using Floyd’s and Steinberg’s ﬁlter weights with a left-to-right raster scan for intensity levels (left) I = 38 and (right) I = 12 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

89

• 7/48 5/48 3/48 5/48 7/48 5/48 3/48 1/48 3/48 5/48 3/48 1/48 Figure 5.12: Jarvis’s, Judice’s, and Ninke’s proposed error ﬁlter. • 8/42 4/42 2/42 4/42 8/42 4/42 2/42 1/42 2/42 4/42 2/42 1/42 Figure 5.13: Stucki’s proposed error ﬁlter.

1/16

1/16

2/16

• 8/16 4/16 0/16

Figure 5.14: Shiau’s and Fan’s proposed error ﬁlter. A fourth approach to ﬁlter weight selection is the error ﬁlter of Shiau and Fan [111], shown in Fig. 5.14. Here, the ﬁlter is restricted to just two rows but has an extraordinarily long tail. The result is a gray-scale ramp, shown in Fig. 5.25, without the worm patterns near g = 0 and g = 1 but also with little diﬀerence in performance from Floyd’s and Steinberg’s ﬁlter in the mid-tones. Algorithms that swap error ﬁlters according to the gray-level of the current input pixel have also been proposed [32, 134]. In Eschbach’s scheme [32], the error ﬁlter is swapped between diﬀerent sized arrangements, with the larger arrangement used near extreme graylevels where large ﬁlters typically perform better while the smaller is used in the mid-tones where small ﬁlters typically perform better. To minimize artifacts or contours created at the point of the ﬁlter swap, the smaller ﬁlter is chosen as a subset of the larger.

© 2008 by Taylor & Francis Group, LLC

90

CHAPTER 5. BLUE-NOISE DITHERING

Figure 5.15: Gray-scale ramp halftoned using Jarvis’s, Judice’s, and Ninke’s ﬁlter weights with a left-to-right raster scan.

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

91

Figure 5.16: Gray-scale image halftoned using Jarvis’s, Judice’s, and Ninke’s ﬁlter weights with a left-to-right raster scan.

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

92

2 RAPSD

RAPSD

2

1

1

fb 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fb 0

0.5 RADIAL FREQUENCY

2

1

hb 0 0

10 RADIAL DISTANCE

20

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

10 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

20

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.17: Spatial and spectral statistics using Jarvis’s, Judice’s, and Ninke’s ﬁlter weights with a left-to-right raster scan for intensity levels 1 1 (left) I = 32 and (right) I = 16 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

93

RAPSD

4

RAPSD

4

1

0.5 RADIAL FREQUENCY

0

0.7071

ANISOTROPY

0

10 0 ï10 0

PAIR CORRELATION

1

fb

0.5 RADIAL FREQUENCY

2

1

hb 0 0

10 RADIAL DISTANCE

20

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.18: Spatial and spectral statistics using Jarvis’s, Judice’s, and Ninke’s ﬁlter weights with a left-to-right raster scan for intensity levels (left) I = 18 and (right) I = 14 .

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

94

RAPSD

4

RAPSD

4

1 0.5 RADIAL FREQUENCY

0

0.7071

ANISOTROPY

0

10 0 ï10 0

PAIR CORRELATION

1

fb

0.5 RADIAL FREQUENCY

2

1

hb 0 0

5 RADIAL DISTANCE

10

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.19: Spatial and spectral statistics using Jarvis’s, Judice’s, and Ninke’s ﬁlter weights with a left-to-right raster scan for intensity levels (left) I = 38 and (right) I = 12 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

95

Figure 5.20: Gray-scale ramp halftoned using Stucki’s ﬁlter weights with a left-to-right raster scan.

© 2008 by Taylor & Francis Group, LLC

96

CHAPTER 5. BLUE-NOISE DITHERING

Figure 5.21: Gray-scale image halftoned using Stucki’s ﬁlter weights with a left-to-right raster scan.

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

97

4 RAPSD

RAPSD

2

1

1

fb 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

0

0.5 RADIAL FREQUENCY

2

1

hb 0 0

10 RADIAL DISTANCE

20

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

10 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

20

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.22: Spatial and spectral statistics using Stucki’s ﬁlter weights 1 with a left-to-right raster scan for intensity levels (left) I = 32 and 1 (right) I = 16 .

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

98

RAPSD

4

RAPSD

4

1

0.5 RADIAL FREQUENCY

0

0.7071

ANISOTROPY

0

10 0 ï10 0

PAIR CORRELATION

1

fb

0.5 RADIAL FREQUENCY

2

1

hb 0 0

5 RADIAL DISTANCE

10

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.23: Spatial and spectral statistics using Stucki’s ﬁlter weights with a left-to-right raster scan for intensity levels (left) I = 18 and (right) I = 14 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

99

RAPSD

4

RAPSD

4

1 0.5 RADIAL FREQUENCY

0

0.7071

ANISOTROPY

0

10 0 ï10 0

PAIR CORRELATION

1

fb

0.5 RADIAL FREQUENCY

2

1

hb 0 0

5 RADIAL DISTANCE

10

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.24: Spatial and spectral statistics using Stucki’s ﬁlter weights with a left-to-right raster scan for intensity levels (left) I = 38 and (right) I = 12 .

© 2008 by Taylor & Francis Group, LLC

100

CHAPTER 5. BLUE-NOISE DITHERING

Figure 5.25: Gray-scale ramp halftoned using Shiau’s and Fan’s ﬁlter weights with a left-to-right raster scan.

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

101

Figure 5.26: Gray-scale image halftoned using Shiau’s and Fan’s ﬁlter weights with a left-to-right raster scan.

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

102

RAPSD

2

RAPSD

4

1

fb 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fb 0

0.5 RADIAL FREQUENCY

2

1

hb 0 0

10 RADIAL DISTANCE

20

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

1

2

1

hb 0 0

10 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

20

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.27: Spatial and spectral statistics using Shiau’s and Fan’s ﬁlter 1 weights with a left-to-right raster scan for intensity levels (left) I = 32 1 and (right) I = 16 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

103

RAPSD

4

RAPSD

4

1

0.5 RADIAL FREQUENCY

0

0.7071

ANISOTROPY

0

10 0 ï10 0

PAIR CORRELATION

1

fb

0.5 RADIAL FREQUENCY

2

1

hb 0 0

10 RADIAL DISTANCE

20

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.28: Spatial and spectral statistics using Shiau’s and Fan’s ﬁlter weights with a left-to-right raster scan for intensity levels (left) I = 18 and (right) I = 14 .

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

104

RAPSD

8

RAPSD

8

fb 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

1 0

0.5 RADIAL FREQUENCY

2

1

hb 0 0

5 RADIAL DISTANCE

10

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

1 0

2

1

hb 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.29: Spatial and spectral statistics using Shiau’s and Fan’s ﬁlter weights with a left-to-right raster scan for intensity levels (left) I = 38 and (right) I = 12 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

105

left-to-right

serpentine Figure 5.30: Two commonly used raster scans for error-diﬀusion shown using the Floyd and Steinberg ﬁlter weights. Raster Scanning Path The scanning path is the order to which input pixels are processed by the error-diﬀusion algorithm. Typically, as is the case with Floyd and Steinberg, the scanning path is a left-to-right raster scan (Fig. 5.30 (top)), where pixels are processed moving left to right along consecutive rows. Another approach, and perhaps the next most common, is a serpentine raster scan (Fig. 5.30 (left)), where the input image is processed along consecutive rows with the ﬁrst row processed left-to-right and the next row right-to-left. Shown in Figs. 5.31–5.35 are the resulting ramps, images, and metrics using Floyd’s and Steinberg’s error ﬁlter with the serpentine raster scan. More creative approaches to scanning paths have also been proposed based on space ﬁlling curves – connected paths that visit each and every input pixel exactly once [125]. Shown in Fig. 5.36 are illustrations showing the Peano and Hilbert paths, but while these paths break up worms, they also introduce a signiﬁcant amount of noise through the introduction of new patterns [56]. Knuth [59] oﬀered an interesting twist to scanning paths when he introduced dot-diﬀusion, a halftoning algorithm based loosely on error-

© 2008 by Taylor & Francis Group, LLC

106

CHAPTER 5. BLUE-NOISE DITHERING

Figure 5.31: Gray-scale ramp halftoned using Floyd’s and Steinberg’s ﬁlter weights with a serpentine raster scan.

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

107

Figure 5.32: Gray-scale image halftoned using Floyd’s and Steinberg’s ﬁlter weights with a serpentine raster scan.

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

108

4 RAPSD

RAPSD

2

1

1

fb 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

0

0.5 RADIAL FREQUENCY

2

1

hb 0 0

10 RADIAL DISTANCE

20

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

10 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

20

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.33: Spatial and spectral statistics using Floyd’s and Steinberg’s ﬁlter weights with a serpentine raster scan for intensity levels 1 1 (left) I = 32 and (right) I = 16 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

109

RAPSD

8

RAPSD

4

1

fb 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

1 0

0.5 RADIAL FREQUENCY

2

1

hb 0 0

5 RADIAL DISTANCE

10

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.34: Spatial and spectral statistics using Floyd’s and Steinberg’s ﬁlter weights with a serpentine raster scan for intensity levels (left) I = 18 and (right) I = 14 .

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

110

RAPSD

8

RAPSD

8

fb 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

1 0

0.5 RADIAL FREQUENCY

2

1

hb 0 0

5 RADIAL DISTANCE

10

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

1 0

2

1

hb 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.35: Spatial and spectral statistics using Floyd’s and Steinberg’s ﬁlter weights with a serpentine raster scan for intensity levels (left) I = 38 and (right) I = 12 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

111

Figure 5.36: The (left) Peano and (right) Hilbert space ﬁlling curves.

= processed input pixel = unprocessed input pixel

Figure 5.37: The diﬀusion of quantization error for pixels within an 8 × 8 block using Knuth’s dot-diﬀusion.

diﬀusion that halftones the input image in independently processed 8 × 8 blocks. In this new algorithm, pixels of each block are processed along a disconnected path speciﬁed by the consecutive thresholds of an 8 × 8 dither array such as that used in clustered-dot ordered dither (Sec. 1.1) or Bayer’s dither. For a particular iteration of dot-diﬀusion, the current input pixel is quantized with the quantization error-diﬀused equally to the neighboring, unprocessed input pixels within the block, as shown in Fig. 5.37. While Knuth’s algorithm leads to strong periodic patterns as in Fig. 5.38 (left), where pixels are processed in the order of clustered-dot ordered dithers, Mese and Vaidyanathan [84] show, as in Fig. 5.38 (right), that the order can be optimized for 16 × 16 blocks to produce results of comparable visual quality to error-diﬀusion.

© 2008 by Taylor & Francis Group, LLC

112

CHAPTER 5. BLUE-NOISE DITHERING

Figure 5.38: The halftone images created using Knuth’s dot-diﬀusion with pixels processed in (left) 8×8 blocks using an ordering speciﬁed by Bayer’s dither and in (right) 16× 16 blocks with the ordering optimized to imitate blue-noise. Filter and Threshold Perturbations Perturbation refers to adding noise or randomness to the error weights or quantization threshold at each iteration of the error-diﬀusion algorithm. An early approach to ﬁlter perturbation was proposed by Ulichney [122], who suggested grouping ﬁlter coeﬃcients of similar weights into pairs and then moving a portion of one weight to the other. The size of the portion was chosen randomly at each iteration and, in order to avoid negative weights, was limited to a maximum percentage of the smaller of the two weights. So, given a ﬁlter pair (a1 , a2 ), where a1 > a2 , the ﬁlter weights used at any given iteration would be determined as a1 = a1 + U (T · a2 ) a2 = a2 − U (T · a2 ),

(5.6) (5.7)

where U is a uniformly distributed random number from the range [−1, 1] and T is a pre-speciﬁed tolerance in the range [0, 1]. Using the Floyd-Steinberg ﬁlter weights, Ulichney showed that perturbing each of the two pairs (7/16, 5/16) and (3/16, 1/16), created a good blue-noise process. In particular, adding 50% noise to each pair appears to optimize the trade-oﬀ between graininess and stable texture

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

113

[123]. Figs. 5.39–5.43 show the resulting gray-scale ramps, gray-scale images, and the spatial and spectral characteristics using this approach. Perturbing the quantization threshold presents an advantage over ﬁlter weight perturbation, having a single, scalar quantity to adjust. An obvious approach to threshold perturbation is to add either a uniformly distributed random number from the range [−T, T ] or a Gaussian distributed random number with variance T . In both cases, T is determined empirically. Shown in Fig. 5.44 (right) is the resulting halftone image using the Gaussian random number where T = 0.01. The drawback of using a perturbed threshold, as seen in Fig. 5.44, is that the randomness added to the threshold whitens the halftone with noisy artifacts most noticeable in the mid-tones. Feedback Error-diﬀusion with feedback refers to algorithms that take into account previous output pixels during the quantization of the current input pixel. An early approach to feedback was proposed by Fawcette and Shrack [38], who modulated the quantization threshold according to the binary arrangement of dots in the previous ﬁve output pixels. Levien [75] oﬀered an alternative approach that suggested modulating the threshold according to the distance between the current input pixel and the nearest minority pixel. If the nearest minority pixel is at a distance d, then the threshold is decreased by (d2 − 1/x[n]) · c for 0 < g < 12 or increased by (d2 − 1/(1 − x[n])) · c for 12 ≤ g < 1, where c is a scalar constant giving the user the ability to regulate how much of an impact d has on y[n]. From visual inspection of the gray-scale ramp of Fig. 5.45, it is clear that Levien’s oﬀset on the quantization threshold has lesser impact in the mid-tones, where 1/x[n] or 1/(1 − x[n]) is minimized relative to the extremes and 1/x[n] or 1/(1 − x[n]) is maximized. In the same spirit as Levien, Eschbach [33] suggested that the threshold oﬀset should be a superposition of oﬀsets derived from all neighboring minority pixels and not just the nearest.

5.2.2

Edge Enhancement

In his book, Ulichney [123] wrote that the measure of a particular halftoning algorithm was its performance in DC regions and that its performance near edges or in areas of high-frequency image content

© 2008 by Taylor & Francis Group, LLC

114

CHAPTER 5. BLUE-NOISE DITHERING

Figure 5.39: Gray-scale ramp halftoned using Floyd’s and Steinberg’s ﬁlter weights with 50% perturbation and a serpentine raster scan.

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

115

Figure 5.40: Gray-scale image halftoned using Floyd’s and Steinberg’s ﬁlter weights with 50% perturbation and a serpentine raster scan.

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

116

2 RAPSD

RAPSD

2

1

1

fb 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fb 0

0.5 RADIAL FREQUENCY

2

1

hb 0 0

10 RADIAL DISTANCE

20

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

10 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

20

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.41: Spatial and spectral statistics using Floyd’s and Steinberg’s ﬁlter weights with 50% perturbation and a serpentine raster scan 1 1 for intensity levels (left) I = 32 and (right) I = 16 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

117

4 RAPSD

RAPSD

2

1

1

fb 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

0

0.5 RADIAL FREQUENCY

2

1

hb 0 0

5 RADIAL DISTANCE

10

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.42: Spatial and spectral statistics using Floyd’s and Steinberg’s ﬁlter weights with 50% perturbation and a serpentine raster scan for intensity levels (left) I = 18 and (right) I = 14 .

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

118

RAPSD

8

RAPSD

4

1

fb 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

1 0

0.5 RADIAL FREQUENCY

2

1

hb 0 0

5 RADIAL DISTANCE

10

fb 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hb 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.43: Spatial and spectral statistics using Floyd’s and Steinberg’s ﬁlter weights with 50% perturbation and a serpentine raster scan for intensity levels (left) I = 38 and (right) I = 12 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

119

Figure 5.44: The halftone images created using Floyd’s and Steinberg’s ﬁlter weights with a left-to-right raster with (left) no threshold perturbation and (right) a Gaussian distributed (V AR = 0.01) threshold perturbation. can be manipulated through pre-ﬁltering the image prior to halftoning. So the remedy for the apparent blurring of edges caused by the error-diﬀusion algorithm was to apply an edge sharpening ﬁlter prior to halftoning such that xsharp [n] = x[n] − β(ψ[n] ∗ x[n]),

(5.8)

where ψ[n] is a digital Laplacian ﬁlter (Fig. 5.50), ∗ denotes convolution, and β is a scalar constant (β ≥ 0) regulating the amount of sharpening with larger β leading to a sharper image xsharp . Shown in Fig. 5.51 is a comparison of two halftones produced using Ulichney’s perturbed error weight scheme with and without sharpening (β = 2). For another approach to edge enhancement, Eschbach and Knox [34] have shown that modulating the quantization threshold at each iteration by a scalar multiple of the current input pixel sharpens the resulting apparent image. To understand why requires a spectral analysis of the error-diﬀusion algorithm itself. To this end, Weissbach et al. [132] showed that the power spectrum, Y , of the output image of error-diﬀusion was related to the power spectrums, X and Xe , of the input and error images as Y = X + F Xe ,

© 2008 by Taylor & Francis Group, LLC

(5.9)

120

CHAPTER 5. BLUE-NOISE DITHERING

Figure 5.45: Gray-scale ramp halftoned using Floyd’s and Steinberg’s ﬁlter weights with Levien’s threshold oﬀset (c = 0.005) and a left-toright raster scan.

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

121

Figure 5.46: Gray-scale image halftoned using Floyd’s and Steinberg’s ﬁlter weights with Levien’s threshold oﬀset (c = 0.005) and a left-toright raster scan.

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

122

RAPSD

4

RAPSD

4

1

0.5 RADIAL FREQUENCY

0

0.7071

ANISOTROPY

0

10 0 ï10 0

PAIR CORRELATION

1

fg

0.5 RADIAL FREQUENCY

2

1

hg 0 0

10 RADIAL DISTANCE

20

fg 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

10 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

20

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.47: Spatial and spectral statistics using Floyd’s and Steinberg’s ﬁlter weights with Levien’s threshold oﬀset (c = 0.005) and a 1 left-to-right raster scan for intensity levels (left) I = 32 and (right) 1 I = 16 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

123

RAPSD

4

RAPSD

4

1

0.5 RADIAL FREQUENCY

0

0.7071

ANISOTROPY

0

10 0 ï10 0

PAIR CORRELATION

1

fg

0.5 RADIAL FREQUENCY

2

1

hg 0 0

10 RADIAL DISTANCE

20

fg 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.48: Spatial and spectral statistics using Floyd’s and Steinberg’s ﬁlter weights with Levien’s threshold oﬀset (c = 0.005) and a left-to-right raster scan for intensity levels (left) I = 18 and (right) I = 14 .

© 2008 by Taylor & Francis Group, LLC

CHAPTER 5. BLUE-NOISE DITHERING

124

RAPSD

4

RAPSD

4

1 0.5 RADIAL FREQUENCY

0

0.7071

ANISOTROPY

0

10 0 ï10 0

PAIR CORRELATION

1

fg

0.5 RADIAL FREQUENCY

2

1

hg 0 0

5 RADIAL DISTANCE

10

fg 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 5.49: Spatial and spectral statistics using Floyd’s and Steinberg’s ﬁlter weights with Levien’s threshold oﬀset (c = 0.005) and a left-to-right raster scan for intensity levels (left) I = 38 and (right) I = 12 .

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

125

Figure 5.50: Two digital Laplacian ﬁlters proposed by Ulichney for edge sharpening prior to halftoning.

Figure 5.51: The halftone images created using Floyd’s and Steinberg’s ﬁlter weights with 50% perturbation and a serpentine raster scan (left) before and (right) after having been edge sharpened prior to halftoning (β = 2). where F = 1 − DFT2D {a}

(5.10)

is a high-pass ﬁlter derived from the two-dimensional discrete Fourier transform of the error ﬁlter a. Relating these results to threshold modulation, Knox and Eschbach [34] later showed that varying the threshold of error-diﬀusion by the function t[n] was equivalent to applying ordinary error-diﬀusion to the input image x˜, where ˜ = X + F T. X

© 2008 by Taylor & Francis Group, LLC

(5.11)

126

CHAPTER 5. BLUE-NOISE DITHERING

If t[n] = k·x[n], then (5.11) is equivalent to adding a high-pass version of x to itself prior to halftoning – leading to sharper edges in the apparent image y. Figure 5.52 shows the resulting halftone images produced by Ulichney’s perturbed error weight scheme with Knox’s and Eschbach’s threshold modulation where k = 0, 2, 5, and −2. Note that the negative value of k leads to blurring instead of sharpening.

© 2008 by Taylor & Francis Group, LLC

5.2. ERROR-DIFFUSION

127

Figure 5.52: The halftone images created using Floyd’s and Steinberg’s ﬁlter weights with 50% perturbation and a serpentine raster scan with threshold modulation where (top left) k = 0, (top right) k = 2, (bottom right) k = 5, and (bottom right) k = −2.

© 2008 by Taylor & Francis Group, LLC

Chapter 6 Blue-Noise Dither Arrays Halftoning via blue-noise dither arrays is a process whereby a continuoustone image is thresholded on a pixel-by-pixel basis with a dither array or mask. A pixel of the resulting binary image is set to one if that pixel of the continuous-tone image is greater than or equal to the corresponding pixel of the dither array; otherwise, the pixel is set to zero. These masks can also be of any size with large images halftoned using new masks formed by tiling edge-to-edge the original dither array. The blue-noise dither array derives its name from the fact that, given a continuous-tone monochrome image of constant gray-level g, the resulting dither pattern has blue-noise characteristics appropriate to g. While dispersed-dot dithering creates patterns with a “strong periodic structure that imparts an unnatural appearance to resulting images” [124], halftoning via blue-noise dither arrays typically uses dither arrays that are much larger in size than those used in disperseddot ordered dithering (256×256 versus 16×16), and while the halftoned images are not as visually appealing as those derived from adaptive techniques such as error-diﬀusion, the computational complexity is greatly reduced, requiring no additional storage other than for the array itself. Also, as a process that need not consider neighboring pixels, halftoning via blue-noise dither arrays is a candidate for parallel processing. The construction of blue-noise dither arrays is generally performed by ﬁrst constructing a set, {Ig : 0 < g < 1}, of binary dither patterns with exactly one dither pattern, Ig , for each unique gray-level of the original, continuous-tone image. Inside of Ig , the fraction of pixels set to white (1) is equal to g, and so for an 8 bit monochrome display, this implies constructing 256 unique dither patterns with the ﬁrst pattern, I0 , corresponding to the all-black pixel pattern for g = 0 and the 129 © 2008 by Taylor & Francis Group, LLC

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

130

12 3

9 13

4 16 6

1

7 10 5 15

1 16

14 2 11 8

Figure 6.1: The (right) dither array constructed from (left) 16 binary dither patterns. last pattern, I1 , corresponding to the all-white pattern for g = 1. And in order to produce visually pleasing dither patterns for large images, the component dither patterns must satisfy a “wrap-around” property where tiling a particular pattern end-to-end does not create any discontinuity in texture moving across boundaries. Having this set, the blue-noise dither array is then constructed by assigning to each pixel a threshold according to the spatial arrangement of binary pixels within {Ig : 0 ≤ g ≤ 1}, where, in order to avoid ambiguities in the assignment of thresholds, the dither patterns, Ig , are constructed under the stacking constraint that Ik ⊂ Ig for all k < g or that, if given Ik [n] = 1, then Ig [n] = 1 for all g > k. As a consequence, the threshold assigned to each pixel of the array is deﬁned as DA[n] = min{g : Ig [n] = 1},

(6.1)

with the minimum gray-level g such that the corresponding pixel in Ig is equal to 1. Given a blue-noise dither array of size M , the output pixel, y[n], is derived from x[n] as

y[n] =

1, if x[modM (n)] ≥ DA[modM (n)] 0, else.

Figure 6.1 illustrates (6.1) for an array of size 4 × 4.

© 2008 by Taylor & Francis Group, LLC

(6.2)

6.1. SIMULATED ANNEALING

6.1

131

Simulated Annealing

While many techniques have been proposed for deriving the component blue-noise dither patterns [86, 3, 20, 21, 26, 80, 92, 107, 124, 127, 128] forming the set {Ig : 0 ≤ g ≤ 1}, perhaps the ﬁrst to do so successfully was Sullivan et al. [119], who proposed using a set visually pleasing, binary dither patterns, {Ig : 0 ≤ g ≤ 1}, to halftone the continuoustone image, x[n], by table look-up such that y[n] = Ix[n] [modM (n)].

(6.3)

But without a stacking constraint, the patterns that formed the set {Ig : 0 ≤ g ≤ 1} could have been generated using any blue-noise halftoning algorithm such as error-diﬀusion or DBS on an appropriate set of input images. Sullivan et al., instead, proposed using a model of the HVS along with simulated annealing, where the 1’s and 0’s of a binary dither pattern are swapped at random, to minimize visible artifacts. Sullivan et al.’s iterative algorithm progresses by keeping any and all random swaps that improve the visual appearance of the pattern as well as a percentage of swaps that do not improve, and possibly degrade, the appearance. With each iteration, the percentage of bad swaps that are kept is reduced, and the algorithm quits after a ﬁxed number of iterations. The steps of Sullivan et al.’s simulated annealing algorithm are described as follows 1. Create a white-noise binary dither pattern, Ig , representing graylevel g, by thresholding a continuous-tone input image with uniformly distributed, uncorrelated (white) noise. Set K, the iteration number, equal to 1. 2. Generate the next pattern in the evolution of Ig by: (a) Calculating the visual cost, Cost(Ig ), of Ig as the total power in Ig after ﬁltering by a model of the HVS such that: Cost(Ig ) =

|DFT2D (Ig ) × HV S(f )|2 .

(6.4)

f

(b) Randomly selecting a pair of pixels, one 1 and one 0, and swap the two, making the 1 a 0 and the 0 a 1, to create the new pattern, Ig .

© 2008 by Taylor & Francis Group, LLC

132

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

Figure 6.2: The (left) initial and (right) ﬁnal dither pattern using Sullivan et al.’s simulated annealing algorithm. (c) Calculating the visual cost, Cost(Ig ), of the new pattern using (6.4). (d) Calculating the Boltzman test statistic, β, as:

−(Cost(Ig ) − Cost(Ig )) β = exp , 0.95K T

(6.5)

where T is a scalar constant regulating the percentage of swaps, good or bad, that will be kept during the current iteration. (e) Calculating ζ as a uniformly distributed random number from the range [0, 1]. If β > ζ, then keep the current swap by setting Ig = Ig ; otherwise, ignore the swap and leave Ig unchanged. (f) Repeating steps (2a)–(2e) a ﬁxed number of times (e.g., 1000). 3. Set K = K + 1. If K is suﬃciently high (e.g. 500), then quit with the ﬁnal pattern stored in Ig ; otherwise, return to step (2). Note that because Sullivan et al. do their ﬁltering process in the spectral domain utilizing the discrete Fourier transform, wrap-around textures are guaranteed as the DFT implicitly assumes the subject pattern represents one period of a repeating process. As a demonstration,

© 2008 by Taylor & Francis Group, LLC

6.1. SIMULATED ANNEALING

133

Cost(Ig) (db)

ï20 ï25 ï30 ï35

0

100

200

300

400

500

Iteration

Figure 6.3: The reduction in cost for the binary dither pattern using simulated annealing. Fig. 6.2 shows an initial dither pattern and its resulting output pattern where the visual cost is based on the two-dimensional HVS model of Chapter 4 for a 300 dpi print resolution and 20 in viewing distance and where T is selected to keep 80% of the swaps in the initial iteration (K = 1). Shown in Fig. 6.3 is the visual cost of the dither pattern at each instance of K showing not only the gradual decrease in overall cost but also a reduction in the variance of the visual cost as fewer and fewer bad swaps are being retained. Shown in Figs. 6.4–6.6 are the resulting spatial and spectral metrics using the simulated annealing algorithm for intensities I = 1 , 1 , 1 , 1 , 3 , and 12 . For I = 18 , 14 , 38 , or 12 , note that simulated 32 16 8 4 8 annealing leads to a signiﬁcant amount of spectral energy at radial frequencies below the principal frequency of blue-noise. By looking at the RAPSD of the HVS model in Fig. 6.7, it is apparent that there is a strong correlation between the shape of the spectral content of the dither pattern and that of the HVS model with minority pixels, as in Figs. 6.5 and 6.6, not adhering to the principal wavelength separation and exhibiting some, although slight, degree of clustering. The correlation between power spectrums of the resulting dither pattern and the HVS model suggests that to improve the blue-noise characteristics of the dither patterns created by simulated annealing, the cut-oﬀ frequency of the HVS model should be manipulated according to the gray-level such that intensities near 12 have a high cut-oﬀ frequency and intensities near 0 have a small cut-oﬀ frequency. Shown in Figs. 6.8–6.10 are the resulting spatial and spectral metrics using the simulated annealing algorithm where the print resolution for the HVS model has been varied with gray-level intensities to reduce minority pixel clustering.

© 2008 by Taylor & Francis Group, LLC

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

134

2 RAPSD

RAPSD

2

1

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fg 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

10 RADIAL DISTANCE

20

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

10 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

20

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.4: Spatial and spectral statistics using Sullivan et al.’s simu1 lated annealing algorithm for intensity levels (left) I = 32 and (right) 1 I = 16 .

© 2008 by Taylor & Francis Group, LLC

6.1. SIMULATED ANNEALING

135

2 RAPSD

RAPSD

2

1

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fg 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

10 RADIAL DISTANCE

20

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

10 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

20

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.5: Spatial and spectral statistics using Sullivan et al.’s simulated annealing algorithm for intensity levels (left) I = 18 and (right) I = 14 .

© 2008 by Taylor & Francis Group, LLC

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

136

2 RAPSD

RAPSD

2

1

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fg 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

10 RADIAL DISTANCE

20

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

10 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

20

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.6: Spatial and spectral statistics using Sullivan et al.’s simulated annealing algorithm for intensity levels (left) I = 38 and (right) I = 12 .

© 2008 by Taylor & Francis Group, LLC

137

l

RAPSD of CSF(f )

6.1. SIMULATED ANNEALING

1 0.5 0

0

0.1

0.2 0.3 0.4 0.5 RADIAL FREQUENCY (Dï1)

0.6

0.7

Figure 6.7: The RAPSD of the two-dimensional HVS model used with simulated annealing to construct the dither patterns of Figs. 6.4–6.6. Figures 6.11 and 6.12 illustrate Sullivan et al.’s scheme for dither array design. The drawback of ignoring the stacking constraint is evident in the gray-scale ramp of Fig. 6.11, where discontinuities, caused by isolated clusters, in the texture of the dither pattern are visible along the border between unique gray-levels. Within the gray-scale image of Fig. 6.12, the results are much worse with the halftone closely modeling white-noise. From these two results, its clear that Sullivan et al.’s unconstrained dither patterns are restricted to applications limited to business graphics (pie charts, bar graphs, etc.). In order for the constructed set, {Ig : 0 ≤ g ≤ 1}, to satisfy the stacking constraint (Fig. 6.13), Sullivan et al.’s simulated annealing algorithm must be constrained in several ways. The ﬁrst is that given a binary pattern, Is , the newly constructed pattern, Ig , such that g > s, must have Is as a subset. That is, Ig [n] = 1 for all n such that Is [n] = 1. This property is satisﬁed by specifying the initial pattern as Is with an appropriate number of pixels, equal to zero, switched to ones. The initial pattern should, after switching, represent gray-level g. The simulated annealing algorithm must also, in order to satisfy the constraint Is ⊂ Ig , consider swapping only those pixels for which Is [n] = 0. A second constraint that Sullivan et al.’s simulated annealing algorithm must be able to satisfy is that, given a pattern IS , the newly constructed pattern, Ig , such that g < S, must be a subset of IS . This property is satisﬁed by specifying the initial pattern as IS with an appropriate number of pixels, equal to one, switched to zeros. One must also consider swapping only those pixels for which IS [n] = 1. Given both Is and IS , the initial pattern should be speciﬁed as Is with an appropriate number of pixels, equal to zero and with corresponding

© 2008 by Taylor & Francis Group, LLC

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

138

2 RAPSD

RAPSD

2

1

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fg 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

10 RADIAL DISTANCE

20

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

10 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

20

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.8: Spatial and spectral statistics using Sullivan et al.’s simu1 lated annealing algorithm for intensity levels (left) I = 32 and (right) 1 I = 16 , where the print resolution of the HVS model has been modiﬁed according to the gray-level.

© 2008 by Taylor & Francis Group, LLC

6.1. SIMULATED ANNEALING

139

2 RAPSD

RAPSD

2

1

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fg 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

5 RADIAL DISTANCE

10

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.9: Spatial and spectral statistics using Sullivan et al.’s simulated annealing algorithm for intensity levels (left) I = 18 and (right) I = 14 , where the print resolution of the HVS model has been modiﬁed according to the gray-level.

© 2008 by Taylor & Francis Group, LLC

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

140

8 RAPSD

RAPSD

2

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

1 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

5 RADIAL DISTANCE

10

fg 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.10: Spatial and spectral statistics using Sullivan et al.’s simulated annealing algorithm for intensity levels (left) I = 38 and (right) I = 12 , where the print resolution of the HVS model has been modiﬁed according to the gray-level.

© 2008 by Taylor & Francis Group, LLC

6.1. SIMULATED ANNEALING

141

Figure 6.11: Gray-scale ramp halftoned using a dither array constructed by Sullivan et al.’s simulated annealing scheme without a stacking constraint.

© 2008 by Taylor & Francis Group, LLC

142

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

Figure 6.12: Gray-scale image halftoned using a dither array constructed by Sullivan et al.’s simulated annealing scheme without a stacking constraint.

© 2008 by Taylor & Francis Group, LLC

6.1. SIMULATED ANNEALING

143

Figure 6.13: Illustration of the stacking constraint on φg such that φs ⊂ φg ⊂ φS . pixels in IS equal to one, switched to ones. So swapping must now consider only those pixels that correspond to zeros in Is and ones in IS . With the simulated annealing algorithm now constrained by previously constructed patterns, the set {Ig : 0 ≤ g ≤ 1} can be constructed one-pattern-at-a-time and in any order, but while the patterns can be constructed in sequential order according to g, Sec. 6.4 will show that some orderings are better then others. So, in summary of blue-noise dither array construction, we assume that images are composed of a discrete set of N gray-levels deﬁned by the monotonically increasing sequence {gi : i = 1, 2, . . . , N } with g1 = 0 (black) and gN = 1 (white). The steps for generating the set {Ig : 0 ≤ g ≤ 1} are then deﬁned according to 1. Given g1 = 0 and gN = 1, deﬁne Ig1 as an all-zero matrix and IgN as an al-one matrix. 2. Deﬁne the sequence {gki : i = 1, 2, . . . , N } as a rearrangement or re-ordering of the sequence {gi : i = 1, 2, . . . , N } such that every gray-level gi appears once and only once in the sequence {gki : i = 1, 2, . . . , N } with gk1 = 0 and gk2 = 1 (k1 = 1 and k2 = N ).

© 2008 by Taylor & Francis Group, LLC

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

144

Figure 6.14: The dither array, constructed by Sullivan et al.’s simulated annealing scheme employing the stacking constraint and a manipulated HVS model, with its corresponding magnitude to its Fourier transform. 3. Set j = 3. 4. Construct the dither pattern Igkj under the stacking constraint for all patterns {Igki : i = 1, 2, . . . , j − 1} (for all patterns that have been generated up to the current iteration). 5. Set j = j + 1. If j = N + 1, the process is complete; otherwise, continue at step 4. Using the above procedure, Figs. 6.14–6.16 show the dither arrays, resulting gray-scale ramps, and resulting gray-scale image when dither patterns are constructed in the order {0, 1, 14 , 34 , 12 , 18 , 38 , 58 , 78 , . . .}. Shown in Fig. 6.17 is the same gray-scale image but with Ulichney’s edge sharpening applied prior to halftoning (β = 2).

6.2

Void-and-Cluster

A popular scheme for building blue-noise dither arrays is Ulichney’s [124] void-and-cluster (VAC) technique [124], which iteratively swaps black and white pixels according to a measure of local white pixel density. As demonstrated in Fig. 6.18, VAC measures the minority pixel density, around a given pixel x[m, n], as the gray-level of the corresponding pixel in the continuous-tone image resulting from the con-

© 2008 by Taylor & Francis Group, LLC

6.2. VOID-AND-CLUSTER

145

Figure 6.15: Gray-scale ramp halftoned using a dither array constructed by Sullivan et al.’s simulated annealing scheme with the stacking constraint and a manipulated HVS model.

© 2008 by Taylor & Francis Group, LLC

146

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

Figure 6.16: Gray-scale image halftoned using a dither array constructed by Sullivan et al.’s simulated annealing scheme with the stacking constraint and a manipulated HVS model.

© 2008 by Taylor & Francis Group, LLC

6.2. VOID-AND-CLUSTER

147

Figure 6.17: Gray-scale image halftoned using a dither array constructed by Sullivan et al.’s simulated annealing scheme with the stacking constraint, a manipulated HVS model, and Ulichney’s edge sharpening applied prior to halftoning.

© 2008 by Taylor & Francis Group, LLC

148

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

Figure 6.18: The current iteration’s dither pattern and the corresponding low-pass ﬁltered image measuring the local white pixel density. volution of a low-pass ﬁlter with the current iteration’s dither pattern. Speciﬁcally, VAC generates a seed pattern, Xk=0 , as a white-noise dither pattern representing the gray-level gi . This seed pattern is then ﬁltered by means of circular convolution with the low-pass ﬁlter, HLP , such that Y = Xk ⊗ HLP , (6.6) where pixel values, y[m, n], less than gi correspond to regions of the dither pattern with too few neighboring white pixels (x[m, n] = 1) while pixel values greater than gi correspond to regions of the dither pattern with too few neighboring black pixels (x[m, n] = 0). Because the success of the void-and-cluster algorithm relies very heavily upon the choice of low-pass ﬁlters, Ulichney recommends a Gaussian ﬁlter deﬁned according to HLP [n] = exp(

−|n|2 ), 2σ 2

(6.7)

where σ is a scalar constant determined empirically to oﬀer the best results at σ = 1.5D [124]. Given the relationship of the ﬁltered image to a measure of white pixel density, the VAC algorithm identiﬁes the white pixel of Xk with the largest concentration of white pixels (largest y[m, n] value), toggling the pixel to black. It is these regions of high, white pixel density

© 2008 by Taylor & Francis Group, LLC

6.2. VOID-AND-CLUSTER

149

Figure 6.19: Illustration of the tiled, binary dither patterns (left) before and (right) after applying VAC to a 108×108 white-noise dither pattern representing gray-level 34 . that Ulichney refers to as a cluster where, by toggling the bit, VAC attempts to create a void. This modiﬁed dither pattern is then re-ﬁltered with the black pixel of Xk having the sparsest concentration of white pixels (smallest y[m, n] value) toggled to white. It is these regions of low, white pixel density that Ulichney refers to as a void, where VAC attempts to create a cluster. It is this process of voiding and clustering white pixels from which VAC derives its name. Having toggled a white pixel to black and then a black pixel to white, the resulting dither pattern, Xk+1 , now completes the current iteration with Xk+1 having the same total number of white and black pixels as Xk . The algorithm then repeats the process of voiding and clustering pixels until the black pixel toggled to white is the same pixel that was toggled from white to black. If this is the case, the process has converged with repeated iterations having no eﬀect. A signiﬁcant feature of VAC is that by performing the low-pass ﬁltering by means of circular convolution, the resulting dither pattern has wrap-around characteristics such that tiling a pattern end-to-end creates no apparent discontinuities in texture. This is demonstrated in Fig. 6.19, where we show a 108 × 108 dither pattern representing gray-level 75% along with its 8-point neighboring tiles (left) before and (right) after optimizing minority pixel placement. Shown in Figs. 6.4–

© 2008 by Taylor & Francis Group, LLC

150

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

6.6 are the resulting spatial and spectral metrics using the void-and1 1 , 16 , 18 , 14 , 38 , and 12 . Like cluster with σ = 1.5D for intensities I = 32 simulated annealing with a varying HVS model, the results of void-andcluster can be improved upon if σ is allowed to vary [80] with I as in Figs. 6.23–6.25. Now, as with simulated annealing for generating subsequent gray-levels, the process of toggling bits to create voids and clusters is repeated under the stacking constraint such that the swapping of pixels is restricted to only those pixels corresponding to white pixels in previously constructed patterns of brighter gray-levels and black pixels in previously constructed patterns of darker gray-levels. In doing so, blue-noise dither arrays can now be constructed by means of void-andcluster, and shown in Fig. 6.26 are two such arrays constructed by voidand-cluster with and without tuning σ, along with the magnitudes of their Fourier transforms. Constructed in the order {0, 1, 14 , 34 , 12 , 18 , 38 , 58 , 7 , . . .}, these two dither arrays lead to the gray-scale ramps and images 8 of Figs. 6.29–6.30. Shown in Fig. 6.31 is the resulting gray-scale image using the tuned σ dither array with Ulichney’s edge sharpening applied to the input image prior to halftoning (β = 2).

6.3

BIPPSMA

In order to construct the set {Ig : 0 ≤ g ≤ 1}, Yao and Parker [136] proposed BIPPSMA (binary pattern power spectrum manipulation algorithm) as a process identical to VAC, except that they toggle multiple pixels simultaneously and, thereby, converge at a faster rate. Also, in their version, ﬁltering is done in the Fourier domain by means of the DFT using a low-pass, two-dimensional Butterworth ﬁlter (Fig. 6.32(a)) of the form 1 D2 (f ) = (6.8) |f | 6 1 + c1 f b or of a Gaussian (Fig. 6.32(b)) of the form

|f |2 D2 (f ) = exp − . c2 fb2

(6.9)

The constants c1 and c2 are chosen based on visual evaluations at each gray-level to minimize low-frequency artifacts in Ig .

© 2008 by Taylor & Francis Group, LLC

6.3. BIPPSMA

151

2 RAPSD

RAPSD

2

1

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fg 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

10 RADIAL DISTANCE

20

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

10 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

20

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.20: Spatial and spectral statistics using Ulichney’s void-and1 cluster algorithm with σ = 1.5 for intensity levels (left) I = 32 and 1 (right) I = 16 .

© 2008 by Taylor & Francis Group, LLC

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

152

2 RAPSD

RAPSD

2

1

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fg 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

5 RADIAL DISTANCE

10

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.21: Spatial and spectral statistics using Ulichney’s void-andcluster algorithm with σ = 1.5 for intensity levels (left) I = 18 and (right) I = 14 .

© 2008 by Taylor & Francis Group, LLC

6.3. BIPPSMA

153

2 RAPSD

RAPSD

2

1

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fg 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

5 RADIAL DISTANCE

10

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.22: Spatial and spectral statistics using Ulichney’s void-andcluster algorithm with σ = 1.5 for intensity levels (left) I = 38 and (right) I = 12 .

© 2008 by Taylor & Francis Group, LLC

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

154

2 RAPSD

RAPSD

2

1

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fg 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

10 RADIAL DISTANCE

20

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.23: Spatial and spectral statistics using Ulichney’s void-and1 cluster algorithm with σ = 2.5 for intensity levels (left) I = 32 and 1 (right) I = 16 .

© 2008 by Taylor & Francis Group, LLC

6.3. BIPPSMA

155

2 RAPSD

RAPSD

2

1

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fg 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

5 RADIAL DISTANCE

10

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.24: Spatial and spectral statistics using Ulichney’s void-andcluster algorithm with σ = 2.5 for intensity levels (left) I = 18 and (right) I = 14 .

© 2008 by Taylor & Francis Group, LLC

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

156

RAPSD

8

RAPSD

4

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

1 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

5 RADIAL DISTANCE

10

fg 0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.25: Spatial and spectral statistics using Ulichney’s void-andcluster algorithm with σ = 2.5 for intensity levels (left) I = 38 and (right) I = 12 .

© 2008 by Taylor & Francis Group, LLC

6.3. BIPPSMA

157

Figure 6.26: Two dither arrays constructed using Ulichney’s void-andcluster algorithm with (top) σ = 1.5 for all intensity levels and (bottom) σ tuned to the intensity, and the magnitude of its corresponding Fourier transform.

© 2008 by Taylor & Francis Group, LLC

158

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

Figure 6.27: Gray-scale ramp halftoned using a dither array constructed by Ulichney’s void-and-cluster algorithm with σ = 1.5 for all intensities.

© 2008 by Taylor & Francis Group, LLC

6.3. BIPPSMA

159

Figure 6.28: Gray-scale image halftoned using a dither array constructed by Ulichney’s void-and-cluster algorithm with σ = 1.5 for all intensities.

© 2008 by Taylor & Francis Group, LLC

160

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

Figure 6.29: Gray-scale ramp halftoned using a dither array constructed by Ulichney’s void-and-cluster algorithm with σ tuned to the corresponding intensities.

© 2008 by Taylor & Francis Group, LLC

6.3. BIPPSMA

161

Figure 6.30: Gray-scale image halftoned using a dither array constructed by Ulichney’s void-and-cluster algorithm with σ tuned to the corresponding intensities.

© 2008 by Taylor & Francis Group, LLC

162

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

Figure 6.31: Gray-scale image halftoned using a dither array constructed by Ulichney’s void-and-cluster algorithm with σ tuned to the corresponding intensities and Ulichney’s edge-sharpening applied to the input image prior to halftoning (β = 2).

© 2008 by Taylor & Francis Group, LLC

6.4. DITHER PATTERN ORDERING

163

An advantage to Yao’s and Parker’s algorithm is that the characteristics of the human visual system [18, 120] can be accounted for to allow increased spectral energy along the diagonals by using the twodimensional ﬁlter, D2 (f ), with an angular weighting function (Fig. 6.32 (c)) such that D2 (f ) = [1 + 0.2 cos(4θf )]D2 (f ), (6.10) where θf is the angle of the point f from the horizontal axis in the frequency plane. Shown in Figs. 6.33–6.35 are the resulting spatial and spectral characteristics of binary dither patterns created using a 1 1 1 Gaussian ﬁlter for gray-levels g = 31 , 15 , 7 , 3 , 5 , and 12 (I = 32 , 16 , 8, 32 16 8 4 8 1 3 1 , , and ). 4 8 2

6.4

Dither Pattern Ordering

While the component dither patterns forming a blue-noise dither array may, in most cases, be constructed in any order, numerous studies have shown that, because of the stacking constraint, the ordering to which patterns are generated aﬀects the visual quality of the resulting dither array and that constructing patterns in a random order may lead to better visual ﬁdelity than by generating patterns in the order of increasing or decreasing gray-levels [67]. As such, the preferred orderings are the ones that maximize the spacing between consecutive gray-levels such that previously constructed patterns have the least amount of inﬂuence on the current dither pattern. In general, the best dither arrays are generated by inter-leaving gray-levels starting with the levels g = 0, 1, 14 , 34 , and 12 and then generating the four patterns corresponding to the mid-way points between these ﬁve patterns. Then, the next patterns to be generated are then ones falling mid-way between these nine levels and repeating this process of dividing in half the current ranges until all 256 patterns are generated. To see the eﬀects of dither array construction order, Fig. 6.36 shows four 150 × 150 (256 gray-levels) dither arrays constructed by means of Yao and Parker’s BIPPSMA with array (a) constructed using 1 the sequential order {0, 1, Δ, 2Δ, . . . , 1 − 2Δ, 1 − Δ}, where Δ = 255 ; 1 1 1 1 1 array (b) constructed using the order {0, 1, 2 , 2 − Δ, 2 + Δ, 2 − 2Δ, 2 + 2Δ, . . . , Δ, 1 − Δ}; array (c) constructed using the order {0, 1, 14 , 34 , 14 + Δ, 34 − Δ, 14 + 2Δ, 34 − 2Δ, . . . , 12 − Δ, 12 + Δ, 12 , 14 − Δ, 34 + Δ, 14 − 2Δ, 34 + 2Δ, . . . , Δ, 1−Δ}; and array (d) constructed using the ordering {0, 1, 14 , 3 1 1 3 5 7 , , , , , , . . .}. Shown in Fig. 6.37 are the resulting magnitudes 4 2 8 8 8 8

© 2008 by Taylor & Francis Group, LLC

CHAPTER 6. BLUE-NOISE DITHER ARRAYS

164

1

0.5

0 1 1

0 VERTICAL FREQUENCY

0 ï1

ï1

HORIZONTAL FREQUENCY

(a) low-pass, two-dimensional Butterworth ﬁlter for BIPPSMA 1

0.5

0 1 1

0 VERTICAL FREQUENCY

0 ï1

ï1

HORIZONTAL FREQUENCY

(b) low-pass, two-dimensional Gaussian ﬁlter for BIPPSMA 1.2 1 0.8

0 1 1

0

0

VERTICAL FREQUENCY

ï1

ï1

HORIZONTAL FREQUENCY

(c) angular weighting function Figure 6.32: Spectral shaping ﬁlters used in Yao’s and Parker’s BIPPSMA [136].

© 2008 by Taylor & Francis Group, LLC

6.4. DITHER PATTERN ORDERING

2 RAPSD

RAPSD

2

165

1

1

fg 0.5 RADIAL FREQUENCY

10 0 ï10 0

PAIR CORRELATION

0.7071

ANISOTROPY

0

fg 0

0.5 RADIAL FREQUENCY

2

1

hg 0 0

10 RADIAL DISTANCE

20

0

0.5 RADIAL FREQUENCY

0.7071

0

0.5 RADIAL FREQUENCY

0.7071

10 0 ï10

0.7071 PAIR CORRELATION

ANISOTROPY

0

2

1

hg 0 0

5 RADIAL DISTANCE

//2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

10

//2

0 2

/

2

1 0 1 DIRECTIONAL DISTRIBUTION

0 2

Figure 6.33: Spatial and spectral statistics using Yao’s and Parker’s 1 [136] BIPPSMA with a Gaussian ﬁlter for intensity levels (left) I = 32 1 and (right) I = 16 .

© 2008 by Taylor & Francis Group,