JP2008299442A - Image processing device and program - Google Patents

Image processing device and program Download PDF

Info

Publication number
JP2008299442A
JP2008299442A JP2007142549A JP2007142549A JP2008299442A JP 2008299442 A JP2008299442 A JP 2008299442A JP 2007142549 A JP2007142549 A JP 2007142549A JP 2007142549 A JP2007142549 A JP 2007142549A JP 2008299442 A JP2008299442 A JP 2008299442A
Authority
JP
Japan
Prior art keywords
code
image
unit
pattern
coordinate
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.)
Granted
Application number
JP2007142549A
Other languages
Japanese (ja)
Other versions
JP4973316B2 (en
Inventor
Takashi Sonoda
隆志 園田
Kenji Onishi
健司 大西
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.)
Fujifilm Business Innovation Corp
Original Assignee
Fuji Xerox Co Ltd
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
Application filed by Fuji Xerox Co Ltd filed Critical Fuji Xerox Co Ltd
Priority to JP2007142549A priority Critical patent/JP4973316B2/en
Publication of JP2008299442A publication Critical patent/JP2008299442A/en
Application granted granted Critical
Publication of JP4973316B2 publication Critical patent/JP4973316B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To detect a bit string as a whole even if failing to detect the bit string with a single image when reading sequential images representing a bit string from a medium. <P>SOLUTION: An image processing device comprises an image reading part 21 for reading an image, a dot array generation part 22 for generating a dot array from the image, a block detection part 23 for detecting blocks on the dot array to generate a code array, a synchronization code detection part 24 for detecting a synchronization code on the code array, a rotation determination part 25 for determining the rotation of the image according to the synchronization code, a code array rotation part 26 for rotating the code array, and an identification code detection part 30, an x-coordinate code detection part 40 and a y-coordinate code detection part 45 for detecting an identification code, an x-coordinate code and a y-coordinate code respectively from the code array. The identification code detection part 30 extracts identification codes from a plurality of sequentially acquired images and determines the correct identification code according to the occurrence frequency of each identification code. <P>COPYRIGHT: (C)2009,JPO&INPIT

Description

本発明は、画像処理装置、プログラムに関する。   The present invention relates to an image processing apparatus and a program.

表面上の複数の位置を符号化する位置コードを提供する方法は知られている(例えば、特許文献1参照)。この特許文献1では、循環数字列を表面に沿って複数回印刷する。その際、循環数字列の異なるローテーションを、隣り合う数字列間で所定のずれが起こるように使用し、表面を分割した複数のコードウィンドウが、少なくとも3つの循環数字列を備えると共に、隣り合うコードウィンドウの1つの数字列と重なり合う1つの数字列を有するものであり、また、コードウィンドウの位置を、そのコードウィンドウに属している循環数字列間のずれによって符号化している。   A method for providing a position code for encoding a plurality of positions on a surface is known (see, for example, Patent Document 1). In this patent document 1, a cyclic numeral sequence is printed a plurality of times along the surface. At that time, using different rotations of the cyclic numeral sequences so that a predetermined deviation occurs between the adjacent numeric strings, a plurality of code windows divided on the surface include at least three cyclic numeral sequences and adjacent codes. It has one numeric string that overlaps one numeric string of the window, and the position of the code window is encoded by a shift between the cyclic numeric strings belonging to the code window.

論理的に順位付けられたデジタル量子の機械読取り可能なエンコーディングを記録した記録媒体からのエンコーディングの空間的に非同期的な読取りを可能にする技術も知られている(例えば、特許文献2参照)。この特許文献2では、本質的に同一であるエンコーディングの多数のコピーを形成し、機械認識可能な空間同期指標をエンコーディングのコピーの各々の中のプリント位置に組み合わせて、エンコーディングの空間的に同期可能な多数の事例を提供し、それらの事例をレイアウト規則に従って記録媒体における空間的に周期的な中心の格子に書き込んでいる。   There is also known a technique that enables spatially asynchronous reading of encoding from a recording medium that records machine-readable encoding of digital quantum that is logically ranked (see, for example, Patent Document 2). In this document, multiple copies of an encoding that are essentially identical can be formed, and a machine-recognizable spatial synchronization index can be combined with the print position in each of the encoding copies to synchronize the encoding spatially. A large number of cases are provided, and these cases are written in a spatially periodic center grid in the recording medium according to the layout rules.

取り込まれた画像の位置をより大きい画像から決定するためのシステム及び方法も知られている(例えば、特許文献3参照)。この特許文献3では、非反復的な系列を、所定のサイズのサブウィンドウ毎に固有とされた非反復的な配列に折り畳み、その取り込まれた位置を非反復的な配列内のサブウィンドウ毎に決定することによって、取り込まれた画像の位置を、より大きいサブウィンドウの画像から決定している。   Systems and methods for determining the position of captured images from larger images are also known (see, for example, Patent Document 3). In this Patent Document 3, a non-repetitive sequence is folded into a non-repetitive sequence unique to each sub-window of a predetermined size, and the captured position is determined for each sub-window in the non-repetitive sequence. Thus, the position of the captured image is determined from the image of the larger subwindow.

光学的に読み取り可能に記録されるマルチメディア情報の長時間記録及び繰り返し再生を可能とする技術も知られている(例えば、特許文献4参照)。この特許文献4において、記録装置は、プリンタシステムや印刷用製版システムにより、オーディオ情報、映像情報、ディジタルコードデータ等を含めた所謂マルチメディア情報を光学的に読み取り可能なドットコードとして、画像や文字と一緒に紙等の媒体上に記録する。ペン型の情報再生装置は、ドットコードの手動走査に応じてそのドットコードを順次取り込んで、元のオーディオ情報を音声出力器にて、元の映像情報を表示装置にて、元のディジタルコードデータをページプリンタ等にて出力する。   A technique that enables long-time recording and repeated reproduction of multimedia information that is optically readable is also known (see, for example, Patent Document 4). In this patent document 4, a recording apparatus uses a printer system or a printing plate making system as a dot code that can optically read so-called multimedia information including audio information, video information, digital code data, etc. And record on a medium such as paper. The pen-type information reproducing device sequentially captures the dot code according to the manual scanning of the dot code, and the original audio information is output by the audio output device, the original video information is displayed by the display device, and the original digital code data Is output by a page printer or the like.

タブレットを使用せずに、媒体上の座標を精緻に検出できるようにする技術も知られている(例えば、特許文献5参照)。この特許文献5において、ペン型の座標入力装置は、媒体上に形成されその媒体上の座標を示すコードシンボルを光学的に読み取り、この読み取ったコードシンボルをデコードし、読み取った画像中におけるコードシンボルの位置、向き及び歪み量を検出する。そして、デコード後の情報と、コードシンボルの位置、向き及び歪み量とにより、先端部の媒体上での位置の座標を検出する。   There is also known a technique that enables precise detection of coordinates on a medium without using a tablet (see, for example, Patent Document 5). In this patent document 5, a pen-type coordinate input device optically reads a code symbol formed on a medium and indicating the coordinates on the medium, decodes the read code symbol, and reads the code symbol in the read image. The position, orientation, and amount of distortion are detected. Then, the coordinates of the position of the tip on the medium are detected based on the decoded information and the position, orientation, and distortion amount of the code symbol.

特表2003−511762号公報JP-T-2003-511762 特開平9−185669号公報JP-A-9-185669 特開2004−152273号公報JP 2004-152273 A 特開平6−231466号公報JP-A-6-231466 特開2000−293303号公報JP 2000-293303 A

ここで、従来、ビット列を表す画像を媒体から順次読み取った際に、1つの画像だけでビット列を検出できなければ、全体としてもビット列を検出することができないという課題があった。
本発明の目的は、ビット列を表す画像を媒体から順次読み取った際に、1つの画像だけでビット列を検出できなくても全体としてビット列を検出できるようにすることにある。
Here, conventionally, when images representing a bit string are sequentially read from a medium, there is a problem that the bit string cannot be detected as a whole unless the bit string can be detected from only one image.
An object of the present invention is to make it possible to detect a bit string as a whole even when an image representing a bit string is sequentially read from a medium and a bit string cannot be detected from only one image.

請求項1に記載の発明は、ビット列を表す画像が繰り返し印刷された媒体から読み取られた当該画像を取得する取得手段と、前記取得手段により順次取得された複数の前記画像がそれぞれ表す複数のビット列を検出する検出手段と、前記検出手段により検出された前記複数のビット列を用いて、1つのビット列を決定する決定手段とを備えたことを特徴とする画像処理装置である。
請求項2に記載の発明は、前記決定手段は、前記1つのビット列の特定の部分列を、前記複数のビット列における当該特定の部分列に対応する部分列を用いて決定することを特徴とする請求項1記載の画像処理装置である。
請求項3に記載の発明は、前記決定手段は、前記1つのビット列の特定の部分列を、前記複数のビット列における当該特定の部分列に対応する部分列のうち最も多く検出されたものに決定することを特徴とする請求項1記載の画像処理装置である。
請求項4に記載の発明は、前記取得手段により順次取得された前記複数の画像は、予め決められた数の画像であることを特徴とする請求項1記載の画像処理装置である。
請求項5に記載の発明は、前記取得手段により順次取得された前記複数の画像は、前記媒体から画像を読み取る読取装置が特定の状態になっている間に当該媒体から読み取られた画像であることを特徴とする請求項1記載の画像処理装置である。
請求項6に記載の発明は、前記1つのビット列は、前記媒体又は前記媒体に印刷された文書を識別する識別情報を表すビット列であることを特徴とする請求項1記載の画像処理装置である。
請求項7に記載の発明は、コンピュータに、ビット列を表す画像が繰り返し印刷された媒体から読み取られた当該画像を取得する機能と、順次取得された複数の前記画像がそれぞれ表す複数のビット列を検出する機能と、検出された前記複数のビット列を用いて、1つのビット列を決定する機能とを実現させるためのプログラムである。
請求項8に記載の発明は、前記決定する機能では、前記1つのビット列の特定の部分列を、前記複数のビット列における当該特定の部分列に対応する部分列を用いて決定することを特徴とする請求項7記載のプログラムである。
請求項9に記載の発明は、前記決定する機能では、前記1つのビット列の特定の部分列を、前記複数のビット列における当該特定の部分列に対応する部分列のうち最も多く検出されたものに決定することを特徴とする請求項7記載のプログラムである。
請求項10に記載の発明は、順次取得された前記複数の画像は、予め決められた数の画像であることを特徴とする請求項7記載のプログラムである。
請求項11に記載の発明は、順次取得された前記複数の画像は、前記媒体から画像を読み取る読取装置が特定の状態になっている間に当該媒体から読み取られた画像であることを特徴とする請求項7記載のプログラムである。
The invention according to claim 1 is an acquisition unit that acquires an image read from a medium on which an image representing a bit string is repeatedly printed, and a plurality of bit strings that are respectively represented by the plurality of images sequentially acquired by the acquisition unit. An image processing apparatus comprising: a detecting unit that detects the image data; and a determining unit that determines one bit string using the plurality of bit strings detected by the detecting unit.
The invention according to claim 2 is characterized in that the determining means determines a specific partial sequence of the one bit sequence using a partial sequence corresponding to the specific partial sequence in the plurality of bit sequences. An image processing apparatus according to claim 1.
According to a third aspect of the present invention, the determining unit determines a specific partial sequence of the one bit sequence to be the most frequently detected partial sequence corresponding to the specific partial sequence in the plurality of bit sequences. The image processing apparatus according to claim 1, wherein:
The invention according to claim 4 is the image processing apparatus according to claim 1, wherein the plurality of images sequentially acquired by the acquisition unit is a predetermined number of images.
According to a fifth aspect of the present invention, the plurality of images sequentially acquired by the acquisition unit are images read from the medium while the reading device that reads the image from the medium is in a specific state. The image processing apparatus according to claim 1.
The invention according to claim 6 is the image processing apparatus according to claim 1, wherein the one bit string is a bit string representing identification information for identifying the medium or a document printed on the medium. .
According to a seventh aspect of the present invention, a computer detects a plurality of bit strings respectively represented by a plurality of sequentially acquired images and a function of acquiring the image read from a medium on which an image representing a bit string is repeatedly printed. And a function for determining one bit string using the detected plurality of bit strings.
The invention according to claim 8 is characterized in that, in the determining function, a specific partial sequence of the one bit sequence is determined using a partial sequence corresponding to the specific partial sequence in the plurality of bit sequences. The program according to claim 7.
In the invention according to claim 9, in the determining function, the specific partial sequence of the one bit sequence is determined to be the most detected among the partial sequences corresponding to the specific partial sequence in the plurality of bit sequences. 8. The program according to claim 7, wherein the program is determined.
The invention according to claim 10 is the program according to claim 7, wherein the plurality of images acquired sequentially is a predetermined number of images.
The invention according to claim 11 is characterized in that the plurality of images acquired sequentially are images read from the medium while a reading device that reads the image from the medium is in a specific state. The program according to claim 7.

請求項1の発明は、ビット列を表す画像を媒体から順次読み取った際に、1つの画像だけでビット列を検出できなくても全体としてビット列を検出することができるという効果を有する。
請求項2の発明は、本構成を有していない場合に比較して、画像からのビット列の検出の精度が高まるという効果を有する。
請求項3の発明は、本構成を有していない場合に比較して、画像からのビット列の検出の精度が高まるという効果を有する。
請求項4の発明は、本構成を有していない場合に比較して、ビット列の検出に用いる画像を確実に取得できるという効果を有する。
請求項5の発明は、ビット列の検出に用いる画像を読取装置の状態に連動して取得することができるという効果を有する。
請求項6の発明は、識別情報を表す画像を媒体から順次読み取った際に、1つの画像だけで識別情報を検出できなくても全体として識別情報を検出することができるという効果を有する。
請求項7の発明は、ビット列を表す画像を媒体から順次読み取った際に、1つの画像だけでビット列を検出できなくても全体としてビット列を検出することができるという効果を有する。
請求項8の発明は、本構成を有していない場合に比較して、画像からのビット列の検出の精度が高まるという効果を有する。
請求項9の発明は、本構成を有していない場合に比較して、画像からのビット列の検出の精度が高まるという効果を有する。
請求項10の発明は、本構成を有していない場合に比較して、ビット列の検出に用いる画像を確実に取得できるという効果を有する。
請求項11の発明は、ビット列の検出に用いる画像を読取装置の状態に連動して取得することができるという効果を有する。
According to the first aspect of the present invention, when an image representing a bit string is sequentially read from the medium, the bit string can be detected as a whole even if the bit string cannot be detected from only one image.
The invention of claim 2 has an effect that the accuracy of detection of a bit string from an image is increased as compared with the case where this configuration is not provided.
The invention of claim 3 has an effect that the accuracy of detection of a bit string from an image is increased as compared with the case where the present configuration is not provided.
The invention of claim 4 has an effect that an image used for detection of a bit string can be reliably acquired as compared with the case where the present configuration is not provided.
The invention of claim 5 has an effect that an image used for detection of a bit string can be acquired in conjunction with the state of the reading device.
According to the sixth aspect of the present invention, when images representing the identification information are sequentially read from the medium, the identification information can be detected as a whole even if the identification information cannot be detected from only one image.
The invention of claim 7 has an effect that when an image representing a bit string is sequentially read from a medium, the bit string can be detected as a whole even if the bit string cannot be detected from only one image.
The invention according to claim 8 has an effect that the accuracy of detection of the bit string from the image is increased as compared with the case where the present configuration is not provided.
The invention of claim 9 has an effect that the accuracy of detection of a bit string from an image is increased as compared with the case where the present configuration is not provided.
The invention of claim 10 has an effect that an image used for detection of a bit string can be reliably acquired as compared with a case where the present configuration is not provided.
The invention of claim 11 has the effect that an image used for detection of a bit string can be acquired in conjunction with the state of the reading device.

以下、添付図面を参照して、本発明を実施するための最良の形態(以下、「実施の形態」という)について詳細に説明する。
本実施の形態では、m(m≧3)箇所から選択したn(1≦n<m)箇所に単位画像を配置してなるパターン画像(以下、「単位符号パターン」という)によってmCn(=m!/{(m−n)!×n!})通りの情報を表現する。つまり、1つの単位画像を情報に対応させるのではなく、複数の単位画像を情報に対応させている。仮に1つの単位画像を情報に対応させたとすると、単位画像が欠損したり、ノイズが加わったりした場合に、誤った情報を表現してしまうという欠点がある。これに対して、例えば2つの単位画像を情報に対応させたとすると、単位画像が1つであったり3つであったりした場合に、容易に誤りであることが分かる。更に、1つの単位画像で1ビット、又は、高々2ビットを表現する方法では、情報を表現するパターンと視覚的に似たパターンで、情報パターンの読出しを制御する同期パターンを表現することができない。このようなことから、本実施の形態では、上記のような符号化方式を採用している。以下では、このような符号化方式をmCn方式と称する。
ここで、単位画像としては、如何なる形状のものを用いてもよい。本実施の形態では、単位画像の一例としてドット画像(以下、単に「ドット」という)を用いるが、例えば、斜線パターン等、他の形状の画像であってもよい。
The best mode for carrying out the present invention (hereinafter referred to as “embodiment”) will be described in detail below with reference to the accompanying drawings.
In the present embodiment, mCn (= m) by a pattern image (hereinafter referred to as “unit code pattern”) in which unit images are arranged at n (1 ≦ n <m) locations selected from m (m ≧ 3) locations. ! / {(Mn)! × n!}) Expresses the information as shown. That is, instead of associating one unit image with information, a plurality of unit images are associated with information. Assuming that one unit image is associated with information, there is a drawback in that erroneous information is expressed when the unit image is lost or noise is added. On the other hand, for example, if two unit images are associated with information, it can be easily understood that there is an error when the number of unit images is one or three. Furthermore, in the method of expressing 1 bit or at most 2 bits in one unit image, it is not possible to express a synchronous pattern that controls reading of the information pattern with a pattern visually similar to the pattern that represents information. . For this reason, the present embodiment employs the above encoding method. Hereinafter, such an encoding method is referred to as an mCn method.
Here, a unit image having any shape may be used. In the present embodiment, a dot image (hereinafter simply referred to as “dot”) is used as an example of a unit image, but an image having another shape such as a hatched pattern may be used.

図1に、mCn方式における単位符号パターンの例を示す。
図では、黒色の領域と斜線の領域をドット配置可能な領域とし、その間にある白色の領域をドット配置不可能な領域としている。そして、ドット配置可能な領域のうち、黒色の領域にドットが配置され、斜線の領域にはドットが配置されていないことを示している。即ち、図1は、縦3ドット、横3ドットの合計9ドットを配置可能な領域を設けた例を示しており、(a)は、ドット配置可能な領域に2ドットを配置する9C2方式における単位符号パターンであり、(b)は、ドット配置可能な領域に3ドットを配置する9C3方式における単位符号パターンである。
FIG. 1 shows an example of a unit code pattern in the mCn system.
In the figure, a black area and a hatched area are areas where dots can be arranged, and a white area between them is an area where dots cannot be arranged. Of the areas where dots can be arranged, dots are arranged in black areas and dots are not arranged in hatched areas. That is, FIG. 1 shows an example in which an area where a total of 9 dots of 3 dots in the vertical direction and 3 dots in the horizontal direction can be arranged is provided. FIG. FIG. 6B shows a unit code pattern, and FIG. 5B shows a unit code pattern in the 9C3 method in which 3 dots are arranged in an area where dots can be arranged.

ところで、図1で配置されるドット(黒色の領域)は、あくまで情報表現のためのドットであり、画像を構成する最小単位であるドット(図1の最小の四角)とは必ずしも一致しない。本実施の形態において、「ドット」というときは前者のドットを指し、後者のドットは「ピクセル」と呼ぶことにすれば、ドットは、600dpiにおける2ピクセル×2ピクセルの大きさを有することになる。600dpiにおける1ピクセルの大きさは0.0423mmなので、ドットの一辺は、84.6μm(=0.0423mm×2)である。ドットは、大きくなればなるほど目に付きやすくなるため、できるだけ小さいほうが好ましい。ところが、あまり小さくすると、プリンタで印刷できなくなってしまう。そこで、ドットの大きさとして、50μmより大きく100μmより小さい上記の値を採用している。但し、上記の値84.6μmは、あくまで計算上の数値であり、実際に印刷されたトナー像では100μm程度になる。   By the way, the dots (black areas) arranged in FIG. 1 are only for information representation, and do not necessarily match the dots (minimum squares in FIG. 1) which are the minimum units constituting the image. In this embodiment, when “dot” refers to the former dot and the latter dot is referred to as “pixel”, the dot has a size of 2 pixels × 2 pixels at 600 dpi. . Since the size of one pixel at 600 dpi is 0.0423 mm, one side of the dot is 84.6 μm (= 0.0423 mm × 2). The larger the dot, the more likely it will be noticeable, so it is preferable to make it as small as possible. However, if it is too small, printing with a printer becomes impossible. Therefore, the above value is adopted as the dot size, which is larger than 50 μm and smaller than 100 μm. However, the above value 84.6 μm is a numerical value to the last, and is about 100 μm in the actually printed toner image.

また、図2に、単位符号パターンの他の例を示す。尚、この図では、ドット間の空白を省略している。
図2(a)は、図1(a)に示した9C2方式における全ての単位符号パターンを示している。9C2方式では、これらの単位符号パターンを用いて、36(=)通りの情報を表現する。また、図2(b)は、図1(b)に示した9C3方式における全ての単位符号パターンを示している。9C3方式では、これらの単位符号パターンを用いて、84(=)通りの情報を表現する。
FIG. 2 shows another example of the unit code pattern. In this figure, spaces between dots are omitted.
FIG. 2A shows all unit code patterns in the 9C2 system shown in FIG. In the 9C2 system, 36 (= 9 C 2 ) types of information are expressed using these unit code patterns. FIG. 2B shows all unit code patterns in the 9C3 system shown in FIG. In the 9C3 system, 84 (= 9 C 3 ) types of information are expressed using these unit code patterns.

尚、単位符号パターンは、m=9の場合に限定されるものではなく、mの値として、例えば、4、16等の値を採用してもよい。また、nの値も1≦n<mを満たしていれば如何なる値を採用してもよい。
また、mの値としては、平方数(整数の2乗)だけでなく、異なる2つの整数の積を採用してもよい。つまり、ドットを配置可能な領域は、3ドット×3ドットを配置する場合のような正方形の領域に限らず、3ドット×4ドットを配置する場合のような長方形の領域であってもよい。尚、本明細書において、長方形とは、隣り合う2辺の長さが等しくない矩形のことをいうものとする。
The unit code pattern is not limited to m = 9. For example, a value such as 4, 16 may be adopted as the value of m. Also, any value may be adopted as long as n satisfies 1 ≦ n <m.
Further, as the value of m, not only a square number (the square of an integer) but also a product of two different integers may be adopted. That is, the area in which dots can be arranged is not limited to a square area as in the case of arranging 3 dots × 3 dots, but may be a rectangular area as in the case of arranging 3 dots × 4 dots. In this specification, the rectangle means a rectangle in which the lengths of two adjacent sides are not equal.

このように、m箇所からn箇所を選択することでmCn種類の単位符号パターンを用意しているが、本実施の形態では、これらの単位符号パターンのうち、特定のパターンを情報パターンとして利用し、残りを同期パターンとして利用する。ここで、情報パターンとは、媒体に埋め込む情報を表現するパターンである。また、同期パターンとは、媒体に印刷された情報パターンを取り出すために用いられるパターンである。例えば、情報パターンの位置を特定したり、画像の回転を検出したりするために用いられる。尚、媒体としては、画像を印刷することが可能であれば、如何なるものを用いてもよい。紙が代表例なので、以下では媒体を紙として説明するが、金属、プラスチック、繊維等であってもよい。   In this way, mCn types of unit code patterns are prepared by selecting n locations from m locations. In this embodiment, a specific pattern is used as an information pattern among these unit code patterns. The rest is used as a synchronization pattern. Here, the information pattern is a pattern representing information to be embedded in the medium. The synchronization pattern is a pattern used for taking out an information pattern printed on a medium. For example, it is used for specifying the position of the information pattern or detecting the rotation of the image. Any medium may be used as long as an image can be printed. Since paper is a representative example, the medium will be described as paper below, but metal, plastic, fiber, or the like may be used.

ここで、同期パターンについて説明する。
図3は、9C2方式における同期パターンの例である。このようにmCn方式におけるmが平方数である場合は、画像の回転の検出のために4種類の単位符号パターンを同期パターンとして用意する必要がある。ここでは、パターン値32の単位符号パターンを正立した同期パターンとしている。また、パターン値33の単位符号パターンを右に90度回転した同期パターン、パターン値34の単位符号パターンを右に180度回転した同期パターン、パターン値35の単位符号パターンを右に270度回転した同期パターンとしている。この場合、36種類の単位符号パターンからこの4種類の同期パターンを除いた残りを情報パターンとし、5ビットの情報を表現するとよい。但し、36種類の単位符号パターンの情報パターンと同期パターンへの振り分け方は、これには限らない。例えば、4種類で1組を構成する同期パターンの組を5つ用意し、残りの16種類の情報パターンで4ビットの情報を表現してもよい。
Here, the synchronization pattern will be described.
FIG. 3 is an example of a synchronization pattern in the 9C2 system. Thus, when m in the mCn system is a square number, it is necessary to prepare four types of unit code patterns as synchronization patterns in order to detect image rotation. Here, the unit code pattern of the pattern value 32 is an upright synchronization pattern. In addition, the unit code pattern of pattern value 33 is rotated 90 degrees to the right, the synchronization pattern of unit value pattern 34 is rotated 180 degrees to the right, and the unit code pattern of pattern value 35 is rotated 270 degrees to the right. The synchronization pattern is used. In this case, 5 bits of information may be expressed by using the remainder obtained by removing these four types of synchronization patterns from the 36 types of unit code patterns as an information pattern. However, the method of assigning 36 types of unit code patterns to information patterns and synchronization patterns is not limited to this. For example, five sets of synchronization patterns that constitute one set of four types may be prepared, and the remaining 16 types of information patterns may represent 4-bit information.

尚、図示しないが、mCnにおけるmが異なる2つの整数の積である場合は、画像の回転の検出のために2種類の単位符号パターンを同期パターンとして用意すればよい。例えば、縦3ドット×横4ドットを配置可能な領域が検出されるべきなのに、縦4ドット×横3ドットを配置可能な領域が検出された場合は、その時点で画像が90度又は270度回転していることが分かるからである。   Although not shown, when m in mCn is a product of two different integers, two types of unit code patterns may be prepared as synchronization patterns in order to detect image rotation. For example, when an area in which 3 dots in the vertical direction and 4 dots in the horizontal direction should be detected but an area in which the 4 dots in the vertical direction and 3 dots in the horizontal direction can be arranged is detected, the image is 90 degrees or 270 degrees at that time. It is because it turns out that it is rotating.

次に、上述した単位符号パターンから構成される符号ブロックについて説明する。
図4は、符号ブロックの一例を示したものである。図では、9C2方式における単位符号パターンを使用していることも同時に示している。即ち、36種類の単位符号パターンを、例えば、同期パターンとして使用する4パターンと、情報パターンとして使用する32パターンとに分け、各パターンをレイアウトに従って配置する。
図では、レイアウトとして、3ドット×3ドットを配置可能な領域(以下、「ブロック」という)を5個×5個の25個並べたものを採用している。そして、この25個のブロックのうち、左上の1ブロックに同期パターンを配置している。また、同期パターンの右の4ブロックに紙面上のX方向の座標を特定するX座標情報を表す情報パターンを配置し、同期パターンの下の4ブロックに紙面上のY方向の座標を特定するY座標情報を表す情報パターンを配置している。更に、これらの座標情報を表す情報パターンで囲まれた16ブロックに、紙面又は紙面に印刷される文書の識別情報を表す情報パターンを配置している。
尚、9C2方式における単位符号パターンはあくまで例であり、図の左下に示すように、9C3方式における単位符号パターンを使用してもよい。
Next, a code block composed of the above-described unit code pattern will be described.
FIG. 4 shows an example of a code block. In the figure, it is also shown that a unit code pattern in the 9C2 system is used. That is, 36 types of unit code patterns are divided into, for example, 4 patterns used as synchronization patterns and 32 patterns used as information patterns, and each pattern is arranged according to a layout.
In the figure, a layout in which 3 areas × 3 dots area (hereinafter referred to as “block”) 25 × 5 × 5 are arranged is used. Of the 25 blocks, a synchronization pattern is arranged in the upper left block. In addition, an information pattern representing X coordinate information that specifies coordinates in the X direction on the paper surface is arranged in the four blocks to the right of the synchronization pattern, and the Y direction coordinates on the paper surface are specified in the four blocks below the synchronization pattern. An information pattern representing coordinate information is arranged. Further, an information pattern representing the identification information of the document printed on the paper surface or the paper surface is arranged in 16 blocks surrounded by the information pattern representing the coordinate information.
The unit code pattern in the 9C2 system is merely an example, and the unit code pattern in the 9C3 system may be used as shown in the lower left of the figure.

また、本実施の形態では、符号ブロックのレイアウトとして、次の3つのレイアウトを想定している。第一に、識別情報と座標情報を符号化したパターンを配置したペンデバイス向けレイアウト、第二に、識別情報のみを符号化したパターンを配置したスキャナ向けレイアウト、第三に、識別情報と座標情報を符号化したパターンとスキャナを制御するための特定のパターンとを配置したスキャナ向けレイアウトである。尚、紙面に印刷された画像を読み取るスキャナには、比較的狭い範囲の画像を読み取るスキャナと、比較的広い範囲の画像を読み取るスキャナとがあるが、ここでは、前者のスキャナをペン型スキャナを例にとって「ペンデバイス」と表記し、後者のスキャナを単に「スキャナ」と表記している。
尚、第二のレイアウトと、第三のレイアウトはスキャナ向けではあるが、本実施の形態では、これらをペンデバイスで読み取ることを想定している。
In the present embodiment, the following three layouts are assumed as the layout of the code block. First, a layout for a pen device in which a pattern in which identification information and coordinate information are encoded is arranged. Second, a layout for a scanner in which a pattern in which only identification information is encoded is arranged. Third, the identification information and coordinate information. This is a layout for a scanner in which a pattern obtained by encoding and a specific pattern for controlling the scanner are arranged. There are two types of scanners that read images printed on paper: a scanner that reads a relatively narrow range of images and a scanner that reads a relatively wide range of images. Here, the former scanner is a pen-type scanner. In the example, “pen device” is indicated, and the latter scanner is simply indicated as “scanner”.
Although the second layout and the third layout are for a scanner, in the present embodiment, it is assumed that these are read by a pen device.

以下、これらのレイアウトを順に説明する。
(1)識別情報と座標情報を符号化したパターンを配置したペンデバイス向けレイアウト
図5に、このようなレイアウトの一部を示す。
このレイアウトでは、図4に示した符号ブロックを基本単位とし、この符号ブロックを紙面全体に周期的に配置する。図では、同期符号を「S」で表している。また、座標情報は、紙面の縦及び横に渡ってM系列で表現する。図では、M系列で表現されたX座標を、X1,X2,…,X12で表し、M系列で表現されたY座標を、Y1,Y2,…,Y12で表している。更に、識別情報の符号化には、幾つかの方法の利用が考えられるが、本実施の形態では、RS符号化が適している。RS符号は多値の符号法であり、この場合、ブロックの表現をRS符号の多値に対応させるとよいからである。図では、RS符号で表現された識別情報を、IXY(X=1〜4,Y=1〜4)で表している。
Hereinafter, these layouts will be described in order.
(1) Pen device layout in which a pattern in which identification information and coordinate information are encoded is arranged. FIG. 5 shows a part of such a layout.
In this layout, the code block shown in FIG. 4 is used as a basic unit, and this code block is periodically arranged on the entire sheet. In the figure, the synchronization code is represented by “S”. Also, the coordinate information is expressed in M series over the vertical and horizontal sides of the page. In the figure, X coordinates expressed in the M series are represented by X1, X2,..., X12, and Y coordinates represented in the M series are represented by Y1, Y2,. Furthermore, although some methods can be used for encoding the identification information, RS encoding is suitable in this embodiment. This is because the RS code is a multi-level coding method, and in this case, the block representation should correspond to the multi-value of the RS code. In the figure, the identification information expressed by the RS code is represented by IXY (X = 1 to 4, Y = 1 to 4).

(2)識別情報のみを符号化したパターンを配置したスキャナ向けレイアウト
図6に、このようなレイアウトの一部を示す。
このレイアウトでは、まず、情報を埋め込むのに必要なブロック数を計算する。例えば、誤り訂正符号も含めて200ビットが必要であったとする。9C3方式では、一例として1ブロックで6ビットの情報を表現するので、34ブロックで204ビットを表現する。更にこれを矩形で表現するために、縦5ブロック、横7ブロックの合計35ブロックを配置したレイアウトとする。尚、縦6ブロック、横6ブロックであってもよいが、図では5ブロック×7ブロックとしている。
但し、図6には、汎用的なレイアウトを示している。即ち、同期パターンが配置されたブロックを黒色で示し、これらのブロックに囲まれた太線内の符号ブロックは、横Xブロック、縦Yブロックからなるものとしている。そして、この領域に、識別情報を表す情報パターンが埋め込まれている。図では、識別情報を、YX(X=Y=1を除く)で表している。上記の例では、X=7、Y=5である。
(2) Layout for a scanner in which a pattern in which only identification information is encoded is arranged. FIG. 6 shows a part of such a layout.
In this layout, first, the number of blocks necessary for embedding information is calculated. For example, it is assumed that 200 bits including an error correction code are necessary. In the 9C3 system, for example, 6 bits of information is represented by one block, and 204 bits are represented by 34 blocks. Furthermore, in order to express this with a rectangle, a layout is arranged in which a total of 35 blocks of 5 vertical blocks and 7 horizontal blocks are arranged. In addition, although it may be 6 vertical blocks and 6 horizontal blocks, it is 5 blocks × 7 blocks in the figure.
However, FIG. 6 shows a general-purpose layout. That is, the block in which the synchronization pattern is arranged is shown in black, and the code block within the bold line surrounded by these blocks is composed of a horizontal X block and a vertical Y block. An information pattern representing identification information is embedded in this area. In the figure, the identification information is represented by YX (excluding X = Y = 1). In the above example, X = 7 and Y = 5.

(3)識別情報と座標情報を符号化したパターンとスキャナを制御するための特定のパターンとを配置したスキャナ向けレイアウト
図7に、このようなレイアウトの一部を示す。
このレイアウトでも、(1)のレイアウトと同様、縦5ブロック、横5ブロックの25ブロックを基本単位とする。ここで、紙面に印刷された画像を読み取った際に、コピーを禁止する等、スキャナに対して何らかの制御を行うことを考える。例えば、識別情報に情報を埋め込んでおき、復号後にスキャナを制御することも考えられるが、復号処理に時間がかかり、制御が間に合わない可能性もある。そこで、符号ブロックに含まれるブロックのうち「*」で示したブロックに対して、復号処理を行わなくても制御が可能な特殊なパターンを埋め込み、パターン認識により制御を行うようにする。
(3) Scanner layout in which a pattern obtained by encoding identification information and coordinate information and a specific pattern for controlling the scanner are arranged. FIG. 7 shows a part of such a layout.
In this layout, as in the layout of (1), 25 blocks of 5 vertical blocks and 5 horizontal blocks are used as basic units. Here, let us consider performing some control on the scanner, such as prohibiting copying when an image printed on paper is read. For example, it is conceivable to embed information in the identification information and control the scanner after decoding, but there is a possibility that the decoding process takes time and the control is not in time. Therefore, a special pattern that can be controlled without performing decoding processing is embedded in the blocks indicated by “*” among the blocks included in the code block, and control is performed by pattern recognition.

尚、ここで説明した3つのレイアウトには、同じパターンが周期的に配置されているという共通の特徴がある。但し、画像として同じパターンであることが必ずしも要求されるわけではなく、同じビット列を表すパターンが周期的に配置されていればよい。このようなことから、上記レイアウトを有する画像は、特定のビット列を表す画像が繰り返し配置された繰り返し画像の一例であることになる。   The three layouts described here have a common feature that the same pattern is periodically arranged. However, it is not always required that the images have the same pattern, and it is only necessary that patterns representing the same bit string are periodically arranged. For this reason, the image having the above layout is an example of a repeated image in which images representing a specific bit string are repeatedly arranged.

次いで、このような画像を生成する画像生成装置10について説明する。
図8は、画像生成装置10の構成例を示したブロック図である。
図示するように、画像生成装置10は、情報取得部11と、識別符号生成部12と、X座標符号生成部13と、Y座標符号生成部14と、符号配列生成部15と、パターン画像記憶部16と、符号画像生成部17とを備える。
Next, the image generation apparatus 10 that generates such an image will be described.
FIG. 8 is a block diagram illustrating a configuration example of the image generation apparatus 10.
As shown in the figure, the image generation apparatus 10 includes an information acquisition unit 11, an identification code generation unit 12, an X coordinate code generation unit 13, a Y coordinate code generation unit 14, a code array generation unit 15, and a pattern image storage. Unit 16 and a code image generation unit 17.

情報取得部11は、紙面又は紙面に印刷される文書の識別情報、及び、紙面上での座標情報を取得する。そして、前者を識別符号生成部12に出力し、後者のうち、X座標情報をX座標符号生成部13に、Y座標情報をY座標符号生成部14に出力する。   The information acquisition unit 11 acquires the identification information of the paper or the document printed on the paper and the coordinate information on the paper. Then, the former is output to the identification code generation unit 12, and among the latter, the X coordinate information is output to the X coordinate code generation unit 13 and the Y coordinate information is output to the Y coordinate code generation unit 14.

識別符号生成部12は、情報取得部11から取得した識別情報を符号化し、符号化された識別情報である識別符号を符号配列生成部15に出力する。この識別情報の符号化は、ブロック分割、RS符号化の処理を含む。
このうち、ブロック分割は、識別情報を構成するビット列を、RS符号化を行うために複数のブロックに分割する処理である。例えば、9C2方式で5ビットの情報を表現可能な情報パターンを用いる場合、60ビットの識別情報は、ブロック長が5ビットの12個のブロックに分割される。
また、RS符号化は、分割されたブロックに対してRS符号化を行い、誤り訂正のための冗長ブロックを付加する処理である。先の例において2ブロックの誤りを訂正可能なRS符号を採用したとすると、符号長は16ブロックとなる。
The identification code generation unit 12 encodes the identification information acquired from the information acquisition unit 11 and outputs the identification code that is the encoded identification information to the code array generation unit 15. The coding of the identification information includes block division and RS coding processing.
Among these, the block division is a process of dividing the bit string constituting the identification information into a plurality of blocks in order to perform RS encoding. For example, when an information pattern capable of expressing 5-bit information in the 9C2 system is used, the 60-bit identification information is divided into 12 blocks having a block length of 5 bits.
RS encoding is a process of performing RS encoding on the divided blocks and adding redundant blocks for error correction. If an RS code capable of correcting an error of 2 blocks is adopted in the previous example, the code length is 16 blocks.

X座標符号生成部13は、X座標情報を符号化する。Y座標符号生成部14は、Y座標情報を符号化する。そして、これらは、符号化された座標情報である座標符号を符号配列生成部15に出力する。この座標情報の符号化は、M系列符号化、ブロック分割の処理を含む。
このうち、M系列符号化は、M系列を使用して座標情報を符号化する処理である。例えば、符号化したい座標情報の長さから必要なM系列の次数を求め、M系列を動的に生成することで座標符号を生成する。但し、予め符号化したい座標情報の長さが分かっている場合には、M系列を画像生成装置10のメモリ等に格納しておき、画像生成時にそれを読み出す構成としてもよい。
また、ブロック分割は、M系列を複数のブロックに分割する処理である。例えば、情報パターンとして16種類の単位符号パターンを選択したとすると、符号ブロックにおける各ブロックには4ビットの情報が格納される。従って、図4のようなレイアウトを有する符号ブロックに対して、X座標情報は、16ビット分格納される。ここで、12次のM系列を利用したとすると、M系列の系列長は4095(=212−1)となる。この系列を4ビットごとに切り出し、符号パターンで表現していくと、最後に3ビットあまることになる。この3ビットに、M系列の最初の1ビットを加えて4ビットとし単位符号パターンで表す。更に、M系列の2ビット目から4ビットごとに切り出し単位符号パターンで表す。すると、次の周期は、M系列の3ビット目から始まり、その次の周期は、M系列の4ビット目から始まる。更に、5周期目は、5ビット目からとなるが、これは最初の周期と一致する。従って、M系列の4周期を4ビットごとに切り出していくと、4095個の単位符号パターンで全てを尽くすことができる。M系列は12次であるので、3つの連続する単位符号パターンは、他のどの位置の連続する符号パターンとも一致することはない。そこで、読出し時には3つの単位符号パターンを読み出せば、復号が可能であるが、誤りを考慮し4ブロックで情報を表現している。
尚、4周期のM系列は、4095個のブロックに分割して格納される。1つのブロックの一辺の長さは、先に述べた印刷条件、即ち、ドットが600dpiにおける2ピクセル×2ピクセルの大きさである場合、0.508mmである。先に述べた第一のレイアウトを採用する場合、連続する4095個のブロックの4ブロックごとに、同期ブロックが挿入される。そこで、5/4倍して、全体で約5118ブロックなので、長さは2599.9mmである。つまり、2599.9mmの長さが符号化されることになる。
また、11次のM系列を使った場合には、2047ビットであり、1299.5mmが符号化される。
The X coordinate code generation unit 13 encodes X coordinate information. The Y coordinate code generation unit 14 encodes the Y coordinate information. And these output the coordinate code | cord | chord which is the encoded coordinate information to the code arrangement | sequence production | generation part 15. FIG. The encoding of the coordinate information includes M-sequence encoding and block division processing.
Among these, the M sequence encoding is a process of encoding coordinate information using the M sequence. For example, a necessary M-sequence order is obtained from the length of coordinate information to be encoded, and a coordinate code is generated by dynamically generating the M-sequence. However, when the length of the coordinate information to be encoded is known in advance, the M series may be stored in the memory or the like of the image generation apparatus 10 and read out when generating the image.
Block division is processing for dividing an M sequence into a plurality of blocks. For example, if 16 types of unit code patterns are selected as the information pattern, 4-bit information is stored in each block in the code block. Therefore, 16 bits of X coordinate information are stored for a code block having a layout as shown in FIG. Here, if a 12th-order M sequence is used, the sequence length of the M sequence is 4095 (= 2 12 −1). When this sequence is cut out every 4 bits and expressed by a code pattern, 3 bits are finally added. The first 1 bit of the M sequence is added to these 3 bits to form 4 bits, which are represented by a unit code pattern. Further, the unit code pattern is cut out every 4 bits from the second bit of the M sequence. Then, the next cycle starts from the third bit of the M sequence, and the next cycle starts from the fourth bit of the M sequence. Furthermore, the fifth cycle starts from the fifth bit, which coincides with the first cycle. Therefore, if 4 periods of the M sequence are cut out every 4 bits, all 4095 unit code patterns can be exhausted. Since the M sequence is twelfth, the three consecutive unit code patterns do not match the continuous code pattern at any other position. Therefore, at the time of reading, decoding is possible by reading three unit code patterns, but information is expressed by four blocks in consideration of errors.
Note that the M sequence of four periods is divided into 4095 blocks and stored. The length of one side of one block is 0.508 mm when the printing conditions described above, i.e., the dot has a size of 2 pixels × 2 pixels at 600 dpi. When the first layout described above is adopted, a synchronization block is inserted every 4 blocks of 4095 consecutive blocks. Therefore, the length is 2599.9 mm because it is multiplied by 5/4 and is about 5118 blocks as a whole. That is, a length of 2599.9 mm is encoded.
When an 11th order M-sequence is used, it is 2047 bits and 1299.5 mm is encoded.

符号配列生成部15は、識別符号生成部12にて生成された識別符号と、X座標符号生成部13及びY座標符号生成部14にて生成された座標符号と、識別符号及び座標符号の読出しを制御する同期符号とを2次元平面に配置して2次元の符号配列を生成する。ここで、同期符号とは、同期パターンに対応する符号である。
パターン画像記憶部16は、例えば図2に示したmCn方式における単位符号パターンを記憶する。ここで、単位符号パターンには、個々の単位符号パターンを一意に特定するパターン値が付されている。例えば、9C2方式における単位符号パターンに対しては、0〜35のパターン値が付されている。これは、符号配列生成部15が生成した2次元の符号配列における各符号値に対応している。即ち、各符号値から単位符号パターンが一意に特定され、選択されるようになっている。尚、本実施の形態において、このパターン画像記憶部16は、予め定められたm及びnに対応するmCn方式における単位符号パターンを少なくとも記憶していればよい。
符号画像生成部17は、符号配列生成部15が生成した2次元の符号配列を参照し、各符号値に対応した単位符号パターンを選択して符号画像を生成する。
The code array generation unit 15 reads the identification code generated by the identification code generation unit 12, the coordinate code generated by the X coordinate code generation unit 13 and the Y coordinate code generation unit 14, and the identification code and the coordinate code. Are arranged on a two-dimensional plane to generate a two-dimensional code array. Here, the synchronization code is a code corresponding to the synchronization pattern.
The pattern image storage unit 16 stores, for example, a unit code pattern in the mCn system shown in FIG. Here, the unit code pattern is assigned a pattern value that uniquely identifies each unit code pattern. For example, pattern values of 0 to 35 are attached to unit code patterns in the 9C2 system. This corresponds to each code value in the two-dimensional code array generated by the code array generation unit 15. That is, a unit code pattern is uniquely identified and selected from each code value. In the present embodiment, the pattern image storage unit 16 may store at least unit code patterns in the mCn system corresponding to predetermined m and n.
The code image generation unit 17 refers to the two-dimensional code array generated by the code array generation unit 15 and selects a unit code pattern corresponding to each code value to generate a code image.

そして、この符号画像は、図示しない画像形成部に渡され、画像形成部が紙面に符号画像を形成する。このとき、画像形成部は、電子文書の文書画像と符号画像とを重畳した重畳画像を紙面に形成するようにしてもよい。また、このように重畳画像を形成する場合には、紙面に対するペンデバイスによる筆記データが電子文書上の適切な位置に反映されるよう電子文書上の位置と紙面上の位置との対応関係を管理することが望ましい。   The code image is transferred to an image forming unit (not shown), and the image forming unit forms a code image on the sheet. At this time, the image forming unit may form a superimposed image in which the document image of the electronic document and the code image are superimposed on the paper surface. In addition, when a superimposed image is formed in this way, the correspondence between the position on the electronic document and the position on the paper is managed so that the writing data by the pen device on the paper is reflected at an appropriate position on the electronic document. It is desirable to do.

また、画像形成部は、符号画像を、例えば電子写真方式を用いて、Kトナー(カーボンを含む赤外光吸収トナー)、又は、特殊トナーにより形成する。
ここで、特殊トナーとしては、可視光領域(400nm〜700nm)における最大吸収率が7%以下であり、近赤外領域(800nm〜1000nm)における吸収率が30%以上の不可視トナーが例示される。ここで、「可視」及び「不可視」は、目視により認識できるかどうかとは関係しない。印刷された媒体に形成された画像が可視光領域における特定の波長の吸収に起因する発色性の有無により認識できるかどうかで「可視」と「不可視」とを区別している。また、可視光領域における特定の波長の吸収に起因する発色性が若干あるが、人間の目で認識し難いものも「不可視」に含める。
The image forming unit forms the code image with K toner (infrared light absorbing toner containing carbon) or special toner, for example, using an electrophotographic system.
Here, as the special toner, an invisible toner having a maximum absorption rate of 7% or less in the visible light region (400 nm to 700 nm) and an absorption rate of 30% or more in the near infrared region (800 nm to 1000 nm) is exemplified. . Here, “visible” and “invisible” are not related to whether they can be recognized visually. “Visible” and “invisible” are distinguished depending on whether or not an image formed on a printed medium can be recognized by the presence or absence of color development due to absorption of a specific wavelength in the visible light region. Further, “invisible” includes those that have some color developability due to absorption of a specific wavelength in the visible light region but are difficult to recognize with human eyes.

尚、これらの機能は、ソフトウェアとハードウェア資源とが協働することにより実現される。具体的には、画像生成装置10のCPU91(図22参照)が、情報取得部11、識別符号生成部12、X座標符号生成部13、Y座標符号生成部14、符号配列生成部15、符号画像生成部17を実現するプログラムを、例えば、磁気ディスク装置93(図22参照)からメインメモリ92(図22参照)に読み込んで実行することにより、実現される。また、パターン画像記憶部16は、例えば、磁気ディスク装置93(図22参照)を用いて実現するとよい。更に、磁気ディスク装置93(図22参照)に記憶されるプログラムやデータは、CD等の記録媒体からロードしてもよいし、インターネット等の通信手段を介してダウンロードしてもよい。   These functions are realized by cooperation between software and hardware resources. Specifically, the CPU 91 (see FIG. 22) of the image generation apparatus 10 includes the information acquisition unit 11, the identification code generation unit 12, the X coordinate code generation unit 13, the Y coordinate code generation unit 14, the code array generation unit 15, and the code. For example, the program for realizing the image generation unit 17 is realized by reading the program from the magnetic disk device 93 (see FIG. 22) into the main memory 92 (see FIG. 22) and executing it. The pattern image storage unit 16 may be realized using, for example, a magnetic disk device 93 (see FIG. 22). Furthermore, the program and data stored in the magnetic disk device 93 (see FIG. 22) may be loaded from a recording medium such as a CD, or may be downloaded via communication means such as the Internet.

次に、紙面に形成された符号画像を読み取って処理する画像処理装置20について説明する。
図9は、画像処理装置20の構成例を示したブロック図である。
図示するように、画像処理装置20は、画像読取部21と、ドット配列生成部22と、ブロック検出部23と、同期符号検出部24と、回転判定部25と、符号配列回転部26とを備える。また、識別符号検出部30と、識別符号復元部31と、識別符号復号部32と、識別符号誤り検出部33と、識別符号誤り訂正部34とを備える。更に、X座標符号検出部40と、X座標符号復号部42と、X座標符号誤り検出部43と、X座標符号誤り訂正部44と、Y座標符号検出部45と、Y座標符号復号部47と、Y座標符号誤り検出部48と、Y座標符号誤り訂正部49と、情報出力部50とを備える。
Next, the image processing apparatus 20 that reads and processes the code image formed on the paper surface will be described.
FIG. 9 is a block diagram illustrating a configuration example of the image processing apparatus 20.
As illustrated, the image processing apparatus 20 includes an image reading unit 21, a dot array generation unit 22, a block detection unit 23, a synchronization code detection unit 24, a rotation determination unit 25, and a code array rotation unit 26. Prepare. In addition, an identification code detection unit 30, an identification code restoration unit 31, an identification code decoding unit 32, an identification code error detection unit 33, and an identification code error correction unit 34 are provided. Furthermore, an X coordinate code detection unit 40, an X coordinate code decoding unit 42, an X coordinate code error detection unit 43, an X coordinate code error correction unit 44, a Y coordinate code detection unit 45, and a Y coordinate code decoding unit 47. A Y coordinate code error detection unit 48, a Y coordinate code error correction unit 49, and an information output unit 50.

画像読取部21は、CCD(Charge Coupled Devices)やCMOS(Complementary Metal Oxide Semiconductor)等の撮像素子を用いて、紙面に印刷された符号画像を読み取る。また、画像読取部21は、読み取った画像に含まれるノイズを除去するための処理も行う。ここで、ノイズには、例えば、撮像素子感度のばらつきや電子回路により発生するノイズがある。ノイズ除去の処理の種類は、撮像系の特性に合わせるべきだが、ぼかし処理やアンシャープマスキング等の先鋭化処理を適用するとよい。更に、画像読取部21は、ノイズが除去された画像からドットを検出する。つまり、ドットが形成された位置を特定する。ここで、ドットの検出は、まず、2値化処理によりドット画像の部分と、その他の背景画像の部分とを切り分け、2値化された個々の画像位置からドットの位置を検出する。その際、2値化された画像にノイズ成分が多数含まれる場合があるため、2値化された画像の面積や形状によりドットの判定を行うフィルタ処理を組み合わせる必要がある。本実施の形態では、画像を取得する取得手段の一例として、画像読取部21のドットを検出する部分を備えている。   The image reading unit 21 reads a code image printed on a paper surface using an imaging element such as a charge coupled device (CCD) or a complementary metal oxide semiconductor (CMOS). The image reading unit 21 also performs processing for removing noise included in the read image. Here, the noise includes, for example, variations in image sensor sensitivity and noise generated by an electronic circuit. The type of noise removal processing should match the characteristics of the imaging system, but sharpening processing such as blurring processing and unsharp masking may be applied. Further, the image reading unit 21 detects dots from the image from which noise has been removed. That is, the position where the dot is formed is specified. Here, in the dot detection, first, the dot image portion and other background image portions are separated by binarization processing, and the dot position is detected from each binarized image position. At that time, since there are cases where a lot of noise components are included in the binarized image, it is necessary to combine filter processing for determining dots based on the area and shape of the binarized image. In the present embodiment, as an example of an acquisition unit that acquires an image, a portion for detecting dots of the image reading unit 21 is provided.

ドット配列生成部22は、検出したドットの位置を参照して、ドット配列を生成する。即ち、2次元の配列上で、例えば、ドットがある位置に「1」を、ドットがない位置に「0」を記憶することにより、画像として検出したドットをデジタルデータに置き換える。そして、この2次元の配列をドット配列として出力する。
ブロック検出部23は、ドット配列上で、符号ブロック内の単位符号パターンに対応するブロックを検出する。即ち、単位符号パターンと同じ大きさをもつ矩形のブロック区切りをドット配列上で適宜動かし、ブロック内のドット数が均等になる位置を正しいブロック区切り位置とし、各ブロック内のパターン値を格納した符号配列を生成する。
The dot array generation unit 22 generates a dot array with reference to the detected dot positions. That is, on a two-dimensional array, for example, “1” is stored at a position where there is a dot and “0” is stored at a position where there is no dot, thereby replacing the dot detected as an image with digital data. Then, this two-dimensional array is output as a dot array.
The block detection unit 23 detects a block corresponding to the unit code pattern in the code block on the dot array. In other words, a rectangular block delimiter having the same size as the unit code pattern is appropriately moved on the dot array, the position where the number of dots in the block is equal is the correct block delimiter position, and the code that stores the pattern value in each block Create an array.

同期符号検出部24は、ドット配列から検出された各単位符号パターンの種類を参照して、同期符号を検出する。
回転判定部25は、検出した同期符号に基づいて、画像の回転を判定する。例えば、正方形の単位符号パターンを用いた場合、90度単位で回転している可能性がある。そこで、検出した同期符号が4種類の同期パターンのいずれに対応しているかによって、その向きを検出する。また、長方形の単位符号パターンを用いた場合、180度単位で回転している可能性がある。そこで、検出された同期符号が2種類の同期パターンのいずれに対応しているかによって、その向きを検出する。
符号配列回転部26は、回転判定部25で検出された回転角度だけ符号配列を回転させて、符号配列を正しい向きに設定する。
The synchronization code detector 24 refers to the type of each unit code pattern detected from the dot array and detects the synchronization code.
The rotation determination unit 25 determines image rotation based on the detected synchronization code. For example, when a square unit code pattern is used, there is a possibility of rotating in units of 90 degrees. Therefore, the direction is detected depending on which of the four types of synchronization patterns the detected synchronization code corresponds to. Further, when a rectangular unit code pattern is used, there is a possibility that the unit code pattern is rotated by 180 degrees. Therefore, the direction is detected depending on which of the two types of synchronization patterns the detected synchronization code corresponds to.
The code array rotation unit 26 rotates the code array by the rotation angle detected by the rotation determination unit 25 and sets the code array in the correct direction.

識別符号検出部30は、角度が補正された符号配列から、同期符号の位置を基準にして識別符号を検出する。本実施の形態では、ビット列を検出する検出手段、ビット列を決定する決定手段の一例として、識別符号検出部30を設けている。
識別符号復元部31は、検出された識別符号を正しい符号順に並べ替える。
識別符号復号部32は、図8を参照して説明したRS符号の符号化処理で用いたパラメータ(ブロック数等)と同じパラメータを用いて識別符号を復号し、識別情報を出力する。
識別符号誤り検出部33は、復号された識別符号の誤りを検出し、識別符号誤り訂正部34は、検出した誤りが訂正可能な誤りである場合に、その誤りを訂正する。
The identification code detection unit 30 detects the identification code from the code array whose angle is corrected with reference to the position of the synchronization code. In the present embodiment, the identification code detection unit 30 is provided as an example of a detection unit that detects a bit string and a determination unit that determines a bit string.
The identification code restoration unit 31 rearranges the detected identification codes in the correct code order.
The identification code decoding unit 32 decodes the identification code using the same parameters (such as the number of blocks) used in the RS code encoding process described with reference to FIG. 8, and outputs identification information.
The identification code error detection unit 33 detects an error of the decoded identification code, and the identification code error correction unit 34 corrects the error when the detected error is a correctable error.

X座標符号検出部40は、角度が補正された符号配列から、同期符号の位置を基準にしてX座標符号を検出する。
X座標符号復号部42は、検出されたX座標符号からM系列の部分系列を取り出し、画像生成に使用したM系列におけるこの部分系列の位置を参照し、この位置を同期符号によるオフセットで補正した値をX座標情報として出力する。
X座標符号誤り検出部43は、復号されたX座標符号の誤りを検出し、X座標符号誤り訂正部44は、検出した誤りが訂正可能な誤りである場合に、その誤りを訂正する。
The X coordinate code detection unit 40 detects the X coordinate code from the code array whose angle is corrected with reference to the position of the synchronization code.
The X coordinate code decoding unit 42 extracts the M series partial sequence from the detected X coordinate code, refers to the position of this partial sequence in the M sequence used for image generation, and corrects this position with the offset by the synchronization code The value is output as X coordinate information.
The X coordinate code error detection unit 43 detects an error in the decoded X coordinate code, and the X coordinate code error correction unit 44 corrects the error when the detected error is a correctable error.

Y座標符号検出部45は、角度が補正された符号配列から、同期符号の位置を基準にしてY座標符号を検出する。
Y座標符号復号部47は、検出されたY座標符号からM系列の部分系列を取り出し、画像生成に使用したM系列におけるこの部分系列の位置を参照し、この位置を同期符号によるオフセットで補正した値をY座標情報として出力する。
Y座標符号誤り検出部48は、復号されたY座標符号の誤りを検出し、Y座標符号誤り訂正部49は、検出した誤りが訂正可能な誤りである場合に、その誤りを訂正する。
The Y coordinate code detection unit 45 detects the Y coordinate code from the code array whose angle is corrected with reference to the position of the synchronization code.
The Y coordinate code decoding unit 47 extracts the M series partial sequence from the detected Y coordinate code, refers to the position of this partial sequence in the M sequence used for image generation, and corrects this position with the offset by the synchronization code. The value is output as Y coordinate information.
The Y coordinate code error detection unit 48 detects an error of the decoded Y coordinate code, and the Y coordinate code error correction unit 49 corrects the error when the detected error is a correctable error.

情報出力部50は、識別符号復号部32、X座標符号復号部42、Y座標符号復号部47からそれぞれ取得した識別情報、X座標情報、Y座標情報を出力する。   The information output unit 50 outputs the identification information, the X coordinate information, and the Y coordinate information acquired from the identification code decoding unit 32, the X coordinate code decoding unit 42, and the Y coordinate code decoding unit 47, respectively.

尚、これらの機能は、ソフトウェアとハードウェア資源とが協働することにより実現される。具体的には、画像処理装置20のCPU91(図22参照)が、ドット配列生成部22、ブロック検出部23、同期符号検出部24、回転判定部25、符号配列回転部26、識別符号検出部30、識別符号復元部31、識別符号復号部32、識別符号誤り検出部33、識別符号誤り訂正部34、X座標符号検出部40、X座標符号復号部42、X座標符号誤り検出部43、X座標符号誤り訂正部44、Y座標符号検出部45、Y座標符号復号部47、Y座標符号誤り検出部48、Y座標符号誤り訂正部49、情報出力部50を実現するプログラムを、例えば、磁気ディスク装置93(図22参照)からメインメモリ92(図22参照)に読み込んで実行することにより、実現される。また、磁気ディスク装置93(図22参照)に記憶されるプログラムやデータは、CD等の記録媒体からロードしてもよいし、インターネット等の通信手段を介してダウンロードしてもよい。   These functions are realized by cooperation between software and hardware resources. Specifically, the CPU 91 (see FIG. 22) of the image processing apparatus 20 includes a dot array generation unit 22, a block detection unit 23, a synchronization code detection unit 24, a rotation determination unit 25, a code array rotation unit 26, and an identification code detection unit. 30, an identification code restoration unit 31, an identification code decoding unit 32, an identification code error detection unit 33, an identification code error correction unit 34, an X coordinate code detection unit 40, an X coordinate code decoding unit 42, an X coordinate code error detection unit 43, A program that realizes the X coordinate code error correction unit 44, the Y coordinate code detection unit 45, the Y coordinate code decoding unit 47, the Y coordinate code error detection unit 48, the Y coordinate code error correction unit 49, and the information output unit 50, for example, This is realized by reading from the magnetic disk device 93 (see FIG. 22) into the main memory 92 (see FIG. 22) and executing it. Further, the program and data stored in the magnetic disk device 93 (see FIG. 22) may be loaded from a recording medium such as a CD, or may be downloaded via communication means such as the Internet.

次に、画像処理装置20による画像処理時の動作について説明する。
まず、画像読取部21が、符号画像が印刷された媒体から、所定の大きさの領域の符号画像を読み取る。ここで、図4に示した1つの符号ブロックから情報を復元するのであれば、1つの符号ブロックだけを含む大きさをこの所定の大きさとして採用すればよい。しかしながら、本実施の形態では、複数の符号ブロックから取り出した符号を用いて、情報を復元するので、複数の符号ブロックを含む大きさをこの所定の大きさとして採用する。そして、画像読取部21は、読み取った画像に対して、ノイズの除去やドットの検出等の画像処理を行う。
Next, the operation at the time of image processing by the image processing apparatus 20 will be described.
First, the image reading unit 21 reads a code image of an area having a predetermined size from the medium on which the code image is printed. Here, if information is restored from one code block shown in FIG. 4, a size including only one code block may be adopted as the predetermined size. However, in the present embodiment, information is restored using codes extracted from a plurality of code blocks, and thus a size including a plurality of code blocks is adopted as the predetermined size. The image reading unit 21 performs image processing such as noise removal and dot detection on the read image.

次に、ドット配列生成部22が、ドットを検出した位置に「1」を、ドットを検出しなかった位置に「0」を設定したドット配列を生成する。
その後、ブロック検出部23が、このドット配列にブロック区切りを重ねて、ブロックの境界を検出する。ここで、ブロックとは、図4を参照して説明したように、埋め込まれた情報を復号する際に必要となる最小の単位である。本実施の形態では、符号ブロックとして5ブロック×5ブロックのものを想定している。従って、ブロック区切りとしても、5ブロック×5ブロックの大きさのものを用いる。
Next, the dot array generation unit 22 generates a dot array in which “1” is set at a position where a dot is detected and “0” is set at a position where a dot is not detected.
Thereafter, the block detection unit 23 detects block boundaries by superimposing block delimiters on this dot array. Here, as described with reference to FIG. 4, the block is a minimum unit necessary for decoding the embedded information. In the present embodiment, a code block of 5 blocks × 5 blocks is assumed. Therefore, the block size is 5 blocks × 5 blocks.

図10は、ブロック区切りを移動させてブロックを検出する際の処理を具体的に示した図である。ここでは、9C2方式で符号化が行われたことが分かっており、9C2方式で復号する場合について示している。
まず、ブロック検出部23は、ドット配列生成部22からドット配列を取得する。ここで取得するドット配列のサイズは予め設定されており、(復号に必要なブロック数×ブロックの一辺のドット数+ブロックの一辺のドット数−1)である。ところが、このドット配列は、画像の任意に選択された領域に対応しているので、ブロック区切りの位置は分からない。そこで、初めに、ドット配列の端を基準にブロック分割を行う。この例では、m=9なので、3ドット×3ドットの大きさのブロックからなるブロック区切りを重ねる。次に、各ブロック内のドットを数える。この例では、n=2なので、各ブロック内に2ドットずつ存在する場合のブロック区切りの位置が正しい区切り位置であるが、この位置ではドット数がばらついており、正しくないことが分かる。そこで、ブロック区切りをずらしてブロック内のドット数を数える。即ち、右方向への開始位置、1ドット分移動した位置、2ドット分移動した位置について同様の動作を行う。また、これらの位置のそれぞれに対し、下方向への開始位置、1ドット移動した位置、2ドット移動した位置についても同様の動作を行う。その結果、右方向に1ドット移動し、下方向に2ドット移動した位置において、全てのブロック内のドット数が「2」となる。従って、この位置を正しい区切り位置とする。
FIG. 10 is a diagram specifically showing processing when detecting a block by moving a block break. Here, it is known that encoding has been performed by the 9C2 system, and a case of decoding by the 9C2 system is shown.
First, the block detection unit 23 acquires a dot array from the dot array generation unit 22. The size of the dot arrangement acquired here is preset, and is (number of blocks necessary for decoding × number of dots on one side of block + number of dots on one side of block−1) 2 . However, since this dot arrangement corresponds to an arbitrarily selected area of the image, the position of the block delimiter is unknown. Therefore, first, block division is performed with reference to the end of the dot array. In this example, since m = 9, block delimiters composed of blocks each having a size of 3 dots × 3 dots are overlapped. Next, the dots in each block are counted. In this example, since n = 2, the position of the block delimiter when there are two dots in each block is the correct delimiter position, but it can be seen that the number of dots varies at this position and is not correct. Therefore, the number of dots in the block is counted by shifting the block delimiter. That is, the same operation is performed for the start position in the right direction, the position moved by one dot, and the position moved by two dots. In addition, the same operation is performed for each of these positions with respect to the start position in the downward direction, the position moved by 1 dot, and the position moved by 2 dots. As a result, the number of dots in all the blocks is “2” at a position where the dot has moved one dot to the right and moved two dots downward. Therefore, this position is set as a correct separation position.

その後、同期符号検出部24、識別符号検出部30、X座標符号検出部40、Y座標符号検出部45等が、各ブロック内のドット配置を参照することにより、同期符号、識別符号、X座標符号、Y座標符号を検出することになる。   Thereafter, the synchronization code detection unit 24, the identification code detection unit 30, the X coordinate code detection unit 40, the Y coordinate code detection unit 45, and the like refer to the dot arrangement in each block, so that the synchronization code, the identification code, the X coordinate The code and the Y coordinate code are detected.

ところが、この場合に、符号誤りが生ずることがある。
この符号誤りは、画像に汚れ等が発生した場合、余計なドットが加わった場合、CCDの性能によりドット画像が取り込めない場合等に発生する。本実施の形態では、ドット配置可能な領域に一定数のドットを配置する方法を用いていることから、ドット付加やドット落ちがあった場合、誤りであることが分かる。後述するフローチャートでも明らかになるが、ブロックを検出する際には全てのブロック内のドット数が期待する値にならなくてもブロックを決定するので、ブロック内のドット数に誤りが生じている場合があるのである。
However, in this case, a code error may occur.
This code error occurs when the image is smudged, when extra dots are added, or when the dot image cannot be captured due to the performance of the CCD. In the present embodiment, since a method of arranging a certain number of dots in a dot arrangementable area is used, it can be seen that an error occurs when there is a dot addition or a dot drop. As will be apparent from the flowchart below, when a block is detected, the block is determined even if the number of dots in all blocks does not reach the expected value, so there is an error in the number of dots in the block. There is.

図11に、このドット付加及びドット落ちの例を示す。
(a)は、ノイズによるドット付加の例であり、(b)は、白抜けによるドット落ちの例である。9C2方式を用いてドットを配置した場合、2つのドットが検出されるべきであるのに、(a)では3つのドットが検出され、(b)では1つのドットしか検出されないため、誤りであると分かる。
FIG. 11 shows an example of dot addition and dot dropping.
(A) is an example of dot addition due to noise, and (b) is an example of dot dropping due to white spots. When dots are arranged using the 9C2 method, two dots should be detected, but three dots are detected in (a), and only one dot is detected in (b), which is an error. I understand.

しかしながら、ドット付加とドット落ちが同時に発生すると、他の単位符号パターンへ誤ってしまうことがある。図12に、この場合の例を示す。
(a)では、ノイズによるドット付加と、白抜けによるドット落ちが同時に発生している。9C2方式を用いてドットを配置した場合、2つのドットが検出されるので、誤りだと分からず、(b)に示すように、別の単位符号パターンと誤認してしまう。
尚、本明細書では、図11のように、誤りであることが分かり単位符号パターンを特定できない誤りを「特定不能誤り」と称し、図12のように、誤りであることが分からず間違った単位符号パターンを特定してしまう誤りを「誤特定誤り」と称する。
尚、先に述べた第三のレイアウトに含まれる制御パターンのブロックは、単位符号パターンが配置されたブロックでないことが明らかなので、「特定不能誤り」と同等に取り扱うことができる。
However, if dot addition and dot drop occur at the same time, there is a possibility that another unit code pattern is mistaken. FIG. 12 shows an example of this case.
In (a), dot addition due to noise and dot dropping due to white spots occur simultaneously. When dots are arranged using the 9C2 method, two dots are detected, so that it is not known that the error is present, and it is mistaken for another unit code pattern as shown in FIG.
In this specification, as shown in FIG. 11, an error that is known to be an error and whose unit code pattern cannot be specified is referred to as an “unidentifiable error”. As shown in FIG. An error that specifies a unit code pattern is referred to as an “error specification error”.
Since the control pattern block included in the third layout described above is clearly not a block in which the unit code pattern is arranged, it can be handled in the same way as an “unspecified error”.

本実施の形態では、このような誤りが生じることを考慮し、次のような方法で符号を検出し復号を行う。先に述べたように、本実施の形態のレイアウトは、同じパターンの画像が周期的に配置されているのが特徴である。例えば、上記(1)のレイアウトでは、X座標を表す画像は、Y方向に周期的に配置されている。また、Y座標を表す画像は、X方向に周期的に配置されている。更に、識別情報を表す画像は、格子状に周期的に配置されている。本実施の形態では、この周期性を利用する。周期性のない画像では、1回の読み込み画像に多くの誤りが含まれていると、復号に失敗してしまう。一方、周期性のある画像では、1回の読み込み画像に誤りが含まれ復号ができない場合においても、複数回画像を読み込むことで正しい画像を推測することを可能にする。つまり、読み込んだ画像に誤りがあり、その結果、間違った符号が検出されても、正しく復号可能なロバスト性の高い方法を提供する。   In the present embodiment, in consideration of the occurrence of such an error, a code is detected and decoded by the following method. As described above, the layout of this embodiment is characterized in that images of the same pattern are periodically arranged. For example, in the layout (1) above, images representing the X coordinate are periodically arranged in the Y direction. In addition, images representing the Y coordinate are periodically arranged in the X direction. Furthermore, the images representing the identification information are periodically arranged in a grid pattern. In this embodiment, this periodicity is used. In an image having no periodicity, if many errors are included in one read image, decoding fails. On the other hand, in the case of an image having periodicity, even when an error is included in one read image and decoding cannot be performed, a correct image can be estimated by reading the image a plurality of times. That is, it provides a highly robust method that can be correctly decoded even if the read image has an error and, as a result, an incorrect code is detected.

図13に、ペンデバイスによる画像の読み込みを例示する。ペンデバイスは、図示するように、連続的に画像を読み込む。図では、連続的に撮像される範囲を円で示し、円を起点とする矢印の先に、各撮像範囲から読み込まれる画像を示している。そして、ペンデバイスは、読み込んだ各画像からドットを特定し、先に説明した方法により単位符号パターンを特定する。また、符号配列内の識別符号を表す要素を復号できる順に並べ替える。図では、最右列に、この並べ替え後の符号配列を示している。   FIG. 13 illustrates reading of an image by a pen device. The pen device continuously reads images as shown in the figure. In the figure, a continuously imaged range is indicated by a circle, and an image read from each imaging range is indicated at the tip of an arrow starting from the circle. Then, the pen device specifies a dot from each read image and specifies a unit code pattern by the method described above. Further, the elements representing the identification codes in the code array are rearranged in the order in which they can be decoded. In the figure, the rearranged code arrangement is shown in the rightmost column.

このように並べ替えられた符号配列には、上述したように、誤りが含まれる可能性がある。そこで、本実施の形態では、複数の符号配列を用いて正しい符号を検出する。
ここでは、符号の検出方法として次の2つを提案する。
第1の方法は、N回の画像読み込みで取得したN個の符号配列を用いるというものである。
ここで、Nは、予め設定した数値であるが、例えば、印刷装置や画像読取部の性能によるノイズや白抜けの頻度から決定するとよい。この方法では、N個の符号配列の要素ごとにパターン値のヒストグラムを生成する。そして、最も多いパターン値に対応する単位符号パターンを正しい単位符号パターンとして決定する。
図14に、このときの処理を例示する。図14では、識別符号のうち「I11」のパターン値のヒストグラムを示している。このヒストグラムでは、「I11」のパターン値として、「1」が6回、「2」が2回、「5」が1回現れたことを示している。
このように、ヒストグラムを作成し最も多く現れたパターンを候補として採用するために、「誤特定誤り」があっても、正しいパターンを推測することが可能である。このことから「誤特定誤り」に適した方法であるが、「特定不能誤り」に対しても有効である。
The code array rearranged in this way may contain an error as described above. Therefore, in the present embodiment, a correct code is detected using a plurality of code arrays.
Here, the following two methods are proposed as a code detection method.
The first method is to use N code arrays acquired by N times of image reading.
Here, N is a preset numerical value, and may be determined from, for example, the frequency of noise or white spots due to the performance of the printing apparatus or the image reading unit. In this method, a histogram of pattern values is generated for each element of N code arrays. Then, the unit code pattern corresponding to the largest number of pattern values is determined as the correct unit code pattern.
FIG. 14 illustrates the processing at this time. FIG. 14 shows a histogram of the pattern value “I11” of the identification codes. This histogram shows that “1” appears 6 times, “2” appears twice, and “5” appears once as a pattern value of “I11”.
In this way, since a histogram is created and the pattern that appears most frequently is adopted as a candidate, it is possible to guess a correct pattern even if there is an “error specific error”. This is a method suitable for “false specific error”, but is also effective for “unspecified error”.

第2の方法は、ペンデバイスの1回のストロークにおける画像読み込みで取得した符号配列を用いるというものである。
この方法の場合、ペンデバイスには、ペン先に接続された微小スイッチ(以下、「ペンスイッチ」という)と、筆記を行った場合にこのペンスイッチをONにする機構とを設ける。これにより、ストロークの始めから終わりまでの画像を一定時間間隔で読み込めるようにする。
図15に、この方法における処理を示す。
(a)は、1回のストロークを例示したものである。ここでは、平仮名の「あ」の第1画目を筆記する間、ペンスイッチがONになっていることから、これが1回のストロークで筆記された部分であると認識されている。
また、(b),(c)は、第1の方法と第2の方法をストローク上で比較して示したものである。このうち、(b)は、第1の方法について示したものであり、ストロークに関係なく、N個の画像からヒストグラムを生成する。これに対し、(c)は、第2の方法について示したものであり、1回のストロークの始めから終わりまでの画像からヒストグラムを生成する。
The second method is to use a code array acquired by reading an image in one stroke of the pen device.
In the case of this method, the pen device is provided with a minute switch (hereinafter referred to as “pen switch”) connected to the pen tip and a mechanism for turning on the pen switch when writing is performed. As a result, images from the beginning to the end of the stroke can be read at regular time intervals.
FIG. 15 shows processing in this method.
(A) illustrates one stroke. Here, since the pen switch is ON while writing the first picture of Hiragana “A”, it is recognized that this is the part written with one stroke.
Further, (b) and (c) show the first method and the second method in comparison on the stroke. Among these, (b) shows the first method, and a histogram is generated from N images regardless of the stroke. On the other hand, (c) shows the second method, and a histogram is generated from images from the beginning to the end of one stroke.

尚、第1の方法は、紙面上のある箇所をポイントする操作等、1回のストローク入力が比較的短いことが多い場合に適している。これに対し、第2の方法は、文字の筆記等、1回のストローク入力が比較的長いことが多い場合に適している。
また、ここでは、ペンスイッチがONになっている状態で取得した画像からヒストグラムを生成したが、ペンデバイスが特定の状態になっている間に取得した画像からヒストグラムを生成する構成として捉えてもよい。この場合、特定の状態は、ペンデバイスに設けられた他のスイッチを押下した電気的な状態や、ペンデバイスの傾き等の物理的な状態を含むものであってよい。
Note that the first method is suitable when a single stroke input is often relatively short, such as an operation of pointing a certain point on the paper. On the other hand, the second method is suitable when a single stroke input is often relatively long, such as writing a character.
In addition, here, the histogram is generated from the image acquired when the pen switch is ON. However, it may be understood that the histogram is generated from the image acquired while the pen device is in a specific state. Good. In this case, the specific state may include an electrical state in which another switch provided in the pen device is pressed, or a physical state such as a tilt of the pen device.

次いで、画像処理装置20の動作について更に詳しく説明する。尚、この動作の説明では、9C2方式の単位符号パターンが図4に示したレイアウトで配置されていることを前提とする。
まず、ブロック検出部23の動作について説明する。
図16は、ブロック検出部23の動作例を示したフローチャートである。
まず、ブロック検出部23は、ドット配列生成部22からドット配列を取得する(ステップ201)。このドット配列の大きさは、上述したように、(復号に必要なブロック数×ブロックの一辺のドット数+ブロックの一辺のドット数−1)である。本実施の形態では、1つの符号ブロック×1つの符号ブロックが復号に必要なので、復号に必要なブロック数は5×5であり、ブロックの一辺のドット数が3であるので、17×17のドット配列を取得する。
Next, the operation of the image processing apparatus 20 will be described in more detail. In the description of this operation, it is assumed that 9C2 unit code patterns are arranged in the layout shown in FIG.
First, the operation of the block detector 23 will be described.
FIG. 16 is a flowchart showing an operation example of the block detection unit 23.
First, the block detector 23 acquires a dot array from the dot array generator 22 (step 201). The size of this dot array is (number of blocks necessary for decoding × number of dots on one side of block + number of dots on one side of block−1) 2 as described above. In this embodiment, since one code block × one code block is necessary for decoding, the number of blocks necessary for decoding is 5 × 5, and the number of dots on one side of the block is 3, so that 17 × 17 Get the dot array.

次に、取得したドット配列に、ブロック区切りを重ね合わせる(ステップ202)。本実施の形態では、5×5のブロック区切りが用いられる。そして、カウンタI、Jに「0」を代入し、MaxBNにも「0」を代入する(ステップ203)。
ここで、I、Jは、ブロック区切りを初期位置から移動させたステップ数をカウントするものである。画像の1ラインごとにブロック区切りを移動させ、そのとき移動させたライン数をカウンタI、Jでカウントする。また、MaxBNは、ブロック内で検出されるドット数が「2」となるブロック数をブロック区切りを移動させながらカウントしていったときに、最大となるカウント値を記録するものである。
Next, a block break is superimposed on the acquired dot array (step 202). In this embodiment, a 5 × 5 block delimiter is used. Then, “0” is substituted into the counters I and J, and “0” is substituted into MaxBN (step 203).
Here, I and J count the number of steps in which the block break is moved from the initial position. The block break is moved for each line of the image, and the number of lines moved at that time is counted by counters I and J. MaxBN records the maximum count value when counting the number of blocks in which the number of dots detected in the block is “2” while moving the block delimiter.

次に、ブロック検出部23は、ブロック区切りをX方向にI、Y方向にJ移動させる(ステップ204)。初期状態においてI、Jは「0」であるので、ブロック区切りは移動しない。そして、ブロック区切りの各ブロックに含まれるドット数をカウントして、ドット数が「2」となるブロックの数をカウントする。カウントしたブロック数はIB[I,J]に格納する(ステップ205)。IB[I,J]のI、Jには、ブロック区切りの移動量を示すIとJの値がそれぞれ記録される。   Next, the block detector 23 moves the block delimiter I in the X direction and J in the Y direction (step 204). Since I and J are “0” in the initial state, the block break does not move. Then, the number of dots included in each block of the block delimiter is counted, and the number of blocks whose dot number is “2” is counted. The counted number of blocks is stored in IB [I, J] (step 205). In I and J of IB [I, J], values of I and J indicating the movement amount of the block break are recorded, respectively.

次に、ブロック検出部23は、IB[I,J]とMaxBNとを比較する(ステップ206)。MaxBNは初期値が「0」であるので、最初の比較では、IB[I,J]がMaxBNよりも大きくなる。この場合、MaxBNにIB[I,J]の値を代入すると共に、IにMXの値を、JにMYの値を代入する(ステップ207)。尚、IB[I,J]がMaxBN以下である場合は、MaxBN、MX、MYの値はそのままにしておく。   Next, the block detection unit 23 compares IB [I, J] with MaxBN (step 206). Since MaxBN has an initial value “0”, in the first comparison, IB [I, J] is larger than MaxBN. In this case, the value of IB [I, J] is substituted for MaxBN, the value of MX is substituted for I, and the value of MY is substituted for J (step 207). When IB [I, J] is MaxBN or less, the values of MaxBN, MX, and MY are left as they are.

その後、ブロック検出部23は、I=2であるかどうかを判定する(ステップ208)。
ここで、I=2でない場合には、Iに「1」を加算する(ステップ209)。そして、ステップ204、205の処理を繰り返し行い、IB[I,J]とMaxBNとを比較していく(ステップ206)。
IB[I,J]が前回までのIB[I,J]の最大値であるMaxBNよりも大きいと、MaxBNにIB[I,J]の値を代入し、そのときのIにMXの値を、JにMYの値を代入する(ステップ207)。また、MaxBNのほうがIB[I,J]よりも大きい場合には、I=2であるかどうかを判定する(ステップ208)。I=2となると、次にJ=2であるかどうかを判定する(ステップ210)。J=2でない場合には、Iに「0」を代入し、Jに「1」を加算する(ステップ211)。このような手順を繰り返し行い、(I,J)が(0,0)から(2,2)までで、IB[I,J]が最大のものを検出する。
Thereafter, the block detection unit 23 determines whether I = 2 (step 208).
If I = 2 is not satisfied, “1” is added to I (step 209). Then, the processing in steps 204 and 205 is repeated to compare IB [I, J] with MaxBN (step 206).
If IB [I, J] is larger than MaxBN, which is the maximum value of IB [I, J] up to the previous time, the value of IB [I, J] is assigned to MaxBN, and the value of MX is substituted for I at that time. , J is substituted for the value of MY (step 207). If MaxBN is larger than IB [I, J], it is determined whether I = 2 (step 208). When I = 2, it is next determined whether J = 2 or not (step 210). If J = 2 is not satisfied, “0” is substituted for I, and “1” is added to J (step 211). Such a procedure is repeated to detect a case where (I, J) is (0, 0) to (2, 2) and IB [I, J] is maximum.

I=2、J=2までの処理が終了すると、ブロック検出部23は、保存しているMaxBNと閾値TBとを比較する(ステップ212)。閾値TBは、ドット数が「2」のブロックの数が復号可能な程度のものかを判定するための閾値である。
ここで、MaxBNが閾値TBよりも大きい場合には、ブロック区切りをMX、MYの位置に固定し、その位置で各ブロックのパターン値を検出する。そして、検出したパターン値を、各ブロックを識別する変数X、Yと共に符号配列PA[X,Y]としてメモリに記録する(ステップ213)。尚、このとき、対応するパターン値に変換することができなければ、パターン値として用いられていない「99」を記録する。そして、ブロック検出部23は、MX、MYと、符号配列PA[X,Y]とを同期符号検出部24に出力する(ステップ214)。
一方、MaxBNが閾値TB以下である場合には、画像のノイズが大きく復号は不可能と判定し、復号不能を出力する(ステップ215)。
When the processing up to I = 2 and J = 2 is completed, the block detection unit 23 compares the stored MaxBN with the threshold value TB (step 212). The threshold value TB is a threshold value for determining whether the number of blocks having a dot number of “2” is such that decoding is possible.
Here, when MaxBN is larger than the threshold value TB, the block break is fixed at the positions MX and MY, and the pattern value of each block is detected at that position. Then, the detected pattern value is recorded in the memory as a code array PA [X, Y] together with variables X and Y for identifying each block (step 213). At this time, if the pattern value cannot be converted, “99” which is not used as a pattern value is recorded. Then, the block detection unit 23 outputs MX and MY and the code array PA [X, Y] to the synchronous code detection unit 24 (step 214).
On the other hand, if MaxBN is equal to or less than the threshold value TB, it is determined that decoding is impossible due to large noise in the image, and decoding is impossible (step 215).

次に、同期符号検出部24の動作について説明する。
図17は、同期符号検出部24の動作例を示したフローチャートである。
まず、同期符号検出部24は、ブロック検出部23からMX、MYと、符号配列PA[X,Y]とを取得する(ステップ251)。
次に、同期符号検出部24は、K、Lに「1」を代入する(ステップ252)。尚、KはX方向のブロック数を示すカウンタであり、LはY方向のブロック数を示すカウンタである。
Next, the operation of the synchronization code detection unit 24 will be described.
FIG. 17 is a flowchart showing an operation example of the synchronization code detection unit 24.
First, the synchronization code detection unit 24 acquires MX and MY and the code array PA [X, Y] from the block detection unit 23 (step 251).
Next, the synchronous code detection unit 24 substitutes “1” for K and L (step 252). K is a counter indicating the number of blocks in the X direction, and L is a counter indicating the number of blocks in the Y direction.

次に、同期符号検出部24は、PA[K,L]のパターン値が32かどうかを判定する(ステップ253)。
PA[K,L]のパターン値が32であれば、符号配列PA[X,Y]の回転は必要ないと判定し、同期符号のあるブロックのX座標SXにKを代入し、Y座標SYにLを代入する。また、ブロック区切りのX方向への移動量ShiftXにMXを代入し、Y方向への移動量ShiftYにMYを代入する(ステップ254)。
Next, the synchronization code detection unit 24 determines whether the pattern value of PA [K, L] is 32 (step 253).
If the pattern value of PA [K, L] is 32, it is determined that the rotation of the code array PA [X, Y] is not necessary, and K is substituted for the X coordinate SX of the block having the synchronization code, and the Y coordinate SY Substitute L for. Further, MX is substituted for the movement amount ShiftX in the X direction of the block delimiter, and MY is substituted for the movement amount ShiftY in the Y direction (step 254).

次に、同期符号検出部24は、PA[K,L]のパターン値が33かどうかを判定する(ステップ255)。
PA[K,L]のパターン値が33であれば、符号配列PA[X,Y]を左方向に90度回転させる(ステップ256)。図3に示すようにパターン値33の単位符号パターンは、パターン値32の単位符号パターンを右方向に90度回転させた画像であるので、逆方向に90度回転させて画像を正立させている。尚、このとき、符号配列PA[X,Y]内の全てのパターン値が、左方向に90度回転させた場合のパターン値に変換される。
また、この回転に伴って、同期符号のあるブロックのX座標SXにLを代入し、Y座標SYに6−Kを代入する。また、ブロック区切りのX方向への移動量ShiftXにMYを代入し、Y方向への移動量ShiftYに2−MXを代入する(ステップ257)。
Next, the synchronization code detection unit 24 determines whether the pattern value of PA [K, L] is 33 (step 255).
If the pattern value of PA [K, L] is 33, the code array PA [X, Y] is rotated 90 degrees to the left (step 256). As shown in FIG. 3, the unit code pattern of the pattern value 33 is an image obtained by rotating the unit code pattern of the pattern value 32 by 90 degrees in the right direction, so that the image is erected by rotating 90 degrees in the reverse direction. Yes. At this time, all pattern values in the code array PA [X, Y] are converted into pattern values when rotated 90 degrees to the left.
In accordance with this rotation, L is substituted for the X coordinate SX of the block having the synchronization code, and 6-K is substituted for the Y coordinate SY. Also, MY is substituted for the movement amount ShiftX in the X direction of the block delimiter, and 2-MX is substituted for the movement amount ShiftY in the Y direction (step 257).

次に、同期符号検出部24は、PA[K,L]のパターン値が34かどうかを判定する(ステップ258)。
PA[K,L]のパターン値が34であれば、符号配列PA[X,Y]を左方向に180度回転させる(ステップ259)。図3に示すようにパターン値34の単位符号パターンは、パターン値32の単位符号パターンを180度回転させた画像であるので、パターン値34の単位符号パターンを180度回転させて画像を正立させている。尚、このとき、符号配列PA[X,Y]内の全てのパターン値が、180度回転させた場合のパターン値に変換される。
また、この回転に伴って、同期符号のあるブロックのX座標SXに6−Kを代入し、Y座標SYに6−Lを代入する。また、ブロック区切りのX方向への移動量ShiftXに2−MXを代入し、Y方向への移動量ShiftYに2−MYを代入する(ステップ260)。
Next, the synchronization code detection unit 24 determines whether or not the pattern value of PA [K, L] is 34 (step 258).
If the pattern value of PA [K, L] is 34, the code array PA [X, Y] is rotated 180 degrees to the left (step 259). As shown in FIG. 3, since the unit code pattern of the pattern value 34 is an image obtained by rotating the unit code pattern of the pattern value 32 by 180 degrees, the unit code pattern of the pattern value 34 is rotated 180 degrees and the image is erected. I am letting. At this time, all the pattern values in the code array PA [X, Y] are converted into pattern values when rotated 180 degrees.
In accordance with this rotation, 6-K is substituted for the X coordinate SX of the block having the synchronization code, and 6-L is substituted for the Y coordinate SY. Further, 2-MX is substituted for the movement amount ShiftX in the X direction of the block delimiter, and 2-MY is substituted for the movement amount ShiftY in the Y direction (step 260).

次に、同期符号検出部24は、PA[K,L]のパターン値が35かどうかを判定する(ステップ261)。
PA[K,L]のパターン値が35であれば、符号配列PA[X,Y]を左方向に270度回転させる(ステップ262)。図3に示すようにパターン値35の単位符号パターンは、パターン値32の単位符号パターンを右に270度回転させた画像であるので、逆方向に270度回転させて画像を正立させている。尚、このとき、符号配列PA[X,Y]内の全てのパターン値が、左方向に270度回転させた場合のパターン値に変換される。
また、この回転に伴って、同期符号のあるブロックのX座標SXに6−Lを代入し、Y座標SYにKを代入する。また、ブロック区切りのX方向への移動量ShiftXに2−MYを代入し、Y方向への移動量ShiftYにMXを代入する(ステップ263)。
Next, the synchronization code detection unit 24 determines whether or not the pattern value of PA [K, L] is 35 (step 261).
If the pattern value of PA [K, L] is 35, the code array PA [X, Y] is rotated 270 degrees to the left (step 262). As shown in FIG. 3, since the unit code pattern of the pattern value 35 is an image obtained by rotating the unit code pattern of the pattern value 32 to the right by 270 degrees, the image is erected by rotating 270 degrees in the reverse direction. . At this time, all the pattern values in the code array PA [X, Y] are converted into pattern values when rotated 270 degrees in the left direction.
In accordance with this rotation, 6-L is substituted for the X coordinate SX of the block having the synchronization code, and K is substituted for the Y coordinate SY. Further, 2-MY is substituted for the movement amount ShiftX in the X direction of the block delimiter, and MX is substituted for the movement amount ShiftY in the Y direction (step 263).

そして、ステップ254、257、260、263で、SX、SY、ShiftX、ShiftYに値が代入された場合、同期符号検出部24は、これらの値を識別符号検出部30、X座標符号検出部40、Y座標符号検出部45に出力する(ステップ264)。
また、PA[K,L]がパターン値32〜35のいずれでもなければ、同期符号検出部24は、K=5であるかどうかを判定する(ステップ265)。K=5でない場合には、Kに「1」を加算し(ステップ266)、ステップ253に戻る。K=5であれば、L=5であるかどうかを判定する(ステップ267)。L=5でない場合には、Kに「1」を代入し、Lに「1」を加算し(ステップ268)、ステップ253に戻る。即ち、ステップ253〜264の処理を、パターン値32〜35のブロックを検出するまでK、Lの値を変更しながら繰り返し行う。また、K=5、L=5になっても、パターン値32〜35のブロックを検出することができなかった場合には、復号不能の判定信号を出力する(ステップ269)。
When the values are assigned to SX, SY, ShiftX, and ShiftY in steps 254, 257, 260, and 263, the synchronization code detection unit 24 assigns these values to the identification code detection unit 30 and the X coordinate code detection unit 40. , And output to the Y coordinate code detector 45 (step 264).
If PA [K, L] is not any of the pattern values 32-35, the synchronization code detector 24 determines whether K = 5 (step 265). If K = 5 is not satisfied, “1” is added to K (step 266), and the process returns to step 253. If K = 5, it is determined whether L = 5 (step 267). If L = 5 is not satisfied, “1” is substituted for K, “1” is added to L (step 268), and the process returns to step 253. That is, the processing of steps 253 to 264 is repeated while changing the values of K and L until a block having pattern values of 32 to 35 is detected. If a block having pattern values of 32 to 35 cannot be detected even when K = 5 and L = 5, an undecodable determination signal is output (step 269).

尚、ステップ253、255、258、261の処理は、同期符号検出部24による制御の下、回転判定部25が行うようにするとよい。また、ステップ254、256、257、259、260、262、263の処理は、同期符号検出部24による制御の下、符号配列回転部26が行うようにするとよい。   Note that the processing of steps 253, 255, 258, and 261 may be performed by the rotation determination unit 25 under the control of the synchronization code detection unit 24. Further, the processing of steps 254, 256, 257, 259, 260, 262, and 263 may be performed by the code array rotation unit 26 under the control of the synchronization code detection unit 24.

次に、識別符号検出部30の動作について説明する。この識別符号検出部30の動作としては、図14に示したN個の符号配列を用いる場合の動作と、図15(c)に示した1回のストロークで取得した符号配列を用いる場合の動作とがあるが、ここでは、前者を第1の動作例、後者を第2の動作例として説明する。
図18は、識別符号検出部30の第1の動作例を示したフローチャートである。
まず、識別符号検出部30は、ペンデバイスによる画像読み取り回数を示すカウンタTに「1」を代入し、判定配列IA[X,Y,P]の全ての要素を「0」で初期化する(ステップ301)。
次に、識別符号検出部30は、同期符号検出部24から符号配列PA[X,Y]、SX、SYを取得する(ステップ302)。そして、符号ブロックにおける各ブロックを識別するためのカウンタIX、IYに「1」を代入する(ステップ303)。ここで、IXは、X方向のブロック数を示すカウンタであり、IYは、Y方向のブロック数を示すカウンタである。
Next, the operation of the identification code detection unit 30 will be described. As the operation of the identification code detection unit 30, the operation when using the N code arrays shown in FIG. 14 and the operation when using the code array acquired by one stroke shown in FIG. 15C. However, here, the former will be described as a first operation example, and the latter will be described as a second operation example.
FIG. 18 is a flowchart illustrating a first operation example of the identification code detection unit 30.
First, the identification code detection unit 30 assigns “1” to the counter T indicating the number of times of image reading by the pen device, and initializes all elements of the determination array IA [X, Y, P] with “0” ( Step 301).
Next, the identification code detection unit 30 acquires the code arrays PA [X, Y], SX, and SY from the synchronization code detection unit 24 (step 302). Then, “1” is substituted into counters IX and IY for identifying each block in the code block (step 303). Here, IX is a counter indicating the number of blocks in the X direction, and IY is a counter indicating the number of blocks in the Y direction.

また、識別符号検出部30は、IY−SYが「5」で割り切れるかどうかを判定する(ステップ304)。即ち、IYで特定されるブロックに同期符号が配置されているかどうかを判定する。
ここで、IY−SYが「5」で割り切れた場合、つまり、このブロックに同期符号が配置されている場合は、識別符号を取り出す対象ではないため、IYに「1」を加算し(ステップ305)、ステップ304へ進む。
一方、IY−SYが「5」で割り切れなかった場合、つまり、このブロックに同期符号が配置されていない場合は、IX−SXが「5」で割り切れるかどうかを判定する(ステップ306)。即ち、IXで特定されるブロックに同期符号が配置されているかどうかを判定する。
The identification code detection unit 30 determines whether IY-SY is divisible by “5” (step 304). That is, it is determined whether or not the synchronization code is arranged in the block specified by IY.
Here, when IY-SY is divisible by “5”, that is, when a synchronous code is arranged in this block, since the identification code is not extracted, “1” is added to IY (step 305). ), Go to step 304.
On the other hand, if IY-SY is not divisible by “5”, that is, if no synchronization code is arranged in this block, it is determined whether IX-SX is divisible by “5” (step 306). That is, it is determined whether or not the synchronization code is arranged in the block specified by IX.

ここで、IX−SXが「5」で割り切れた場合、つまり、このブロックに同期符号が配置されている場合は、識別符号を取り出す対象ではないため、IXに「1」を加算し(ステップ307)、ステップ306へ進む。
一方、IX−SXが「5」で割り切れなかった場合、つまり、このブロックに同期符号が配置されていない場合、識別符号検出部30は、IA[(IX−SX)mod5,(IY−SY)mod5,PA[IX,IY]]に「1」を加算する(ステップ308)。
Here, when IX-SX is divisible by “5”, that is, when a synchronization code is arranged in this block, since the identification code is not extracted, “1” is added to IX (step 307). ), Go to Step 306.
On the other hand, when IX-SX is not divisible by “5”, that is, when no synchronization code is arranged in this block, the identification code detection unit 30 performs IA [(IX-SX) mod5, (IY-SY) “5” is added to mod5, PA [IX, IY]] (step 308).

そして、IX=5であるかどうかを判定する(ステップ309)。
ここで、IX=5でない場合には、IXに「1」を加算して(ステップ307)、ステップ306〜308の処理をIX=5となるまで繰り返し行う。また、IX=5となると、次に、IY=5であるかどうかを判定する(ステップ310)。IY=5でない場合には、IXに「1」を代入し(ステップ311)、IYに「1」を加算して(ステップ305)、ステップ304〜309の処理をIY=5となるまで繰り返し行う。また、IY=5となると、T=Nであるかどうかを判定する(ステップ312)。その結果、T=Nでない場合には、Tに「1」を加算して(ステップ313)、ステップ302〜311の処理をT=Nとなるまで繰り返し行う。一方、T=Nとなると、これまで求めたIA[X,Y,P]の最大値を求める処理に移る。
Then, it is determined whether or not IX = 5 (step 309).
If IX = 5 is not satisfied, “1” is added to IX (step 307), and the processing of steps 306 to 308 is repeated until IX = 5. When IX = 5, it is next determined whether IY = 5 (step 310). If IY = 5 is not satisfied, “1” is substituted for IX (step 311), “1” is added to IY (step 305), and the processing of steps 304 to 309 is repeated until IY = 5. . When IY = 5, it is determined whether T = N (step 312). As a result, if T = N is not satisfied, “1” is added to T (step 313), and the processing of steps 302 to 311 is repeated until T = N. On the other hand, when T = N, the process proceeds to a process for obtaining the maximum value of IA [X, Y, P] obtained so far.

まず、識別符号検出部30は、識別符号配列における各ブロックを識別するためのJX、JYに「1」を代入する(ステップ321)。
次に、識別符号検出部30は、ステップ308で生成した判定配列IA[JX,JY,P]を最大にするPの値を、識別符号配列EA[JX,JY]に格納する(ステップ322)。
そして、JX=4であるかどうかを判定する(ステップ323)。
ここで、JX=4でない場合には、JXに「1」を加算して(ステップ324)、ステップ322の処理をJX=4となるまで繰り返し行う。また、JX=4となると、次に、JY=4であるかどうかを判定する(ステップ325)。JY=4でない場合には、JXに「1」を代入し、JYに「1」を加算して(ステップ326)、ステップ322〜324の処理をJY=4となるまで繰り返し行う。また、JY=4となると、識別符号検出部30は、識別符号配列EA[JX,JY]を識別符号復元部31に出力する(ステップ327)。
First, the identification code detection unit 30 substitutes “1” into JX and JY for identifying each block in the identification code array (step 321).
Next, the identification code detection unit 30 stores the value of P that maximizes the determination array IA [JX, JY, P] generated in step 308 in the identification code array EA [JX, JY] (step 322). .
Then, it is determined whether JX = 4 (step 323).
If JX = 4 is not satisfied, “1” is added to JX (step 324), and the process of step 322 is repeated until JX = 4. When JX = 4, it is next determined whether JY = 4 (step 325). If JY = 4 is not satisfied, “1” is substituted for JX, “1” is added to JY (step 326), and the processing of steps 322 to 324 is repeated until JY = 4. When JY = 4, the identification code detection unit 30 outputs the identification code array EA [JX, JY] to the identification code restoration unit 31 (step 327).

図19は、識別符号検出部30の第2の動作例を示したフローチャートである。尚、この動作は、ペンデバイスにおけるペンスイッチがONになった場合に開始する。
まず、識別符号検出部30は、判定配列IA[X,Y,P]の全ての要素を「0」で初期化する(ステップ351)。
次に、識別符号検出部30は、同期符号検出部24から符号配列PA[X,Y]、SX、SYを取得する(ステップ352)。そして、符号ブロックにおける各ブロックを識別するためのカウンタIX、IYに「1」を代入する(ステップ353)。ここで、IXは、X方向のブロック数を示すカウンタであり、IYは、Y方向のブロック数を示すカウンタである。
FIG. 19 is a flowchart illustrating a second operation example of the identification code detection unit 30. This operation starts when the pen switch in the pen device is turned on.
First, the identification code detection unit 30 initializes all elements of the determination array IA [X, Y, P] with “0” (step 351).
Next, the identification code detection unit 30 acquires the code arrays PA [X, Y], SX, and SY from the synchronization code detection unit 24 (step 352). Then, “1” is substituted into counters IX and IY for identifying each block in the code block (step 353). Here, IX is a counter indicating the number of blocks in the X direction, and IY is a counter indicating the number of blocks in the Y direction.

また、識別符号検出部30は、IY−SYが「5」で割り切れるかどうかを判定する(ステップ354)。即ち、IYで特定されるブロックに同期符号が配置されているかどうかを判定する。
ここで、IY−SYが「5」で割り切れた場合、つまり、このブロックに同期符号が配置されている場合は、識別符号を取り出す対象ではないため、IYに「1」を加算し(ステップ355)、ステップ354へ進む。
一方、IY−SYが「5」で割り切れなかった場合、つまり、このブロックに同期符号が配置されていない場合は、IX−SXが「5」で割り切れるかどうかを判定する(ステップ356)。即ち、IXで特定されるブロックに同期符号が配置されているかどうかを判定する。
The identification code detection unit 30 determines whether IY-SY is divisible by “5” (step 354). That is, it is determined whether or not the synchronization code is arranged in the block specified by IY.
Here, when IY-SY is divisible by “5”, that is, when a synchronization code is arranged in this block, since the identification code is not extracted, “1” is added to IY (step 355). ), Go to Step 354.
On the other hand, if IY-SY is not divisible by “5”, that is, if no synchronization code is arranged in this block, it is determined whether IX-SX is divisible by “5” (step 356). That is, it is determined whether or not the synchronization code is arranged in the block specified by IX.

ここで、IX−SXが「5」で割り切れた場合、つまり、このブロックに同期符号が配置されている場合は、識別符号を取り出す対象ではないため、IXに「1」を加算し(ステップ357)、ステップ356へ進む。
一方、IX−SXが「5」で割り切れなかった場合、つまり、このブロックに同期符号が配置されていない場合、識別符号検出部30は、IA[(IX−SX)mod5,(IY−SY)mod5,PA[IX,IY]]に「1」を加算する(ステップ358)。
Here, when IX-SX is divisible by “5”, that is, when a synchronization code is arranged in this block, since the identification code is not extracted, “1” is added to IX (step 357). ), Go to Step 356.
On the other hand, when IX-SX is not divisible by “5”, that is, when no synchronization code is arranged in this block, the identification code detection unit 30 performs IA [(IX-SX) mod5, (IY-SY) “5” is added to mod5, PA [IX, IY]] (step 358).

そして、IX=5であるかどうかを判定する(ステップ359)。
ここで、IX=5でない場合には、IXに「1」を加算して(ステップ357)、ステップ356〜358の処理をIX=5となるまで繰り返し行う。また、IX=5となると、次に、IY=5であるかどうかを判定する(ステップ360)。IY=5でない場合には、IXに「1」を代入し(ステップ361)、IYに「1」を加算して(ステップ355)、ステップ354〜359の処理をIY=5となるまで繰り返し行う。また、IY=5となると、ペンスイッチがONであるかどうかを判定する(ステップ362)。その結果、ONである場合には、ステップ352〜361の処理をペンスイッチがOFFとなるまで繰り返し行う。一方、ペンスイッチがOFFとなると、これまで求めたIA[X,Y,P]の最大値を求める処理に移る。
Then, it is determined whether or not IX = 5 (step 359).
If IX = 5 is not satisfied, “1” is added to IX (step 357), and the processing of steps 356 to 358 is repeated until IX = 5. When IX = 5, it is next determined whether IY = 5 (step 360). If IY = 5 is not satisfied, “1” is substituted for IX (step 361), “1” is added to IY (step 355), and the processing of steps 354 to 359 is repeated until IY = 5. . When IY = 5, it is determined whether the pen switch is ON (step 362). As a result, if it is ON, the processing in steps 352 to 361 is repeated until the pen switch is turned OFF. On the other hand, when the pen switch is turned off, the process proceeds to a process for obtaining the maximum value of IA [X, Y, P] obtained so far.

まず、識別符号検出部30は、識別符号配列における各ブロックを識別するためのJX、JYに「1」を代入する(ステップ371)。
次に、識別符号検出部30は、ステップ358で生成した判定配列IA[JX,JY,P]を最大にするPの値を、識別符号配列EA[JX,JY]に格納する(ステップ372)。
そして、JX=4であるかどうかを判定する(ステップ373)。
ここで、JX=4でない場合には、JXに「1」を加算して(ステップ374)、ステップ372の処理をJX=4となるまで繰り返し行う。また、JX=4となると、次に、JY=4であるかどうかを判定する(ステップ375)。JY=4でない場合には、JXに「1」を代入し、JYに「1」を加算して(ステップ376)、ステップ372〜374の処理をJY=4となるまで繰り返し行う。また、JY=4となると、識別符号検出部30は、識別符号配列EA[JX,JY]を識別符号復元部31に出力する(ステップ377)。
First, the identification code detection unit 30 substitutes “1” into JX and JY for identifying each block in the identification code array (step 371).
Next, the identification code detection unit 30 stores the value of P that maximizes the determination array IA [JX, JY, P] generated in step 358 in the identification code array EA [JX, JY] (step 372). .
Then, it is determined whether JX = 4 (step 373).
If JX = 4 is not satisfied, “1” is added to JX (step 374), and the process of step 372 is repeated until JX = 4. When JX = 4, it is next determined whether JY = 4 (step 375). If JY = 4 is not satisfied, “1” is substituted for JX, “1” is added to JY (step 376), and the processes in steps 372 to 374 are repeated until JY = 4. When JY = 4, the identification code detection unit 30 outputs the identification code array EA [JX, JY] to the identification code restoration unit 31 (step 377).

次に、X座標符号検出部40の動作について説明する。
図20は、X座標符号検出部40の動作例を示したフローチャートである。
まず、X座標符号検出部40は、同期符号検出部24から符号配列PA[X,Y]、SX、SYを取得する(ステップ401)。
次に、X座標符号検出部40は、X座標符号配列EA[X,0]の全ての要素を「99」で初期化する(ステップ402)。尚、この「99」は、パターン値として用いられていない番号とする。そして、符号ブロックにおける各ブロックを識別するためのカウンタIX、IYに「1」を代入する。ここで、IXは、X方向のブロック数を示すカウンタであり、IYは、Y方向のブロック数を示すカウンタである。更に、X座標符号検出部40は、X座標符号配列における各要素を識別するためのカウンタKXにも「1」を代入する(ステップ403)。
Next, the operation of the X coordinate code detection unit 40 will be described.
FIG. 20 is a flowchart illustrating an operation example of the X coordinate code detection unit 40.
First, the X coordinate code detection unit 40 acquires the code arrays PA [X, Y], SX, and SY from the synchronization code detection unit 24 (step 401).
Next, the X coordinate code detection unit 40 initializes all elements of the X coordinate code array EA [X, 0] with “99” (step 402). The “99” is a number that is not used as a pattern value. Then, “1” is substituted into counters IX and IY for identifying each block in the code block. Here, IX is a counter indicating the number of blocks in the X direction, and IY is a counter indicating the number of blocks in the Y direction. Furthermore, the X coordinate code detection unit 40 substitutes “1” into a counter KX for identifying each element in the X coordinate code array (step 403).

また、X座標符号検出部40は、IY−SYが「5」で割り切れるかどうかを判定する(ステップ404)。即ち、IYで特定されるブロックに同期符号が配置されているかどうかを判定する。
ここで、IY−SYが「5」で割り切れなかった場合、つまり、このブロックに同期符号が配置されていない場合は、X座標符号を取り出す対象ではないため、IYに「1」を加算し(ステップ405)、ステップ404へ進む。
一方、IY−SYが「5」で割り切れた場合、つまり、このブロックに同期符号が配置されている場合、X座標符号検出部40は、IX−SXが「5」で割り切れるかどうかを判定する(ステップ406)。即ち、IXで特定されるブロックに同期符号が配置されているかどうかを判定する。
Further, the X coordinate code detection unit 40 determines whether IY-SY is divisible by “5” (step 404). That is, it is determined whether or not the synchronization code is arranged in the block specified by IY.
Here, if IY-SY is not divisible by “5”, that is, if no synchronization code is arranged in this block, the X coordinate code is not extracted, so “1” is added to IY ( Step 405), the process proceeds to Step 404.
On the other hand, when IY-SY is divisible by “5”, that is, when a synchronization code is arranged in this block, the X coordinate code detection unit 40 determines whether IX-SX is divisible by “5”. (Step 406). That is, it is determined whether or not the synchronization code is arranged in the block specified by IX.

ここで、IX−SXが「5」で割り切れた場合、つまり、このブロックに同期符号が配置されている場合は、X座標符号を取り出す対象ではないため、IXに「1」を加算し(ステップ407)、ステップ406へ進む。
一方、IX−SXが「5」で割り切れなかった場合、つまり、このブロックに同期符号が配置されていない場合、X座標符号検出部40は、EA[KX,0]にPA[IX,IY]を代入する(ステップ408)。
Here, when IX-SX is divisible by “5”, that is, when a synchronous code is arranged in this block, since the X coordinate code is not extracted, “1” is added to IX (Step 1 407), go to step 406.
On the other hand, when IX-SX is not divisible by “5”, that is, when no synchronization code is arranged in this block, the X coordinate code detection unit 40 sets PA [IX, IY] to EA [KX, 0]. Is substituted (step 408).

そして、IX=5であるかどうかを判定する(ステップ409)。
ここで、IX=5でない場合には、KXに「1」を加算し(ステップ410)、IXに「1」を加算して(ステップ407)、ステップ406〜408の処理をIX=5となるまで繰り返し行う。また、IX=5となると、次に、IY=5であるかどうかを判定する(ステップ411)。IY=5でない場合には、IX、KXに「1」を代入し(ステップ412)、IYに「1」を加算して(ステップ405)、ステップ404〜410の処理をIY=5となるまで繰り返し行う。また、IY=5となると、X座標符号検出部40は、X座標符号配列EA[X,0]をX座標符号復号部42に出力する(ステップ413)。
尚、ここでは、X座標符号検出部40の動作のみ説明したが、Y座標符号検出部45も同様の動作を行う。
以上により、本実施の形態における画像処理装置20の詳細な動作説明を終了する。
Then, it is determined whether or not IX = 5 (step 409).
If IX = 5 is not satisfied, “1” is added to KX (step 410), “1” is added to IX (step 407), and the processing of steps 406 to 408 becomes IX = 5. Repeat until When IX = 5, it is next determined whether IY = 5 (step 411). If IY = 5 is not satisfied, “1” is substituted into IX and KX (step 412), “1” is added to IY (step 405), and the processing of steps 404 to 410 is performed until IY = 5. Repeat. When IY = 5, the X coordinate code detection unit 40 outputs the X coordinate code array EA [X, 0] to the X coordinate code decoding unit 42 (step 413).
Although only the operation of the X coordinate code detection unit 40 has been described here, the Y coordinate code detection unit 45 performs the same operation.
Thus, the detailed operation description of the image processing apparatus 20 in the present embodiment is finished.

次に、本実施の形態における画像処理装置20の具体的なハードウェア構成について説明する。
まず、画像処理装置20を実現するペンデバイス60について説明する。
図21は、ペンデバイス60の機構を示した図である。
図示するように、ペンデバイス60は、ペン全体の動作を制御する制御回路61を備える。また、制御回路61は、入力画像から検出した符号画像を処理する画像処理部61aと、そこでの処理結果から識別情報及び位置情報を抽出するデータ処理部61bとを含む。
そして、制御回路61には、ペンデバイス60による筆記動作をペンチップ69に加わる圧力によって検出する圧力センサ62が接続されている。また、媒体上に赤外光を照射する赤外LED63と、画像を入力する赤外CMOS64も接続されている。更に、識別情報及び位置情報を記憶するための情報メモリ65と、外部装置と通信するための通信回路66と、ペンを駆動するためのバッテリ67と、ペンの識別情報(ペンID)を記憶するペンIDメモリ68も接続されている。
Next, a specific hardware configuration of the image processing apparatus 20 in the present embodiment will be described.
First, the pen device 60 that implements the image processing apparatus 20 will be described.
FIG. 21 is a diagram illustrating the mechanism of the pen device 60.
As illustrated, the pen device 60 includes a control circuit 61 that controls the operation of the entire pen. In addition, the control circuit 61 includes an image processing unit 61a that processes a code image detected from an input image, and a data processing unit 61b that extracts identification information and position information from the processing result.
The control circuit 61 is connected to a pressure sensor 62 that detects the writing operation by the pen device 60 by the pressure applied to the pen tip 69. Further, an infrared LED 63 that irradiates infrared light onto the medium and an infrared CMOS 64 that inputs an image are also connected. Further, an information memory 65 for storing identification information and position information, a communication circuit 66 for communicating with an external device, a battery 67 for driving the pen, and pen identification information (pen ID) are stored. A pen ID memory 68 is also connected.

尚、図9に示した画像読取部21の画像を読み取る機能は、例えば、図21の赤外CMOS64にて実現される。また、画像読取部21のうちノイズを除去したりドットを検出したりする機能や、ドット配列生成部22は、例えば、図21の画像処理部61aにて実現される。更に、図9に示したブロック検出部23、同期符号検出部24、回転判定部25、符号配列回転部26、識別符号検出部30、識別符号復元部31、識別符号復号部32、識別符号誤り検出部33、識別符号誤り訂正部34、X座標符号検出部40、X座標符号復号部42、X座標符号誤り検出部43、X座標符号誤り訂正部44、Y座標符号検出部45、Y座標符号復号部47、Y座標符号誤り検出部48、Y座標符号誤り訂正部49、情報出力部50は、例えば、図21のデータ処理部61bにて実現される。   The function of reading the image of the image reading unit 21 shown in FIG. 9 is realized by, for example, the infrared CMOS 64 of FIG. Further, the function of removing noise or detecting dots in the image reading unit 21 and the dot array generation unit 22 are realized by, for example, the image processing unit 61a in FIG. Furthermore, the block detection unit 23, the synchronization code detection unit 24, the rotation determination unit 25, the code array rotation unit 26, the identification code detection unit 30, the identification code restoration unit 31, the identification code decoding unit 32, and the identification code error illustrated in FIG. Detection unit 33, identification code error correction unit 34, X coordinate code detection unit 40, X coordinate code decoding unit 42, X coordinate code error detection unit 43, X coordinate code error correction unit 44, Y coordinate code detection unit 45, Y coordinate The code decoding unit 47, the Y coordinate code error detection unit 48, the Y coordinate code error correction unit 49, and the information output unit 50 are realized by, for example, the data processing unit 61b in FIG.

また、図21の画像処理部61a又はデータ処理部61bにて実現される処理は、例えば、汎用のコンピュータで実現してもよい。そこで、かかる処理をコンピュータ90で実現するものとし、コンピュータ90のハードウェア構成について説明する。
図22は、コンピュータ90のハードウェア構成を示した図である。
図示するように、コンピュータ90は、演算手段であるCPU(Central Processing Unit)91と、記憶手段であるメインメモリ92及び磁気ディスク装置(HDD:Hard Disk Drive)93とを備える。ここで、CPU91は、OS(Operating System)やアプリケーション等の各種ソフトウェアを実行し、上述した各機能を実現する。また、メインメモリ92は、各種ソフトウェアやその実行に用いるデータ等を記憶する記憶領域であり、磁気ディスク装置93は、各種ソフトウェアに対する入力データや各種ソフトウェアからの出力データ等を記憶する記憶領域である。
更に、コンピュータ90は、外部との通信を行うための通信I/F94と、ビデオメモリやディスプレイ等からなる表示機構95と、キーボードやマウス等の入力デバイス96とを備える。
Further, the processing realized by the image processing unit 61a or the data processing unit 61b in FIG. 21 may be realized by, for example, a general-purpose computer. Accordingly, assuming that such processing is realized by the computer 90, the hardware configuration of the computer 90 will be described.
FIG. 22 is a diagram illustrating a hardware configuration of the computer 90.
As shown in the figure, the computer 90 includes a CPU (Central Processing Unit) 91 as a calculation means, a main memory 92 as a storage means, and a magnetic disk device (HDD: Hard Disk Drive) 93. Here, the CPU 91 executes various types of software such as an OS (Operating System) and applications to realize the above-described functions. The main memory 92 is a storage area for storing various software and data used for execution thereof, and the magnetic disk device 93 is a storage area for storing input data for various software, output data from various software, and the like. .
Further, the computer 90 includes a communication I / F 94 for performing communication with the outside, a display mechanism 95 including a video memory and a display, and an input device 96 such as a keyboard and a mouse.

尚、本実施の形態を実現するプログラムは、通信手段により提供することはもちろん、CD−ROM等の記録媒体に格納して提供することも可能である。   The program for realizing the present embodiment can be provided not only by communication means but also by storing it in a recording medium such as a CD-ROM.

9Cn方式における単位符号パターンの一例を示した図である。It is the figure which showed an example of the unit code pattern in 9Cn system. 9Cn方式における単位符号パターンの他の例を示した図である。It is the figure which showed the other example of the unit code pattern in 9Cn system. 9Cn方式における同期パターンの例を示した図である。It is the figure which showed the example of the synchronous pattern in 9Cn system. 符号ブロックの基本的なレイアウトの例を示した図である。It is the figure which showed the example of the basic layout of a code block. 符号ブロックのレイアウトの第1の例を示した図である。It is the figure which showed the 1st example of the layout of a code block. 符号ブロックのレイアウトの第2の例を示した図である。It is the figure which showed the 2nd example of the layout of a code block. 符号ブロックのレイアウトの第3の例を示した図である。It is the figure which showed the 3rd example of the layout of a code block. 本実施の形態における画像生成装置の機能構成を示したブロック図である。It is the block diagram which showed the function structure of the image generation apparatus in this Embodiment. 本実施の形態における画像処理装置の機能構成を示したブロック図である。It is the block diagram which showed the function structure of the image processing apparatus in this Embodiment. ドット配列上でブロックを検出する際の処理を説明するための図である。It is a figure for demonstrating the process at the time of detecting a block on a dot arrangement | sequence. 特定不能誤りについて説明するための図である。It is a figure for demonstrating an unspecified error. 誤特定誤りについて説明するための図である。It is a figure for demonstrating a misidentification error. 本実施の形態におけるペンデバイスによる画像読み取りについて説明するための図である。It is a figure for demonstrating the image reading by the pen device in this Embodiment. N個の符号配列を用いて符号を検出する方法について説明するための図である。It is a figure for demonstrating the method to detect a code | symbol using N code arrangement | sequences. 1回のストロークで得られる符号配列を用いて符号を検出する方法について説明するための図である。It is a figure for demonstrating the method to detect a code | symbol using the code | symbol arrangement | sequence obtained by one stroke. 本実施の形態におけるブロック検出部の動作例を示したフローチャートである。It is the flowchart which showed the operation example of the block detection part in this Embodiment. 本実施の形態における同期符号検出部の動作例を示したフローチャートである。It is the flowchart which showed the operation example of the synchronous code detection part in this Embodiment. 本実施の形態における識別符号検出部の第1の動作例を示したフローチャートである。It is the flowchart which showed the 1st operation example of the identification code | symbol detection part in this Embodiment. 本実施の形態における識別符号検出部の第2の動作例を示したフローチャートである。It is the flowchart which showed the 2nd operation example of the identification code detection part in this Embodiment. 本実施の形態におけるX座標符号検出部の動作例を示したフローチャートである。It is the flowchart which showed the operation example of the X coordinate code detection part in this Embodiment. 本実施の形態における画像処理装置を実現可能なペンデバイスの機構を示した図である。It is the figure which showed the mechanism of the pen device which can implement | achieve the image processing apparatus in this Embodiment. 本実施の形態を適用可能なコンピュータのハードウェア構成図である。It is a hardware block diagram of the computer which can apply this Embodiment.

符号の説明Explanation of symbols

10…画像生成装置、20…画像処理装置、21…画像読取部、22…ドット配列生成部、23…ブロック検出部、24…同期符号検出部、25…回転判定部、26…符号配列回転部、30…識別符号検出部、31…識別符号復元部、32…識別符号復号部、33…識別符号誤り検出部、34…識別符号誤り訂正部、40…X座標符号検出部、42…X座標符号復号部、43…X座標符号誤り検出部、44…X座標符号誤り訂正部、45…Y座標符号検出部、47…Y座標符号復号部、48…Y座標符号誤り検出部、49…Y座標符号誤り訂正部、50…情報出力部 DESCRIPTION OF SYMBOLS 10 ... Image generation apparatus, 20 ... Image processing apparatus, 21 ... Image reading part, 22 ... Dot array generation part, 23 ... Block detection part, 24 ... Synchronous code detection part, 25 ... Rotation determination part, 26 ... Code arrangement rotation part , 30 ... identification code detection unit, 31 ... identification code restoration unit, 32 ... identification code decoding unit, 33 ... identification code error detection unit, 34 ... identification code error correction unit, 40 ... X coordinate code detection unit, 42 ... X coordinate Code decoding unit 43 ... X coordinate code error detection unit 44 ... X coordinate code error correction unit 45 ... Y coordinate code detection unit 47 ... Y coordinate code decoding unit 48 ... Y coordinate code error detection unit 49 ... Y Coordinate code error correction unit, 50... Information output unit

Claims (11)

ビット列を表す画像が繰り返し印刷された媒体から読み取られた当該画像を取得する取得手段と、
前記取得手段により順次取得された複数の前記画像がそれぞれ表す複数のビット列を検出する検出手段と、
前記検出手段により検出された前記複数のビット列を用いて、1つのビット列を決定する決定手段と
を備えたことを特徴とする画像処理装置。
Acquisition means for acquiring the image read from the medium on which the image representing the bit string is repeatedly printed;
Detecting means for detecting a plurality of bit strings respectively represented by the plurality of images sequentially acquired by the acquiring means;
An image processing apparatus comprising: a determining unit that determines one bit string using the plurality of bit strings detected by the detecting unit.
前記決定手段は、前記1つのビット列の特定の部分列を、前記複数のビット列における当該特定の部分列に対応する部分列を用いて決定することを特徴とする請求項1記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the determining unit determines a specific partial sequence of the one bit sequence using a partial sequence corresponding to the specific partial sequence in the plurality of bit sequences. 前記決定手段は、前記1つのビット列の特定の部分列を、前記複数のビット列における当該特定の部分列に対応する部分列のうち最も多く検出されたものに決定することを特徴とする請求項1記載の画像処理装置。   2. The determining unit determines a specific partial sequence of the one bit sequence to be the most frequently detected partial sequence corresponding to the specific partial sequence in the plurality of bit sequences. The image processing apparatus described. 前記取得手段により順次取得された前記複数の画像は、予め決められた数の画像であることを特徴とする請求項1記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the plurality of images sequentially acquired by the acquisition unit is a predetermined number of images. 前記取得手段により順次取得された前記複数の画像は、前記媒体から画像を読み取る読取装置が特定の状態になっている間に当該媒体から読み取られた画像であることを特徴とする請求項1記載の画像処理装置。   The plurality of images sequentially acquired by the acquisition unit are images read from the medium while a reading device that reads the image from the medium is in a specific state. Image processing apparatus. 前記1つのビット列は、前記媒体又は前記媒体に印刷された文書を識別する識別情報を表すビット列であることを特徴とする請求項1記載の画像処理装置。   The image processing apparatus according to claim 1, wherein the one bit string is a bit string representing identification information for identifying the medium or a document printed on the medium. コンピュータに、
ビット列を表す画像が繰り返し印刷された媒体から読み取られた当該画像を取得する機能と、
順次取得された複数の前記画像がそれぞれ表す複数のビット列を検出する機能と、
検出された前記複数のビット列を用いて、1つのビット列を決定する機能と
を実現させるためのプログラム。
On the computer,
A function of acquiring the image read from the medium on which the image representing the bit string is repeatedly printed;
A function of detecting a plurality of bit strings respectively represented by the plurality of sequentially acquired images;
A program for realizing a function of determining one bit string using the plurality of detected bit strings.
前記決定する機能では、前記1つのビット列の特定の部分列を、前記複数のビット列における当該特定の部分列に対応する部分列を用いて決定することを特徴とする請求項7記載のプログラム。   8. The program according to claim 7, wherein, in the determining function, a specific partial sequence of the one bit sequence is determined using a partial sequence corresponding to the specific partial sequence in the plurality of bit sequences. 前記決定する機能では、前記1つのビット列の特定の部分列を、前記複数のビット列における当該特定の部分列に対応する部分列のうち最も多く検出されたものに決定することを特徴とする請求項7記載のプログラム。   The determining function determines a specific partial sequence of the one bit sequence to be the most frequently detected partial sequence corresponding to the specific partial sequence in the plurality of bit sequences. 7. The program according to 7. 順次取得された前記複数の画像は、予め決められた数の画像であることを特徴とする請求項7記載のプログラム。   8. The program according to claim 7, wherein the plurality of images acquired sequentially is a predetermined number of images. 順次取得された前記複数の画像は、前記媒体から画像を読み取る読取装置が特定の状態になっている間に当該媒体から読み取られた画像であることを特徴とする請求項7記載のプログラム。   The program according to claim 7, wherein the plurality of images acquired sequentially are images read from the medium while a reading device that reads the image from the medium is in a specific state.
JP2007142549A 2007-05-29 2007-05-29 Image processing apparatus and program Active JP4973316B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2007142549A JP4973316B2 (en) 2007-05-29 2007-05-29 Image processing apparatus and program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2007142549A JP4973316B2 (en) 2007-05-29 2007-05-29 Image processing apparatus and program

Publications (2)

Publication Number Publication Date
JP2008299442A true JP2008299442A (en) 2008-12-11
JP4973316B2 JP4973316B2 (en) 2012-07-11

Family

ID=40172941

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2007142549A Active JP4973316B2 (en) 2007-05-29 2007-05-29 Image processing apparatus and program

Country Status (1)

Country Link
JP (1) JP4973316B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012063957A (en) * 2010-09-15 2012-03-29 Fuji Xerox Co Ltd Image processing device, identification device, electronic writing tool and program

Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002082763A (en) * 2001-08-02 2002-03-22 Sharp Corp Optical pen and pattern formation paper sheet for coordinate input system
JP2006243818A (en) * 2005-02-28 2006-09-14 Fuji Xerox Co Ltd Printed matter with position identification function, two-dimensional coordinate identification device, image formation device, and its method
JP2007041691A (en) * 2005-08-01 2007-02-15 Fuji Xerox Co Ltd Code pattern image generating device and method, code pattern image reading device and method, and code pattern image medium

Patent Citations (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002082763A (en) * 2001-08-02 2002-03-22 Sharp Corp Optical pen and pattern formation paper sheet for coordinate input system
JP2006243818A (en) * 2005-02-28 2006-09-14 Fuji Xerox Co Ltd Printed matter with position identification function, two-dimensional coordinate identification device, image formation device, and its method
JP2007041691A (en) * 2005-08-01 2007-02-15 Fuji Xerox Co Ltd Code pattern image generating device and method, code pattern image reading device and method, and code pattern image medium

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2012063957A (en) * 2010-09-15 2012-03-29 Fuji Xerox Co Ltd Image processing device, identification device, electronic writing tool and program

Also Published As

Publication number Publication date
JP4973316B2 (en) 2012-07-11

Similar Documents

Publication Publication Date Title
JP4207049B2 (en) Printed matter with identification function, image generation apparatus, image processing apparatus and method thereof
JP2007179111A (en) Code pattern, printed matter, image forming device, image processor, image forming method, and information specifying method
JP2006525593A (en) Method, apparatus, computer program and storage medium for position decoding This application is incorporated herein by reference in its entirety, Swedish Patent Application No. 0301248-1, filed April 29, 2003, and 2003 4 Claims the benefit of US Provisional Application No. 60 / 466,036, filed on May 29.
JP5971098B2 (en) Information processing apparatus and information processing program
US8019181B2 (en) Image generation apparatus, image processing apparatus, computer readable medium and computer data signal
JP4670740B2 (en) Image generating apparatus, image processing system, and program
JP5609469B2 (en) Image processing apparatus, identification apparatus, electronic writing instrument, and program
JP4967823B2 (en) Position detection apparatus and program
JP4985436B2 (en) Position detection apparatus and program
US8657205B2 (en) Image processing apparatus, identification apparatus, method for determining bit sequence and computer readable medium
JP4973316B2 (en) Image processing apparatus and program
JP4973317B2 (en) Image processing apparatus and program
JP5098441B2 (en) Image processing apparatus and program
JP5125547B2 (en) Image generating apparatus, image processing apparatus, program, and print medium
JP5125548B2 (en) Image processing apparatus and program
JP5115213B2 (en) Image generating apparatus, image processing apparatus, program, and print medium
JP2009181341A (en) Position detection device and program
JP2008301120A (en) Image processor, image generating apparatus and program
JP2009182823A (en) Image processor and program
JP2009176251A (en) Image processing device and program
JP5028955B2 (en) Image processing apparatus and program
JP4765894B2 (en) Image generating apparatus, information reading apparatus, and recording medium
JP4915211B2 (en) Image generating apparatus, print medium, and program
JP2008301128A (en) Image processor, image-generating apparatus and program
JP2009181346A (en) Image processor, pen device, and program

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20100423

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20110728

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20110816

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20111017

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20120313

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20120326

R150 Certificate of patent or registration of utility model

Ref document number: 4973316

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20150420

Year of fee payment: 3

S533 Written request for registration of change of name

Free format text: JAPANESE INTERMEDIATE CODE: R313533

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350