Calligraphic Packing Jie Xu Craig S. Kaplan Computer Graphics Lab David R. Cheriton School of Computer Science University of Waterloo GI'07 May 28, 2007
Outline 1 Background of NPR Packing Artistic Packing Text Packing Challenge of Calligraphic Packing 2 Approach The procedure of our system Container extraction Container subdivision Letter Warping 3 Results and conclusion
Artistic Packing Representing a large image from smaller, recognizable elements. It has been explored by many artists. Giuseppe Arcimboldo Sandro Del-Prete
Image Packing Hausner, Simulating decorative mosaics, SIGGRAPH 2001. Dalal et al., A spectral approach to NPR packing, NPAR 2006. Kaplan and Salesin, Escherization, SIGGRAPH 2000.
NPR packing Kim and Pellacini, Jigsaw image mosaics, SIGGRAPH 2002. Gal et al., Non-realistic expressive modeling, SIGGRAPH 2006 sketch.
Transfer to Text Use text to tile a shape. Letters should be legible. Letters can stand a signicant amount of deformation.
Transfer to Text Jigsaw image mosaics: only support minor deformation. Decorative mosaics and spectral packing: aim at packing a large number of small elements without deformation. Escherization: tile a plane with a lot of copies of one deformed shape strictly. Expressive modeling: compose 3D shapes with rigid motion.
Islamic Calligraphy by Hassan Musa
Representational Calligraphy by AlmapBBDO
Representational Calligraphy
Calligraphic Packing It is a combination of calligraphy and packing. Given a region and a sequence of letters, construct a non-overlapping arrangement of deformed glyphs. The glyphs ll the region as much as possible. Glyphs are recognizable. The arrangement should follow the order of these letters.
Algorithm Convert an image into a container. Subdivide image into regions. Warp the letters into these regions. elephant
Container Extraction Use graph-cut algorithm to remove background. Apply Gaussian blur to smooth the image. Threshold the image to produce a bi-level result. (a) (b) (c) (d)
Subdivision Set the starting arrangement of letters. Run a level-set algorithm to grow letters and cluster pixels. Use Lloyd's method to create an even arrangement.
Convert Regions into Paths Smooth the boundaries of regions by morphological operations. Trace the boundary to extract paths.
Warping Create a mapping from the convex hull of glyph to the subregion. Given the convex hull C i of glyph and the subregion R i. Do convex partition for the subregion. Place the same number of sample points around C i and R i. Select a correspondence. Create subdivision for the convex hull. Do warping in each convex piece.
Warping Create a mapping from the convex hull of glyph to the subregion. Given the convex hull C i of glyph and the subregion R i. Do convex partition for the subregion. Place the same number of sample points around C i and R i. Select a correspondence. Create subdivision for the convex hull. Do warping in each convex piece.
Warping Create a mapping from the convex hull of glyph to the subregion. Given the convex hull C i of glyph and the subregion R i. Do convex partition for the subregion. Place the same number of sample points around C i and R i. Select a correspondence. Create subdivision for the convex hull. Do warping in each convex piece.
Warping Create a mapping from the convex hull of glyph to the subregion. Given the convex hull C i of glyph and the subregion R i. Do convex partition for the subregion. Place the same number of sample points around C i and R i. Select a correspondence. Create subdivision for the convex hull. Do warping in each convex piece.
Warping Create a mapping from the convex hull of glyph to the subregion. Given the convex hull C i of glyph and the subregion R i. Do convex partition for the subregion. Place the same number of sample points around C i and R i. Select a correspondence. Create subdivision for the convex hull. Do warping in each convex piece.
Warping Create a mapping from the convex hull of glyph to the subregion. Given the convex hull C i of glyph and the subregion R i. Do convex partition for the subregion. Place the same number of sample points around C i and R i. Select a correspondence. Create subdivision for the convex hull. Do warping in each convex piece.
Warping Create a mapping from the convex hull of glyph to the subregion. Given the convex hull C i of glyph and the subregion R i. Do convex partition for the subregion. Place the same number of sample points around C i and R i. Select a correspondence. Create subdivision for the convex hull. Do warping in each convex piece.
Geometric Shape Cost Use \shape context" to measure the similarity of two shapes. Compute a log-polar histogram for every reference point. Compute the geometric similarity 4 g as the sum of histogram distance between all pairs of points. ¹ ¹ ¹ ¹ ¹ ¹ ¹ ¹ ¹ ¹ º º º º º º º º º º»»»»»»»»»»»» ¼ ¼ ¼ ¼ ¼ ¼ ¼ ¼ ¼ ¼ ½ ½ ½ ½ ½ ½ ½ ½ ½ ½ ¾ ¾ ¾ ¾ ¾ ¾ ¾ ¾ ¾ ¾ À À À À À À À À À À Á Á Á Á Á Á Á Á Á Á Á Á Â Â Â Â Â Â Â Â Â Â Ã Ã Ã Ã Ã Ã Ã Ã Ã Ã Ã Ã Ä Ä Ä Ä Ä Ä Ä Ä Ä Ä Å Å Å Å Å Å Å Å Å Å Å Å Æ Æ Æ Æ Æ Æ Æ Æ Æ Æ Ç Ç Ç Ç Ç Ç Ç Ç Ç Ç È È È È È È È È È È É É É É É É É É É É É É Ê Ê Ê Ê Ê Ê Ê Ê Ê Ê Ë Ë Ë Ë Ë Ë Ë Ë Ë Ë Ì Ì Ì Ì Ì Ì Ì Ì Ì Ì Í Í Í Í Í Í Í Í Í Í Í Í Î Î Î Î Î Î Î Î Î Î Ï Ï Ï Ï Ï Ï Ï Ï Ï Ï Ï Ï Ð Ð Ð Ð Ð Ð Ð Ð Ð Ð Ñ Ñ Ñ Ñ Ñ Ñ Ñ Ñ Ñ Ñ Ò Ò Ò Ò Ò Ò Ò Ò Ò Ò Ó Ó Ó Ó Ó Ó Ó Ó Ó Ó Ô Ô Ô Ô Ô Ô Ô Ô Ô Ô Õ Õ Õ Õ Õ Õ Õ Õ Õ Õ Õ Õ Ö Ö Ö Ö Ö Ö Ö Ö Ö Ö Ø Ø Ø Ø Ø Ø Ø Ø Ø Ø Ù Ù Ù Ù Ù Ù Ù Ù Ù Ù Ù Ù Ú Ú Ú Ú Ú Ú Ú Ú Ú Ú Û Û Û Û Û Û Û Û Û Û Û Û Ü Ü Ü Ü Ü Ü Ü Ü Ü Ü Ý Ý Ý Ý Ý Ý Ý Ý Ý Ý Ý Ý Þ Þ Þ Þ Þ Þ Þ Þ Þ Þ ß ß ß ß ß ß ß ß ß ß à à à à à à à à à à á á á á á á á á á á á á â â â â â â â â â â ã ã ã ã ã ã ã ã ã ã ã ã ä ä ä ä ä ä ä ä ä ä å å å å å å å å å å æ æ æ æ æ æ æ æ æ æ ç ç ç ç ç ç ç ç ç ç è è è è è è è è è è é é é é é é é é é é é é ê ê ê ê ê ê ê ê ê ê ë ë ë ë ë ë ë ë ë ë ë ë ì ì ì ì ì ì ì ì ì ì í í í í í í í í í í î î î î î î î î î î ï ï ï ï ï ï ï ï ï ï ï ï ð ð ð ð ð ð ð ð ð ð ñ ñ ñ ñ ñ ñ ñ ñ ñ ñ ñ ñ ò ò ò ò ò ò ò ò ò ò ó ó ó ó ó ó ó ó ó ó ó ó ô ô ô ô ô ô ô ô ô ô õ õ õ õ õ õ õ õ õ õ ö ö ö ö ö ö ö ö ö ö ø ø ø ø ø ø ø ø ø ø ù ù ù ù ù ù ù ù ù ù ù ù ú ú ú ú ú ú ú ú ú ú û û û û û û û û û û û û ü ü ü ü ü ü ü ü ü ü ý ý ý ý ý ý ý ý ý ý þ þ þ þ þ þ þ þ þ þ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ ÿ!!!!!!!!!! " " " " " " " " " " # # # # # # # # # # $ $ $ $ $ $ $ $ $ $ % % % % % % % % % % & & & & & & & & & & ' ' ' ' ' ' ' ' ' ' ' ' ( ( ( ( ( ( ( ( ( ( ) ) ) ) ) ) ) ) ) ) * * * * * * * * * * + + + + + + + + + + + +,,,,,,,,,, - - - - - - - - - - - -.......... / / / / / / / / / / 0 0 0 0 0 0 0 0 0 0 1 1 1 1 1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2 2 2 3 3 3 3 3 3 3 3 3 3 3 3 4 4 4 4 4 4 4 4 4 4 5 5 5 5 5 5 5 5 5 5 6 6 6 6 6 6 6 6 6 6 7 7 7 7 7 7 7 7 7 7 8 8 8 8 8 8 8 8 8 8 9 9 9 9 9 9 9 9 9 9 : : : : : : : : : : ; ; ; ; ; ; ; ; ; ; ; ; < < < < < < < < < < = = = = = = = = = = > > > > > > > > > >?????????? @ @ @ @ @ @ @ @ @ @ A A A A A A A A A A B B B B B B B B B B C C C C C C C C C C D D D D D D D D D D E E E E E E E E E E F F F F F F F F F F G G G G G G G G G G H H H H H H H H H H I I I I I I I I I I J J J J J J J J J J K K K K K K K K K K L L L L L L L L L L M M M M M M M M M M θ log r
Orientation Cost Orientation is important to preserve legibility. Use a least-square method to compute the rigid motion from original glyph to warped one. From the rotation angle, we dene the orientation cost: 4 o = =.
Area Cost Warped glyphs should ll the subregions as much as possible. Area cost is dened as: 4 a = 1 A w =A r.
Total Cost Shape matching cost is 4 = 4 g + 4 o +4 a. cost=0.328 cost=0.369 cost=0.371 cost=0.429 cost=0.512
Warping Multiple Typefaces For each letter, we warp lowercase and uppercase glyphs from multiple typefaces. cost=0.324 cost=0.396 cost=0.333 cost=0.376 cost=0.469 cost=0.456 cost=0.36 cost=0.463
Rendering Styles Perturb boundaries of letters with random osets. Fill letters with streamlines.
Rendering Styles Perturb boundaries of letters with random osets. Fill letters with streamlines. freedom & slavery successful
Results
Results monalisa
Results monalisa lose & win
Results
Results niao (bird)
Results niao (bird) muse
Results
Results laugh & cry
Results laugh & cry graceful
Results laugh & cry graceful Da Vinci code
Conclusion and Future Work Distribute letters automatically. Improve the letter deformation model.
Questions?
User-Specied Subdivision User-specied clustering. User-specied exclusion.