AU742875B2 - Method and apparatus for generating a distance image of an original image - Google Patents

Method and apparatus for generating a distance image of an original image Download PDF

Info

Publication number
AU742875B2
AU742875B2 AU60647/99A AU6064799A AU742875B2 AU 742875 B2 AU742875 B2 AU 742875B2 AU 60647/99 A AU60647/99 A AU 60647/99A AU 6064799 A AU6064799 A AU 6064799A AU 742875 B2 AU742875 B2 AU 742875B2
Authority
AU
Australia
Prior art keywords
ordinate
image
pixel
ordinates
pixels
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Ceased
Application number
AU60647/99A
Other versions
AU6064799A (en
Inventor
Michael Richard Arnold
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Canon Inc
Original Assignee
Canon Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Priority claimed from AUPP7405A external-priority patent/AUPP740598A0/en
Application filed by Canon Inc filed Critical Canon Inc
Priority to AU60647/99A priority Critical patent/AU742875B2/en
Publication of AU6064799A publication Critical patent/AU6064799A/en
Application granted granted Critical
Publication of AU742875B2 publication Critical patent/AU742875B2/en
Anticipated expiration legal-status Critical
Ceased legal-status Critical Current

Links

Description

kl'' ;t u S&F Ref: 482995
AUSTRALIA
PATENTS ACT 1990 COMPLETE SPECIFICATION FOR A STANDARD PATENT
ORIGINAL
Name and Address of Applicant: Actual Inventor(s): Address for Service: Canon Kabushiki Kaisha 30-2, Shimomaruko 3-chome Ohta-ku Tokyo Japan Michael Richard Arnold Spruson Ferguson St Martins Tower 31 Market Street Sydney NSW 2000 Method and Apparatus for Generating a Distance Image of an Original Image Invention Title: ASSOCIATED PROVISIONAL APPLICATION DETAILS [33] Country [31] Applic. No(s) AU PP7405 The following statement is a full description of this invention, performing it known to me/us:- [32] Application Date 27 November 1998 including the best method of 5815c METHOD AND APPARATUS FOR GENERATING A DISTANCE IMAGE OF AN ORIGINAL IMAGE Field of Invention The present invention relates to a method and apparatus for generating a distance image of an original image. The invention also relates to a computer readable medium comprising a computer program for generating a distance image of an original image.
The present invention still further relates to a method and apparatus for generating a representation of voronoi regions of an original image. The invention also relates to a computer readable medium comprising a computer program for generating a representation of voronoi regions of an original image.
Background The generation of a distance image by a distance transform is an important step in many image-processing tasks such as offset generation, kerning, and matching. For example, a distance image is used in pattern matching for identifying high level features 15 of objects in an image.
The publication "Hierarchical Chamfer Matching: A Parametric Edge Matching Algorithm by Gunilla Borgefors, IEEE Transactions on Pattern Analysis and Machine Intelligence, Vol. 10 No. 6 November 1988 discloses at page 851 a sequential distance transform DT used in image processing. In the Borgefors sequential DT transform, the processing starts from the image, where each edge pixel is set to zero and each non-edge pixel is set to infinity. Two passes are made over the image, first "forward" from left to right and from top to bottom; and then "backward" from right to left and from bottom to top. During the "forward" scan, the transform determines for each scanned pixel the following distance measure vij minimum (vi-lj.
1 4, vi-lj vi-lj+i vi,j_ 3, vij), 25 where (ij) is the pixel position. During the "backward" scan, the transform determines for each scanned pixel the following distance measure vij minimum (vij, vij+l vi+lj-i vi+lj 3, vi+lj+l However, the use of this distance transform DT suffers from the disadvantage that the resultant distance image is very block-like when the object is circular or has another gradually increasing boundary.
Summary of the Invention It is an object of the present invention to ameliorate one or more disadvantages of the prior art.
According to one aspect of the invention, there is provided a method of generating a distance image of an image, wherein said image comprises a plurality of first CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:ldp fl -2and second pixels, the method comprises the steps of: scanning said first and second pixels; calculating, for each currently scanned second pixel, the respective distances between a co-ordinate of the currently scanned second pixel and a plurality of first coordinates, wherein said plurality of first co-ordinates are derived from second co-ordinates stored in a co-ordinate array associated with pixels neighbouring said currently scanned second pixel; determining, for each currently scanned second pixel, a said first coordinate that results in a minimum said calculated distance; replacing, for each currently scanned second pixel, the second co-ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and generating data values in the distance image representative of the distance between the co-ordinates of the pixels of the image and the second coordinates currently stored in the co-ordinate array associated with the pixels.
According to another aspect of the invention, there is provided a method of generating a distance image of an image, wherein said image comprises a plurality of first o 15 and second pixels, the method comprises the steps of: scanning said first and second pixels; calculating, for each currently scanned second pixel, the respective distances between a co-ordinate of the currently scanned second pixel and a plurality of first coordinates, wherein said plurality of first co-ordinates are stored in a co-ordinate array associated with pixels neighbouring said currently scanned second pixel; determining, for each currently scanned second pixel, a said first co-ordinate that results in a minimum said calculated distance; replacing, for each currently scanned second pixel, the second co-ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and 5: generating data values in the distance image representative of the distance between the co- 25 ordinates of the pixels of the image and the second co-ordinates currently stored in the coordinate array associated with the pixels.
According to a still another aspect of the invention, there is provided a method of generating a representation of voronoi regions of an image, wherein said image comprises a plurality of first and second pixels, the method comprises the steps of: scanning said first and second pixels; calculating, for each currently scanned second pixel, the distances between a co-ordinate of the currently scanned second pixel and first co-ordinates derived from second co-ordinates stored in a co-ordinate array associated with one or more neighboring pixels; determining, for each currently scanned second pixel, a said first coordinate that results in a minimum said calculated distance; replacing, for each currently CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp -3scanned second pixel, the second co-ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and outputting said co-ordinate array as a representation of said voronoi regions.
According to a still another aspect of the invention, there is provided apparatus for generating a distance image of an image, wherein said image comprises a plurality of first and second pixels, the apparatus comprises: means for scanning said first and second pixels;means for calculating, for each currently scanned second pixel, the respective distances between a co-ordinate of the currently scanned second pixel and a plurality of first co-ordinates, wherein said plurality of first co-ordinates are derived from second coordinates stored in a co-ordinate array associated with pixels neighbouring said currently scanned second pixel; means for determining, for each currently scanned second pixel, a said first co-ordinate that results in a minimum said calculated distance; means for replacing, for each currently scanned second pixel, the second co-ordinate within the co- 15 ordinate array corresponding to the currently scanned second pixel with said first coordinate resulting in the minimum said calculated distance; and means for generating data values in the distance image representative of the distance between the co-ordinates of the pixels of the image and the second co-ordinates currently stored in the co-ordinate array associated with the pixels.
According to a still another aspect of the invention, there is provided apparatus for generating a distance image of an image, wherein said image comprises a plurality of first and second pixels, the apparatus comprises: means for scanning said first and second pixels; means for calculating, for each currently scanned second pixel, the respective distances between a co-ordinate of the currently scanned second pixel and a plurality of first co-ordinates, wherein said plurality of first co-ordinates are stored in a co-ordinate array associated with pixels neighbouring said currently scanned second pixel; means for determining, for each currently scanned second pixel, a said first co-ordinate that results in a minimum said calculated distance; means for replacing, for each currently scanned second pixel, the second co-ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and means for generating data values in the distance image representative of the distance between the co-ordinates of the pixels of the image and the second co-ordinates currently stored in the co-ordinate array associated with the pixels.
"CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp According to a still another aspect of the invention, there is provided apparatus for generating a representation of voronoi regions of an image, wherein said image comprises a plurality of first and second pixels, the apparatus comprises: means for scanning said first and second pixels; means for calculating, for each currently scanned second pixel, the distances between a co-ordinate of the currently scanned second pixel and first co-ordinates derived from second co-ordinates stored in a co-ordinate array associated with one or more neighboring pixels; means for determining, for each currently scanned second pixel, a said first co-ordinate that results in a minimum said calculated distance; means for replacing, for each currently scanned second pixel, the second coordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and means for outputting said co-ordinate array as a representation of said voronoi regions.
According to a still another aspect of the invention, there is provided a computer readable medium comprising a computer program for generating a distance image of an 15 image, wherein said image comprises a plurality of first and second pixels, the computer *program comprising: code for scanning said first and second pixels; code for calculating, for each currently scanned second pixel, the respective distances between a co-ordinate of the currently scanned second pixel and a plurality of first co-ordinates, wherein said plurality of first co-ordinates are derived from second co-ordinates stored in a co-ordinate array associated with pixels neighbouring said currently scanned second pixel; code for determining, for each currently scanned second pixel, a said first co-ordinate that results in a minimum said calculated distance; code for replacing, for each currently scanned second pixel, the second co-ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said 25 calculated distance; and code for generating data values in the distance image representative of the distance between the co-ordinates of the pixels of the image and the second co-ordinates currently stored in the co-ordinate array associated with the pixels.
According to a still another aspect of the invention, there is provided a computer readable medium comprising a computer program for generating a distance image of an image, wherein said image comprises a plurality of first and second pixels, the computer program comprising: code for scanning said first and second pixels; code for calculating, for each currently scanned second pixel, the respective distances between a co-ordinate of the currently scanned second pixel and a plurality of first co-ordinates, wherein said plurality of first co-ordinates are stored in a co-ordinate array associated with pixels CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp neighbouring said currently scanned second pixel; code for determining, for each currently scanned second pixel, a said first co-ordinate that results in a minimum said calculated distance; code for replacing, for each currently scanned second pixel, the second co-ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and code for generating data values in the distance image representative of the distance between the co-ordinates of the pixels of the image and the second co-ordinates currently stored in the co-ordinate array associated with the pixels.
According to a still another aspect of the invention, there is provided a computer readable medium comprising a computer program for generating a representation of voronoi regions of an image, wherein said image comprises a plurality of first and second pixels, the computer program comprising: code for scanning said first and second pixels; code for calculating, for each currently scanned second pixel, the distances between a co- S:i •ordinate of the currently scanned second pixel and first co-ordinates derived from second 15 co-ordinates stored in a co-ordinate array associated with one or more neighboring pixels; code for determining, for each currently scanned second pixel, a said first co-ordinate that results in a minimum said calculated distance; code for replacing, for each currently scanned second pixel, the second co-ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and code for outputting said co-ordinate array as a representation of said voronoi regions.
Brief Description of the Drawings Embodiments of the invention are described with reference to the drawings, in which: 25 Fig. 1 is a flow diagram of a method of generating a distance image of an original image I0 having one or more objects in accordance with a first embodiment; Fig. 2 shows a diagrammatic representation of a portion of the array J 0 Fig. 3 shows a diagrammatic representation of a portion of the array J 0 Fig. 4 shows a flow diagram of a method of generating a distance image of a lower resolution image I in accordance with a second embodiment; Fig. 5 shows a diagrammatic representation of an original image Io a low resolution image I1 of the original image Io and an array J 1 for storing co-ordinates associated with the original image I; and CFP1534AU Open40 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:ldp -6- Fig. 6 is a block diagram of a general-purpose computer for implementing any one or more of the embodiments of the method.
Detailed Description The principles of the method described herein have general applicability to the generation of a distance image of an original image having one or more objects.
However, for ease of explanation, the steps of the method are described with reference to a method of generating a distance image of a bi-tonal two-dimensional rasterized image.
However, it is not intended that the present invention be limited to such a method. For example, the invention may also have application to a multidimensional image, e.g. 3dimensional image. In addition, the invention may also have application to the generation of a representation of Voronoi regions. The term distance transform is used herein to refer to an operation of converting a binary image to an approximate distance image. For instance, where each non-edge is given a value that is a measure or approximate measure of the distance to the nearest edge pixel.
15 Some portions of the detailed descriptions which follow are explicitly or implicitly presented in terms of algorithms and symbolic representations of operations on data within a computer memory. These algorithmic descriptions and representations are the means used by those skilled in the data processing arts to most effectively convey the •substance of their work to others skilled in the art. An algorithm is here, and generally, conceived to be a self-consistent sequence of steps leading to a desired result. The steps are those requiring physical manipulations of physical quantities. Usually, though not necessarily, these quantities take the form of electrical or magnetic signals capable of being stored, transferred, combined, compared, and otherwise manipulated. It has proven convenient at times, principally for reasons of common usage, to refer to these signals as S 25 bits, values, elements, symbols, characters, terms, numbers, or the like.
It should be borne in mind, however, that all of these and similar terms are to be associated with the appropriate physical quantities and are merely convenient labels applied to these quantities. Unless specifically stated otherwise as apparent from the following discussions, it is appreciated that throughout the present invention, discussions utilizing terms such as "scanning", "calculating", "determining", "replacing", "generating" "initializing", "outputting", or the like, refer to the action and processes of a computer system, or similar electronic computing device, that manipulates and transforms data represented as physical (electronic) quantities within the computer system's registers and memories into other data similarly represented as physical quantities within the CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN401482995.doc:Idp -7computer system memories or registers or other such information storage, transmission or display devices.
The present invention also relates to apparatus for performing the operations of the methods. This apparatus may be specially constructed for the required purposes, or it may comprise a general purpose computer selectively activated or reconfigured by a computer program stored in the computer. The algorithms and displays presented herein are not inherently related to any particular computer or other apparatus. Various general purpose machines may be used with programs in accordance with the teachings herein, or it may prove convenient to construct more specialized apparatus to perform the required method steps. The structure of a conventional general purpose computer will appear from the description below.
In addition, the present invention also relates to a computer readable medium comprising a computer program for performing the operations of the methods. The computer readable medium is taken herein to include any transmission medium for 15 transmitting the computer program between a source and a designation. The transmission medium may include storage devices such as magnetic or optical disks, memory chips, or other storage devices suitable for interfacing with a general purpose computer. The transmission medium may also include a hard-wired medium such as exemplified in the Internet system, or wireless medium such as exemplified in the GSM mobile telephone S 20 system. The computer program is not intended to be limited to any particular programming language and implementation thereof. It will be appreciated that a variety of programming languages and coding thereof may be used to implement the teachings of the invention as described herein.
First Embodiment of Method 25 Fig. 1 is a flow diagram of a method of generating a distance image of a bi-tonal two-dimensional rasterized image I. The method commences at step 100 and proceeds to the first step 102. In the step 102, a user inputs a desired bi-tonal two-dimensional image In addition, the step 102 determines the size of the inputted image 10. Specifically, the step 102 determines the number of rows and columns H and W, where H represents the height of the image 10 in terms of pixels and W represents the width of the image 1 o in terms of pixels. A pixel of an image 10 at row x and column y is represented herein as For ease of explanation, the image consists of black and white pixels with the black pixels represented by a binary one and the white pixels by a binary zero. However, the invention is not limited to these colors and is applicable to any bi-tonal image.
CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp Moreover, the binary representation of the colors is arbitrary, for instance the white pixels may be represented by a binary one and the black by zero.
In the next step 104, a two-dimensional array Jo(i,j) is generated for storing x,y co-ordinate values at each location within the array. The generated array Jo(ij) has the same number of rows H and the same number of columns W as the image Io(x,y). In the next step 106, the array Jo(ij) is initialized. Each co-ordinate value within Jo(ij) is initialized to the same large co-ordinate value. This large co-ordinate value is further from every pixel point of Io(x,y) than any pixel point in Io(x,y). For example, each coordinate value within Jo(ij) is set to the co-ordinate (2H 2W 1, 2H 2W After completion of step 106, the processing continues at step 108.
In step 108, the method scans the image Io in a forward raster direction one pixel Io(x,y) at a time, commencing at the top left pixel. Namely, the scanning commences at the top left pixel and continues along the first row of pixels one after another. Once the first row has been scanned, the scanning continues at the second row at the leftmost pixel 15 and so on.
Once a pixel Io(x,y) has been scanned, the method performs the loop 109, 110, 111, 112 and 114 and checks in decision block 115 whether the last scanned pixel Io(x,y) is the last pixel Io(H,W) in the image Io. If the decision block 115 returns false, then the processing again continues at step 108, where the next pixel Io(x,y) is scanned and the loop 109, 110, 111, 112 and 114 is once again performed. If however, the decision block 115 returns true, namely the last pixel Io(H,W) has been scanned, then the processing continues at step 116.
In decision block 109, a check is made whether the pixel Io(x,y) is equal to a binary one. If decision block 109 returns true, then the co-ordinate value stored at Jo(x,y) 25 is reset to in step 110. Or in other words, the closest point x,y, or zero offset to pixel Io(x,y) is itself. After step 110, the processing continues at decision block 115. If the decision block 109 returns false, then the processing continues at step 111.
In step 111, the method calculates the following distance metrics, where x,y is the co-ordinate of the presently scanned pixel Io(x,y), and Jo(x,y) is the co-ordinate values stored in the array Jo at location x,y.
d( Jo(x-l,y)) d( Jo(x-l,y-1)) d( Jo(x,y-1)) CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\PENE40]482995.doc:Idp d( Jo(x Eqn 1.
Preferably, the distance metric used in calculating d( is the following Euclidean metric in Eqn 2. However, other metrics may be used without departing from the spirit of the invention.
d( (p-r) 2 q-s) 2 ]1/ 2 Eqn 2 Turning now to Fig. 2, there is shown a diagrammatic representation of Jo(x,y) Jo(x-l,y), Jo(x-l,y-1), Jo(x,y-1), and Jo(x+l,y-1) in the array Jo. The distance metrics calculate the distance between the co-ordinate of the presently scanned pixel and the coordinates stored in the co-ordinate array Jo associated with the neighboring pixels of the presently scanned pixel. In the circumstances where a co-ordinate Jo(x-l,y), Jo(x-l,y-l), Jo(x,y-1), or Jo(x+l,y-1) in Eqn 1 falls outside the array Jo, the distance metric for that co- 15 ordinate is not calculated.
After the distance metrics of Eqn have been calculated, the processing continues at step 112. In step 112, the distance metric of Eqn having the minimum distance is determined. The current co-ordinate value Jo(x,y) is then replaced in step 114 with the co-ordinate value Jo(x-l,y), Jo(x-1,y-1), Jo(x,y-l), or Jo(x+l,y-1) that resulted in the minimum distance metric. In the event there are two or more distance metrics having the same value, then a choice is made between the two according to a predetermined order. For example, those metrics having a Jo co-ordinate earliest in the raster order. In the event the distance metrics are outside the array, e.g. at the top left pixel during the forward scanning pass, then Jo(x,y) is not replaced. Where some but not all the distance 25 metrics are outside the array, then the minimum distance metric is determined from those metrics whose co-ordinate values lie in the Jo array.
After step 114, the processing continues at decision block 115, where a check is made whether the scanned pixel is the last pixel (bottom right) in the image. If the decision block returns true, the processing continues at step 116.
In step 116, the method scans the image Io in a reverse raster direction one pixel Io(x,y) at a time, commencing at the bottom right pixel. Namely, the scanning in the reverse pass commences at the bottom right pixel and continues along the bottom row of pixels one after another. Once the bottom row has been scanned, the scanning continues at the next row up at the rightmost pixel and so on.
CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp Once a pixel Io(x,y) has been scanned, the method performs the loop 119, 120, 122 and 124 and checks in decision block 124 whether the last scanned pixel Io(x,y) is the top left pixel Io(0,0) in the image Io. If the decision block 124 returns false, then the processing continues at step 116, where the next pixel Io(x,y) is scanned and the loop 119, 120, 122 and 124 is once again performed. If however, the decision block 124 returns true, namely the top left pixel Io(0,0) has been scanned, then the processing continues at step 126.
After completion of step 116, the method proceeds to step 119. In step 119, the method calculates the following distance metrics, where x,y is the co-ordinate of the presently scanned pixel Io(x,y) and Jo(x,y) is the co-ordinate values stored in the array Jo at location x,y.
d( Jo(x,y)) d( Jo(x+l,y) 15 d( Jo(x+l,y+l)) d( Jo(x,y+l)) d( Jo(x- Eqn 3.
The distance metric used in calculating the distances in Eqn 3 is the same 20 distance metric used in calculating the distance during the forward scan, i.e. Eqn 2.
Turning now to Fig. 3, there is shown a diagrammatic representation of Jo(x,y) Jo(x+l,y), Jo(x+l,y+l), Jo(x,y+l), and Jo(x-l,y+l) in the array Jo. The distance metrics calculate the distance between the co-ordinate of the presently scanned pixel and the coordinates stored in the co-ordinate array Jo associated with the presently scanned pixel 25 and it's neighboring pixels. In the circumstances where a co-ordinate Jo(x+l,y), Jo(x+l,y+l), Jo(x,y+l), or Jo(x-l,y+l) in Eqn 3 falls outside the array, the distance metric for that co-ordinate is not calculated.
After completion of step 119, the method proceeds with step 120. The method steps performed by steps 120 and 122 are essentially the same as those performed by steps 112 and 114 of the forward scan and will not be described further.
After step 122, the processing continues at decision block 124, where a check is made whether the scanned pixel is the last pixel (top left) in the image. If the decision block returns true, the processing continues at step 126.
CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp -11 In step 126, the distance image D is determined. The distance image D is an two dimensional array of floating point numbers and has the same number of rows and columns as the image and the Jo array, i.e. H rows and W columns. The distance image D(x,y) is calculated as follows, where Jo(x,y) is the resultant array Jo(x,y) after completion of the forward and reverse scans of the image.
d( Jo(x,y)) Eqn. 4 The distance metric used in calculating the distance transform is the same distance metric used in calculating the distance during the forward and reverse scans, i.e. Eqn 2. After the completion of step 126, the processing terminates at step 128.
It is in this way, that the method is able to produce a more smooth-like distance image of an image. In particular, the method is able to produce a distance image which in most instances is a good approximation of the true Euclidean distance without the demanding computations.
For ease of explanation, the steps of the method are now described with reference to the following example. In image Io below, there is shown a bi-tonal image having 7 rows and 5 columns.
IMAGE Io 0 0 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 0 0 0 0 1 1 1 0 0 0 0 0 0 a a. a Initially, an array Jo is generated (steps ARRAY of the above IMAGE Io is shown below, 2W+ 1,2H 2W+ 1).
104 106) where (K,K) and initialized. The Jo is the co-ordinates (2H CFP1534AU OpenO 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp -12- Jo ARRAY
(K,K)
K(K,KK) (K,K)
(K,K)
(K,K)
(K,K)
(KK)
(K,K)
After the scanning pass in the forward direction (steps 108 to 115) the Jo ARRAY is updated as follows: Jo ARRAY 0* a4.' a.
0000 0.0* a a 9t 0 a baa a* a as a. a a
S
604.
5 .00.
(K,K)
(1,1) (1,2) (1,3) (1,4) As can be seen from the above, those locations within the Jo ARRAY, corresponding to those pixels of the image Io set to binary one, have it's co-ordinates set to it's own location (decision block 109 and step 110). For example, the pixel set to binary one in row 2 and column 1, i.e. Io(1,2) in IMAGE Io, has in the corresponding location Jo(1,2) in the Jo ARRAY the stored co-ordinates The steps 111, 112, and 114 of the method will now be described with reference to the pixel at row 6 column 2, i.e. Io(2,6) in IMAGE Io. Prior to the scanning of pixel 10(2,6), the method has previously processed all the pixels excluding pixels 10(2,6) 10(3,6) and Io(4,6). In step 111, the method determines the distance measure for the currently scanned pixel Io(2,6).
CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp -13d( Jo(1,6) 21/2 d( Jo(1,5) d( 21/2 d( Jo(2,5) 1 d( Jo(3,5) d( 3,5) 21/2 In the next step 112, the method determines which stored Jo co-ordinate or results in a minimum distance value. In this case the relevant coordinate is In the next step 114, the method replaces the co-ordinate stored at Jo(2,6) with After the scanning pass in the reverse direction (steps 116 to 124) the Jo ARRAY is updated as follows: Jo ARRAY 660e o S000 6660 00 0eS0 0@00 0 6 00.
S
S.
@0 0000 SS S
S
0 *5 06 S (1,1) (1,1) (1,2) The steps 119, 120, and 122 of the method will now be described with reference 15 to the pixel at row 5 column 0, i.e. Io(0,5) in IMAGE I0. In step 119, the method determines the distance measure for the currently scanned pixel d( Jo(0,5)) d( 212 d( Jo(1,5) 1 d( Jo(1,6) 1 d( Jo(0,6) d( 1 d( Jo(-1, 6 outside area disregard In the next step 112, the method determines which stored Jo co-ordinate or results in a minimum distance value. In this case the relevant Jo coordinate is In the next step 114, the method replaces the co-ordinate stored at Jo(0,5) with CFP153AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp -14- After the reverse scanning pass, the method determines the distance image D in step 126 from the Jo ARRAY where D(x,y) d( The distance image D of the above IMAGE Io is thus: DISTANCE IMAGE D 21/2 1 21/2 51/2 10 1 /2 1 0 1 2 3 1 0 1 2 3 1 0 1 2 51/2 1 0 1 1 21/2 1 0 0 0 1 21/2 1 1 1 21/2 Preferably, the array Jo(x,y) stores only one co-ordinate for each location of the array. Alternatively, Jo(x,y) can be generated as an array of lists, where each location S:i" 10 of the array consists of a list of one or more co-ordinates. During processing, Jo(x,y) would generally store only one co-ordinate at a location Namely, that co-ordinate resulting in the minimum distance value as described previously. However, in the circumstances where where two or more co-ordinates have the same minimum distance, these two or more co-ordinates can be stored at the location as a list. Thus when the 15 process scans the pixels in the reverse direction, the process may take into account all the co-ordinates at a location when determining the minimum distance.
i The foregoing describes an arrangement for controlling the flow of the processes of the method. It would be apparent to a person skilled in the art that modifications and/or changes can be made to the control flow without departing from the scope and 20 spirit of the invention. For instance, during initialization of the Jo array, each co-ordinate corresponding to a pixel having a binary one can be set to it's own location and all other co-ordinates set to the large co-ordinate Thus the loops 109 and 110 in the latter case may be dispensed with.
Second Embodiment of Method A second embodiment of the invention is directed to a method of generating a representation of voronoi regions of an original image. The method is in effect the same as the method of generating a distance image of an original image as shown in Fig. 1 with CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN401482995.doc:Idp one major difference. The resultant J 0 array after the forward and reverse scans of the original image I1 is effectively equivalent to a representation of voronoi regions of the original image I. Consequently, in the method of generating a representation of voronoi regions, the step 126 of calculating the distance image may be dispensed with.
Third Embodiment of Method In the circumstances where a higher resolution image is displayed as a lower resolution image, it may be desirable to use the information contained in the higher resolution image to determine more accurately the distance image of the lower resolution image. This can be achieved by the following third embodiment.
Turning now to Fig. 4, there is shown a flow diagram of a method of generating a distance image of a lower resolution image in accordance with a third embodiment. The third embodiment of the method commences at step 400 and proceeds to the first step 402. In the step 402, a user inputs a desired bi-tonal two-dimensional image I1. This image II is a low-resolution image of an original image herein designated I0. The original image Io has a number of rows and columns of pixels and has a height H and width W measured in terms of pixels. The lower resolution image I1 also has a number of rows and columns of pixels and has a height H/R and width W/R measured in terms of pixels. The oo*.
constant R is the resolution factor. In step 402, the user also inputs the original image Io.
Alternatively, the user may instead input the original image Io only and the lower 20 resolution image 11 is generated by known means during this step.
*In addition, the step 402 determines the size of the both inputted images Io and I,.
Specifically, the step 402 determines the number of rows and columns H and W of image Io and the number of rows and columns H/R and W/R of image 11.
5 In the next step 404, a two-dimensional array Jl(ij) is generated for storing x,y 25 co-ordinate values at each location (ij) within the array. The generated array Jl(ij) has the same number of rows H/R and the same number of columns W/R as the image In the next step 406, the array J 1 (ij) is initialized. The array is initialized in the same manner as described with reference to the first embodiment. Namely, each coordinate value within Jl(ij) is initialized to the same large co-ordinate value. After completion of step 406, the processing continues at step 408.
In step 408, the method scans the lower resolution image I in a forward raster direction one pixel at a time, in a similar manner to that described with reference to the first embodiment.
CFP1534AU Open4O 482995 [(I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp -16- Once a pixel Ii(x,y) has been scanned, the method performs the loop 409, 410, 411, 412 and 414 and checks in decision block 415 whether the last scanned pixel II(x,y) is the last pixel II(H/R,W/R) in the image I1. If the decision block 415 returns false, then the processing again continues at step 408, where the next pixel Ii(x,y) is scanned and the loop 409, 410, 411, 412 and 414 is once again performed. If however, the decision block 415 returns true, namely the last pixel II(H/R,W/R) has been scanned, then the processing continues at step 416.
After completion of step 408, the method proceeds to decision block 409. In decision block 409, a check is made whether the following equation is true or false for the currently scanned pixel I d( f(x,y) d f(x,y) Jl(x,y) Io(a,b) 1 for any in the neighborhood N of f(x,y); wherein the neighborhood N are those pixels of Io that resolve to pixel Ii(x,y); f(x,y) is the affine transformation of the x,y co-ordinates in the lower resolution image I to the co-ordinates in higher resolution original image l; and Jl(x,y) is the co-ordinate stored at location in array J 1 Eqn 20 If the decision block 409 ieturns true, the processing continues at step 410. In step 410, the current Ji(x,y) co-ordinate, is then replaced with the co-ordinate that solves the equation 5, for the currently scanned pixel Ii(x,y). In the case where the equation is solved by two co-ordinates the Ji(x,y) co-ordinate is then replaced with the co-ordinate which results in the smallest distance measure d( f(x,y) 25 namely the one that is closest to f(x,y).
For ease of explanation, the decision block 409 and step 410 are now described in more detail with reference to the following example. In this example, the image I is a low-resolution image having 3 rows and 3 columns of an original image Io having 6 rows and 6 columns. The resolution factor R is 2.The associated Ji array has 3 rows and 3 columns and each co-ordinate value of the array has been previously initialized to the large co-ordinate values In this particular example, the pixels Io(0,0), Io(1,0), Io( 0, and Io(1,1) of the original image have binary values 0,0,0, and 1 respectively. The affine transformation of the first pixel of the low-resolution image I(0,0) to the pixel of the original image is Io(f(0,0)) Io( V2, The neighborhood N of pixel Io(f(0,0)) Io( CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp -17- V2) are pixels Io(0,0), Io(1,0), Io( 0, and Io(1,1) of the original image. Conceptually speaking, the pixels Io(0,0), Io(1,0), Io( 0, and Io(1,1) of the original image can be thought of "underlying" or resolving to pixel I of the low resolution image.
In this example, z2), d Y2, Io(1,1) 1 and thus equation 5 is true for pixel Io(1,1). However it is not true for pixels Io(0,0), Io(1,0), and Io(0, 1) as Io(a,b) is not equal to 1 in these cases. Thus in step 410 the co-ordinate (K,K) stored at Ji(0,0) is replaced with co-ordinate Or expressed in other words, the coordinate Ji(x,y) currently stored is replaced with the co-ordinate of the pixel of the original image having a binary one that "underlies" the currently scanned pixel Ii(x,y) of the low-resolution image. Where there are more than one pixels having a binary one "underlying" the currently scanned pixel Ii(x,y) of the low resolution image, the coordinate of the "underlying" pixel of the original image that is closest to f(x,y) is chosen to replace Jl(x,y).
If the decision block 409 returns false, the processing continues at step 411. In Step 411, the process determines the following distance measures for the currently scanned pixel Il(x,y): d( e.
20 for any Io(a,b) 1 in any of the neighborhoods M of the co-ordinates stored at Ji(x,y), Ji(x-l,y), Jl(x-l,y-1), Ji(x,y-1) or Ji(x 1,y-l) respectively; S.wherein the neighborhoods M are squares centered on respective co-ordinates Ji(x,y), Ji(x-l,y), Ji(x-l,y-l), Ji(x,y-1) and Ji(x 1,y-l) and having a size of M +lxM 1 pixels; 25 f(x,y) is the affine transformation of the x,y co-ordinates in the lower resolution image I to the co-ordinates in higher resolution original image Io; and Ji(x,y) is that co-ordinate stored at location in array J 1 Eqn 6.
lo After the distance metrics of Eqn have been calculated, the processing continues at step 412. In step 412, the distance metric of Eqn having the minimum distance is determined. The current co-ordinate value Ji(x,y) is then replaced in step 414 with the co-ordinate value Ji(x,y), Ji(x-l,y), Jl(x-1,y-1), Ji(x,y-1), or Ji(x+l,y-1) that resulted in the minimum distance metric. In the event there are two or more distance metrics having the same value, then a choice is made between the two according to a CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:ldp -18predetermined order. For example, those metrics having a Ji co-ordinate earliest in the raster order. In the event there are no distance metrics, e.g. at the top left pixel during the forward scanning pass, then JI(x,y) is not replaced. Where some but not all the distance metrics are outside the array, then the minimum distance metric is determined from those metrics whose co-ordinate values lie in the Jo array.
For ease of explanation, steps 411, 412 and 414 of Fig. 4 will now be described in more detail with reference to Fig. 5. Turning now to Fig. 5, there is shown a diagrammatic representation of an original image Io, a low-resolution image I1 of the original image Io and an array Ji for storing co-ordinates associated with the original image Io. In the third embodiment, the J 1 array has the same number of rows and columns as the low-resolution image Ji has rows and columns of pixels. For each scanned pixel Ji(x,y) within the low-resolution image Ii, a number of distance measures are determined (step 411 Eqn These distance measures are measured between the pixel f(x,y) of the original image Io and any pixels within the neighborhoods M that have binary values of one, i.e. Io(a,b) 1. The location of the neighborhoods M are centered on coordinates which are determined from the co-ordinate values stored in the co-ordinate array Ji at Ji(x,y), Ji(x-l,y), Jl(x-l,y-1), Ji(x,y-1) and Ji(x The size of each neighborhood M is M+lxM+1 pixels. In step 412, the pixel Io(a,b) that resulted in the minimum distance measure is determined. In step 414, the co-ordinate stored at Ji(x,y) is 20 replaced by the co-ordinate that resulted in the minimum distance measure.
Returning now to Fig. 4, the further steps of the method are now described.
After step 414, the processing continues at decision block 415, where a check is made whether the scanned pixel is the last pixel (bottom right) in the image. If the decision block returns true, the processing continues at step 416.
25 In step 416, the method scans the image Io in a reverse raster direction one pixel Io(x,y) at a time, commencing at the bottom right pixel in a similar manner to that S: described with reference to the first embodiment. Namely, the scanning in the reverse pass commences at the bottom right pixel and continues along the bottom row of pixels one after another. Once the bottom row has been scanned, the scanning continues at the next row up at the rightmost pixel and so on.
Once a pixel Io(x,y) has been scanned, the method performs the loop 419, 420, 422 and 424 and checks in decision block 424 whether the last scanned pixel is the top left pixel I1(0,0) in the image I1. If the decision block 424 returns false, then the processing continues at step 416, where the next pixel Ii(x,y) is scanned and the loop 419, CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp -19- 420, 422 and 424 is once again performed. If however, the decision block 424 returns true, namely the top left pixel Io(0,0) has been scanned, then the processing continues at step 426.
After completion of step 416, the method proceeds to step 419. In step 419, the method calculates the following distance metrics, where x,y is the co-ordinate of the presently scanned pixel Ii(x,y) and Ji(x,y) is the co-ordinate values stored in the array J 1 at location x,y: d( for any Io(a,b) 1 in any of the neighborhoods M of the co-ordinates stored at Ji(x,y), Ji(x 1, Ji(x- 1, y+ Jl(x, y+ 1) or Ji(x 1, y 1) respectively; wherein the neighborhoods M are squares centered on respective co-ordinates Ji(x,y), Ji(x+l,y), Ji(x-l,y+l), Ji(x,y+l) and Ji(x 1,y+l) and having a size of M +lxM 1 pixels; f(x,y) is the affine transformation of the x,y co-ordinates in the lower resolution image I 1 to the co-ordinates in higher resolution original image Io; and Jl(x,y) is that co-ordinate stored at location in array J 1 Eqn 7.
The distance metrics in Eqn 7 are essentially the same as those in Eqn 6, except the neighboring locations in the Ji array differ due to the direction of the scan.
After completion of step 419, the method proceeds with step 420. The method steps performed by steps 420 and 422 are essentially the same as those performed by steps 412 and 414 of the forward scan and will not described any further.
25 After step 422, the processing continues at decision block 424, where a check is made whether the scanned pixel is the last pixel (top left) in the image. If the decision Sblock returns true, the processing continues at step 426.
In step 426, the distance image D is determined. The distance image D is an two dimensional array of floating point numbers and has the same number of rows and columns as the image and the J array, i.e. H rows and W columns. The distance image Dl(x,y) is calculated as follows, where Ji(x,y) is the resultant array JI(x,y) after completion of the forward and reverse scans of the image I.
Di(x,y) d( Ji(x,y)) Eqn. 8 CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp Afterwards the distance image is outputted, stored or used in further processing.
The method terminates at step 428.
Fourth Embodiment of Method In a fourth embodiment, the method is applicable to an original image Io of a set of curves such as bezier curves. Each curve within the image Io is designated by a integral number n and the positions on each curve are designated by a parameter t. In this embodiment, a distance image is determined for some resolution image Ii of the original image Io. In this context, the fourth embodiment is similar to the third embodiment, and the steps of both methods are overall the same.
In the fourth embodiment of the method, initially the array Ji(i,j) is generated having the same number of rows H and the same number of columns W as the image Ii(x,y). The J 1 array is generated for storing positions of the curves for each pixel location of the image I. That is, the J 1 array stores at it's location a value (n,t) associated with pixel Ii(x,y). Initially each t value within Ji(ij) is initialized to the same large value. The number of the curve is initialized to some number that does not cause a conflict, for instance a negative number. In the next step all the curves are subdivided as sub-curves until the sub-curves lie approximately within the individual pixels of Ii(x,y).
The method then scans the image II(x,y) in a similar manner to that previously described.
If the scanned pixel Ii(x,y) has a sub-curve lying within the scanned pixel, the method then determines the distance between the center of'the pixel and the closest point on the sub-curve The method then assigns this point to Ji(x,y) if the distance between this point and the center of the pixel is smaller than the distance between the previously stored point and the center of the pixel. If however, the scanned pixel does not have a sub-curve directly lying within the pixel, then the method instead proceeds with the following steps. The method calculates for the forwardly scanned pixel Ii(x,y), the minimum distance between the center of the current pixel Ii(x,y) and that sub-curve that spans the range of sub-curves stored at Ji(x-l,y), Jl(x-l,y-1), Ji(x,y-1), and Ji(x The method then replaces the position at Ji(x,y) with that position that resulted in the minimum distance. The method performs a similar calculation during the reverse scan of pixel Ii(x,y), but for that sub-curve that scans the sub-curves stored at Ji(x,y), Jl(x+l,y), Ji(x-l,y+l), Ji(x,y+l) and Ji(x Similarly, the method during the reverse scan replaces the position at Ji(x,y) with the position that resulted in the minimum distance.
CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp -21- Finally, the method determines the distance image of the image 11 DI(x,y) d( center(x,y), Jl(x,y)) Eqn. 9 where center(x,y) is the center position of pixel Embodiments of Apparatus and Computer Readable Medium The first, second, third or fourth embodiments as illustrated in Figs. 1 to 5 are preferably practiced using a conventional general-purpose computer, such as the one shown in Fig. 6. The first, second, third, or fourth embodiments as illustrated in Figs. 1 to may be implemented as software executing on the computer. In particular, the steps of these embodiments of the methods are effected by instructions in the software that are carried out by the computer. The software may be divided into two separate parts; one part for carrying out these embodiments of the methods; and another part to manage the user interface between the latter and the user. The software may be stored in a computer readable medium, comprising the storage devices described below, for example. The software is loaded into the computer from the computer readable medium, and then executed by the computer. The use of the computer program in the computer preferably effects an advantageous apparatus in accordance with the embodiments of the invention.
The computer system 600 consists of the computer 602, a video display 616, and input devices 618, 620. In addition, the computer system 600 can have any of a number of other output devices comprising line printers, laser printers, plotters, and other reproduction devices connected to the computer 602. The computer system 600 can be connected to one or more other computers via a communication interface 608b using an appropriate communication channel 630 such as a modem communications path, a computer network, or the like. The computer network may comprise a local area network a wide area network (WAN), an Intranet, and/or the Internet 25 The computer 602 itself consists of a central processing unit(s) (simply referred to as a processor hereinafter) 604 a memory 606 which may comprise random access memory (RAM) and read-only memory (ROM), input/output (10) interfaces 608a 608b, a video interface 610, and one or more storage devices generally represented by a block 612 in Fig. 6. The storage device(s) 612 can consist of one or more of the following: a floppy disc, a hard disc drive, a magneto-optical disc drive, CD-ROM, magnetic tape or any other of a number of non-volatile storage devices well known to those skilled in the art. Each of the components 604 to 612 is typically connected to one or more of the other devices via a bus 614 that in turn can consist of data, address, and control buses.
CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp -22- The video interface 610 is connected to the video display 616 and provides video signals from the computer 602 for display on the video display 616. User input to operate the computer 602 can be provided by one or more input devices 608a. For example, an operator can use the keyboard 618 and/or a pointing device such as the mouse 620 to provide input to the computer 602.
The system 600 is simply provided for illustrative purposes and other configurations can be employed without departing from the scope and spirit of the invention. Exemplary computers on which the embodiment can be practiced comprise IBM-PC/ATs or compatibles, one of the Macintosh (TM) family of PCs, Sun Sparcstation or the like. The foregoing are merely exemplary of the types of computers with which the embodiments of the invention may be practiced. Typically, the processes of the embodiments, described hereinafter, are resident as software or a program recorded on a hard disk drive (generally depicted as block 612 in Fig. 6) as the computer readable medium, and read and controlled using the processor 604. Intermediate storage of the program and pixel data and any data fetched from the network may be accomplished using the semiconductor memory 606, possibly in concert with the hard disk drive 612.
:i In some instances, the program may be supplied to the user encoded on a CD-ROM or a floppy disk (both generally depicted by block 612), or alternatively could be read by the user from the network via a modem device connected to the computer, for example. Still further, the software can also be loaded into the computer system 6x00 from other computer readable medium comprising magnetic tape, a ROM or integrated circuit, a magneto-optical disk, a radio or infra-red transmission channel between the computer and another device, a computer readable card such as a PCMCIA card, and the o Internet and Intranets comprising email transmissions and information recorded on 25 websites and the like. The foregoing are merely exemplary of relevant computer readable mediums. Other computer readable mediums may be practiced without departing from the scope and spirit of the invention.
The first to fourth embodiments of the method may alternatively be implemented in dedicated hardware such as one or more integrated circuits performing the functions or sub functions of the preferred methods. Such dedicated hardware may comprise graphic processors, digital signal processors, or one or more microprocessors and associated memories.
The foregoing only describes a small number of embodiments of the present invention, however, modifications and/or changes can be made thereto by a person skilled CFP1534AU Open4O 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp -23in the art without departing from the scope and spirit of the invention. The present embodiments are, therefore, to be considered in all respects to be illustrative and not restrictive.
In the context of this specification and accompanying aspects of invention, the word "comprising" means "including principally but not necessarily solely". Variations of the word comprising, such as "comprise" and "comprises" have correspondingly varied meanings.
e S
S
S
o o* oo *0 **ooo CFP1534AU Open410 482995 [I:\ELEC\CISRA\OPEN\OPEN40]482995.doc:Idp

Claims (9)

1. A method of generating a distance image of an image, wherein said image comprises a plurality of first and second pixels, the method comprises the steps of: scanning said first and second pixels; calculating, for each currently scanned second pixel, the respective distances between a co-ordinate of the currently scanned secbnd pixel and a plurality of first co- ordinates, wherein said plurality of first co-ordinates are derived from second co-ordinates stored in a co-ordinate array associated with pixels neighbouring said currently scanned second pixel; determining, for each currently scanned second pixel, a said first co-ordinate that •results in a minimum said calculated distance; replacing, for each currently scanned second pixel, the second co-ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said 15 first co-ordinate resulting in the minimum said calculated distance; and generating data values in the distance image representative of the distance between the co-ordinates of the pixels of the image and the second co-ordinates currently o stored in the co-ordinate array associated with the pixels. S 20
2. A method as claimed in claim 1, wherein the derived first co-ordinates are said •stored second co-ordinates associated with said neighboring pixels. ooooo.
3. A method as claimed in claim 1, wherein the derived first co-ordinates fall within regions bounding said stored second co-ordinates associated with said neighboring pixels.
4. A method as claimed in claim 1, wherein said derived first co-ordinates span a range of said second co-ordinates associated with said neighboring pixels.
A method as claimed in claim 4, wherein said first and second co-ordinates are represented by where n designates a curve and t a parameter value.
6. A method as claimed in claim 2 or 3, wherein said first and second co-ordinates are represented by where x designates a column and y designates a row of a said first or second pixel of the image.
482995.doc
7. A method as claimed in claim 1, wherein the method comprises the following step prior to said calculating step; generating said co-ordinate array having rows and columns of the same dimensions as said image for storing said co-ordinate values associated with said pixels; and initializing each said co-ordinate value within said co-ordinate array to the same co-ordinate, wherein said same co-ordinate is greater than the size of the array.
8. A method as claimed in claim 1, wherein said scanning step comprises the sub- steps of: forward scanning said pixels in raster order from left to right, commencing at the top left and performing the said calculating, determining and replacing steps; and Sreverse scanning said pixels in raster order from right to left, commencing at the 15 bottom right and repeating said calculating, determining and replacing steps.
9. A method as claimed in claim 8, wherein said calculating step during the forward scanning comprises calculating the following distance metrics: d( Jo(x-l,y)) 20 d( Jo(x-l,y-1)) d( Jo(x,y-1)) d( Jo(x wherein x,y is the co-ordinates of the currently scanned second pixel and Jo(x,y) is the co- ordinate stored in said co-odinate array at the location A method as claimed in claim 8 or 9, wherein said calculating step during the reverse scanning comprises calculating the following distance metrics: d( Jo(x,y)) d( Jo(x+l,y)) d( Jo(x+l,y+l)) d( Jo(x,y+l)) d( Jo(x l,y+l), wherein x,y is the co-ordinate of the currently scanned second pixel and Jo(x,y) is the co- ordinate stored in said co-odinate array at the location 482995.doc -26- 11. A method as claimed in claim 1, wherein said method further comprises the step of replacing, for each currently scanned first pixel, the second co-ordinate stored in a co- ordinate array associated with the currently scanned first pixel with a co-ordinate of the currently scanned first pixel. 12. A method as claimed in claim 8, wherein said image is a low resolution image of an original image and said calculating step comprises calculating during said forward scan said distances in accordance with the following distance metric: for any first pixels of the original image in any neighborhoods M of the co-ordinates stored at Ji(x,y), Ji(x-l,y), Ji(x-l,y-1), or Ji(x l,y-l) respectively; where the neighborhoods M are squares centered on respective co-ordinates Ji(x,y), Ji(x-l,y), Ji(x- S and Ji(x 1,y-l) and having a size ofM +lxM 1 pixels; where f(x,y) 15 is the affine transformation of the x,y co-ordinates in the lower resolution image to the co- ordinates in higher resolution original image; and where Ji(x,y) is that co-ordinate stored at location in said co-ordinate array. 13. A method as claimed in claim 8, wherein said image is a low resolution image of 20 an original image and said calculating step comprises calculating during said forward scan said distances in accordance with the following distance metric: i for any first pixels of the original image in any neighborhoods M of the co-ordinates stored at Ji(x,y), Ji(x 1, Ji(x- 1, y+ Ji(x, y+ 1) or Ji(x 1, y 1) respectively; where the neighborhoods M are squares centered on respective co-ordinates Ji(x,y), Ji(x 1, Ji(x- 1, y+ Ji(x, y+ 1) and JI(x 1, y 1) and having a size of M +lxM 1 pixels; where f(x,y) is the affine transformation of the x,y co-ordinates in the lower resolution image to the co-ordinates in higher resolution original image; and where Ji(x,y) is that co-ordinate stored at location in said co-ordinate array. 14. A method as claimed in claim 9 or 10, wherein said distance metric is determined according to the following formulae: d( p-r) 2 q-s) 2 1 2 482995.doc -27- A method of generating a distance image of an image, wherein said image comprises a plurality of first and second pixels, the method comprises the steps of: scanning said first and second pixels; calculating, for each currently scanned second pixel, the respective distances between a co-ordinate of the currently scanned second pixel and a plurality of first co- ordinates, wherein said plurality of first co-ordinates are stored in a co-ordinate array associated with pixels neighbouring said currently scanned second pixel; determining, for each currently scanned second pixel, a said first co-ordinate that results in a minimum said calculated distance; replacing, for each currently scanned second pixel, the second co-ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said •first co-ordinate resulting in the minimum said calculated distance; and generating data values in the distance image representative of the distance between the co-ordinates of the pixels of the image and the second co-ordinates currently 15 stored in the co-ordinate array associated with the pixels. i 16. A method of generating a representation of voronoi regions of an image, wherein said image comprises a plurality of first and second pixels, the method comprises the steps of: 20 scanning said first and second pixels; •°calculating, for each currently scanned second pixel, the distances between a co- i •ordinate of the currently scanned second pixel and first co-ordinates derived from second co-ordinates stored in a co-ordinate array associated with one or more neighboring pixels; determining, for each currently scanned second pixel, a said first co-ordinate that results in a minimum said calculated distance; replacing, for each currently scanned second pixel, the second co-ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and outputting said co-ordinate array as a representation of said voronoi regions. 17. Apparatus for generating a distance image of an image, wherein said image comprises a plurality of first and second pixels, the apparatus comprises: means for scanning said first and second pixels; 482995.doc -28- means for calculating, for each currently scanned second pixel, the respective distances between a co-ordinate of the currently scanned second pixel and a plurality of first co-ordinates, wherein said plurality of first co-ordinates are derived from second co- ordinates stored in a co-ordinate array associated with pixels neighbouring said currently scanned second pixel; means for determining, for each currently scanned second pixel, a said first co- ordinate that results in a minimum said calculated distance; means for replacing, for each currently scanned second pixel, the second co- ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and means for generating data values in the distance image representative of the distance between the co-ordinates of the pixels of the image and the second co-ordinates currently stored in the co-ordinate array associated with the pixels. oooo ooo* 15 18. Apparatus as claimed in claim 17, wherein the derived first co-ordinates are said stored second co-ordinates associated with said neighboring pixels. *•ooo 19. Apparatus as claimed in claim 17, wherein the derived first co-ordinates fall S: •within regions bounding said stored second co-ordinates associated with said neighboring 20 pixels. 20. Apparatus as claimed in claim 17, wherein said derived first co-ordinates span a range of said second co-ordinates associated with said neighboring pixels. 21. Apparatus as claimed in claim 20, wherein said first and second co-ordinates are represented by where n designates a curve and t a parameter value. 22. Apparatus as claimed in claim 18 or 19, wherein said first and second co- ordinates are represented by where x designates a column and y designates a row of a said first or second pixel of the image. 23. Apparatus as claimed in claim 17, wherein the apparatus comprises: 482995.doc -29- means for generating said co-ordinate array having rows and columns of the same dimensions as said image for storing said co-ordinate values associated with said pixels; and means for initializing each said co-ordinate value within said co-ordinate array to the same co-ordinate, wherein said same co-ordinate is greater than the size of the array. 24. Apparatus as claimed in claim 17, wherein said scanning means comprises: means for forward scanning said pixels in raster order from left to right, commencing at the top left and performing the said calculating, determining and replacing steps; and means for reverse scanning said pixels in raster order from right to left, commencing at the bottom right and repeating said calculating, determining and replacing steps. 15 25. Apparatus as claimed in claim 24, wherein said calculating means comprises: means for calculating, during the forward scanning, the following distance metrics: d( Jo(x-1,y)) d( Jo(x-l,y-1)) 20 d( Jo(x,y-1)) d( Jo(x l,y-l) wherein x,y is the co-ordinates of the currently scanned second pixel and Jo(x,y) is the co- ordinate stored in said co-odinate array at the location 26. Apparatus as claimed in claim 24 or 25, wherein said calculating means comprises: means for calculating, during the reverse scanning, the following distance metrics: d( Jo(x,y)) d( Jo(x+l,y)) d( Jo(x+l,y+l)) d( Jo(x,y+l)) d( Jo(x 1,y+l), S482995.doc wherein x,y is the co-ordinate of the currently scanned second pixel and Jo(x,y) is the co- ordinate stored in said co-odinate array at the location 27. Apparatus as claimed in claim 17, wherein said apparatus further comprises means for replacing, for each currently scanned first pixel, the second co-ordinate stored in a co-ordinate array associated with the currently scanned first pixel with a co-ordinate of the currently scanned first pixel. 28. Apparatus as claimed in claim 24 wherein said image is a low resolution image of an original image and said calculating means comprises: means for calculating, during said forward scan, said distances in accordance with the following distance metric: S: for any first pixels of the original image in any neighborhoods M of the co-ordinates 15 stored at Ji(x,y), Ji(x-l,y), Ji(x-l,y-1), or Ji(x l,y-l) respectively; where the neighborhoods M are squares centered on respective co-ordinates Ji(x,y), Ji(x-l,y), Ji(x- and Jl(x 1,y-l) and having a size ofM +lxM 1 pixels; where f(x,y) is the affine transformation of the x,y co-ordinates in the lower resolution image to the co- ordinates in higher resolution original image; and where Ji(x,y) is that co-ordinate stored 20 at location in said co-ordinate array. 29. Apparatus as claimed in claim 24, wherein said image is a low resolution image of an original image and said calculating means comprises: means for calculating, during said forward scan, said distances in accordance with the following distance metric: for any first pixels of the original image in any neighborhoods M of the co-ordinates stored at Ji(x,y), JI(x 1, Ji(x- 1, y+ Ji(x, y+ 1) or Ji(x 1, y 1) respectively; where the neighborhoods M are squares centered on respective co-ordinates Ji(x,y), JI(x 1, Ji(x- 1, y+ Ji(x, y+ 1) and Ji(x 1, y 1) and having a size of M +lxM 1 pixels; where f(x,y) is the affine transformation of the x,y co-ordinates in the lower resolution image to the co-ordinates in higher resolution original image; and where Ji(x,y) is that co-ordinate stored at location in said co-ordinate array. 482995.doc 482995.doc -31 Apparatus as claimed in claim 25 or 26, wherein said distance metric is determined according to the following formulae (p-r) 2 q-s)2]1 2 31. Apparatus for generating a distance image of an image, wherein said image comprises a plurality of first and second pixels, the apparatus comprises: means for scanning said first and second pixels; means for calculating, for each currently scanned second pixel, the respective distances between a co-ordinate of the currently scanned second pixel and a plurality of first co-ordinates, wherein said plurality of first co-ordinates are stored in a co-ordinate array associated with pixels neighbouring said currently scanned second pixel; means for determining, for each currently scanned second pixel, a said first co- ordinate that results in a minimum said calculated distance; means for replacing, for each currently scanned second pixel, the second co- 15 ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and means for generating data values in the distance image representative of the distance between the co-ordinates of the pixels of the image and the second co-ordinates currently stored in the co-ordinate array associated with the pixels. 32. Apparatus for generating a representation of voronoi regions of an image, wherein said image comprises a plurality of first and second pixels, the apparatus comprises: means for scanning said first and second pixels; means for calculating, for each currently scanned second pixel, the distances between a co-ordinate of the currently scanned second pixel and first co-ordinates derived from second co-ordinates stored in a co-ordinate array associated with one or more neighboring pixels; means for determining, for each currently scanned second pixel, a said first co- ordinate that results in a minimum said calculated distance; means for replacing, for each currently scanned second pixel, the second co- ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and 482995.doc -32- means for outputting said co-ordinate array as a representation of said voronoi regions. 33. A computer readable medium comprising a computer program for generating a distance image of an image, wherein said image comprises a plurality of first and second pixels, the computer program comprising: code for scanning said first and second pixels; code for calculating, for each currently scanned second pixel, the respective distances between a co-ordinate of the currently scanned second pixel and a plurality of first co-ordinates, wherein said plurality of first co-ordinates are derived from second co- ordinates stored in a co-ordinate array associated with pixels neighbouring said currently •scanned second pixel; :•.code for determining, for each currently scanned second pixel, a said first co- ordinate that results in a minimum said calculated distance; 15 code for replacing, for each currently scanned second pixel, the second co- ordinate within the co-ordinate array corresponding to the currently scanned second pixel ••with said first co-ordinate resulting in the minimum said calculated distance; and code for generating data values in the distance image representative of the distance between the co-ordinates of the pixels of the image and the second co-ordinates 20 currently stored in the co-ordinate array associated with the pixels. 34. A computer readable medium comprising a computer program for generating a distance image of an image, wherein said image comprises a plurality of first and second pixels, the computer program comprising: code for scanning said first and second pixels; code for calculating, for each currently scanned second pixel, the respective distances between a co-ordinate of the currently scanned second pixel and a plurality of first co-ordinates, wherein said plurality of first co-ordinates are stored in a co-ordinate array associated with pixels neighbouring said currently scanned second pixel; code for determining, for each currently scanned second pixel, a said first co- ordinate that results in a minimum said calculated distance; code for replacing, for each currently scanned second pixel, the second co- ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and S482995.doc I './v~o~r.482995doc -33- code for generating data values in the distance image representative of the distance between the co-ordinates of the pixels of the image and the second co-ordinates currently stored in the co-ordinate array associated with the pixels. 35. A computer readable medium comprising a computer program for generating a representation of voronoi regions of an image, wherein said image comprises a plurality of first and second pixels, the computer program comprising: code for scanning said first and second pixels; code for calculating, for each currently scanned second pixel, the distances between a co-ordinate of the currently scanned second pixel and first co-ordinates derived from second co-ordinates stored in a co-ordinate array associated with one or more oneighboring pixels; code for determining, for each currently scanned second pixel, a said first co- ordinate that results in a minimum said calculated distance; 15 code for replacing, for each currently scanned second pixel, the second co- ordinate within the co-ordinate array corresponding to the currently scanned second pixel with said first co-ordinate resulting in the minimum said calculated distance; and code for outputting said co-ordinate array as a representation of said voronoi regions. 36. A method of generating a distance image of an image, said method substantially as described herein with reference to Figs. 1, 2, and 3 of the accompanying drawings. 37. A method of generating a distance image of an image, said method substantially as described herein with reference to Figs. 4 and 5 of the accompanying drawings. 38. A method of generating a representation of voronoi regions of an image, said method substantially as described herein with reference to Figs. 1, 2, and 3 of the accompanying drawings. 39. Apparatus for generating a distance image of an image, said apparatus substantially as described herein with reference to Figs. 1, 2, 3, and 6 of the accompanying drawings. 482995.doc -34- Apparatus for generating a distance image of an image, said apparatus substantially as described herein with reference to the Figs. 4, 5, and 6 of the accompanying drawings. 41. Apparatus for generating a representation of voronoi regions of an image, said apparatus substantially as described herein with reference to Figs. 1, 2, 3, and 6 of the accompanying drawings. 42. A computer readable medium having a computer program for generating a distance image of an image, said program substantially as described herein with reference to Figs. 1, 2, 3, and 6 of the accompanying drawings. 43. A computer readable medium having a computer program for generating a a distance image of an image, said program substantially as described herein with reference 15 to the Figs. 4, 5, and 6 of the accompanying drawings. 44. A computer readable medium having a computer program for generating a representation of voronoi regions of an image, said program substantially as described herein with reference to Figs. 1, 2, 3, and 6 of the accompanying drawings. DATED this fourteenth Day of November, 2001 Canon Kabushiki Kaisha Patent Attomeys for the Applicant SPRUSON FERGUSON 482995.doc
AU60647/99A 1998-11-27 1999-11-25 Method and apparatus for generating a distance image of an original image Ceased AU742875B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
AU60647/99A AU742875B2 (en) 1998-11-27 1999-11-25 Method and apparatus for generating a distance image of an original image

Applications Claiming Priority (3)

Application Number Priority Date Filing Date Title
AUPP7405A AUPP740598A0 (en) 1998-11-27 1998-11-27 Method and apparatus for generating a distance image of an original image
AUPP7405 1998-11-27
AU60647/99A AU742875B2 (en) 1998-11-27 1999-11-25 Method and apparatus for generating a distance image of an original image

Publications (2)

Publication Number Publication Date
AU6064799A AU6064799A (en) 2000-06-01
AU742875B2 true AU742875B2 (en) 2002-01-17

Family

ID=25632833

Family Applications (1)

Application Number Title Priority Date Filing Date
AU60647/99A Ceased AU742875B2 (en) 1998-11-27 1999-11-25 Method and apparatus for generating a distance image of an original image

Country Status (1)

Country Link
AU (1) AU742875B2 (en)

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5555354A (en) * 1993-03-23 1996-09-10 Silicon Graphics Inc. Method and apparatus for navigation within three-dimensional information landscape
US5835094A (en) * 1996-12-31 1998-11-10 Compaq Computer Corporation Three-dimensional computer environment

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US5555354A (en) * 1993-03-23 1996-09-10 Silicon Graphics Inc. Method and apparatus for navigation within three-dimensional information landscape
US5835094A (en) * 1996-12-31 1998-11-10 Compaq Computer Corporation Three-dimensional computer environment

Also Published As

Publication number Publication date
AU6064799A (en) 2000-06-01

Similar Documents

Publication Publication Date Title
US8265350B2 (en) Method and apparatus for detecting and processing specific pattern from image
US6577762B1 (en) Background surface thresholding
US6807304B2 (en) Feature recognition using loose gray scale template matching
US8352856B2 (en) Systems and methods to resize document content
EP1347410B1 (en) Edge-based enlargement and interpolation of images
EP1091320A2 (en) Processing multiple digital images
Savakis Adaptive document image thresholding using foreground and background clustering
US5892854A (en) Automatic image registration using binary moments
JP4535584B2 (en) Digital image processing method
CN105765551A (en) Systems and methods for three dimensional geometric reconstruction of captured image data
JP2003091721A (en) Method and apparatus for resolving perspective distortion in document image and for calculating line sum in image
KR20160026936A (en) System and method for clean document reconstruction from annotated document images
AU2005209703B2 (en) Grid orientation, scale, translation and modulation estimation
US6813367B1 (en) Method and apparatus for site selection for data embedding
US7024049B2 (en) Method and apparatus for improving image appearance
CN110807342B (en) Bar code positioning method, bar code positioning device, computer equipment and storage medium
JP4756436B2 (en) Pattern recognition apparatus, pattern recognition method, and pattern recognition program
AU742875B2 (en) Method and apparatus for generating a distance image of an original image
JP2003067738A (en) Method and system for removing net point
JP2005039802A (en) Image processor, method and program for processing image, and storage medium
AU746669B2 (en) Method and apparatus for segmenting images
JP2001101399A (en) Method for detecting image inclination, method for detecting margin, method for correcting image inclination and document image processor
US20020164087A1 (en) System and method for fast rotation of binary images using block matching method
JP4259950B2 (en) Image recognition apparatus, image recognition program, and recording medium
JPH09120430A (en) Image processor

Legal Events

Date Code Title Description
FGA Letters patent sealed or granted (standard patent)