JP7102128B2 - Programs, image processing equipment, and image processing methods - Google Patents

Programs, image processing equipment, and image processing methods Download PDF

Info

Publication number
JP7102128B2
JP7102128B2 JP2017217748A JP2017217748A JP7102128B2 JP 7102128 B2 JP7102128 B2 JP 7102128B2 JP 2017217748 A JP2017217748 A JP 2017217748A JP 2017217748 A JP2017217748 A JP 2017217748A JP 7102128 B2 JP7102128 B2 JP 7102128B2
Authority
JP
Japan
Prior art keywords
data
region
image
embedding
embedded
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.)
Active
Application number
JP2017217748A
Other languages
Japanese (ja)
Other versions
JP2019091976A (en
Inventor
智博 鈴木
勇気 大曲
充 浦谷
洋行 酒井
祐樹 石田
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Canon Inc
Original Assignee
Canon Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Canon Inc filed Critical Canon Inc
Priority to JP2017217748A priority Critical patent/JP7102128B2/en
Publication of JP2019091976A publication Critical patent/JP2019091976A/en
Application granted granted Critical
Publication of JP7102128B2 publication Critical patent/JP7102128B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Description

本発明は、画像にデータを埋め込むためのプログラム、画像処理装置、および画像処理方法に関する。 The present invention relates to a program for embedding data in an image, an image processing apparatus, and an image processing method.

電子透かし技術と称し、印刷物に対して付加情報を視覚的に判別しづらいように多重化する技術が利用されている。以降、ステガノグラフィ、ウォーターマークなど、データに対して別の意味合いを持つデータを重畳させること、もしくはその技術分野を総称して「多重化」とも記載する。 A technique called digital watermarking technique, which multiplexes additional information on printed matter so that it is difficult to visually distinguish it, is used. Hereinafter, data having a different meaning, such as steganography and watermark, is superimposed on the data, or the technical fields thereof are collectively referred to as "multiplexing".

特許文献1には、画像に対して音声情報等を多重化することが記載されている。 Patent Document 1 describes multiplexing audio information and the like with respect to an image.

特開2003-174556号公報Japanese Unexamined Patent Publication No. 2003-174556

データの多重化およびそのデータの復号の方法として、画像に埋め込まれるデータに応じて該画像に変化を加え、該画像が印刷された印刷物を撮影した装置が、撮影された画像に基づき上記の変化を捉えることで、上記データを復号する方法がある。 As a method of multiplexing data and decoding the data, a device that changes the image according to the data embedded in the image and captures a printed matter on which the image is printed performs the above-mentioned change based on the captured image. There is a method of decoding the above data by capturing.

しかしながら、データが埋め込まれる画像において、データに変化を加えやすい領域(以降、得意領域とも記載する)、データに変化を加えにくい領域(以降、苦手領域とも記載する)が存在する。例えば、各画素値が0~255の範囲の値であり、多重化のために画素値を10加算するとする。この場合、画素値が246未満の画素では10加算することが可能であるが、画素値が246以上の画素の場合は、10加算されると0~255の範囲を超えてしまうため、正しく加算できない。このような適切に変化をつけにくい苦手領域に対してデータが多重化されたとしても、復号の際に、該データを発見できない場合や、データを誤判定する場合が起こり得る。 However, in the image in which the data is embedded, there are a region in which the data is easily changed (hereinafter, also referred to as a strong region) and a region in which the data is difficult to be changed (hereinafter, also referred to as a weak region). For example, it is assumed that each pixel value is a value in the range of 0 to 255, and 10 pixel values are added for multiplexing. In this case, it is possible to add 10 for pixels with a pixel value of less than 246, but for pixels with a pixel value of 246 or more, adding 10 will exceed the range of 0 to 255, so the addition will be correct. Can not. Even if the data is multiplexed in such a region where it is difficult to change appropriately, there may be a case where the data cannot be found or a case where the data is erroneously determined at the time of decoding.

本発明は、画像における適切な位置にデータを埋め込むことができる技術を提供することを目的とする。 An object of the present invention is to provide a technique capable of embedding data at an appropriate position in an image.

本発明のプログラムは、画像に含まれる画素の画素値に所定の変化を与える所定の埋め込み方法に従って、前記画像に対してデータを埋め込むためのプログラムであって、前記所定の埋め込み方法に対応する所定の解析方法に従って、前記画像に含まれる画素の画素値に基づく解析を行う解析手段と、前記画像において、前記所定の変化を与えることが可能な領域を少なくとも含む第1の領域が前記所定の変化を与えることが可能でない第2の領域よりも優先されて前記データが埋め込まれるように、前記画像における、前記解析手段による解析結果に基づく位置に、前記所定の埋め込み方法に従って前記データを埋め込む埋め込み手段と、前記第1の領域に前記所定の変化を与えることが可能でない領域が含まれる場合、前記第1の領域に関する情報として、前記所定の変化を与えることが可能でない領域の座標を記述する記述手段と、としてコンピュータを機能させ、前記第1の領域のうち、前記所定の変化を与えることが可能でない領域には前記データが埋め込まれないように制御されることを特徴とする。 The program of the present invention is a program for embedding data in the image according to a predetermined embedding method that gives a predetermined change to the pixel value of the pixels included in the image, and is a predetermined embedding method corresponding to the predetermined embedding method. An analysis means that performs analysis based on the pixel values of the pixels included in the image according to the analysis method of the above, and a first region including at least a region capable of giving the predetermined change in the image is the predetermined change. An embedding means for embedding the data at a position in the image based on the analysis result by the analysis means according to the predetermined embedding method so that the data is embedded in preference to a second region in which the data cannot be given. And, when the first region includes a region that cannot give the predetermined change, the description describing the coordinates of the region that cannot give the predetermined change as the information regarding the first region. As a means, the computer is operated as a means, and the data is controlled so as not to be embedded in the region of the first region where the predetermined change cannot be given.

本発明によれば、画像に多重化されたデータの復号をより確実に行えるように、画像における適切な位置にデータの多重化を行うことができる。 According to the present invention, the data can be multiplexed at an appropriate position in the image so that the data multiplexed on the image can be more reliably decoded.

画像処理システムの構成を示すブロック図である。It is a block diagram which shows the structure of an image processing system. 多重化処理に使用されるマスクを示す図である。It is a figure which shows the mask used for the multiplexing process. 多重化処理に使用されるマスクを説明するための図である。It is a figure for demonstrating the mask used for the multiplexing process. データが多重化される画像を示す図である。It is a figure which shows the image in which the data is multiplexed. データが多重化された画像の一例を示す図である。It is a figure which shows an example of the image in which data is multiplexed. データが多重化された画像の他の例を示す図である。It is a figure which shows another example of an image in which data is multiplexed. データが多重化された画像にFFTを適用した結果の一例を示す図である。It is a figure which shows an example of the result of applying FFT to an image in which data is multiplexed. データが多重化されていない画像にFFTを適用した結果の一例を示す図である。It is a figure which shows an example of the result of applying FFT to the image which data is not multiplexed. データが多重化された画像にFFTを適用した結果の別の例を示す図である。It is a figure which shows another example of the result of applying FFT to an image in which data is multiplexed. データが多重化された画像にFFTを適用した結果の別の例を示す図である。It is a figure which shows another example of the result of applying FFT to an image in which data is multiplexed. 埋め込みデータの開始位置を判定するためのパターンを示す図である。It is a figure which shows the pattern for determining the start position of the embedded data. 本実施形態におけるデータの埋め込み位置の決定処理を示すフローチャートである。It is a flowchart which shows the determination process of the embedding position of data in this embodiment. 画像に埋め込まれるデータのデータ構成の一例を示す図であるIt is a figure which shows an example of the data structure of the data embedded in an image. ファイルフォーマット部として埋め込まれる情報と、ファイルフォーマットの種類の関係を示す図である。It is a figure which shows the relationship between the information embedded as a file format part, and the type of a file format. 苦手領域の判定が行われた結果の一例を示す図である。It is a figure which shows an example of the result of having determined the weak area. 本実施形態の処理により決定された位置に多重化が行われた画像の一例を示す図である。It is a figure which shows an example of the image which was multiplexed at the position determined by the process of this embodiment. 非連続のブロックに埋め込みデータが分割されて埋め込まれた結果の一例を示す図である。It is a figure which shows an example of the result which the embedded data was divided and embedded in a discontinuous block. 埋め込みデータのデータ構成の一例を示す図である。It is a figure which shows an example of the data structure of the embedded data. 埋め込みデータが埋め込まれた領域の周期パターンの一例を示す図である。It is a figure which shows an example of the periodic pattern of the region where the embedded data is embedded. 苦手領域の判定が行われた結果の別の例を示す図である。It is a figure which shows another example of the result of having determined the weak area. 全てが得意領域となる正方形の領域の例を示す図である。It is a figure which shows the example of the square area which is all good areas. 埋め込みデータのデータ構成の別の例を示す図である。It is a figure which shows another example of the data structure of the embedded data.

以下、図面を参照して本発明に係る実施形態を詳細に説明する。尚、実施形態における画像処理装置は、付加情報を埋め込む多重化装置と、該付加情報を印刷物から読み取る分離装置がある。多重化装置として、プリンタエンジンへ出力すべき画像情報を作成するコンピュータ内のプリンタドライバソフト、もしくは、アプリケーションソフトとして内蔵する。しかしそれに限らず、複写機、ファクシミリ、プリンタ本体等にハードウェア、及びソフトウエアとして内蔵してもよい。分離装置として、カメラ付携帯電話、カメラ付スマートフォンやタブレットPCなどが挙げられる。以下、こうした撮像デバイスをカメラ付携帯端末と呼ぶ。もしくは、デジタルスチールカメラで撮影した画像をコンピュータ内のアプリケーションプログラムで付加情報を分離する一連の装置でもよい。 Hereinafter, embodiments according to the present invention will be described in detail with reference to the drawings. The image processing device according to the embodiment includes a multiplexing device for embedding additional information and a separation device for reading the additional information from printed matter. As a multiplexing device, it is built in as printer driver software or application software in a computer that creates image information to be output to the printer engine. However, the present invention is not limited to this, and may be incorporated as hardware or software in a copying machine, a facsimile, a printer main body, or the like. Examples of the separation device include a mobile phone with a camera, a smartphone with a camera, and a tablet PC. Hereinafter, such an imaging device will be referred to as a mobile terminal with a camera. Alternatively, it may be a series of devices for separating additional information from an image taken by a digital still camera by an application program in a computer.

(第1の実施形態)
図1は、第1の実施形態の画像処理システムの構成を示すブロック図である。
(First Embodiment)
FIG. 1 is a block diagram showing a configuration of an image processing system according to the first embodiment.

102は、多重化装置を示し、視覚的に判別しづらいように、画像情報中に付加情報を埋め込ませる装置である。多重化装置102は、例えばスマートフォン等のカメラ付携帯端末201に含まれる。100及び101はともにカメラ付携帯端末201が備える入力部を示し、100からは多階調の画像情報が、101からは、画像情報の中に埋め込むべき必要な付加情報が入力される。この付加情報は、入力部100にて入力される画像情報とは別の情報である。例えば、音声情報や動画情報、テキスト文書情報や、それらの情報を識別するための識別情報である。または、入力部100にて入力される画像に関する著作権、撮影日時、撮影場所、撮影者等の諸情報、また別の画像情報等であってもよい。 Reference numeral 102 denotes a multiplexing device, which is a device for embedding additional information in the image information so as to be difficult to visually discriminate. The multiplexing device 102 is included in a mobile terminal 201 with a camera such as a smartphone. Both 100 and 101 indicate an input unit included in the camera-equipped mobile terminal 201. From 100, multi-gradation image information is input, and from 101, necessary additional information to be embedded in the image information is input. This additional information is information different from the image information input by the input unit 100. For example, it is audio information, moving image information, text document information, and identification information for identifying such information. Alternatively, it may be copyright, shooting date and time, shooting location, various information such as the photographer, and other image information related to the image input by the input unit 100.

103はプリンタを示し、多重化装置で作成された情報をプリンタエンジンにて出力する。プリンタ103は、例えばインクジェットプリンタ、レーザープリンタ等、疑似階調処理を用いることにより階調表現を実現するプリンタである。 Reference numeral 103 denotes a printer, and the printer engine outputs the information created by the multiplexing device. The printer 103 is a printer that realizes gradation expression by using pseudo gradation processing such as an inkjet printer and a laser printer.

カメラ付携帯端末201は撮像センサ104を備え、撮像センサ104により、プリンタ103により印刷された印刷物を撮像する。そして、その撮像により得られた撮像画像が、カメラ付携帯端末201に含まれる分離装置105に入力される。そして、分離装置105が撮像画像を解析することによって、印刷物中に埋め込まれた付加情報を分離(抽出)し、出力部106に出力する。この出力部106は、取得した付加情報を出力するインターフェースである。例えば付加情報が音声情報である場合、カメラ付携帯端末201が備えるスピーカ210へ付加情報が出力され、音声が出力される。また付加情報が画像情報である場合、カメラ付携帯端末201が備えるディスプレイ211に付加情報が出力され、表示が行われる。また、出力部106は、外部デバイスへデータを出力してもよい。また、カメラ付携帯端末201に複数の撮像センサがある場合、1または複数の撮像センサにより印刷物が撮像されてもよい。 The mobile terminal 201 with a camera includes an image pickup sensor 104, and the image pickup sensor 104 captures an image of a printed matter printed by the printer 103. Then, the captured image obtained by the imaging is input to the separation device 105 included in the camera-equipped mobile terminal 201. Then, the separation device 105 analyzes the captured image to separate (extract) the additional information embedded in the printed matter and output it to the output unit 106. The output unit 106 is an interface that outputs the acquired additional information. For example, when the additional information is voice information, the additional information is output to the speaker 210 included in the camera-equipped mobile terminal 201, and the voice is output. When the additional information is image information, the additional information is output to the display 211 included in the camera-equipped mobile terminal 201 and displayed. Further, the output unit 106 may output data to an external device. Further, when the mobile terminal 201 with a camera has a plurality of image pickup sensors, the printed matter may be imaged by one or a plurality of image pickup sensors.

なお、多重化装置102としてのカメラ付携帯端末と、分離装置105としてのカメラ付携帯端末は、同一の端末であってもよいし、別の端末であってもよい。 The camera-equipped mobile terminal as the multiplexing device 102 and the camera-equipped mobile terminal as the separation device 105 may be the same terminal or different terminals.

図1(b)は、カメラ付携帯端末201のハードウェア構成図である。カメラ付携帯端末201は、一例として、インターフェース202、CPU203、ROM204、操作部205、RAM206、外部記憶装置207、通信部208、撮像部209を有する。さらに、カメラ付携帯端末201は、スピーカ210、ディスプレイ211を有する。なお、これらのブロックは、例えば内部バスを用いて相互に接続される。 FIG. 1B is a hardware configuration diagram of the camera-equipped mobile terminal 201. As an example, the mobile terminal 201 with a camera has an interface 202, a CPU 203, a ROM 204, an operation unit 205, a RAM 206, an external storage device 207, a communication unit 208, and an imaging unit 209. Further, the camera-equipped mobile terminal 201 has a speaker 210 and a display 211. Note that these blocks are connected to each other using, for example, an internal bus.

CPU203は、システム制御部であり、装置の全体を制御する。RAM206は、例えばRAM206と同様に、バックアップ電源を必要とするDRAM(Dynamic RAM)等で構成される。RAM206は、CPU203の主メモリとワークメモリとしても用いられる。ROM204は、CPU203が実行する制御プログラムやデータテーブル、OSプログラム等の固定データを格納する。例えば、Webにおいて各種のアプリケーションプログラム(以下、アプリケーションと呼ぶ)を提供するサーバからダウンロードされたアプリケーションが、ROM204に記憶されている。CPU203は、ROM204に記憶されているプログラムをRAM206において実行することで、上述した多重化装置102および分離装置105として動作する。また、CPU203は、上述した入力部100、101、出力部106としても動作する。例えばCPU203は、入力部100として、外部記憶装置207に記憶された画像情報を外部記憶装置207から入力する。またCPU203は、入力部101として、外部記憶装置207やRAM206から付加情報を入力する。またCPU203は、出力部106として、音声情報である付加情報をスピーカ210に出力して音声出力を行い、また画像情報である付加情報をディスプレイ211に出力して表示させる。また、付加情報が外部記憶装置207に記憶されている音声情報や画像情報の識別情報である場合、CPU203は、識別情報に従って外部記憶装置207から音声情報や画像情報を読み出し、スピーカ210またはディスプレイ211に出力する。 The CPU 203 is a system control unit and controls the entire device. The RAM 206 is composed of a DRAM (Dynamic RAM) or the like that requires a backup power supply, like the RAM 206, for example. The RAM 206 is also used as the main memory and the work memory of the CPU 203. The ROM 204 stores fixed data such as a control program, a data table, and an OS program executed by the CPU 203. For example, an application downloaded from a server that provides various application programs (hereinafter referred to as an application) on the Web is stored in the ROM 204. The CPU 203 operates as the multiplexing device 102 and the separating device 105 described above by executing the program stored in the ROM 204 in the RAM 206. The CPU 203 also operates as the input units 100 and 101 and the output unit 106 described above. For example, the CPU 203 inputs the image information stored in the external storage device 207 from the external storage device 207 as the input unit 100. Further, the CPU 203 inputs additional information from the external storage device 207 or the RAM 206 as the input unit 101. Further, the CPU 203 outputs the additional information which is the audio information to the speaker 210 to output the audio, and outputs the additional information which is the image information to the display 211 for display as the output unit 106. When the additional information is the identification information of the voice information or the image information stored in the external storage device 207, the CPU 203 reads the voice information or the image information from the external storage device 207 according to the identification information, and the speaker 210 or the display 211. Output to.

通信部208は、無線LAN、有線LAN等の通信により、外部の装置との通信を行うことができる。スピーカ210は音声を出力する。例えばカメラ付携帯端末201がスマートフォンの場合、スピーカ210は、通話相手からの音声や、音楽等の音声ファイル内の音声データ、各種の通知音などを出力する。ディスプレイ211は、上述した付加情報や、撮像部209により撮像された画像、外部記憶装置207から読み出された画像、各種のアイコンやメニューを表示する。操作部205は、ユーザが操作してカメラ付携帯端末201に指示を行うためのものであり、ボタン等を含み、またタッチパネルとしてディスプレイ211一体的に設けられてもよい。撮像部209はカメラであり、上述した撮像センサ104は撮像部209に含まれる。 The communication unit 208 can communicate with an external device by communicating with a wireless LAN, a wired LAN, or the like. The speaker 210 outputs audio. For example, when the mobile terminal 201 with a camera is a smartphone, the speaker 210 outputs voice from the other party, voice data in a voice file such as music, various notification sounds, and the like. The display 211 displays the above-mentioned additional information, an image captured by the imaging unit 209, an image read from the external storage device 207, and various icons and menus. The operation unit 205 is for the user to operate and give an instruction to the mobile terminal 201 with a camera, includes buttons and the like, and may be provided integrally with the display 211 as a touch panel. The image pickup unit 209 is a camera, and the above-mentioned image pickup sensor 104 is included in the image pickup unit 209.

なお、図1(b)に示すカメラ付携帯端末201は、多重化装置102と分離装置105の両方として機能可能な装置として説明したが、これに限らず、いずれか一方のみとして動作してもよい。例えば、多重化装置102として動作するためのアプリケーションと、分離装置105として動作するためのアプリケーションとが、Web上のサーバで個別に用意されていてもよい。そして、いずれか一方のみがカメラ付携帯端末201にダウンロードされてもよい。この場合、多重化装置102として動作する携帯端末とは別の携帯端末が分離装置105として動作する。 The camera-equipped mobile terminal 201 shown in FIG. 1B has been described as a device capable of functioning as both the multiplexing device 102 and the separating device 105, but the present invention is not limited to this, and the camera-equipped mobile terminal 201 may operate as only one of them. good. For example, an application for operating as the multiplexing device 102 and an application for operating as the separation device 105 may be individually prepared by a server on the Web. Then, only one of them may be downloaded to the camera-equipped mobile terminal 201. In this case, a mobile terminal different from the mobile terminal that operates as the multiplexing device 102 operates as the separating device 105.

次に、多重化装置を用いて、画像に対いて付加情報を多重化する手法について述べる。なお、以下で説明する多重化方法は一例であり、この方法に限られるわけではない。ここでの説明では、カメラ付携帯端末201を用いて画像に「hello」という情報を多重化する方法を説明する。 Next, a method of multiplexing additional information with respect to an image using a multiplexing device will be described. The multiplexing method described below is an example, and is not limited to this method. In the description here, a method of multiplexing the information "hello" in the image by using the mobile terminal 201 with a camera will be described.

まず、カメラ付携帯端末201のような情報処理装置では、バイナリデータを扱う。バイナリデータとは「0」もしくは「1」の情報であり、この「0」もしくは「1」の情報が連続でつながることで、特定のデータを示す。例えば文字の情報は、それぞれの文字に対応するコードがバイナリデータで定められている。どのバイナリデータに対してどの文字が対応しているかは「文字コード」と呼ばれるもので定義されている。文字コードの中の一つである「シフトJIS」を例にとると、「h」はバイナリデータの「01101000」に対応している。同様に「e」は「01100101」、「l」は「01101100」、「o」は「01101111」というバイナリデータに対応している。つまり「hello」という文字はバイナリデータで「0110100001100101011011000110110001101111」と表現できる。逆に「0110100001100101011011000110110001101111」というバイナリデータが取得できれば「hello」という文字に変換することができる。 First, an information processing device such as a mobile terminal 201 with a camera handles binary data. Binary data is information of "0" or "1", and specific data is indicated by connecting the information of "0" or "1" in succession. For example, for character information, the code corresponding to each character is defined as binary data. Which character corresponds to which binary data is defined by what is called a "character code". Taking "Shift JIS", which is one of the character codes, as an example, "h" corresponds to the binary data "01101000". Similarly, "e" corresponds to "01100101", "l" corresponds to "01101100", and "o" corresponds to binary data "01101111". That is, the character "hello" can be expressed as "0110100001100101011011000110110001101111" in binary data. On the contrary, if the binary data "0110100001100101011011000110110001101111" can be acquired, it can be converted into the character "hello".

つまり多重化装置102としてのCPU203は多重化処理として、分離装置105が「0」もしくは「1」を判定できるように、画像にデータを埋め込む。CPU203は、入力部101として、多重化されるデータ「hello」を入力しているが、実際に埋め込むデータは「0110100001100101011011000110110001101111」である。これら二つは同一の情報を示しているが、区別をするため「hello」を付加情報とし、埋め込み用に変換された「0110100001100101011011000110110001101111」を埋め込みデータと呼称する。 That is, the CPU 203 as the multiplexing device 102 embeds data in the image as the multiplexing process so that the separating device 105 can determine "0" or "1". The CPU 203 inputs the multiplexed data "hello" as the input unit 101, but the data to be actually embedded is "0110100001100101011011000110110001101111". Although these two show the same information, "hello" is used as additional information to distinguish them, and "0110100001100101011011000110110001101111" converted for embedding is referred to as embedding data.

次に、画像に対して埋め込みデータを多重化する方法について説明する。本実施例は「0」「1」を示すデータの埋め込みを説明するが、多重化方法を「0」「1」の埋め込みに限定しているわけではなく、エンコード側とデコード側でデータを一意に対応づけることができる埋め込み方であれば他の情報でもよい。また多重化される画像のサイズは縦幅640px、横幅480pxとして説明をする。 Next, a method of multiplexing embedded data with respect to an image will be described. Although this embodiment describes embedding of data indicating "0" and "1", the multiplexing method is not limited to embedding "0" and "1", and the data is unique on the encoding side and the decoding side. Other information may be used as long as it can be associated with. Further, the size of the image to be multiplexed will be described as having a vertical width of 640 px and a horizontal width of 480 px.

図2は、多重化処理に使用されるマスクを示す図である。ここで、「0」、「1」を生成するために図2(a)(b)に示すマスクは、8px×8pxで構成されたマスクである。画像に対してマスクの内容が加算されることで、画像内の8px×8pxの領域に対して周期性を持ったパターンを与えることができる。図3は、多重化処理に使用されるマスクを説明するための図であり、マスクによって画像にどのようなパターンを与えるかを視覚的に示す。図2のマスクにおける「30」の位置を黒、「0」の位置を灰色、「-30」の位置を白で表現しており、画像には図3のような斜め線が現れることとなる。 FIG. 2 is a diagram showing a mask used in the multiplexing process. Here, the mask shown in FIGS. 2A and 2B for generating "0" and "1" is a mask composed of 8px × 8px. By adding the contents of the mask to the image, it is possible to give a pattern having periodicity to the region of 8px × 8px in the image. FIG. 3 is a diagram for explaining a mask used in the multiplexing process, and visually shows what kind of pattern is given to the image by the mask. The position of "30" in the mask of FIG. 2 is represented by black, the position of "0" is represented by gray, and the position of "-30" is represented by white, and diagonal lines as shown in FIG. 3 appear in the image. ..

ここで、図2(a)のマスクと図2(b)のマスクを画像全体に対して交互に適応する疑似コードを下記に示す。 Here, a pseudo code for alternately applying the mask of FIG. 2 (a) and the mask of FIG. 2 (b) to the entire image is shown below.

Figure 0007102128000001
Figure 0007102128000001

本実施形態では、説明のため、3行目の画像データはグレー画像であり、その画素値にマスクにより変化が加えられる処理について説明する。ただし、マスクにより変化が加えられる色成分は、人間が視覚的に視認しにくいものであるのが好ましい。例えばRGBの成分を持つカラー画像において、マスクにより変更が加えられる8px×8pxの領域において赤色が支配的であれば、赤成分に対して変更が加えられてもよい。他にも、RGBをLab成分に変換して、人間が視認しにくいと言われているb成分について変更が加えられてもよい。また、YUVや、Labのabを組み合わせて使うなど、マスクにより変更が加えられる色成分には様々なものが考えられる。また、図2に示す8px×8pxのマスクの値は、内部の係数を総和すると0に近い値になるように設定されている。通常のプリンタによる印刷であれば、印刷物における8px×8pxの領域は、非常に小さいサイズである。そのため、この領域の内部で変化が加えられていても、変化される値の総和が0に近くなるようマスクが設定されていれば、その変化を人間が視認しにくいため、視覚的に判別しづらいように多重化を行うことができる。 In the present embodiment, for the sake of explanation, the image data in the third line is a gray image, and a process in which the pixel value is changed by a mask will be described. However, it is preferable that the color component that is changed by the mask is difficult for humans to visually recognize. For example, in a color image having an RGB component, if red is dominant in the 8px × 8px region to be changed by the mask, the red component may be changed. In addition, RGB may be converted into a Lab component, and changes may be made to the b component, which is said to be difficult for humans to see. Further, various color components that can be changed by the mask, such as using YUV or Lab ab in combination, can be considered. Further, the mask value of 8px × 8px shown in FIG. 2 is set so that the total of the internal coefficients is close to 0. In the case of printing by a normal printer, the area of 8px × 8px in the printed matter has a very small size. Therefore, even if a change is applied inside this region, if the mask is set so that the sum of the changed values is close to 0, it is difficult for humans to see the change, so it is visually discriminated. Multiplexing can be done so that it is difficult.

パターンをつけるためのマスクの値の加算はある画素に対して1回のみおこなっており、重複して値が加算されることはない。つまり、マスクのサイズである8×8のブロック単位ずつ処理がおこなわれている。 The mask value for adding a pattern is added only once for a certain pixel, and the values are not added twice. That is, processing is performed in block units of 8 × 8, which is the size of the mask.

図4は、データが多重化される画像を示す図であり、図5は、データが多重化された画像の一例を示す図である。図5に示す画像は、図4に示す画像に斜め線のパターンが入れられた画像となる。図5の画像には、「0」と「1」の情報が交互に埋め込まれている。つまり、図3(a)、(b)に示したパターンが8×8のブロック単位で交互に入れられるため、図5に示すパターンとなる。なお、図5では説明のために、視認しやすいグレー画像で説明しているが、本来であれば視覚的に認識しにくい色成分や模様、サイズなどを考慮した多重化処理を行う。 FIG. 4 is a diagram showing an image in which data is multiplexed, and FIG. 5 is a diagram showing an example of an image in which data is multiplexed. The image shown in FIG. 5 is an image in which a diagonal line pattern is added to the image shown in FIG. Information of "0" and "1" is alternately embedded in the image of FIG. That is, since the patterns shown in FIGS. 3A and 3B are alternately inserted in 8 × 8 block units, the pattern shown in FIG. 5 is obtained. In FIG. 5, for the sake of explanation, a gray image that is easy to see is used, but multiplexing processing is performed in consideration of color components, patterns, sizes, and the like that are normally difficult to visually recognize.

図6は、データが多重化された画像の他の例を示す図である。具体的には、「hello」に相当する埋め込みデータである「0110100001100101011011000110110001101111」が埋め込まれた画像を示す。この埋め込みデータは40ビットの情報であるため、40個の8×8ブロック(320×8画素)の領域への埋め込みで十分である。ただし本実施形態では、図6に示すように、「hello」に相当する埋め込みデータを繰り返し埋め込む。このように、繰り返して同じデータが埋め込まれることで、印刷物の傷や汚れなどによってパターンが消えてしまうことへの耐性を高め、また分離装置105による埋め込みデータのデコード時の探索を容易にすることができる。 FIG. 6 is a diagram showing another example of an image in which data is multiplexed. Specifically, it shows an image in which "0110100001100101011011000110110001101111", which is embedded data corresponding to "hello", is embedded. Since this embedded data is 40-bit information, it is sufficient to embed it in an area of 40 8 × 8 blocks (320 × 8 pixels). However, in the present embodiment, as shown in FIG. 6, embedded data corresponding to "hello" is repeatedly embedded. By repeatedly embedding the same data in this way, it is possible to increase the resistance to the pattern disappearing due to scratches or stains on the printed matter, and to facilitate the search when decoding the embedded data by the separator 105. Can be done.

また、データが多重化される画像のサイズが640×480画素であるとすると、総画素数は307200画素となる。そのため、「hello」を埋め込むのに必要な画素数は320×8であり、2560画素に相当する。つまり上記の例では、「hello」の埋め込みは、120回(307200÷2560=120)繰り返されている。また、同一の埋め込みデータが繰り返し埋め込まれる場合に、その埋め込みデータの先頭にデータの始まりを示す特定の情報が埋め込まれてもよい。そして、埋め込みデータのデコードの際には、その特定の情報により埋め込みデータ「hellо」が埋め込まれている位置を認識することができる。 Further, assuming that the size of the image in which the data is multiplexed is 640 × 480 pixels, the total number of pixels is 307,200 pixels. Therefore, the number of pixels required for embedding "hello" is 320 × 8, which corresponds to 2560 pixels. That is, in the above example, the embedding of "hello" is repeated 120 times (307200/2560 = 120). Further, when the same embedded data is repeatedly embedded, specific information indicating the start of the data may be embedded at the beginning of the embedded data. Then, when decoding the embedded data, the position where the embedded data "hellо" is embedded can be recognized from the specific information.

このように、本実施形態による多重化方法によれば、データが多重化された画像は周期的なパターンをもっている。多重化された画像における周期性を説明するために、以下、図7~図10を用いて、画像に対してFFT(Fast Fourier Transform)を適用した結果を示す。 As described above, according to the multiplexing method according to the present embodiment, the image in which the data is multiplexed has a periodic pattern. In order to explain the periodicity in the multiplexed image, the results of applying FFT (Fast Fourier Transform) to the image are shown below with reference to FIGS. 7 to 10.

図7は、データが多重化された画像にFFTを適用した結果の一例を示す図である。一方、図8は、データが多重化されていな画像にFFTを適用した結果の一例を示す図である。図7に示す結果は、図8と比べ、特定の位置にスペクトル(白い点)が出現していることがわかる。なお、図7および後述の図9、図10は、FFTによる画像のスペクトルと画像の中心を結んだ直線の方向に画像の変動(画素値の変化)があることを示している。また、画像の中心から外側のスペクトルほど高周波成分(出現する間隔が短い)であり、より白いほどスペクトルが強く、その特徴が画像内に強く現れていることを示す。 FIG. 7 is a diagram showing an example of the result of applying the FFT to the image in which the data is multiplexed. On the other hand, FIG. 8 is a diagram showing an example of the result of applying the FFT to the image in which the data is not multiplexed. The results shown in FIG. 7 show that the spectrum (white dots) appears at a specific position as compared with FIG. Note that FIG. 7 and FIGS. 9 and 10 described later show that there is an image variation (change in pixel value) in the direction of a straight line connecting the spectrum of the image and the center of the image by FFT. Further, the spectrum outside the center of the image has a high frequency component (the interval of appearance is short), and the whiter the spectrum, the stronger the spectrum, indicating that the feature appears strongly in the image.

図9、図10は、データが多重化された画像にFFTを適用した結果の別の例を示す図である。具体的には、図9は「0」のみが多重化された画像にFFTが適用された結果を示し、図10は「1」のみが多重化された画像にFFTが適用された結果を示す。図9、図10に示すように、埋め込まれるデータが「0」であるか「1」であるかに応じて、FFTが適用された結果においてスペクトルの出現の仕方が異なる。図9では、左上から中心を通って右下にかけて斜め45度でスペクトルが点在していることが分かる。つまり画像内を左上から右下の斜め45度の方向において、ある間隔で変動(画素値の変化)が発生していることを示している。「0」が繰り返し多重化された場合、左上の画素から右下の画素に進む際に、ある周期で画素値の変動が起きるようにマスクが作られている(図2(a))。逆に「0」の多重化において、右上から左下にかけての斜め45度へ進む際には画素値の変動が起きづらく、図9においても右上から左下斜め45度にはスペクトルは発生していない。 9 and 10 are diagrams showing another example of the result of applying the FFT to the image in which the data is multiplexed. Specifically, FIG. 9 shows the result of applying the FFT to the image in which only "0" is multiplexed, and FIG. 10 shows the result of applying the FFT to the image in which only "1" is multiplexed. .. As shown in FIGS. 9 and 10, the appearance of the spectrum differs depending on whether the embedded data is “0” or “1” in the result of applying the FFT. In FIG. 9, it can be seen that the spectra are scattered at an angle of 45 degrees from the upper left to the lower right through the center. That is, it shows that fluctuations (changes in pixel values) occur at certain intervals in the direction of an oblique 45 degrees from the upper left to the lower right in the image. When "0" is repeatedly multiplexed, a mask is created so that the pixel value fluctuates at a certain cycle when proceeding from the upper left pixel to the lower right pixel (FIG. 2A). On the contrary, in the multiplexing of "0", it is difficult for the pixel value to fluctuate when proceeding from the upper right to the lower left at an angle of 45 degrees, and in FIG. 9, the spectrum does not occur from the upper right to the lower left at an angle of 45 degrees.

一方、図10では、右上から中心を通って左下にかけて斜め45度でスペクトルが点在していることが分かる。つまり画像内を右上から左下の斜め45度に移動するときに、ある間隔で変動(画素値の変化)が発生していることを示している。「1」が繰り返し多重化された場合、右上の画素から左下の画素の方向に、ある周期で画素値の変動が起きるようにマスクが作られているためである(図2(b))。 On the other hand, in FIG. 10, it can be seen that the spectra are scattered at an angle of 45 degrees from the upper right to the lower left through the center. That is, it shows that fluctuations (changes in pixel values) occur at certain intervals when moving in the image from the upper right to the lower left at an angle of 45 degrees. This is because when "1" is repeatedly multiplexed, the mask is made so that the pixel value fluctuates in a certain cycle from the upper right pixel to the lower left pixel (FIG. 2B).

図9、図10に示すように、図3(a)(b)のような周期的な変動を持つマスクで画素値を変動させると、後から「0」か「1」かを判定できる性質を持たせられることがわかる。ただし、ここで「0」と「1」が混在する情報を埋め込む場合、図7に示したように、画像全体におけるFFTの結果からは、「0」または「1」がどのブロックで表現されているものなのかを判定することはできない。そのため、本実施形態でCPU203は、FFT解析のサイズを、多重化を行ったブロックと同じ8×8のサイズで行う。そしてCPU203は、各ブロックに対して「0」、「1」のどちらに対応するかを判定する。この方法により、CPU203は、複数の連続するブロックに対応する「0」と「1」が連続するバイナリデータを抽出することができる。 As shown in FIGS. 9 and 10, when the pixel value is changed with a mask having periodic fluctuations as shown in FIGS. 3 (a) and 3 (b), it is possible to determine later whether it is "0" or "1". It turns out that you can have. However, when embedding information in which "0" and "1" are mixed here, as shown in FIG. 7, "0" or "1" is represented by which block from the FFT result in the entire image. It is not possible to determine if it is present. Therefore, in the present embodiment, the CPU 203 performs the FFT analysis size in the same 8 × 8 size as the multiplexed block. Then, the CPU 203 determines whether each block corresponds to "0" or "1". By this method, the CPU 203 can extract binary data in which "0" and "1" correspond to a plurality of consecutive blocks.

なお、各ブロックが「0」、「1」のどちらに対応するか判定する方法はFFTに限らない。例えば、斜め方向のエッジ検出をおこなって、検出されたエッジが「0」に対応するエッジパターン、「1」に対応するエッジパターンのどちらに近いか判定する方法でもよい。他にも、ブロックマッチングを使って、判定対象のブロックが「0」に対応するブロック、「1」に対応するブロックのどちらに類似するか判定するなど、種々の判定方法を適用することができる。 The method of determining whether each block corresponds to "0" or "1" is not limited to FFT. For example, a method may be used in which edge detection in the diagonal direction is performed to determine whether the detected edge is closer to the edge pattern corresponding to “0” or the edge pattern corresponding to “1”. In addition, various determination methods can be applied, such as determining whether the block to be determined is similar to the block corresponding to "0" or the block corresponding to "1" by using block matching. ..

また、CPU203は、ノイズの影響等による誤判定を防ぐために、所定の閾値以上の情報量が得られない場合は判定をやり直す。また、元の画像に多重化する埋め込みデータによるパターンが含まれている場合、そのパターンにより埋め込みデータが判定され、結果として本来の埋め込みデータが適切に抽出されないことが考えられる。そのため、CPU203は、多重化する埋め込みデータによるパターンと類似するパターンを除去するためのプレフィルタを元の画像に用い、その後に埋め込みデータを多重化してもよい。 Further, in order to prevent erroneous determination due to the influence of noise or the like, the CPU 203 redoes the determination when the amount of information equal to or greater than a predetermined threshold value cannot be obtained. Further, when the original image contains a pattern of embedded data to be multiplexed, it is conceivable that the embedded data is determined by the pattern, and as a result, the original embedded data is not properly extracted. Therefore, the CPU 203 may use a pre-filter for removing a pattern similar to the pattern of the embedded data to be multiplexed in the original image, and then multiplex the embedded data.

また分離装置105等の埋め込みデータをデコードする装置により、各ブロックが「0」、「1」のどちらに対応するか判定する際は、画像のどの位置(ブロック)から埋め込みデータが始まるのかを特定する必要ある。その場合は、例えば、先述の「0」、「1」のパターンとは異なる「開始位置判定用のパターン」を多重化し、埋め込みデータの始まりを判定できるようにする。 Further, when determining whether each block corresponds to "0" or "1" by a device that decodes the embedded data such as the separation device 105, it is specified from which position (block) of the image the embedded data starts. Need to be done. In that case, for example, a "pattern for determining the start position" different from the patterns of "0" and "1" described above is multiplexed so that the start of the embedded data can be determined.

図11は、埋め込みデータの開始位置を判定するためのパターンを示す図である。図3に示したように、「0」、「1」に対応するパターンは、8×8画素のブロックにおける斜め方向のパターンであるのに対し、埋め込みデータの開始位置を判定するためのパターンは、ブロックの水平方向のパターンである。 FIG. 11 is a diagram showing a pattern for determining the start position of the embedded data. As shown in FIG. 3, the pattern corresponding to "0" and "1" is a pattern in the diagonal direction in the block of 8 × 8 pixels, whereas the pattern for determining the start position of the embedded data is , The horizontal pattern of blocks.

なお、カメラ付携帯端末201が撮像センサによって画像を取得し、データを複号する場合、種々の方向で印刷物が撮像される可能性がある。また、撮像の際のカメラ付携帯端末201と印刷物の間の距離も様々であることが考えられ、即ち、撮像画像における印刷物に対応する領域のサイズにもばらつきが生じることになる。そのため、「0」または「1」を示す、印刷時の8×8画素のブロックについても、撮像環境により、撮像画像におけるサイズが異なり、正しくデータを複号できない可能性がある。 When the mobile terminal 201 with a camera acquires an image by an image sensor and multiplexes the data, the printed matter may be imaged in various directions. Further, it is considered that the distance between the camera-equipped mobile terminal 201 and the printed matter at the time of imaging varies, that is, the size of the region corresponding to the printed matter in the captured image also varies. Therefore, even for a block of 8 × 8 pixels at the time of printing, which indicates “0” or “1”, the size of the captured image differs depending on the imaging environment, and there is a possibility that the data cannot be duplicated correctly.

そのため、カメラ付携帯端末201(分離装置105)は、撮像画像を回転、縮小、拡大を異なる回転角度、異なる変倍率で複数回行い、「0」と「1」の情報が最も強く出現する状態を探索することが考えられる。また、図3、図11に示したように、「0」、「1」のパターンと、埋め込みデータの開始位置の判定のためのパターンは、周期性の方向が異なることで区別が可能である。ただし、撮像時の印刷物に対するカメラ付携帯端末201の角度によっては、両者を区別できないことも考えられる。ただし、埋め込みデータの開始位置の判定のためのパターンに対応するブロックに比べて「0」、「1」に対応するブロックの数が圧倒的に多い。そのため、撮像画像が異なる回転角度により回転された場合に、例えば「0」、「1」と判定されたブロックの数が最も多い回転角度で回転された撮像画像から、埋め込みデータが抽出されてもよい。 Therefore, the camera-equipped mobile terminal 201 (separator 105) rotates, reduces, and magnifies the captured image a plurality of times at different rotation angles and different magnifications, and the information of "0" and "1" appears most strongly. It is conceivable to search for. Further, as shown in FIGS. 3 and 11, the patterns of "0" and "1" and the pattern for determining the start position of the embedded data can be distinguished by different directions of periodicity. .. However, it may not be possible to distinguish between the two depending on the angle of the camera-equipped mobile terminal 201 with respect to the printed matter at the time of imaging. However, the number of blocks corresponding to "0" and "1" is overwhelmingly larger than that of the blocks corresponding to the pattern for determining the start position of the embedded data. Therefore, even if the embedded data is extracted from the captured image rotated at the rotation angle with the largest number of blocks determined to be "0" or "1" when the captured image is rotated by different rotation angles, for example. good.

上記のように、撮像画像は角度、大きさの異なる複数のものが生成されるが、以下の記載における撮像画像は、正しい方向、正しい距離で撮像されたものであるとする。つまり、撮像センサで取得した撮像画像について回転や拡大、縮小などの事前処理が行われずとも、復号処理が行われるものとする。 As described above, a plurality of captured images having different angles and sizes are generated, but it is assumed that the captured images in the following description are captured in the correct direction and at the correct distance. That is, it is assumed that the decoding process is performed on the captured image acquired by the image pickup sensor without performing the pre-processing such as rotation, enlargement, and reduction.

次に、本実施形態における、画像における多重化対象の領域を決定する方法について説明する。上述のような多重化方法では、例えば図2のマスクにより元の画像の画素値に10を加算もしくは減算することで画素値に周期性を与え、「0」または「1」を表現していた。しかし、画像における画素値は有限値であり、通常0~255の範囲の情報が扱われている。ここで、10~245の画素値であれば、画素値に対する10の加算もしくは減算を正しく行えるが、それ以外の画素値であると、正しく情報を付与することができない。例えば、「0」に対して10の減算を行おうとした場合、0~255データ範囲外となるため、例えば「0」に変換されてしまう。つまり「-10」の画素値を与えることができない。また、1~9の画素値に対して10減算しようとして、例えば画素値「0」が与えられた場合、画素値を多少変動させることは可能ではあるが、想定されている「10」という差分を作ることができない。そのため、「0」、「1」のパターンが十分に表現されず、デコードの際の判定が困難になる、または正しく判定できなくなる可能性がある。 Next, a method of determining the region to be multiplexed in the image in the present embodiment will be described. In the multiplexing method as described above, for example, by adding or subtracting 10 to the pixel value of the original image by the mask of FIG. 2, the pixel value is given periodicity to express "0" or "1". .. However, the pixel value in the image is a finite value, and information in the range of 0 to 255 is usually handled. Here, if the pixel value is 10 to 245, 10 can be correctly added or subtracted from the pixel value, but if the pixel value is other than that, information cannot be correctly added. For example, if you try to subtract 10 from "0", it will be out of the data range of 0 to 255, so it will be converted to "0", for example. That is, it is not possible to give a pixel value of "-10". Further, when an attempt is made to subtract 10 from the pixel values of 1 to 9, for example, when the pixel value "0" is given, the pixel value can be slightly changed, but the expected difference of "10" is obtained. Can't make. Therefore, the patterns of "0" and "1" may not be sufficiently expressed, and the determination at the time of decoding may become difficult or may not be correctly determined.

以降、多重化が行われる画像において、例えば10~245の範囲外の画素値の画素が多く含まれる領域を、想定通りに埋め込みデータが付与できない可能性がある領域として苦手領域(不得意領域)と記述する。一方、多重化が行われる画像において、例えば10~245の範囲内の画素値の画素が多く含まれる領域を、想定通りに埋め込みデータが付与できない可能性が高い領域として得意領域と記述する。なお、1画素単体であっても苦手画素、得意画素ではなく、苦手領域、得意領域と記述することとする。 After that, in the image to be multiplexed, for example, a region containing many pixels having a pixel value outside the range of 10 to 245 is a region that is not good (a weak region) as an region where embedded data may not be added as expected. Describe as. On the other hand, in the image to be multiplexed, for example, a region containing many pixels having a pixel value in the range of 10 to 245 is described as a region in which it is highly likely that embedded data cannot be added as expected. It should be noted that even if only one pixel is used, it is described as a weak area and a good area, not a weak pixel and a good pixel.

なお、先述にあるように、同一の画像の異なる領域に対して、同一の埋め込みデータを繰り返し多重化することで、ある特定の部分(例えば苦手領域)で復号が失敗しても他の部分で補填するという方法がある。しかしながら、デコードを行う装置において画像のどこが苦手領域であるか認識できない場合、上記の多重化の繰り返し回数を多くすることでデータ復元を担保するしかない。ただ、繰り返し回数を増やしたとしても、それらに全て苦手領域が含まれる可能性もあり、十分な得意領域は存在していたにも関わらず、復号できない状態を作りかねない。 As described above, by repeatedly multiplexing the same embedded data for different regions of the same image, even if decoding fails in a specific portion (for example, a weak region), in another portion. There is a method of making up for it. However, when the decoding device cannot recognize which region of the image is weak, data restoration can only be ensured by increasing the number of repetitions of the above multiplexing. However, even if the number of repetitions is increased, there is a possibility that all of them include areas where they are not good at, and even though there are sufficient areas where they are good at, it may create a state in which decoding cannot be performed.

他の方法として、画像における苦手領域に適切な多重化を行えるように、画像内の画素値を変更する方法がある。例えば元画像の画素値を10~245に収まるように変換する(階調数を下げる)ことで、画素値に対する10の加算または減算を保障する方法もある。しかしながら、この方法は元画像のデータを多く変化されるため、画質劣化の要因となってしまう。 As another method, there is a method of changing the pixel value in the image so that appropriate multiplexing can be performed in the weak area in the image. For example, there is also a method of guaranteeing addition or subtraction of 10 to the pixel value by converting the pixel value of the original image so as to be within 10 to 245 (decreasing the number of gradations). However, since this method changes a lot of data of the original image, it causes deterioration of image quality.

そこで本実施形態では、カメラ付携帯端末201は、多重化装置102として埋め込みデータを画像に埋め込む場合に、画像を解析することで、デコードの際に埋め込みデータが適切に復号できる可能性が高い領域を自動的に決定する。図12は、本実施形態におけるデータの埋め込み位置の決定処理を示すフローチャートである。なお、多重化技術はデータを埋め込む方法とデータを復号する方法の2つで成立する技術であり、それぞれをエンコード、デコードとも記載することとする。また図12に示す各ステップは、多重化装置102として動作するカメラ付携帯端末201により実行される。具体的には、図12に示す各ステップの処理に対応するアプリケーション等のプログラムがROM204に格納されている。CPU203がそのプログラムをRAM206に読み出して実行することで、図12に示す処理が実現される。 Therefore, in the present embodiment, when the embedded data is embedded in the image as the multiplexing device 102, the camera-equipped mobile terminal 201 has a high possibility that the embedded data can be appropriately decoded at the time of decoding by analyzing the image. Is automatically determined. FIG. 12 is a flowchart showing a process of determining the data embedding position in the present embodiment. The multiplexing technique is a technique that is established by two methods, a method of embedding data and a method of decoding data, and each of them will be described as encoding and decoding. Each step shown in FIG. 12 is executed by the camera-equipped mobile terminal 201 that operates as the multiplexing device 102. Specifically, a program such as an application corresponding to the processing of each step shown in FIG. 12 is stored in the ROM 204. When the CPU 203 reads the program into the RAM 206 and executes it, the process shown in FIG. 12 is realized.

S1201でCPU203は、多重化が実行される画像を取得する。例えばCPU203は、ROM204に記憶されているOSの機能により、外部記憶装置207に記憶されている画像のサムネイル画像をディスプレイ211に表示する。そしてCPU203は、ユーザが操作部205を用いて指定したサムネイル画像に対応する画像を、多重化が実行される画像としてRAM206に読み出す。また、多重化が実行される画像は、アプリケーションにより管理されているURLを用いて、ネットワーク上のサーバから取得されてもよい。 In S1201, the CPU 203 acquires an image in which multiplexing is executed. For example, the CPU 203 displays a thumbnail image of an image stored in the external storage device 207 on the display 211 by the function of the OS stored in the ROM 204. Then, the CPU 203 reads the image corresponding to the thumbnail image specified by the user using the operation unit 205 into the RAM 206 as an image to be multiplexed. Further, the image to be multiplexed may be acquired from a server on the network by using the URL managed by the application.

S1202でCPU203は、S1201で取得された画像の画像データに対して埋め込むデータを取得する。例えばCPU203は、テキスト入力画面をディスプレイ211に表示させ、ユーザが操作部205を用いて入力したテキストを、埋め込みデータとして取得する。なお、先述の通り、実際に画像に埋め込まれるデータは「0」「1」で表現されるバイナリデータであるので、CPU203は、取得されたテキストを文字コードにバイナリデータに変換する。また、文字コードによってバイナリデータは異なってくるので、CPU203は、文字コードの指定がある場合はそれに従ったバイナリデータへと変換する。デコード側の装置は、このバイナリデータを印刷物の撮像画像から抽出し、文字コードに従ってバイナリデータをテキストに変換することで、埋め込まれた情報を復号することが可能である。 In S1202, the CPU 203 acquires data to be embedded in the image data of the image acquired in S1201. For example, the CPU 203 displays the text input screen on the display 211, and acquires the text input by the user using the operation unit 205 as embedded data. As described above, since the data actually embedded in the image is binary data represented by "0" and "1", the CPU 203 converts the acquired text into binary data into a character code. Further, since the binary data differs depending on the character code, the CPU 203 converts the character code into binary data according to the specified character code, if any. The device on the decoding side can decode the embedded information by extracting this binary data from the captured image of the printed matter and converting the binary data into text according to the character code.

上記の例では、テキストが画像に多重化される例について説明したが、これに限らず、音声情報や画像情報が多重化されてもよいし、また音声ファイルや画像ファイルの識別情報(ファイル名、ファイルパス、URL等)が多重化されてもよい。識別情報が多重化される場合、デコード側の装置は、その識別情報に従ってファイルを取得し、取得されたファイルにより音声の出力や画像の表示を行うことができる。 In the above example, the example in which the text is multiplexed into the image has been described, but the present invention is not limited to this, and the audio information and the image information may be multiplexed, and the identification information (file name) of the audio file and the image file may be multiplexed. , File path, URL, etc.) may be multiplexed. When the identification information is multiplexed, the decoding-side device can acquire a file according to the identification information, and can output audio and display an image based on the acquired file.

ただし、このように種々のファイルが多重化される場合、エンコード側の装置が、埋め込みデータがどのようなファイルフォーマットであるか認識する必要がある。デコード側の装置において、復号可能なファイルフォーマットが例えば「シフトJISの文字列」に限らず、音声データや、画像データも復号可能な場合、バイナリデータだけでは、ファイルの種類を判定できない場合もある。そのため多重化装置102として動作するカメラ付携帯端末201は、埋め込まれるデータがどのファイルフォーマットであるかを示す情報を、データの内容を示すバイナリデータとともに埋め込む。 However, when various files are multiplexed in this way, the device on the encoding side needs to recognize what kind of file format the embedded data is. In the device on the decoding side, if the file format that can be decoded is not limited to, for example, "Shift JIS character string", and audio data and image data can also be decoded, the file type may not be determined only by the binary data. .. Therefore, the camera-equipped mobile terminal 201 that operates as the multiplexing device 102 embeds information indicating which file format the embedded data is, together with binary data indicating the contents of the data.

図13は、画像に埋め込まれるデータのデータ構成を示す図である。図13に示すように、例えば40ビットの実データ部に加え、ファイルのフォーマットを示す4ビットのファイルフォーマット部についても多重化される。ファイルフォーマット部として埋め込まれる情報は、ファイルフォーマットの種類と対応付けられている。図14は、ファイルフォーマット部として埋め込まれる情報と、ファイルフォーマットの種類の関係を示す図である。図14に示すファイルフォーマットと番号を対応させたテーブルをエンコード側とデコード側の両方が参照することで、先述のファイルフォーマットの問題は解決できる。例えば、エンコード用の機能とデコード用の機能が同一のアプリケーションにより提供される場合、そのアプリケーションにおいて図14に示すテーブルが定義され、アプリケーションのインストールの際に、カメラ付携帯端末201に記憶される。またエンコード用のアプリケーションとデコード用のアプリケーションが個別に提供される場合、それぞれのアプリケーションにおいて同一のテーブルが定義されるようにアプリケーションが作成される。 FIG. 13 is a diagram showing a data structure of data embedded in an image. As shown in FIG. 13, for example, in addition to the 40-bit actual data unit, the 4-bit file format unit indicating the file format is also multiplexed. The information embedded as the file format part is associated with the type of file format. FIG. 14 is a diagram showing the relationship between the information embedded as the file format unit and the type of file format. The above-mentioned file format problem can be solved by both the encoding side and the decoding side referencing the table in which the file formats and numbers correspond to each other shown in FIG. For example, when the function for encoding and the function for decoding are provided by the same application, the table shown in FIG. 14 is defined in the application and stored in the camera-equipped mobile terminal 201 when the application is installed. When an application for encoding and an application for decoding are provided separately, the application is created so that the same table is defined in each application.

S1203でCPU203は、データを埋め込む対象となる画像における、苦手領域(不得意領域)を判定する。ここでは説明のため、グレースケールの画像に含まれる画素の画素値を10加算または減算することで周期的な変化を与えるものとする。 In S1203, the CPU 203 determines a weak area (weak area) in the image to be embedded with data. Here, for the sake of explanation, it is assumed that a periodic change is given by adding or subtracting 10 pixel values of pixels included in a grayscale image.

ここで、S1203における処理の詳細を説明する。まずCPU203は、データが埋め込まれる画像の画素値を全ての画素について検出し、10の加算および減算(画素値の変更処理)が可能か判定する。具体的には、各画素の画素値が10~245の間であるかを判定する。図15は、苦手領域の判定が行われた結果の一例を示す図である。図15では、画素値が10~245の間である画素(画素値の変更処理が可能な画素)を白、それ以外を黒で表現している。つまり、図15における白で表現されている領域が、データを想定通りに埋め込める領域(得意領域)となる。一方で、黒で表現されている領域が、データを想定通りに埋め込めない可能性がある領域(苦手領域)となる。なお、上記の例では画素ごとに判定を行っているが、複数画素で構成される領域毎に判定が行われてもよい。例えば8×8ブロック毎に解析をし、該ブロックの平均画素により得意領域か苦手領域を判定してもよい。ただし、8px×8pxの計64画素中32画素が「0」、32画素が「255」であった場合、平均値は127.5となり、本来は苦手領域にも関わらず得意領域と判定されかねない。その場合に備え、8px×8pxブロック内の分散値を計算し、分散値が低い(画素にばらつきがない)場合のみ得意領域と判定することが望ましい。このように、各画素、もしくは領域毎など、画素を解析した解析結果に基づいて得意領域、苦手領域が判定される。また上記の例では、画像を得意領域と苦手領域に二分しているが、得意領域、苦手領域、中間領域など、複数の段階を設けてよい。 Here, the details of the processing in S1203 will be described. First, the CPU 203 detects the pixel values of the image in which the data is embedded for all the pixels, and determines whether addition and subtraction of 10 (pixel value change processing) are possible. Specifically, it is determined whether the pixel value of each pixel is between 10 and 245. FIG. 15 is a diagram showing an example of the result of determining the weak region. In FIG. 15, pixels having a pixel value between 10 and 245 (pixels capable of changing the pixel value) are represented by white, and the others are represented by black. That is, the area represented by white in FIG. 15 is an area (specialty area) in which data can be embedded as expected. On the other hand, the area represented in black is an area (a weak area) in which data may not be embedded as expected. In the above example, the determination is performed for each pixel, but the determination may be performed for each region composed of a plurality of pixels. For example, analysis may be performed for each 8 × 8 block, and a strong region or a weak region may be determined based on the average pixel of the block. However, if 32 pixels out of a total of 64 pixels of 8px x 8px are "0" and 32 pixels are "255", the average value will be 127.5, and it may be judged as a good area even though it is originally a weak area. do not have. In preparation for such a case, it is desirable to calculate the dispersion value in the 8px × 8px block and determine that the region is good only when the dispersion value is low (there is no variation in pixels). In this way, the strong region and the weak region are determined based on the analysis result of analyzing the pixel, such as each pixel or each region. Further, in the above example, the image is divided into a strong region and a weak region, but a plurality of stages such as a strong region, a weak region, and an intermediate region may be provided.

また、本実施形態では画素の画素値に10の加算および減算が可能か判定されるが、得意領域、不得意領域の判定方法として種々のものを用いることができる。例えば、アプリケーションにおいて多重化処理に適さない色があらかじめテーブルで保持されており、データが埋め込まれる画像の各画素(もしくは各ブロック)と、先述のテーブルを比較することによって、得意領域、不得意領域が判定されてもよい。特に、プリンタによりJPEGやPNGなどの写真データが印刷される場合、RGBデータからCMYKデータへの変換が発生することが多い。この場合、画像に対して周期的に行われた変動がそのまま残っていることは少ない。また、カメラ付携帯端末201上で扱える0~255の値を持つ画像データと、プリンタの扱える色の特性(色空間)には違いがあることがある。その結果、カメラ付携帯端末201で画像の画素値に10の加算または減算を行っても、それがプリンタでは表現できない色空間であると、例えばプリンタ側での変動が5の加算または減算に縮小されるということもあり得る。そこで、デコードのための機能を備えるアプリケーションにおいて、プリンタの特性(例えばプリンタによる画像データ形式の変換により、データ埋め込みのための周期的変化がどの程度ずれるか、等)を示すテーブルが定義されてもよい。そしてカメラ付携帯端末201がデコードを行う際には、先述のテーブルを参照することで得意領域、苦手領域を判断するようにしてもよい。このテーブルは、カメラ付携帯端末201がプリンタと通信して取得してもよい。さらに、得意領域、不得意領域の判定は色に基づくものでなくとも、画像におけるある領域のパターンや周波数成分を解析することで、得意領域、不得意領域を判定してもよいし、また色や周波数の組み合わせによって判定してもよい。 Further, in the present embodiment, it is determined whether or not 10 can be added or subtracted from the pixel value of the pixel, but various methods can be used as the determination method of the strong region and the weak region. For example, in an application, colors that are not suitable for multiplexing processing are stored in a table in advance, and by comparing each pixel (or each block) of the image in which data is embedded with the above-mentioned table, a strong area and a weak area May be determined. In particular, when photographic data such as JPEG or PNG is printed by a printer, conversion from RGB data to CMYK data often occurs. In this case, it is unlikely that the periodic fluctuations in the image remain as they are. Further, there may be a difference between the image data having a value of 0 to 255 that can be handled on the camera-equipped mobile terminal 201 and the color characteristics (color space) that can be handled by the printer. As a result, even if the pixel value of the image is added or subtracted by 10 on the camera-equipped mobile terminal 201, if it is a color space that cannot be expressed by the printer, for example, the fluctuation on the printer side is reduced to the addition or subtraction of 5. It is possible that it will be done. Therefore, even if a table showing the characteristics of the printer (for example, how much the periodic change for data embedding shifts due to the conversion of the image data format by the printer, etc.) is defined in the application having the function for decoding. good. Then, when the mobile terminal 201 with a camera performs decoding, it may be possible to determine a strong region and a weak region by referring to the above-mentioned table. This table may be acquired by the camera-equipped mobile terminal 201 communicating with the printer. Further, the determination of the strong region and the weak region is not based on the color, but the strong region and the weak region may be determined by analyzing the pattern and the frequency component of a certain region in the image, and the color may be determined. And may be judged by the combination of frequencies.

また、本実施形態では、図2、図3に示すように、画像における8px×8pxのブロック毎に2px幅の斜めの周期性が与えられる。このエンコード方式であると、埋め込み対象の画像に同様のパターンが存在する場合、誤判定をする可能性が高くなる。つまり、エンコード方式によって、苦手となる領域は異なってくる。また、携帯端末(撮像センサ)の特性によっても得意領域、苦手領域が異なってくる。例えばある携帯端末では、センサ性能の低さや、独自の画像処理の介入により、ある色成分において期待している値が取得できない場合がある。つまり、苦手領域、不得意領域の判定のために適切な処理は、利用するエンコード方式や想定している撮像センサやデコード装置などの条件により異なる。そのため、この条件に応じて、苦手領域、不得意領域の判定方法を異ならせることが望ましい。 Further, in the present embodiment, as shown in FIGS. 2 and 3, an oblique periodicity of 2 px width is given for each block of 8 px × 8 px in the image. With this encoding method, if a similar pattern exists in the image to be embedded, there is a high possibility of making an erroneous determination. In other words, the area that you are not good at differs depending on the encoding method. In addition, the areas of strength and weakness differ depending on the characteristics of the mobile terminal (imaging sensor). For example, in a certain mobile terminal, the expected value for a certain color component may not be obtained due to low sensor performance or intervention of original image processing. That is, the appropriate processing for determining the weak area and the weak area differs depending on the conditions such as the encoding method to be used and the assumed imaging sensor and decoding device. Therefore, it is desirable to make different determination methods for weak areas and weak areas according to this condition.

次にS1204~S1208でCPU203は、S1203における苦手領域の判定結果に基づいて、画像における埋め込みデータの埋め込み位置を決定し、その領域にデータを埋め込む。具体的には、画像において、画素値に所定の変化を与えることが可能な領域が、当該所定の変化を与えることが可能でない領域よりも優先されるように、データが埋め込まれる。先述の多重化方法では「hello」の8px×8pxのブロックを40ビット分のパターン横一列に並べていたため、320px×8pxの領域が必要である。ここで、埋め込みデータの埋め込みに必要なブロックの数を示す変数としてW、Hが定義され、横W個、縦H個の8px×8pxのブロックによりデータが埋め込まれるものとする。320px×8pxの領域にデータが埋め込まれる場合、W=40、H=1である。CPU203は、図15に示した画像において、すべて白画素(得意領域)となる320px×8pxの領域を探索する。 Next, in S1204 to S1208, the CPU 203 determines the embedding position of the embedded data in the image based on the determination result of the weak region in S1203, and embeds the data in that region. Specifically, in the image, data is embedded so that a region capable of giving a predetermined change to the pixel value has priority over a region in which the predetermined change cannot be given. In the multiplexing method described above, 8 px × 8 px blocks of “hello” are arranged in a horizontal row of patterns for 40 bits, so a 320 px × 8 px area is required. Here, W and H are defined as variables indicating the number of blocks required for embedding the embedded data, and it is assumed that the data is embedded by 8px × 8px blocks of W horizontally and H vertically. When data is embedded in the area of 320px × 8px, W = 40 and H = 1. In the image shown in FIG. 15, the CPU 203 searches for a region of 320 px × 8 px, which is an all white pixel (specialty region).

具体的には、S1204においてCPU203は、埋め込み領域の探索を開始する。探索開始の基準となる画素は、初回の探索では画像の左上の画素であり、2回目以降の探索では右方向、下方向にインクリメントされる。S1205においてCPU203は、図15に示す画像に含まれる画素の画素値を解析することで、埋め込み可能領域が検出されたか判定する。具体的には、S1205においてCPU203は、埋め込まれるデータの情報量に応じて、画像における当該データを埋め込むための領域のサイズを特定し、そのサイズであり、且つ得意領域に該当する領域を探索する。例えばCPU203は、図15に示す画像において、探索の基準となる画素を左上の始点とする、320px×8pxの領域が全て白画素(得意領域)であるか判定する。埋め込み可能領域が検出されたと判定された場合、CPU203はS1206において、上述した方法によりS1205において検出された領域にデータを埋め込む。そして、S1207においてCPU203は、図15に示す画像において、S1205において検出された領域を黒画素(苦手領域)に変更する。この処理は、次にS1205の処理が行われた場合に再度白画素(得意領域)と判定され、データが重複して埋め込まれるのを避けるためである。S1206においてデータが埋め込まれた場合、もしくはS1205において埋め込み可能領域が検出されない場合、S1208に処理が進む。S1208おいてCPU203は、全画素について埋め込み可能領域の探索処理が実行されたか判定する。例えば、画像の全画素が、上記の基準となる画素となったか判定される。全画素について埋め込み可能領域の探索処理が実行されたと判定された場合、処理を終了する。一方、全画素について埋め込み可能領域の探索処理が実行されていない場合、S1205に処理が戻る。このとき、上述のように、探索の基準となる画素が更新される。S1209でCPU203は、アプリケーションを実行してOSにコマンドを送ることで、S1204~S1208によりデータが埋め込まれた画像をプリンタ103に送信して印刷させる印刷制御を実行する。 Specifically, in S1204, the CPU 203 starts searching for the embedded area. The pixel that serves as a reference for starting the search is the pixel on the upper left of the image in the first search, and is incremented to the right and downward in the second and subsequent searches. In S1205, the CPU 203 determines whether or not the embeddingable region has been detected by analyzing the pixel values of the pixels included in the image shown in FIG. Specifically, in S1205, the CPU 203 specifies the size of the area for embedding the data in the image according to the amount of information of the data to be embedded, and searches for an area that is the size and corresponds to the area of specialty. .. For example, in the image shown in FIG. 15, the CPU 203 determines whether or not all the 320px × 8px regions having the pixel that is the reference of the search as the starting point on the upper left are white pixels (specialty regions). When it is determined that the embeddingable area is detected, the CPU 203 embeds the data in the area detected in S1205 by the method described above in S1206. Then, in S1207, the CPU 203 changes the region detected in S1205 to a black pixel (a weak region) in the image shown in FIG. This process is for avoiding that when the process of S1205 is performed next time, it is determined again as a white pixel (specialty area) and data is duplicated and embedded. If the data is embedded in S1206, or if the embeddable area is not detected in S1205, the process proceeds to S1208. In S1208, the CPU 203 determines whether the search process of the embedding area is executed for all the pixels. For example, it is determined whether all the pixels of the image have become the above-mentioned reference pixels. When it is determined that the search processing of the embedding area is executed for all the pixels, the processing is terminated. On the other hand, when the search processing of the embedding area is not executed for all the pixels, the processing returns to S1205. At this time, as described above, the pixel that is the reference for the search is updated. In S1209, the CPU 203 executes an application and sends a command to the OS to execute print control for transmitting the image in which the data is embedded by S1204 to S1208 to the printer 103 for printing.

上述のS1204~S1208と同様の処理を行うためのプログラムコードの一例を以下に示す。 An example of the program code for performing the same processing as S1204 to S1208 described above is shown below.

Figure 0007102128000002
Figure 0007102128000002

14~20行目において、注目している320px×8pxの領域が、全ての画素で白となる得意領域であるか判断している。もし、黒領域(黒画素)が含まれる場合、isDrawableのフラグがfalseとなり、22行目において、多重化処理を行う前に次の探索位置へと移行する。全て白領域であった場合は24行目で320px×8pxの領域に対して埋め込み処理を行う。26~30行目において、埋め込み処理がなされた領域は、多重化不可領域として扱うために、drawableMapをfalseに更新する。 In the 14th to 20th lines, it is determined whether the region of 320px × 8px of interest is a region that is good at being white in all pixels. If a black region (black pixel) is included, the isDrawable flag becomes false, and in the 22nd line, the search position shifts to the next search position before performing the multiplexing process. If all are white areas, embedding processing is performed on the 320px × 8px area on the 24th line. In the 26th to 30th lines, the area where the embedding process has been performed is treated as a non-multiplexable area, so the drawableMap is updated to false.

図16は、本実施形態の処理により決定された位置に多重化が行われた画像の一例を示す図である。図16では、図15の画像内で320px×8pxが全て白という領域に多重化が施されている。 FIG. 16 is a diagram showing an example of an image in which multiplexing is performed at a position determined by the process of the present embodiment. In FIG. 16, in the image of FIG. 15, the region where 320px × 8px is all white is multiplexed.

しかし、図16では苦手領域を避けて埋め込みは実行できているが、使われていない白領域(得意領域)も多くある。そこで、埋め込みデータに用いられる領域の形状は、上述したものに限らない。図17は、本実施形態の処理により決定された位置に多重化が行われた画像の別の例を示す図である。図17では、64px×40pxの領域で8px×8pxが横に8つ、縦に5つ並んでいる領域について、左上から右下に向かう方向に、バイナリデータに含まれる「0」または「1」がブロックに埋め込まれている。64px×40pxの領域のように、ブロックが集中する形状を採用することで、カメラをより近づけても埋め込みデータ全体が入る状態になる可能性が高く、デコードに必要な領域の画像を鮮明に取得できるようになる可能性が高くなる。また、埋め込みデータに相当するブロックが集中しているほど、カメラレンズの収差によるズレの影響や、カメラの傾きによる誤差の影響が少なくなる利点もある。 However, in FIG. 16, although the embedding can be performed while avoiding the weak area, there are many unused white areas (good areas). Therefore, the shape of the region used for the embedded data is not limited to that described above. FIG. 17 is a diagram showing another example of an image in which multiplexing is performed at a position determined by the processing of the present embodiment. In FIG. 17, “0” or “1” included in the binary data is included in the binary data in the direction from the upper left to the lower right in the area of 64px × 40px in which eight 8px × 8px are arranged horizontally and five vertically. Is embedded in the block. By adopting a shape in which blocks are concentrated, such as a 64px x 40px area, there is a high possibility that the entire embedded data will be included even if the camera is brought closer, and the image of the area required for decoding will be clearly acquired. It is more likely that you will be able to do it. Further, as the blocks corresponding to the embedded data are concentrated, there is an advantage that the influence of the deviation due to the aberration of the camera lens and the influence of the error due to the tilt of the camera are reduced.

このように、埋め込みデータが埋め込まれる領域の形状は種々のものを採用することができ、またその形状である複数の候補から、多重化、印刷される画像に使用される形状が自動的に決定されてもよい。例えばCPU203は、埋め込みデータが埋め込まれる領域として異なる形状を採用し、図12のS1203、S1204の処理を実行する。そしてCPU203は、同一の埋め込みデータが得意領域において繰り返し埋め込まれるときに、最も埋め込み回数(埋め込まれる領域の数)が多くなる形状を特定する。そして、特定された形状を用いて、埋め込みデータを多重化し、印刷のための画像を生成する。 In this way, various shapes of the area in which the embedded data is embedded can be adopted, and the shape used for the image to be multiplexed and printed is automatically determined from a plurality of candidates which are the shapes. May be done. For example, the CPU 203 adopts a different shape as an area in which the embedded data is embedded, and executes the processes of S1203 and S1204 of FIG. Then, the CPU 203 specifies the shape in which the number of times of embedding (the number of embedded areas) is the largest when the same embedded data is repeatedly embedded in the specialty area. Then, using the specified shape, the embedded data is multiplexed to generate an image for printing.

上述のように、8px×8pxを40個並べるパターンとして種々のものを採用することができる。ここで、8px×8pxのブロックが縦W個、横H個並ぶとすれば、それが40個以上になればよいので、式(1)を満たせば良いことがわかる。 As described above, various patterns can be adopted as a pattern in which 40 pieces of 8px × 8px are arranged. Here, if 8px × 8px blocks are arranged vertically W and horizontally H, it is sufficient that the number of blocks is 40 or more, so it can be seen that the equation (1) should be satisfied.

W×H≧40 (1)
つまり、W,Hの組み合わせにおいて、得意領域に配置できる個数が最大になるものを選択すればよい。
W × H ≧ 40 (1)
That is, in the combination of W and H, the one that maximizes the number that can be arranged in the specialty area may be selected.

また、先述の埋め込みは「hello」のバイナリデータについての埋め込みについて説明したが、本実施形態では、デコード側の処理のために、データの開始位置や変数W、Hの情報についても埋め込む例についても説明する。 Further, in the above-mentioned embedding, the embedding of the binary data of "hello" has been described, but in the present embodiment, there is also an example of embedding the data start position and the information of the variables W and H for the processing on the decoding side. explain.

図18は、埋め込みデータのデータ形式の一例を示す図である。図18に示すように、埋め込みデータには、開始位置判定パターン1801、ヘッダ部1802、実データ部1803が含まれる。ヘッダ部には「0」「1」とは違ったパターンのブロックが存在しており、デコードを行う装置では、このブロックによってヘッダの位置を特定することができる。ヘッダの位置から(x1、y1)ずれた位置にはWに相当する4bitの情報が埋め込まれ、(x2、y2)ずれた位置にはHに相当する4bitの情報が埋め込まれ、(x3、y3)ずれた位置が実データ部開始位置のように定められている。このような取り決めに従ってデータが埋め込まれた場合の周期パターンについて、図19を用いて後述する。なお、このような取決めは、エンコード処理とデコード処理が同一のアプリケーションにより実現される場合、該アプリケーションで定められている。またエンコード処理とデコード処理が個別のアプリケーションにより実現される場合、2つのアプリケーション間で共通の定義が行われている。また図18に示すデータ構成には、図13で説明したファイルフォーマット部も含まれる。 FIG. 18 is a diagram showing an example of a data format of embedded data. As shown in FIG. 18, the embedded data includes a start position determination pattern 1801, a header unit 1802, and an actual data unit 1803. A block having a pattern different from "0" and "1" exists in the header portion, and the decoding device can specify the position of the header by this block. 4 bit information corresponding to W is embedded in the position deviated from the position of the header (x1, y1), and 4 bit information corresponding to H is embedded in the position deviated from the position (x2, y2), and (x3, y3). ) The shifted position is defined as the start position of the actual data section. The periodic pattern when data is embedded according to such an agreement will be described later with reference to FIG. It should be noted that such an agreement is defined in an application when the encoding process and the decoding process are realized by the same application. Further, when the encoding process and the decoding process are realized by individual applications, a common definition is made between the two applications. The data structure shown in FIG. 18 also includes the file format unit described with reference to FIG.

図19は、埋め込みデータが埋め込まれた領域の周期パターンの一例を示す図である。図19では、図18に示したデータ形式の埋め込みデータが、9×9個のブロック(72px×72pxの領域)に埋め込まれた場合の例である。開始位置判定パターン1901は、図18の1801に相当し、図11に示したパターンにより表現されている。W情報1902、H情報1903、ファイルフォーマット情報1904は、図18のヘッダ部1802に含まれる4ビットの情報であり、それぞれ横に並んだ4つのブロックにより表現されている。実データ1905は、図18の1803に相当し、横8個、縦5個の40個のブロックにより、40ビットのバイナリデータを表現している。 FIG. 19 is a diagram showing an example of a periodic pattern of a region in which embedded data is embedded. FIG. 19 shows an example in which the embedded data in the data format shown in FIG. 18 is embedded in 9 × 9 blocks (72px × 72px area). The start position determination pattern 1901 corresponds to 1801 in FIG. 18 and is represented by the pattern shown in FIG. The W information 1902, the H information 1903, and the file format information 1904 are 4-bit information included in the header portion 1802 of FIG. 18, and are represented by four blocks arranged side by side. The actual data 1905 corresponds to 1803 in FIG. 18, and represents 40-bit binary data by 40 blocks of 8 horizontal and 5 vertical.

なお、図18に示したヘッダ部の形態はこれに限らず、様々な情報を持たすように拡張されもよいし、開始位置判定ブロックの配置位置も図19の限りではなく、どこに配置されてもよい。また、位置判定の精度を上げるために、複数の開始位置判定ブロックが設けられてもよいし、より大きなサイズの開始位置判定ブロックが設けられてもよい。また、図19では埋め込みデータが埋め込まれる領域の形状が正方形であるが、正方形以外の矩形でもよい。 The form of the header portion shown in FIG. 18 is not limited to this, and may be expanded to have various information, and the arrangement position of the start position determination block is not limited to that in FIG. 19, and may be arranged anywhere. good. Further, in order to improve the accuracy of the position determination, a plurality of start position determination blocks may be provided, or a larger size start position determination block may be provided. Further, in FIG. 19, the shape of the region where the embedded data is embedded is a square, but a rectangle other than the square may be used.

以上の実施形態における処理によれば、画像に含まれる画素の画素値を変化させることで、画像にデータを埋め込むことができる。また、画像に含まれる画素の画素値を解析することで、その変化を行うのに適切な画素(領域)であるか判定する。そのため、画像において多重化が適切に行われない可能性がある苦手領域を避けて、埋め込みデータを多重化することができる。従って、デコードを行う装置において、多重化されたデータを適切にデコードできないケースを低減させることができる。さらに、例えば画像における苦手領域に適切な多重化を行えるように、画像内の画素値を変更する方法に比べ、画質劣化を抑えたうえで多重化を行うことができる。 According to the processing in the above embodiment, data can be embedded in the image by changing the pixel values of the pixels included in the image. Further, by analyzing the pixel values of the pixels included in the image, it is determined whether or not the pixels (regions) are appropriate for the change. Therefore, it is possible to multiplex the embedded data while avoiding a weak area where multiplexing may not be performed properly in the image. Therefore, it is possible to reduce the cases where the multiplexed data cannot be appropriately decoded in the decoding device. Further, for example, as compared with the method of changing the pixel value in the image, the multiplexing can be performed after suppressing the deterioration of the image quality so that the appropriate multiplexing can be performed in the weak area in the image.

(第2の実施形態)
第2の実施形態では、埋め込みデータを非連続のブロックに埋め込む処理について説明する。第1の実施形態では、埋め込みデータを、画像において連続するブロックに埋め込んでいた。しかしながら、埋め込みデータを全て表現できる数の連続するブロックに相当する得意領域が、画像内に存在しない場合がある。特に、埋め込もうとするデータの情報量が多い場合や、得意領域と判定される情報が厳しい場合、全情報を埋め込める数の連続するブロックに相当する得意領域が、画像内に存在しない場合がある。このような場合においても、得意領域のみを利用した情報の埋め込みを行う処理について説明する。以降、「0」もしくは「1」もしくは開始位置を表現するための8px×8pxブロックを「基礎ブロック」と記述し、デコードで利用する形に基礎ブロックをまとめたものを「データブロック」とする。つまり図3(a)(b)や図9に示したブロックが基礎ブロックであり、図19に示したブロックが、データブロックである。
(Second embodiment)
In the second embodiment, the process of embedding the embedded data in the discontinuous block will be described. In the first embodiment, the embedded data is embedded in continuous blocks in the image. However, there are cases where there is no specialty area in the image corresponding to a number of consecutive blocks that can represent all the embedded data. In particular, when the amount of information of the data to be embedded is large, when the information determined to be a good area is strict, or when there is no good area corresponding to the number of consecutive blocks in which all the information can be embedded in the image. There is. Even in such a case, the process of embedding information using only the area of specialty will be described. Hereinafter, the 8px × 8px block for expressing “0” or “1” or the start position is described as a “basic block”, and the basic block is referred to as a “data block” in a form used for decoding. That is, the blocks shown in FIGS. 3 (a) and 3 (b) and 9 are basic blocks, and the blocks shown in FIG. 19 are data blocks.

実施形態1では画素値が10加算または減算されることで、多重化が行われた。実施形態2では、画素値が15加算または減算されることで多重化が行われる。図20は、このような条件で図12のS1203の処理により苦手領域の判定が行われた結果の別の例を示す図である。図15と同様、画像中の黒い箇所が苦手領域であり、画像中の白い箇所が得意領域である。ここで、画像に埋め込まれる内容を「hello」ではなく「Congrats on your tenth birthday」とする。前記の文字はスペース含め全31文字であり、1文字が8bitだとすると、全部で248bitの情報が必要になる。即ち「0」もしくは「1」を表現するために図3(a)(b)のような8px×8pxのパターンを利用した場合、上記の文字列を表現するためには最低248個の基礎ブロックが必要となる。本実施形態は説明のため、データを埋め込むブロック(データブロック)は正方形として説明をおこなうが、正方形に限定されるわけではなく、正方形以外の矩形でも良い。 In the first embodiment, multiplexing is performed by adding or subtracting 10 pixel values. In the second embodiment, multiplexing is performed by adding or subtracting 15 pixel values. FIG. 20 is a diagram showing another example of the result of determining a weak region by the process of S1203 of FIG. 12 under such conditions. Similar to FIG. 15, the black part in the image is a weak area, and the white part in the image is a good area. Here, the content embedded in the image is not "hello" but "Congrats on your birthday". The above characters are all 31 characters including spaces, and if one character is 8 bits, a total of 248 bits of information is required. That is, when the 8px × 8px pattern as shown in FIGS. 3 (a) and 3 (b) is used to express “0” or “1”, at least 248 basic blocks are used to express the above character string. Is required. For the sake of explanation, the block in which data is embedded (data block) will be described as a square, but the present embodiment is not limited to a square and may be a rectangle other than a square.

まずCPU203は、図20において全てが得意領域となる正方形の領域を検出する。図21は、全てが得意領域となる正方形の領域の例を示す図である。ブロックAは96px×96pxの正方形の領域であり、ブロックBは120px×120pxの正方形の領域である。ブロックAの領域は基礎ブロック数では144個分に相当し、ブロックBの領域は基礎ブロック数で225個分に相当する。これらは二つとも「Congrats on your tenth birthday」を表現する為に最低限必要な基礎ブロック248個分には満たないが、二つを合わせると248個分を満たすことができる。そこで、実施形態2では、ブロックAの領域とブロックBの領域の両方を用いて「Congrats on your tenth birthday」を表現する。ここで、ブロックAには「Congrats on 」(96bit)、ブロックBには「your tenth birthday」(152bit)を埋め込むこととする。 First, the CPU 203 detects a square area in FIG. 20, which is a region in which all are good. FIG. 21 is a diagram showing an example of a square area in which all are good areas. Block A is a 96px × 96px square area, and block B is a 120px × 120px square area. The area of block A corresponds to 144 basic blocks, and the area of block B corresponds to 225 basic blocks. Both of these are less than the minimum 248 foundation blocks required to express "Congrats on your tenth birthday", but the two together can satisfy 248. Therefore, in the second embodiment, "Congrats on your tenth birthday" is expressed by using both the region of block A and the region of block B. Here, "Congrats on" (96 bits) is embedded in the block A, and "your tenth birthday" (152 bits) is embedded in the block B.

二つのブロックで一つのデータを表現するためには、実施例の情報に加え、「全データ中のどこからどこまでのデータか」を示す情報が必要になる。これを実現するためにヘッダを図22のように作成する。図22は、埋め込みデータのデータ構成の別の例を示す図である。開始位置判定パターン2201は、上述した開始位置判定パターンと同様であるので説明を省略する。全データ数2202は、埋め込みデータの全データ数を示し、今回の場合は248bitを示す。実データ数2203は、実データ部に何ビット分のデータが入っているかを示す値である。例えばブロックAにおける実データ数2203は96を示し、ブロックBおける実データ数2203は152を示す。開始オフセット2204は、データブロック含まれるデータが、埋め込みデータ全体におけるどの位置から始まるデータであるかを示す。ブロックAに関してはデータが先頭から始まっているので、開始オフセット2204は「0」を示し、ブロックBに関しては96bit目以降の情報が入るという意味で、開始オフセット2204は「96」を示す。 In order to express one data with two blocks, in addition to the information of the embodiment, the information indicating "where to where in all the data" is required. To achieve this, a header is created as shown in FIG. FIG. 22 is a diagram showing another example of the data structure of the embedded data. Since the start position determination pattern 2201 is the same as the start position determination pattern described above, the description thereof will be omitted. The total number of data 2202 indicates the total number of embedded data, and in this case, 248 bits. The number of actual data 2203 is a value indicating how many bits of data are contained in the actual data unit. For example, the number of actual data 2203 in block A indicates 96, and the number of actual data 2203 in block B indicates 152. The start offset 2204 indicates from which position in the entire embedded data the data included in the data block starts. Since the data starts from the beginning of the block A, the start offset 2204 indicates "0", and the start offset 2204 indicates "96" in the sense that the information after the 96th bit is input for the block B.

図22に示したデータ形式により、デコード側の装置では、分割された複数のデータブロックから抽出したデータの結合方法を認識することができ、埋め込みデータを復号することが可能となる。また図22の例では、データブロックにおけるヘッダ部は開始位置のブロックを含め37bitが必要であり、二つ分であると74bit必要となる。また実データ部が248bitであるため、ヘッダ部と実データ部の合計で322bitであり322個の基礎ブロックが必要である。ブロックAは基礎ブロックを144個含み、ブロックBは基礎ブロックを225個含むため、合計で369個分の基礎ブロックが含まれる。つまり、本実施例のデータにおいてはブロックAとブロックBを合わせて用いることで、上述の322bitの埋め込みデータを埋め込めることが可能である。 With the data format shown in FIG. 22, the device on the decoding side can recognize the method of combining the data extracted from the plurality of divided data blocks, and can decode the embedded data. Further, in the example of FIG. 22, the header portion in the data block requires 37 bits including the block at the start position, and 74 bits is required if it is divided into two. Further, since the actual data unit is 248 bits, the total of the header unit and the actual data unit is 322 bits, and 322 basic blocks are required. Since block A contains 144 basic blocks and block B contains 225 basic blocks, a total of 369 basic blocks are included. That is, in the data of this embodiment, by using the block A and the block B together, it is possible to embed the above-mentioned 322 bit embedded data.

なお、本実施形態では「Congrats on your tenth birthday」を「Congrats on 」と「your tenth birthday」に二分割にしたが、情報を重複させてもよい。つまり、データブロックに余裕がある場合は「Congrats on your」と「on your tenth birthday」のように埋め込んでも良い。 In the present embodiment, "Congrats on your tenth birthday" is divided into "Congrats on" and "your tenth birthday", but the information may be duplicated. That is, if there is a margin in the data block, it may be embedded like "Congrats on your" and "on your birthday".

なお、本実施形態では2つのデータブロックを結合することによってデータを表現する説明を行ったが、2つ以上のデータブロックによりデータを表現してもよい。ただし、データブロックを分割するためには、それらを表現するためのヘッダ部が必要となり、分割数が増えれば増えるほどヘッダ部のオーバーヘッドが増えることになる。そのため、分割数はなるたけ少ないほうが望ましい。 In the present embodiment, the data is expressed by combining two data blocks, but the data may be expressed by two or more data blocks. However, in order to divide the data blocks, a header part for expressing them is required, and as the number of divisions increases, the overhead of the header part increases. Therefore, it is desirable that the number of divisions is as small as possible.

また本実施形態では説明のため得意領域の正方形が2つのみであったが、得意領域の正方形が複数存在する場合も起こり得る。その場合のCPU203によるブロックの位置とサイズの決定方法は下記のような手順が考えられる。下記の手順は分割なしでデータを埋め込む方法も含まれている。 Further, in the present embodiment, for the sake of explanation, there are only two squares in the specialty area, but there may be a case where there are a plurality of squares in the specialty area. In that case, the following procedure can be considered as a method for determining the block position and size by the CPU 203. The procedure below also includes a method of embedding data without splitting.

ステップ1においてCPU203は、埋め込みたいデータを全て埋め込める最小のデータブロックサイズを決定する。ステップ2においてCPU203は、ステップ1で決定されたサイズで得意領域の条件を満たす位置を探索する。ステップ3においてCPU203は、ステップ2において探索できた位置に対して情報を埋め込む。そして、CPU203は、ステップ2における処理が画像の全領域に対して実行されるまで、ステップ1~3の処理を繰り返す。上記のステップ1~3は、例えば図12のS1204~S1208の処理により実現される。 In step 1, the CPU 203 determines the minimum data block size in which all the data to be embedded can be embedded. In step 2, the CPU 203 searches for a position that satisfies the condition of the specialty region with the size determined in step 1. In step 3, the CPU 203 embeds information for the position searched in step 2. Then, the CPU 203 repeats the processes of steps 1 to 3 until the process of step 2 is executed for the entire area of the image. The above steps 1 to 3 are realized, for example, by the processing of S1204 to S1208 of FIG.

またステップ4においてCPU203は、ステップ1で決定されたサイズより小さいサイズで得意領域の条件を満たす位置を探索する。ステップ4における処理は、例えばステップ3における埋め込みの回数が所定数以下の場合に実行される。ステップ5においてCPU203は、ステップ4で得意領域が探索されるたびに得意領域のサイズを加算する。そして、CPU203は、ステップ6において、ステップ4において加算されたサイズが、ヘッダ部と実データ部を埋め込めるサイズであれば、複数の得意領域に埋め込みデータを分割して埋め込む。そして、CPU203は、ステップ4における処理が画像の全領域に対して実行されるまで、ステップ4~6の処理を繰り返す。 Further, in step 4, the CPU 203 searches for a position that satisfies the condition of the specialty region with a size smaller than the size determined in step 1. The process in step 4 is executed, for example, when the number of times of embedding in step 3 is a predetermined number or less. In step 5, the CPU 203 adds the size of the specialty area each time the specialty area is searched for in step 4. Then, in step 6, if the size added in step 4 is a size that can embed the header part and the actual data part, the CPU 203 divides and embeds the embedded data in a plurality of specialty areas. Then, the CPU 203 repeats the processes of steps 4 to 6 until the process of step 4 is executed for the entire area of the image.

つまり、ステップ1~3の処理により、分割をしないでもデータを埋め込める得意領域があれば、その得意領域にデータが埋め込まれる。一方、ステップ4~6の処理により、分割してデータを埋め込める領域が探索され、その領域にデータが分割されて埋め込まれる。上記の得意領域の条件は先述の通り、エンコードとデコードの特性に応じて適切なものが設定される。上記のように埋め込みデータが分割して埋め込まれることで、連続する得意領域が全データを埋め込むには不十分なサイズであっても、データを埋め込むことが可能となる。 That is, if there is a good area in which data can be embedded without division by the processing of steps 1 to 3, the data is embedded in the good area. On the other hand, by the processing of steps 4 to 6, an area in which the data can be divided and embedded is searched, and the data is divided and embedded in the area. As described above, the conditions of the above-mentioned specialty area are set appropriately according to the characteristics of encoding and decoding. By embedding the embedded data separately as described above, it is possible to embed the data even if the continuous specialty area is not large enough to embed all the data.

(その他の実施形態)
以上の実施形態におけるデータ埋め込みは全て矩形で説明したが、矩形でなくてもよい。例えばデータブロックのヘッダ部に、x座標、y座標と半径情報を入れることで、円形領域に基礎ブロックを配置することも可能である。また、以上の実施形態においては、データブロック内に苦手領域が含まれていないものとして説明したが、データブロックから苦手領域を全て除かなければならないわけではない。例えば、データブロックのヘッダ部にデータブロック内における苦手領域の座標を記述しておき、その位置には基礎ブロックを配置しないようにしてもよい。例えば、苦手領域、得意領域の判定において「注目領域における苦手領域の含有率は10%まで許容する」などの対応が可能となる。
(Other embodiments)
Although all the data embeddings in the above embodiments have been described with rectangles, they do not have to be rectangles. For example, by putting the x-coordinate, y-coordinate and radius information in the header part of the data block, it is possible to arrange the basic block in the circular area. Further, in the above embodiment, it has been described that the weak area is not included in the data block, but it is not necessary to remove all the weak areas from the data block. For example, the coordinates of the weak area in the data block may be described in the header part of the data block, and the basic block may not be arranged at that position. For example, in determining the weak region and the strong region, it is possible to take measures such as "the content rate of the weak region in the region of interest is allowed up to 10%".

さらに、以上の実施形態では、注目画素に対する苦手領域の判定方法として、所定の埋め込み方法によるデータの埋め込みが可能か否かを判定していた。例えば所定の埋め込み方法が、画素値に対する所定の変化(例えば10の加算または減算)を与える方法の場合、CPU203は、その変化(加算または減算)を行うことが可能か否かを判定していた。そして、画像において、その変化が可能な領域が、その変化が可能でない領域よりも優先されてデータが埋め込まれるように、データの埋め込み位置が決定されていた。しかしこれに限らず、例えば10の加算または減算はできなくても、8や9の加算または減算が可能であれば得意領域に該当する画素と判定するなど、許容範囲が設けられてもよい。この場合、データの埋め込み方法として画素値に与えられる変化は、「画素値に対する8~10の加算または減算」となり、その変化が可能な領域が、その変化が可能でない領域よりも優先されてデータが埋め込まれる。 Further, in the above embodiment, as a method of determining a region that is not good for the pixel of interest, it is determined whether or not data can be embedded by a predetermined embedding method. For example, when the predetermined embedding method is a method of giving a predetermined change (for example, addition or subtraction of 10) to the pixel value, the CPU 203 determines whether or not the change (addition or subtraction) can be performed. .. Then, in the image, the embedding position of the data is determined so that the region where the change is possible is prioritized over the region where the change is not possible and the data is embedded. However, the present invention is not limited to this, and an allowable range may be provided, for example, even if addition or subtraction of 10 is not possible, if addition or subtraction of 8 or 9 is possible, it is determined that the pixel corresponds to a specialty region. In this case, the change given to the pixel value as a data embedding method is "addition or subtraction of 8 to 10 with respect to the pixel value", and the area where the change is possible has priority over the area where the change is not possible. Is embedded.

また、画像における得意領域にデータが分割されないように、まとめて埋め込む場合、苦手領域にはデータを埋め込まないようにしてもよいし、苦手領域にもデータをまとめて埋め込むようにしてもよい。この場合でも、得意領域と苦手領域が混在する領域にデータが埋め込まれるのを防ぐことができる。またそれとともに、例えば印刷物における得意領域に該当する部分に折れや汚れが生じ、データのデコードが困難になった場合でも、苦手領域に該当する部分からデコードが可能となる余地を残すことができる。 Further, when embedding the data collectively so as not to divide the data into the strong areas in the image, the data may not be embedded in the weak area, or the data may be collectively embedded in the weak area. Even in this case, it is possible to prevent data from being embedded in an area where a strong area and a weak area coexist. At the same time, for example, even if the portion corresponding to the strong region in the printed matter is broken or soiled and it becomes difficult to decode the data, it is possible to leave room for decoding from the portion corresponding to the weak region.

なお、本実施形態の機能は以下の構成によっても実現することができる。つまり、本実施形態の処理を行うためのプログラムコードをシステムあるいは装置に供給し、そのシステムあるいは装置のコンピュータ(またはCPUやMPU)がプログラムコードを実行することによっても達成される。この場合、記憶媒体から読み出されたプログラムコード自体が上述した実施形態の機能を実現することとなり、またそのプログラムコードを記憶した記憶媒体も本実施形態の機能を実現することになる。 The function of this embodiment can also be realized by the following configuration. That is, it is also achieved by supplying the program code for performing the processing of the present embodiment to the system or the device, and executing the program code by the computer (or CPU or MPU) of the system or the device. In this case, the program code itself read from the storage medium realizes the function of the above-described embodiment, and the storage medium storing the program code also realizes the function of the present embodiment.

また、本実施形態の機能を実現するためのプログラムコードを、1つのコンピュータ(CPU、MPU)で実行する場合であってもよいし、複数のコンピュータが協働することによって実行する場合であってもよい。さらに、プログラムコードをコンピュータが実行する場合であってもよいし、プログラムコードの機能を実現するための回路等のハードウェアを設けてもよい。またはプログラムコードの一部をハードウェアで実現し、残りの部分をコンピュータが実行する場合であってもよい。 Further, the program code for realizing the function of the present embodiment may be executed by one computer (CPU, MPU), or may be executed by a plurality of computers collaborating with each other. May be good. Further, the program code may be executed by a computer, or hardware such as a circuit for realizing the function of the program code may be provided. Alternatively, a part of the program code may be implemented by hardware and the rest may be executed by a computer.

Claims (16)

画像に含まれる画素の画素値に所定の変化を与える所定の埋め込み方法に従って、前記画像に対してデータを埋め込むためのプログラムであって、
前記所定の埋め込み方法に対応する所定の解析方法に従って、前記画像に含まれる画素の画素値に基づく解析を行う解析手段と、
前記画像において、前記所定の変化を与えることが可能な領域を少なくとも含む第1の領域が前記所定の変化を与えることが可能でない第2の領域よりも優先されて前記データが埋め込まれるように、前記画像における、前記解析手段による解析結果に基づく位置に、前記所定の埋め込み方法に従って前記データを埋め込む埋め込み手段と、
前記第1の領域に前記所定の変化を与えることが可能でない領域が含まれる場合、前記第1の領域に関する情報として、前記所定の変化を与えることが可能でない領域の座標を記述する記述手段と、
としてコンピュータを機能させ、
前記第1の領域のうち、前記所定の変化を与えることが可能でない領域には前記データが埋め込まれないように制御されることを特徴とするプログラム。
A program for embedding data in an image according to a predetermined embedding method that gives a predetermined change to the pixel values of pixels included in the image.
An analysis means that performs analysis based on the pixel values of the pixels included in the image according to a predetermined analysis method corresponding to the predetermined embedding method.
In the image, the data is embedded so that the first region containing at least the region capable of giving the predetermined change is prioritized over the second region not capable of giving the predetermined change. An embedding means for embedding the data at a position in the image based on the analysis result by the analysis means according to the predetermined embedding method.
When the first region includes a region that cannot give the predetermined change, as information about the first region, a description means for describing the coordinates of the region that cannot give the predetermined change. ,
Make your computer work as
A program characterized in that the data is controlled so as not to be embedded in a region of the first region that cannot be given a predetermined change.
前記解析手段は、前記所定の解析方法として、前記所定の埋め込み方法により前記画素値に前記所定の変化を与えた場合の結果に関する解析を行うことを特徴とする請求項1に記載のプログラム。 The program according to claim 1, wherein the analysis means analyzes the result when the predetermined change is given to the pixel value by the predetermined embedding method as the predetermined analysis method. 前記解析手段は、前記所定の解析方法として、前記画素値に前記所定の変化を与えることが可能か否かを解析することを特徴とする請求項2に記載のプログラム。 The program according to claim 2, wherein the analysis means analyzes whether or not it is possible to give the predetermined change to the pixel value as the predetermined analysis method. 前記埋め込み手段は、前記解析結果と前記データの情報量に基づく位置に、前記データを埋め込むことを特徴とする請求項1乃至3のいずれか1項に記載のプログラム。 The program according to any one of claims 1 to 3, wherein the embedding means embeds the data at a position based on the analysis result and the amount of information of the data. 前記埋め込み手段は、前記データの情報量を埋め込むための前記画像における領域のサイズを特定し、特定された前記サイズであり且つ前記解析手段による解析結果が所定の条件を満たす領域を探索し、前記探索により検出された領域に前記データを埋め込むことを特徴とする請求項4に記載のプログラム。 The embedding means specifies the size of a region in the image for embedding the amount of information of the data, searches for a region having the specified size and the analysis result by the analysis means satisfies a predetermined condition, and then searches for the region. The program according to claim 4, wherein the data is embedded in a region detected by the search. 前記所定の条件は、前記領域における全画素が前記所定の埋め込み方法を実行することが可能であることを特徴とする請求項5に記載のプログラム。 The program according to claim 5, wherein all the pixels in the region can execute the predetermined embedding method. 前記埋め込み手段は、前記データの情報量に基づいて、前記データを前記画像の非連続の複数の領域に分割して埋め込むことを特徴とする請求項5または6に記載のプログラム。 The program according to claim 5 or 6, wherein the embedding means divides the data into a plurality of discontinuous regions of the image and embeds the data based on the amount of information of the data. 前記埋め込み手段は、前記特定されたサイズであり且つ前記解析手段による解析結果が前記所定の条件を満たす領域が前記探索により検出されない場合に、前記データを、前記所定の条件を満たす前記非連続の複数の領域に分割して埋め込むことを特徴とする請求項7に記載のプログラム。 When the region having the specified size and the analysis result by the analysis means satisfies the predetermined condition is not detected by the search, the embedding means obtains the data in the discontinuous state satisfying the predetermined condition. The program according to claim 7, wherein the program is divided into a plurality of areas and embedded. 前記埋め込み手段により前記データは視覚的に判別しづらいように埋め込まれることを特徴とする請求項1乃至8のいずれか1項に記載のプログラム。 The program according to any one of claims 1 to 8, wherein the data is embedded by the embedding means so as to be difficult to visually discriminate. 前記埋め込み手段により前記データが埋め込まれた前記画像をプリンタに印刷させる印刷制御手段として前記コンピュータをさらに機能させることを特徴とする請求項1乃至9のいずれか1項に記載のプログラム。 The program according to any one of claims 1 to 9, wherein the computer further functions as a print control means for causing a printer to print the image in which the data is embedded by the embedding means. 前記埋め込み手段は、前記解析結果と前記プリンタの特性とに応じた位置に、前記データを埋め込むことを特徴とする請求項10に記載のプログラム。 The program according to claim 10, wherein the embedding means embeds the data at a position corresponding to the analysis result and the characteristics of the printer. 前記埋め込み手段は、同一の前記データを前記画像の異なる領域に繰り返し埋め込むことを特徴とする請求項1乃至11のいずれか1項に記載のプログラム。 The program according to any one of claims 1 to 11, wherein the embedding means repeatedly embeds the same data in different regions of the image. 前記埋め込み手段は、前記第1の領域に前記データが埋め込まれ、前記第2の領域には前記データが埋め込まれないように、前記データを前記画像に埋め込むことを特徴とする請求項1乃至12のいずれか1項に記載のプログラム。 Claims 1 to 12 characterized in that the embedding means embeds the data in the image so that the data is embedded in the first region and the data is not embedded in the second region. The program described in any one of the above. 前記第1の領域に関する情報は、前記第1の領域のヘッダ部であることを特徴とする請求項1乃至13のいずれか1項に記載のプログラム。 The program according to any one of claims 1 to 13, wherein the information regarding the first region is a header portion of the first region. 画像に含まれる画素の画素値に所定の変化を与える所定の埋め込み方法に従って、前記画像に対してデータを埋め込むための画像処理装置であって、
前記所定の埋め込み方法に対応する所定の解析方法に従って、前記画像に含まれる画素の画素値に基づく解析を行う解析手段と、
前記画像において、前記所定の変化を与えることが可能な領域を少なくとも含む第1の領域が前記所定の変化を与えることが可能でない第2の領域よりも優先されて前記データが埋め込まれるように、前記画像における、前記解析手段による解析結果に基づく位置に、前記所定の埋め込み方法に従って前記データを埋め込む埋め込み手段と、
前記第1の領域に前記所定の変化を与えることが可能でない領域が含まれる場合、前記第1の領域に関する情報として、前記所定の変化を与えることが可能でない領域の座標を記述する記述手段と、
を有し、
前記第1の領域のうち、前記所定の変化を与えることが可能でない領域には前記データが埋め込まれないように制御されることを特徴とする画像処理装置。
An image processing device for embedding data in an image according to a predetermined embedding method that gives a predetermined change to the pixel values of pixels included in the image.
An analysis means that performs analysis based on the pixel values of the pixels included in the image according to a predetermined analysis method corresponding to the predetermined embedding method.
In the image, the data is embedded so that the first region containing at least the region capable of giving the predetermined change is prioritized over the second region not capable of giving the predetermined change. An embedding means for embedding the data at a position in the image based on the analysis result by the analysis means according to the predetermined embedding method.
When the first region includes a region that cannot give the predetermined change, as information about the first region, a description means for describing the coordinates of the region that cannot give the predetermined change. ,
Have,
An image processing apparatus, characterized in that the data is controlled so as not to be embedded in a region of the first region that cannot be given a predetermined change.
画像に含まれる画素の画素値に所定の変化を与える所定の埋め込み方法に従って、前記画像に対してデータを埋め込むための画像処理方法であって、
前記所定の埋め込み方法に対応する所定の解析方法に従って、前記画像に含まれる画素の画素値に基づく解析を行う解析工程と、
前記画像において、前記所定の変化を与えることが可能な領域を少なくとも含む第1の領域が前記所定の変化を与えることが可能でない第2の領域よりも優先されて前記データが埋め込まれるように、前記画像における、前記解析工程における解析結果に基づく位置に、前記所定の埋め込み方法に従って前記データを埋め込む埋め込み工程と、
前記第1の領域に前記所定の変化を与えることが可能でない領域が含まれる場合、前記第1の領域に関する情報として、前記所定の変化を与えることが可能でない領域の座標を記述する記述工程と、
を有し、
前記第1の領域のうち、前記所定の変化を与えることが可能でない領域には前記データが埋め込まれないように制御されることを特徴とする画像処理方法。
An image processing method for embedding data in an image according to a predetermined embedding method that gives a predetermined change to the pixel values of pixels included in the image.
An analysis step of performing analysis based on the pixel values of the pixels included in the image according to a predetermined analysis method corresponding to the predetermined embedding method, and
In the image, the data is embedded so that the first region containing at least the region capable of giving the predetermined change is prioritized over the second region not capable of giving the predetermined change. An embedding step of embedding the data in the image according to the predetermined embedding method at a position based on the analysis result in the analysis step.
When the first region includes a region that cannot give the predetermined change, the description step of describing the coordinates of the region that cannot give the predetermined change as information regarding the first region. ,
Have,
An image processing method, characterized in that the data is controlled so as not to be embedded in a region of the first region that cannot be given a predetermined change.
JP2017217748A 2017-11-10 2017-11-10 Programs, image processing equipment, and image processing methods Active JP7102128B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2017217748A JP7102128B2 (en) 2017-11-10 2017-11-10 Programs, image processing equipment, and image processing methods

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2017217748A JP7102128B2 (en) 2017-11-10 2017-11-10 Programs, image processing equipment, and image processing methods

Publications (2)

Publication Number Publication Date
JP2019091976A JP2019091976A (en) 2019-06-13
JP7102128B2 true JP7102128B2 (en) 2022-07-19

Family

ID=66836671

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2017217748A Active JP7102128B2 (en) 2017-11-10 2017-11-10 Programs, image processing equipment, and image processing methods

Country Status (1)

Country Link
JP (1) JP7102128B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP7433912B2 (en) 2020-01-06 2024-02-20 キヤノン株式会社 Information processing device, control method for information processing device, program, and storage medium

Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2001024873A (en) 1999-07-05 2001-01-26 Toshiba Corp Printer and information processor
JP2006203787A (en) 2005-01-24 2006-08-03 Toshiba Corp Image processing device, image processing method, and recorded material
JP2007201631A (en) 2006-01-24 2007-08-09 Fuji Xerox Co Ltd Device and method for generating image having watermark, device for analyzing image having watermark, medium, and program
JP2008258814A (en) 2007-04-03 2008-10-23 Konica Minolta Business Technologies Inc Image processor
JP2009124412A (en) 2007-11-14 2009-06-04 Canon Inc Digital watermark embedding method

Patent Citations (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2001024873A (en) 1999-07-05 2001-01-26 Toshiba Corp Printer and information processor
JP2006203787A (en) 2005-01-24 2006-08-03 Toshiba Corp Image processing device, image processing method, and recorded material
JP2007201631A (en) 2006-01-24 2007-08-09 Fuji Xerox Co Ltd Device and method for generating image having watermark, device for analyzing image having watermark, medium, and program
JP2008258814A (en) 2007-04-03 2008-10-23 Konica Minolta Business Technologies Inc Image processor
JP2009124412A (en) 2007-11-14 2009-06-04 Canon Inc Digital watermark embedding method

Also Published As

Publication number Publication date
JP2019091976A (en) 2019-06-13

Similar Documents

Publication Publication Date Title
US9569831B2 (en) Image processing apparatus, image processing method, and non-transitory computer-readable storage medium for extracting information embedded in a printed material
US9602691B2 (en) Image processing apparatus that determines code corresponding to a digital watermark embedded in an image
US10469701B2 (en) Image processing method that obtains special data from an external apparatus based on information multiplexed in image data and apparatus therefor
JP2004140764A (en) Image processing device and method therefor
JP4819723B2 (en) Information extraction apparatus, information extraction method, information extraction program, and recording medium
JP2008099149A (en) Image processor, image processing method and image processing program
US20160080602A1 (en) Image processing apparatus, image processing method, and non-transitory computer-readable storage medium
JP4837101B2 (en) Digital watermark embedding device, digital watermark detection device, and program
EP3422690B1 (en) Information processing apparatus, control method thereof, and program
US10715697B2 (en) Image processing method that determines a number of blocks for embedding information based on a size of an image to be printed, image processing apparatus, and storage medium
JP4595014B2 (en) Digital watermark embedding device and detection device
JP7102128B2 (en) Programs, image processing equipment, and image processing methods
US20190387207A1 (en) Information processing apparatus, information processing system, information processing method, and storage medium
JP2004334852A (en) Image processing by pixel types
JP2020167592A (en) Program, image processing device, and image processing method
JP2007143123A (en) Image processing apparatus, image processing method, image processing program, and recording medium
US10033904B2 (en) Information processing apparatus for multiplexing information in an image, information processing method, and storage medium storing program
US10412265B2 (en) Information processing apparatus that displays a prompt to move the apparatus and information processing method
US8938088B2 (en) Method and apparatus for classifying sections of an image into a plurality of embedded areas
US10764491B2 (en) Image processing apparatus, image processing method, and storage medium
JP2007072852A (en) Image processing device, cellular telephone, image processing method and image processing program
JP5381069B2 (en) Information processing apparatus and program
JP2007036471A (en) Image processing method and image processing apparatus
JP2021103854A (en) Program, image processing apparatus, and image processing method
WO2021126268A1 (en) Neural networks to provide images to recognition engines

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20201109

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20210730

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20210810

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20211008

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20211109

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20220108

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20220315

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20220510

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: 20220607

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20220706

R151 Written notification of patent or utility model registration

Ref document number: 7102128

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R151