JPH11191845A - Error diffusing method - Google Patents

Error diffusing method

Info

Publication number
JPH11191845A
JPH11191845A JP9356886A JP35688697A JPH11191845A JP H11191845 A JPH11191845 A JP H11191845A JP 9356886 A JP9356886 A JP 9356886A JP 35688697 A JP35688697 A JP 35688697A JP H11191845 A JPH11191845 A JP H11191845A
Authority
JP
Japan
Prior art keywords
error
image
degree
data
error diffusion
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.)
Pending
Application number
JP9356886A
Other languages
Japanese (ja)
Inventor
Nobuhisa Yamazaki
信久 山崎
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.)
PFU Ltd
Original Assignee
PFU Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by PFU Ltd filed Critical PFU Ltd
Priority to JP9356886A priority Critical patent/JPH11191845A/en
Publication of JPH11191845A publication Critical patent/JPH11191845A/en
Pending legal-status Critical Current

Links

Landscapes

  • Facsimile Image Signal Circuits (AREA)

Abstract

PROBLEM TO BE SOLVED: To prevent the generation of jaggy at the edge of a character by performing error diffusion processing while changing the degree of error influence corresponding to the sharpness degree of an image. SOLUTION: Maximum and minimum values are found from the density data of pixels around an object pixel to be binarized, and the sharpness degree of the image is found. The degree of error influence corresponding to that degree is calculated. Bias density data V of the object pixel are calculated by density data A of the object pixel, error data and a calculated degree αof error influence. If the V is <=255, the binarized data of the object pixel are made into '0' and a value to be stored in an error buffer is made into V. When the V is not <=255, the binarized data of the object pixel are made into '1', and the value to be stored in the error buffer is made into (V-255). When the degree α of error influence is equal with '0', the density data V become (A+V) and the error diffusion is performed to the binarized data. In the case of α=1, the density data V become (2A) and the error diffusion is not performed.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】この発明は、イメージ画像デ
ータを2値化する誤差拡散法に関するものであり、特
に、画像のメリハリの度合いにより、誤差の影響の度合
いを変化させ、イメージ画像内の文字のエッジで発生す
るジャギーをなくす。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an error diffusion method for binarizing image data, and more particularly, to changing the degree of the influence of an error depending on the degree of sharpness of an image, thereby enabling a character in an image to be displayed. Eliminates jaggies that occur at the edges

【0002】[0002]

【従来の技術】イメージ画像データを2値化する方法に
は、単純スライスや浮動スライスおよびディザ法があ
る。単純スライスや浮動スライスは、テキスト画像の再
現イメージはよいが、写真画像の再現イメージがよくな
い。また、ディザ法は、逆に写真画像の再現イメージは
よいが、テキスト画像の再現イメージがよくない。そし
て、またモワレ現象も発生する。
2. Description of the Related Art Methods for binarizing image data include a simple slice, a floating slice, and a dither method. The simple slice and the floating slice have a good reproduction image of the text image, but have a poor reproduction image of the photographic image. On the other hand, in the dither method, a reproduced image of a photographic image is good, but a reproduced image of a text image is not good. Then, a moiré phenomenon also occurs.

【0003】このため像域分離などの手法が用いられる
が、写真画像とテキスト画像の分離は難しく、特に「写
真の中の文字」はうまく再現できない。
For this reason, a technique such as image area separation is used, but it is difficult to separate a photographic image from a text image, and especially "characters in a photograph" cannot be reproduced well.

【0004】これを解決する手段として「誤差拡散法」
が知られている。誤差拡散法はディザ法と異なり、空間
に対して固定的なスライスを行っているのではなく、濃
度分布からその領域でのスライスを決めている。つま
り、2値化する対象画素の重みを1/2とし、残りの1
/2を周りの画素を参照することにより2値化処理を行
っている。
As a means for solving this, "error diffusion method"
It has been known. Unlike the dither method, the error diffusion method does not perform a fixed slice with respect to the space, but determines a slice in the area from the density distribution. That is, the weight of the target pixel to be binarized is set to 1 /, and the remaining 1
The binarization process is performed by referring to the surrounding pixels at / 2.

【0005】このため、誤差拡散法はテキスト画像およ
び中間調のある写真画像も再現イメージがよくなる。
[0005] For this reason, the error diffusion method improves the reproduced image of a text image and a photographic image having a halftone.

【0006】図4に、従来の誤差拡散処理の処理フロー
チャートを示す。また、図5に、2値化の対象となる対
象画素と周囲画素および誤差データにかける係数の説明
図を示す。
FIG. 4 shows a flowchart of a conventional error diffusion process. FIG. 5 is an explanatory diagram of a target pixel to be binarized, surrounding pixels, and coefficients applied to error data.

【0007】以下、図4のフローにしたがって動作を説
明する。なお、このフローはイメージ画像の1画素に対
しての誤差拡散処理を示したものであるが、イメージ画
像全体の処理は、対象画素を順次に変えて処理が行われ
るだけである。
Hereinafter, the operation will be described with reference to the flow chart of FIG. Although this flow shows the error diffusion processing for one pixel of the image image, the processing of the entire image image is performed only by sequentially changing the target pixel.

【0008】ステップS401:対象画素の濃度データ
Aと、その対象画素に対する周囲画素の誤差データとそ
れぞれの周囲画素の位置に対応して設けられた係数とを
かけた誤差データ加算値Bとを加えてバイアス濃度デー
タVを算出する。
Step S401: The density data A of the target pixel, the error data of the peripheral pixel with respect to the target pixel, and the error data addition value B obtained by multiplying the error data by a coefficient provided corresponding to the position of each peripheral pixel are added. To calculate bias density data V.

【0009】つまり、バイアス濃度データVは次のよう
に求まる。 バイアス濃度データV=A+B
That is, the bias density data V is obtained as follows. Bias density data V = A + B

【0010】このとき対象画素に対する周囲画素の誤差
データとその位置は、図5(a)のEa1、Ea2、E
a3、Eb1となる。そして、対象画素に対応する周囲
画素の誤差データの位置に対応して設けられた係数を図
5(b)の(1/8)、(1/4)、(1/8)、(1
/2)とすると、誤差データ加算値Bは次のように求ま
る。 誤差データ加算値B=Ea1×(1/8)+ Ea2×
(1/4)+Ea3×(1/8)+ Eb1×(1/
2)
At this time, the error data of the surrounding pixels with respect to the target pixel and their positions are represented by Ea1, Ea2, Ea in FIG.
a3 and Eb1. Then, the coefficients provided corresponding to the positions of the error data of the surrounding pixels corresponding to the target pixel are represented by (1/8), (1/4), (1/8), (1) in FIG.
/ 2), the error data addition value B is obtained as follows. Error data addition value B = Ea1 × (1/8) + Ea2 ×
(1/4) + Ea3 × (1/8) + Eb1 × (1 /
2)

【0011】ステップS402:バイアス濃度データV
が255以下か判定する。255以下ならばステップS
403に進み、255以下でなければステップS405
に進む。
Step S402: bias density data V
Is 255 or less. If less than 255, step S
Proceed to 403; if not less than 255, step S405
Proceed to.

【0012】ステップS403:対象画素の2値化デー
タを0(黒)とする。
Step S403: The binary data of the target pixel is set to 0 (black).

【0013】ステップS404:誤差バッファに格納す
る値をVとする。そして、処理を終了する。
Step S404: The value stored in the error buffer is set to V. Then, the process ends.

【0014】ステップS405:対象画素の2値化デー
タを1(白)とする。
Step S405: The binary data of the target pixel is set to 1 (white).

【0015】ステップS406:誤差バッファに格納す
る値を(V−255)とする。そして、処理を終了す
る。
Step S406: The value stored in the error buffer is set to (V-255). Then, the process ends.

【0016】[0016]

【発明が解決しようとする課題】しかしながら、図4に
示す従来技術では、2値化する対象画素の重みがいかな
る場合でも1/2に固定であるため、特に文字のエッジ
のように中間的な出力の場合、周りの影響で「白」また
は「黒」に2値化の結果が交番し、結果的にジャギーが
発生してしまう。
However, in the prior art shown in FIG. 4, since the weight of the target pixel to be binarized is fixed to い か な る in any case, an intermediate pixel such as a character edge is used. In the case of output, the result of binarization alternates between "white" or "black" due to the surroundings, resulting in jaggies.

【0017】図6に、従来の誤差拡散法で2値化した画
像データの文字のエッジの拡大図を示す。この図は、文
字「/」の一部を拡大した図であり、○で囲まれた部分
が発生したジャギーである。
FIG. 6 is an enlarged view of a character edge of image data binarized by a conventional error diffusion method. This figure is an enlarged view of a part of the character “/”, and the part surrounded by a circle is a jaggy.

【0018】このように誤差拡散法でもテキスト画像は
文字の周りにジャギーが発生し、単純スライスほどの画
質にならないという問題点があった。
As described above, even in the error diffusion method, there is a problem that a text image is jagged around a character and the image quality is not as high as that of a simple slice.

【0019】[0019]

【課題を解決するための手段】この発明は上記のような
問題点を考慮してなされたもので、画像のメリハリの度
合いにより、誤差の影響の度合いを変化させて誤差拡散
の処理を行う。これにより、イメージ画像内の文字のエ
ッジで発生するジャギーをなくすことが可能となる。
SUMMARY OF THE INVENTION The present invention has been made in consideration of the above-described problems, and performs error diffusion processing by changing the degree of influence of an error depending on the degree of sharpness of an image. This makes it possible to eliminate jaggies that occur at the edges of characters in the image.

【0020】[0020]

【発明の実施の形態】イメージ画像データを2値化する
誤差拡散法において、画像のメリハリの度合いにより、
誤差の影響の度合いを変化させて誤差拡散の処理を行
う。これにより、イメージ画像内の文字のエッジで発生
するジャギーをなくすことが可能となる。
DESCRIPTION OF THE PREFERRED EMBODIMENTS In an error diffusion method for binarizing image image data, the degree of sharpness of an image is determined according to the degree of sharpness of the image.
The error diffusion process is performed by changing the degree of the influence of the error. This makes it possible to eliminate jaggies that occur at the edges of characters in the image.

【0021】また、周囲画素の最大値から最小値を減算
した値で画像のメリハリの度合いを設定する。これによ
り、単純かつ迅速に画像のメリハリの度合いを算出する
ことができる。
The sharpness of the image is set by a value obtained by subtracting the minimum value from the maximum value of the surrounding pixels. This makes it possible to calculate the degree of sharpness of the image simply and quickly.

【0022】また、誤差の影響の度合いを画像のメリハ
リの度合いにより、線形または非線形に変化させる。こ
れにより、イメージ画像をテキスト画像風および写真画
像風に調整することができる。また、イメージ画像内の
文字のエッジで発生するジャギーをなくすことが可能と
なる。
The degree of the influence of the error is changed linearly or non-linearly according to the degree of sharpness of the image. Thereby, the image image can be adjusted to a text image style and a photographic image style. In addition, it is possible to eliminate jaggies that occur at edges of characters in the image.

【0023】[0023]

【実施例】図1に、本発明の誤差拡散処理の一実施例の
処理フローチャートを示す。また図2に、対象画素と周
囲画素の説明図を示す。以下、このフローにしたがって
動作を説明する。
FIG. 1 is a flowchart showing an error diffusion process according to an embodiment of the present invention. FIG. 2 is an explanatory diagram of a target pixel and surrounding pixels. Hereinafter, the operation will be described according to this flow.

【0024】ステップS101:2値化する対象画素に
対する周囲画素の濃度データから最大値と最小値を求
め、画像のメリハリの度合いを(最大値−最小値)で求
める。
Step S101: The maximum value and the minimum value are obtained from the density data of the surrounding pixels for the target pixel to be binarized, and the sharpness of the image is obtained by (maximum value-minimum value).

【0025】なお、対象画素に対する周囲画素とは、図
2に示されるように、対象画素の周りの画素Ma1〜M
a3、Mb1、Mb3、Mc1〜Mc3である。
The surrounding pixels for the target pixel are, as shown in FIG. 2, pixels Ma1 to Ma around the target pixel.
a3, Mb1, Mb3, Mc1 to Mc3.

【0026】ステップS102:画像のメリハリの度合
いに対応する誤差の影響の度合いを対応テーブルから算
出する。
Step S102: The degree of influence of an error corresponding to the degree of sharpness of the image is calculated from the correspondence table.

【0027】図3に、画像のメリハリの度合い/誤差の
影響の度合いの対応テーブルの一実施例図を示す。この
例では、画像のメリハリの度合い、つまり画像の濃度デ
ータ0〜255に対応させて線形に変化する誤差の影響
の度合いαを設定している。例えば、画像の濃度データ
をnとすると誤差の影響の度合いαはn/255として
いる。
FIG. 3 shows an embodiment of a correspondence table of the degree of sharpness of an image / the degree of influence of an error. In this example, the degree of sharpness of the image, that is, the degree α of the influence of an error that changes linearly in accordance with the density data 0 to 255 of the image is set. For example, if the density data of the image is n, the degree α of the influence of the error is n / 255.

【0028】ステップS103:対象画素の濃度データ
Aとその誤差データおよびステップS102で算出した
誤差の影響の度合いαにより対象画素のバイアス濃度デ
ータVを算出する。対象画素に対する誤差データが図5
と同じであり、また誤差データ加算値をBとするとバイ
アス濃度データVは次のように求まる。 バイアス濃度データV=(1+α)A+(1−α)B
Step S103: The bias density data V of the target pixel is calculated from the density data A of the target pixel and the error data thereof and the degree of the influence α of the error calculated in step S102. FIG. 5 shows the error data for the target pixel.
The bias density data V is obtained as follows when the error data addition value is B. Bias density data V = (1 + α) A + (1-α) B

【0029】ステップS104:バイアス濃度データV
が255以下か判定する。255以下ならばステップS
105に進み、255以下でなければステップS107
に進む。
Step S104: bias density data V
Is 255 or less. If less than 255, step S
Proceed to 105, if not less than 255, step S107
Proceed to.

【0030】ステップS105:対象画素の2値化デー
タを0(黒)とする。
Step S105: The binary data of the target pixel is set to 0 (black).

【0031】ステップS106:誤差バッファに格納す
る値をVとする。そして、処理を終了する。
Step S106: The value stored in the error buffer is set to V. Then, the process ends.

【0032】ステップS107:対象画素の2値化デー
タを1(白)とする。
Step S107: The binary data of the target pixel is set to 1 (white).

【0033】ステップS108:誤差バッファに格納す
る値を(V−255)とする。そして、処理を終了す
る。
Step S108: The value stored in the error buffer is set to (V-255). Then, the process ends.

【0034】この処理では、ステップS103で求める
バイアス濃度データが2値化の判断値であり、誤差の影
響の度合いαが、α=0の場合は濃度データVは(A+
B)となり、2値化された画像データは誤差拡散が施さ
れ、写真画像に適した画像が得られる。またα=1の場
合は濃度データVは(2A)となり、2値化された画像
データは誤差拡散が施されず、テキスト画像に適した画
像が得られる。
In this processing, the bias density data obtained in step S103 is a decision value for binarization, and when the degree α of the influence of the error is α = 0, the density data V is (A +
B), the binarized image data is subjected to error diffusion, and an image suitable for a photographic image is obtained. If α = 1, the density data V is (2A), and the binarized image data is not subjected to error diffusion, and an image suitable for a text image is obtained.

【0035】[0035]

【発明の効果】この発明は、上記に説明したような形態
で実施され、以下の効果がある。
The present invention is embodied in the form described above, and has the following effects.

【0036】誤差拡散法でテキスト画像が含まれるイメ
ージ画像データを2値化しても、文字のエッジでジャギ
ーが発生しない画像データを得ることが可能となる。
Even if the image data including the text image is binarized by the error diffusion method, it is possible to obtain image data in which jaggies do not occur at the edges of the characters.

【図面の簡単な説明】[Brief description of the drawings]

【図1】 本発明の誤差拡散処理の一実施例の処理フロ
ーチャートである。
FIG. 1 is a process flowchart of an embodiment of an error diffusion process of the present invention.

【図2】 対象画素と周囲画素の説明図である。FIG. 2 is an explanatory diagram of a target pixel and surrounding pixels.

【図3】 画像のメリハリの度合い/誤差の影響の度合
いの対応テーブルの一実施例図である。
FIG. 3 is a diagram illustrating an example of a correspondence table of a degree of sharpness of an image / a degree of influence of an error.

【図4】 従来の誤差拡散処理の処理フローチャートで
ある。
FIG. 4 is a processing flowchart of a conventional error diffusion process.

【図5】 対象画素と周囲画素および誤差データにかけ
る係数の説明図である。
FIG. 5 is an explanatory diagram of a target pixel, surrounding pixels, and coefficients applied to error data.

【図6】 従来の誤差拡散法で2値化した画像データの
文字のエッジの拡大図である。
FIG. 6 is an enlarged view of a character edge of image data binarized by a conventional error diffusion method.

【符号の説明】[Explanation of symbols]

1 誤差拡散処理 1 Error diffusion processing

Claims (3)

【特許請求の範囲】[Claims] 【請求項1】 イメージ画像データを2値化する誤差拡
散法において、画像のメリハリの度合いにより、誤差の
影響の度合いを変化させて誤差拡散の処理を行うことを
特徴とする誤差拡散法。
1. An error diffusion method for binarizing image image data, wherein error diffusion processing is performed by changing the degree of influence of an error depending on the degree of sharpness of an image.
【請求項2】 周囲画素の最大値から最小値を減算した
値で画像のメリハリの度合いを設定することを特徴とす
る請求項1記載の誤差拡散法。
2. The error diffusion method according to claim 1, wherein the degree of sharpness of the image is set by a value obtained by subtracting a minimum value from a maximum value of surrounding pixels.
【請求項3】 誤差の影響の度合いを画像のメリハリの
度合いにより線形または非線形に変化させることを特徴
とする請求項1記載の誤差拡散法。
3. The error diffusion method according to claim 1, wherein the degree of the influence of the error is changed linearly or non-linearly according to the degree of sharpness of the image.
JP9356886A 1997-12-25 1997-12-25 Error diffusing method Pending JPH11191845A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP9356886A JPH11191845A (en) 1997-12-25 1997-12-25 Error diffusing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP9356886A JPH11191845A (en) 1997-12-25 1997-12-25 Error diffusing method

Publications (1)

Publication Number Publication Date
JPH11191845A true JPH11191845A (en) 1999-07-13

Family

ID=18451256

Family Applications (1)

Application Number Title Priority Date Filing Date
JP9356886A Pending JPH11191845A (en) 1997-12-25 1997-12-25 Error diffusing method

Country Status (1)

Country Link
JP (1) JPH11191845A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10205850B2 (en) 2016-09-22 2019-02-12 Brother Kogyo Kabushiki Kaisha Image processor and storage medium storing program

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US10205850B2 (en) 2016-09-22 2019-02-12 Brother Kogyo Kabushiki Kaisha Image processor and storage medium storing program

Similar Documents

Publication Publication Date Title
JP3585703B2 (en) Image processing device
JPH02110629A (en) Method and device for generating composite picture
JPH07131634A (en) Image processor
JPH1056569A (en) Image processing method and device therefor
JP3026706B2 (en) Image processing device
JPH11191845A (en) Error diffusing method
JP3262425B2 (en) Image processing device
JPH0799575A (en) Processing method for picture information
JPH10200733A (en) Image processing unit
JPS60136478A (en) Picture processor
JP2841942B2 (en) Image input device
JPH05160996A (en) Image processing method
JP3787890B2 (en) Image processing device
JP2825927B2 (en) Image processing device
JP2729278B2 (en) Image binarization expression method
JP3017249B2 (en) Image reproduction device
JP2000149009A (en) Image processor
JPH05191637A (en) Picture magnification device
JPH11275368A (en) Picture correction processing method
JPH06205201A (en) Binary picture magnification/reduction device
JPS6118388B2 (en)
JPH0548870A (en) Frame erasing method
JPH10200734A (en) Image processing unit
JPH06178087A (en) Enlargement and reduction processing system for dither picture
JPS61194974A (en) Image processing method