JP4172399B2 - Image processing apparatus and program - Google Patents

Image processing apparatus and program Download PDF

Info

Publication number
JP4172399B2
JP4172399B2 JP2004027106A JP2004027106A JP4172399B2 JP 4172399 B2 JP4172399 B2 JP 4172399B2 JP 2004027106 A JP2004027106 A JP 2004027106A JP 2004027106 A JP2004027106 A JP 2004027106A JP 4172399 B2 JP4172399 B2 JP 4172399B2
Authority
JP
Japan
Prior art keywords
image data
pixel
data
value
binary
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.)
Expired - Fee Related
Application number
JP2004027106A
Other languages
Japanese (ja)
Other versions
JP2005027270A (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.)
Fujifilm Business Innovation Corp
Original Assignee
Fuji Xerox Co Ltd
Fujifilm Business Innovation Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fuji Xerox Co Ltd, Fujifilm Business Innovation Corp filed Critical Fuji Xerox Co Ltd
Priority to JP2004027106A priority Critical patent/JP4172399B2/en
Publication of JP2005027270A publication Critical patent/JP2005027270A/en
Application granted granted Critical
Publication of JP4172399B2 publication Critical patent/JP4172399B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Description

本発明は、多値画像を2値画像に変換して出力する画像処理装置に関する。   The present invention relates to an image processing apparatus that converts a multi-value image into a binary image and outputs the binary image.

近年、製版工程においては、デジタル化された印刷原稿のデータを使用し,印刷用の刷版をデジタル製版装置により直接作製する、CTP(computer to plate)と呼ばれる方法が採られている。CTPにより印刷用の刷版を作成する場合、ページ記述言語で記述された原稿のデータを、RIP(Raster Image Processing)処理により網点成分を有する2値画像データに変換し、この2値画像データから刷版を作成する。   In recent years, in the plate making process, a method called CTP (computer to plate) has been adopted in which digitized printing original data is used and a printing plate for printing is directly produced by a digital plate making apparatus. When creating a printing plate for printing by CTP, document data described in a page description language is converted into binary image data having a halftone dot component by RIP (Raster Image Processing) processing, and this binary image data Make a plate from

さて、CTPにより刷版を作成した場合、原稿の校正を行う際には、RIP処理により2値化された画像データを、通常、DDCP(direct digital color proof)と呼ばれる色校正システムに出力することにより、校正刷りを得るが、近年、RIP処理により2値化された画像データをカラープリンタに出力することにより、DDCPのような高額な機器を用いることなく、校正刷りを得る方法・装置が開発されている(例えば、特許文献1参照)。   Now, when a printing plate is created by CTP, when proofing a document, image data binarized by RIP processing is usually output to a color proofing system called DDCP (direct digital color proof). In recent years, a method and apparatus has been developed to obtain proof prints without using expensive equipment such as DDCP by outputting image data binarized by RIP processing to a color printer. (For example, refer to Patent Document 1).

図26は、特許文献1に記載されているカラー出力装置の構成を示すブロック図である。特許文献1に記載されているカラー出力装置においては、まず、RIP処理により2値化された画像データDが多値変換手段11へ供給される。この画像データは網点成分を有している。次に、多値変換手段11が、供給された2値の画像データを擬似的に多値の画像データDoに変換し、ディスクリーニング手段12が、この画像データDoに対してディスクリーニング処理を施す。これにより、画像データDoから網点成分が除去され、中間調を有する画像データDdが生成される。次に、この画像データDdに色補正を施すための色補正データDcが色補正テーブル13から読み出される。色補正手段14において、この色補正データDcと網点成分を有する多値の画像データDoとが加算され、加算により得られた画像データDxが誤差拡散処理手段15に入力される。誤差拡散処理手段15は、入力された画像データに誤差拡散処理を施すことにより、多値画像データを2値画像データに変換し、変換した画像データDzを出力手段2へ出力する。こうして出力された画像データDzは、当初の網点成分を有し、カラーマッチングが施された画像データとなるから、精度の高い校正刷りを得ることができる。   FIG. 26 is a block diagram showing the configuration of the color output device described in Patent Document 1. In FIG. In the color output device described in Patent Document 1, first, image data D binarized by RIP processing is supplied to the multi-value conversion means 11. This image data has a halftone dot component. Next, the multi-value conversion means 11 artificially converts the supplied binary image data into multi-value image data Do, and the descreening means 12 performs a descreening process on the image data Do. . Thereby, the halftone dot component is removed from the image data Do, and the image data Dd having a halftone is generated. Next, color correction data Dc for performing color correction on the image data Dd is read from the color correction table 13. The color correction unit 14 adds the color correction data Dc and the multivalued image data Do having a halftone component, and the image data Dx obtained by the addition is input to the error diffusion processing unit 15. The error diffusion processing unit 15 converts the multi-valued image data into binary image data by performing error diffusion processing on the input image data, and outputs the converted image data Dz to the output unit 2. The image data Dz output in this way has the original halftone dot component and is image data that has been subjected to color matching, so that a highly accurate proof can be obtained.

また、カラープリンタの特性にあった色補正処理を2値画像データに対して施す技術として、例えば、特許文献2に記載されている技術が知られている。特許文献2に記載されている画像データ処理方法では、まず、2値画像データが多値の画像データに変換された後、カラープリンタの特性にあうように色補正処理が施され、次いで、この色補正処理が施された多値画像データが2値化され、多値化データに見合う印刷画素数が決定される。印刷画素数が決定されると、2値画像データの画素配置を参照することにより印刷画素が配置され、印刷画素の増減がある場合には、テーブルを参照してどの位置の画素を増減させるかが決定される。画素を配置する時に生じる誤差、特に多値から2値への変換で生じる誤差は他の画素に拡散される。特許文献2に記載されている画像データ処理方法では、このような処理により、カラープリンタに最適な2値画像データが生成され、原稿の画像に近い画像を得ることができる。
特開2001−144979号公報 特許第2877356号明細書
For example, a technique described in Patent Document 2 is known as a technique for performing color correction processing suitable for the characteristics of a color printer on binary image data. In the image data processing method described in Patent Document 2, first, after binary image data is converted into multi-value image data, color correction processing is performed so as to match the characteristics of the color printer. The multi-valued image data that has been subjected to the color correction processing is binarized, and the number of print pixels corresponding to the multi-valued data is determined. When the number of print pixels is determined, the print pixels are arranged by referring to the pixel arrangement of the binary image data, and when there is an increase / decrease in the print pixels, which position of the pixel is increased / decreased by referring to the table Is determined. Errors that occur when pixels are arranged, particularly errors that occur in conversion from multivalue to binary, are diffused to other pixels. In the image data processing method described in Patent Document 2, binary image data that is optimal for a color printer is generated by such processing, and an image close to an image of a document can be obtained.
Japanese Patent Laid-Open No. 2001-144799 Japanese Patent No. 2877356

特許文献1に記載されているカラー出力装置では、多値の画像データの画素値が例えば0〜255の値をとるとした場合、色補正後の多値画像データの画素値の範囲も0〜255としていた。このため、例えば、色補正前の多値画像データDoの画素値が「0」であり、色補正データDcの画素値が「−5」である場合、色補正後の画像データの画素値は、下限である「0」になってしまい、色補正データを反映した内容にならなかった。   In the color output device described in Patent Document 1, when the pixel value of multi-valued image data takes a value of, for example, 0 to 255, the pixel value range of the multi-valued image data after color correction is also 0 to 0. It was 255. Therefore, for example, when the pixel value of the multivalued image data Do before color correction is “0” and the pixel value of the color correction data Dc is “−5”, the pixel value of the image data after color correction is Therefore, the lower limit is “0”, and the content does not reflect the color correction data.

色補正は、正確な校正刷りを得るために正確に施す必要がある。しかしながら、特許文献1に記載されているカラー出力装置は、色補正の結果を多値画像データと加算する際、上述したように、多値化された画像データがとる値の範囲を超えた分を切り捨ててしまい、せっかく補正した色の情報を欠落させてしまう場合がある。このため、特許文献1に開示されているカラー出力装置においては、折角施した色補正が正確に適用されず、精度良く色補正が施された校正刷りを得ることができないという問題が生じ得る。また、出力される画像データDzにおいて、RIP処理により2値化された画像データDが有していた網点成分は基本的には保持されるものの、誤差拡散により生じる黒画素や白画素は、2値化された画像データDが有していた網点成分とは無関係に生じてしまうという問題があった。   Color correction must be accurately performed to obtain an accurate proof. However, when the color output device described in Patent Document 1 adds the result of color correction to multi-valued image data, as described above, the amount exceeding the range of values taken by the multi-valued image data. May be omitted, and the corrected color information may be lost. For this reason, in the color output device disclosed in Patent Document 1, the color correction performed at the corner is not applied accurately, and there is a problem that it is not possible to obtain a proof printed with the color correction performed accurately. In addition, in the output image data Dz, although the halftone dot component that the image data D binarized by the RIP process has is basically retained, black pixels and white pixels generated by error diffusion are There has been a problem that it occurs regardless of the halftone dot component that the binarized image data D had.

これに対し、特許文献2に記載されている方法では、特許文献1に記載されているカラー出力方法のように、色補正時のデータが切り捨てられてしまうことがなく、プリンタの色特性にあった画像を出力することができる。しかしながら、特許文献2に記載されている方法では、多値の画像データを2値の画像データに変換する際、予め具備しているテーブルを参照してどの位置の画素を増減させるかが決定される。このような方法では、入力される2値の画像データが有する網点成分の周期と、テーブルにより増減される画素の周期とが一致していないと、出力する画像にビートが発生してしまうという問題が生じてしまう。   On the other hand, in the method described in Patent Document 2, unlike the color output method described in Patent Document 1, data at the time of color correction is not discarded, and the color characteristics of the printer are met. Images can be output. However, in the method described in Patent Document 2, when converting multi-valued image data to binary image data, it is determined which pixel to increase or decrease by referring to a previously provided table. The In such a method, if the period of the halftone dot component included in the input binary image data does not match the period of the pixels that are increased or decreased by the table, a beat occurs in the output image. Problems arise.

本発明は、上述した事情に鑑みてなされたものであり、入力される2値の画像データが有する網点成分を保持しつつ色補正の補正結果を精度よく反映した2値画像を出力する技術を提供することを目的とする。   The present invention has been made in view of the above-described circumstances, and outputs a binary image that accurately reflects the correction result of color correction while retaining the halftone dot component of the input binary image data. The purpose is to provide.

上述した課題を解決するために本発明は、2値画像データを受け取る2値画像入力手段と、前記2値画像データを多値化して所定の処理が施された多値画像データまたは前記2値画像データの画像と同じ画像を表す多値の画像データに所定の処理が施された多値画像データを受け取る多値画像入力手段と、供給される誤差データと、前記多値画像入力手段から画素単位で供給される多値画像データの画素値とを画素単位で加算して誤差加算データを生成する画像補正手段と、前記画像補正手段が生成した誤差加算データを閾値により2値化して再2値化画像データを生成する比較手段と、前記2値画像入力手段が受け取った2値画像データにおける注目画素が、該2値画像データが示す画像のエッジ部分の画素であるか否か検知し、該2値画像データにおける注目画素が該画像のエッジ部分の画素である場合には、前記比較手段が生成した再2値化画像データを選択するように指示する画素値選択信号を出力し、該2値画像データにおける注目画素が該画像のエッジ部分の画素でない場合には、前記2値画像入力手段が受け取った2値画像データを選択するよう指示する画素値選択信号を出力する画素判定手段と、前記画素判定手段が出力した画素値選択信号に従い、前記2値画像入力手段が受け取った2値画像データまたは前記比較手段が生成した再2値化画像データを選択し、出力2値データとして出力するセレクタ手段と、前記画像補正手段が生成した誤差加算データと前記セレクタ手段が出力した出力2値データとを用いて、2値化により生じた誤差を示す2値化誤差データを求める誤差算出手段と、前記画像補正手段において前記多値画像データの画素値に加算される前記誤差データを、前記誤差算出手段により求められた2値化誤差データを用いて求め、求めた誤差データを前記画像補正手段に供給する補正算出手段と、を有する画像処理装置を提供する。 In order to solve the above-described problem, the present invention provides binary image input means for receiving binary image data, multi-valued image data obtained by multi-leveling the binary image data and subjected to predetermined processing, or the binary value. Multi-value image input means for receiving multi- value image data obtained by performing predetermined processing on multi-value image data representing the same image as the image of the image data , supplied error data, and pixels from the multi-value image input means An image correction unit that adds pixel values of multi-valued image data supplied in units to generate error addition data, and binarizes the error addition data generated by the image correction unit by using a threshold value. Detecting whether the pixel of interest in the binary image data received by the binary image data received by the comparison unit that generates the binarized image data is a pixel of an edge portion of the image indicated by the binary image data; The binary image When the pixel of interest in the data is a pixel of an edge portion of the image, and outputs the pixel value selection signal instructing to select the re-binarized image data the comparison means has generated, the binary image data A pixel determination unit that outputs a pixel value selection signal instructing to select binary image data received by the binary image input unit when the pixel of interest is not a pixel at an edge portion of the image; and the pixel determination according pixel value selection signal is output means, and selector means for the binary image input means binary image data or the comparison means received selects re binary image data generated as the output binary data Binarization error data indicating an error caused by binarization using the error addition data generated by the image correction unit and the output binary data output by the selector unit. And error calculating means for determining, the error data is added to the pixel values of the multivalued image data in the image correction means, determined using the binarization error data obtained by the error calculating means calculates error There is provided an image processing apparatus comprising correction calculation means for supplying data to the image correction means .

また本発明は、コンピュータ装置を、2値画像データを受け取る2値画像入力手段と、前記2値画像データを多値化して所定の処理が施された多値画像データまたは前記2値画像データの画像と同じ画像を表す多値の画像データに所定の処理が施された多値画像データを受け取る多値画像入力手段と、供給される誤差データと、前記多値画像入力手段から画素単位で供給される多値画像データの画素値とを画素単位で加算して誤差加算データを生成する画像補正手段と、前記画像補正手段が生成した誤差加算データを閾値により2値化して再2値化画像データを生成する比較手段と、前記2値画像入力手段が受け取った2値画像データにおける注目画素が、該2値画像データが示す画像のエッジ部分の画素であるか否か検知し、該2値画像データにおける注目画素が該画像のエッジ部分の画素である場合には、前記比較手段が生成した再2値化画像データを選択するように指示する画素値選択信号を出力し、該2値画像データにおける注目画素が該画像のエッジ部分の画素でない場合には、前記2値画像入力手段が受け取った2値画像データを選択するよう指示する画素値選択信号を出力する画素判定手段と、前記画素判定手段が出力した画素値選択信号に従い、前記2値画像入力手段が受け取った2値画像データまたは前記比較手段が生成した再2値化画像データを選択し、出力2値データとして出力するセレクタ手段と、前記画像補正手段が生成した誤差加算データと前記セレクタ手段が出力した出力2値データとを用いて、2値化により生じた誤差を示す2値化誤差データを求める誤差算出手段と、前記画像補正手段において前記多値画像データの画素値に加算される前記誤差データを、前記誤差算出手段により求められた2値化誤差データを用いて求め、求めた誤差データを前記画像補正手段に供給する補正算出手段として機能させるためのプログラムを提供する。 According to another aspect of the present invention, there is provided a computer apparatus comprising: binary image input means for receiving binary image data; multivalued image data obtained by converting the binary image data into multivalued data and subjected to predetermined processing ; Multi-value image input means for receiving multi- value image data obtained by performing predetermined processing on multi-value image data representing the same image as the image , supplied error data, and supplied from the multi-value image input means in pixel units an image correcting unit that the pixel value of the multivalued image data by adding in pixel units to generate the error addition data, binarized and re binarized image error added data by the image correcting means is generated by the threshold A comparison unit for generating data, and detecting whether the pixel of interest in the binary image data received by the binary image input unit is a pixel at an edge portion of the image indicated by the binary image data; Image When the pixel of interest in the data is a pixel of an edge portion of the image, and outputs the pixel value selection signal instructing to select the re-binarized image data the comparison means has generated, the binary image data A pixel determination unit that outputs a pixel value selection signal instructing to select binary image data received by the binary image input unit when the pixel of interest is not a pixel at an edge portion of the image; and the pixel determination according pixel value selection signal is output means, and selector means for the binary image input means binary image data or the comparison means received selects re binary image data generated as the output binary data Binarization error data indicating an error caused by binarization using the error addition data generated by the image correction unit and the output binary data output by the selector unit. And Mel error calculation means, the error data is added to the pixel values of the multivalued image data in the image correction means, determined using the binarization error data obtained by the error calculating means calculates error A program is provided for causing data to function as correction calculation means for supplying data to the image correction means .

本発明によれば、画像処理装置は2値画像データと多値画像データとを受け取る。画像処理装置は、多値画像データと、誤差データとを画素単位で加算し、この加算結果を示す誤差加算データを生成し、この誤差加算データを閾値により2値化する。また、画像処理装置は、2値画像データにおける注目画素の画素値と、注目画素に隣接する画素の画素値とに基づいて、前記2値画像入力手段が受け取った2値画像データまたは前記再2値化手段が生成した再2値化画像データのいずれを出力するか指示する画素値選択信号を出力し、出力した画素値選択信号が、前記2値画像入力手段が受け取った2値画像データを出力するよう指示する信号である場合には、前記2値画像入力手段が受け取った2値画像データを出力2値データとして出力し、前記選択信号出力手段が出力した信号が、前記再2値化手段が生成した再2値化画像データを出力するよう指示する信号である場合には、前記再2値化手段が生成した再2値化画像データを出力2値データとして出力する。そして、画像処理装置は、誤差加算データの画素値とと出力2値データの画素値とを用いて、次に多値画像データの画素値に加算する誤差データを求める。   According to the present invention, the image processing apparatus receives binary image data and multi-value image data. The image processing apparatus adds the multi-value image data and the error data in units of pixels, generates error addition data indicating the addition result, and binarizes the error addition data with a threshold value. Further, the image processing apparatus may be configured to receive the binary image data received by the binary image input unit based on the pixel value of the pixel of interest in the binary image data and the pixel value of the pixel adjacent to the pixel of interest, or the second image data. A pixel value selection signal that indicates which of the re-binarized image data generated by the binarization means is output is output, and the output pixel value selection signal is the binary image data received by the binary image input means. When the signal is an instruction to output, the binary image data received by the binary image input unit is output as output binary data, and the signal output by the selection signal output unit is converted to the re-binarized signal. When the signal is an instruction to output the re-binarized image data generated by the means, the re-binarized image data generated by the re-binarization means is output as output binary data. Then, the image processing apparatus uses the pixel value of the error addition data and the pixel value of the output binary data to obtain error data to be added to the pixel value of the multivalued image data.

本発明によれば、入力される2値の画像データが有する網点成分を保持しつつ色補正の補正結果を精度よく反映した2値画像を出力することが可能となる。   According to the present invention, it is possible to output a binary image that accurately reflects the correction result of color correction while retaining the halftone dot component of the input binary image data.

[1.第1実施形態]
[1−1.第1実施形態の構成]
まず、図1を用いて本発明の第1実施形態に係わる画像処理装置の構成を説明する。画像入力部100は、RIP処理により網点成分を有する2値画像データに変換された原稿の画像データ(以下、この画像データを入力2値画像データD10と称する)を受け取るインターフェースとして機能し、受け取った画像データを多値化部200と誤差拡散部500とへ供給する。この入力2値画像データD10においては、個々の画素の値が1ビットで表される。即ち、黒画素の値は「1」、白画素の値は「0」である。
[1. First Embodiment]
[1-1. Configuration of First Embodiment]
First, the configuration of the image processing apparatus according to the first embodiment of the present invention will be described with reference to FIG. The image input unit 100 functions as an interface for receiving image data (hereinafter referred to as input binary image data D10) of a document converted into binary image data having a halftone dot component by RIP processing. The obtained image data is supplied to the multi-value quantization unit 200 and the error diffusion unit 500. In the input binary image data D10, the value of each pixel is represented by 1 bit. That is, the value of the black pixel is “1”, and the value of the white pixel is “0”.

多値化部200は、入力2値画像データD10を多値画像データに変換するものであり、入力2値画像データD10を受け取ると、2値画像データによって表された2値の各画素値を各画素毎に各々複数ビットで表したデータを生成する。例えば、画素値が「0」である場合には「0」を、「1」である場合には「255」を新たな画素値とする単純な変換を行う。つまり、画像データは、1ビットで表されていた画素値が8ビットで表されるように変換される(以下、多値化部200により生成される画像データを単純多値画像データD20と称する)。多値化部200は、この単純多値画像データD20を網点除去部300へ供給する。   The multi-value conversion unit 200 converts the input binary image data D10 into multi-value image data. When the input binary image data D10 is received, each of the binary pixel values represented by the binary image data is converted. Data represented by a plurality of bits is generated for each pixel. For example, when the pixel value is “0”, simple conversion is performed with “0” as the new pixel value and “255” as the new pixel value. That is, the image data is converted so that the pixel value represented by 1 bit is represented by 8 bits (hereinafter, the image data generated by the multi-value conversion unit 200 is referred to as simple multi-value image data D20). ). The multi-value conversion unit 200 supplies the simple multi-value image data D20 to the halftone dot removal unit 300.

網点除去部300は、例えば、入力された単純多値画像データD20に対して平滑化フィルタ処理を施すことにより、単純多値画像データD20が有する網点成分を除去したデータであって、かつ、中間階調を有する画像データ(以下、この画像データを平滑化画像データD30と称する)を生成する。網点除去部300は、この平滑化画像データD30を色変換部400へ供給する。なお、この平滑化画像データD30においては、個々の画素の画素値が8ビットで表されている。   The halftone dot removing unit 300 is, for example, data obtained by removing the halftone dot component of the simple multilevel image data D20 by performing a smoothing filter process on the input simple multilevel image data D20, and Then, image data having intermediate gradation (hereinafter, this image data is referred to as smoothed image data D30) is generated. The halftone dot removal unit 300 supplies the smoothed image data D30 to the color conversion unit 400. In the smoothed image data D30, the pixel value of each pixel is represented by 8 bits.

色変換部400は、網点除去部300から供給された平滑化画像データD30に対して、色補正を施すものであり、当該画像処理装置が印刷する印刷物と、印刷機で印刷した印刷物の色合いが同じになるように平滑化画像データD30に対して色補正を施す。色変換部400は、この色補正を施した多値画像データ(以下、この画像データを色補正画像データD40と称する)を誤差拡散部500へ供給する。なお、この色補正画像データD40においては、個々の画素の画素値が8ビットで表されている。   The color conversion unit 400 performs color correction on the smoothed image data D30 supplied from the halftone removal unit 300, and the color of the printed material printed by the image processing apparatus and the printed material printed by the printing machine. Are subjected to color correction on the smoothed image data D30. The color conversion unit 400 supplies the multi-value image data subjected to the color correction (hereinafter, this image data is referred to as color correction image data D40) to the error diffusion unit 500. In this color corrected image data D40, the pixel value of each pixel is represented by 8 bits.

誤差拡散部500は、色変換部400から供給された色補正画像データD40に対して平均誤差最小法を用いて誤差拡散処理を施し、個々の画素を1ビットのデジタルデータで表す2値画像データ(以下、この画像データを出力2値画像データD60と称する)を生成するものである。誤差拡散部500は、生成した画像データを画像出力部600へ供給する。誤差拡散部500の詳細については、後に説明する。   The error diffusion unit 500 performs error diffusion processing on the color-corrected image data D40 supplied from the color conversion unit 400 using the average error minimum method, and binary image data that represents each pixel as 1-bit digital data. (Hereinafter, this image data is referred to as output binary image data D60). The error diffusion unit 500 supplies the generated image data to the image output unit 600. Details of the error diffusion unit 500 will be described later.

画像出力部600は、印刷を行う機能を具備しており、誤差拡散部500から供給される出力2値画像データD60を受け取り、受け取った画像データに基づいて印刷を行う。   The image output unit 600 has a printing function, receives the output binary image data D60 supplied from the error diffusion unit 500, and performs printing based on the received image data.

[1−2.誤差拡散部の構成]
図2は、誤差拡散部500の構成を例示するブロック図である。2値画像入力部570は、画像入力部100から供給される入力2値画像データD10を受け取るインターフェースとして機能する。2値画像入力部570は、入力2値画像データD10を受け取ると、個々の画素の値を示す1ビットのデータ(以下、2値画素データD50bと称する)を閾値計算部510の反転部511と、2値化部520の隣接画素判定部522およびセレクタ部523へ順次供給する。
[1-2. Configuration of error diffusion unit]
FIG. 2 is a block diagram illustrating the configuration of the error diffusion unit 500. The binary image input unit 570 functions as an interface that receives the input binary image data D10 supplied from the image input unit 100. When the binary image input unit 570 receives the input binary image data D10, the binary image input unit 570 generates 1-bit data (hereinafter referred to as binary pixel data D50b) indicating the value of each pixel from the inversion unit 511 of the threshold value calculation unit 510. This is sequentially supplied to the adjacent pixel determination unit 522 and the selector unit 523 of the binarization unit 520.

閾値計算部510は、2値画像入力部570から供給される2値画素データD50bを用いて閾値データを生成するものであり、反転部511と、係数発生部512と、乗算部513とを具備している。
反転部511は、2値画像入力部570から供給される2値画素データD50bの画素値を反転するものである。反転部511は、2値画素データD50bが供給されると、2値画素データD50bの画素値が「0」である場合には画素値を「1」に変換し、2値画素データD50bの画素値が「1」である場合には画素値を「0」に変換し、変換した2値画素データD50bを反転データD50gとして乗算部513へ供給する。
係数発生部512は、反転部511から供給される反転データD50gに乗ずる係数を発生するものであり、例えば、色補正画像データD40がとりうる画素値の最大値を係数とし、この係数を示す係数データD50hを乗算部513へ供給する。なお、係数は、色補正画像データD40がとりうる画素値の最大値に限定されるものではなく、任意の値としてもよい。
乗算部513は、反転部511から供給される反転データD50gの画素値に係数発生部512から供給される係数データD50hが示す係数を乗じ、この乗算により得た値を示す閾値データD50iを2値化部520へ供給する。
The threshold calculation unit 510 generates threshold data using the binary pixel data D50b supplied from the binary image input unit 570, and includes an inversion unit 511, a coefficient generation unit 512, and a multiplication unit 513. is doing.
The inversion unit 511 inverts the pixel value of the binary pixel data D50b supplied from the binary image input unit 570. When the binary pixel data D50b is supplied, the inversion unit 511 converts the pixel value to “1” when the pixel value of the binary pixel data D50b is “0”, and the pixel of the binary pixel data D50b When the value is “1”, the pixel value is converted to “0”, and the converted binary pixel data D50b is supplied to the multiplication unit 513 as inverted data D50g.
The coefficient generation unit 512 generates a coefficient to be multiplied by the inverted data D50g supplied from the inversion unit 511. For example, the coefficient is a maximum pixel value that the color correction image data D40 can take, and a coefficient indicating the coefficient The data D50h is supplied to the multiplication unit 513. The coefficient is not limited to the maximum pixel value that the color correction image data D40 can take, and may be an arbitrary value.
The multiplier 513 multiplies the pixel value of the inverted data D50g supplied from the inverter 511 by the coefficient indicated by the coefficient data D50h supplied from the coefficient generator 512, and binary threshold data D50i indicating the value obtained by this multiplication. To the conversion unit 520.

2値化部520は、画像補正部530から供給される誤差加算データD50cを、閾値計算部510から供給される閾値データD50iを用いて2値化するものであり、比較部521と、隣接画素判定部522と、セレクタ部523とを具備している。
比較部521は、画像補正部530から供給される誤差加算データD50cを閾値計算部510から供給される閾値データD50iにより2値化するものである。比較部521は、誤差加算データD50cが示す値が閾値データD50iが示す値以上である場合には、画素値を「1」とした再2値化データD50jをセレクタ部523へ供給し、誤差加算データD50cが示す値が閾値データD50iが示す値未満の場合には、画素値を「0」とした再2値化データD50jをセレクタ部523へ供給する。
The binarization unit 520 binarizes the error addition data D50c supplied from the image correction unit 530 using the threshold value data D50i supplied from the threshold value calculation unit 510. A determination unit 522 and a selector unit 523 are provided.
The comparison unit 521 binarizes the error addition data D50c supplied from the image correction unit 530 with the threshold data D50i supplied from the threshold calculation unit 510. When the value indicated by the error addition data D50c is equal to or greater than the value indicated by the threshold data D50i, the comparison unit 521 supplies re-binarized data D50j with the pixel value “1” to the selector unit 523, and adds the error. When the value indicated by the data D50c is less than the value indicated by the threshold data D50i, the re-binarized data D50j with the pixel value “0” is supplied to the selector unit 523.

隣接画素判定部522は、2値画像入力部570から供給される2値画素データD50bを用いて、注目画素の値と注目画素に隣接する画素の値とに応じて、「Disable」または「Enable」なる値をとる画素値変更可能信号D50kをセレクタ523へ供給するものである。
図3および図4は、注目画素の値と画素値変更可能信号D50kがとる値の関係を示す図である。隣接画素判定部522は、注目している2値画素データD50bが示す値が「0」である場合、注目画素に隣接する上下左右の2値画素データの値の論理和を求め、この論理演算の結果と注目画素の画素値との間で排他的論理和をとる。隣接画素判定部522は、図3に示したように、注目画素の値と隣接画素の画素値の論理和の値が同じである場合には、画素値変更可能信号D50kとして「Disable」を出力し、注目画素の画素値と隣接画素の画素値の論理和の値が異なる場合には、画素値変更可能信号D50kとして「Enable」を出力する。
また、隣接画素判定部522は、注目している2値画素データD50bが示す値が「1」である場合、注目画素に隣接する上下左右の2値画素データの値の論理積を求め、この論理演算の結果と注目画素の画素値との間で排他的論理和をとる。隣接画素判定部522は、図4に示したように、注目画素の値と隣接画素の画素値の論理積の値とが同じである場合には、画素値変更可能信号D50kとして「Disable」を出力し、注目画素の値と隣接画素の画素値の論理積の値とが異なる場合には、画素値変更可能信号D50kとして「Enable」を出力する。
The adjacent pixel determination unit 522 uses the binary pixel data D50b supplied from the binary image input unit 570 and uses “Disable” or “Enable” according to the value of the target pixel and the value of the pixel adjacent to the target pixel. The pixel value changeable signal D50k taking the value "" is supplied to the selector 523.
3 and 4 are diagrams showing the relationship between the value of the target pixel and the value taken by the pixel value changeable signal D50k. When the value indicated by the focused binary pixel data D50b is “0”, the adjacent pixel determination unit 522 calculates a logical sum of the values of the upper, lower, left, and right binary pixel data adjacent to the focused pixel, and performs this logical operation. And the exclusive OR of the pixel value of the target pixel. As shown in FIG. 3, the adjacent pixel determination unit 522 outputs “Disable” as the pixel value changeable signal D50k when the value of the pixel of interest and the logical sum of the pixel values of the adjacent pixels are the same. If the value of the logical sum of the pixel value of the target pixel and the pixel value of the adjacent pixel is different, “Enable” is output as the pixel value changeable signal D50k.
In addition, when the value indicated by the focused binary pixel data D50b is “1”, the adjacent pixel determination unit 522 calculates a logical product of the values of the upper, lower, left, and right binary pixel data adjacent to the target pixel. An exclusive OR is calculated between the result of the logical operation and the pixel value of the target pixel. As shown in FIG. 4, the adjacent pixel determination unit 522 sets “Disable” as the pixel value changeable signal D50k when the value of the pixel of interest and the logical product of the pixel values of the adjacent pixels are the same. If the value of the pixel of interest differs from the logical product of the pixel values of adjacent pixels, “Enable” is output as the pixel value changeable signal D50k.

セレクタ部523は、隣接画素判定部522から供給される画素値変更可能信号D50kに基づいて、2値画像入力部570から供給される2値画素データD50bまたは比較部521から供給される再2値化データD50jのいずれかを出力するものである。セレクタ部523は、隣接画素判定部522から供給される画素値変更可能信号D50kが「Enable」である場合、比較部521から供給される再2値化データD50jを出力2値データD50mとして2値画像出力部590へ供給し、画素値変更可能信号D50kが「Disable」である場合、2値画像入力部570から供給される2値画素データD50bを出力2値データD50mとして2値画像出力部590へ供給する。   The selector unit 523 uses the binary pixel data D50b supplied from the binary image input unit 570 or the re-binary supplied from the comparison unit 521 based on the pixel value changeable signal D50k supplied from the adjacent pixel determination unit 522. One of the digitized data D50j is output. When the pixel value changeable signal D50k supplied from the adjacent pixel determination unit 522 is “Enable”, the selector unit 523 uses the re-binarized data D50j supplied from the comparison unit 521 as the output binary data D50m and is binary. When the pixel value changeable signal D50k is “Disable” supplied to the image output unit 590, the binary image output unit 590 uses the binary pixel data D50b supplied from the binary image input unit 570 as output binary data D50m. To supply.

2値画像出力部590は、セレクタ部523から供給されたデータを画像出力部600へ供給するインターフェースとしての機能を有しており、セレクタ部523から供給されたデータを出力2値画像データD60として画像出力部600へ供給する。   The binary image output unit 590 has a function as an interface for supplying the data supplied from the selector unit 523 to the image output unit 600, and the data supplied from the selector unit 523 is used as output binary image data D60. The image is supplied to the image output unit 600.

一方、多値画像入力部580は、色変換部400から供給される色補正画像データD40を受け取るインターフェースとして機能し、色補正画像データD40を受け取ると、個々の画素の値を示す8ビットのデータ(以下、多値画素データD50aと称する)を画像補正部530へ順次供給する。   On the other hand, the multi-value image input unit 580 functions as an interface that receives the color correction image data D40 supplied from the color conversion unit 400. When the color correction image data D40 is received, 8-bit data indicating the value of each pixel. (Hereinafter, referred to as multi-value pixel data D50a) is sequentially supplied to the image correction unit 530.

誤差算出部540は、画像補正部530から供給される誤差加算データD50cと、2値化部520から供給される出力2値データD50mとを用いて、2値化誤差データD50dを生成するものである。誤差算出部540は、例えば、2値化部520から供給される出力2値データD50mが「0」を示す場合には、誤差加算データD50cが示す値と「0」との差を差分値としてもとめ、2値化部520から供給されるデータが「1」を示す場合には、誤差加算データD50cが示す値から「255」を引いた値を差分値としてもとめ、この求めた差分値を示すデータを2値化誤差データD50dとして誤差記憶部550へ供給する。この2値化誤差データD50dは、誤差記憶部550に記憶される。   The error calculation unit 540 generates binarization error data D50d using the error addition data D50c supplied from the image correction unit 530 and the output binary data D50m supplied from the binarization unit 520. is there. For example, when the output binary data D50m supplied from the binarization unit 520 indicates “0”, the error calculation unit 540 uses the difference between the value indicated by the error addition data D50c and “0” as a difference value. When the data supplied from the binarization unit 520 indicates “1”, a value obtained by subtracting “255” from the value indicated by the error addition data D50c is obtained as a difference value, and the obtained difference value is indicated. The data is supplied to the error storage unit 550 as binarized error data D50d. The binarized error data D50d is stored in the error storage unit 550.

補正算出部560は、注目画素の周辺の画素で生じた誤差から誤差データD50fを求めるものである。補正算出部560は、誤差記憶部550に記憶された2値化誤差データD50dのうち、注目画素の周辺の画素の2値化誤差データD50dに対し、予め定めた係数を乗じることにより誤差データD50fを求める。そして補正算出部560は、次に画像補正部530に供給される多値画素データD50aが示す値に加算する誤差データD50fを画像補正部530へ供給する。   The correction calculation unit 560 obtains error data D50f from errors generated in pixels around the target pixel. The correction calculation unit 560 multiplies the binarization error data D50d of the pixels around the pixel of interest among the binarization error data D50d stored in the error storage unit 550 by multiplying the error data D50f by a predetermined coefficient. Ask for. Then, the correction calculation unit 560 supplies error data D50f to be added to the value indicated by the multi-value pixel data D50a supplied to the image correction unit 530 to the image correction unit 530.

画像補正部530は、多値画像入力部580から供給される多値画素データD50aが示す画素値に、補正算出部560から供給される誤差データD50fが示す値を加算するものであり、加算により得られた値を示す誤差加算データD50cを比較部521と誤差算出部540へ供給する。   The image correction unit 530 adds the value indicated by the error data D50f supplied from the correction calculation unit 560 to the pixel value indicated by the multi-value pixel data D50a supplied from the multi-value image input unit 580. Error addition data D50c indicating the obtained value is supplied to the comparison unit 521 and the error calculation unit 540.

つまり、画像補正部530は、誤差拡散により誤差が加算された多値画素データを比較部521へ供給し、比較部521は、この誤差拡散により誤差が加算された多値画素データを、閾値計算部510から供給される閾値データを用いて2値化し再2値化データD50jを生成する。そしてセレクタ部523は、画素値変更可能信号に応じて、黒画素あるいは白画素が連続する部分においては、2値画像入力部570に入力されたデータをそのまま出力2値データD50mとして出力し、画素値が変わる部分においては、誤差が加算されたデータを2値化した再2値化データを出力2値データD50mとして出力する。   That is, the image correction unit 530 supplies the multi-valued pixel data with the error added by error diffusion to the comparison unit 521, and the comparison unit 521 calculates the threshold value for the multi-valued pixel data with the error added by the error diffusion. Binarization is performed using the threshold data supplied from the unit 510, and rebinarized data D50j is generated. Then, in accordance with the pixel value changeable signal, the selector unit 523 outputs the data input to the binary image input unit 570 as it is as output binary data D50m in the portion where black pixels or white pixels are continuous, In the portion where the value changes, rebinarized data obtained by binarizing the data with the error added is output as output binary data D50m.

[1−3.第1実施形態の動作]
次に、第1実施形態の動作について説明する。以下の説明では、まず、誤差拡散部500に入力2値画像データD10と色補正画像データD40とが入力されるまでの動作について説明し、次に、入力2値画像データD10と色補正画像データD40とを受け取った誤差拡散部500の動作について説明する。
[1-3. Operation of First Embodiment]
Next, the operation of the first embodiment will be described. In the following description, first, an operation until the input binary image data D10 and the color correction image data D40 are input to the error diffusion unit 500 will be described. Next, the input binary image data D10 and the color correction image data will be described. The operation of the error diffusion unit 500 that has received D40 will be described.

[1−3−1.色補正画像データD40が誤差拡散部500に入力されるまでの動作]
入力2値画像データD10が画像入力部100に入力されると、この入力2値画像データD10は画像入力部100から多値化部200と誤差拡散部500とへ供給される。この入力2値画像データD10が多値化部200に入力されると、この入力2値画像データD10は、多値化部200において、個々の画素を8ビットのデジタルデータで表す単純多値画像データD20に変換される。この単純多値画像データD20は、多値化部200から網点除去部300へ供給される。
[1-3-1. Operation until the color correction image data D40 is input to the error diffusion unit 500]
When the input binary image data D10 is input to the image input unit 100, the input binary image data D10 is supplied from the image input unit 100 to the multilevel conversion unit 200 and the error diffusion unit 500. When the input binary image data D10 is input to the multilevel conversion unit 200, the input binary image data D10 is converted into a simple multilevel image in which each pixel is represented by 8-bit digital data in the multilevel conversion unit 200. Converted to data D20. This simple multi-value image data D20 is supplied from the multi-value conversion unit 200 to the halftone dot removal unit 300.

網点除去部300に供給された単純多値画像データD20は、網点除去部300において平滑化フィルタ処理により網点成分が除去され、中間階調を有する平滑化画像データD30に変換される。この平滑化画像データD30は網点除去部300から色変換部400へ供給される。平滑化画像データD30が供給された色変換部400では、平滑化画像データD30に対して色補正が施され色補正画像データD40が生成される。この色補正データは、色変換部400から誤差拡散部500へ供給される。   The simple multi-valued image data D20 supplied to the halftone dot removing unit 300 is subjected to smoothing filter processing in the halftone dot removing unit 300 to remove halftone dot components and converted to smoothed image data D30 having an intermediate gradation. The smoothed image data D30 is supplied from the halftone dot removal unit 300 to the color conversion unit 400. In the color conversion unit 400 to which the smoothed image data D30 is supplied, color correction is performed on the smoothed image data D30 to generate color corrected image data D40. This color correction data is supplied from the color conversion unit 400 to the error diffusion unit 500.

画像入力部100から出力された2値画像データが誤差拡散部500の2値画像入力部570へ供給され、色変換部400から供給された色補正画像データD40が誤差拡散部500の多値画像入力部580に供給されると、誤差拡散部500では、これらのデータを用いて誤差拡散が行われる。   The binary image data output from the image input unit 100 is supplied to the binary image input unit 570 of the error diffusion unit 500, and the color correction image data D40 supplied from the color conversion unit 400 is the multi-value image of the error diffusion unit 500. When supplied to the input unit 580, the error diffusion unit 500 performs error diffusion using these data.

[1−3−2.誤差拡散部500の動作]
次に誤差拡散部500の動作について説明する。入力2値画像データD10が入力された2値画像入力部570からは、2値画素データD50bが、閾値計算部510の反転部511と、2値化部520の隣接画素判定部522およびセレクタ部523とへ供給される。
[1-3-2. Operation of error diffusion unit 500]
Next, the operation of the error diffusion unit 500 will be described. From the binary image input unit 570 to which the input binary image data D10 is input, the binary pixel data D50b includes the inversion unit 511 of the threshold value calculation unit 510, the adjacent pixel determination unit 522 and the selector unit of the binarization unit 520. 523.

反転部511に供給された2値画素データD50bは、反転部511において画素値が反転された後、反転データD50gとして反転部511から乗算部513へ供給される。乗算部513では、反転部511から供給された反転データD50gが示す値に係数発生部512から供給された係数データD50hが示す値が乗ぜられ、この乗算により得られた値が閾値データD50iとして2値化部520の比較部521へ供給される。   The binary pixel data D50b supplied to the inversion unit 511 is supplied from the inversion unit 511 to the multiplication unit 513 as inverted data D50g after the pixel value is inverted by the inversion unit 511. The multiplier 513 multiplies the value indicated by the inverted data D50g supplied from the inverter 511 by the value indicated by the coefficient data D50h supplied from the coefficient generator 512, and the value obtained by this multiplication is 2 as the threshold data D50i. The value is supplied to the comparison unit 521 of the value conversion unit 520.

閾値データD50iが比較部521に供給されると、比較部521において、画像補正部530から供給される誤差加算データD50cが示す値と閾値データD50iが示す値との比較が行われ、誤差加算データD50cを2値化した再2値化データD50jが生成される。例えば、誤差加算データD50cが示す値が「255」であり、閾値データD50iが示す値が「0」というように、多値画像データが示す値が閾値データD50iの値以上である場合には、画素値を「1」とした再2値化データD50jが比較部521からセレクタ部523へ供給され、誤差加算データD50cが示す値が「0」であり、閾値データD50iが示す値が「255」というように、多値画像データが示す値が閾値データD50iの値未満である場合には、画素値を「0」とした再2値化データD50jが比較部521からセレクタ部523へ供給される。   When the threshold value data D50i is supplied to the comparison unit 521, the comparison unit 521 compares the value indicated by the error addition data D50c supplied from the image correction unit 530 with the value indicated by the threshold value data D50i. Re-binarized data D50j obtained by binarizing D50c is generated. For example, when the value indicated by the error added data D50c is “255” and the value indicated by the threshold data D50i is “0”, the value indicated by the multi-valued image data is equal to or greater than the value of the threshold data D50i. The re-binarized data D50j with the pixel value “1” is supplied from the comparison unit 521 to the selector unit 523, the value indicated by the error addition data D50c is “0”, and the value indicated by the threshold data D50i is “255”. As described above, when the value indicated by the multi-valued image data is less than the value of the threshold data D50i, the re-binarized data D50j with the pixel value “0” is supplied from the comparison unit 521 to the selector unit 523. .

一方、隣接画素判定部522においては、2値画像入力部570から供給された2値画素データD50bに基づいて、画素値変更可能信号D50kが生成される。この隣接画素判定部522の動作について、図5を用いて説明する。図5は、入力2値画像データD10が示す画像と、2値画素データD50bに基づいて出力される画素値変更可能信号D50kの関係を説明するための図である。図5においては、画素を表現するために13×13のマトリクスを用い、横方向にA〜Mの符号、縦方向に1〜13の符号を付け、これらの符号の組み合わせにより画素を表すこととする。   On the other hand, in the adjacent pixel determination unit 522, the pixel value changeable signal D50k is generated based on the binary pixel data D50b supplied from the binary image input unit 570. The operation of the adjacent pixel determination unit 522 will be described with reference to FIG. FIG. 5 is a diagram for explaining the relationship between the image indicated by the input binary image data D10 and the pixel value changeable signal D50k output based on the binary pixel data D50b. In FIG. 5, a 13 × 13 matrix is used to represent the pixels, codes A to M in the horizontal direction and codes 1 to 13 in the vertical direction, and the pixels are represented by a combination of these codes. To do.

入力2値画像データD10をXからYの方向へ走査し、画素B7を注目画素とした場合、注目画素の値が「0」であるので、隣接画素判定部522では画素B7に隣接する上下左右の画素の画素値の論理和が求められる。画素B7に隣接する上下左右の画素の画素値の論理和は「0」であり、注目画素の値が「0」であるため、図3に従い、隣接画素判定部522からは画素値変更可能信号D50kとして「Disable」が出力される(図5:期間a)。   When the input binary image data D10 is scanned in the X to Y direction and the pixel B7 is set as the target pixel, the value of the target pixel is “0”. Therefore, the adjacent pixel determination unit 522 is vertically and horizontally adjacent to the pixel B7. The logical sum of the pixel values of these pixels is obtained. Since the logical sum of the pixel values of the upper, lower, left and right pixels adjacent to the pixel B7 is “0” and the value of the target pixel is “0”, the pixel value changeable signal is output from the adjacent pixel determination unit 522 according to FIG. “Disable” is output as D50k (FIG. 5: period a).

次に、画素C7を注目画素とした場合、隣接画素判定部522では画素C7に隣接する上下左右の画素の画素値の論理和が求められる。画素C7の右の画素D7の値は「1」であり、画素C7の上と下と左の画素の値はいずれも「0」であるので、画素B7に隣接する上下左右の画素の画素値の論理和は「1」となる。注目画素の値が「0」であり、隣接画素の画素値の論理和が「1」であるため、図3の表に従い、隣接画素判定部522からは、画素値変更可能信号D50kとして「Enable」が出力される(図5:期間b)。   Next, when the pixel C7 is the target pixel, the adjacent pixel determination unit 522 calculates the logical sum of the pixel values of the upper, lower, left, and right pixels adjacent to the pixel C7. Since the value of the right pixel D7 of the pixel C7 is “1” and the values of the upper, lower, and left pixels of the pixel C7 are all “0”, the logic of the pixel values of the upper, lower, left, and right pixels adjacent to the pixel B7 The sum is “1”. Since the value of the target pixel is “0” and the logical sum of the pixel values of adjacent pixels is “1”, according to the table of FIG. 3, the adjacent pixel determination unit 522 generates “Enable” as the pixel value changeable signal D50k. Is output (FIG. 5: period b).

次に、画素D7を着目画素とした場合、注目画素の値が「1」であるため、隣接画素判定部522では画素D7に隣接する上下左右の画素の画素値の論理積が求められる。画素D7の左の画素C7の値は「0」であり、画素D7の上と下と右の画素の値はいずれも「1」であるので、画素D7に隣接する上下左右の画素の画素値の論理積は「0」となる。注目画素の値が「1」であり、隣接画素の画素値の論理積が「0」であるため、図4の表に従い、隣接画素判定部522からは、画素値変更可能信号D50kとして「Enable」が出力される(図5:期間c)。   Next, when the pixel D7 is the pixel of interest, since the value of the pixel of interest is “1”, the adjacent pixel determination unit 522 calculates the logical product of the pixel values of the upper, lower, left, and right pixels adjacent to the pixel D7. Since the value of the left pixel C7 of the pixel D7 is “0” and the values of the upper, lower, and right pixels of the pixel D7 are all “1”, the logic of the pixel values of the upper, lower, left, and right pixels adjacent to the pixel D7 The product is “0”. Since the value of the target pixel is “1” and the logical product of the pixel values of adjacent pixels is “0”, according to the table of FIG. 4, the adjacent pixel determination unit 522 generates “Enable” as the pixel value changeable signal D50k. Is output (FIG. 5: period c).

次に、画素E7を着目画素とした場合、隣接画素判定部522では画素E7に隣接する上下左右の画素の画素値の論理積が求められる。画素E7の上下左右の画素はいずれも「1」であるので、画素E7に隣接する上下左右の画素の画素値の論理積は「1」となる。注目画素の値が「1」であり、隣接画素の画素値の論理積が「1」であるため、図4の表に従い、隣接画素判定部522からは、画素値変更可能信号D50kとして「Disable」が出力される(図5:期間d)。   Next, when the pixel E7 is the pixel of interest, the adjacent pixel determination unit 522 calculates the logical product of the pixel values of the upper, lower, left, and right pixels adjacent to the pixel E7. Since the upper, lower, left, and right pixels of the pixel E7 are all “1”, the logical product of the pixel values of the upper, lower, left, and right pixels adjacent to the pixel E7 is “1”. Since the value of the target pixel is “1” and the logical product of the pixel values of adjacent pixels is “1”, according to the table of FIG. 4, the adjacent pixel determination unit 522 generates “Disable” as the pixel value changeable signal D50k. Is output (FIG. 5: period d).

このように、隣接画素判定部522においては、注目画素の画素値と、注目画素に隣接する画素の画素値の論理和の結果、または注目画素に隣接する画素の画素値の論理積の結果との排他的論理和をとることにより、画素の値が変化する部分を注目画素としている場合、即ち、画像のエッジ部分においてのみ、「Enable」の値をとる画素値変更可能信号D50kが出力される。   As described above, in the adjacent pixel determination unit 522, the result of the logical sum of the pixel value of the target pixel and the pixel value of the pixel adjacent to the target pixel, or the result of the logical product of the pixel value of the pixel adjacent to the target pixel. Is taken as the pixel of interest, that is, only at the edge portion of the image, the pixel value changeable signal D50k having the value of “Enable” is output. .

隣接画素判定部522から出力された画素値変更可能信号D50kは、セレクタ部523へ供給される。セレクタ部523に画素値変更可能信号D50kとして「Enable」が入力されると、比較部521から供給された再2値化データD50jがセレクタ部523から出力される(図5:期間(A))。このように、画素値変更可能信号D50kとして「Enable」が出力されている場合、即ち、画素の値が変化する部分(画像のエッジ部分)を注目画素としている期間は、比較部521から供給された再2値化データD50j、即ち、色補正画像データD40に対して誤差拡散を施し、この誤差拡散を施したデータを2値化した再2値化データD50jがセレクタ部523から出力2値データD50mとして出力される。   The pixel value changeable signal D50k output from the adjacent pixel determination unit 522 is supplied to the selector unit 523. When “Enable” is input as the pixel value changeable signal D50k to the selector unit 523, the re-binarized data D50j supplied from the comparison unit 521 is output from the selector unit 523 (FIG. 5: period (A)). . As described above, when “Enable” is output as the pixel value changeable signal D50k, that is, the period in which the pixel value change portion (the edge portion of the image) is the target pixel is supplied from the comparison unit 521. The re-binarized data D50j, that is, the color-corrected image data D40 is subjected to error diffusion, and the re-binarized data D50j obtained by binarizing the error-diffused data is output from the selector unit 523 as binary data. D50m is output.

セレクタ部523に画素値変更可能信号D50kとして「Disable」が入力されると、2値画像入力部570から供給された2値画素データD50bがセレクタ部523からそのまま出力される(図5:期間(B))。このように、画素値変更可能信号D50kとして「Disable」が出力されている場合、即ち、画像を形成する黒画素が連続する部分を注目画素としている期間においては、2値画像入力部570から供給された2値画素データD50bがセレクタ部523からそのまま出力される。   When “Disable” is input as the pixel value changeable signal D50k to the selector unit 523, the binary pixel data D50b supplied from the binary image input unit 570 is output as it is from the selector unit 523 (FIG. 5: period ( B)). As described above, when “Disable” is output as the pixel value changeable signal D50k, that is, in a period in which a portion in which black pixels forming an image are continuous is a target pixel, the pixel value is supplied from the binary image input unit 570. The binary pixel data D50b thus output is output from the selector unit 523 as it is.

セレクタ部523から出力されたデータは、2値画像出力部590と誤差算出部540とへ供給される。2値画像出力部590に供給されたデータは、出力2値画像データD60として画像出力部600へ供給される。この出力2値画像データD60が供給された画像出力部600では、供給された出力2値画像データD60に基づいて印刷が行われる。   The data output from the selector unit 523 is supplied to the binary image output unit 590 and the error calculation unit 540. The data supplied to the binary image output unit 590 is supplied to the image output unit 600 as output binary image data D60. In the image output unit 600 supplied with the output binary image data D60, printing is performed based on the supplied output binary image data D60.

誤差算出部540では、セレクタ部523から供給された出力2値データD50mと、画像補正部530から供給された誤差加算データD50cとが用いられ、2値化誤差データD50dが生成される。補正算出部560では、誤差記憶部550に記憶された2値化誤差データD50dを用いて、注目画素に対する誤差データD50fが算出される。この誤差データD50fは画像補正部530へ供給され、誤差データD50fが示す値は、次に画像補正部530へ供給される多値画素データD50aが示す値に加算される。   The error calculation unit 540 uses the output binary data D50m supplied from the selector unit 523 and the error addition data D50c supplied from the image correction unit 530, and generates binarized error data D50d. In the correction calculation unit 560, error data D50f for the target pixel is calculated using the binarized error data D50d stored in the error storage unit 550. The error data D50f is supplied to the image correction unit 530, and the value indicated by the error data D50f is added to the value indicated by the multi-value pixel data D50a supplied to the image correction unit 530 next.

以上説明したように本実施形態によれば、画素値変更可能信号D50kにより、黒画素あるいは白画素が連続する部分においては、誤差拡散が施されたデータが出力されるのではなく、入力2値画像データD10がそのまま出力される。誤差拡散により多値の画像データを2値化すると、画像を形成する画素が連続する部分において、元の2値画像データが有していた画素が誤差の蓄積により欠落する場合がある。しかしながら、本実施形態の2値化部520は、上述したように黒画素あるいは白画素が連続する部分においては、誤差拡散を施したデータを出力するのではなく、入力2値画像データD10をそのまま出力するので、当該画像処理装置に入力された入力2値画像データD10が有していた網点成分を精度よく保存した画像データを出力することが可能となる。   As described above, according to the present embodiment, in accordance with the pixel value changeable signal D50k, in the portion where black pixels or white pixels are continuous, the data subjected to error diffusion is not output, but the input binary value is output. The image data D10 is output as it is. When multi-valued image data is binarized by error diffusion, pixels that the original binary image data has may be lost due to error accumulation in a portion where pixels forming an image are continuous. However, as described above, the binarization unit 520 of the present embodiment does not output error-diffused data in a portion where black pixels or white pixels are continuous, but uses the input binary image data D10 as it is. Since the data is output, it is possible to output image data in which the halftone dot component included in the input binary image data D10 input to the image processing apparatus is accurately stored.

また、本実施形態では、特許文献1に記載されているカラー出力装置のように、色補正の結果を単純多値画像データD20に加算し、この加算により得られる多値画像データに対して誤差拡散を施して2値の画像データを得るのではなく、平滑化画像データD30に対して色補正を施し、この補正を施した画像データに対して誤差拡散を施して2値の画像データを得る。特許文献1に記載されているカラー出力装置は、色補正の結果を単純多値画像データD20に加算するが、網点構造を有する単純多値画像では、値が「0」である画素が多数存在するため、加算結果が画素の取りうる値の範囲を超える場合が多く発生する。特許文献1に記載されているカラー出力装置は、加算結果が画素の取りうる値の範囲を超えた場合、画素の値を画素値が取る範囲内になるように修正してしまうため、色補正結果を加算した画像データには、正確に色補正が施されていない画素が多数存在することとなる。
これに対して本実施形態では、平滑化画像データD30に対して色補正が施された色補正画像データD40が直接誤差拡散処理されることにより、色補正の精度を反映した2値画像データを出力することが可能となる。
In the present embodiment, the color correction result is added to the simple multi-valued image data D20 as in the color output device described in Patent Document 1, and the multi-valued image data obtained by this addition has an error. Rather than performing binary diffusion to obtain binary image data, color correction is performed on the smoothed image data D30, and error diffusion is performed on the corrected image data to obtain binary image data. . The color output device described in Patent Document 1 adds the result of color correction to the simple multivalued image data D20. However, in a simple multivalued image having a halftone dot structure, there are many pixels having a value of “0”. Therefore, there are many cases where the addition result exceeds the range of values that the pixel can take. The color output device described in Patent Literature 1 corrects the pixel value so that the pixel value falls within the range that the pixel value can take when the addition result exceeds the range of the value that the pixel can take. In the image data obtained by adding the results, there are many pixels that have not been accurately subjected to color correction.
On the other hand, in the present embodiment, the binary image data reflecting the accuracy of color correction is obtained by directly error-diffusing the color-corrected image data D40 obtained by performing color correction on the smoothed image data D30. It becomes possible to output.

[2.第2実施形態]
次に本発明の第2実施形態について説明する。なお、以下に説明する第2実施形態において、第1実施形態と構成が同じ部分については第1実施形態と同じ符号を付し、その説明を省略する。
[2. Second Embodiment]
Next, a second embodiment of the present invention will be described. In addition, in 2nd Embodiment demonstrated below, the same code | symbol as 1st Embodiment is attached | subjected about the part which has the same structure as 1st Embodiment, and the description is abbreviate | omitted.

[2−1.第2実施形態の構成]
図6は、本発明の第2実施形態に係わる誤差拡散部500の構成を例示するブロック図である。本発明の第2実施形態が第1実施形態と異なるのは、誤差拡散部500が画像修正部595を具備している点である。
[2-1. Configuration of Second Embodiment]
FIG. 6 is a block diagram illustrating the configuration of the error diffusion unit 500 according to the second embodiment of the invention. The second embodiment of the present invention differs from the first embodiment in that the error diffusion unit 500 includes an image correction unit 595.

画像修正部595は、セレクタ部523から供給される出力2値データD50mの修正を行うものであり、セレクタ部523から供給される出力2値データD50mと、2値画像入力部570から供給される2値画素データD50bと、隣接画素判定部522から供給される画素値変更可能信号D50kとを記憶するメモリ(図示略)とを具備している。
画像修正部595は、画素値変更可能信号D50kが「Disable」から「Enable」に変化した時にこの直後の画素で2値画素データD50bの値と出力2値データD50mの値が異なり、次に画素値変更可能信号D50kが「Disable」から「Enable」に変化した時にもこの直後の画素で2値画素データD50bの値と出力2値データD50mの値が異なる場合、この画素値変更可能信号が変化した時点の出力2値データD50mの値を反転する。また、画像修正部595は、画素値変更可能信号D50kが「Enable」から「Disable」に変化した時にこの直前の画素で2値画素データD50bの値と出力2値データD50mの値が異なり、次に画素値変更可能信号D50kが「Enable」から「Disable」に変化した時にもこの直前の画素で2値画素データD50bの値と出力2値データD50mの値が異なる場合、この画素値変更可能信号が変化した時点の出力2値データD50mの値を反転する。画像修正部595は、記憶した画素値変更可能信号D50kの変化の確認が終了すると、修正が施された出力2値データD50mを2値画像出力部590へ供給する。
The image correction unit 595 corrects the output binary data D50m supplied from the selector unit 523, and is supplied from the output binary data D50m supplied from the selector unit 523 and the binary image input unit 570. A memory (not shown) for storing the binary pixel data D50b and the pixel value changeable signal D50k supplied from the adjacent pixel determination unit 522 is provided.
When the pixel value changeable signal D50k changes from “Disable” to “Enable”, the image correction unit 595 differs in the value of the binary pixel data D50b and the value of the output binary data D50m in the pixel immediately after this, Even when the value changeable signal D50k changes from “Disable” to “Enable”, if the value of the binary pixel data D50b is different from the value of the output binary data D50m in the immediately following pixel, the pixel value changeable signal changes. The value of the output binary data D50m at that time is inverted. In addition, when the pixel value changeable signal D50k changes from “Enable” to “Disable”, the image correction unit 595 differs in the value of the binary pixel data D50b and the value of the output binary data D50m for the immediately preceding pixel. Even when the pixel value changeable signal D50k changes from “Enable” to “Disable”, if the value of the binary pixel data D50b and the value of the output binary data D50m are different in the immediately preceding pixel, this pixel value changeable signal The value of the output binary data D50m at the time when is changed is inverted. When the confirmation of the change in the stored pixel value changeable signal D50k is completed, the image correction unit 595 supplies the corrected output binary data D50m to the binary image output unit 590.

[2−2.第2実施形態の動作]
次に本発明の第2実施形態の動作について説明する。なお、以下に説明する動作において、画像修正部595を除く他の部分の動作については、第1実施形態の動作と同じであるためその説明を省略し、画像修正部595の動作についてのみ説明する。また、以下に説明する画像修正部595の動作においては、図7に示したように、画素値変更可能信号D50kが「Disable」から「Enable」に変化した時に、2値画像入力部570から出力された2値画素データD50bの値と異なる値の出力2値データD50mがセレクタ部523から出力された場合を想定し、動作の説明を行う。
[2-2. Operation of Second Embodiment]
Next, the operation of the second embodiment of the present invention will be described. Note that, in the operation described below, the operation of the other parts excluding the image correction unit 595 is the same as the operation of the first embodiment, so the description thereof will be omitted, and only the operation of the image correction unit 595 will be described. . In the operation of the image correction unit 595 described below, as shown in FIG. 7, when the pixel value changeable signal D50k changes from “Disable” to “Enable”, the output from the binary image input unit 570 is performed. The operation will be described assuming that the output binary data D50m having a value different from the value of the binary pixel data D50b is output from the selector unit 523.

図7は、入力2値画像データD10が示す画像と、2値画像入力部から出力される2値画素データD50bの値と、画素値変更可能信号D50kと、セレクタ部523から出力される出力2値データD50mおよび画像修正部595から出力される出力2値データD50mの関係を説明するための図である。図7においては、図5と同様に符号の組み合わせにより画素を表すこととする。   FIG. 7 shows the image indicated by the input binary image data D10, the value of the binary pixel data D50b output from the binary image input unit, the pixel value changeable signal D50k, and the output 2 output from the selector unit 523. It is a figure for demonstrating the relationship between value data D50m and the output binary data D50m output from the image correction part 595. FIG. In FIG. 7, pixels are represented by combinations of symbols as in FIG. 5.

画像修正部595では、記憶した画素値変更可能信号D50kが順次読み出され、図7に示したように、時点eにおいて、読み出した画素値変更可能信号D50kが「Disable」から「Enable」に変化すると、セレクタ部523から供給されたデータのうち、画素C7に相当する出力2値データD50mが示す画素値と、2値画像入力部570から供給された2値画素データD50bのうち画素C7に相当する2値画素データD50bが示す画素値とを比較する。
図7に示されているように、セレクタ部523から供給された出力2値データD50mが示す画素値「1」と、2値画像入力部から供給された2値画像データが示す画素値「0」とは異なるので、画像修正部595は、次に画素値変更可能信号D50kが「Disable」から「Enable」に変化する点を見つけだす。
画像修正部595では、画素値変更可能信号D50kが順次読み出され、時点gにおいて、画素値変更可能信号D50kが「Disable」から「Enable」に変化すると、セレクタ部523から供給された出力2値データD50mのうち画素J7に相当する出力2値データD50mが示す画素値と、2値画像入力部から供給された2値画素データD50bのうち画素J7に相当する2値画素データD50bが示す画素値とを比較する。
図7に示されているように、セレクタ部523から供給された出力2値データD50mが示す画素値「0」と、2値画像入力部から供給された2値画像データが示す画素値「1」とは異なるので、画像修正部595は、画素C7における出力2値データD50mの画素値を「0」に修正し、画素J7における出力2値データD50mの画素値を「1」に修正する。このように修正された出力2値画素データD50bは、画像修正部595から画像出力部600へ供給される。
In the image correction unit 595, the stored pixel value changeable signal D50k is sequentially read, and as shown in FIG. 7, the read pixel value changeable signal D50k changes from “Disable” to “Enable” at the time point e. Then, among the data supplied from the selector unit 523, the pixel value indicated by the output binary data D50m corresponding to the pixel C7 and the binary pixel data D50b supplied from the binary image input unit 570 are equivalent to the pixel C7. The pixel value indicated by the binary pixel data D50b to be compared is compared.
As shown in FIG. 7, the pixel value “1” indicated by the output binary data D50m supplied from the selector unit 523 and the pixel value “0” indicated by the binary image data supplied from the binary image input unit. Therefore, the image correcting unit 595 finds a point where the pixel value changeable signal D50k changes from “Disable” to “Enable”.
In the image correction unit 595, the pixel value changeable signal D50k is sequentially read, and when the pixel value changeable signal D50k changes from “Disable” to “Enable” at the time point g, the output binary value supplied from the selector unit 523 is output. Among the data D50m, the pixel value indicated by the output binary data D50m corresponding to the pixel J7 and the pixel value indicated by the binary pixel data D50b corresponding to the pixel J7 among the binary pixel data D50b supplied from the binary image input unit. And compare.
As shown in FIG. 7, the pixel value “0” indicated by the output binary data D50m supplied from the selector unit 523 and the pixel value “1” indicated by the binary image data supplied from the binary image input unit. Therefore, the image correcting unit 595 corrects the pixel value of the output binary data D50m in the pixel C7 to “0” and corrects the pixel value of the output binary data D50m in the pixel J7 to “1”. The output binary pixel data D50b corrected in this way is supplied from the image correction unit 595 to the image output unit 600.

以上説明したように本実施形態によれば、画像のエッジ部においてセレクタ部523から出力される出力2値データD50mの画素値が入力2値画像データD10の画素値と異なる場合、画像修正部595により、画素値が元の入力2値画像データD10が有する画素値に修正される。本実施形態によれば、誤差拡散を施したデータを2値化して得た画像が、入力2値画像データD10の画像に対して1画素分ずれた場合でも、画像修正部595により修正されるので、入力2値画像データD10が示す画像の形状を精度よく保持した画像を出力することが可能となる。   As described above, according to the present embodiment, when the pixel value of the output binary data D50m output from the selector unit 523 is different from the pixel value of the input binary image data D10 at the edge portion of the image, the image correction unit 595 is used. Thus, the pixel value is corrected to the pixel value of the original input binary image data D10. According to this embodiment, even when an image obtained by binarizing error diffusion data is shifted by one pixel from the image of the input binary image data D10, the image correction unit 595 corrects the image. Therefore, it is possible to output an image that accurately holds the shape of the image indicated by the input binary image data D10.

[3.第3実施形態]
次に本発明の第3実施形態について説明する。なお、以下に説明する第3実施形態において、第1実施形態と構成が同じ部分については第1実施形態と同じ符号を付し、その説明を省略する。
[3. Third Embodiment]
Next, a third embodiment of the present invention will be described. Note that in the third embodiment described below, the same reference numerals as those in the first embodiment are given to portions having the same configurations as those in the first embodiment, and description thereof is omitted.

[3−1.第3実施形態の構成]
図8は、本発明の第3実施形態に係わる画像処理装置の構成を例示するブロック図である。本発明の第3実施形態が第1実施形態と異なるのは、差分計算部700を具備している点と、差分計算部700から出力される画像データ(以下、この画像データを差分画像データD70と称する)に対して誤差拡散部500が誤差拡散を施し2値画像データを生成する点である。
[3-1. Configuration of Third Embodiment]
FIG. 8 is a block diagram illustrating the configuration of an image processing apparatus according to the third embodiment of the present invention. The third embodiment of the present invention differs from the first embodiment in that it includes a difference calculation unit 700 and image data output from the difference calculation unit 700 (hereinafter, this image data is referred to as difference image data D70). The error diffusion unit 500 performs error diffusion to generate binary image data.

図8に示したように差分計算部700には、網点除去部300にて生成された平滑化画像データD30と、色変換部400にて生成された色補正画像データD40とが入力される。差分計算部700は、網点成分が除去された平滑化画像データD30が示す画素値と、この平滑化画像データD30に対して色補正を施した色補正画像データD40が示す画素値との差を求める。このように平滑化画像データD30が示す画素値と、色補正画像データD40が示す画素値との差をとることにより、網点成分が除去された画像データにおいて、色補正が施された部分がのみが差となって表れる。差分計算部700は、この差を示す差分画像データD70を誤差拡散部500の多値画像入力部580へ供給する。   As shown in FIG. 8, the difference calculation unit 700 receives the smoothed image data D30 generated by the halftone dot removal unit 300 and the color correction image data D40 generated by the color conversion unit 400. . The difference calculation unit 700 calculates the difference between the pixel value indicated by the smoothed image data D30 from which the halftone dot component has been removed and the pixel value indicated by the color corrected image data D40 obtained by performing color correction on the smoothed image data D30. Ask for. Thus, by taking the difference between the pixel value indicated by the smoothed image data D30 and the pixel value indicated by the color correction image data D40, the portion of the image data from which the halftone dot component has been removed is subjected to color correction. Only appears as a difference. The difference calculation unit 700 supplies difference image data D70 indicating this difference to the multi-value image input unit 580 of the error diffusion unit 500.

本発明の第3実施形態では、誤差拡散部500は、この差分計算部700から出力された差分画像データD70に対して、誤差拡散を施す。誤差拡散部500は、第1実施形態と同様に、2値画素データD50bから画素値変更可能信号D50kを生成し、画素値変更可能信号D50kが「Disable」である場合には、入力2値画像データD10をそのまま出力し、画素値変更可能信号D50kが「Enable」である場合には、誤差拡散が施された差分画像データD70を2値化した再2値化データD50jを出力する。   In the third embodiment of the present invention, the error diffusion unit 500 performs error diffusion on the difference image data D70 output from the difference calculation unit 700. As in the first embodiment, the error diffusion unit 500 generates a pixel value changeable signal D50k from the binary pixel data D50b. When the pixel value changeable signal D50k is “Disable”, the input binary image When the data D10 is output as it is and the pixel value changeable signal D50k is “Enable”, rebinarized data D50j obtained by binarizing the difference image data D70 subjected to error diffusion is output.

以上説明したように、本発明の第3実施形態では、差分画像データD70に対して誤差拡散が施されるので、特許文献1に記載されている技術のような、画素値が画素の取りうる値の範囲を超える場合が多く発生するという問題が解決され、色補正の精度を向上させることが可能となる。また、第1実施形態と同様に黒画素や白画素が連続する部分においては、入力2値画像データD10が有する画素の値が出力され、画像のエッジ部分については、誤差拡散が施された差分画像データD70を2値化して得た画像データが出力されることにより、入力2値画像データD10が示す画像の形状を精度よく保持した画像を出力することが可能となる。   As described above, in the third embodiment of the present invention, since error diffusion is performed on the difference image data D70, the pixel value can be taken by the pixel as in the technique described in Patent Document 1. The problem that the range of values often occurs is solved, and the accuracy of color correction can be improved. Further, as in the first embodiment, the value of the pixel included in the input binary image data D10 is output in a portion where black pixels and white pixels are continuous, and the difference subjected to error diffusion is applied to the edge portion of the image. By outputting the image data obtained by binarizing the image data D70, it is possible to output an image that accurately holds the shape of the image indicated by the input binary image data D10.

[4.第4実施形態]
次に本発明の第4実施形態について説明する。本発明の第4実施形態では、単純多値画像データの生成、平滑化画像データの生成、平滑化した画像データに対する色補正および誤差拡散などの一連の処理をソフトウェアにより実現するようにしている。
[4. Fourth Embodiment]
Next, a fourth embodiment of the present invention will be described. In the fourth embodiment of the present invention, a series of processes such as generation of simple multi-value image data, generation of smoothed image data, color correction and error diffusion for the smoothed image data are realized by software.

図9は、これらの処理をソフトウェアにより実現する画像処理装置のハードウェア構成を例示するブロック図である。図9に示したように、この画像処理装置は、ROM(Read Only Memory)902、RAM(Random Access Memory)903、CPU(Central Processing Unit)904、不揮発性メモリ905および入力2値画像データD10を受け取るためのインターフェース部906、印刷を行うための出力部907とを具備しており、これら各部はバス901で接続されている。ROM902は、CPU904に画像処理装置の各部の制御を行わせるための制御プログラムを記憶しており、不揮発性メモリ905は上述した処理をCPU904に実行させるための誤差拡散プログラムを記憶している。CPU904は、画像処理装置の電源が入れられると、ROM902から制御プログラムを読み出し起動する。制御プログラムを起動したCPU904は、不揮発性メモリ905から誤差拡散プログラムを読み出し、読み出したプログラムをRAM903を作業エリアとして実行する。このように画像処理装置は、CPU904がプログラムに従って各部を制御し処理を行うという点において、一般的なコンピュータ装置と同様のハードウェア構成を有していると言える。   FIG. 9 is a block diagram illustrating a hardware configuration of an image processing apparatus that implements these processes using software. As shown in FIG. 9, this image processing apparatus includes a ROM (Read Only Memory) 902, a RAM (Random Access Memory) 903, a CPU (Central Processing Unit) 904, a nonvolatile memory 905, and input binary image data D10. An interface unit 906 for receiving and an output unit 907 for printing are provided, and these units are connected by a bus 901. The ROM 902 stores a control program for causing the CPU 904 to control each unit of the image processing apparatus, and the nonvolatile memory 905 stores an error diffusion program for causing the CPU 904 to execute the above-described processing. When the image processing apparatus is turned on, the CPU 904 reads the control program from the ROM 902 and activates it. The CPU 904 that has activated the control program reads the error diffusion program from the nonvolatile memory 905 and executes the read program using the RAM 903 as a work area. Thus, it can be said that the image processing apparatus has a hardware configuration similar to that of a general computer apparatus in that the CPU 904 controls each unit according to a program and performs processing.

図10は、誤差拡散プログラムを実行したプログラムが行う処理の流れを例示するフローチャートである。CPU904は、誤差拡散プログラムを起動すると、インターフェース部906に入力2値画像データD10が入力されるのを待つ(ステップSA1)。CPU904は、インターフェース部906に入力2値画像データD10が入力されると、インターフェース部906に入力された入力2値画像データD10から単純多値画像データを生成し(ステップSA2)、生成した単純多値画像データに対して平滑化処理を施す(ステップSA3)。CPU904は、平滑化処理を行い平滑化画像データを生成すると、この平滑化画像データに対して色補正を施し、色補正画像データを生成する(ステップSA4)。CPU904は、色補正処理を行った後、入力2値画像データD10と、色補正画像データとを用いて誤差拡散処理を行い、2値の画像データを生成する(ステップSA5)。そしてCPU904が、この画像データを出力部907へ供給し、出力部907を制御すると、この2値の画像データに基づいて印刷が行われる。このように、ソフトウェアにより単純多値画像データの生成、平滑化画像データの生成、平滑化した画像データに対する色補正および誤差拡散を行うようにすれば、ハードウェアでこれらの処理を実現する態様と比較して、色変換を施す際のパラメータを容易に変更することが可能となる。なお、ソフトウェアにより処理を行う場合、他の実施例についてもソフトウェアにより処理を行えることは言うまでもない。   FIG. 10 is a flowchart illustrating the flow of processing performed by the program that executed the error diffusion program. When the error diffusion program is activated, the CPU 904 waits for input binary image data D10 to be input to the interface unit 906 (step SA1). When the input binary image data D10 is input to the interface unit 906, the CPU 904 generates simple multi-value image data from the input binary image data D10 input to the interface unit 906 (step SA2), and the generated simple multi-value data. Smoothing processing is performed on the value image data (step SA3). When the CPU 904 performs smoothing processing to generate smoothed image data, the CPU 904 performs color correction on the smoothed image data to generate color corrected image data (step SA4). After performing the color correction processing, the CPU 904 performs error diffusion processing using the input binary image data D10 and the color correction image data to generate binary image data (step SA5). When the CPU 904 supplies the image data to the output unit 907 and controls the output unit 907, printing is performed based on the binary image data. As described above, when software performs simple multi-value image data generation, smoothed image data generation, color correction and error diffusion for the smoothed image data, these processes are realized by hardware. In comparison, it is possible to easily change parameters when color conversion is performed. Needless to say, when processing is performed by software, other embodiments can also perform processing by software.

[5.その他の実施形態]
本発明は、上述した実施形態に限定されるものではなく、種々の変形が可能である。
<5−1>
例えば、図11に示したように、入力2値画像データD10の代わりに、単純多値画像データD20を誤差拡散部500へ入力し、誤差拡散部500では、この単純多値画像データD20を用いて閾値や画素値変更可能信号D50kを生成し、色補正が施された色補正画像データD40を2値画像データに変換するようにしてもよい。
[5. Other Embodiments]
The present invention is not limited to the above-described embodiments, and various modifications can be made.
<5-1>
For example, as shown in FIG. 11, instead of the input binary image data D10, simple multilevel image data D20 is input to the error diffusion unit 500, and the error diffusion unit 500 uses the simple multilevel image data D20. Then, a threshold value or pixel value changeable signal D50k may be generated, and the color corrected image data D40 subjected to color correction may be converted into binary image data.

<5−2>
閾値計算部510は2値画像入力部570に入力された入力2値画像データD10から閾値を生成するのではなく、図12に示したように、予め定めた値を閾値として2値化部520へ供給する構成としてもよい。また、第2実施形態および第3実施形態の誤差拡散部500においても、2値画像入力部570に入力された入力2値画像データD10から閾値を生成するのではなく、予め定めた値を閾値として2値化部520へ供給するようにしてもよい。
<5-2>
The threshold value calculation unit 510 does not generate a threshold value from the input binary image data D10 input to the binary image input unit 570, but a binarization unit 520 using a predetermined value as a threshold value as shown in FIG. It is good also as a structure supplied to. Also in the error diffusion unit 500 of the second embodiment and the third embodiment, instead of generating a threshold value from the input binary image data D10 input to the binary image input unit 570, a predetermined value is used as the threshold value. May be supplied to the binarization unit 520.

<5−3>
閾値計算部510は、LUT(Look Up Table)を用いて閾値を生成するようにしてもよい。図13は、LUTを用いて閾値を生成する場合の閾値計算部510の構成を例示するブロック図である。図13に示したLUT部514は、図14に例示したフォーマットのテーブルを記憶しており、このテーブルには、入力された2値の画像データに応じて出力する閾値が格納されている。図14のテーブルにおいて、Lmaxは色補正を行う際に画素がとりうる値の最大値を示し、Lminは色補正を行う際に画素がとりうる値の最小値を示している。LUT部514は、このテーブルに基づいて、入力された2値画素データD50bが示す画素値が「0」である場合には、閾値としてLmaxを出力し、画素値が「1」である場合には、閾値としてLminを出力するようにしてもよい。
<5-3>
The threshold calculation unit 510 may generate a threshold using an LUT (Look Up Table). FIG. 13 is a block diagram illustrating a configuration of the threshold value calculation unit 510 when a threshold value is generated using an LUT. The LUT unit 514 illustrated in FIG. 13 stores a table in the format illustrated in FIG. 14, and threshold values to be output according to input binary image data are stored in this table. In the table of FIG. 14, Lmax indicates the maximum value that the pixel can take when performing color correction, and Lmin indicates the minimum value that the pixel can take when performing color correction. Based on this table, the LUT unit 514 outputs Lmax as the threshold when the pixel value indicated by the input binary pixel data D50b is “0”, and when the pixel value is “1”. May output Lmin as a threshold value.

<5−4>
閾値計算部510の構成は、図15に例示したように、反転部511と、フィルタ部515とを備えた構成としてもよい。反転部511は上述した実施形態の反転部511と同様の動作を行う。フィルタ部515は、値が反転された2値画像データに対してフィルタ処理を施すことにより、例えば、図16に例示したように閾値データD50iを発生させる。このような態様によれば、閾値データD50iの値が隣あう画素毎に異なる値となるので、注目画素の周辺に注目画素と異なる値の画素が多くあるほど注目画素の値が変化する確率が高くなる。
<5-4>
The configuration of the threshold value calculation unit 510 may include a reversing unit 511 and a filter unit 515 as illustrated in FIG. The inversion unit 511 performs the same operation as that of the inversion unit 511 of the above-described embodiment. For example, as illustrated in FIG. 16, the filter unit 515 generates threshold data D50i by performing a filtering process on binary image data whose values are inverted. According to such an aspect, the value of the threshold data D50i becomes a different value for each adjacent pixel. Therefore, the probability that the value of the target pixel changes as the number of pixels having different values from the target pixel increases around the target pixel. Get higher.

<5−5>
隣接画素判定部522は、上述した態様に加えて、入力2値画像が示す画像と文字や図形などの特定の画像パターンとを比較し、パターンのマッチングが生じた場合には、注目画素と隣接する画素との関係から画素値変更可能信号D50kの出力を「Enable」と判断した場合でも「Disable」を出力するようにしてもよい。このような態様によれば、文字などのパターンに対しては入力2値画像データD10がそのまま出力されるので、文字の形状を精度よく保持した画像を出力することができる。
<5-5>
In addition to the above-described aspect, the adjacent pixel determination unit 522 compares the image indicated by the input binary image with a specific image pattern such as a character or a figure, and if pattern matching occurs, the adjacent pixel determination unit 522 “Disable” may be output even when the output of the pixel value changeable signal D50k is determined as “Enable” from the relationship with the pixel to be changed. According to such an aspect, since the input binary image data D10 is output as it is for a pattern such as a character, it is possible to output an image that maintains the shape of the character with high accuracy.

<5−6>
誤差拡散部500の構成が、第1実施形態にて説明した構成である場合、画像処理装置は、図17に例示したように誤差拡散部500を縦列に持つようにしてもよい。このような態様によれば、色変換部400における画素値の変化が大きい場合でも、誤差が十分に拡散される。
<5-6>
When the configuration of the error diffusion unit 500 is the configuration described in the first embodiment, the image processing apparatus may have the error diffusion units 500 in columns as illustrated in FIG. According to such an aspect, even when the change of the pixel value in the color conversion unit 400 is large, the error is sufficiently diffused.

<5−7>
また、画像処理装置の構成は、図18に例示したようにしてもよい。図18に例示した構成においては、第1画像入力部100Aには多値画像データが入力され、第2画像入力部100Bには、第1画像入力部100Aに入力される多値画像データに対してスクリーン処理を施した画像データ、即ち、網点成分を有する2値画像データが入力される。色変換部400は、第1画像入力部100Aから供給される多値画像データに対して色変換を施し、色補正画像データD40を誤差拡散部500へ供給する。誤差拡散部500は、上述した実施形態と同様に、色補正画像データD40と2値画像データを用いて2値画像データを生成し、生成した2値画像データを画像出力部600へ供給する。このような態様でも、元の画像データを精度よく保存した画像データを出力用の2値の画像データとして出力することが可能となる。
<5-7>
Further, the configuration of the image processing apparatus may be as illustrated in FIG. In the configuration illustrated in FIG. 18, multi-value image data is input to the first image input unit 100A, and multi-value image data input to the first image input unit 100A is input to the second image input unit 100B. Then, image data subjected to screen processing, that is, binary image data having a halftone dot component is input. The color conversion unit 400 performs color conversion on the multivalued image data supplied from the first image input unit 100A, and supplies the color correction image data D40 to the error diffusion unit 500. The error diffusion unit 500 generates binary image data using the color correction image data D40 and binary image data, and supplies the generated binary image data to the image output unit 600, as in the above-described embodiment. Even in such an aspect, it is possible to output image data obtained by accurately storing original image data as binary image data for output.

<5−8>
本発明の第4実施形態では、誤差拡散処理をソフトウェアにより実現しているが、この態様において、2値化誤差データが示す値の最大値を記憶し、この値が所定の値より大きい場合には誤差拡散処理を再度行うようにし、この値が所定の値より大きい場合には誤差拡散処理を終了するようにしてもよい。
<5-8>
In the fourth embodiment of the present invention, error diffusion processing is realized by software. In this aspect, the maximum value of the value indicated by the binarized error data is stored, and this value is larger than a predetermined value. The error diffusion process may be performed again, and if this value is greater than a predetermined value, the error diffusion process may be terminated.

<5−9>
本発明の第4実施形態においては、RIP処理により2値化された画像データを画像処理装置が受け取り、画像処理装置が、この画像データに対して色変換および2値化を行い印刷を行うようにしているが、画像処理装置をLAN(Local Area Network)に接続し、RIP処理により2値化された画像データと、カラープリンタを特定するデータとをLANを介して受け取り、カラープリンタの出力特性にあうように変換した2値の画像データを生成し、この生成した画像データを、RIP処理により2値化された画像データを送信してきた装置に送信するようにしてもよい。
<5-9>
In the fourth embodiment of the present invention, an image processing apparatus receives image data binarized by RIP processing, and the image processing apparatus performs color conversion and binarization on the image data to perform printing. However, the image processing apparatus is connected to a LAN (Local Area Network), receives image data binarized by RIP processing and data for specifying a color printer via the LAN, and outputs the color printer. It is also possible to generate binary image data converted in such a manner and transmit the generated image data to a device that has transmitted image data binarized by RIP processing.

<5−10>
また、図19に例示したように、画像処理装置をインターネット等の広域ネットワークに接続し、画像処理装置が、クライアント装置から送信される、カラープリンタを特定するデータとRIP処理により2値化された画像データとを広域ネットワークを介して受け取り、これらのデータを用いて、カラープリンタの出力特性にあうように変換した2値の画像データを生成し、生成した2値の画像データを、RIP処理により2値化された画像データの送信元や、この送信元が指定した宛先へ送信するようにしてもよい。
また、上述したように、画像処理装置をインターネットに接続する態様においては、RIP処理により2値の画像データを受けとってからカラープリンタの出力特性にあうように変換した2値の画像データを生成するまでの処理のうち、例えば、平滑化画像データを生成するまでの処理をデータの送信元が行い、残りの処理を画像処理装置が行うなど、RIP処理により2値化された画像データの送信元と、画像処理装置とが互いに通信して、カラープリンタの出力特性にあうように変換した2値の画像データを生成するようにしてもよい。
<5-10>
Further, as illustrated in FIG. 19, the image processing apparatus is connected to a wide area network such as the Internet, and the image processing apparatus is binarized by data specifying a color printer and RIP processing transmitted from the client apparatus. Image data is received via a wide area network, and using these data, binary image data converted to match the output characteristics of the color printer is generated, and the generated binary image data is converted by RIP processing. You may make it transmit to the transmission source of the binarized image data, and the destination designated by this transmission source.
Further, as described above, in the aspect in which the image processing apparatus is connected to the Internet, binary image data converted to meet the output characteristics of the color printer is generated after receiving the binary image data by RIP processing. Among the processes up to, for example, the data transmission source performs the process until the smoothed image data is generated, and the image processing apparatus performs the rest of the processes, for example, the transmission source of the image data binarized by the RIP process And the image processing apparatus may communicate with each other to generate binary image data converted to match the output characteristics of the color printer.

<5−11>
隣接画素判定部522が注目画素に隣接する画素の画素値の論理演算を行う際、注目画素に隣接する上下左右の画素の画素値に対して論理演算を行う態様に限定されず、例えば、左右の二つの画素の画素値に対して論理演算を行うようにしてもよい。このような態様でも、隣接画素判定部522は、画像のエッジ部分において画素値変更可能信号D50kを出力することが可能となる。また、隣接画素判定部522は、注目画素に隣接する画素の画素値のいずれかが、注目画素の画素値と異なる場合には、画素値変更可能信号D50kを出力するようにしてもよい。このような態様によれば、例えば、図5に例示した画素A1〜画素A13、画素A1〜画素M1、画素M1〜画素M13、画素A13〜画素M13などの画素のように、端部の画素についても画素値変更可能信号D50kを出力することが可能となる。
<5-11>
When the adjacent pixel determination unit 522 performs a logical operation on a pixel value of a pixel adjacent to the pixel of interest, the embodiment is not limited to a mode in which a logical operation is performed on the pixel values of upper, lower, left, and right pixels adjacent to the target pixel. A logical operation may be performed on the pixel values of the two pixels. Even in such an aspect, the adjacent pixel determination unit 522 can output the pixel value changeable signal D50k at the edge portion of the image. The adjacent pixel determination unit 522 may output the pixel value changeable signal D50k when any pixel value of the pixel adjacent to the target pixel is different from the pixel value of the target pixel. According to such an aspect, for example, the pixel at the end, such as the pixel A1 to pixel A13, the pixel A1 to pixel M1, the pixel M1 to pixel M13, and the pixel A13 to pixel M13 illustrated in FIG. Also, the pixel value changeable signal D50k can be output.

<5−12>
上述した第3実施形態の誤差拡散部500においては、多値画像入力部580に、差分画像データD70が入力され、この差分画像データD70に対して誤差拡散が行われる。この場合、図20に示したように、2値画像入力部570から出力される2値画素データD50bが誤差算出部540へ供給されるように、誤差拡散部500を構成してもよい。
<5-12>
In the error diffusion unit 500 of the third embodiment described above, the difference image data D70 is input to the multi-value image input unit 580, and error diffusion is performed on the difference image data D70. In this case, as shown in FIG. 20, the error diffusion unit 500 may be configured such that the binary pixel data D50b output from the binary image input unit 570 is supplied to the error calculation unit 540.

この態様において、誤差算出部540は、2値画素データD50bが示す画素値が「0」であり、且つ、出力2値データD50mが示す画素値が「1」の時、誤差加算データD50cが示す値から「255」を減算した値を2値化誤差データD50dとして誤差記憶部550へ供給する。
また、誤差算出部540は、2値画素データD50bが示す画素値が「1」であり、且つ、出力2値データD50mが示す画素値が「0」の時、誤差加算データD50cが示す値に「255」を加算した値、あるいは「−255」を減算した値を2値化誤差データD50dとして誤差記憶部550へ供給する。
誤差算出部540は、2値画素データD50bが示す画素値と、出力2値データD50mが示す画素値が同じである場合、誤差加算データD50cをそのまま2値化誤差データD50dとして誤差記憶部550へ供給する。
In this aspect, the error calculation unit 540 indicates that the error addition data D50c indicates that the pixel value indicated by the binary pixel data D50b is “0” and the pixel value indicated by the output binary data D50m is “1”. A value obtained by subtracting “255” from the value is supplied to the error storage unit 550 as binarized error data D50d.
The error calculation unit 540 sets the value indicated by the error addition data D50c when the pixel value indicated by the binary pixel data D50b is “1” and the pixel value indicated by the output binary data D50m is “0”. A value obtained by adding “255” or a value obtained by subtracting “−255” is supplied to the error storage unit 550 as binarized error data D50d.
When the pixel value indicated by the binary pixel data D50b and the pixel value indicated by the output binary data D50m are the same, the error calculation unit 540 directly uses the error addition data D50c as the binarized error data D50d to the error storage unit 550. Supply.

従来の誤差拡散の手法は、誤差拡散が施される画像の画素値が全て正の値を持つことを想定している。しかしながら、この態様によれば、差分画像データD70のような、正の画素値のデータと負の画素値のデータの両方を持つ画像データに対して誤差拡散を施し、誤差拡散が施されたデータを2値化部520に供給して、入力2値画像データD10に重畳させることが可能となるため、色変換の結果をより正確に反映できると共に、網点形状をより正確に保存できる。特に、差分画像データD70の全ての画素の画素値が0である時、入力2値画像データD10と出力2値画像データD60の全ての画素の画素値を同じとすることができる。   The conventional error diffusion method assumes that all pixel values of an image subjected to error diffusion have a positive value. However, according to this aspect, error diffusion is performed on image data having both positive pixel value data and negative pixel value data, such as difference image data D70, and error diffusion is performed. Can be supplied to the binarization unit 520 and superimposed on the input binary image data D10, so that the result of color conversion can be reflected more accurately and the halftone dot shape can be stored more accurately. In particular, when the pixel values of all the pixels of the difference image data D70 are 0, the pixel values of all the pixels of the input binary image data D10 and the output binary image data D60 can be made the same.

<5−13>
上述した第3実施形態の誤差拡散部500においては、多値画像入力部580に、差分画像データD70が入力され、この差分画像データD70に対して誤差拡散が行われる。この場合、図21に示したように、2値画素データD50bが画像補正部530へ供給されるように、誤差拡散部500を構成してもよい。
<5-13>
In the error diffusion unit 500 of the third embodiment described above, the difference image data D70 is input to the multi-value image input unit 580, and error diffusion is performed on the difference image data D70. In this case, the error diffusion unit 500 may be configured such that the binary pixel data D50b is supplied to the image correction unit 530 as shown in FIG.

この態様において、画像補正部530は、まず誤差データD50fと多値画素データD50aとを加算する。次に、画像補正部530は、供給された2値画素データD50bの画素値が「0」の場合、先の加算結果に「0」を加算した値を誤差加算データD50cとし、供給された2値画素データD50bの画素値が「1」の場合、先の加算結果に「255」を加算した値を誤差加算データD50cとする。画像補正部530は、この生成した誤差加算データD50cを2値化部520と誤差算出部540へ供給する。   In this aspect, the image correction unit 530 first adds the error data D50f and the multi-value pixel data D50a. Next, when the pixel value of the supplied binary pixel data D50b is “0”, the image correction unit 530 sets the value obtained by adding “0” to the previous addition result as error addition data D50c and supplies the supplied 2 When the pixel value of the value pixel data D50b is “1”, a value obtained by adding “255” to the previous addition result is set as error addition data D50c. The image correction unit 530 supplies the generated error addition data D50c to the binarization unit 520 and the error calculation unit 540.

この態様でも、差分画像データD70のような、正の画素値のデータと負の画素値のデータの両方を持つ画像データに誤差拡散を施して、入力2値画像データD10に重畳させることが可能となるため、色変換の結果をより正確に反映できると共に、網点形状をより正確に保存できる。また、差分画像データD70の全ての画素の画素値が0である時、入力2値画像データD10と出力2値画像データD60の全ての画素の画素値を同じとすることができる。   Even in this mode, it is possible to apply error diffusion to image data having both positive pixel value data and negative pixel value data, such as difference image data D70, and to superimpose it on input binary image data D10. Therefore, the result of color conversion can be reflected more accurately, and the halftone dot shape can be stored more accurately. Further, when the pixel values of all the pixels of the difference image data D70 are 0, the pixel values of all the pixels of the input binary image data D10 and the output binary image data D60 can be made the same.

<5−14>
誤差拡散部500の構成を<5−12>または<5−13>で述べた構成とした場合にも、<5−6>で述べたように、誤差拡散部を縦列に持つようにしてもよい。この場合の画像処理装置500の構成を図22に示す。図2に示したように、画像処理装置は、多値化部、網点除去部、差分計算部、誤差拡散部を各々2つづつ具備している。
<5-14>
Even when the configuration of the error diffusion unit 500 is the configuration described in <5-12> or <5-13>, as described in <5-6>, the error diffusion units may be arranged in columns. Good. The configuration of the image processing apparatus 500 in this case is shown in FIG. As shown in FIG. 2 2, the image processing apparatus, multi-value conversion unit, the halftone removal unit, the difference calculation section, and each 2 by one comprises an error diffusion unit.

本態様に係わる画像処理装置においては、入力された2値画像データD10が、第1多値化部200Aと、第1誤差拡散部500Aとに供給される。第1多値化部200Aは、供給された2値画像データD10を多値化して単純多値画像データD20を生成し、この単純多値画像データD20を第1網点除去部300Aへ供給する。第1網点除去部300Aは、単純多値画像データD20が有する網点成分を除去した平滑化画像データD30を生成し、この平滑化画像データD30を色変換部400と、第1差分計算部700Aとに供給する。色変換部400は、平滑化画像データD30に対して色補正を施して色補正画像データD40を生成し、この色補正画像データD40を第1差分計算部700Aと第2差分計算部700Bとへ供給する。第1差分計算部700Aは、供給される平滑化画像データD30と色補正画像データD40との差を求めて差分画像データD70を生成し、この差分画像データD70を第1誤差拡散部500Aへ供給する。   In the image processing apparatus according to this aspect, the input binary image data D10 is supplied to the first multi-value quantization unit 200A and the first error diffusion unit 500A. The first multi-value conversion unit 200A multi-values the supplied binary image data D10 to generate simple multi-value image data D20, and supplies this simple multi-value image data D20 to the first halftone dot removal unit 300A. . The first halftone dot removing unit 300A generates smoothed image data D30 from which halftone dot components included in the simple multi-valued image data D20 are removed, and the smoothed image data D30 is converted into the color conversion unit 400 and the first difference calculation unit. 700A. The color conversion unit 400 performs color correction on the smoothed image data D30 to generate color correction image data D40, and the color correction image data D40 is transferred to the first difference calculation unit 700A and the second difference calculation unit 700B. Supply. The first difference calculation unit 700A obtains a difference between the supplied smoothed image data D30 and the color-corrected image data D40, generates difference image data D70, and supplies the difference image data D70 to the first error diffusion unit 500A. To do.

第1誤差拡散部500Aは、供給される2値画像データD10と差分画像データD70とを用いて誤差拡散を行い、出力2値画像データD60を生成して第2多値化部200Bと第2誤差拡散部500Bへ供給する。第2多値化部200Bは、供給された出力2値画像データD60を多値化して単純多値画像データD20を生成し、この単純多値画像データD20を第2網点除去部300Bへ供給する。第2網点除去部300Bは、単純多値画像データD20が有する網点成分を除去した平滑化画像データD30を生成し、この平滑化画像データD30を第2差分計算部700Bに供給する。第2差分計算部700Bは、供給される平滑化画像データD30と色補正画像データD40との差を求めて差分画像データD70を生成し、この差分画像データD70を第2誤差拡散部500Bへ供給する。
第2誤差拡散部500Bは、供給される出力2値画像データD60と差分画像データD70とを用いて誤差拡散を行い、出力2値画像データD60を生成して画像出力部600へ供給する。
このような態様によれば、色変換部400における画素値の変化が大きい場合でも、誤差が十分に拡散される。
The first error diffusion unit 500A performs error diffusion using the supplied binary image data D10 and difference image data D70, generates output binary image data D60, and generates second output binarization unit 200B and second image data D70. This is supplied to the error diffusion unit 500B. The second multi-value conversion unit 200B multi-values the supplied output binary image data D60 to generate simple multi-value image data D20, and supplies this simple multi-value image data D20 to the second halftone dot removal unit 300B. To do. The second halftone dot removing unit 300B generates smoothed image data D30 from which halftone dot components included in the simple multivalued image data D20 are removed, and supplies the smoothed image data D30 to the second difference calculation unit 700B. The second difference calculation unit 700B obtains a difference between the supplied smoothed image data D30 and the color-corrected image data D40, generates difference image data D70, and supplies the difference image data D70 to the second error diffusion unit 500B. To do.
The second error diffusion unit 500B performs error diffusion using the supplied output binary image data D60 and difference image data D70, generates output binary image data D60, and supplies it to the image output unit 600.
According to such an aspect, even when the change of the pixel value in the color conversion unit 400 is large, the error is sufficiently diffused.

<5−15>
誤差拡散部500の構成を<5−12>または<5−13>で述べた構成とした場合にも、<5−7>で述べたように、多値画像データと2値画像データとを別々に入力するようにしてもよい。この場合の画像処理装置500の構成を図23に示す。本態様においては、第1画像入力部100Aに入力された多値画像データが色変換部400と差分計算部700に供給される。色変換部400は、入力された多値画像データに対して色補正を施した画像データを生成し、この画像データを差分計算部700へ供給する。差分計算部700は、供給される多値画像データと色補正が施された画像データとの差を求めて差分画像データを生成し、この差分画像データを誤差拡散部500へ供給する。誤差拡散部500は、この差分画像データと、2値画像データとを用いて誤差拡散を行い、出力2値画像データを生成する。このような態様でも、元の画像データを精度よく保存した画像データを出力用の2値の画像データとして出力することが可能となる。
<5-15>
Even when the configuration of the error diffusion unit 500 is the configuration described in <5-12> or <5-13>, as described in <5-7>, the multi-value image data and the binary image data are You may make it input separately. The configuration of the image processing apparatus 500 in this case is shown in FIG. In this aspect, the multi-value image data input to the first image input unit 100A is supplied to the color conversion unit 400 and the difference calculation unit 700. The color conversion unit 400 generates image data obtained by performing color correction on the input multi-value image data, and supplies the image data to the difference calculation unit 700. The difference calculation unit 700 obtains a difference between the supplied multi-value image data and the color-corrected image data, generates difference image data, and supplies the difference image data to the error diffusion unit 500. The error diffusion unit 500 performs error diffusion using the difference image data and the binary image data, and generates output binary image data. Even in such an aspect, it is possible to output image data obtained by accurately storing original image data as binary image data for output.

<5−16>
誤差拡散部500は、2つの閾値を用いて誤差加算データの2値化を行う構成としてもよい。図24は、2つの閾値を用いて誤差加算データの2値化を行う場合の誤差拡散部500の構成を示すブロック図である。なお、以下の説明において、第1実施形態と同じ部分については第1実施形態と同じ符号を付し、その説明を省略する。
<5-16>
The error diffusion unit 500 may be configured to binarize the error addition data using two threshold values. FIG. 24 is a block diagram showing a configuration of the error diffusion unit 500 when binarizing the error addition data using two threshold values. In the following description, the same parts as those of the first embodiment are denoted by the same reference numerals as those of the first embodiment, and the description thereof is omitted.

閾値計算部510は、予め定めた値を閾値として2値化部520へ供給するものであり、第1閾値を示す第1閾値データD50i−1と、第2閾値を示す第2閾値データD50i−2とを出力する。第1閾値データD50i−1が示す値は、第2閾値データD50i−2が示す値より大となっている。   The threshold value calculation unit 510 supplies a predetermined value as a threshold value to the binarization unit 520, and includes first threshold value data D50i-1 indicating a first threshold value and second threshold value data D50i- indicating a second threshold value. 2 is output. The value indicated by the first threshold data D50i-1 is larger than the value indicated by the second threshold data D50i-2.

第1比較部521aは、画像補正部530から供給される誤差加算データD50cを閾値計算部510から供給される第1閾値データD50i−1により2値化するものである。第1比較部521aは、誤差加算データD50cが示す値が閾値データD50i−1が示す値以上である場合には、画素値を「1」とした第1再2値化データD50j−1を排他的論理和演算部524aへ供給し、誤差加算データD50cが示す値が閾値データD50i−1が示す値未満の場合には、画素値を「0」とした第1再2値化データD50j−1を排他的論理和演算部524aへ供給する。   The first comparison unit 521a binarizes the error addition data D50c supplied from the image correction unit 530 with the first threshold data D50i-1 supplied from the threshold calculation unit 510. When the value indicated by the error addition data D50c is equal to or greater than the value indicated by the threshold data D50i-1, the first comparison unit 521a excludes the first re-binarized data D50j-1 whose pixel value is “1”. If the value indicated by the error addition data D50c is less than the value indicated by the threshold data D50i-1, the first re-binarized data D50j-1 with the pixel value set to “0” is supplied to the logical OR operation unit 524a. Is supplied to the exclusive OR operation unit 524a.

第2比較部521bは、画像補正部530から供給される誤差加算データD50cを閾値計算部510から供給される第2閾値データD50i−2により2値化するものである。第2比較部521bは、誤差加算データD50cが示す値が閾値データD50i−2が示す値以上である場合には、画素値を「1」とした第2再2値化データD50j−2を排他的論理和演算部524aとセレクタ部523へ供給し、誤差加算データD50cが示す値が第2閾値データD50i−2が示す値未満の場合には、画素値を「0」とした第2再2値化データD50j−2を排他的論理和演算部524aとセレクタ部523へ供給する。   The second comparison unit 521b binarizes the error addition data D50c supplied from the image correction unit 530 with the second threshold data D50i-2 supplied from the threshold calculation unit 510. When the value indicated by the error addition data D50c is equal to or greater than the value indicated by the threshold data D50i-2, the second comparison unit 521b excludes the second re-binarized data D50j-2 having the pixel value “1”. When the value indicated by the error addition data D50c is less than the value indicated by the second threshold data D50i-2, the pixel value is set to “0”. The value data D50j-2 is supplied to the exclusive OR operation unit 524a and the selector unit 523.

排他的論理和演算部524aは、第1再2値化データD50j−1の値と、第2再2値化データD50j−2の値の排他的論理和を求めるものであり、この論理演算の結果を示すデータD50nを否定演算部524bへ供給する。
具体的には、第1再2値化データD50j−1が「1」であり、第2再2値化データD50j−2が「1」である場合、即ち、誤差加算データD50cが示す値が、第1閾値データD50i−1より大である場合、論理演算の結果である「0」を示すデータD50nを出力する。また、第1再2値化データD50j−1が「0」であり、第2再2値化データD50j−2が「1」である場合、即ち、誤差加算データD50cが示す値が、第1閾値データD50i−1より小であり、第2閾値データD50i−2より等しいか大である場合、論理演算の結果である「1」を示すデータD50nを出力する。また、第1再2値化データD50j−1が「0」であり、第2再2値化データD50j−2が「0」である場合、即ち、誤差加算データD50cが示す値が、第2閾値データD50i−2より小である場合、論理演算の結果である「0」を示すデータD50nを出力する。
The exclusive OR operation unit 524a obtains an exclusive OR of the value of the first rebinarized data D50j-1 and the value of the second rebinarized data D50j-2. Data D50n indicating the result is supplied to the negative operation unit 524b.
Specifically, when the first rebinarized data D50j-1 is “1” and the second rebinarized data D50j-2 is “1”, that is, the value indicated by the error addition data D50c is If it is larger than the first threshold data D50i-1, data D50n indicating "0", which is the result of the logical operation, is output. Further, when the first re-binarized data D50j-1 is “0” and the second re-binarized data D50j-2 is “1”, that is, the value indicated by the error addition data D50c is the first value. When it is smaller than the threshold data D50i-1 and equal to or larger than the second threshold data D50i-2, data D50n indicating “1” as a result of the logical operation is output. Further, when the first re-binarized data D50j-1 is “0” and the second re-binarized data D50j-2 is “0”, that is, the value indicated by the error addition data D50c is the second value. When it is smaller than the threshold data D50i-2, data D50n indicating "0" as a result of the logical operation is output.

否定演算部524bは、論理演算によりデータD50nの否定を求めるものであり、この論理演算の結果を示すデータD50pを論理積演算部524cへ供給する。
論理積演算部524cは、画素値変更可能信号D50kと、データD50pとの論理積を求めるものである。この論理演算の結果が「1」である場合には、第2の画素値変更可能信号D50rとして「Enable」をセレクタ部523へ出力し、この論理演算の結果が「0」場合には、画素値変更可能信号D50rとして「Disable」をセレクタ部523へ出力する。
具体的には、論理積演算部524cは、画素値変更可能信号が「Enable」であり、データD50pが「0」、即ち、誤差加算データD50cの値が、「第1閾値データ>誤差加算データ≧第2閾値データ」である場合、画素値変更可能信号D50rとして「Disable」を出力する。また、論理積演算部524cは、画素値変更可能信号が「Enable」であり、データD50pが「1」、即ち、誤差加算データD50cの値が、「誤差加算データ>第1閾値データ」か、または「第2閾値データ>誤差加算データ」である場合、画素値変更可能信号D50rとして「Enable」を出力する。また、論理積演算部524cは、画素値変更可能信号が「Disable」である場合にはデータD50pの値にかかわらず、画素値変更可能信号D50rとして「Disable」を出力する。
The negative operation unit 524b obtains negation of the data D50n by a logical operation, and supplies data D50p indicating the result of the logical operation to the logical product operation unit 524c.
The AND operation unit 524c obtains a logical product of the pixel value changeable signal D50k and the data D50p. When the result of this logical operation is “1”, “Enable” is output to the selector unit 523 as the second pixel value changeable signal D50r, and when the result of this logical operation is “0”, the pixel “Disable” is output to the selector unit 523 as the value changeable signal D50r.
Specifically, the AND operation unit 524c indicates that the pixel value changeable signal is “Enable”, the data D50p is “0”, that is, the value of the error addition data D50c is “first threshold data> error addition data”. If ≧ second threshold data ”,“ Disable ”is output as the pixel value changeable signal D50r. Further, the AND operation unit 524c determines that the pixel value changeable signal is “Enable” and the data D50p is “1”, that is, the value of the error addition data D50c is “error addition data> first threshold data”, Alternatively, when “second threshold data> error addition data”, “Enable” is output as the pixel value changeable signal D50r. Further, when the pixel value changeable signal is “Disable”, the logical product operation unit 524c outputs “Disable” as the pixel value changeable signal D50r regardless of the value of the data D50p.

セレクタ部523は、第2の画素値変更可能信号D50rが「Enable」である場合、第2再2値化データD50j−2を出力2値データD50mとして出力し、第2の画素値変更可能信号D50rが「Disable」の場合、2値画素データD50bを出力2値データD50mとして出力する。   When the second pixel value changeable signal D50r is “Enable”, the selector unit 523 outputs the second re-binarized data D50j-2 as output binary data D50m, and the second pixel value changeable signal. When D50r is “Disable”, the binary pixel data D50b is output as output binary data D50m.

次にこの構成を採用した誤差拡散部500の動作について、図25を用い、第1実施形態の誤差拡散部500の動作と比較して説明する。図25においては、画素を表現するために横方向に1〜15の符号を付け、これにより画素を表すこととする。
また、図25の1〜15の区間における多値画素データの画素値は「80」であり、誤差拡散の開始時点において誤差データD50fの値は「0」である場合を想定する。また、第1閾値データD50i−1の値は「128」であり、第2閾値データD50i−2の値は「−128」である場合を想定する。なお、説明の便宜上、補正算出部560での誤差データD50fの算出は、注目画素の左の画素の2値化誤差データD50dのみを用いることとし、隣接画素判定部522においては、注目画素の上下左右ではなく、注目画素の左右の画素との関係で、画素値変更可能信号を生成する場合を想定する。
Next, the operation of the error diffusion unit 500 employing this configuration will be described using FIG. 25 in comparison with the operation of the error diffusion unit 500 of the first embodiment. In FIG. 25, in order to express a pixel, the code | symbol of 1-15 is attached to the horizontal direction, and it shall represent a pixel by this.
Further, it is assumed that the pixel value of the multi-value pixel data in the section 1 to 15 in FIG. 25 is “80”, and the value of the error data D50f is “0” at the start of error diffusion. Further, it is assumed that the value of the first threshold data D50i-1 is “128” and the value of the second threshold data D50i-2 is “−128”. For convenience of explanation, calculation of the error data D50f by the correction calculation unit 560 uses only the binarization error data D50d of the pixel to the left of the target pixel, and the adjacent pixel determination unit 522 Assume that the pixel value changeable signal is generated not in terms of left and right but in relation to the left and right pixels of the target pixel.

まず、第1実施形態の誤差拡散部500の動作について説明する。2値画素データD50bの画素1を注目画素とした場合、画像補正部530に入力される多値画素データD50aの値は「80」であり、誤差データD50fの値は「0」であるため、誤差加算データD50cの値は「80」となる。隣接画素判定部522においては、画素1の画素値が「0」であり、隣接する画素との論理和が「0」であるため、「Disable」を示す画素値変更可能信号D50kが出力される。画素値変更可能信号D50rが「Disable」であるため、セレクタ部523は、2値画素データD50bが示す値「0」を出力2値データとして出力する。誤差算出部540においては、この出力2値データD50mの値「0」と誤差加算データD50cとの差分値「80」が求められる。   First, the operation of the error diffusion unit 500 of the first embodiment will be described. When the pixel 1 of the binary pixel data D50b is the target pixel, the value of the multivalued pixel data D50a input to the image correction unit 530 is “80”, and the value of the error data D50f is “0”. The value of the error addition data D50c is “80”. In the adjacent pixel determination unit 522, since the pixel value of the pixel 1 is “0” and the logical sum with the adjacent pixel is “0”, the pixel value changeable signal D50k indicating “Disable” is output. . Since the pixel value changeable signal D50r is “Disable”, the selector unit 523 outputs the value “0” indicated by the binary pixel data D50b as output binary data. In the error calculation unit 540, a difference value “80” between the value “0” of the output binary data D50m and the error addition data D50c is obtained.

次に、2値画素データD50bの画素2を注目画素とした場合、画像補正部530に入力される多値画素データD50aの値は「80」であり、誤差データD50fの値は「80」であるため、誤差加算データD50cの値は「160」となる。隣接画素判定部522においては、画素1と同様に画素値変更可能信号D50kが「Disable」となる。画素値変更可能信号D50kが「Disable」であるため、セレクタ部523は、2値画素データD50bが示す値「0」を出力2値データとして出力する。誤差算出部540においては、この出力2値データD50mの値「0」と誤差加算データD50cとの差分値「160」が求められる。   Next, when the pixel 2 of the binary pixel data D50b is the target pixel, the value of the multi-value pixel data D50a input to the image correction unit 530 is “80”, and the value of the error data D50f is “80”. Therefore, the value of the error addition data D50c is “160”. In the adjacent pixel determination unit 522, the pixel value changeable signal D50k becomes “Disable” in the same manner as the pixel 1. Since the pixel value changeable signal D50k is “Disable”, the selector unit 523 outputs the value “0” indicated by the binary pixel data D50b as output binary data. In the error calculation unit 540, a difference value “160” between the value “0” of the output binary data D50m and the error addition data D50c is obtained.

次に、2値画素データD50bの画素3を注目画素とした場合、画像補正部530に入力される多値画素データD50aの値は「80」であり、誤差データD50fの値は「160」であるため、誤差加算データD50cの値は「240」となる。隣接画素判定部522においては、画素3の画素値が「0」であり画素4の画素値が「1」であるため、隣接する画素との論理和が「1」となる。この結果、画素値変更可能信号D50kが「Enalbe」となる。比較部521は、誤差加算データD50cの値「240」が、閾値データD50iの値「128」より大であるため、画素値が「1」である再2値化データD50jをセレクタ部523へ供給する。セレクタ部523は、画素値変更可能信号D50kが「Enable」であるので、再2値化データD50jの値「1」を出力2値データD50mとして出力する。誤差算出部540は、2値化部520から供給される出力2値データD50mが「1」であるので、誤差加算データD50cが示す値「240」から「255」を引いた値を差分値としてもとめ、この求めた差分値「−15」を示すデータを2値化誤差データD50dとして誤差記憶部550へ供給する。   Next, when the pixel 3 of the binary pixel data D50b is the target pixel, the value of the multi-value pixel data D50a input to the image correction unit 530 is “80”, and the value of the error data D50f is “160”. Therefore, the value of the error addition data D50c is “240”. In the adjacent pixel determination unit 522, since the pixel value of the pixel 3 is “0” and the pixel value of the pixel 4 is “1”, the logical sum with the adjacent pixel is “1”. As a result, the pixel value changeable signal D50k becomes “Enalbe”. The comparison unit 521 supplies the re-binarized data D50j having the pixel value “1” to the selector unit 523 because the value “240” of the error addition data D50c is greater than the value “128” of the threshold data D50i. To do. Since the pixel value changeable signal D50k is “Enable”, the selector unit 523 outputs the value “1” of the re-binarized data D50j as the output binary data D50m. Since the output binary data D50m supplied from the binarization unit 520 is “1”, the error calculation unit 540 subtracts “255” from the value “240” indicated by the error addition data D50c as a difference value. The data indicating the obtained difference value “−15” is supplied to the error storage unit 550 as binarized error data D50d.

次に、2値画素データD50bの画素4を注目画素とした場合、画像補正部530に入力される多値画素データD50aの値は「80」であり、誤差データD50fの値は「−15」であるため、誤差加算データD50cの値は「65」となる。隣接画素判定部522においては、画素4の画素値が「1」であり、画素3の画素値が「0」であるため、隣接する画素との論理積が「0」となる。この結果、画素値変更可能信号D50kが「Enalbe」となる。比較部521は、誤差加算データD50cの値「65」が、閾値データD50iの値「128」より小であるため、画素値が「0」である再2値化データD50jをセレクタ部523へ供給する。セレクタ部523は、画素値変更可能信号D50kが「Enable」であるので、再2値化データD50jの値「0」を出力2値データD50mとして出力する。誤差算出部540は、2値化部520から供給される出力2値データD50mが「0」であるので、誤差加算データD50cが示す値「65」と出力2値データD50m「0」との差分値「65」を示すデータを2値化誤差データD50dとして誤差記憶部550へ供給する。このように、第1実施形態の誤差拡散部500の構成では、画像のエッジ部分において、元の画像で黒画素である部分を白画素としてしまう場合が生じ得る。   Next, when the pixel 4 of the binary pixel data D50b is the target pixel, the value of the multivalued pixel data D50a input to the image correction unit 530 is “80”, and the value of the error data D50f is “−15”. Therefore, the value of the error addition data D50c is “65”. In the adjacent pixel determination unit 522, since the pixel value of the pixel 4 is “1” and the pixel value of the pixel 3 is “0”, the logical product with the adjacent pixel is “0”. As a result, the pixel value changeable signal D50k becomes “Enalbe”. The comparison unit 521 supplies the re-binarized data D50j whose pixel value is “0” to the selector unit 523 because the value “65” of the error addition data D50c is smaller than the value “128” of the threshold data D50i. To do. Since the pixel value changeable signal D50k is “Enable”, the selector unit 523 outputs the value “0” of the rebinarized data D50j as the output binary data D50m. Since the output binary data D50m supplied from the binarization unit 520 is “0”, the error calculation unit 540 has a difference between the value “65” indicated by the error addition data D50c and the output binary data D50m “0”. Data indicating the value “65” is supplied to the error storage unit 550 as binarized error data D50d. As described above, in the configuration of the error diffusion unit 500 according to the first embodiment, a portion that is a black pixel in the original image may be a white pixel in the edge portion of the image.

次に、2つの閾値信号を用いて誤差拡散を行う態様の動作について説明する。なお、画素1を注目画素とした場合と、画素2を注目画素とした場合の動作については、上述した第1実施形態の動作と同様であるため、その説明を省略する。   Next, an operation of an aspect in which error diffusion is performed using two threshold signals will be described. Note that the operation when the pixel 1 is the target pixel and the operation when the pixel 2 is the target pixel are the same as the operation of the first embodiment described above, and thus description thereof is omitted.

2値画素データD50bの画素3を注目画素とした場合、画像補正部530に入力される多値画素データD50aの値は「80」であり、誤差データD50fの値は「160」であるため、誤差加算データD50cの値は「240」となる。隣接画素判定部522においては、画素3の画素値が「0」であり画素4の画素値が「1」であるため、隣接する画素との論理和が「1」となる。この結果、画素値変更可能信号D50kが「Enalbe」となる。   When the pixel 3 of the binary pixel data D50b is the target pixel, the value of the multi-value pixel data D50a input to the image correction unit 530 is “80”, and the value of the error data D50f is “160”. The value of the error addition data D50c is “240”. In the adjacent pixel determination unit 522, since the pixel value of the pixel 3 is “0” and the pixel value of the pixel 4 is “1”, the logical sum with the adjacent pixel is “1”. As a result, the pixel value changeable signal D50k becomes “Enalbe”.

第1比較部521aは、誤差加算データD50cの値「240」が、第1閾値データD50i−1の値「128」より大であるため、画素値が「1」である第1再2値化データD50j−1を排他的論理和演算部524aへ供給する。一方、第2比較部521bは、誤差加算データD50cの値「240」が、第2閾値データD50i−2の値「−128」より大であるため、画素値が「1」である第2再2値化データD50j−2を排他的論理和演算部524aとセレクタ部523へ供給する。   Since the value “240” of the error addition data D50c is larger than the value “128” of the first threshold data D50i-1, the first comparison unit 521a performs the first re-binarization with the pixel value “1”. The data D50j-1 is supplied to the exclusive OR operation unit 524a. On the other hand, since the value “240” of the error addition data D50c is larger than the value “−128” of the second threshold data D50i-2, the second comparison unit 521b performs the second re-creation with the pixel value “1”. The binarized data D50j-2 is supplied to the exclusive OR operation unit 524a and the selector unit 523.

排他的論理和演算部524aは、供給される第1再2値化データD50j−1が「1」であり、第2再2値化データD50j−2が「1」であるので、排他的論理和演算の結果である「0」を示すデータD50nを出力する。否定演算部524bは、データD50nの値が「0」であるので、論理演算の結果である「1」を示すデータD50pを論理積演算部524cへ供給する。   Since the supplied first re-binarized data D50j-1 is “1” and the second re-binarized data D50j-2 is “1”, the exclusive OR operation unit 524a Data D50n indicating “0” as the result of the sum operation is output. Since the value of the data D50n is “0”, the negative operation unit 524b supplies the data D50p indicating “1”, which is the result of the logical operation, to the logical product operation unit 524c.

論理積演算部524cは、論理積演算部524cは、画素値変更可能信号が「Enable」であり、データD50pが「1」であるので、第2の画素値変更可能信号D50rとして「Enable」を出力する。セレクタ部523は、第2の画素値変更可能信号D50rが「Enable」であるので、第2再2値化データD50j−2の値「1」を出力2値データD50mとして出力する。誤差算出部540は、2値化部520から供給される出力2値データD50mが「1」であるので、誤差加算データD50cが示す値「240」から「255」を引いた値を差分値としてもとめ、この求めた差分値「−15」を示すデータを2値化誤差データD50dとして誤差記憶部550へ供給する。   Since the pixel value changeable signal is “Enable” and the data D50p is “1”, the AND operation unit 524c sets “Enable” as the second pixel value changeable signal D50r. Output. Since the second pixel value changeable signal D50r is “Enable”, the selector unit 523 outputs the value “1” of the second rebinarized data D50j-2 as the output binary data D50m. Since the output binary data D50m supplied from the binarization unit 520 is “1”, the error calculation unit 540 subtracts “255” from the value “240” indicated by the error addition data D50c as a difference value. The data indicating the obtained difference value “−15” is supplied to the error storage unit 550 as binarized error data D50d.

次に、2値画素データD50bの画素4を注目画素とした場合、画像補正部530に入力される多値画素データD50aの値は「80」であり、誤差データD50fの値は「−15」であるため、誤差加算データD50cの値は「65」となる。隣接画素判定部522においては、画素4の画素値が「1」であり、画素3の画素値が「0」であるため、隣接する画素との論理積が「0」となる。この結果、画素値変更可能信号D50kが「Enalbe」となる。   Next, when the pixel 4 of the binary pixel data D50b is the target pixel, the value of the multivalued pixel data D50a input to the image correction unit 530 is “80”, and the value of the error data D50f is “−15”. Therefore, the value of the error addition data D50c is “65”. In the adjacent pixel determination unit 522, since the pixel value of the pixel 4 is “1” and the pixel value of the pixel 3 is “0”, the logical product with the adjacent pixel is “0”. As a result, the pixel value changeable signal D50k becomes “Enalbe”.

第1比較部521aは、誤差加算データD50cの値「65」が、第1閾値データD50i−1の値「128」より小であるため、画素値が「0」である第1再2値化データD50j−1を排他的論理和演算部524aへ供給する。一方、第2比較部521bは、誤差加算データD50cの値「65」が、第2閾値データD50i−2の値「−128」より大であるため、画素値が「1」である第2再2値化データD50j−2を排他的論理和演算部524aとセレクタ部523へ供給する。   Since the value “65” of the error addition data D50c is smaller than the value “128” of the first threshold data D50i-1, the first comparison unit 521a performs the first re-binarization in which the pixel value is “0”. The data D50j-1 is supplied to the exclusive OR operation unit 524a. On the other hand, since the value “65” of the error addition data D50c is larger than the value “−128” of the second threshold data D50i-2, the second comparison unit 521b performs the second re-creation with the pixel value “1”. The binarized data D50j-2 is supplied to the exclusive OR operation unit 524a and the selector unit 523.

排他的論理和演算部524aは、供給される第1再2値化データD50j−1が「0」であり、第2再2値化データD50j−2が「1」であるので、排他的論理和演算の結果である「1」を示すデータD50nを出力する。否定演算部524bは、データD50nの値が「1」であるので、論理演算の結果である「0」を示すデータD50pを論理積演算部524cへ供給する。   Since the supplied first re-binarized data D50j-1 is “0” and the second re-binarized data D50j-2 is “1”, the exclusive OR operation unit 524a Data D50n indicating “1” which is the result of the sum operation is output. Since the value of the data D50n is “1”, the negative operation unit 524b supplies the data D50p indicating “0”, which is the result of the logical operation, to the logical product operation unit 524c.

論理積演算部524cは、論理積演算部524cは、画素値変更可能信号が「Enable」であり、データD50pが「0」であるので、第2の画素値変更可能信号D50rとして「Disable」を出力する。セレクタ部523は、第2の画素値変更可能信号D50rが「Disable」であるので、2値画素データD50bの値「1」を出力2値データD50mとして出力する。誤差算出部540は、2値化部520から供給される出力2値データD50mが「1」であるので、誤差加算データD50cが示す値「65」から「255」を引いた値を差分値としてもとめ、この求めた差分値「−190」を示すデータを2値化誤差データD50dとして誤差記憶部550へ供給する。   Since the pixel value changeable signal is “Enable” and the data D50p is “0”, the AND operation unit 524c sets “Disable” as the second pixel value changeable signal D50r. Output. Since the second pixel value changeable signal D50r is “Disable”, the selector unit 523 outputs the value “1” of the binary pixel data D50b as the output binary data D50m. Since the output binary data D50m supplied from the binarization unit 520 is “1”, the error calculation unit 540 subtracts “255” from the value “65” indicated by the error addition data D50c as a difference value. The data indicating the obtained difference value “−190” is supplied to the error storage unit 550 as binarized error data D50d.

以上説明したように、本態様によれば、画像のエッジ部分において、元の画像で黒画素であった部分はそのまま黒画素とされるので、元の画像の網点を構成する黒画素や白画素を増減させた時に、例えば黒画素が連続した部分において孤立した白画素が発生し、網点が一つの固まりではなくなってしまうという問題を生じないようにすることができる。
なお、本態様においては、誤差拡散部500の構成を<5−12>または<5−13>で述べた構成としてもよい。
誤差拡散部500の構成を<5−12>または<5−13>で述べた構成とした場合、
図25に示したように2値画素データが入力されると、画素1以前の画素の部分においても本態様と同様の処理が施される。誤差拡散の処理の特性から画素1での誤差データD50fの値は「0」ではなくオフセットが生じるため、出力2値データD50mが「1」である区間は、ほぼ画素4から画素10の区間となる。本態様のように、出力2値データD50mが「1」である区間が画素3から画素9の区間となり、2値画素データD50bと1画素ずれている場合でも、本発明の第2実施形態と組み合わせることにより、元の入力2値画像データを精度良く保存した出力2値画像データを出力することができる。
As described above, according to this aspect, in the edge portion of the image, the black pixel portion in the original image is directly used as the black pixel. When the number of pixels is increased / decreased, for example, an isolated white pixel is generated in a portion where black pixels are continuous, and the problem that the halftone dots are not one cluster can be prevented.
In this aspect, the configuration of error diffusion section 500 may be the configuration described in <5-12> or <5-13>.
When the configuration of the error diffusion unit 500 is the configuration described in <5-12> or <5-13>,
When binary pixel data is input as shown in FIG. 25, the same processing as in this aspect is performed on the pixel portion before pixel 1. Since the error data D50f value at the pixel 1 is offset instead of “0” due to the characteristics of the error diffusion process, the section where the output binary data D50m is “1” is almost the section from the pixel 4 to the pixel 10. Become. Even in the case where the section where the output binary data D50m is “1” is the section from the pixel 3 to the pixel 9 as in this aspect, and is shifted by one pixel from the binary pixel data D50b, the second embodiment of the present invention By combining them, output binary image data in which the original input binary image data is stored with high accuracy can be output.

本発明の第1実施形態に係わる画像処理装置の構成を例示するブロック図である。1 is a block diagram illustrating a configuration of an image processing apparatus according to a first embodiment of the present invention. 同第1実施形態に係わる画像処理装置が具備する誤差拡散部の構成を例示するブロック図である。2 is a block diagram illustrating a configuration of an error diffusion unit included in the image processing apparatus according to the first embodiment. FIG. 同第1実施形態における、注目画素の画素値と隣接画素判定部522から出力される画素値変更可能信号との関係を示す図である。It is a figure which shows the relationship between the pixel value of an attention pixel and the pixel value changeable signal output from the adjacent pixel determination part 522 in the said 1st Embodiment. 同第1実施形態における、注目画素の画素値と隣接画素判定部522から出力される画素値変更可能信号との関係を示す図である。It is a figure which shows the relationship between the pixel value of an attention pixel and the pixel value changeable signal output from the adjacent pixel determination part 522 in the said 1st Embodiment. 同第1実施形態の隣接画素判定部522の動作を説明するための図である。It is a figure for demonstrating operation | movement of the adjacent pixel determination part 522 of the 1st embodiment. 本発明の第2実施形態に係わる画像処理装置の構成を例示するブロック図である。It is a block diagram which illustrates the composition of the image processing device concerning a 2nd embodiment of the present invention. 同第2実施形態の動作例を説明するための図である。It is a figure for demonstrating the operation example of the 2nd Embodiment. 本発明の第3実施形態に係わる画像処理装置の構成を例示するブロック図である。It is a block diagram which illustrates the composition of the image processing device concerning a 3rd embodiment of the present invention. 本発明の第4実施形態に係わる画像処理装置の構成を例示するブロック図である。It is a block diagram which illustrates the composition of the image processing device concerning a 4th embodiment of the present invention. 同第4実施形態に係わる画像処理装置のCPUが行う処理の流れを例示するフローチャートである。It is a flowchart which illustrates the flow of the process which CPU of the image processing apparatus concerning the 4th Embodiment performs. 本発明に係わる画像処理装置の変形例の構成を例示するブロック図である。It is a block diagram which illustrates the composition of the modification of the image processing device concerning the present invention. 本発明に係わる誤差拡散部500の変形例の構成を例示するブロック図である。It is a block diagram which illustrates the composition of the modification of error diffusion part 500 concerning the present invention. 本発明に係わる閾値計算部510の変形例の構成を例示するブロック図である。It is a block diagram which illustrates the composition of the modification of threshold calculation part 510 concerning the present invention. 同閾値計算部510のLUT部514が記憶しているLUTのフォーマットを例示する図である。It is a figure which illustrates the format of LUT which the LUT part 514 of the threshold value calculation part 510 has memorize | stored. 本発明に係わる閾値計算部510の変形例の構成を例示するブロック図である。It is a block diagram which illustrates the composition of the modification of threshold calculation part 510 concerning the present invention. 同閾値計算部510から出力される閾値データを例示する図である。It is a figure which illustrates the threshold value data output from the threshold value calculation part 510. 本発明に係わる画像処理装置の変形例の構成を例示するブロック図である。It is a block diagram which illustrates the composition of the modification of the image processing device concerning the present invention. 本発明に係わる画像処理装置の変形例の構成を例示するブロック図である。It is a block diagram which illustrates the composition of the modification of the image processing device concerning the present invention. 本発明に係わる画像処理装置の変形例を説明するための図である。It is a figure for demonstrating the modification of the image processing apparatus concerning this invention. 本発明に係わる画像処理装置の変形例の構成を示すブロック図である。It is a block diagram which shows the structure of the modification of the image processing apparatus concerning this invention. 本発明に係わる画像処理装置の変形例の構成を示すブロック図である。It is a block diagram which shows the structure of the modification of the image processing apparatus concerning this invention. 本発明に係わる画像処理装置の変形例の構成を示すブロック図である。It is a block diagram which shows the structure of the modification of the image processing apparatus concerning this invention. 本発明に係わる画像処理装置の変形例の構成を示すブロック図である。It is a block diagram which shows the structure of the modification of the image processing apparatus concerning this invention. 本発明に係わる画像処理装置の変形例の構成を示すブロック図である。It is a block diagram which shows the structure of the modification of the image processing apparatus concerning this invention. 本発明に係わる画像処理装置の変形例の動作を説明するための図である。It is a figure for demonstrating operation | movement of the modification of the image processing apparatus concerning this invention. 従来の技術を説明するための図である。It is a figure for demonstrating the prior art.

符号の説明Explanation of symbols

100・・・画像入力部、200・・・多値化部、300・・・網点除去部、400・・・色変換部、500・・・誤差拡散部、600・・・画像出力部、700・・・差分計算部、510・・・閾値計算部、511・・・反転部、512・・・係数発生部、513・・・乗算部、514・・・LUT部、515・・・フィルタ部、520・・・2値化部、521・・・比較部、521a・・・第1比較部、521b・・・第2比較部、522・・・隣接画素判定部、523・・・セレクタ部、524a・・・論理和演算部、524b・・・否定演算部、524c・・・論理積演算部、530・・・画像補正部、540・・・誤差算出部、550・・・誤差記憶部、560・・・補正算出部、570・・・2値画像入力部、580・・・多値画像入力部、590・・・2値画像出力部、595・・・画像修正部、901・・・バス、902・・・ROM、903・・・RAM、904・・・CPU、905・・・不揮発性メモリ、906・・・インターフェース部、907・・・出力部。   DESCRIPTION OF SYMBOLS 100 ... Image input part, 200 ... Multi-value conversion part, 300 ... Halftone dot removal part, 400 ... Color conversion part, 500 ... Error diffusion part, 600 ... Image output part, 700: Difference calculation unit, 510 ... Threshold calculation unit, 511 ... Inversion unit, 512 ... Coefficient generation unit, 513 ... Multiplication unit, 514 ... LUT unit, 515 ... Filter , 520..., Binarization unit, 521... Comparison unit, 521a... First comparison unit, 521b... Second comparison unit, 522. , 524a ... logical sum operation unit, 524b ... negation operation unit, 524c ... logical product operation unit, 530 ... image correction unit, 540 ... error calculation unit, 550 ... error storage 560... Correction calculation unit 570... Binary image input unit 580. Image input unit, 590 ... binary image output unit, 595 ... image correction unit, 901 ... bus, 902 ... ROM, 903 ... RAM, 904 ... CPU, 905 ... Non-volatile memory, 906... Interface unit, 907.

Claims (22)

2値画像データを受け取る2値画像入力手段と、
前記2値画像データを多値化して所定の処理が施された多値画像データまたは前記2値画像データの画像と同じ画像を表す多値の画像データに所定の処理が施された多値画像データを受け取る多値画像入力手段と、
供給される誤差データと、前記多値画像入力手段から画素単位で供給される多値画像データの画素値とを画素単位で加算して誤差加算データを生成する画像補正手段と、
前記画像補正手段が生成した誤差加算データを閾値により2値化して再2値化画像データを生成する比較手段と、
前記2値画像入力手段が受け取った2値画像データにおける注目画素が、該2値画像データが示す画像のエッジ部分の画素であるか否か検知し、該2値画像データにおける注目画素が該画像のエッジ部分の画素である場合には、前記比較手段が生成した再2値化画像データを選択するように指示する画素値選択信号を出力し、該2値画像データにおける注目画素が該画像のエッジ部分の画素でない場合には、前記2値画像入力手段が受け取った2値画像データを選択するよう指示する画素値選択信号を出力する画素判定手段と、
前記画素判定手段が出力した画素値選択信号に従い、前記2値画像入力手段が受け取った2値画像データまたは前記比較手段が生成した再2値化画像データを選択し、出力2値データとして出力するセレクタ手段と、
前記画像補正手段が生成した誤差加算データと前記セレクタ手段が出力した出力2値データとを用いて、2値化により生じた誤差を示す2値化誤差データを求める誤差算出手段と、
前記画像補正手段において前記多値画像データの画素値に加算される前記誤差データを、前記誤差算出手段により求められた2値化誤差データを用いて求め、求めた誤差データを前記画像補正手段に供給する補正算出手段と、
を有する画像処理装置。
Binary image input means for receiving binary image data;
Multi-valued image data obtained by subjecting the binary image data to multi-valued data and subjected to predetermined processing, or multi-valued image data representing the same image as the image of the binary image data. Multi-value image input means for receiving data ;
And error data supplied, and image correcting means for generating an error added data by adding the pixel values of the multivalued image data supplied by the multi-valued image input unit pixels from a pixel unit,
A comparison unit that binarizes the error addition data generated by the image correction unit using a threshold value to generate re-binarized image data;
It is detected whether the pixel of interest in the binary image data received by the binary image input means is a pixel at the edge portion of the image indicated by the binary image data, and the pixel of interest in the binary image data is the image. A pixel value selection signal instructing to select the re-binarized image data generated by the comparison means , and the target pixel in the binary image data is the pixel of the image. A pixel determination unit that outputs a pixel value selection signal instructing to select the binary image data received by the binary image input unit when the pixel is not an edge portion pixel;
According to the pixel value selection signal output from the pixel determination means, the binary image data received by the binary image input means or the re-binarized image data generated by the comparison means is selected and output as output binary data. Selector means;
Error calculating means for obtaining binarized error data indicating an error caused by binarization using the error addition data generated by the image correcting means and the output binary data output by the selector means;
The error data to be added to the pixel value of the multi-value image data in the image correction means is obtained using the binarized error data obtained by the error calculation means, and the obtained error data is stored in the image correction means. Correction calculation means to be supplied ;
An image processing apparatus.
前記画素判定手段は、前記2値画像入力手段が受け取った2値画像データにおける注目画素の画素値が白画素を示している場合、前記2値画像データにおける当該注目画素に隣接する画素の画素値の論理和を求め、この論理和と前記2値画像データにおける当該注目画素の画素値との排他的論理和が真である場合には、前記比較手段が生成した再2値化画像データの選択を指示する画素値選択信号を出力し、該排他的論理和が偽である場合には、前記2値画像入力手段が受け取った2値画像データの選択を指示する画素値選択信号を出力し、
前記2値画像入力手段が受け取った2値画像データにおける注目画素の画素値が黒画素を示している場合、前記2値画像データにおける当該注目画素に隣接する画素の画素値の論理積を求め、この論理積と前記2値画像データにおける当該注目画素の画素値との排他的論理和が真である場合には、前記比較手段が生成した再2値化画像データの選択を指示する画素値選択信号を出力し、該排他的論理和が偽である場合には、前記2値画像入力手段が受け取った2値画像データの選択を指示する画素値選択信号を出力すること
を特徴とする請求項1に記載の画像処理装置。
When the pixel value of the pixel of interest in the binary image data received by the binary image input unit indicates a white pixel, the pixel determination unit is a pixel value of a pixel adjacent to the pixel of interest in the binary image data When the exclusive OR of the logical sum and the pixel value of the target pixel in the binary image data is true, the re-binarized image data generated by the comparison unit is selected. A pixel value selection signal for instructing selection of binary image data received by the binary image input means when the exclusive OR is false,
When the pixel value of the pixel of interest in the binary image data received by the binary image input means indicates a black pixel, obtain the logical product of the pixel values of the pixels adjacent to the pixel of interest in the binary image data, If the exclusive OR of the logical product and the pixel value of the pixel of interest in the binary image data is true, the pixel value selection instructing the selection of the re-binarized image data generated by the comparison unit A signal is output, and when the exclusive OR is false, a pixel value selection signal instructing selection of binary image data received by the binary image input means is output. The image processing apparatus according to 1.
前記画素判定手段は、前記2値画像入力手段が受け取った2値画像データが示す画像と、予め定めた画像パターンとを比較し、画像パターンが一致した場合には、前記2値画像入力手段が受け取った2値化画像データを出力2値データとして出力するよう指示する画素値選択信号を出力すること
を特徴とする請求項2に記載の画像処理装置。
The pixel determination means compares the image indicated by the binary image data received by the binary image input means with a predetermined image pattern. If the image patterns match, the binary image input means The image processing apparatus according to claim 2, wherein a pixel value selection signal instructing to output the received binarized image data as output binary data is output.
前記2値画像入力手段が受け取った2値画像データから多値画像データを生成する多値画像データ生成手段を具備し、
前記多値画像入力手段が受け取る多値画像データは、該多値画像データ生成手段により生成された多値画像データであること
を特徴とする請求項1に記載の画像処理装置。
Comprising multi-value image data generating means for generating multi-value image data from the binary image data received by the binary image input means;
The image processing apparatus according to claim 1, wherein the multi-value image data received by the multi-value image input unit is multi-value image data generated by the multi-value image data generation unit.
前記多値画像データ生成手段は、
前記2値画像入力手段が受け取った2値画像データによって表された2値の各画素値を各画素毎に各々複数ビットで表した単純多値画像データを生成する多値化手段と、
前記多値化手段により生成された単純多値画像データを平滑化して平滑化画像データを生成する平滑化手段と、
前記平滑化手段により生成された平滑化画像データに対して色補正を施した色補正画像データを生成する色補正画像データ生成手段とを有し、
該色補正画像データを多値画像データとして前記多値画像入力手段へ供給すること
を特徴とする請求項4に記載の画像処理装置。
The multi-value image data generating means
Multi-value conversion means for generating simple multi-value image data in which each of the binary pixel values represented by the binary image data received by the binary image input means is represented by a plurality of bits for each pixel;
Smoothing means for smoothing simple multi-value image data generated by the multi-value conversion means to generate smoothed image data;
Color correction image data generation means for generating color correction image data obtained by performing color correction on the smoothed image data generated by the smoothing means;
The image processing apparatus according to claim 4, wherein the color correction image data is supplied to the multi-value image input unit as multi-value image data.
前記多値画像データ生成手段は、
前記平滑化手段により生成された平滑化画像データと、前記色補正画像データ生成手段により生成された色補正画像データとの差分を画素単位で求め、この差分を示す差分画像データを生成する差分画像データ生成手段を具備し、
該差分画像データを多値画像データとして前記多値画像入力手段へ供給すること
を特徴とする請求項5に記載の画像処理装置。
The multi-value image data generating means
A difference image that obtains a difference between the smoothed image data generated by the smoothing unit and the color correction image data generated by the color correction image data generation unit in units of pixels and generates difference image data indicating the difference Comprising data generation means,
The image processing apparatus according to claim 5, wherein the difference image data is supplied to the multi-value image input unit as multi-value image data.
前記2値画像入力手段が受け取る2値画像データは、各画素が各々複数のビットで表されている多値画像データに対してスクリーン処理が施されたデータであり、
該各画素が各々複数のビットで表されている多値画像データに対して色補正を施し、色補正画像データを生成する色補正データ生成手段を具備し、
前記多値画像入力手段が受け取る多値画像データは、該色補正データ生成手段により生成された色補正画像データであること
を特徴とする請求項1に記載の画像処理装置。
The binary image data received by the binary image input means is data obtained by performing screen processing on multi-value image data in which each pixel is represented by a plurality of bits.
Color correction data generation means for generating color correction image data by performing color correction on multi-value image data in which each pixel is represented by a plurality of bits,
The image processing apparatus according to claim 1, wherein the multi-value image data received by the multi-value image input unit is color correction image data generated by the color correction data generation unit.
前記色補正データ生成手段により受け取られる、各画素が各々複数のビットで表されている多値画像データと、前記色補正データ生成手段により生成された色補正画像データとの差分を画素単位で求め、この差分を示す差分画像データを生成する差分画像データ生成手段を具備し、
該差分画像データを多値画像データとして前記多値画像入力手段へ供給すること
を特徴とする請求項7に記載の画像処理装置。
The difference between the multi-valued image data received by the color correction data generation unit and each pixel represented by a plurality of bits and the color correction image data generated by the color correction data generation unit is obtained in units of pixels. , Comprising difference image data generation means for generating difference image data indicating the difference,
The image processing apparatus according to claim 7, wherein the difference image data is supplied to the multi-value image input unit as multi-value image data.
前記画像補正手段は、前記2値画像入力手段が受取った2値画像データを受取り、該2値画像データにおける注目画素の画素値が黒画素を示している場合には、前記色補正画像データの画素値がとりうる値の最大値を前記誤差加算データに加算すること
を特徴とする請求項6または請求項8に記載の画像処理装置。
The image correction unit receives the binary image data received by the binary image input unit, and when the pixel value of the target pixel in the binary image data indicates a black pixel, the color correction image data The image processing apparatus according to claim 6, wherein a maximum value that can be taken by a pixel value is added to the error addition data.
前記誤差算出手段は、前記画像補正手段が生成した誤差加算データと、前記セレクタ手段が生成した出力2値データと、前記2値画像入力手段が受け取った2値画像データを受取り、前記2値画像データにおける注目画素の画素値が白画素を示しており、且つ前記出力2値データが黒画素を示している場合には、前記色補正画像データが取りうる画素値の最大値を前記誤差加算データから減算した値を2値化誤差データとして出力し、前記2値画像データにおける注目画素の画素値が黒画素を示しており、且つ前記出力2値データが白画素を示している場合には、前記色補正画像データが取りうる画素値の最大値を前記誤差加算データに加算した値を2値化誤差データとして出力し、前記2値画像データにおける注目画素の画素値と前記出力2値データの画素値が同じ場合には、前記誤差加算データを2値化誤差データとして出力すること
を特徴とする請求項6または請求項8に記載の画像処理装置。
The error calculation means receives the error addition data generated by the image correction means, the output binary data generated by the selector means, and the binary image data received by the binary image input means. When the pixel value of the pixel of interest in the data indicates a white pixel and the output binary data indicates a black pixel, the maximum pixel value that can be taken by the color correction image data is set as the error addition data. When the value subtracted from is output as binarization error data, the pixel value of the pixel of interest in the binary image data indicates a black pixel, and the output binary data indicates a white pixel, A value obtained by adding the maximum pixel value that can be taken by the color-corrected image data to the error addition data is output as binarization error data, and the pixel value of the pixel of interest in the binary image data and the output If the pixel value of the value data is the same, the image processing apparatus according to claim 6 or claim 8 and outputs the error-added data as the binarization error data.
前記誤差算出手段は、前記画像補正手段が生成した誤差加算データと、前記セレクタ手段が生成した出力2値データと、前記2値画像入力手段が受け取った2値画像データを受取り、前記2値画像データにおける注目画素の画素値が白画素を示しており、且つ前記出力2値データが黒画素を示している場合には、前記多値画像入力手段が受け取った多値画像データが取りうる画素値の最大値を前記誤差加算データから減算した値を2値化誤差データとして出力し、前記2値画像データにおける注目画素の画素値が黒画素を示しており、且つ前記出力2値データが白画素を示している場合には、前記多値画像データが取りうる画素値の最大値を前記誤差加算データに加算した値を2値化誤差データとして出力し、前記2値画像データにおける注目画素の画素値と前記出力2値データの画素値が同じ場合には、前記誤差加算データを2値化誤差データとして出力すること
を特徴とする請求項6または請求項8に記載の画像処理装置。
The error calculation means receives the error addition data generated by the image correction means, the output binary data generated by the selector means, and the binary image data received by the binary image input means. If the pixel value of the pixel of interest in the data indicates a white pixel and the output binary data indicates a black pixel, the pixel value that can be taken by the multi-value image data received by the multi-value image input means A value obtained by subtracting the maximum value of the error added data from the error addition data is output as binarized error data, the pixel value of the pixel of interest in the binary image data indicates a black pixel, and the output binary data is a white pixel if it represents outputs a value obtained by adding the error addition data the maximum value of the pixel values multivalued image data can take as the binarization error data, note in the binary image data The image processing apparatus according to claim 6 or 8, wherein when the pixel value of a pixel and the pixel value of the output binary data are the same, the error addition data is output as binarized error data. .
前記比較手段で用いられる閾値を、前記2値画像入力手段が受け取った2値画像データを用いて生成する閾値生成手段を具備することを特徴とする請求項1に記載の画像処理装置。 The image processing apparatus according to claim 1, further comprising a threshold generation unit configured to generate a threshold used by the comparison unit using binary image data received by the binary image input unit. 第1閾値と、前記第1閾値より値が小である第2閾値とを生成する閾値生成手段を有し、
前記比較手段は、前記画像補正手段が生成した誤差加算データを、前記閾値生成手段が生成した第2閾値により2値化して再2値化画像データを生成し、
前記画素判定手段は、前記2値画像入力手段が受け取った2値画像データにおける注目画素が、該2値画像データが示す画像のエッジ部分の画素であって、前記画像補正手段により生成された誤差加算データが示す値が前記第1閾値未満であり、且つ前記第2閾値以上である場合には、前記2値画像入力手段が受け取った2値画像データの選択を指示する画素値選択信号を出力し、前記2値画像入力手段が受け取った2値画像データにおける注目画素が、該2値画像データが示す画像のエッジ部分の画素であって、前記画像補正手段により生成された誤差加算データが示す値が前記第1閾値以上または前記第2閾値未満である場合には、前記比較手段が生成した再2値化画像データの選択を指示する画素値選択信号を出力すること
を特徴とする請求項1に記載の画像処理装置。
Threshold generating means for generating a first threshold and a second threshold having a value smaller than the first threshold;
The comparison unit binarizes the error addition data generated by the image correction unit using the second threshold generated by the threshold generation unit to generate re-binarized image data,
The pixel determination unit is configured such that the target pixel in the binary image data received by the binary image input unit is a pixel at an edge portion of an image indicated by the binary image data, and the error generated by the image correction unit When the value indicated by the addition data is less than the first threshold value and greater than or equal to the second threshold value, a pixel value selection signal instructing selection of the binary image data received by the binary image input means is output. The target pixel in the binary image data received by the binary image input means is a pixel at the edge portion of the image indicated by the binary image data, and the error addition data generated by the image correction means indicates When the value is greater than or equal to the first threshold value or less than the second threshold value, a pixel value selection signal instructing selection of the re-binarized image data generated by the comparison unit is output. The image processing apparatus according to claim 1.
前記画素判定手段が出力する画素値選択信号と、前記2値画像入力手段が受け取った2値画像データと、前記セレクタ部が出力した出力2値データとを時系列に記憶する記憶手段と、
前記記憶手段が記憶した画素値選択信号を時系列に順次読み出し、前記画素値選択信号の内容が、前記2値画像入力手段が受け取った2値画像データの出力指示から前記比較手段が生成した再2値化画像データの出力指示に変化した時、この直後の画素で前記セレクタ部が出力した出力2値データの画素値が、前記2値画像入力部が受け取った2値画像データの画素値と異なり、
且つ、次に前記画素値選択信号の内容が、前記2値画像入力手段が受け取った2値画像データの出力指示から前記比較手段が生成した再2値化画像データの出力指示に変化した時、この直後の画素で前記セレクタ部が出力した出力2値データの画素値が、前記2値画像入力部が受け取った2値画像データの画素値と異なる場合、
前記画素値選択信号が変化した時点の前記出力2値データの画素値を反転した修正画像データを生成して出力する画像データ修正手段と
を有することを特徴とする請求項1に記載の画像処理装置。
Storage means for storing, in time series, a pixel value selection signal output by the pixel determination means, binary image data received by the binary image input means, and output binary data output by the selector unit;
The pixel value selection signals stored in the storage unit are sequentially read out in time series, and the contents of the pixel value selection signals are reproduced by the comparison unit generated from the binary image data output instruction received by the binary image input unit. When changing to the output instruction of binarized image data, the pixel value of the output binary data output by the selector unit at the pixel immediately after this becomes the pixel value of the binary image data received by the binary image input unit. Differently
And, when the content of the pixel value selection signal is changed from the output instruction of the binary image data received by the binary image input means to the output instruction of the re-binarized image data generated by the comparison means , When the pixel value of the output binary data output by the selector unit at the pixel immediately after this is different from the pixel value of the binary image data received by the binary image input unit,
The image processing according to claim 1, further comprising: image data correction means for generating and outputting corrected image data obtained by inverting the pixel value of the output binary data at the time when the pixel value selection signal changes. apparatus.
前記画像データ修正手段は、
前記画素値選択信号の内容が、前記比較手段が生成した再2値化画像データの出力指示から前記2値画像入力手段が受け取った2値画像データの出力指示に変化した時、この直前の画素で前記セレクタ部が出力した出力2値データの画素値が、前記2値画像入力部が受け取った2値画像データの画素値と異なり、
且つ、次に前記画素値選択信号の内容が、前記比較手段が生成した再2値化画像データの出力指示から前記2値画像入力手段が受け取った2値画像データの出力指示に変化した時、この直前の画素で前記セレクタ部が出力した出力2値データの画素値が、前記2値画像入力部が受け取った2値画像データの画素値と異なる場合、
前記画素値選択信号が変化した時点の前記出力2値データの画素値を反転した修正画像データを生成して出力すること
を特徴とする請求項14に記載の画像処理装置。
The image data correction means includes
When the content of the pixel value selection signal changes from an output instruction for re-binarized image data generated by the comparison means to an output instruction for binary image data received by the binary image input means, the immediately preceding pixel The pixel value of the output binary data output by the selector unit is different from the pixel value of the binary image data received by the binary image input unit,
And then, when the content of the pixel value selection signal changes from the output instruction of the re-binarized image data generated by the comparison means to the output instruction of the binary image data received by the binary image input means, When the pixel value of the output binary data output by the selector unit at the immediately preceding pixel is different from the pixel value of the binary image data received by the binary image input unit,
The image processing apparatus according to claim 14, wherein the image processing apparatus generates and outputs corrected image data obtained by inverting the pixel value of the output binary data when the pixel value selection signal changes.
2値画像データを受け取る2値画像入力手段と、
前記2値画像データを多値化して所定の処理が施された多値画像データまたは前記2値画像データの画像と同じ画像を表す多値の画像データに所定の処理が施された多値画像データを受け取る多値画像入力手段と、
供給される誤差データと、前記多値画像入力手段から画素単位で供給される多値画像データの画素値とを画素単位で加算して誤差加算データを生成する画像補正手段と、
前記画像補正手段が生成した誤差加算データを閾値により2値化して再2値化画像データを生成する比較手段と、
前記2値画像入力手段が受け取った2値画像データにおける注目画素が、該2値画像データが示す画像のエッジ部分の画素であるか否か検知し、該2値画像データにおける注目画素が該画像のエッジ部分の画素である場合には、前記比較手段が生成した再2値化画像データを選択するように指示する画素値選択信号を出力し、該2値画像データにおける注目画素が該画像のエッジ部分の画素でない場合には、前記2値画像入力手段が受け取った2値画像データを選択するよう指示する画素値選択信号を出力する画素判定手段と、
前記画素判定手段が出力した画素値選択信号に従い、前記2値画像入力手段が受け取った2値画像データまたは前記比較手段が生成した再2値化画像データを選択し、出力2値データとして出力するセレクタ手段と、
前記画像補正手段が生成した誤差加算データと、前記セレクタ手段が出力した出力2値データと、前記2値画像入力手段が受け取った2値画像データを受取り、前記2値画像データにおける注目画素の画素値が白画素を示しており、且つ前記出力2値データが黒画素を示している場合には、前記多値画像入力手段が受け取った多値画像データが取りうる画素値の最大値を前記誤差加算データから減算した値を2値化誤差データとして出力し、前記2値画像データにおける注目画素の画素値が黒画素を示しており、且つ前記出力2値データが白画素を示している場合には、前記多値画像データが取りうる画素値の最大値を前記誤差加算データに加算した値を2値化誤差データとして出力し、前記2値画像データにおける注目画素の画素値と前記出力2値データの画素値が同じ場合には、前記誤差加算データを2値化誤差データとして出力する誤差算出手段と、
前記画像補正手段において前記多値画像データの画素値に加算される前記誤差データを、前記誤差算出手段により求められた2値化誤差データを用いて求め、求めた誤差データを前記画像補正手段に供給する補正算出手段と、
を有する画像処理装置。
Binary image input means for receiving binary image data;
Multi-valued image data obtained by subjecting the binary image data to multi-valued data and subjected to predetermined processing, or multi-valued image data representing the same image as the image of the binary image data. Multi-value image input means for receiving data ;
And error data supplied, and image correcting means for generating an error added data by adding the pixel values of the multivalued image data supplied by the multi-valued image input unit pixels from a pixel unit,
A comparison unit that binarizes the error addition data generated by the image correction unit using a threshold value to generate re-binarized image data;
It is detected whether the pixel of interest in the binary image data received by the binary image input means is a pixel at the edge portion of the image indicated by the binary image data, and the pixel of interest in the binary image data is the image. A pixel value selection signal instructing to select the re-binarized image data generated by the comparison means, and the target pixel in the binary image data is the pixel of the image. A pixel determination unit that outputs a pixel value selection signal instructing to select the binary image data received by the binary image input unit when the pixel is not an edge portion pixel;
According to the pixel value selection signal output from the pixel determination means, the binary image data received by the binary image input means or the re-binarized image data generated by the comparison means is selected and output as output binary data. Selector means;
The error addition data generated by the image correction unit, the output binary data output by the selector unit, and the binary image data received by the binary image input unit are received, and the pixel of the target pixel in the binary image data When the value indicates a white pixel and the output binary data indicates a black pixel, the maximum value of the pixel values that can be taken by the multi-value image data received by the multi-value image input means is set as the error. When the value subtracted from the addition data is output as binarization error data, the pixel value of the pixel of interest in the binary image data indicates a black pixel, and the output binary data indicates a white pixel outputs a value obtained by adding the error addition data the maximum value of the pixel values multivalued image data can take as the binarization error data, wherein the pixel value of the target pixel in the binary image data If the pixel value of the force binary data are the same, the error calculation means for outputting the error-added data as the binarization error data,
The error data to be added to the pixel value of the multi-value image data in the image correction means is obtained using the binarized error data obtained by the error calculation means, and the obtained error data is stored in the image correction means. Correction calculation means to be supplied ;
An image processing apparatus.
前記2値画像入力手段が受け取った2値画像データから多値画像データを生成する多値画像データ生成手段を具備し、
前記多値画像入力手段が受け取る多値画像データは、該多値画像データ生成手段により生成された多値画像データであること
を特徴とする請求項16に記載の画像処理装置。
Comprising multi-value image data generating means for generating multi-value image data from the binary image data received by the binary image input means;
The image processing apparatus according to claim 16, wherein the multi-value image data received by the multi-value image input means is multi-value image data generated by the multi-value image data generation means.
前記多値画像データ生成手段は、
前記2値画像入力手段が受け取った2値画像データによって表された2値の各画素値を各画素毎に各々複数ビットで表した単純多値画像データを生成する多値化手段と、
前記多値化手段により生成された単純多値画像データを平滑化して平滑化画像データを生成する平滑化手段と、
前記平滑化手段により生成された平滑化画像データに対して色補正を施した色補正画像データを生成する色補正画像データ生成手段とを有し、
該色補正画像データを多値画像データとして前記多値画像入力手段へ供給すること
を特徴とする請求項17に記載の画像処理装置。
The multi-value image data generating means
Multi-value conversion means for generating simple multi-value image data in which each of the binary pixel values represented by the binary image data received by the binary image input means is represented by a plurality of bits for each pixel;
Smoothing means for smoothing simple multi-value image data generated by the multi-value conversion means to generate smoothed image data;
Color correction image data generation means for generating color correction image data obtained by performing color correction on the smoothed image data generated by the smoothing means;
The image processing apparatus according to claim 17, wherein the color correction image data is supplied to the multi-value image input unit as multi-value image data.
前記多値画像データ生成手段は、
前記平滑化手段により生成された平滑化画像データと、前記色補正画像データ手段により生成された色補正画像データとの差分を画素単位で求め、この差分を示す差分画像データを生成する差分画像データ生成手段を具備し、
該差分画像データを多値画像データとして前記多値画像入力手段へ供給すること
を特徴とする請求項18に記載の画像処理装置。
The multi-value image data generating means
Difference image data for obtaining a difference between the smoothed image data generated by the smoothing unit and the color correction image data generated by the color correction image data unit in units of pixels and generating difference image data indicating the difference Comprising generating means,
The image processing apparatus according to claim 18, wherein the difference image data is supplied to the multi-value image input unit as multi-value image data.
前記2値画像入力手段が受け取る2値画像データは、各画素が各々複数のビットで表されている多値画像データに対してスクリーン処理が施されたデータであり、
該各画素が各々複数のビットで表されている多値画像データに対して色補正を施し、色補正画像データを生成する色補正データ生成手段を具備し、
前記多値画像入力手段が受け取る多値画像データは、該色補正データ生成手段により生成された色補正画像データであること
を特徴とする請求項16に記載の画像処理装置。
The binary image data received by the binary image input means is data obtained by performing screen processing on multi-value image data in which each pixel is represented by a plurality of bits.
Color correction data generation means for generating color correction image data by performing color correction on multi-value image data in which each pixel is represented by a plurality of bits,
The image processing apparatus according to claim 16, wherein the multi-value image data received by the multi-value image input unit is color correction image data generated by the color correction data generation unit.
前記色補正データ生成手段により受け取られる、各画素が各々複数のビットで表されている多値画像データと、前記色補正データ生成手段により生成された色補正画像データとの差分を画素単位で求め、この差分を示す差分画像データを生成する差分画像データ生成手段を具備し、
該差分画像データを多値画像データとして前記多値画像入力手段へ供給すること
を特徴とする請求項20に記載の画像処理装置。
The difference between the multi-valued image data received by the color correction data generation unit and each pixel represented by a plurality of bits and the color correction image data generated by the color correction data generation unit is obtained in units of pixels. , Comprising difference image data generation means for generating difference image data indicating the difference,
The image processing apparatus according to claim 20, wherein the difference image data is supplied to the multi-value image input means as multi-value image data.
コンピュータ装置を、
2値画像データを受け取る2値画像入力手段と、
前記2値画像データを多値化して所定の処理が施された多値画像データまたは前記2値画像データの画像と同じ画像を表す多値の画像データに所定の処理が施された多値画像データを受け取る多値画像入力手段と、
供給される誤差データと、前記多値画像入力手段から画素単位で供給される多値画像データの画素値とを画素単位で加算して誤差加算データを生成する画像補正手段と、
前記画像補正手段が生成した誤差加算データを閾値により2値化して再2値化画像データを生成する比較手段と、
前記2値画像入力手段が受け取った2値画像データにおける注目画素が、該2値画像データが示す画像のエッジ部分の画素であるか否か検知し、該2値画像データにおける注目画素が該画像のエッジ部分の画素である場合には、前記比較手段が生成した再2値化画像データを選択するように指示する画素値選択信号を出力し、該2値画像データにおける注目画素が該画像のエッジ部分の画素でない場合には、前記2値画像入力手段が受け取った2値画像データを選択するよう指示する画素値選択信号を出力する画素判定手段と、
前記画素判定手段が出力した画素値選択信号に従い、前記2値画像入力手段が受け取った2値画像データまたは前記比較手段が生成した再2値化画像データを選択し、出力2値データとして出力するセレクタ手段と、
前記画像補正手段が生成した誤差加算データと前記セレクタ手段が出力した出力2値データとを用いて、2値化により生じた誤差を示す2値化誤差データを求める誤差算出手段と、
前記画像補正手段において前記多値画像データの画素値に加算される前記誤差データを、前記誤差算出手段により求められた2値化誤差データを用いて求め、求めた誤差データを前記画像補正手段に供給する補正算出手段
として機能させるためのプログラム。
Computer equipment,
Binary image input means for receiving binary image data;
Multi-valued image data obtained by subjecting the binary image data to multi-valued data and subjected to predetermined processing, or multi-valued image data representing the same image as the image of the binary image data. Multi-value image input means for receiving data ;
And error data supplied, and image correcting means for generating an error added data by adding the pixel values of the multivalued image data supplied by the multi-valued image input unit pixels from a pixel unit,
A comparison unit that binarizes the error addition data generated by the image correction unit using a threshold value to generate re-binarized image data;
It is detected whether the pixel of interest in the binary image data received by the binary image input means is a pixel at the edge portion of the image indicated by the binary image data, and the pixel of interest in the binary image data is the image. A pixel value selection signal instructing to select the re-binarized image data generated by the comparison means , and the target pixel in the binary image data is the pixel of the image. A pixel determination unit that outputs a pixel value selection signal instructing to select the binary image data received by the binary image input unit when the pixel is not an edge portion pixel;
According to the pixel value selection signal output from the pixel determination means, the binary image data received by the binary image input means or the re-binarized image data generated by the comparison means is selected and output as output binary data. Selector means;
Error calculating means for obtaining binarized error data indicating an error caused by binarization using the error addition data generated by the image correcting means and the output binary data output by the selector means;
The error data to be added to the pixel value of the multi-value image data in the image correction means is obtained using the binarized error data obtained by the error calculation means, and the obtained error data is stored in the image correction means. A program for functioning as a correction calculation means to be supplied .
JP2004027106A 2003-06-09 2004-02-03 Image processing apparatus and program Expired - Fee Related JP4172399B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004027106A JP4172399B2 (en) 2003-06-09 2004-02-03 Image processing apparatus and program

Applications Claiming Priority (2)

Application Number Priority Date Filing Date Title
JP2003164298 2003-06-09
JP2004027106A JP4172399B2 (en) 2003-06-09 2004-02-03 Image processing apparatus and program

Publications (2)

Publication Number Publication Date
JP2005027270A JP2005027270A (en) 2005-01-27
JP4172399B2 true JP4172399B2 (en) 2008-10-29

Family

ID=34196894

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004027106A Expired - Fee Related JP4172399B2 (en) 2003-06-09 2004-02-03 Image processing apparatus and program

Country Status (1)

Country Link
JP (1) JP4172399B2 (en)

Families Citing this family (4)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2007088970A (en) * 2005-09-26 2007-04-05 Fuji Xerox Co Ltd Output apparatus
JP4894588B2 (en) * 2007-03-29 2012-03-14 富士ゼロックス株式会社 Image processing apparatus, printing apparatus, and image processing program
JP5971068B2 (en) 2012-10-02 2016-08-17 富士ゼロックス株式会社 Image processing apparatus, image forming system, and image processing program
US20150163375A1 (en) * 2013-12-11 2015-06-11 Ricoh Company, Ltd. Binary periodic to multibit aperiodic halftone and resolution conversion

Also Published As

Publication number Publication date
JP2005027270A (en) 2005-01-27

Similar Documents

Publication Publication Date Title
US5379130A (en) Text/image separation method
EP1505821B1 (en) Image processing apparatus, an image forming apparatus and an image processing method
US20040156079A1 (en) Laser print apparatus that generates pulse width value and justification value based on pixels in a multi-bit image
JPH08223422A (en) Processing system to prepare color document
EP0781034B1 (en) Image processing apparatus and method
US5862305A (en) Logic filters for resolution conversion of digital images
KR100418539B1 (en) Image processing apparatus, image processing method and computer-readable recording medium on which image processing program is recorded
JP4172399B2 (en) Image processing apparatus and program
JP3578878B2 (en) Image processing device
JP3982979B2 (en) Image forming apparatus
JP2000125134A (en) Image processor and image processing method
JP2003046793A (en) Method and device for image processing
JP4182907B2 (en) Image processing apparatus and program
JP4218560B2 (en) Image processing apparatus and program
JPH0738767A (en) Image binarizing processor
JP3111418B2 (en) Image forming device
JP2000156784A (en) Image processor, and image processing method and storage medium thereof
JP3810817B2 (en) Image processing device
US6246806B1 (en) Image processing apparatus
JP3461247B2 (en) Image processing apparatus and image processing method
JP2900907B2 (en) Image processing device
JP3501533B2 (en) Color image forming equipment
JP2005229418A (en) Image processing apparatus and image processing method
JP2005012475A (en) Image processing unit
JPH0795408A (en) Picture processor

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20070119

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20080117

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20080226

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20080422

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

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

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20080804

R150 Certificate of patent or registration of utility model

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20110822

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20120822

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20120822

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20130822

Year of fee payment: 5

LAPS Cancellation because of no payment of annual fees