JP5927984B2 - Image processing apparatus and image processing program - Google Patents

Image processing apparatus and image processing program Download PDF

Info

Publication number
JP5927984B2
JP5927984B2 JP2012042224A JP2012042224A JP5927984B2 JP 5927984 B2 JP5927984 B2 JP 5927984B2 JP 2012042224 A JP2012042224 A JP 2012042224A JP 2012042224 A JP2012042224 A JP 2012042224A JP 5927984 B2 JP5927984 B2 JP 5927984B2
Authority
JP
Japan
Prior art keywords
pixel
image
pattern
specific
dot
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
JP2012042224A
Other languages
Japanese (ja)
Other versions
JP2013179474A (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.)
Brother Industries Ltd
Original Assignee
Brother Industries Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Brother Industries Ltd filed Critical Brother Industries Ltd
Priority to JP2012042224A priority Critical patent/JP5927984B2/en
Priority to US13/763,983 priority patent/US8855445B2/en
Publication of JP2013179474A publication Critical patent/JP2013179474A/en
Application granted granted Critical
Publication of JP5927984B2 publication Critical patent/JP5927984B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Images

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T3/00Geometric image transformation in the plane of the image
    • G06T3/40Scaling the whole image or part thereof

Description

本発明は、拡大処理を含む画像処理に関する。   The present invention relates to image processing including enlargement processing.

画像処理装置は、元画像を表す元画像データを用いて、元画像の大きさを拡大する拡大処理を実行して、拡大画像データを生成することがある。例えば、印刷を行う際に、当該拡大処理を実行すれば、元画像が比較的小さい場合であっても、比較的大きな印刷画像を印刷することができる。   The image processing apparatus may generate enlarged image data by executing enlargement processing for enlarging the size of the original image using original image data representing the original image. For example, if the enlargement process is executed when printing, a relatively large print image can be printed even if the original image is relatively small.

特開平8−258255号公報JP-A-8-258255 特開2003−319182号公報JP 2003-319182 A

しかしながら、拡大処理を行うと、拡大画像において、エッジの見栄えが損なわれる場合があった。例えば、元画像を横方向に2倍に拡大した拡大画像では、元画像における横方向の1画素分の段差が、2画素分の段差になるので、当該段差を含むエッジは、がたつきが目立つ場合があった。   However, when the enlargement process is performed, the appearance of the edge may be impaired in the enlarged image. For example, in an enlarged image obtained by enlarging the original image twice in the horizontal direction, the step for one pixel in the horizontal direction in the original image becomes a step for two pixels, so that the edge including the step has a rattling. There was a case where it stood out.

本発明の主な利点は、拡大処理後の拡大画像におけるエッジの見栄えを向上することである。   The main advantage of the present invention is to improve the appearance of the edge in the enlarged image after the enlargement process.

本発明は、上述の課題の少なくとも一部を解決するためになされたものであり、以下の適用例として実現することが可能である。   SUMMARY An advantage of some aspects of the invention is to solve at least a part of the problems described above, and the invention can be implemented as the following application examples.

[適用例1]第1種の画素と第2種の画素を含む元画像を表す元画像データであって、前記第1種の画素の色と前記第2種の画素の色との色差は特定基準値以上である、前記元画像データを取得する取得部と、元画像データに対して拡大処理を実行して、前記元画像を第1の方向に拡大した拡大画像を表す拡大画像データを生成する拡大処理部と、を備え、前記拡大処理部は、前記元画像内に前記第1種の画素と前記第2種の画素とによって構成される特定パターンが含まれる場合に、前記拡大画像内の前記第1の方向と交差する第2の方向に延びる画素群を選択する画素群選択部であって、前記拡大画像内の前記画素群は、前記元画像内の特定画素に対応する対応特定画素と、前記対応特定画素の前記第2の方向に位置する画素と、を含み、前記元画像内の前記特定画素は、前記特定パターンを構成する特定の前記第1種の画素に対応する画素であり、前記拡大画像内の前記画素群を構成する画素の数は、第1の連続数と第2の連続数とに応じた数であり、前記第1の連続数は、前記元画像において前記特定画素から前記第2の方向に向かって第1のパターンが連続する数であり、前記第2の連続数は、前記元画像において前記特定画素から前記第2の方向の反対方向に向かって第2のパターンが連続する数である、前記画素群選択部と、前記拡大画像内の前記画素群を構成する画素を、前記第2種の画素に設定する設定部と、を備える、画像処理装置。   Application Example 1 Original image data representing an original image including a first type pixel and a second type pixel, and a color difference between the color of the first type pixel and the color of the second type pixel is An acquisition unit that acquires the original image data that is equal to or greater than a specific reference value, and enlargement image data that represents an enlarged image obtained by enlarging the original image in a first direction by executing enlargement processing on the original image data An enlargement processing unit that generates the enlargement image when the original image includes a specific pattern composed of the first type of pixels and the second type of pixels. A pixel group selecting unit that selects a pixel group extending in a second direction intersecting the first direction, wherein the pixel group in the enlarged image corresponds to a specific pixel in the original image A specific pixel, and a pixel located in the second direction of the corresponding specific pixel. The specific pixel in the original image is a pixel corresponding to the specific first type pixel constituting the specific pattern, and the number of pixels constituting the pixel group in the enlarged image is a first number It is a number according to a continuous number and a second continuous number, and the first continuous number is a number in which the first pattern continues from the specific pixel toward the second direction in the original image. The second continuous number is a number in which the second pattern continues from the specific pixel toward the opposite direction of the second direction in the original image, and in the enlarged image An image processing apparatus comprising: a setting unit that sets the pixels constituting the pixel group of the second group of pixels.

上記構成によれば、元画像の特定パターンを構成する第1種の画素である特定画素に対応する画素を含む拡大画像の画素群を選択し、選択された画素群を第2種の画素に設定する。画素群を構成する画素の数は、第1の連続数と第2の連続数とに応じた数である。この結果、元画像の特定パターンの周囲の画像を考慮して、特定パターンに対応する拡大画像のエッジの見栄えを向上することができる。   According to the above configuration, the pixel group of the enlarged image including the pixel corresponding to the specific pixel which is the first type pixel constituting the specific pattern of the original image is selected, and the selected pixel group is set as the second type pixel. Set. The number of pixels constituting the pixel group is a number corresponding to the first continuous number and the second continuous number. As a result, it is possible to improve the appearance of the edge of the enlarged image corresponding to the specific pattern in consideration of the image around the specific pattern of the original image.

[適用例2]適用例1に記載の画像処理装置であって、前記第1のパターンは、前記第1種の画素である第1の中央画素と、前記第1の中央画素に対して前記第1の方向に隣接する前記第1種の画素である第1隣接画素と、前記第1の中央画素に対して前記第1の方向の反対方向に隣接する前記第2種の画素である第2隣接画素と、を含むパターンであり、前記第2のパターンは、前記第2種の画素である第2の中央画素と、前記第2の中央画素に対して前記第1の方向に隣接する前記第1種の画素である第3隣接画素と、を含むパターンであり、前記第1の中央画素の前記第1の方向の位置と、前記第2の中央画素の前記第1の方向の位置とは、前記元画像内の前記特定画素の前記第1の方向の位置と同じである、画像処理装置。
上記構成によれば、画素群を構成する画素の数を適切に定めることができる。
Application Example 2 In the image processing apparatus according to Application Example 1, the first pattern includes a first central pixel that is the first type of pixel and the first central pixel. A first adjacent pixel that is the first type of pixel adjacent in the first direction and a second type of pixel that is adjacent to the first central pixel in the opposite direction of the first direction. The second pattern is adjacent to the second central pixel, which is the second type of pixel, in the first direction with respect to the second central pixel. And a third adjacent pixel that is the first type of pixel, a position of the first central pixel in the first direction, and a position of the second central pixel in the first direction. Is the same as the position of the specific pixel in the original image in the first direction.
According to the above configuration, the number of pixels constituting the pixel group can be determined appropriately.

[適用例3]適用例1または適用例2に記載の画像処理装置であって、前記第1のパターンは、前記特定パターンの一部である第1部分パターンであり、前記第2のパターンは、前記特定パターンの一部であり、前記第1部分パターンと異なる第2部分パターンである、画像処理装置。
上記構成によれば、見栄えを向上するべきエッジを適切に選んで、当該エッジの見栄えを向上することができる。
Application Example 3 In the image processing apparatus according to Application Example 1 or Application Example 2, the first pattern is a first partial pattern that is a part of the specific pattern, and the second pattern is An image processing apparatus that is a second partial pattern that is a part of the specific pattern and is different from the first partial pattern.
According to the above configuration, it is possible to appropriately select an edge whose appearance is to be improved and improve the appearance of the edge.

[適用例4]適用例1ないし適用例3のいずれかに記載の画像処理装置であって、前記特定パターンは、前記特定画素に対して前記第2の方向に隣接する第1部分パターンと、前記特定画素に対して前記第2の方向の反対方向に隣接する第2部分パターンと、を含み、前記第1部分パターンは、前記特定画素に対して前記第2の方向に隣接する中央画素と、前記中央画素に対して前記第1の方向に隣接する前記第1種の画素である第1周辺画素と、前記中央画素に対して前記第1の方向の反対方向に隣接する前記第2種の画素である第2周辺画素と、を含むパターンであり、前記第2部分パターンは、前記特定画素に対して前記第2の方向の反対方向に隣接する前記第2種の画素である第3周辺画素と、前記第3周辺画素に対して前記第1の方向に隣接する前記第1種の画素である第4周辺画素と、を含むパターンである、画像処理装置。
上記構成によれば、見栄えを向上するべきエッジを適切に選んで、当該エッジの見栄えを向上することができる。
Application Example 4 In the image processing device according to any one of Application Example 1 to Application Example 3, the specific pattern includes a first partial pattern adjacent to the specific pixel in the second direction; A second partial pattern adjacent to the specific pixel in a direction opposite to the second direction, and the first partial pattern includes a central pixel adjacent to the specific pixel in the second direction A first peripheral pixel that is the first type of pixel adjacent to the central pixel in the first direction, and the second type of pixel adjacent to the central pixel in a direction opposite to the first direction. A second peripheral pixel that is a pixel of the second type, and the second partial pattern is a second type of pixel that is adjacent to the specific pixel in a direction opposite to the second direction. The first pixel with respect to the peripheral pixel and the third peripheral pixel; A fourth peripheral pixel is the first type of pixels adjacent to the direction, a pattern including the image processing apparatus.
According to the above configuration, it is possible to appropriately select an edge whose appearance is to be improved and improve the appearance of the edge.

[適用例5]適用例1ないし適用例4のいずれかに記載の画像処理装置であって、前記拡大処理部は、前記第1の連続数が前記第2の連続数より多い場合には、前記画素群を構成する画素の数を、前記第2の連続数を用いて決定し、前記第1の連続数が前記第2の連続数より小さい場合には、前記画素群を構成する画素の数を、前記第1の連続数を用いて決定する決定部を備える、画像処理装置。
上記構成によれば、画素群を構成する画素の数を適切に決定することができる。
Application Example 5 In the image processing device according to any one of Application Example 1 to Application Example 4, in the case where the enlargement processing unit has the first continuous number larger than the second continuous number, The number of pixels constituting the pixel group is determined using the second continuous number, and when the first continuous number is smaller than the second continuous number, the number of pixels constituting the pixel group is determined. An image processing apparatus comprising: a determination unit that determines a number using the first continuous number.
According to the above configuration, the number of pixels constituting the pixel group can be appropriately determined.

[適用例6]適用例1ないし適用例5のいずれかに記載の画像処理装置であって、前記拡大処理部は、前記元画像を構成する複数の画素の中から順次に対象画素を選択する対象画素選択部を備え、前記拡大処理部は、前記対象画素が選択される度に、第1処理と第2処理とを含む複数の処理のうちのいずれかを実行することによって、前記拡大画像データを生成し、前記第1処理は、前記対象画素が前記特定画素を含む場合に実行される処理であって、前記画素群選択部による前記画素群の選択と、前記設定部による前記画素群を構成する画素の設定と、を含む処理であり、前記第2処理は、前記対象画素が前記特定画素を含まない場合に実行される処理であって、前記画素群選択部による前記画素群の選択と、前記設定部による前記画素群を構成する画素の設定と、を含まない処理である、画像処理装置。
上記構成によれば、エッジの見栄えを向上できる拡大画像データを容易に作成することができる。
Application Example 6 In the image processing device according to any one of Application Examples 1 to 5, the enlargement processing unit sequentially selects a target pixel from among a plurality of pixels constituting the original image. A target pixel selection unit, and the enlargement processing unit executes any one of a plurality of processes including a first process and a second process each time the target pixel is selected, thereby the enlarged image Data is generated, and the first process is a process executed when the target pixel includes the specific pixel, wherein the pixel group is selected by the pixel group selection unit, and the pixel group is set by the setting unit. The second process is a process executed when the target pixel does not include the specific pixel, and the pixel group is selected by the pixel group selection unit. Selection and the pixel group by the setting unit Setting the pixels constituting a process that does not include the image processing apparatus.
According to the above configuration, enlarged image data that can improve the appearance of the edge can be easily created.

[適用例7]適用例1ないし適用例6のいずれかに記載の画像処理装置であって、前記拡大処理部は、歪みのない前記元画像に対して前記拡大処理を実行して、歪みのある前記拡大画像を表す前記拡大画像データを生成し、前記画像処理装置は、ドット画像を印刷する印刷実行部のための装置であり、前記画像処理装置は、さらに、前記拡大処理部によって生成された歪みのある前記拡大画像を表す前記拡大画像データに対して、画素毎にドットの形成状態を表すドットデータを生成するハーフトーン処理を実行して、歪みのある歪ドット画像を表す歪ドットデータを生成するハーフトーン処理部と、前記歪ドットデータに対して前記拡大処理とは異なる処理を実行して、前記歪ドット画像を少なくとも前記第2の方向に拡大した歪みのない無歪ドット画像を表す無歪ドットデータを生成するドット画像拡大部と、を備える、画像処理装置。
上記構成によれば、無歪ドット画像を印刷するためのハーフトーン処理の処理量を低減できるとともに、印刷された無歪ドット画像において、エッジの見栄えを向上することができる。
Application Example 7 In the image processing apparatus according to any one of Application Example 1 to Application Example 6, the enlargement processing unit performs the enlargement process on the original image without distortion so as to reduce distortion. The enlarged image data representing the enlarged image is generated, and the image processing device is a device for a print execution unit that prints a dot image, and the image processing device is further generated by the enlargement processing unit. Dot data representing a distorted dot image by executing a halftone process for generating dot data representing a dot formation state for each pixel on the enlarged image data representing the enlarged image having a distorted distortion A halftone processing unit that generates the image and a process different from the enlargement process on the distorted dot data, and the distortion dot image is expanded at least in the second direction without distortion Comprising a dot image enlargement unit that generates a strain-free dot data representing the distortion dot image, the image processing apparatus.
According to the above configuration, the amount of halftone processing for printing an undistorted dot image can be reduced, and the appearance of the edge can be improved in the printed undistorted dot image.

[適用例8]適用例7に記載の画像処理装置であって、前記無歪ドット画像は、同一行の組を複数個含み、前記同一行の組は、前記無歪ドット画像を構成する前記第1の方向に沿った複数の行のうち、互いに隣接するとともに、各構成画素のドットの形成状態が互いに同一である2以上の行を含む組であり、前記無歪ドットデータは、前記同一行の組を表す圧縮データを含み、前記圧縮データは、1つの代表行を表す代表行データと、前記代表行データが繰り返されることを示すデータと、を含む、画像処理装置。
上記構成によれば、無歪ドットデータのデータ量を低減することができる。
Application Example 8 In the image processing device according to Application Example 7, the undistorted dot image includes a plurality of sets of the same row, and the set of the same row configures the undistorted dot image. Among the plurality of rows along the first direction, the set includes two or more rows that are adjacent to each other and in which the dot formation state of each constituent pixel is the same, and the undistorted dot data is the same An image processing apparatus including compressed data representing a set of rows, wherein the compressed data includes representative row data representing one representative row and data indicating that the representative row data is repeated.
According to the above configuration, the data amount of undistorted dot data can be reduced.

[適用例9]適用例1ないし適用例8のいずれかに記載の画像処理装置であって、前記拡大処理部は、前記元画像において前記特定パターンを検出する検出部を備え、前記拡大処理部は、検出された前記特定パターンについて、前記画素群選択部による前記画素群の選択と、前記設定部による前記画素群を構成する画素の設定と、を実行する、画像処理装置。   Application Example 9 In the image processing apparatus according to any one of Application Examples 1 to 8, the enlargement processing unit includes a detection unit that detects the specific pattern in the original image, and the enlargement processing unit An image processing apparatus that executes the selection of the pixel group by the pixel group selection unit and the setting of the pixels constituting the pixel group by the setting unit for the detected specific pattern.

[適用例10]適用例1ないし適用例8のいずれかに記載の画像処理装置であって、前記拡大処理部は、前記拡大画像において、前記元画像の前記特定パターンに対応する対応特定パターンを検出する検出部を備え、前記拡大処理部は、検出された前記対応特定パターンについて、前記画素群選択部による前記画素群の選択と、前記設定部による前記画素群を構成する画素の設定と、を実行する、画像処理装置。   [Application Example 10] The image processing apparatus according to any one of Application Examples 1 to 8, wherein the enlargement processing unit displays a corresponding specific pattern corresponding to the specific pattern of the original image in the enlarged image. A detection unit for detecting, the enlargement processing unit, for the detected correspondence specific pattern, the selection of the pixel group by the pixel group selection unit, the setting of the pixels constituting the pixel group by the setting unit, An image processing apparatus that executes

本発明は、種々の形態で実現することが可能であり、例えば、上記装置の機能を実現する方法、上記装置の機能を実現するコンピュータプログラム、当該コンピュータプログラムを記録した記録媒体、等の形態で実現することができる。   The present invention can be realized in various forms, for example, in the form of a method for realizing the function of the device, a computer program for realizing the function of the device, a recording medium on which the computer program is recorded, and the like. Can be realized.

実施例の計算装置100と印刷装置200のブロック図。1 is a block diagram of a computing device 100 and a printing device 200 according to an embodiment. 画像処理のフローチャート。The flowchart of an image process. 画像処理を説明する概念図。The conceptual diagram explaining image processing. 圧縮処理のフローチャート。The flowchart of a compression process. 圧縮ドットデータ300を概念的に示す図。The figure which shows the compression dot data 300 notionally. ディザマトリクスDM1を示す図。The figure which shows dither matrix DM1. ディザマトリクスDM1のスクリーン角度について説明する図。The figure explaining the screen angle of dither matrix DM1. 無歪ドット画像GD2に表れるスクリーン角度を説明する図。The figure explaining the screen angle which appears in the undistorted dot image GD2. 横方向拡大処理(図2:S600)のフローチャート。The flowchart of a horizontal direction expansion process (FIG. 2: S600). 実施例の横方向拡大処理における特定パターンとカウント用パターンについて説明する図。The figure explaining the specific pattern and the pattern for a count in the horizontal direction expansion process of an Example. エッジ補完処理のフローチャート。The flowchart of an edge complementation process. エッジ補完処理について説明する図。The figure explaining an edge complementation process. 拡大画像における補完画素の配置例を示す図。The figure which shows the example of arrangement | positioning of the complementary pixel in an enlarged image. 拡大画像における補完画素の配置例を示す図。The figure which shows the example of arrangement | positioning of the complementary pixel in an enlarged image. 実施例の印刷画像のエッジと比較例の印刷画像のエッジを示す図。The figure which shows the edge of the printing image of an Example, and the edge of the printing image of a comparative example. 縦方向拡大処理における特定パターンとカウント用パターンについて説明する図。The figure explaining the specific pattern and the pattern for a count in a vertical direction expansion process. 変形例における横方向拡大処理のフローチャート。The flowchart of the horizontal direction expansion process in a modification. 変形例の横方向拡大処理における特定パターンとカウント用パターンについて説明する図。The figure explaining the specific pattern and the pattern for counting in the horizontal direction expansion process of a modification.

A.実施例:
A−1:計算装置100と印刷装置200の構成
本発明の実施の形態を実施例に基づき説明する。図1は、実施例の画像処理装置としての計算装置100と、印刷装置200のブロック図である。
A. Example:
A-1: Configuration of Computing Device 100 and Printing Device 200 An embodiment of the present invention will be described based on examples. FIG. 1 is a block diagram of a computing device 100 as an image processing device and a printing device 200 according to an embodiment.

計算装置100は、印刷装置200と通信可能に接続されたコンピュータ(例えば、パーソナルコンピュータ)である。計算装置100は、CPU110と、ROMやRAMなどの内部記憶装置120と、ハードディスクなどの外部記憶装置130と、キーボードやマウスなどの操作部170と、液晶ディスプレイなどの表示部180と、外部装置(例えば、印刷装置200)との通信のためのインタフェースを含む通信部190とを備えている。   The computing device 100 is a computer (for example, a personal computer) that is communicably connected to the printing device 200. The computing device 100 includes a CPU 110, an internal storage device 120 such as a ROM and a RAM, an external storage device 130 such as a hard disk, an operation unit 170 such as a keyboard and a mouse, a display unit 180 such as a liquid crystal display, and an external device ( For example, a communication unit 190 including an interface for communication with the printing apparatus 200) is provided.

外部記憶装置130は、本実施例の画像処理プログラムとしてのドライバプログラム132と、図示しないアプリケーションプログラムによって作成された画像データ134とを格納している。   The external storage device 130 stores a driver program 132 as an image processing program of the present embodiment and image data 134 created by an application program (not shown).

CPU110は、ドライバプログラム132を実行することによって、プリンタドライバM10の機能を実現する。プリンタドライバM10は、画像データ取得部M12と、拡大処理部M14と、ハーフトーン処理部M16と、ドット画像拡大部M18と、圧縮部M19とを備え、本実施例の画像処理(後述)を実行する。拡大処理部M14は、対象画素選択部M141と、パターン検出部M142と、連続数決定部M143と、画素群選択部M144と、画素データ設定部M145とを備える。   The CPU 110 implements the function of the printer driver M10 by executing the driver program 132. The printer driver M10 includes an image data acquisition unit M12, an enlargement processing unit M14, a halftone processing unit M16, a dot image enlargement unit M18, and a compression unit M19, and executes image processing (described later) of this embodiment. To do. The enlargement processing unit M14 includes a target pixel selection unit M141, a pattern detection unit M142, a continuation number determination unit M143, a pixel group selection unit M144, and a pixel data setting unit M145.

印刷装置200は、集積回路210と、プリンタエンジン250と、各種のボタンやタッチパネルなどの操作部270と、液晶パネルなどの表示部280と、外部機器(例えば、計算装置100)との通信のためのインタフェースを含む通信部290と、を備えている。   The printing apparatus 200 communicates with the integrated circuit 210, the printer engine 250, an operation unit 270 such as various buttons and a touch panel, a display unit 280 such as a liquid crystal panel, and an external device (for example, the computing device 100). And a communication unit 290 including the interface.

集積回路210は、例えば、ASIC(Application Specific Integrated Circuit)であり、制御回路212と、DRAMなどの揮発性メモリ214と、マスクROMやEEPROMなどの不揮発性メモリ216を含んでいる。揮発性メモリ214は、制御回路212が用いるバッファ領域を提供する。不揮発性メモリ216は、制御回路212が参照する制御データ、プログラムなどを格納している。制御回路212は、印刷装置200の全体を制御する装置制御部M20として機能する。なお、揮発性メモリ214や不揮発性メモリ216の全部または一部は、集積回路210の外部に設けられていても良い。   The integrated circuit 210 is, for example, an ASIC (Application Specific Integrated Circuit), and includes a control circuit 212, a volatile memory 214 such as a DRAM, and a nonvolatile memory 216 such as a mask ROM or an EEPROM. The volatile memory 214 provides a buffer area used by the control circuit 212. The nonvolatile memory 216 stores control data, programs, and the like that are referred to by the control circuit 212. The control circuit 212 functions as an apparatus control unit M20 that controls the entire printing apparatus 200. Note that all or part of the volatile memory 214 and the nonvolatile memory 216 may be provided outside the integrated circuit 210.

プリンタエンジン250は、装置制御部M20(集積回路210)の制御および装置制御部M20から供給される印刷データに従って、印刷を行う機構部である。プリンタエンジン250は、例えば、印刷材として黒色のトナーを用いて印刷媒体にドット画像を印刷するモノクロレーザープリンタとしての機能を実現する。すなわち、プリンタエンジン250は、レーザを用いて感光体を露光する露光工程と、露光によって感光体に形成された静電潜像にトナーを感光体に付着させる現像工程と、現像されたトナー像を感光体から印刷媒体に転写する転写工程と、転写されたトナー像を印刷媒体に定着させる定着工程と、を実現する。装置制御部M20とプリンタエンジン250との全体は、印刷実行部の例である。   The printer engine 250 is a mechanism unit that performs printing in accordance with the control of the device control unit M20 (integrated circuit 210) and the print data supplied from the device control unit M20. The printer engine 250 realizes a function as a monochrome laser printer that prints a dot image on a printing medium using black toner as a printing material, for example. In other words, the printer engine 250 exposes the photosensitive member using a laser, a developing step for attaching toner to the electrostatic latent image formed on the photosensitive member by exposure, and the developed toner image. A transfer process for transferring from the photoreceptor to the print medium and a fixing process for fixing the transferred toner image on the print medium are realized. The entire apparatus control unit M20 and the printer engine 250 are examples of a print execution unit.

プリンタドライバM10の機能を実現するドライバプログラム132や、装置制御部M20の機能を実現するプログラムは、コンピュータ読み取り可能な記録媒体に格納された形で提供され得る。   The driver program 132 that realizes the function of the printer driver M10 and the program that realizes the function of the apparatus control unit M20 may be provided in a form stored in a computer-readable recording medium.

A−2:プリンタドライバM10の画像処理:
図2は、計算装置100のプリンタドライバM10によって実行される画像処理のフローチャートである。この画像処理は、画像データ134を用いて印刷装置200に供給する印刷データを生成する処理である。プリンタドライバM10は、例えば、ユーザの印刷指示に応じて、画像処理を開始する。
A-2: Image processing of printer driver M10:
FIG. 2 is a flowchart of image processing executed by the printer driver M10 of the computing device 100. This image processing is processing for generating print data to be supplied to the printing apparatus 200 using the image data 134. For example, the printer driver M10 starts image processing in response to a user's print instruction.

ステップS100では、プリンタドライバM10の画像データ取得部M12は、処理対象の画像データ(対象画像データ)を取得する。対象画像データは、例えば、上述した画像データ134(図1)であり、当該画像データ134を作成したアプリケーションプログラムから取得される。対象画像データは、当該画像データを作成したアプリケーションプログラムごとに異なるデータ形式を有している。   In step S100, the image data acquisition unit M12 of the printer driver M10 acquires image data to be processed (target image data). The target image data is, for example, the above-described image data 134 (FIG. 1), and is acquired from the application program that created the image data 134. The target image data has a different data format for each application program that created the image data.

ステップS200では、画像データ取得部M12は、対象画像データを、RGB画素データで構成されたビットマップデータ(RGB画像データ)に変換するラスタライズ処理を実行する。RGB画素データは、RGBの各色成分の階調値(例えば、256階調)を含む。   In step S200, the image data acquisition unit M12 executes rasterization processing for converting the target image data into bitmap data (RGB image data) composed of RGB pixel data. The RGB pixel data includes gradation values (for example, 256 gradations) of RGB color components.

ステップS300では、画像データ取得部M12は、RGB画像データを、黒(K)成分の濃度を表す単色画素データで構成されたビットマップデータ(単色画像データ)に変換する(モノクロ変換処理)。本実施例では、単色画素データは、0〜255の範囲の階調値であり、階調値「0」は白を表し、階調値「255」は黒を表し、中間階調値は階調数が大きいほど濃度が高いグレーを表す。具体的には、画像データ取得部M12は、例えば、RGB画素データの輝度値Yを算出する。画像データ取得部M12は、輝度値Yを、ルックアップテーブルを用いて単色画素データに変換する。   In step S300, the image data acquisition unit M12 converts the RGB image data into bitmap data (monochrome image data) composed of monochrome pixel data representing the density of the black (K) component (monochrome conversion processing). In the present embodiment, the monochrome pixel data is a gradation value in the range of 0 to 255, the gradation value “0” represents white, the gradation value “255” represents black, and the intermediate gradation value represents a gradation value. The higher the logarithm, the higher the density of gray. Specifically, the image data acquisition unit M12 calculates a luminance value Y of RGB pixel data, for example. The image data acquisition unit M12 converts the luminance value Y into single-color pixel data using a lookup table.

ステップS400では、画像データ取得部M12は、生成された単色画像データが表す単色画像が縦長の画像(ポートレイト)であるか否か、すなわち、縦方向の画素数に対する横方向の画素数比Sが1より小さい画像であるか否かを判断する。画像データ取得部M12は、単色画像が縦長の画像でない、すなわち、横長の画像(ランドスケープ)であると判断した場合には(ステップS400:NO)、単色画像を90度回転する回転処理を実行して、縦長の単色画像を表す単色画像データを生成する(ステップS500)。画像データ取得部M12は、単色画像が縦長の画像であると判断した場合には(ステップS400:YES)、ステップS600に処理を進める。   In step S400, the image data acquisition unit M12 determines whether or not the monochrome image represented by the generated monochrome image data is a vertically long image (portrait), that is, the ratio of the number of pixels in the horizontal direction to the number of pixels in the vertical direction. It is determined whether or not the image is smaller than 1. If the image data acquisition unit M12 determines that the monochrome image is not a portrait image, that is, a landscape image (landscape) (step S400: NO), the image data acquisition unit M12 performs a rotation process that rotates the monochrome image by 90 degrees. Thus, monochrome image data representing a vertically long monochrome image is generated (step S500). If the image data acquisition unit M12 determines that the single-color image is a vertically long image (step S400: YES), the process proceeds to step S600.

図3は、画像処理を説明する概念図である。図3(A)には、単色画像データによって表される単色画像PG1(90度回転処理が行われる場合には、回転処理後の単色画像PG1)が示されている。本実施例の単色画像PG1の大きさ(画素数)は、縦3407画素×横2380画素である。単色画像PG1の画素数比Sは、約0.70である。画素数比Sは、縦方向の画素数に対する横方向の画素数の比である。   FIG. 3 is a conceptual diagram illustrating image processing. FIG. 3A shows a monochromatic image PG1 represented by monochromatic image data (a monochromatic image PG1 after the rotation process when the 90-degree rotation process is performed). The size (number of pixels) of the monochromatic image PG1 of this embodiment is 3407 pixels long × 2380 pixels wide. The pixel number ratio S of the monochrome image PG1 is about 0.70. The pixel number ratio S is the ratio of the number of pixels in the horizontal direction to the number of pixels in the vertical direction.

ステップS600では、プリンタドライバM10の拡大処理部M14は、単色画像データに対して、単色画像PG1の横方向の大きさを2倍に拡大する(横方向の画素数を2倍に増やす)横方向拡大処理を実行する。横方向拡大処理によって、拡大単色画像PG2を表す拡大単色画像データが生成される。図3(B)には、拡大単色画像PG2が示されている。横方向拡大処理の具体的な処理内容については後述する。   In step S600, the enlargement processing unit M14 of the printer driver M10 doubles the size of the monochrome image PG1 in the horizontal direction with respect to the monochrome image data (increases the number of pixels in the horizontal direction by 2). Execute the enlargement process. By the horizontal enlargement process, enlarged monochrome image data representing the enlarged monochrome image PG2 is generated. FIG. 3B shows an enlarged monochromatic image PG2. Specific processing contents of the horizontal enlargement processing will be described later.

拡大単色画像PG2の横方向の画素数は、単色画像PG1の横方向の画素数の2倍になり、図3(B)の例では、4760画素になる。拡大単色画像PG2の縦方向の画素数は、3407画素であり、単色画像PG1の縦方向の画素数と同じである。すなわち、拡大単色画像PG2の画素数比S2は、単色画像PG1の画素数比Sの2倍、図3(B)の例では、約1.40になる。ここで、図3(A)(B)に示すように、拡大単色画像PG2は、歪みのない単色画像PG1を歪ませた歪みのある画像となる。以下では、単色画像PG1を無歪画像PG1とも呼び、拡大単色画像PG2を歪画像PG2とも呼ぶ。また、無歪画像PG1を表す単色画像データを無歪画像データとも呼び、歪画像PG2を表す拡大単色画像データを歪画像データとも呼ぶ。   The number of pixels in the horizontal direction of the enlarged monochrome image PG2 is twice the number of pixels in the horizontal direction of the monochrome image PG1, and is 4760 pixels in the example of FIG. The number of pixels in the vertical direction of the enlarged monochrome image PG2 is 3407 pixels, which is the same as the number of pixels in the vertical direction of the monochrome image PG1. That is, the pixel number ratio S2 of the enlarged monochrome image PG2 is twice the pixel number ratio S of the monochrome image PG1, and is about 1.40 in the example of FIG. Here, as shown in FIGS. 3A and 3B, the enlarged single-color image PG2 is a distorted image obtained by distorting the single-color image PG1 without distortion. Hereinafter, the monochromatic image PG1 is also referred to as an undistorted image PG1, and the enlarged monochromatic image PG2 is also referred to as a distorted image PG2. Further, the monochrome image data representing the undistorted image PG1 is also referred to as undistorted image data, and the enlarged monochrome image data representing the strained image PG2 is also referred to as strain image data.

ステップS700では、プリンタドライバM10のハーフトーン処理部M16は、取得された歪画像データに対してハーフトーン処理を実行する。ハーフトーン処理は、ディザマトリクスDM1(図5:後述)を用いて、画素毎にドットの形成状態を表すドットデータを生成する処理である。具体的には、ドットデータを構成する各画素データは、対応する画素がドットを形成することを表す「1」と、対応する画素がドットを形成しないことを表す「0」と、のいずれかの値を取る二値データである。本ステップのハーフトーン処理によって、歪画像PG2(図3(B))に対応する歪みのある歪ドット画像GD1を表す歪ドットデータが生成される。図3(C)には、歪ドット画像GD1の一例が示されている。歪ドット画像GD1の縦方向の画素数および横方向の画素数は、歪画像PG2の縦方向の画素数および横方向の画素数と同じである。したがって、歪ドット画像GD1の画素数比も、歪画像PG2の画素数比S2と同じである。   In step S700, the halftone processing unit M16 of the printer driver M10 performs halftone processing on the acquired distorted image data. The halftone process is a process for generating dot data representing a dot formation state for each pixel using a dither matrix DM1 (FIG. 5: described later). Specifically, each pixel data constituting the dot data is either “1” indicating that the corresponding pixel forms a dot, or “0” indicating that the corresponding pixel does not form a dot. It is binary data that takes the value of. By the halftone process of this step, distorted dot data representing a distorted dot image GD1 corresponding to the distorted image PG2 (FIG. 3B) is generated. FIG. 3C shows an example of the distorted dot image GD1. The number of pixels in the vertical direction and the number of pixels in the horizontal direction of the distorted dot image GD1 are the same as the number of pixels in the vertical direction and the number of pixels in the horizontal direction of the distorted image PG2. Therefore, the pixel number ratio of the distorted dot image GD1 is also the same as the pixel number ratio S2 of the distorted image PG2.

ステップS800では、プリンタドライバM10のドット画像拡大部M18は、歪ドットデータに対してドット画像拡大処理を実行して、歪のない無歪ドット画像GD2を表す無歪ドットデータを生成する。図3(D)には、無歪ドット画像GD2の一例が示されている。   In step S800, the dot image enlargement unit M18 of the printer driver M10 performs dot image enlargement processing on the distorted dot data to generate undistorted dot data representing the undistorted dot image GD2 without distortion. FIG. 3D shows an example of the undistorted dot image GD2.

具体的には、ドット画像拡大部M18は、歪ドットデータを構成するn番目の行データと、(n+1)番目の行データとの間に、n番目の行データのコピーデータを挿入することによって、無歪ドットデータを生成する。したがって、無歪ドットデータにおいて、奇数行データと、当該奇数行データの次の偶数行データとは、同一のデータになる。したがって、図3(C)(D)に示すように、無歪ドットデータが表す無歪ドット画像GD2の(2n−1)番目の行の各画素PX2を表す各画素データと2n番目の行の各画素PX2を表す各画素データは、同じデータ(歪ドット画像GD1のn番目の行の各画素PX2を表す各画素データ)となる。また、無歪ドットデータが表す無歪ドット画像GD2の(2n+1)番目の行の各画素PX2を表す各画素データと(2n+2)番目の行の各画素PX2を表す各画素データは、同じデータ(歪ドット画像GD1の(n+1)番目の行の各画素PX2を表す各画素データ)となる。   Specifically, the dot image enlargement unit M18 inserts copy data of the nth row data between the nth row data constituting the distorted dot data and the (n + 1) th row data. Generates undistorted dot data. Accordingly, in the undistorted dot data, the odd-numbered row data and the even-numbered row data next to the odd-numbered row data are the same data. Therefore, as shown in FIGS. 3C and 3D, each pixel data representing each pixel PX2 in the (2n-1) th row of the undistorted dot image GD2 represented by the undistorted dot data and each of the 2nth row Each pixel data representing each pixel PX2 is the same data (each pixel data representing each pixel PX2 in the nth row of the distorted dot image GD1). Each pixel data representing each pixel PX2 in the (2n + 1) th row of the undistorted dot image GD2 represented by the undistorted dot data and each pixel data representing each pixel PX2 in the (2n + 2) th row are the same data ( Each pixel data representing each pixel PX2 in the (n + 1) th row of the distorted dot image GD1.

無歪ドット画像GD2の縦方向の画素数は、歪ドット画像GD1および無歪画像PG1および歪画像PG2の縦方向の画素数の2倍である(例えば、6814画素)。無歪ドット画像GD2の横方向の画素数は、歪ドット画像GD1および歪画像PG2の横方向の画素数と同じであり、無歪画像PG1の横方向の画素数の2倍である(例えば、4760画素)。したがって、無歪ドット画像GD2の画素数比は、無歪画像PG1の画素数比Sと同じであり、歪画像PG2および歪ドット画像GD1の画素数比S2の1/2である。   The number of pixels in the vertical direction of the undistorted dot image GD2 is twice the number of pixels in the vertical direction of the strained dot image GD1, the undistorted image PG1, and the distorted image PG2 (for example, 6814 pixels). The number of pixels in the horizontal direction of the undistorted dot image GD2 is the same as the number of pixels in the horizontal direction of the distorted dot image GD1 and the distorted image PG2, and is twice the number of pixels in the horizontal direction of the undistorted image PG1 (for example, 4760 pixels). Therefore, the pixel number ratio of the undistorted dot image GD2 is the same as the pixel number ratio S of the undistorted image PG1, and is ½ of the pixel number ratio S2 of the distorted image PG2 and the distorted dot image GD1.

ここで、無歪ドット画像GD2の(2n−1)番目の行と2n番目の行の組のように、無歪ドット画像を構成する複数の行のうち、互いに隣接するとともに、各構成画素のドットの形成状態(ドットデータを構成する画素データの画素値)が互いに同一である2以上の行の組を、同一行の組とも呼ぶ。また、無歪ドットデータに含まれる、同一行の組を表す行データの組を、同一行データの組とも呼ぶ。無歪ドット画像GD2の縦方向の画素数(行数)をNとすると、無歪ドット画像GD2は、(N/2)個の同一行の組を含む。   Here, as in the set of the (2n-1) th row and the 2nth row of the undistorted dot image GD2, the plurality of rows constituting the undistorted dot image are adjacent to each other, and A set of two or more rows having the same dot formation state (pixel value of pixel data constituting the dot data) is also referred to as a set of the same row. In addition, a set of row data representing a set of the same row included in the undistorted dot data is also referred to as a set of the same row data. When the number of pixels (number of rows) in the vertical direction of the undistorted dot image GD2 is N, the undistorted dot image GD2 includes a set of (N / 2) identical rows.

ステップS900では、プリンタドライバM10の圧縮部M19は、無歪ドットデータを圧縮する圧縮処理を実行して圧縮ドットデータ300を生成する。図4は、圧縮処理のフローチャートである。図5は、圧縮ドットデータ300を概念的に示す図である。   In step S900, the compression unit M19 of the printer driver M10 generates a compressed dot data 300 by executing a compression process for compressing the undistorted dot data. FIG. 4 is a flowchart of the compression process. FIG. 5 is a diagram conceptually showing the compressed dot data 300.

ステップS902では、圧縮部M19は、処理対象である無歪ドットデータが表す無歪ドット画像GD2を構成する行を順次に(具体的には、図3(D)の上から順に)処理対象行として選択する。ステップS904では、圧縮部M19は、処理対象行の行データ(処理対象行データ)が、前回の処理対象行データと同一か否かを判断する。この例では、奇数番目の行が処理対象行である場合には、処理対象行データと、前回の処理対象行データとは同一ではない。一方、偶数番目の行が処理対象行である場合には、処理対象行データと、前回の処理対象行データとは同一である。   In step S902, the compression unit M19 sequentially processes the rows constituting the undistorted dot image GD2 represented by the undistorted dot data to be processed (specifically, from the top in FIG. 3D). Choose as. In step S904, the compression unit M19 determines whether the row data of the processing target row (processing target row data) is the same as the previous processing target row data. In this example, when the odd-numbered row is a processing target row, the processing target row data and the previous processing target row data are not the same. On the other hand, when the even-numbered row is a processing target row, the processing target row data is the same as the previous processing target row data.

圧縮部M19は、処理対象行データが、前回の処理対象行データと同一でないと判断すると(ステップS904:NO)、「OFF」の参照フラグを表す参照フラグデータを生成する(ステップS906)。ステップS908では、圧縮部M19は、圧縮行データと、圧縮行データのデータ量を表すデータ量データを生成する。圧縮部M19は、処理対象行データを、ランレングス圧縮によって圧縮して、圧縮行データを生成する。   When the compression unit M19 determines that the processing target row data is not the same as the previous processing target row data (step S904: NO), the compression unit M19 generates reference flag data representing a reference flag of “OFF” (step S906). In step S908, the compression unit M19 generates compressed row data and data amount data representing the data amount of the compressed row data. The compression unit M19 compresses the processing target row data by run length compression to generate compressed row data.

圧縮部M19は、処理対象行データが、前回の処理対象行データと同一であると判断すると(ステップS904:YES)、「ON」の参照フラグを表す参照フラグデータを生成する(ステップS910)。   When the compression unit M19 determines that the processing target row data is the same as the previous processing target row data (step S904: YES), the compression unit M19 generates reference flag data representing a reference flag of “ON” (step S910).

ステップS912では、圧縮部M19は、処理対象である無歪ドットデータが表す無歪ドット画像GD2を構成する全ての行を処理対象行として選択したか否かを判断する。圧縮部M19は、全ての行が処理対象行として選択されていない場合には(ステップS912:NO)、ステップS902に戻って、未選択の行を新たな処理選択行として、ステップS904〜S910の処理を繰り返す。圧縮部M19は、全ての行が処理対象行として選択されている場合には(ステップS912:YES)、圧縮処理を終了する。   In step S912, the compression unit M19 determines whether or not all the rows constituting the undistorted dot image GD2 represented by the undistorted dot data to be processed are selected as the processing target rows. If all the rows have not been selected as processing target rows (step S912: NO), the compression unit M19 returns to step S902, sets the unselected rows as new processing selection rows, and performs steps S904 to S910. Repeat the process. When all the rows have been selected as processing target rows (step S912: YES), the compression unit M19 ends the compression processing.

図5に示すように、圧縮処理によって生成される圧縮ドットデータ300は、無歪ドット画像GD2の各行を表すデータを含む。奇数行を表すデータ(例えば、図5:1行目および3行目のデータ)は、「OFF」の参照フラグデータ310Aと、データ量データ320と、圧縮行データ330とを含む。偶数行を表すデータ(例えば、図5:2行目および4行目のデータ)は、「ON」の参照フラグデータ310Bを含む。「OFF」の参照フラグデータ310Aは、その後に、データ量データ320と、データ量データ320が表すデータ量の圧縮行データ330とが続くことを示すフラグである。「ON」の参照フラグデータ310Bは、直前の圧縮行データ330で表される行が繰り返されることを示すデータである。このように、同一のデータによって表される行が繰り返されるときには、繰り返される行のうち、2番目以降の行を表す行データを、直前の行データを参照することを示す情報(「ON」の参照フラグデータ310B)に置き換えることによって、ドットデータを圧縮する。この圧縮処理を「前参照圧縮処理」とも呼ぶ。   As shown in FIG. 5, the compressed dot data 300 generated by the compression process includes data representing each row of the undistorted dot image GD2. The data representing the odd-numbered rows (for example, data in the first row and the third row in FIG. 5) includes “OFF” reference flag data 310A, data amount data 320, and compressed row data 330. Data representing even lines (for example, data in the second and fourth lines in FIG. 5) includes reference flag data 310B of “ON”. The “OFF” reference flag data 310 </ b> A is a flag indicating that the data amount data 320 and the compressed row data 330 having the data amount represented by the data amount data 320 follow thereafter. The “ON” reference flag data 310B is data indicating that the line represented by the immediately preceding compressed line data 330 is repeated. As described above, when the rows represented by the same data are repeated, information indicating that the row data representing the second and subsequent rows among the repeated rows is referred to the immediately preceding row data ("ON"). The dot data is compressed by replacing it with the reference flag data 310B). This compression processing is also referred to as “pre-reference compression processing”.

以上の説明から解るように、奇数行を表すデータ310A、320、330と、当該奇数行の次の偶数行を表すデータ310Bとの組は、上述した同一行の組を表す圧縮データであり、上述した同一行データの組を圧縮した圧縮データである。同一行の組を表す圧縮データは、1つの代表行を表す代表行データ(この例では、奇数行を表すデータ310A、320、330)と、代表行データが繰り返されることを表すデータ(この例では、偶数行を表すデータ310B)との組を含むデータであると言うことができる。   As understood from the above description, the set of the data 310A, 320, 330 representing the odd rows and the data 310B representing the even rows next to the odd rows is the compressed data representing the set of the same rows described above. This is compressed data obtained by compressing the set of the same row data described above. The compressed data representing a set of the same row includes representative row data representing one representative row (in this example, data 310A, 320, 330 representing odd rows) and data representing that the representative row data is repeated (in this example) Then, it can be said that the data includes a set with data 310B) representing an even-numbered row.

図2のステップS1000では、プリンタドライバM10は、生成された圧縮ドットデータ300に、各種のプリンタ制御コードや、データ識別コードを付加して、印刷装置200の装置制御部M20(図1)が解釈可能な印刷データを生成する。ステップS1100では、プリンタドライバM10は、生成された印刷データを、印刷装置200に対して送信して、処理を終了する。   In step S1000 of FIG. 2, the printer driver M10 adds various printer control codes and data identification codes to the generated compressed dot data 300, and the apparatus control unit M20 (FIG. 1) of the printing apparatus 200 interprets them. Generate possible print data. In step S1100, the printer driver M10 transmits the generated print data to the printing apparatus 200, and ends the process.

印刷データを受信した印刷装置200の装置制御部M20(集積回路210)は、印刷データを揮発性メモリ214に格納する。装置制御部M20は、印刷データに含まれる圧縮ドットデータ300を所定量ずつ(例えば、特定行数分ずつ)復元しながら順次にプリンタエンジン250に供給することによって、無歪ドット画像GD2を印刷する。   The apparatus control unit M20 (integrated circuit 210) of the printing apparatus 200 that has received the print data stores the print data in the volatile memory 214. The apparatus control unit M20 prints the undistorted dot image GD2 by sequentially supplying the compressed dot data 300 included in the print data to the printer engine 250 while restoring it by a predetermined amount (for example, by a specific number of rows). .

A−3.ディザマトリクスDM1:
図6は、ディザマトリクスDM1を示す図である。ディザマトリクスDM1は、歪ドット画像GD1の各画素(図3(C))に対応する升PM1を縦8行×横16列(計128個)に並べて構成されている。ディザマトリクスDM1は、縦2個×横4個=8個のサブマトリクスCE1を含み、各サブマトリクスは、それぞれ縦4行×横4列の16個の升PM1を含んでいる。各升PM1には、閾値TH1が規定されている。図6の各升PM1の内部に示した番号は、各升PM1に設定されている閾値TH1を示している。この例では、128個の閾値TH1は、入力される階調値の取り得る範囲(例えば、0〜255)の全体に略均等に分布するように設定されている。この結果、このディザマトリクスDM1を用いて生成された歪ドットデータが表す歪ドット画像GD1は、縦8画素×横16画素の範囲で、128階調を表現することができる。
A-3. Dither matrix DM1:
FIG. 6 shows the dither matrix DM1. The dither matrix DM1 is configured by arranging 升 PM1 corresponding to each pixel (FIG. 3C) of the distorted dot image GD1 in 8 rows × 16 columns (128 in total). The dither matrix DM1 includes 2 vertical × 4 horizontal = 8 sub-matrixes CE1, and each sub-matrix includes 16 rows PM1 of 4 rows × 4 columns. A threshold TH1 is defined for each bag PM1. The numbers shown inside each bag PM1 in FIG. 6 indicate the threshold value TH1 set for each bag PM1. In this example, the 128 threshold values TH1 are set so as to be distributed substantially evenly over the entire range (for example, 0 to 255) that the input gradation value can take. As a result, the distorted dot image GD1 represented by the distorted dot data generated using the dither matrix DM1 can express 128 gradations in the range of 8 pixels vertically × 16 pixels horizontally.

図7は、ディザマトリクスDM1のスクリーン角度について説明する図である。図7の模式図は、ディザマトリクスDM1の升PM1のうち、閾値TH1が112以下である升PM1に対応する領域にハッチングを付し、閾値TH1が112より大きい升PM1に対応する領域を白色とした図である。また、この図7は、ディザマトリクスDM1を用いて生成された歪ドットデータが表す歪ドット画像GD1に表れる部分歪ドット画像PGD1を示しているとも言える。すなわち、部分歪ドット画像PGD1は、階調値が122である単色画素データで構成された一定濃度の画像領域に対して、ハーフトーン処理を行ったドットデータに対応している。   FIG. 7 is a diagram for explaining the screen angle of the dither matrix DM1. In the schematic diagram of FIG. 7, among the 升 PM1 of the dither matrix DM1, a region corresponding to 升 PM1 having a threshold TH1 of 112 or less is hatched, and a region corresponding to 升 PM1 having a threshold TH1 greater than 112 is white. FIG. FIG. 7 can also be said to show a partially distorted dot image PGD1 that appears in the distorted dot image GD1 represented by the distorted dot data generated using the dither matrix DM1. That is, the partially distorted dot image PGD1 corresponds to dot data obtained by performing halftone processing on an image area having a constant density composed of single-color pixel data having a gradation value of 122.

図7に示す部分歪ドット画像PGD1から解るように、歪ドット画像GD1には、ディザマトリクスDM1におけるサブマトリクスCE1に対応するドットの集合DT1が表れる。図7に示す実線DL1から解るように、歪ドット画像GD1には、複数のドットDT1が繋がってできる複数のドットラインが表れる。このドットラインの角度は、ディザマトリクスDM1のスクリーン角度を表している。一般的に、スクリーン角度φは、反時計回りに、3時の方向(図6の右方向)からドットラインまでの角度で表される。この例では、スクリーン角度φは、約26.56度である。ドットラインは、スクリーン角度の方向に沿って、複数のドットによって形成されるラインである。   As can be seen from the partially distorted dot image PGD1 shown in FIG. 7, in the distorted dot image GD1, a set of dots DT1 corresponding to the sub-matrix CE1 in the dither matrix DM1 appears. As can be seen from the solid line DL1 shown in FIG. 7, a plurality of dot lines formed by connecting a plurality of dots DT1 appear in the distorted dot image GD1. The angle of this dot line represents the screen angle of the dither matrix DM1. Generally, the screen angle φ is represented counterclockwise by the angle from the 3 o'clock direction (right direction in FIG. 6) to the dot line. In this example, the screen angle φ is about 26.56 degrees. A dot line is a line formed by a plurality of dots along the direction of the screen angle.

図8は、印刷される無歪ドット画像GD2に表れるスクリーン角度を説明する図である。図8は、図7に示す部分歪ドット画像PGD1に対応する無歪ドット画像GD2の領域(部分無歪ドット画像PGD2とも呼ぶ)を示している。   FIG. 8 is a diagram for explaining a screen angle appearing in the undistorted dot image GD2 to be printed. FIG. 8 shows a region of the undistorted dot image GD2 (also referred to as a partially undistorted dot image PGD2) corresponding to the partially distorted dot image PGD1 shown in FIG.

図8に示す部分無歪ドット画像PGD2から解るように、無歪ドット画像GD2に表れるドットの集合DT2は、歪ドット画像GD1に表れる対応するドットの集合DT1(図7)を縦方向に2倍に拡大した形状になる。図8に示す実線DL2から解るように、無歪ドット画像GD2には、複数のドットが繋がってできる複数のドットラインが表れる。このドットラインの角度、すなわち、印刷される無歪ドット画像GD2に表れるスクリーン角度をθとする。この例では、スクリーン角度θは、約45度である。   As can be seen from the partial undistorted dot image PGD2 shown in FIG. 8, the set of dots DT2 appearing in the undistorted dot image GD2 is twice the corresponding set of dots DT1 (FIG. 7) appearing in the distorted dot image GD1 in the vertical direction. The shape is enlarged. As can be seen from the solid line DL2 shown in FIG. 8, the undistorted dot image GD2 has a plurality of dot lines formed by connecting a plurality of dots. The angle of this dot line, that is, the screen angle appearing in the undistorted dot image GD2 to be printed is defined as θ. In this example, the screen angle θ is about 45 degrees.

ところで、ディザマトリクスDM1のスクリーン角度φ(歪ドット画像GD1に表れるスクリーン角度)の正接(tanφ)は、TL1/YL1である。ここで、TL1は、歪ドット画像GD1の複数のドットラインの横方向の周期(図7の例では、4画素(4升)分の長さ)である。YL1は、歪ドット画像GD1の複数のドットラインの横方向の周期(図7の例では、8画素(8升)分の長さ)である。そして、無歪ドット画像GD2に表れるスクリーン角度θの正接(tanθ)=TL2/YL2である。ここで、TL2は、無歪ドット画像GD2の複数のドットラインの横方向の周期(図8の例では、8画素(8升)分の長さ)である。YL2は、無歪ドット画像GD2の複数のドットラインの横方向の周期(図8の例では、8画素(8升)分の長さ)である。そして、TL2=2×TL1であり、YL1=YL2であるから、tanφ=(tanθ)/2である。従って、ディザマトリクスDM1のスクリーン角度φは、約arctan((tanθ)/2)に設定されている、と言うことができる。   Incidentally, the tangent (tan φ) of the screen angle φ (screen angle appearing in the distorted dot image GD1) of the dither matrix DM1 is TL1 / YL1. Here, TL1 is the horizontal period of the plurality of dot lines of the distorted dot image GD1 (in the example of FIG. 7, a length corresponding to 4 pixels (4 升)). YL1 is a horizontal period of the plurality of dot lines of the distorted dot image GD1 (in the example of FIG. 7, a length corresponding to 8 pixels (8 cm)). Then, the tangent (tan θ) of the screen angle θ appearing in the undistorted dot image GD2 is TL2 / YL2. Here, TL2 is a horizontal period of the plurality of dot lines of the undistorted dot image GD2 (in the example of FIG. 8, a length corresponding to 8 pixels (8 cm)). YL2 is a period in the horizontal direction of a plurality of dot lines of the undistorted dot image GD2 (in the example of FIG. 8, a length corresponding to 8 pixels (8 cm)). Since TL2 = 2 × TL1 and YL1 = YL2, tan φ = (tan θ) / 2. Therefore, it can be said that the screen angle φ of the dither matrix DM1 is set to about arctan ((tan θ) / 2).

歪ドット画像GD1の複数のドットラインのライン間隔Lは、cosφ×TL1で表される。また、無歪ドット画像GD2の複数のドットラインのライン間隔Dは、cosθ×TL2で表される。したがって、歪ドット画像GD1の複数のドットラインのライン間隔Lは、L=(1/2)×D×cosφ/cosθに設定されている、と言うことができる。ここで、上述の通り、φ=arctan((tanθ)/2)である。本実施例では、ディザマトリクスDM1の1つの升PM1に対応するドット画像の画素を単位として、歪ドット画像GD1のライン間隔L=約3.16画素、無歪ドット画像GD2のライン間隔D=約5.66画素である。   A line interval L between a plurality of dot lines of the distorted dot image GD1 is represented by cosφ × TL1. Further, the line interval D of the plurality of dot lines of the undistorted dot image GD2 is represented by cos θ × TL2. Therefore, it can be said that the line interval L of the plurality of dot lines of the distorted dot image GD1 is set to L = (1/2) × D × cos φ / cos θ. Here, as described above, φ = arctan ((tan θ) / 2). In the present embodiment, the line interval L of the distorted dot image GD1 is approximately 3.16 pixels and the line interval D of the undistorted dot image GD2 is approximately equal to about a dot image pixel corresponding to one 升 PM1 of the dither matrix DM1. 5.66 pixels.

印刷される無歪ドット画像GD2に表れるスクリーン角度θや、無歪ドット画像GD2の複数のドットラインのライン間隔Dに基づいて定まる線数(単位はLpi(line per inch))は、公知のスクリーンゲージを用いて、印刷された無歪ドット画像GD2を測定することによって、容易に認識することができる。   The screen angle θ appearing in the undistorted dot image GD2 to be printed and the number of lines (unit: Lpi (line per inch)) determined based on the line spacing D of a plurality of dot lines of the undistorted dot image GD2 are known screens. It can be easily recognized by measuring the printed undistorted dot image GD2 using a gauge.

A−4.横方向拡大処理:
図9は、横方向拡大処理(図2:S600)のフローチャートである。上述したように、横方向拡大処理は、無歪画像PG1を表す無歪画像データに対して実行される処理である。横方向拡大処理の結果、無歪画像PG1の横方向の大きさを2倍に拡大した(横方向の画素数を2倍に増やした)歪画像PG2を表す歪画像データが生成される。横方向処理の説明では、無歪画像PG1を元画像とも呼び、無歪画像データを元画像データとも呼ぶ。また、歪画像PG2を拡大画像とも呼び、歪画像データを拡大画像データとも呼ぶ。この横方向拡大処理は、単純に、元画像の横方向の大きさを2倍に拡大するだけでなく、拡大画像のエッジの見栄えを向上するために、拡大画像に補完画素を追加する処理(エッジ補完処理)を含んでいる。
A-4. Horizontal enlargement processing:
FIG. 9 is a flowchart of the horizontal enlargement process (FIG. 2: S600). As described above, the horizontal enlargement process is a process executed on undistorted image data representing the undistorted image PG1. As a result of the horizontal enlargement process, distorted image data representing the distorted image PG2 in which the size of the undistorted image PG1 in the horizontal direction is doubled (the number of pixels in the horizontal direction is doubled) is generated. In the description of the horizontal processing, the undistorted image PG1 is also referred to as an original image, and the undistorted image data is also referred to as original image data. The distorted image PG2 is also referred to as an enlarged image, and the distorted image data is also referred to as enlarged image data. In this horizontal enlargement process, not only the horizontal size of the original image is doubled, but also a complementary pixel is added to the enlarged image in order to improve the appearance of the edge of the enlarged image ( Edge complement processing).

ステップS605では、拡大処理部M14の対象画素選択部M141は、元画像(無歪画像PG1)を構成する画素の中から処理対象とする対象画素SPを順次に1つずつ選択する。具体的には、本処理では、図3(A)に示す無歪画像PG1の上端の行(左右方向の画素行)から順に、下方に向かって処理対象とする。同じ行の中では、左端の画素から、右に向かって順次に処理対象とする。   In step S605, the target pixel selection unit M141 of the enlargement processing unit M14 sequentially selects the target pixels SP to be processed one by one from the pixels constituting the original image (undistorted image PG1). Specifically, in this processing, the processing target is set downward from the top row (pixel row in the left-right direction) of the undistorted image PG1 shown in FIG. In the same row, processing is sequentially performed from the leftmost pixel toward the right.

ステップS610では、拡大処理部M14は、対象画素SPの画素値(画素データ)を用いて、対象画素SPは白画素であるか否かを判断する。上述したように、無歪画像PGAを構成する画素の画素値(単色画素データ)は、階調数が大きいほど濃度が高い(黒に近い)無彩色を表す。ここで、白画素は、例えば、画素値が、0または比較的0に近い値の画素値を有する画素、具体的には、画素値が白画素判定用基準値(例えば、5)以下の画素である。すなわち、白画素は、例えば、画素値が、0〜5のいずれかである画素である。なお、後述する黒画素は、例えば、画素値が、255または比較的255に近い値の画素値を有する画素、具体的には、画素値が黒画素判定用基準値(例えば、250)以上の画素である。すなわち、黒画素は、例えば、画素値が、250〜255のいずれかである画素である。なお、黒画素および白画素を除く画素(例えば、画素値が6以上249以下である画素)を灰色画素とも呼ぶ。   In step S610, the enlargement processing unit M14 determines whether the target pixel SP is a white pixel using the pixel value (pixel data) of the target pixel SP. As described above, the pixel value (monochromatic pixel data) of the pixels constituting the undistorted image PGA represents an achromatic color having a higher density (closer to black) as the number of gradations increases. Here, the white pixel is, for example, a pixel having a pixel value of 0 or a value relatively close to 0, specifically, a pixel having a pixel value equal to or less than a white pixel determination reference value (for example, 5). It is. That is, a white pixel is a pixel whose pixel value is any one of 0-5, for example. Note that a black pixel described later is, for example, a pixel having a pixel value having a pixel value of 255 or relatively close to 255, specifically, a pixel value equal to or greater than a black pixel determination reference value (for example, 250). Pixel. That is, a black pixel is a pixel whose pixel value is any one of 250-255, for example. A pixel excluding a black pixel and a white pixel (for example, a pixel having a pixel value of 6 or more and 249 or less) is also referred to as a gray pixel.

対象画素SPが白画素でないと判断すると(ステップS610:NO)、拡大処理部M14は、対象画素SPに対応する拡大画像内の画素(対応対象画素)TPは未設定であるか否かを判断する。元画像の対象画素SPの座標を(Xa、Ya)とすると、拡大画像の対応対象画素TPの座標は、(2Xa、Ya)と(2Xa+1、Ya)である。なお、元画像(無歪画像PG1(図3(A))の座標と、拡大画像(歪画像PG2(図3(B))の座標は、ともに、画像の左上を原点(0、0)とし、右方向をX軸の正方向、下方向をY軸の正方向とした座標(単位は画素)を用いる。   If it is determined that the target pixel SP is not a white pixel (step S610: NO), the enlargement processing unit M14 determines whether or not the pixel (corresponding target pixel) TP in the enlarged image corresponding to the target pixel SP is not set. To do. If the coordinates of the target pixel SP of the original image are (Xa, Ya), the coordinates of the corresponding target pixel TP of the enlarged image are (2Xa, Ya) and (2Xa + 1, Ya). The coordinates of the original image (undistorted image PG1 (FIG. 3A)) and the coordinate of the enlarged image (distorted image PG2 (FIG. 3B)) are both set to the origin (0, 0) at the upper left of the image. The coordinates (unit is pixel) are used with the right direction as the positive direction of the X axis and the downward direction as the positive direction of the Y axis.

拡大処理部M14は、対応対象画素TPが未設定でない(設定済みである)と判断すると(ステップS615:NO)、ステップS635に処理を進める。拡大処理部M14は、対応対象画素TPが未設定であると判断すると(ステップS615:YES)、未設定である2つの対応対象画素TPの画素値を、それぞれ対象画素SPの画素値と同じ値に設定する(対応対象画素TPの画素データを生成する)。   If the enlargement processing unit M14 determines that the corresponding target pixel TP is not set (set) (step S615: NO), the process proceeds to step S635. When the enlargement processing unit M14 determines that the corresponding target pixel TP has not been set (step S615: YES), the pixel values of the two corresponding target pixels TP that have not been set are the same as the pixel values of the target pixel SP, respectively. (Pixel data of the corresponding target pixel TP is generated).

上述したステップS610にて、拡大処理部M14は、対象画素SPが白画素であると判断すると(ステップS610:YES)、拡大処理部M14のパターン検出部M142は、元画像において、対象画素SPとその周辺画素とは、後述する4種類の特定パターン1〜4のいずれかを形成するか否かを判断する(ステップS625)。   When the enlargement processing unit M14 determines that the target pixel SP is a white pixel in step S610 described above (step S610: YES), the pattern detection unit M142 of the enlargement processing unit M14 determines that the target pixel SP is the same as the target pixel SP. With respect to the peripheral pixels, it is determined whether or not any of four types of specific patterns 1 to 4 to be described later is formed (step S625).

図10は、本実施例の横方向拡大処理における特定パターンとカウント用パターンについて説明する図である。図10に示すように、4種類の特定パターン1〜4は、それぞれ縦3×横3の計9個の画素で構成される。   FIG. 10 is a diagram for explaining the specific pattern and the counting pattern in the horizontal enlargement process of the present embodiment. As shown in FIG. 10, the four types of specific patterns 1 to 4 are each composed of a total of nine pixels of 3 × 3.

特定パターン1は、横方向に並んだ3つの画素で構成される中央部分パターンMP1と、中央部分パターンMP1の上方向に隣接する上部分パターンUP1と、中央部分パターンMP1の下方向に隣接する下部分パターンBP1とを含む。   The specific pattern 1 includes a central part pattern MP1 composed of three pixels arranged in the horizontal direction, an upper part pattern UP1 that is adjacent to the upper part of the central part pattern MP1, and a lower part that is adjacent to the lower part of the central part pattern MP1. And a partial pattern BP1.

中央部分パターンMP1は、白画素である中央画素と、この中央画素に対して右方向に隣接する白画素である右隣接画素と、この中央画素に対して左方向に隣接する黒画素である左隣接画素とを含む。上部分パターンUP1は、中央部分パターンMP1と同じく、白画素である中央画素と、この中央画素に対して右方向に隣接する白画素である右隣接画素と、この中央画素に対して左方向に隣接する黒画素である左隣接画素とを含む。下部分パターンBP1は、黒画素である中央画素と、この中央画素に対して右方向に隣接する白画素である右隣接画素とを含む。なお、下部分パターンBP1において、中央画素に対して左方向に隣接する画素(図10:「any」の文字が記された画素)は任意の画素(白画素または黒画素または灰色画素のいずれか)であって良い。   The central partial pattern MP1 is a white pixel, a central pixel that is a white pixel, a right adjacent pixel that is a white pixel adjacent to the central pixel in the right direction, and a black pixel that is adjacent to the central pixel in the left direction. Adjacent pixels. Similar to the central partial pattern MP1, the upper partial pattern UP1 is a central pixel that is a white pixel, a right adjacent pixel that is a white pixel adjacent to the central pixel in the right direction, and a left direction relative to the central pixel. And a left adjacent pixel which is an adjacent black pixel. The lower part pattern BP1 includes a central pixel that is a black pixel and a right adjacent pixel that is a white pixel adjacent to the central pixel in the right direction. In the lower partial pattern BP1, the pixel adjacent to the center pixel in the left direction (FIG. 10: the pixel with the letters “any”) is any pixel (white pixel, black pixel, or gray pixel). )

中央部分パターンMP1における中央画素(図10においてバツ印が付された白画素)を、特定パターン1の中心画素とも呼ぶ。パターン検出部M142は、対象画素SPを中心画素として、対象画素SPとその周辺画素が特定パターンに該当するか否かを判断する。なお、図10において、クロスハッチングされた画素は、黒画素を表し、ハッチングがされていない画素およびバツ印が付された画素(中心画素)は、白画素を表す。   A central pixel (white pixel marked with a cross in FIG. 10) in the central partial pattern MP1 is also referred to as a central pixel of the specific pattern 1. The pattern detection unit M142 determines whether the target pixel SP and its peripheral pixels correspond to the specific pattern with the target pixel SP as the central pixel. In FIG. 10, the cross-hatched pixel represents a black pixel, and the non-hatched pixel and the cross-hatched pixel (center pixel) represent a white pixel.

特定パターン2、3、4は、それぞれ、中心画素を含む中央部分パターンMP2、MP3、MP4と、中央部分パターンMP2、MP3、MP4の上方向に隣接する上部分パターンUP2、UP3、UP4と、中央部分パターンMP2、MP3、MP4の下方向に隣接する下部分パターンBP2、BP3、BP4と、を含む。図10に示すように、特定パターン2は、特定パターン1を上下に反転したパターンであり、特定パターン3は、特定パターン1を左右に反転したパターンであり、特定パターン4は、特定パターン3を上下に反転したパターンである。   The specific patterns 2, 3, and 4 are respectively the center partial patterns MP 2, MP 3, and MP 4 including the central pixel, and the upper partial patterns UP 2, UP 3, and UP 4 that are adjacent in the upper direction of the central partial patterns MP 2, MP 3, and MP 4 The lower partial patterns BP2, BP3, and BP4 that are adjacent in the lower direction of the partial patterns MP2, MP3, and MP4 are included. As shown in FIG. 10, the specific pattern 2 is a pattern obtained by inverting the specific pattern 1 up and down, the specific pattern 3 is a pattern obtained by inverting the specific pattern 1 left and right, and the specific pattern 4 The pattern is inverted up and down.

対象画素SPとその周辺画素が、特定パターン1〜4のいずれかを形成しない場合には(ステップS625:NO)、拡大処理部M14の画素データ設定部M145は、上述したステップS615、620の処理を行う。すなわち、画素データ設定部M145は、対象画素SPに対応する対応対象画素TPが未設定であれば、対応対象画素TPの画素値を、対象画素SPの画素値と同じ値に設定して、ステップS635に処理を進める。   When the target pixel SP and its surrounding pixels do not form any of the specific patterns 1 to 4 (step S625: NO), the pixel data setting unit M145 of the enlargement processing unit M14 performs the processing of steps S615 and 620 described above. I do. That is, if the corresponding target pixel TP corresponding to the target pixel SP is not set, the pixel data setting unit M145 sets the pixel value of the corresponding target pixel TP to the same value as the pixel value of the target pixel SP. The process proceeds to S635.

対象画素SPとその周辺画素が、特定パターン1〜4のいずれかを形成する場合には(ステップS625:YES)、拡大処理部M14は、エッジ補完処理を実行する(ステップS630)。   When the target pixel SP and its surrounding pixels form any one of the specific patterns 1 to 4 (step S625: YES), the enlargement processing unit M14 performs an edge complement process (step S630).

図11は、エッジ補完処理のフローチャートである。ステップS6305では、連続数決定部M143は、対象画素SPとその周辺画素によって形成される特定パターンに応じて、連続数をカウントするためのカウント用パターンをそれぞれ設定する。図10には、特定パターン1〜4のそれぞれに対応するカウント用パターンが図示されている。カウント用パターンは、第1の連続数CLをカウントするための第1のパターンLCPと、第2の連続数CUをカウントするための第2のパターンUCPとを含んでいる。   FIG. 11 is a flowchart of edge complement processing. In step S6305, the continuous number determination unit M143 sets a counting pattern for counting the continuous number according to a specific pattern formed by the target pixel SP and its peripheral pixels. FIG. 10 shows the counting patterns corresponding to the specific patterns 1 to 4, respectively. The counting pattern includes a first pattern LCP for counting the first continuous number CL and a second pattern UCP for counting the second continuous number CU.

第1のパターンLCPは、対応する特定パターンに含まれる3つの部分パターンのうち、中心画素に対して第1の連続数CLのカウント方向CD1(図10:後述)に隣接する部分パターンと同じパターンである。第2のパターンUCPは、対応する特定パターンに含まれる3つの部分パターンのうち、中心画素に対して第2の連続数CUのカウント方向CD2(図10:後述)に隣接する部分パターンと同じパターンである。例えば、図10に示すように、特定パターン1に対応する第1のパターンLCP1は、特定パターン1の上部分パターンUP1と同じであり、特定パターン1に対応する第2のパターンUCP1は、特定パターン1の下部分パターンBP1と同じである。特定パターン2に対応する第1のパターンLCP2は、特定パターン2の下部分パターンBP2と同じであり、特定パターン2に対応する第2のパターンUCP2は、特定パターン2の上部分パターンUP2と同じである。   The first pattern LCP is the same pattern as the partial pattern adjacent to the central pixel in the count direction CD1 (FIG. 10: described later) with respect to the center pixel among the three partial patterns included in the corresponding specific pattern. It is. The second pattern UCP is the same pattern as the partial pattern adjacent to the central pixel in the count direction CD2 (FIG. 10: described later) of the second consecutive number CU among the three partial patterns included in the corresponding specific pattern. It is. For example, as shown in FIG. 10, the first pattern LCP1 corresponding to the specific pattern 1 is the same as the upper pattern UP1 of the specific pattern 1, and the second pattern UCP1 corresponding to the specific pattern 1 is the specific pattern 1 is the same as the lower part pattern BP1. The first pattern LCP2 corresponding to the specific pattern 2 is the same as the lower part pattern BP2 of the specific pattern 2, and the second pattern UCP2 corresponding to the specific pattern 2 is the same as the upper part pattern UP2 of the specific pattern 2 is there.

より具体的には、特定パターン1に対応する第1のパターンLCP1は、特定パターン1の中心画素が位置する縦方向の画素列に位置する中央画素(白画素)と、この中央画素に対して右方向に隣接する右隣接画素(白画素)と、この中央画素に対して左方向に隣接する左隣接画素(黒画素)とを含む。すなわち、第1のパターンLCP1の中央画素(白画素)の左右方向の位置は、特定パターン1の中心画素の左右方向の位置と同じである。特定パターン1に対応する第2のパターンUCP1は、特定パターン1の中心画素が位置する縦方向の画素列に位置する中央画素(黒画素)と、この中央画素に対して右方向に隣接する右隣接画素(白画素)とを含む。すなわち、第2のパターンLCP2の中央画素(黒画素)の左右方向の位置は、特定パターン1の中心画素の左右方向の位置と同じである。なお、この第2のパターンUCP1において、中央画素に対して左方向に隣接する画素(図10:「any」の文字が記された画素)は任意の画素(白画素または黒画素または灰色画素のいずれか)であって良い。ここで、この例では、第1のパターンLCP1の画素数(3画素)と、第2のパターンLCP2の画素数(3画素)は、同じであるが、異なっていても良い。例えば、第2のパターンLCP2は、「any」の文字が記された画素を除いた2画素で構成されても良い。   More specifically, the first pattern LCP1 corresponding to the specific pattern 1 includes a central pixel (white pixel) located in a vertical pixel row where the central pixel of the specific pattern 1 is located, and the central pixel. A right adjacent pixel (white pixel) adjacent in the right direction and a left adjacent pixel (black pixel) adjacent in the left direction with respect to the center pixel are included. That is, the horizontal position of the center pixel (white pixel) of the first pattern LCP1 is the same as the horizontal position of the center pixel of the specific pattern 1. The second pattern UCP1 corresponding to the specific pattern 1 includes a central pixel (black pixel) located in the vertical pixel row where the central pixel of the specific pattern 1 is located, and a right adjacent to the central pixel in the right direction. Adjacent pixels (white pixels). That is, the horizontal position of the central pixel (black pixel) of the second pattern LCP2 is the same as the horizontal position of the central pixel of the specific pattern 1. In the second pattern UCP1, a pixel adjacent to the center pixel in the left direction (FIG. 10: a pixel on which “any” is written) is an arbitrary pixel (a white pixel, a black pixel, or a gray pixel). Either). Here, in this example, the number of pixels of the first pattern LCP1 (3 pixels) and the number of pixels of the second pattern LCP2 (3 pixels) are the same, but they may be different. For example, the second pattern LCP2 may be composed of two pixels excluding the pixels on which the characters “any” are written.

ステップS6310では、連続数決定部M143は、カウント用パターン(第1のパターンLCPおよび第2のパターンUCP)を用いて、第1の連続数CLと第2の連続数CUとをカウントする。第1の連続数CLは、対象画素SPから、カウント方向CD1に向かって第1のパターンLCPが連続する数である。第2の連続数CUは、対象画素SPから、カウント方向CD2に向かって第2のパターンUCPが連続する数である。カウント方向CD1とカウント方向CD2との組み合わせは、4種類の特定パターンごとに、定められている。カウント方向CD1とカウント方向CD2とは互いに逆方向である。図10に示すように、特定パターン1の場合には、カウント方向CD1は、上向きであり、カウント方向CD2は、下向きである。特定パターン2の場合は、カウント方向CD1は、下向きであり、カウント方向CD2は、上向きである。   In step S6310, the continuous number determining unit M143 counts the first continuous number CL and the second continuous number CU using the counting pattern (first pattern LCP and second pattern UCP). The first continuous number CL is a number in which the first pattern LCP continues from the target pixel SP in the count direction CD1. The second continuous number CU is a number in which the second pattern UCP continues from the target pixel SP toward the count direction CD2. A combination of the count direction CD1 and the count direction CD2 is determined for each of four types of specific patterns. The count direction CD1 and the count direction CD2 are opposite to each other. As shown in FIG. 10, in the case of the specific pattern 1, the count direction CD1 is upward and the count direction CD2 is downward. In the case of the specific pattern 2, the count direction CD1 is downward, and the count direction CD2 is upward.

図12は、エッジ補完処理について説明する図である。図12(A)に示すように、対象画素SPを中心とする縦3画素×横3画素の領域ARが特定パターン2を形成している場合を例に説明する。この場合には、第1の連続数CL=3となり、第2の連続数CU=4である。   FIG. 12 is a diagram for explaining edge complement processing. As shown in FIG. 12A, an example will be described in which a specific pattern 2 is formed in an area AR of 3 vertical pixels × 3 horizontal pixels centering on the target pixel SP. In this case, the first continuous number CL = 3 and the second continuous number CU = 4.

ステップS6315では、連続数決定部M143は、第1の連続数CLと第2の連続数CUの少なくとも一方は、1であるか否かを判断する。連続数決定部M143は、第1の連続数CLと第2の連続数CUの少なくとも一方が、1である場合には(ステップS6315:YES)、連続数決定部M143は、補完数SCを1に決定する。連続数決定部M143は、第1の連続数CLと第2の連続数CUの両方が、1でない場合には(ステップS6315:NO)、第1の連続数CLは、第2の連続数CUより大きいか否かを判断する(ステップS6325)。   In step S6315, the continuous number determination unit M143 determines whether or not at least one of the first continuous number CL and the second continuous number CU is one. When at least one of the first continuous number CL and the second continuous number CU is 1 (step S6315: YES), the continuous number determining unit M143 sets the complementary number SC to 1 To decide. If both the first continuous number CL and the second continuous number CU are not 1 (step S6315: NO), the continuous number determining unit M143 determines that the first continuous number CL is the second continuous number CU. It is determined whether it is larger (step S6325).

連続数決定部M143は、第1の連続数CLが、第2の連続数CUより大きいと判断した場合には(ステップS6325:YES)、補完数SCを、(第2の連続数CU−1)個に決定する(ステップS6330)。連続数決定部M143は、第1の連続数CLが、第2の連続数CU以下であると判断した場合には(ステップS6325:NO)、補完数SCを、(第1の連続数CL/2(ただし、2で割り切れない場合は四捨五入によって整数値とする))に決定する(ステップS6335)。   When the continuous number determination unit M143 determines that the first continuous number CL is larger than the second continuous number CU (step S6325: YES), the complementary number SC is set to (second continuous number CU-1). ) (Step S6330). When the continuous number determination unit M143 determines that the first continuous number CL is equal to or smaller than the second continuous number CU (step S6325: NO), the complementary number SC is set to (first continuous number CL / 2 (however, if it is not divisible by 2, it is rounded off to be an integer value)) (step S6335).

図12(A)に示す例では、第1の連続数CL<第2の連続数CUである。この場合には、第1の連続数CL/2=3/2=1.5であるから、四捨五入されて、補完数SC=2に決定される。   In the example shown in FIG. 12A, the first continuous number CL <the second continuous number CU. In this case, since the first continuous number CL / 2 = 3/2 = 1.5, it is rounded off to determine the complement number SC = 2.

補完数SCが決定されると、拡大処理部M14は、補完画素を含む画素の画素値を設定する(ステップS6340)。具体的には、拡大処理部M14の画素群選択部M144は、拡大画像において設定対象の画素群SCPを選択する。図12(B)には、画素群SCPの例が示されている。画素群SCPは、対象画素SP(座標(Xa、Ya))に対応する1組の対応対象画素TP(座標(2Xa、Ya)、(2Xa+1、Ya))を含む。さらに、補完数SCが2以上である場合には、画素群SCPは、一方の対応対象画素TP(座標(2Xa、Ya)から補完方向SDに連続する(SC−1)個の画素と、他方の対応対象画素TP(座標(2Xa+1、Ya)から補完方向SDに連続する(SC−1)個の画素とを含む。つまり、画素群SCPは、横方向に並ぶ2個の画素の組がSC個分、2×SC個の画素を含む。補完方向SDは、図10に示すように、4種類の特定パターンごとに、定められている。補完方向SDは、第1の連続数CLのカウント方向CD1と同じ方向であり、第2の連続数CUのカウント方向CD2の反対方向である。図12(B)の例では、補完数SC=2であり、画素群SCPは、座標(2Xa、Ya)、(2Xa+1、Ya)の画素の組と、座標(2Xa、Ya−1)、(2Xa+1、Ya−1)の画素の組と、を含む4つの画素を含む。   When the complement number SC is determined, the enlargement processing unit M14 sets the pixel value of the pixel including the complement pixel (step S6340). Specifically, the pixel group selection unit M144 of the enlargement processing unit M14 selects the pixel group SCP to be set in the enlarged image. FIG. 12B illustrates an example of the pixel group SCP. The pixel group SCP includes a set of corresponding target pixels TP (coordinates (2Xa, Ya), (2Xa + 1, Ya)) corresponding to the target pixel SP (coordinates (Xa, Ya)). Further, when the complement number SC is 2 or more, the pixel group SCP includes one corresponding target pixel TP ((SC-1) pixels continuous in the complement direction SD from the coordinates (2Xa, Ya), and the other Corresponding pixel TP (coordinate (2Xa + 1, Ya) to (SC-1) pixels continuous in the complementary direction SD. In other words, the pixel group SCP includes a set of two pixels arranged in the horizontal direction as SC. 2 × SC pixels are included, and the complementary direction SD is determined for each of four types of specific patterns as shown in Fig. 10. The complementary direction SD is a count of the first continuous number CL. In the example of Fig. 12B, the complement number SC = 2, and the pixel group SCP has coordinates (2Xa, Ya), (2Xa + 1, Ya) pixel set and coordinates 2xa, Ya-1), including four pixels including a set of pixels of the (2Xa + 1, Ya-1).

画素データ設定部M145は、選択された画素群SCPに含まれる横方向に並ぶ2個の画素の各組を、補完パターンSDPにそれぞれ設定する。補完パターンSDPは、4種類の特定パターンごとに、定められている(図10:SDP1〜SDP4)。この結果、図12に拡大画像において、画素群SCPに含まれる画素のうち、横方向に黒画素が隣接する画素群は、黒画素に設定される。また、拡大画像において、画素群SCPに含まれる画素のうち、横方向に白画素が隣接する画素群は、白画素に設定される。横方向に黒画素が隣接する画素群は、特定パターン1、2の場合には、画素群SCPのうち、X座標が2Xaである画素列の画素群であり、特定パターン3、4の場合には、画素群SCPのうち、X座標が(2Xa+1)である画素列の画素群である。ここで、黒画素に設定される画素は、例えば、その画素値が、255に設定されても良いし、その画素値が、元画像の対象画素SPの近傍の黒画素(例えば、右方向または左方向に隣接する黒画素)の画素値と同じ値に設定されても良い。また、白画素に設定される画素は、例えば、その画素値が0に設定されても良いし、その画素値が、元画像の対象画素SPの画素値と同じ値に設定されても良い。   The pixel data setting unit M145 sets each set of two pixels arranged in the horizontal direction included in the selected pixel group SCP in the complementary pattern SDP. The complementary pattern SDP is determined for each of the four types of specific patterns (FIG. 10: SDP1 to SDP4). As a result, in the enlarged image shown in FIG. 12, among the pixels included in the pixel group SCP, the pixel group adjacent to the black pixel in the horizontal direction is set as a black pixel. In the enlarged image, among the pixels included in the pixel group SCP, a pixel group in which white pixels are adjacent in the horizontal direction is set as a white pixel. In the case of the specific patterns 1 and 2, the pixel group in which the black pixels are adjacent to each other in the horizontal direction is a pixel group in the pixel column having the X coordinate of 2Xa in the pixel group SCP. Is a pixel group of a pixel column whose X coordinate is (2Xa + 1) in the pixel group SCP. Here, for the pixel set as the black pixel, for example, the pixel value may be set to 255, or the pixel value may be set to a black pixel in the vicinity of the target pixel SP of the original image (for example, in the right direction or The pixel value of a black pixel adjacent in the left direction may be set to the same value. In addition, for a pixel set as a white pixel, for example, the pixel value may be set to 0, or the pixel value may be set to the same value as the pixel value of the target pixel SP of the original image.

図9に戻って説明を続ける。ステップS635では、拡大処理部M14は、元画像の全ての画素が対象画素SPとして選択済みであるか否かを判断する。拡大処理部M14は、未選択の画素があると判断すると(ステップS635:NO)、ステップS605に戻って、未選択の画素を新たな対象画素SPとして選択して、上述したステップS610〜S630の処理を繰り返す。拡大処理部M14は、全ての画素が選択済みであると判断すると(ステップS635:YES)、横方向拡大処理を終了する。   Returning to FIG. 9, the description will be continued. In step S635, the enlargement processing unit M14 determines whether all the pixels of the original image have been selected as the target pixel SP. When the enlargement processing unit M14 determines that there is an unselected pixel (step S635: NO), the process returns to step S605, selects the unselected pixel as a new target pixel SP, and performs the above-described steps S610 to S630. Repeat the process. If the enlargement processing unit M14 determines that all the pixels have been selected (step S635: YES), the enlargement processing unit M14 ends the lateral enlargement processing.

横方向拡大処理によって生成される拡大画像(歪画像PG2(図3(B)))は、単純拡大画像に、補完画素を付加した画像となる。ここで、単純拡大画像は、元画像を構成する縦方向に沿ったm番目の画素列と、(m+1)番目の画素列との間に、m番目の画素列と同じ画素列が配置された画像である。すなわち、単純拡大画像は、奇数番目の画素列と、当該画素列の次の偶数番目の画素列と、が同じになる。補完画素(上述のステップS6340(図11)で黒画素に設定される画素)を構成する画素群は、元画像において特定パターン1〜4を構成する9個の画素のうちの特定画素(特定パターンの中心に位置する白画素)に対応する拡大画像の画素(対応特定画素)を含み、縦方向に延びる補完数SC個の画素である。   An enlarged image (distorted image PG2 (FIG. 3B)) generated by the horizontal enlargement process is an image obtained by adding complementary pixels to a simple enlarged image. Here, in the simple enlarged image, the same pixel column as the m-th pixel column is arranged between the m-th pixel column along the vertical direction constituting the original image and the (m + 1) -th pixel column. It is an image. That is, in the simple enlarged image, the odd-numbered pixel column and the even-numbered pixel column next to the pixel column are the same. The pixel group constituting the complementary pixel (the pixel set as the black pixel in step S6340 (FIG. 11) described above) is a specific pixel (specific pattern) among the nine pixels forming the specific patterns 1 to 4 in the original image. Is a pixel of the supplement number SC including the pixel (corresponding specific pixel) of the enlarged image corresponding to the white pixel located at the center of the pixel and extending in the vertical direction.

図12(B)に示す拡大画像の例では、クロスハッチングされた画素は、単純拡大画像を構成する黒画素を示し、シングルハッチングされた画素は、補完画素である黒画素を示している。後述する図13に示す拡大画像の例でも同様とする。   In the example of the enlarged image shown in FIG. 12B, the cross-hatched pixel indicates a black pixel constituting the simple enlarged image, and the single-hatched pixel indicates a black pixel that is a complementary pixel. The same applies to an example of an enlarged image shown in FIG.

図12(C)には、図12(B)に示す拡大画像(歪画像PG2)に対応する印刷画像(無歪ドット画像GD2)が示されている。図12(C)において、クロスハッチングされた画素は、拡大画像における単純拡大画像を構成する黒画素に対応するドット形成画素(画素値「1」の画素)を示す。また、シングルハッチングされた画素は、拡大画像における補完画素に対応するドット形成画素を示す。印刷画像は、図2を参照して説明したように、歪画像PG2を縦方向に2倍に拡大した画像であるので、印刷画像において、補完画素に対応するドット形成画素SCDの数は、拡大画像(図12(B))における補完画素の数の2倍になる。   FIG. 12C shows a print image (undistorted dot image GD2) corresponding to the enlarged image (distorted image PG2) shown in FIG. In FIG. 12C, cross-hatched pixels indicate dot formation pixels (pixels with a pixel value “1”) corresponding to black pixels that form a simple enlarged image in the enlarged image. The single-hatched pixel indicates a dot formation pixel corresponding to a complementary pixel in the enlarged image. As described with reference to FIG. 2, the print image is an image obtained by enlarging the distorted image PG2 twice in the vertical direction. Therefore, in the print image, the number of dot formation pixels SCD corresponding to the complementary pixels is enlarged. This is twice the number of complementary pixels in the image (FIG. 12B).

以上説明した本実施例によれば、画素群選択部M144は、元画像において特定パターン1〜4(図10)のいずれかを構成する白画素である特定画素(本実施例では、各特定パターンを形成する9個の画素の中心に位置する画素)に対応する対応特定画素を含む拡大画像の画素群SCPを選択する(図12)。画素データ設定部M145は、2列の画素群SCPのうちの一列の画素群を黒画素に設定する、すなわち、画素群SCPに対応する領域に補完画素を配置する。黒画素に設定される画素の数(補完数SC)は、第1の連続数CLと第2の連続数CUとに応じた数である。この結果、元画像の特定パターンの特定画素から見て、上方向の画素と、下方向の画素の配置を考慮して、特定パターンに対応する拡大画像のエッジの見栄えを向上することができる。   According to the present embodiment described above, the pixel group selection unit M144 is a specific pixel (in the present embodiment, each specific pattern that is a white pixel constituting any one of the specific patterns 1 to 4 (FIG. 10) in the original image. The pixel group SCP of the enlarged image including the corresponding specific pixel corresponding to (the pixel located at the center of the nine pixels forming the pixel) is selected (FIG. 12). The pixel data setting unit M145 sets one pixel group of the two pixel groups SCP as a black pixel, that is, arranges a complementary pixel in a region corresponding to the pixel group SCP. The number of pixels set as black pixels (complement number SC) is a number corresponding to the first continuous number CL and the second continuous number CU. As a result, it is possible to improve the appearance of the edge of the enlarged image corresponding to the specific pattern in consideration of the arrangement of the pixels in the upward direction and the pixels in the downward direction when viewed from the specific pixels of the specific pattern of the original image.

より具体的には、例えば、特定パターン1は、図10に示す上部分パターンUP1と、中央部分パターンMP1と、下部分パターンBP1を含むパターンである。すなわち、特定パターン1は、黒画素によって形成される形状が、L字型となる(横方向に一画素分の段差がある形状)パターンである。他の特定パターン2〜3も同様である。   More specifically, for example, the specific pattern 1 is a pattern including the upper part pattern UP1, the center part pattern MP1, and the lower part pattern BP1 shown in FIG. That is, the specific pattern 1 is a pattern in which the shape formed by the black pixels is L-shaped (a shape having a level difference of one pixel in the horizontal direction). The same applies to the other specific patterns 2 to 3.

図13および図14は、拡大画像における補完画素の配置例を示す図である。図13(A)〜(F)および図14(A)、(B)のそれぞれにおいて、左側は、元画像の一部分の例を示し、右側は、左側の元画像の一部分に対応する拡大画像の一部分を示している。また、図13および図14に示す拡大画像における破線は、白画素と黒画素によって形成されるエッジの方向を大まかに示している。   13 and 14 are diagrams illustrating an example of the arrangement of complementary pixels in an enlarged image. 13A to 13F and FIGS. 14A and 14B, the left side shows an example of a part of the original image, and the right side shows an enlarged image corresponding to a part of the left original image. A part is shown. Moreover, the broken line in the enlarged images shown in FIGS. 13 and 14 roughly indicates the direction of the edge formed by the white pixel and the black pixel.

これらの図から解るように、元画像における横方向に1画素分の段差が、単純拡大画像では、横方向に2画素分の段差になる。したがって、単純拡大画像では、斜め方向のエッジのがたつきが元画像と比較して大きくなる。この結果、単純拡大画像を用いて、最終的に印刷される無歪ドット画像GD2においても斜め方向のエッジのがたつきが目立ちやすくなる。   As can be seen from these figures, the level difference of one pixel in the horizontal direction in the original image is a level difference of two pixels in the horizontal direction in the simple enlarged image. Therefore, in the simple enlarged image, the shakiness of the edge in the oblique direction is larger than that in the original image. As a result, shakiness of the edge in the oblique direction is easily noticeable in the undistorted dot image GD2 that is finally printed using the simple enlarged image.

本実施例では、上述のように、L字型の特定パターンを検出して、補完画素の配置対象とするので、見栄えを向上するべきエッジを適切に選んで、当該エッジの見栄えを向上することができる。例えば、図13(A)〜(E)に示す例では、補完画素を配置するが、図13(F)に示す例では、補完画素を配置しない。この結果、補完画素を配置することによって、エッジの全体の形状(例えば、図13(F)の破線を参照)が損なわれる可能性がある箇所に、補完画素が配置されることを抑制することができる。なお、図13(A)〜(E)、図14(A)は、特定パターン2に対応する補完対象箇所の例を示し、図14(B)は、特定パターン2に対応する補完対象箇所(上側)と、特定パターン1に対応する補完対象箇所(下側)とが近接している例を示している。   In the present embodiment, as described above, an L-shaped specific pattern is detected and set as a complementary pixel arrangement target. Therefore, an edge that should be improved in appearance is appropriately selected to improve the appearance of the edge. Can do. For example, in the example shown in FIGS. 13A to 13E, complementary pixels are arranged, but in the example shown in FIG. 13F, no complementary pixels are arranged. As a result, by arranging the complementary pixels, it is possible to prevent the complementary pixels from being arranged at a place where the entire shape of the edge (for example, see the broken line in FIG. 13F) may be damaged. Can do. FIGS. 13A to 13E and FIG. 14A show examples of complement target locations corresponding to the specific pattern 2, and FIG. 14B shows complement target locations corresponding to the specific pattern 2 ( An example is shown in which the upper side) and the complement target portion (lower side) corresponding to the specific pattern 1 are close to each other.

さらに、連続数決定部M143は、特定パターン1〜4の部分パターンUP1、BP2、UP3、BP4と同じパターンである第1のパターンLCP1〜LCP4を用いて、第1の連続数CLをカウントする。連続数決定部M143は、特定パターン1〜4の部分パターンBP1、UP2、BP3、UP4と同じパターンである第2のパターンUCP1〜LCP4を用いて、第2の連続数CUをカウントする。この結果、補完数SCを定めるための第1の連続数CLと第2の連続数CUとを適切にカウントすることができる。   Furthermore, the continuous number determination unit M143 counts the first continuous number CL using the first patterns LCP1 to LCP4 that are the same patterns as the partial patterns UP1, BP2, UP3, and BP4 of the specific patterns 1 to 4. The continuous number determination unit M143 uses the second patterns UCP1 to LCP4, which are the same patterns as the partial patterns BP1, UP2, BP3, and UP4 of the specific patterns 1 to 4, to count the second continuous number CU. As a result, it is possible to appropriately count the first continuous number CL and the second continuous number CU for determining the complement number SC.

さらに、連続数決定部M143は、第1の連続数CLが第2の連続数CUより多い場合には、補完数SCを、第2の連続数CUを用いて、決定している(具体的には、SC=CU−1としている。図11:S6330)。   Furthermore, when the first continuous number CL is greater than the second continuous number CU, the continuous number determining unit M143 determines the complement number SC using the second continuous number CU (specifically, SC = CU−1 (FIG. 11: S6330).

例えば、図13(A)は、第1の連続数CL=7、第2の連続数CU=4である補完対象箇所が、1つある例を示し、図14(B)は、第1の連続数CL=7、第2の連続数CU=4である補完対象箇所が、2つある例を示している。この例では、第2の連続数CUを用いて補完数SCが適切な数(3個)に定められることによって、破線で示す方向に延びるエッジの全体の形状を維持しつつ、エッジを滑らかにされている。また、図14(B)の例では、補完数SCが適切な数(上下3個ずつ)に定められることによって、図13に符号VPで示す画素が黒画素に設定されない。すなわち、上側の補完画素と下側の補完画素とが繋がってしまうことが抑制される。この結果、表現すべき段差が補完画素によって消失することなく、エッジを滑らかにすることができる。   For example, FIG. 13A shows an example in which there is one complementation target portion where the first continuous number CL = 7 and the second continuous number CU = 4, and FIG. An example is shown in which there are two complementation target portions where the continuous number CL = 7 and the second continuous number CU = 4. In this example, by using the second continuous number CU, the complement number SC is set to an appropriate number (3), so that the entire shape of the edge extending in the direction indicated by the broken line is maintained and the edge is smoothed. Has been. Further, in the example of FIG. 14B, the complement number SC is set to an appropriate number (upper and lower three), so that the pixel indicated by the symbol VP in FIG. 13 is not set as a black pixel. That is, the upper complementary pixel and the lower complementary pixel are prevented from being connected. As a result, the edge can be smoothed without the step to be expressed being lost by the complementary pixels.

さらに、連続数決定部M143は、第1の連続数CLが第2の連続数CU以下である場合には、補完数SCを、第1の連続数CLを用いて、決定している(具体的には、SC=CL/2としている。図11:S6335)。   Furthermore, when the first continuous number CL is equal to or less than the second continuous number CU, the continuous number determining unit M143 determines the complement number SC using the first continuous number CL (specifically) Specifically, SC = CL / 2 (FIG. 11: S6335).

例えば、図13(B)は、第1の連続数CL=4、第2の連続数CU=4である補完対象箇所の例を示し、図13(D)は、第1の連続数CL=2、第2の連続数CU=4である補完対象箇所がの例を示している。この例では、第1の連続数CLを用いて、補完数SCが適切な数(図13(B):2個、図13(D):1個)に定められることによって、破線で示す方向に延びるエッジの全体の形状を維持しつつ、エッジを滑らかにされている。   For example, FIG. 13B illustrates an example of a complement target portion where the first continuous number CL = 4 and the second continuous number CU = 4, and FIG. 13D illustrates the first continuous number CL = 4. 2 shows an example in which the complement target portion where the second continuous number CU = 4 is set. In this example, by using the first continuous number CL, the complement number SC is set to an appropriate number (FIG. 13B: 2, FIG. 13D: 1), and the direction indicated by the broken line The edges are smoothed while maintaining the overall shape of the edges that extend to.

さらに、連続数決定部M143は、第1の連続数CLと第2の連続数CUとの少なくとも一方が1である場合には、補完数SCを、1に決定している(図11:S6320)。   Furthermore, the continuous number determination unit M143 determines the complement number SC as 1 when at least one of the first continuous number CL and the second continuous number CU is 1 (FIG. 11: S6320). ).

例えば、図13(C)は、第1の連続数CL=1、第2の連続数CU=1である補完対象箇所の例を示し、図13(E)は、第1の連続数CL=1、第2の連続数CU=4である補完対象箇所の例を示し、図14(A)は、第1の連続数CL=4、第2の連続数CU=1である補完対象箇所の例を示している。これらの例では、補完数SCが適切な数(1個)に定められることによって、破線で示す方向に延びるエッジの全体の形状を維持しつつ、エッジを滑らかにされている。   For example, FIG. 13C illustrates an example of a complement target portion where the first continuous number CL = 1 and the second continuous number CU = 1, and FIG. 13E illustrates the first continuous number CL = FIG. 14A shows an example of a complement target location where 1 and the second continuous number CU = 4, and FIG. 14A shows a complement target location where the first continuous number CL = 4 and the second continuous number CU = 1. An example is shown. In these examples, by setting the complement number SC to an appropriate number (one), the edges are smoothed while maintaining the overall shape of the edges extending in the direction indicated by the broken line.

このように、第1の連続数CLと第2の連続数CUを適切に用いて、補完数SCを決定する結果、拡大画像において、再現すべきエッジの全体の形状を維持しつつ、エッジのがたつきを抑制することができる。したがって、最終的な印刷画像(無歪ドット画像GD2)において、元画像のエッジの全体の形状を維持しつつ、エッジのがたつきを抑制することができる。   As described above, as a result of determining the complement number SC by appropriately using the first continuous number CL and the second continuous number CU, in the enlarged image, while maintaining the entire shape of the edge to be reproduced, Shaking can be suppressed. Therefore, in the final printed image (undistorted dot image GD2), it is possible to suppress the rattling of the edge while maintaining the entire shape of the edge of the original image.

図15は、本実施例の印刷画像のエッジと、比較例の印刷画像のエッジを示す図である。図15(A)は、ステップS100(図2)において取得された対象画像データがポートレイトである場合の例を示している。図15(B)は、ステップS100(図2)において取得された対象画像データがランドスケープである場合の例を示している。図15(A)、(B)において、右側は、本実施例の画像処理が行われた場合、すなわち、補完画素が付加された場合を示し、左側は、単純拡大画像を用いた場合、すなわち、補完画素が付加されなかった場合を示している。   FIG. 15 is a diagram illustrating an edge of the print image of the present embodiment and an edge of the print image of the comparative example. FIG. 15A shows an example in which the target image data acquired in step S100 (FIG. 2) is a portrait. FIG. 15B shows an example in which the target image data acquired in step S100 (FIG. 2) is a landscape. 15A and 15B, the right side shows the case where the image processing of the present embodiment is performed, that is, the case where the complementary pixel is added, and the left side shows the case where the simple enlarged image is used, that is, This shows a case where no complementary pixel is added.

図15(A)、(B)ともに、右側の本実施例の印刷画像は、左側の単純拡大画像を用いた印刷画像と比較して、白画素と黒画素とで形成されるエッジの全体の形状は変化していないにも拘わらず、エッジのがたつきが抑制されていることが解る。本実施例の印刷画像は、特に、斜め方向に延びるエッジ(例えば、符号E1〜E6で示す部分)で、顕著にエッジのがたつきが抑制されていることが解る。   In both FIGS. 15A and 15B, the print image of this embodiment on the right side is the entire edge formed by white pixels and black pixels as compared to the print image using the left side simple enlarged image. It can be seen that the rattling of the edge is suppressed even though the shape has not changed. In the printed image of this example, it can be seen that the rattling of the edges is remarkably suppressed particularly at the edges (for example, portions indicated by reference numerals E1 to E6) extending in the oblique direction.

さらに、本実施例の拡大処理部M14は、元画像を構成する複数の画素の中から順次に対象画素SPを選択し(図9:S605、S635)、対象画素SPが選択される度に、エッジ補完処理を含む第1処理(図9:ステップS630)と、エッジ補完処理を含まない第2処理(例えば、図9:ステップS615、S620)のうちのいずれかを実行することによって、拡大画像データを生成している。第1処理は、対象画素SPが特定画素(特定パターンを形成する画素群の中心画素)を含む場合に実行される。第2処理は、対象画素SPが特定画素を含まない場合に実行される。この結果、補完画素が付加された拡大画像(無歪画像PG1)を容易に作成することができる。   Further, the enlargement processing unit M14 of the present embodiment sequentially selects the target pixel SP from the plurality of pixels constituting the original image (FIG. 9: S605, S635), and every time the target pixel SP is selected, By executing one of the first process including the edge complement process (FIG. 9: Step S630) and the second process not including the edge complement process (for example, FIG. 9: Steps S615 and S620), the enlarged image is displayed. Data is being generated. The first process is executed when the target pixel SP includes a specific pixel (a central pixel of a pixel group that forms a specific pattern). The second process is executed when the target pixel SP does not include the specific pixel. As a result, it is possible to easily create an enlarged image (undistorted image PG1) to which complementary pixels are added.

また、本実施例によれば、ハーフトーン処理部M16は、ディザマトリクスを用いて、画素数比S2が無歪画像PG1の画素数比Sの2倍である歪ドット画像GD1を表す歪ドットデータを生成する(図2:S700)。そして、ドット画像拡大部M18は、歪ドットデータに対してドット画像拡大処理を実行して、無歪ドット画像GD2を表す無歪ドットデータを生成する(図2:S800)。この結果、ハーフトーン処理部M16は、無歪ドット画像GD2より小さい歪ドット画像GD1を表す歪ドットデータを生成すれば良いので、ハーフトーン処理の処理量を低減することができる。   Further, according to the present embodiment, the halftone processing unit M16 uses the dither matrix, and the distorted dot data representing the distorted dot image GD1 in which the pixel number ratio S2 is twice the pixel number ratio S of the undistorted image PG1. (FIG. 2: S700). Then, the dot image enlargement unit M18 performs dot image enlargement processing on the distorted dot data to generate undistorted dot data representing the undistorted dot image GD2 (FIG. 2: S800). As a result, the halftone processing unit M16 only needs to generate distorted dot data representing the distorted dot image GD1 smaller than the undistorted dot image GD2, so that the processing amount of the halftone process can be reduced.

また、上記実施例では、圧縮部M19は、同一行の組を含む無歪ドット画像GD2を表す無歪ドットデータを、前参照圧縮処理(図4)を用いて圧縮するので、無歪ドットデータのデータ量を低減できる。したがって、印刷装置200に送信する印刷データのデータ量を低減できる。この結果、印刷装置200に必要なメモリ容量(例えば、揮発性メモリ214の容量)を低減することができる。   In the above-described embodiment, the compression unit M19 compresses the undistorted dot data representing the undistorted dot image GD2 including the set of the same row using the pre-reference compression process (FIG. 4). The amount of data can be reduced. Accordingly, the amount of print data transmitted to the printing apparatus 200 can be reduced. As a result, the memory capacity required for the printing apparatus 200 (for example, the capacity of the volatile memory 214) can be reduced.

さらに、印刷画像に表れるスクリーン角度、すなわち、本実施例では、無歪ドット画像GD2(部分無歪ドット画像PGD2(図8))に表れるスクリーン角度は、画質に影響を与える。例えば、人間の視覚特性において、縦方向および横方向の縞模様に対する分解能が高く、斜め方向の縞模様に対する分解能が低いことが知られている。このために、縦方向および横方向の縞模様は目立ちやすく、斜め方向の縞模様は目立ちにくい。このような人間の視覚特性を考慮して、モノクロ印刷では、印刷画像に表れるスクリーン角度は45度に設定されるのが一般的である。上記構成によれば、無歪ドット画像GD2(部分無歪ドット画像PGD2(図8))に表れるスクリーン角度が目標値θになるように、ディザマトリクスDM1のスクリーン角度φは、φ=arctan((tanθ)/2)に設定されている。具体的には、無歪ドット画像GD2(部分無歪ドット画像PGD2(図8))に表れるスクリーン角度θが約45度になるように、ディザマトリクスDM1のスクリーン角度φは、約26.56度に設定されている。この結果、印刷画像、すなわち、無歪ドット画像GD2に表れるスクリーン角度を適正化して、印刷画像の画質を向上することができる。   Further, the screen angle appearing in the printed image, that is, the screen angle appearing in the undistorted dot image GD2 (partial undistorted dot image PGD2 (FIG. 8)) in this embodiment affects the image quality. For example, in human visual characteristics, it is known that the resolution for vertical and horizontal stripe patterns is high and the resolution for diagonal stripe patterns is low. For this reason, the stripe pattern in the vertical direction and the horizontal direction is easily noticeable, and the stripe pattern in the oblique direction is not easily noticeable. In consideration of such human visual characteristics, in monochrome printing, the screen angle appearing in a printed image is generally set to 45 degrees. According to the above configuration, the screen angle φ of the dither matrix DM1 is φ = arctan ((() so that the screen angle appearing in the undistorted dot image GD2 (partial undistorted dot image PGD2 (FIG. 8)) becomes the target value θ. tan θ) / 2). Specifically, the screen angle φ of the dither matrix DM1 is about 26.56 degrees so that the screen angle θ appearing in the undistorted dot image GD2 (partial undistorted dot image PGD2 (FIG. 8)) is about 45 degrees. Is set to As a result, the screen angle appearing in the print image, that is, the undistorted dot image GD2, can be optimized and the image quality of the print image can be improved.

また、印刷画像における線数(単位は、line per inch)、すなわち、本実施例では、無歪ドット画像GD2(部分無歪ドット画像PGD2(図8))における線数は、画質に影響を与える。例えば、線数が小さい場合には、互いに隣接するドットの集合の大きさ(サブマトリクスCE1に対応(図6))が大きくなるので、トナーの安定性が向上して、バンディングなどの不具合が起こりにくくなる。一方、線数が小さい場合には、画像が粗くなり、エッジのがたつきが大きくなる。このような、利点と欠点を考慮して、適切な線数が定められる。無歪ドット画像GD2(部分無歪ドット画像PGD2(図8))における線数は、上述したライン間隔Dによって定まる。上記構成によれば、無歪ドット画像GD2(部分無歪ドット画像PGD2(図8))に表れるライン間隔が目標値Dになるように、ディザマトリクスDM1は、歪ドット画像GD1(部分歪ドット画像PGD1:図7)に表れるライン間隔Lが、およそ(1/2)×D×cosφ/cosθ、ただし、φ=arctan((tanθ)/2) となるように、設定されている。この結果、印刷画像、すなわち、無歪ドット画像GD2に表れるライン間隔D、および、ライン間隔Dによって定まる線数を適正化して、印刷画像の画質を向上することができる。   The number of lines in the printed image (unit is line per inch), that is, the number of lines in the undistorted dot image GD2 (partial undistorted dot image PGD2 (FIG. 8)) in this embodiment affects the image quality. . For example, when the number of lines is small, the size of a set of adjacent dots (corresponding to the submatrix CE1 (FIG. 6)) increases, so that the stability of the toner is improved and problems such as banding occur. It becomes difficult. On the other hand, when the number of lines is small, the image becomes rough and the edge shakiness increases. An appropriate number of lines is determined in consideration of such advantages and disadvantages. The number of lines in the undistorted dot image GD2 (partial undistorted dot image PGD2 (FIG. 8)) is determined by the line interval D described above. According to the above configuration, the dither matrix DM1 has the distorted dot image GD1 (partially distorted dot image so that the line interval appearing in the undistorted dot image GD2 (partial distorted dot image PGD2 (FIG. 8)) becomes the target value D. PGD1: The line interval L shown in FIG. 7) is set to be approximately (1/2) × D × cos φ / cos θ, where φ = arctan ((tan θ) / 2). As a result, the image quality of the print image can be improved by optimizing the line interval D appearing in the print image, that is, the undistorted dot image GD2, and the number of lines determined by the line interval D.

以上の説明から解るように、本実施例における上方向および下方向のいずれか一方は、第1の方向の例であり、右方向および左方向のいずれか一方が、第1の方向と交差する第2の方向の例である。また、本実施例における特定パターン1、3の上部分パターンUP1、UP3は、第1部分パターンの例であり、本実施例における特定パターン1、3の下部分パターンBP1、BP3は、第2部分パターンの例である。また、本実施例における特定パターン2、4の下部分パターンBP2、BP4は、第1部分パターンの例であり、本実施例における特定パターン2、4の上部分パターンUP2、UP4は、第2部分パターンの例である。   As can be understood from the above description, either one of the upward direction and the downward direction in this embodiment is an example of the first direction, and either the right direction or the left direction intersects the first direction. It is an example of the second direction. Further, the upper part patterns UP1 and UP3 of the specific patterns 1 and 3 in this embodiment are examples of the first part pattern, and the lower part patterns BP1 and BP3 of the specific patterns 1 and 3 in this embodiment are the second part patterns. It is an example of a pattern. In addition, the lower part patterns BP2 and BP4 of the specific patterns 2 and 4 in the present embodiment are examples of the first partial pattern, and the upper part patterns UP2 and UP4 of the specific patterns 2 and 4 in the present embodiment are the second part patterns. It is an example of a pattern.

B.変形例:
(1)実施例では、拡大処理部M14は、元画像(無歪画像PG1)を拡大して、拡大画像(歪画像PG2)を生成する処理として、元画像を横方向に拡大する横方向拡大処理(図2:ステップS600)を実行しているが、元画像を縦方向に拡大する縦方向拡大処理を実行しても良い。例えば、ステップS100(図2)において取得された対象画像データがランドスケープである場合に、拡大処理部M14は、90度回転処理(図2:S500)を行うことなく、横方向拡大処理に代えて、縦方向拡大処理を実行しても良い。この場合には、縦方向拡大処理によって生成された拡大画像(歪画像)を表す拡大画像データに対して、ハーフトーン処理(図2:S700)を行う前に、90度回転処理を行うことが好ましい。
B. Variations:
(1) In the embodiment, the enlargement processing unit M14 enlarges the original image (undistorted image PG1) and generates the enlarged image (distorted image PG2) as a process of enlarging the original image in the horizontal direction. Although the process (FIG. 2: step S600) is executed, a vertical enlargement process for enlarging the original image in the vertical direction may be executed. For example, when the target image data acquired in step S100 (FIG. 2) is a landscape, the enlargement processing unit M14 does not perform the 90-degree rotation process (FIG. 2: S500), and instead of the horizontal enlargement process. Further, the vertical enlargement process may be executed. In this case, the 90 degree rotation process may be performed on the enlarged image data representing the enlarged image (distorted image) generated by the vertical enlargement process before the halftone process (FIG. 2: S700). preferable.

図16は、縦方向拡大処理における特定パターンとカウント用パターンについて説明する図である。縦方向拡大処理は、実施例における横方向拡大処理(図9、図11)と基本的に同じであるが、以下の点が異なる。
1)縦方向拡大処理では、元画像の対象画素SPの座標を(Xa、Ya)とすると、拡大画像の対応対象画素TPの座標は、(Xa、2Ya)と(Xa、2Ya+1)である。
2)図16に示すように、縦方向拡大処理の4種類の特定パターン1〜4は、横方向拡大処理の4種類の特定パターン1〜4(図10)を、それぞれ90度回転(図16の例では、反時計回りに90度)させたパターンである。
3)図16に示すように、縦方向拡大処理の特定パターン1〜4に対応する第1のパターンLCP1〜LCP4、第2のパターンUCP1〜UCP4、カウント方向CD1、CD2、補完方向SD、補完パターンSDP1〜SDP4は、横方向拡大処理におけるこれらの要素LCP1〜LCP4、UCP1〜UCP4、CD1、CD2、SD、SDP1〜SDP4を、それぞれ、90度回転(図16の例では、反時計回りに90度)させたものである。
FIG. 16 is a diagram illustrating a specific pattern and a count pattern in the vertical enlargement process. The vertical enlargement process is basically the same as the horizontal enlargement process (FIGS. 9 and 11) in the embodiment, except for the following points.
1) In the vertical enlargement process, if the coordinates of the target pixel SP of the original image are (Xa, Ya), the coordinates of the corresponding target pixel TP of the enlarged image are (Xa, 2Ya) and (Xa, 2Ya + 1).
2) As shown in FIG. 16, the four types of specific patterns 1 to 4 of the vertical direction enlargement process rotate the four types of specific patterns 1 to 4 (FIG. 10) of the horizontal direction enlargement process by 90 degrees (FIG. 16). In this example, the pattern is 90 degrees counterclockwise.
3) As shown in FIG. 16, the first patterns LCP1 to LCP4, the second patterns UCP1 to UCP4, the count directions CD1, CD2, the complementary direction SD, and the complementary pattern corresponding to the specific patterns 1 to 4 of the vertical enlargement process SDP1 to SDP4 rotate these elements LCP1 to LCP4, UCP1 to UCP4, CD1, CD2, SD, and SDP1 to SDP4 in the horizontal enlargement process by 90 degrees (in the example of FIG. 16, 90 degrees counterclockwise). ).

例えば、縦方向拡大処理の特定パターン1〜4は、それぞれ、縦方向に並んだ3つの画素で構成される中央部分パターンMP1〜MP4と、中央部分パターンMP1〜MP4の左方向にそれぞれ隣接する左部分パターンLP1〜LP4と、中央部分パターンMP1の右方向にそれぞれ隣接する右部分パターンRP1〜RP4とを含む。   For example, the specific patterns 1 to 4 of the vertical enlargement process are respectively adjacent to the left of the central partial patterns MP1 to MP4 composed of three pixels arranged in the vertical direction and the central partial patterns MP1 to MP4. Partial patterns LP1 to LP4 and right partial patterns RP1 to RP4 adjacent in the right direction of the central partial pattern MP1 are included.

そして、縦方向拡大処理の第1のパターンLCP1〜LCP4は、対応する特定パターンに含まれる3つの部分パターンのうち、中心画素に対してカウント方向CD1に隣接する部分パターンと同じパターンである。縦方向拡大処理の第2のパターンUCP1〜UCP4は、対応する特定パターンに含まれる3つの部分パターンのうち、中心画素に対してカウント方向CD2に隣接する部分パターンと同じパターンである。   The first patterns LCP1 to LCP4 of the vertical direction enlargement process are the same patterns as the partial patterns adjacent to the central pixel in the count direction CD1 among the three partial patterns included in the corresponding specific pattern. The second patterns UCP1 to UCP4 of the vertical expansion process are the same patterns as the partial patterns adjacent to the central pixel in the count direction CD2 among the three partial patterns included in the corresponding specific pattern.

縦方向拡大処理を採用しても、実施例と同様の作用・効果を奏する。
また、以上の説明から解るように、本変形例における右方向および左方向のいずれか一方は、第1の方向の例であり、下方向および上方向のいずれか一方が、第1の方向と交差する第2の方向の例である。また、本変形例における特定パターン1、3の左部分パターンLP1、LP3は、第1部分パターンの例であり、本変形例における特定パターン1、3の右部分パターンRP1、RP3は、第2部分パターンの例である。また、本変形例における特定パターン2、4の右部分パターンRP2、RP4は、第1部分パターンの例であり、本変形例における特定パターン2、4の左部分パターンLP2、LP4は、第2部分パターンの例である。
Even when the vertical enlargement process is employed, the same operations and effects as the embodiment are obtained.
Further, as can be understood from the above description, one of the right direction and the left direction in the present modification is an example of the first direction, and one of the downward direction and the upward direction is the first direction. It is an example of the 2nd direction which crosses. Further, the left partial patterns LP1 and LP3 of the specific patterns 1 and 3 in the present modification are examples of the first partial pattern, and the right partial patterns RP1 and RP3 of the specific patterns 1 and 3 in the present modification are the second part. It is an example of a pattern. In addition, the right partial patterns RP2 and RP4 of the specific patterns 2 and 4 in this modification are examples of the first partial pattern, and the left partial patterns LP2 and LP4 of the specific patterns 2 and 4 in this modification are the second part. It is an example of a pattern.

(2)上記実施例における横方向拡大処理(図9)に代えて、先に、単純拡大画像を表す単純拡大画像データを生成し、単純拡大画像に補完画素を付加するように、単純拡大画像データを修正することによって、拡大画像データを生成しても良い。 (2) Instead of the horizontal enlargement processing (FIG. 9) in the above-described embodiment, the simple enlarged image is generated so that the simple enlarged image data representing the simple enlarged image is first generated and the complementary pixel is added to the simple enlarged image. The enlarged image data may be generated by correcting the data.

図17は、本変形例における横方向拡大処理のフローチャートである。ステップS602Bでは、拡大処理部M14は、単純拡大画像データを生成する。ステップS605では、拡大処理部M14は、単純拡大画像を構成する画素の中から処理対象とする対象画素を順次に1つずつ選択する。具体的には、単純拡大画像の上端の行から順に、下方に向かって処理対象とする。同じ行の中では、左端の画素から、右に向かって順次に処理対象とする。   FIG. 17 is a flowchart of the horizontal enlargement process in this modification. In step S602B, the enlargement processing unit M14 generates simple enlarged image data. In step S605, the enlargement processing unit M14 sequentially selects target pixels to be processed one by one from the pixels constituting the simple enlarged image. Specifically, the processing targets are processed downward in order from the top row of the simple enlarged image. In the same row, processing is sequentially performed from the leftmost pixel toward the right.

ステップS610Bでは、実施例のステップ610と同様に、拡大処理部M14は、対象画素は白画素であるか否かを判断する。対象画素が白画素であると判断されると(ステップS610B:YES)、拡大処理部M14のパターン検出部M142は、単純拡大画像において、対象画素とその周辺画素とは、後述する4種類の特定パターン1〜4のいずれかを形成するか否かを判断する(ステップS625B)。   In step S610B, as in step 610 of the embodiment, the enlargement processing unit M14 determines whether the target pixel is a white pixel. If it is determined that the target pixel is a white pixel (step S610B: YES), the pattern detection unit M142 of the enlargement processing unit M14 determines that the target pixel and its surrounding pixels are the following four types of identification in the simple enlarged image: It is determined whether or not any one of patterns 1 to 4 is formed (step S625B).

図18は、本変形例の横方向拡大処理における特定パターンとカウント用パターンについて説明する図である。本変形例における特定パターンは、実施例における元画像の特定パターン1〜4(図10)にそれぞれ対応する、拡大画像の特定パターン1〜4(図18)である。本変形例における拡大画像の特定パターン1〜4を対応特定パターンとも呼ぶ。例えば、対応特定パターン1〜4は、4つの縦方向の列を含む、縦3画素×横4画素(計12画素)のパターンである(図18)。対応特定パターン1〜4の中央の2列(2列目と3列目)は、元画像の特定パターン1〜4(図10)を構成する3つの縦方向の列のうち、中央の列と同じである。パターン検出部M142は、このような拡大画像の対応特定パターン1〜4を、単純拡大画像において検出することによって、実施例において補完画素を付加すべき位置として検出される拡大画像上の位置と同じ位置を、単純拡大画像において検出することができる。   FIG. 18 is a diagram for describing a specific pattern and a counting pattern in the horizontal enlargement process of the present modification. The specific patterns in this modification are specific patterns 1 to 4 (FIG. 18) of the enlarged image corresponding to the specific patterns 1 to 4 (FIG. 10) of the original image in the embodiment. The specific patterns 1 to 4 of the enlarged image in this modification are also referred to as corresponding specific patterns. For example, the correspondence specific patterns 1 to 4 are patterns of 3 vertical pixels × 4 horizontal pixels (12 pixels in total) including four vertical columns (FIG. 18). The middle two columns (second column and third column) of the corresponding specific patterns 1 to 4 are the central column of the three vertical columns constituting the specific patterns 1 to 4 (FIG. 10) of the original image. The same. The pattern detection unit M142 detects the corresponding specific patterns 1 to 4 of the enlarged image in the simple enlarged image, and thus is the same as the position on the enlarged image that is detected as the position where the complementary pixel is to be added in the embodiment. The position can be detected in a simple magnified image.

ステップS610Bにおいて、対象画素は白画素でないと判断された場合(ステップS610B:NO)、および、ステップS625Bにおいて、対象画素とその周辺画素とは、単純拡大画像において4種類の対応特定パターン1〜4のいずれも形成しないと判断された場合(ステップS625B:NO)には、拡大処理部M14は、ステップS635に処理を進める。   When it is determined in step S610B that the target pixel is not a white pixel (step S610B: NO), and in step S625B, the target pixel and its surrounding pixels are four types of corresponding specific patterns 1 to 4 in the simple enlarged image. If it is determined that none of these are formed (step S625B: NO), the enlargement processing unit M14 advances the process to step S635.

対象画素とその周辺画素とは、単純拡大画像において4種類の対応特定パターン1〜4のいずれかを形成すると判断された場合(ステップS625B:YES)には、拡大処理部M14は、エッジ補完処理を実行する(ステップS630B)。   When it is determined that the target pixel and the surrounding pixels form any of the four types of correspondence specific patterns 1 to 4 in the simple enlarged image (step S625B: YES), the enlargement processing unit M14 performs the edge complement processing. Is executed (step S630B).

本変形例のエッジ補完処理の処理フローは、実施例におけるエッジ補完処理(図11)と基本的に同じであるが、以下の点が異なる。
1)本変形例では、第1の連続数CLと第2の連続数CUのカウントは、単純拡大画像においてカウントされる。本変形例において、これらのカウントに用いられる第1のパターンLCP1〜LCP4および第2のパターンUCP1〜UCP4は、図18に示すように、対応特定パターン1〜4の一部分である横方向に並んだ4個の画素(上部分パターンUP1〜UP4および下部分パターンBP1〜BP4のいずれか)と同じパターンである。
The processing flow of the edge complementation process of the present modification is basically the same as the edge complementation process (FIG. 11) in the embodiment, except for the following points.
1) In the present modification, the first continuous number CL and the second continuous number CU are counted in the simple enlarged image. In the present modification, the first patterns LCP1 to LCP4 and the second patterns UCP1 to UCP4 used for these counts are arranged in the horizontal direction as a part of the corresponding specific patterns 1 to 4, as shown in FIG. This is the same pattern as four pixels (any one of the upper part patterns UP1 to UP4 and the lower part patterns BP1 to BP4).

このように、単純拡大画像において、第1の連続数CLおよび第2の連続数CUをカウントしても、実施例のように、元画像において第1の連続数CLおよび第2の連続数CUをカウントしても、結果的には、第1の連続数CLおよび第2の連続数CUは同じ値となる。この結果、いずれの場合であっても、連続数決定部M143は、補完数SCを、元画像における第1の連続数CLと第2の連続数CUに応じた数に、適切に決定することができる。   In this way, even if the first continuous number CL and the second continuous number CU are counted in the simple enlarged image, the first continuous number CL and the second continuous number CU in the original image as in the embodiment. As a result, the first continuous number CL and the second continuous number CU have the same value. As a result, in any case, the continuous number determination unit M143 appropriately determines the complement number SC to a number corresponding to the first continuous number CL and the second continuous number CU in the original image. Can do.

なお、本変形例においても、第1の連続数CLと第2の連続数CUのカウントは、実施例と同様に、元画像においてカウントされても良い。ただし、単純拡大画像においてカウントすれば、単純拡大画像データを生成した時点で、元画像データを消去しても良いので、処理に要するメモリ量を削減することができる。   In the present modification, the first continuous number CL and the second continuous number CU may be counted in the original image as in the embodiment. However, if counting is performed in a simple enlarged image, the original image data may be deleted when the simple enlarged image data is generated, so that the amount of memory required for processing can be reduced.

本変形例の横方向拡大処理を採用しても、実施例と同様の作用・効果を奏する。   Even if the lateral enlargement process of this modification is employed, the same operations and effects as in the embodiment are obtained.

(3)上記実施例の横方向拡大処理では、元画像に白画素と黒画素とによって構成される特定パターンが含まれる場合に、拡大画像に、黒画素を補完画素として付加しているが、白画素と黒画素の組合せに限らず、互いの色の相違が比較的大きい(基準値より大きい)色をそれぞれ表す第1種の画素と第2種の画素との組合せであれば良い。例えば、黒以外の色成分(例えば、RGBや、CMYのいずれか)の階調値を表す画素のうち、最大値近傍の色の画素と、最小値近傍の色の画素との組合せであっても良い。第1種の画素は、特定の階調値(例えば、RGBのいずれかの階調値、CMYKのいずれかの階調値)が、当該階調値が取り得る値の最大値および最小値のうちの一方である画素を含むことが好ましく、第2種の画素は、当該特定の階調値が、当該階調値が取り得る値の最大値および最小値のうちの他方である画素を含むことが好ましい。 (3) In the horizontal enlargement process of the above embodiment, when the original image includes a specific pattern composed of white pixels and black pixels, black pixels are added to the enlarged image as complementary pixels. The combination is not limited to the combination of white pixels and black pixels, and may be a combination of a first type pixel and a second type pixel each representing a color having a relatively large difference in color (greater than a reference value). For example, among pixels representing gradation values of color components other than black (for example, any one of RGB and CMY), a combination of a pixel of a color near the maximum value and a pixel of a color near the minimum value Also good. The first type pixel has a specific gradation value (for example, any one of RGB gradation values, any one of CMYK gradation values) having a maximum value and a minimum value that the gradation value can take. It is preferable that one of the pixels is included, and the second type pixel includes a pixel in which the specific gradation value is the other of the maximum value and the minimum value that the gradation value can take. It is preferable.

(4)上記実施例では、モノクロ印刷のための印刷データを生成しているが、これに代えて、カラー印刷のための印刷データを生成しても良い。例えば、RGB画像データや、カラー印刷に用いられる印刷材(具体的には、CMYKのトナー)に対応する色成分の階調値の組(具体的には、CMYKの階調値の組)を表すCMYK画素データで構成されたビットマップデータ(CMYK画像データ)に対して、上述した画像処理を行って良い。具体的には、プリンタドライバM10は、各色成分の画素値で表される各単色画像データに対して、それぞれ、上述した横方向拡大処理を含む処理(図2:S600〜S900)を実行して、CMYKの各色成分の圧縮ドットデータ300を生成しても良い。プリンタドライバM10は、圧縮ドットデータ300を用いて印刷データを生成して、印刷装置200に送信しても良い。 (4) In the above embodiment, print data for monochrome printing is generated, but instead, print data for color printing may be generated. For example, a set of gradation values of color components (specifically, a set of gradation values of CMYK) corresponding to RGB image data or a printing material (specifically, CMYK toner) used for color printing. The above-described image processing may be performed on bitmap data (CMYK image data) composed of CMYK pixel data to be represented. Specifically, the printer driver M10 executes processing (FIG. 2: S600 to S900) including the above-described lateral enlargement processing for each single color image data represented by the pixel value of each color component. The compressed dot data 300 for each color component of CMYK may be generated. The printer driver M <b> 10 may generate print data using the compressed dot data 300 and transmit the print data to the printing apparatus 200.

(5)上記実施例において、カウント用パターン(第1のパターンLCPと第2のパターンUCP)は、対応する特定パターンの一部である部分特定パターンと同じパターンであるが、部分特定パターンとは異なるパターンであっても良い。 (5) In the above embodiment, the counting pattern (the first pattern LCP and the second pattern UCP) is the same pattern as the partial specific pattern that is a part of the corresponding specific pattern. Different patterns may be used.

(6)なお、上記実施例では、ドット画像拡大部M18が、圧縮されていない無歪ドットデータを生成した後に、圧縮部M19が該無歪ドットデータを圧縮して圧縮ドットデータ300(図5)を生成している。これに代えて、ドット画像拡大部M18が、歪ドットデータを用いて、圧縮されていない無歪ドットデータを生成することなく、圧縮ドットデータ300を生成しても良い。具体的には、ドット画像拡大部M18は、歪ドットデータに含まれる各行データを圧縮して、無歪ドットデータにおける奇数行データ310A、320、330を生成する度に、偶数行データ310B(ONの参照フラグデータ)を、奇数行データの直後に付加するしても良い。ドット画像拡大部M18は、この処理を、歪ドットデータに含まれる全ての行データについて繰り返すことによって、圧縮されていない無歪ドットデータを生成することなく、圧縮された無歪ドットデータである圧縮ドットデータ300を生成しても良い。すなわち、ドット画像拡大部M18は、同一行の組を表す圧縮データを含む無歪ドットデータ(圧縮ドットデータ300)を、歪ドットデータを用いて生成しても良い。 (6) In the above embodiment, after the dot image enlargement unit M18 generates uncompressed undistorted dot data, the compression unit M19 compresses the undistorted dot data and compresses the compressed dot data 300 (FIG. 5). ) Is generated. Alternatively, the dot image enlargement unit M18 may generate the compressed dot data 300 without using the distorted dot data to generate uncompressed undistorted dot data. Specifically, the dot image enlargement unit M18 compresses each row data included in the distorted dot data to generate the odd row data 310A, 320, 330 in the undistorted dot data, and the even row data 310B (ON May be added immediately after the odd-numbered row data. The dot image enlargement unit M18 repeats this process for all the row data included in the distorted dot data, thereby generating compressed undistorted dot data without generating uncompressed undistorted dot data. The dot data 300 may be generated. That is, the dot image enlargement unit M18 may generate undistorted dot data (compressed dot data 300) including compressed data representing a set of the same row using the distorted dot data.

(7)上記実施例の画像処理において、ステップS800とS900(図2)の処理を省略して、S700において生成された歪ドットデータを印刷データとして、印刷装置200に供給しても良い。この場合には、印刷装置200の装置制御部M20が、歪ドットデータを用いて無歪ドットデータを生成し、生成した無歪ドットデータをプリンタエンジン250に供給しても良い。こうすれば、印刷装置200は、上記実施例と同様に、無歪ドットデータが表す無歪ドット画像GD2を印刷することができる。 (7) In the image processing of the above embodiment, the processing in steps S800 and S900 (FIG. 2) may be omitted, and the distorted dot data generated in S700 may be supplied to the printing apparatus 200 as print data. In this case, the apparatus control unit M20 of the printing apparatus 200 may generate undistorted dot data using the distorted dot data and supply the generated undistorted dot data to the printer engine 250. In this way, the printing apparatus 200 can print the undistorted dot image GD2 represented by the undistorted dot data, as in the above embodiment.

(8)上記実施例におけるプリンタドライバM10の各機能部M12〜M19は、印刷装置200の制御回路212によって実現されても良い。すなわち、印刷装置200の制御回路212において、上述した画像処理が実行されても良い。この場合には、印刷装置200における画像処理によって、印刷画像におけるエッジの見栄えを向上することができる。 (8) The functional units M12 to M19 of the printer driver M10 in the above embodiment may be realized by the control circuit 212 of the printing apparatus 200. That is, the above-described image processing may be executed in the control circuit 212 of the printing apparatus 200. In this case, the appearance of the edge in the print image can be improved by the image processing in the printing apparatus 200.

(9)上記各実施例において、ハードウェアによって実現されていた構成の一部をソフトウェアに置き換えるようにしてもよく、逆に、ソフトウェアによって実現されていた構成の一部あるいは全部をハードウェアに置き換えるようにしてもよい。 (9) In each of the above embodiments, a part of the configuration realized by hardware may be replaced with software, and conversely, part or all of the configuration realized by software is replaced with hardware. You may do it.

以上、実施例、変形例に基づき本発明について説明してきたが、上記した発明の実施の形態は、本発明の理解を容易にするためのものであり、本発明を限定するものではない。本発明は、その趣旨並びに特許請求の範囲を逸脱することなく、変更、改良され得ると共に、本発明にはその等価物が含まれる。   As mentioned above, although this invention was demonstrated based on the Example and the modification, Embodiment mentioned above is for making an understanding of this invention easy, and does not limit this invention. The present invention can be changed and improved without departing from the spirit and scope of the claims, and equivalents thereof are included in the present invention.

100...計算装置、110...CPU、120...内部記憶装置、130...外部記憶装置、132...ドライバプログラム、134...画像データ、170...操作部、180...表示部、190...通信部、200...印刷装置、210...集積回路、212...制御回路、214...揮発性メモリ、216...不揮発性メモリ、250...プリンタエンジン、270...操作部、280...表示部、290...通信部、M10...プリンタドライバ、M20...装置制御部、M12...画像データ取得部、M14...拡大処理部、M16...ハーフトーン処理部、M18...ドット画像拡大部、M19...圧縮部、M141...対象画素選択部、M142...パターン検出部、M143...連続数決定部、M144...画素群選択部、M145...画素データ設定部 DESCRIPTION OF SYMBOLS 100 ... Calculation apparatus, 110 ... CPU, 120 ... Internal storage device, 130 ... External storage device, 132 ... Driver program, 134 ... Image data, 170 ... Operation unit, 180 ... display unit, 190 ... communication unit, 200 ... printing device, 210 ... integrated circuit, 212 ... control circuit, 214 ... volatile memory, 216 ... nonvolatile memory , 250 ... Printer engine, 270 ... Operation unit, 280 ... Display unit, 290 ... Communication unit, M10 ... Printer driver, M20 ... Device control unit, M12 ... Image data Acquisition unit, M14 ... enlargement processing unit, M16 ... halftone processing unit, M18 ... dot image enlargement unit, M19 ... compression unit, M141 ... target pixel selection unit, M142 ... pattern Detection unit, M143 ... continuous number determination unit, M144 ... pixel group selection unit, M145 ... pixel data setting unit

Claims (11)

画像処理装置であって、
第1種の画素と第2種の画素を含む元画像を表す元画像データを取得する取得部と、
前記元画像データに対して拡大処理を実行して、前記元画像を第1の方向に拡大した拡大画像を表す拡大画像データを生成する拡大処理部と、
を備え、
前記拡大処理部は、
前記元画像内に前記第1種の画素と前記第2種の画素とによって構成される特定パターンが含まれる場合に、前記拡大画像内の前記第1の方向と交差する第2の方向に延びる画素群を選択する画素群選択部であって、前記拡大画像内の前記画素群は、前記元画像内の特定画素に対応する対応特定画素と、前記対応特定画素の前記第2の方向に位置する画素と、を含み、前記元画像内の前記特定画素は、前記特定パターンを構成する特定の前記第1種の画素に対応する画素であり、前記拡大画像内の前記画素群を構成する画素の数は、第1の連続数と第2の連続数とに応じた数であり、前記第1の連続数は、前記元画像において前記特定画素から前記第2の方向に向かって第1のパターンが連続する数であり、前記第2の連続数は、前記元画像において前記特定画素から前記第2の方向の反対方向に向かって第2のパターンが連続する数であり、前記第1のパターンは、前記特定パターンのうち、前記第2の方向の側の一部に基づくパターンであり、前記第2のパターンは、前記特定パターンのうち、前記第2の方向の前記反対方向の側の一部に基づくパターンである、前記画素群選択部と、
前記拡大画像内の前記画素群のうち、前記第1の方向において前記第2種の画素に隣接する画素を、前記第2種の画素に設定する設定部と、
を備える、画像処理装置。
An image processing apparatus,
An acquisition unit that acquires original image data representing an original image including the first type of pixels and the second type of pixels;
An enlargement processing unit that executes enlargement processing on the original image data and generates enlarged image data representing an enlarged image obtained by enlarging the original image in a first direction;
With
The enlargement processing unit
When the original image includes a specific pattern constituted by the first type pixel and the second type pixel, the original image extends in a second direction that intersects the first direction in the enlarged image. A pixel group selection unit that selects a pixel group, wherein the pixel group in the enlarged image is positioned in the second direction of the corresponding specific pixel corresponding to the specific pixel in the original image and the corresponding specific pixel The specific pixel in the original image is a pixel corresponding to the specific first type pixel that forms the specific pattern, and the pixel that forms the pixel group in the enlarged image Is a number according to the first continuous number and the second continuous number, and the first continuous number is a first number from the specific pixel toward the second direction in the original image. The number of continuous patterns, and the second continuous number is the original image Oite wherein Ri number der the second pattern is continuous from the specific pixel toward the opposite direction of the second direction, said first pattern, said one of the specific pattern, on the side of the second direction a part based pattern, said second pattern, said one of the specific pattern, wherein the Ru pattern der based on part of the opposite direction of the side, the pixel group selector in the second direction,
A setting unit that sets a pixel adjacent to the second type pixel in the first direction in the pixel group in the enlarged image as the second type pixel;
An image processing apparatus comprising:
請求項1に記載の画像処理装置であって、
前記第1のパターンは、前記第1種の画素である第1の中央画素と、前記第1の中央画素に対して前記第1の方向に隣接する前記第1種の画素である第1隣接画素と、前記第1の中央画素に対して前記第1の方向の反対方向に隣接する前記第2種の画素である第2隣接画素と、を含むパターンであり、
前記第2のパターンは、前記第2種の画素である第2の中央画素と、前記第2の中央画素に対して前記第1の方向に隣接する前記第1種の画素である第3隣接画素と、を含むパターンであり、
前記第1の中央画素の前記第1の方向の位置と、前記第2の中央画素の前記第1の方向の位置とは、前記元画像内の前記特定画素の前記第1の方向の位置と同じである、画像処理装置。
The image processing apparatus according to claim 1,
The first pattern includes a first central pixel that is the first type of pixel, and a first adjacent that is the first type of pixel that is adjacent to the first central pixel in the first direction. A pattern including a pixel and a second adjacent pixel that is the second type of pixel adjacent to the first central pixel in a direction opposite to the first direction;
The second pattern includes a second central pixel that is the second type pixel, and a third adjacent pixel that is the first type pixel adjacent to the second central pixel in the first direction. A pattern including pixels,
The position of the first central pixel in the first direction and the position of the second central pixel in the first direction are the position of the specific pixel in the original image in the first direction. An image processing apparatus that is the same.
請求項1または請求項2に記載の画像処理装置であって、
前記第1のパターンは、前記特定パターンの一部である第1部分パターンであり、
前記第2のパターンは、前記特定パターンの一部であり、前記第1部分パターンと異なる第2部分パターンである、画像処理装置。
The image processing apparatus according to claim 1 or 2,
The first pattern is a first partial pattern that is a part of the specific pattern,
The image processing apparatus, wherein the second pattern is a second partial pattern that is a part of the specific pattern and is different from the first partial pattern.
請求項1ないし請求項3のいずれかに記載の画像処理装置であって、
前記特定パターンは、前記特定画素に対して前記第2の方向に隣接する第1部分パターンと、前記特定画素に対して前記第2の方向の反対方向に隣接する第2部分パターンと、を含み、
前記第1部分パターンは、前記特定画素に対して前記第2の方向に隣接する中央画素と、前記中央画素に対して前記第1の方向に隣接する前記第1種の画素である第1周辺画素と、前記中央画素に対して前記第1の方向の反対方向に隣接する前記第2種の画素である第2周辺画素と、を含むパターンであり、
前記第2部分パターンは、前記特定画素に対して前記第2の方向の反対方向に隣接する前記第2種の画素である第3周辺画素と、前記第3周辺画素に対して前記第1の方向に隣接する前記第1種の画素である第4周辺画素と、を含むパターンである、画像処理装置。
An image processing apparatus according to any one of claims 1 to 3,
The specific pattern includes a first partial pattern adjacent to the specific pixel in the second direction, and a second partial pattern adjacent to the specific pixel in a direction opposite to the second direction. ,
The first partial pattern is a central pixel that is adjacent to the specific pixel in the second direction, and a first periphery that is the first type of pixel that is adjacent to the central pixel in the first direction. A pattern including a pixel and a second peripheral pixel that is the second type of pixel adjacent to the central pixel in a direction opposite to the first direction,
The second partial pattern includes a third peripheral pixel that is the second type of pixel adjacent to the specific pixel in a direction opposite to the second direction, and the first peripheral pixel is the first peripheral pixel. An image processing apparatus, comprising: a fourth peripheral pixel that is the first type of pixel adjacent in the direction.
請求項1ないし請求項4のいずれかに記載の画像処理装置であって、
前記拡大処理部は、
前記第1の連続数が前記第2の連続数より多い場合には、前記画素群を構成する画素の数を、前記第2の連続数を用いて決定し、前記第1の連続数が前記第2の連続数より小さい場合には、前記画素群を構成する画素の数を、前記第1の連続数を用いて決定する決定部を備える、画像処理装置。
An image processing apparatus according to any one of claims 1 to 4,
The enlargement processing unit
When the first continuous number is greater than the second continuous number, the number of pixels constituting the pixel group is determined using the second continuous number, and the first continuous number is An image processing apparatus comprising: a determination unit that determines the number of pixels constituting the pixel group using the first continuous number when the number is smaller than the second continuous number.
請求項1ないし請求項5のいずれかに記載の画像処理装置であって、
前記拡大処理部は、前記元画像を構成する複数の画素の中から順次に対象画素を選択する対象画素選択部を備え、
前記拡大処理部は、前記対象画素が選択される度に、第1処理と第2処理とを含む複数の処理のうちのいずれかを実行することによって、前記拡大画像データを生成し、
前記第1処理は、前記対象画素が前記特定画素を含む場合に実行される処理であって、前記画素群選択部による前記画素群の選択と、前記設定部による前記画素群を構成する画素の設定と、を含む処理であり、
前記第2処理は、前記対象画素が前記特定画素を含まない場合に実行される処理であって、前記画素群選択部による前記画素群の選択と、前記設定部による前記画素群を構成する画素の設定と、を含まない処理である、画像処理装置。
An image processing apparatus according to any one of claims 1 to 5,
The enlargement processing unit includes a target pixel selection unit that sequentially selects a target pixel from among a plurality of pixels constituting the original image,
The enlargement processing unit generates the enlarged image data by executing one of a plurality of processes including a first process and a second process each time the target pixel is selected,
The first process is a process that is executed when the target pixel includes the specific pixel, and the selection of the pixel group by the pixel group selection unit and the setting of the pixel group that constitutes the pixel group by the setting unit. And processing including setting,
The second process is a process that is executed when the target pixel does not include the specific pixel, and the pixel group selection unit by the pixel group selection unit and the pixels that configure the pixel group by the setting unit The image processing apparatus is a process that does not include the setting.
請求項1ないし請求項6のいずれかに記載の画像処理装置であって、
前記拡大処理部は、歪みのない前記元画像に対して前記拡大処理を実行して、歪みのある前記拡大画像を表す前記拡大画像データを生成し、
前記画像処理装置は、ドット画像を印刷する印刷実行部のための装置であり、
前記画像処理装置は、さらに、
前記拡大処理部によって生成された歪みのある前記拡大画像を表す前記拡大画像データに対して、画素毎にドットの形成状態を表すドットデータを生成するハーフトーン処理を実行して、歪みのある歪ドット画像を表す歪ドットデータを生成するハーフトーン処理部と、
前記歪ドットデータに対して前記拡大処理とは異なる処理を実行して、前記歪ドット画像を少なくとも前記第2の方向に拡大した歪みのない無歪ドット画像を表す無歪ドットデータを生成するドット画像拡大部と、
を備える、画像処理装置。
An image processing apparatus according to any one of claims 1 to 6,
The enlargement processing unit performs the enlargement process on the original image without distortion, and generates the enlarged image data representing the enlarged image with distortion,
The image processing apparatus is an apparatus for a print execution unit that prints a dot image;
The image processing apparatus further includes:
A halftone process for generating dot data representing a dot formation state for each pixel is performed on the enlarged image data representing the enlarged image with distortion generated by the enlargement processing unit, and distortion with distortion is performed. A halftone processing unit for generating distorted dot data representing a dot image;
Dots that perform processing different from the enlargement processing on the distorted dot data to generate undistorted dot data representing an undistorted dot image in which the distorted dot image is expanded at least in the second direction. An image magnifier,
An image processing apparatus comprising:
請求項7に記載の画像処理装置であって、
前記無歪ドット画像は、同一行の組を複数個含み、
前記同一行の組は、前記無歪ドット画像を構成する前記第1の方向に沿った複数の行のうち、互いに隣接するとともに、各構成画素のドットの形成状態が互いに同一である2以上の行を含む組であり、
前記無歪ドットデータは、前記同一行の組を表す圧縮データを含み、
前記圧縮データは、1つの代表行を表す代表行データと、前記代表行データが繰り返されることを示すデータと、を含む、画像処理装置。
The image processing apparatus according to claim 7,
The undistorted dot image includes a plurality of sets of the same row,
The set of the same row is adjacent to each other among a plurality of rows along the first direction constituting the undistorted dot image, and two or more dot formation states of the constituent pixels are the same. A set containing lines,
The undistorted dot data includes compressed data representing the set of the same row,
The compressed data includes an image processing apparatus including representative row data representing one representative row and data indicating that the representative row data is repeated.
請求項1ないし請求項8のいずれかに記載の画像処理装置であって、
前記拡大処理部は、前記元画像において前記特定パターンを検出する検出部を備え、
前記拡大処理部は、検出された前記特定パターンについて、前記画素群選択部による前記画素群の選択と、前記設定部による前記画素群を構成する画素の設定と、を実行する、画像処理装置。
An image processing apparatus according to any one of claims 1 to 8,
The enlargement processing unit includes a detection unit that detects the specific pattern in the original image,
The enlargement processing unit is configured to perform selection of the pixel group by the pixel group selection unit and setting of pixels constituting the pixel group by the setting unit with respect to the detected specific pattern.
請求項1ないし請求項8のいずれかに記載の画像処理装置であって、
前記拡大処理部は、前記拡大画像において、前記元画像の前記特定パターンに対応する対応特定パターンを検出する検出部を備え、
前記拡大処理部は、検出された前記対応特定パターンについて、前記画素群選択部による前記画素群の選択と、前記設定部による前記画素群を構成する画素の設定と、を実行する、画像処理装置。
An image processing apparatus according to any one of claims 1 to 8,
The enlargement processing unit includes a detection unit that detects a corresponding specific pattern corresponding to the specific pattern of the original image in the enlarged image,
The enlargement processing unit executes selection of the pixel group by the pixel group selection unit and setting of pixels constituting the pixel group by the setting unit for the detected correspondence specific pattern. .
画像処理プログラムであって、
第1種の画素と第2種の画素を含む元画像を表す元画像データを取得する取得機能と、
前記元画像データに対して拡大処理を実行して、前記元画像を第1の方向に拡大した拡大画像を表す拡大画像データを生成する拡大処理機能と、
をコンピュータに実現させ、
前記拡大処理機能は、
前記元画像内に前記第1種の画素と前記第2種の画素とによって構成される特定パターンが含まれる場合に、前記拡大画像内の前記第1の方向と交差する第2の方向に延びる画素群を選択する画素群選択機能であって、前記拡大画像内の前記画素群は、前記元画像内の特定画素に対応する対応特定画素と、前記対応特定画素の前記第2の方向に位置する画素と、を含み、前記元画像内の前記特定画素は、前記特定パターンを構成する特定の前記第1種の画素に対応する画素であり、前記拡大画像内の前記画素群を構成する画素の数は、第1の連続数と第2の連続数とに応じた数であり、前記第1の連続数は、前記元画像において前記特定画素から前記第2の方向に向かって第1のパターンが連続する数であり、前記第2の連続数は、前記元画像において前記特定画素から前記第2の方向の反対方向に向かって第2のパターンが連続する数であり、前記第1のパターンは、前記特定パターンのうち、前記第2の方向の側の一部に基づくパターンであり、前記第2のパターンは、前記特定パターンのうち、前記第2の方向の前記反対方向の側の一部に基づくパターンである、前記画素群選択機能と、
前記拡大画像内の前記画素群のうち、前記第1の方向において前記第2種の画素に隣接する画素を、前記第2種の画素に設定する設定機能と、
を備える、画像処理プログラム。
An image processing program,
An acquisition function for acquiring original image data representing an original image including a first type pixel and a second type pixel;
An enlargement processing function for executing enlargement processing on the original image data and generating enlarged image data representing an enlarged image obtained by enlarging the original image in a first direction;
Is realized on a computer,
The enlargement processing function is:
When the original image includes a specific pattern constituted by the first type pixel and the second type pixel, the original image extends in a second direction that intersects the first direction in the enlarged image. A pixel group selection function for selecting a pixel group, wherein the pixel group in the enlarged image is positioned in the second direction of the corresponding specific pixel corresponding to the specific pixel in the original image and the corresponding specific pixel The specific pixel in the original image is a pixel corresponding to the specific first type pixel that forms the specific pattern, and the pixel that forms the pixel group in the enlarged image Is a number according to the first continuous number and the second continuous number, and the first continuous number is a first number from the specific pixel toward the second direction in the original image. The number of consecutive patterns, and the second consecutive number is the original image Ri number der the second pattern is continuous toward the opposite direction of the second direction from the specified pixel in the first pattern, of the specific pattern, on the side of the second direction one- a pattern based on parts, the second pattern, of the specific pattern, the Ru pattern der based on a part of the opposite direction of the side of the second direction, and the pixel group selection function,
A setting function for setting a pixel adjacent to the second type pixel in the first direction in the pixel group in the enlarged image as the second type pixel;
An image processing program.
JP2012042224A 2012-02-28 2012-02-28 Image processing apparatus and image processing program Active JP5927984B2 (en)

Priority Applications (2)

Application Number Priority Date Filing Date Title
JP2012042224A JP5927984B2 (en) 2012-02-28 2012-02-28 Image processing apparatus and image processing program
US13/763,983 US8855445B2 (en) 2012-02-28 2013-02-11 Image processing apparatus

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2012042224A JP5927984B2 (en) 2012-02-28 2012-02-28 Image processing apparatus and image processing program

Publications (2)

Publication Number Publication Date
JP2013179474A JP2013179474A (en) 2013-09-09
JP5927984B2 true JP5927984B2 (en) 2016-06-01

Family

ID=49002959

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2012042224A Active JP5927984B2 (en) 2012-02-28 2012-02-28 Image processing apparatus and image processing program

Country Status (2)

Country Link
US (1) US8855445B2 (en)
JP (1) JP5927984B2 (en)

Families Citing this family (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2013066303A1 (en) * 2011-10-31 2013-05-10 Hewlett-Packard Development Company, L.P. Method and system for halftone printing

Family Cites Families (15)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH08227456A (en) * 1994-09-22 1996-09-03 Casio Comput Co Ltd Device and method for smoothing dot pattern
US5742300A (en) 1995-01-03 1998-04-21 Xerox Corporation Resolution enhancement and thinning method for printing pixel images
TW377431B (en) * 1995-04-14 1999-12-21 Hitachi Ltd Method and apparatus for changing resolution
JPH11175710A (en) * 1997-12-16 1999-07-02 Sharp Corp Picture forming device
JP2002024815A (en) * 2000-06-13 2002-01-25 Internatl Business Mach Corp <Ibm> Image conversion method for converting into enlarged image data, image processing device, and image display device
JP4057337B2 (en) 2002-04-24 2008-03-05 東芝テック株式会社 Image processing apparatus and image forming apparatus
JP4799009B2 (en) * 2005-02-17 2011-10-19 キヤノン株式会社 Image processing apparatus and method
JP4510069B2 (en) * 2007-12-10 2010-07-21 シャープ株式会社 Image processing apparatus, image display apparatus, image forming apparatus, image processing method, computer program, and storage medium
US8472753B2 (en) * 2008-01-10 2013-06-25 Samsung Electronics Co., Ltd. Method and system of adaptive reformatting of digital image
JP2010003251A (en) * 2008-06-23 2010-01-07 Panasonic Corp Image resizing device and image resizing method
JP2010120329A (en) * 2008-11-21 2010-06-03 Seiko Epson Corp Image processing of reducing jaggy of printing image
US8400473B2 (en) * 2009-06-24 2013-03-19 Ariel Shamir Multi-operator media retargeting
US8483513B2 (en) * 2010-01-22 2013-07-09 Corel Corporation, Inc. Method of content aware image resizing
US8571309B2 (en) * 2011-11-15 2013-10-29 At&T Intellectual Property I, L.P. System and method of image upsampling
JP5966434B2 (en) * 2012-02-28 2016-08-10 ブラザー工業株式会社 Image processing apparatus and image processing program

Also Published As

Publication number Publication date
JP2013179474A (en) 2013-09-09
US20130223765A1 (en) 2013-08-29
US8855445B2 (en) 2014-10-07

Similar Documents

Publication Publication Date Title
JP2010118927A (en) Program, recording medium, image processing apparatus, image processing method, and sheet for gradation correction parameter generation
US8098960B2 (en) Image processing apparatus, computer readable medium storing program, image processing method, and computer data signal
JP5882713B2 (en) Image processing apparatus, image processing method, and computer program
US7570807B2 (en) Image processing apparatus, image forming system, computer readable medium storing program and image processing method
JP5494641B2 (en) Color conversion table creation device, color conversion table creation method and program
JP2008022153A (en) Device and method for processing image
JP5927984B2 (en) Image processing apparatus and image processing program
US7809199B2 (en) Image processing apparatus
JP2010278948A (en) Image processing apparatus
JP5103304B2 (en) Image processing apparatus, image processing method, and image processing program
JP5966434B2 (en) Image processing apparatus and image processing program
US11423268B2 (en) Image processing apparatus, image processing apparatus control method, and storage medium
JP6758928B2 (en) Image processing equipment, image processing methods, and programs
JP2019146037A (en) Image processing apparatus and method for controlling the same, and program
JP7381211B2 (en) Image processing device and image processing method
JP5649552B2 (en) Image processing apparatus and image forming apparatus
JP4983947B2 (en) Halftone image generation apparatus and halftone image generation method
JP6750357B2 (en) Image processing apparatus, image processing method and program
US20130057923A1 (en) Image processing system, method, program, and storage medium
JP7238485B2 (en) image forming device
JP2004025621A (en) Dot gradation expression method, computer program, and computer readable storage medium
JP2012000895A (en) Image forming apparatus and image processing method
JP2006243858A (en) Generation of print data according to paper size
EP2469833A2 (en) Image processing apparatus using threshold matrix of resolution higher than resolution of input image
JP2005348158A (en) Image processing apparatus and image processing method

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20150123

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20151218

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20160105

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20160303

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

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20160411

R150 Certificate of patent or registration of utility model

Ref document number: 5927984

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150