Image hatching for visual cryptography

Published:

Abstract-Image hatching (or non-photorealistic line-art) is a technique widely applied in the printing or engraving of currency. Diverse styles of brush strokes have previously been adopted for different areas of an image to create textures and shading. Because there is no continuous tone within these types of images, we propose a multi-level scheme, which uses different textures based on a threshold level. These textures are then applied to the different levels and are then combined to build up the final image. We propose a technique by which one can hide a secret using visual cryptography (VC) within the hatched images. Visual cryptography provides a very powerful means by which one secret can be distributed into two or more pieces known as shares. When the shares are superimposed exactly together, the original secret can be discovered without computer participation.

Keywords-Visual cryptography; secret sharing; image hatching

INTRODUCTION

Visual cryptography (VC) is a powerful technique which combines the notions of perfect ciphers and secret sharing in cryptography with that of raster graphics. A binary image can be divided into shares which can be stacked together to approximately recover the original image. In this paper, we extend the notion of VC to that of hatched images. More- over, we propose the use of this technique for authenticating hatched images by embedding a message inside which can only be revealed if the corresponding secret hatched mask is superimposed upon the image.

Lady using a tablet
Lady using a tablet

Professional

Essay Writers

Lady Using Tablet

Get your grade
or your money back

using our Essay Writing Service!

Essay Writing Service

Image hatching [1] in general is a series of similar strokes which use various lengths, angles, mutual space, and other properties of lines to represent parts of an image. These strokes give depth and shape to the image. For example, a dark part of an image would be represented by strokes that are very close together. Conversely, a lighter section of an image would be represented by strokes that are further apart. For any hatching scheme, the appropriate level of detail should be retained such that the image is still recog- nizable. Specific items such as clothing, facial features, and expressions should be unambiguously rendered. This type of non-photorealistic (NPR) line-art drawing has been highly successful over the years, with its roots in line engraving [2], classical drawing [3] and wood carving [4].

The proposed technique of image hatching in this paper differs significantly from the existing techniques in how the final hatched images are generated. As with existing methods, the strokes or textures utilized will create the correct shadows and tones to convey a realistic image with appropriate shading. The scheme developed within this paper can be applied to any grayscale image in order to get a NPR hatched version; examples are shown of human faces and physical buildings. We take these ideas and extend them into the VC domain and develop a novel scheme to generate suitable hatched images capable of hiding VC shares.

Figure 1 provides an example of our algorithm working on an image of the Birdsnest stadium. Figure 1(b) and Fig- ure 1(c) provide a comparison between a real-time hatching technique [5] and our newly proposed line-art based scheme. A more detailed image of Lena is used later within this paper to illustrate the process on a human face and to show the versatility of our algorithm.

Image hatching for VC can be used for specialized image authentication applications. For example, it can be used as a protection mechanism against counterfeiting of currency. Unique random masks can be employed to verify these specially created hatched images and used specifically in identifying counterfeit polymer banknotes adopted world- wide. This security can be achieved through VC.

RELATED WORK

Digital engraving techniques have been demonstrated [6] using binary and colour images. Ostromoukhov deals with 2D images and corresponds to work based on line-art [7], [8], [9]. It specifically deals with reproducing a human face as accurately as possible while maintaining the traditional copperplate engraving style. Other impressive pen-and-ink illustrations have been presented within [10], [11]; these use a brush stroke style when reproducing the textures and shading, rather than a thinner line style.

Real-time hatching techniques have also been examined in 2001 [5]. The techniques discussed within [5] employ a tonal art map. This map scans the image or scene and creates a texture for it, after which a tone is generated which attempts to maintain spatial and temporal coherence. However, this technique primarily relies on 3D models for it to work correctly. A comparison between our technique and this real-time technique can be viewed in Figure 1.

Lady using a tablet
Lady using a tablet

Comprehensive

Writing Services

Lady Using Tablet

Plagiarism-free
Always on Time

Marked to Standard

Order Now

Image sharing using VC defines a scheme which is identical to that of general secret sharing [12]. In (k, n) image sharing, the image that carries the secret is split up into n pieces and the decryption is totally unsuccessful unless at least k pieces are collected and superimposed. A visual cryptography scheme (VCS) provides a mechanism by which physically superimposing two pieces (known as shares) of an image is able to securely recover the secret.

The techniques developed within this paper help to further the security of printed images in that they provide an authentication method. A novel image hatching technique is also presented which allows images to be converted to a style which is similar to techniques currently in use in today's currency. The properties of these hatched images make them very suitable for use in conjunction with VC. They are halftone [13] images in that they are binary images. The distance between the pixels indicates the textures and shading which are used to simulate the gray levels.

Protection and authentication of digital content, particularly printed images, is a hugely important factor in today's world [14], especially when dealing with currency. Securely protecting these items can be achieved using VC. These VC techniques have been successfully applied using watermark- ing techniques and steganography.

Many visual cryptography schemes that have been developed, regardless of image type, binary/halftone [15], [16], or colour [17], deal primarily with sharing a single secret. We use the idea of single secret sharing within this paper. Further development of these schemes would increase the capability of possibly hiding multiple secrets within these hatched images [18], [19], [20]. We also use an image size invariant form of VC which allows the VC shares to be the same size as the original secret [21].

There are three novel outcomes described in this paper:

(1) Definition of a new technique which easily allows the creation of an NPR image, similar to that of a bank note; (2) Definition of a method that will allows us to use these hatched images as a cover image for the VC shares. This should allow us to embed a secure share within the hatched image; (3) Extend the above definition to correspond to multiple hatched shares. Superimposing the hatched images should reveal the secret.

These techniques allow multiple, secure, validation and identification marks on the cover image. If these VC shares cannot be located or recovered, image tampering should be assumed and thus the validity of the image cannot be trusted. The main difference between this scheme and other halftone schemes is that our scheme uses a series of lines, the corresponding space between those lines gives the image the correct shape and shading, whereas other halftone images used in other schemes use dot clustering to achieve the same effects.

The remainder of this paper is set out as follows: Section III details our contributions and proposed techniques; Section IV provides a security analysis of the proposed scheme; the results are displayed in Section V; the final conclusions are drawn in Section VI.

OUR CONTRIBUTION

Image Hatching

Our proposed scheme consists of eight different textures (line styles) which are used for the various shading effects. Let S represent the set of textures, such that si ? S where si is one of the texture patterns and i = 1, 2, . . . , 8. Figure 2 illustrates these textures.

The next step involves taking multiple threshold levels of the original grayscale image to allow the textures to be applied. Because there are eight different textures, we must also obtain eight different threshold levels from the image to which each of the strokes can be applied.

Let pij ε P , P is the set of all pixels and pij =

0, . . . , 255 where pij represents the pixels grayscale value,

i = 1, 2, . . . , W and j = 1, 2, . . . , H . W and H represent the images width and height respectively. For example, the pixel at coordinate position (0, 0) with the grayscale value 34 would be represented like this: p0,0 = 34.

Our threshold function examines P eight different times based on a different grayscale level each time, tk ε T , k = 1, 2, . . . , 8, tk represents the current grayscale threshold of the image. If 0 ? pij < 32k, draw a black pixel, otherwise draw a white pixel. This process is performed for each grayscale threshold. For example, grayscale level k = 4 would fall between: 0 ? pij < 128 which corresponds to the threshold image within Figure 3(d).

Lady using a tablet
Lady using a tablet

This Essay is

a Student's Work

Lady Using Tablet

This essay has been submitted by a student. This is not an example of the work written by our professional essay writers.

Examples of our work

Firstly, the eight hatching textures from Figure 2 are created. The textures are then applied to the thresholds using Eq. (1). This works as follows: each of the textures need to be applied to its corresponding threshold so as to create the set of thresholds with their corresponding textures (Figure 4). The first pair are taken s1 and t1 , and Eq. (1) is applied. At the pixel level, this operation can be represented mathematically, where v is the pixel value returned, max is the largest pixel value, si represents the pixel values in the texture image and ti represents the pixel values in the threshold image.

(max -ti )

Image Hatching with VC

Traditional VC shares are very effective in terms of secret sharing, but pixel expansion tends to be a problem. Pixel expansion occurs due to how the VC shares are created. Typically one pixel is expanded into a 2 - 2 block of pixels, which is used to represent the original pixel. This results in the final shares being twice the size of the original secret after encryption. Size invariant shares have the potential for better results, they have no pixel expansion and offer quality similar to that of the traditional schemes. We utilize the scheme proposed in [21] when creating the shares for our scheme.

Once the hatched image has been generated, a secret of the same size is chosen. The secret is not required to be a hatched image, any secret can be used. The size invariant VC scheme is applied to the secret in order to generate the two shares. To embed the first share successfully within the hatched image we need to alter it. This involves reducing its overall pixel density. This reduction in pixel density is a tradeoff between security and visually being able to hide the share within the hatched image. It lowers the recovered secret's overall contrast but allows the embedded hatched image to remain inconspicuous. Contrast is an extremely important part of any VC scheme [22], [23] because it determines the visibility of the recovered secret.

Reducing the shares density involves cutting or removing vertical or horizontal strips from the first share image. This allows the share to be embedded, without distorting the hatched image too significantly, while keeping its secure properties and retaining enough data in order to successfully recover the secret. This cutting process removes specific pixels, either at random, or on a row or column basis. This allows for easy insertion of the share into the hatched image without dramatically altering the overall hatched images quality.

v = max -(max -si ) - max

Three separate schemes are defined here for using the second share in order to recover the secret. The first, used in Figure 7, leaves the second share unaltered, resulting in a non-hatched random mask for the hatching cover image and its embedded VC share. This provides an overall darker contrast after the secret has been revealed. The second scheme, illustrated in Figure 8, involves creating a secure hatched mesh. Patterns from S are chosen, namely s6 and s8 and are then applied to the second share. This hatched mesh share is used to recover the embedded secret. The final scheme is presented in Figure 9. Each share is embedded into a hatched image, using the same cutting process described above. Superimposing these hatched images reveals the secret. Figure 5 provides a flowchart of these prospective schemes.

SECURITY ANALYSIS

The security of our proposed scheme rests primarily with VC but also the cover images. Firstly, our chosen size invariant VC scheme is secure in that given any amount of sub-pixels from a single share, it is impossible to tell if the corresponding shares sub-pixels represent a black or a white pixel before superimposing them. This means that even if the complete VC share pattern is discovered within the cover image, working out its corresponding share is highly difficult. Traditional VC shares can also be employed within this scheme. This does mean that the secrets have to be half the size of the hatched image in terms of dimensions (due to the pixel expansion) but it also means the security of this scheme holds up very well, which has been well documented in the literature [24].

Nothing about the secret can be deduced based on analysis of either the cover image or the revealing share. After the share has been embedded, certain pixels overlap, this also impedes analysis because it remains uncertain if that overlapped pixel belongs to the original cover image or the actual embedded share itself.

Secondly, the hatched image is visually pleasing which helps to draw attention away from any encryption or noise the embedded shares may generate. This alleviates any suspi- cion that encryption has taken place, thus further increasing the overall secrecy of the embedded shares by increasing their imperceptibility.

EXPERIM ENTAL RESULTS

In this section, we provide the results and commentary on each of the expected outcomes discussed previously in Section II. All code was developed in Python 2.5 using the Python Imaging Library 1.1.6.

Figure 6(a) shows the original Lena image, its binary halftone equivalent is in Figure 6(b) (created using Floyd- Steinberg dithering) and the newly created hatched image based on our proposed scheme is located in Figure 6(c). Notice the different contours and line directions to give the image the correct depth and feel. The dark parts of the image show up correctly in that they have a very thick texture pattern applied to them. The brighter parts have a lighter texture pattern on them so that they do not show up completely white. This is very similar to the engraving techniques discussed previously. All the specific facial features such as the mouth, nose, and eyes are all correctly displayed along with the hat and feathers. The frame of the mirror is also clearly visible and defined. This supports our first expected outcome.

Figure 7 and Figure 8 highlight expected outcome two and provides the results. The hatched cover image is still very legible with the embedded VC share. The second share can then be used to recover the secret. This provides a very useful technique for practical applications in terms of verification and identification of images. This type of technique could be adapted to check the validity of currency because of its secure properties previously discussed.

Figure 9 shows how we achieved expected outcome three. Two VC shares are hidden within two separate hatched images. Figure 9(a) and 9(b) illustrate the final hatched images with the embedded shares. The resultant secret after superimposing each of these hatched images can be viewed in Figure 9(c). The secret is visible, however due to the nature of this scheme, the contrast suffers when the secret is recovered. The text is clearly visible, but this would be a potential area for improvement.

CONCLUSION

In this paper, we have developed a novel hatching scheme for images which embed a secret using VC. This technique can be used for image authentication. For image hatching, generating similar patterns to those used in the engraving and printing of currency can be accomplished. Generating these hatched images using a threshold based approach has proved to be very effective and easy to implement. One of the key strengths of the scheme is that it can take a multitude of images and apply these hatching styles to them. No specific type of image is required. This would allow for easy application in the currency domain with respect to generating suitable images based on current up-to-date techniques.

Using these hatched patterns, we have described various ways of embedding basic VC shares within them. The dot patterns are small enough so that they can be hidden within similar regions of an appropriate image, but also remain very legible and clear after the secret recovery has taken place.

This type of secret embedding could have various po- tential secure applications, particulary within the banking industry. Protecting high value cheques, for authentication and identification purposes using our techniques could easily be applied.

REFERENCES

  1. G. Elber, "Line art illustrations of parametric and implicit forms," IEEE Transactions on Visualization and Computer Graphics, vol. 4, no. 1, pp. 71-81, 1998.
  2. W. M. Ivins, How Prints Look, Photographs with Commen- tary, revised ed. Boston: Beacon Press, 1987.
  3. --, Prints and Visual Communication, eighth printing. MIT Press, 1992.
  4. P. N. Hasluck, Manual of Traditional Wood Carving. New York: Dover Publications, 1977.
  5. E. Praun, H. Hoppe, M. Webb, and A. Finkelstein, "Real-time hatching," in SIGGRAPH '01, New York, NY, USA, 2001, pp. 581-586.
  6. V. Ostromoukhov, "Digital facial engraving," in SIGGRAPH '99, New York, NY, USA, 1999, pp. 417-424.
  7. G. Elber, "Line Art Rendering via a Coverage of Isoparamet- ric Curves," IEEE Transactions on Visualization and Com- puter Graphics, vol. 1, no. 3, pp. 231-239, September 1995.
  8. --, "Line Illustrations in Computer Graphics," The Visual Computer, vol. 11, no. 6, pp. 290-296, June 1995.
  9. --, "Line Art Illustrations of Parametric and Implicit Forms," IEEE Transactions on Visualization and Computer Graphics, vol. 4, no. 1, pp. 71-81, January 1998.
  10. M. Salisbury, C. Anderson, D. Lischinski, and D. H. Salesin, "Scale-dependent reproduction of pen-and-ink illustrations," in SIGGRAPH '96, New York, NY, USA, 1996, pp. 461-468.
  11. M. P. Salisbury, S. E. Anderson, R. Barzel, and D. H. Salesin, "Interactive pen-and-ink illustration," in SIGGRAPH '94, New York, NY, USA, 1994, pp. 101-108.
  12. A. Shamir, "How to share a secret," Communications of the ACM, vol. 22, no. 11, pp. 612-613, 1979.
  13. D. L. Lau and G. R. Arce, Modern Digital Halftoning. Marcel Dekker, 2000.
  14. N. Memon and P. W. Wong, "Protecting digital media con- tent," Communications of the ACM, vol. 41, no. 7, pp. 35-43, 1998.
  15. G. Ateniese, C. Blundo, A. D. Santis, and D. R. Stinson, "Extended schemes for visual cryptography," Theoretical Computer Science, vol. 250, pp. 1-16, June 1996.
  16. Z. Zhou, G. R. Arce, and G. D. Crescenzo, "Halftone vi- sual cryptography," IEEE Transactions on Image Processing, vol. 15, no. 8, pp. 2441-2453, August 2006.
  17. Y. C. Hou, C. Y. Chang, and S. F. Tu, "Visual cryptography for color images based on halftone technology," Proceedings of International Conference on Image, Acoustic, Speech and Signal Processing, Part 2, 2001.
  18. J.-B. Feng, H.-C. Wu, C.-S. Tsai, Y.-F. Chang, and Y.-P.
  19. Chu, "Visual secret sharing for multiple secrets," Pattern Recognition, vol. 41, no. 12, pp. 3572-3581, 2008.
  20. H.-C. Hsu, T.-S. Chen, and Y.-H. Lin, "The ringed shadow image technology of visual cryptography by applying diverse rotating angles to hide the secret sharing," Networking, Sens- ing and Control, vol. 2, pp. 996-1001, 2004.
  21. S. J. Shyu, S.-Y. Huang, Y.-K. Lee, R.-Z. Wang, and K. Chen, "Sharing multiple secrets in visual cryptography," Pattern Recognition, vol. 40, no. 12, pp. 3633-3651, 2007.
  22. R. Ito, H. Kuwakado, and H. Tanaka, "Image size invariant visual cryptography," Institute of Electronic, Information and Communication Engineers Transactions, vol. E82-A, no. 10, pp. 2172 - 2177, October 1999.
  23. C. Blundo, P. D'Arco, A. D. Santis, and D. R. Stinson, "Contrast optimal threshold visual cryptography schemes," SIAM Journal on Discrete Mathematics, vol. 16, no. 2, pp. 224-261, 2003.
  24. C.-N. Yang, C.-C. Wang, and T.-S. Chen, "Real perfect contrast visual secret sharing schemes with reversing," in ACNS, 2006, pp. 433-447.
  25. A. De Bonis and A. De Santis, "Randomness in secret sharing and visual cryptography schemes," Theoretical Computer Science, vol. 314, no. 3, pp. 351-374, 2004.