JP3480547B2 - Image correction method and apparatus, and storage medium storing program - Google Patents

Image correction method and apparatus, and storage medium storing program

Info

Publication number
JP3480547B2
JP3480547B2 JP14766997A JP14766997A JP3480547B2 JP 3480547 B2 JP3480547 B2 JP 3480547B2 JP 14766997 A JP14766997 A JP 14766997A JP 14766997 A JP14766997 A JP 14766997A JP 3480547 B2 JP3480547 B2 JP 3480547B2
Authority
JP
Japan
Prior art keywords
pixel
density data
value
image
weighted average
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
JP14766997A
Other languages
Japanese (ja)
Other versions
JPH10336451A (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.)
Screen Holdings Co Ltd
Dainippon Screen Manufacturing Co Ltd
Original Assignee
Screen Holdings Co Ltd
Dainippon Screen Manufacturing Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Screen Holdings Co Ltd, Dainippon Screen Manufacturing Co Ltd filed Critical Screen Holdings Co Ltd
Priority to JP14766997A priority Critical patent/JP3480547B2/en
Publication of JPH10336451A publication Critical patent/JPH10336451A/en
Application granted granted Critical
Publication of JP3480547B2 publication Critical patent/JP3480547B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Landscapes

  • Facsimile Image Signal Circuits (AREA)

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【発明の属する技術分野】本発明は、デジタルの原画像
を修正する画像修正方法及びその方法を実施する画像修
正装置並びにその方法をコンピュータに実行させるため
のプログラムを記録した記憶媒体に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to an image correction method for correcting a digital original image, an image correction apparatus for executing the method, and a storage medium recording a program for causing a computer to execute the method.

【0002】[0002]

【従来の技術】従来のこの種の画像修正処理としては、
ノイズ除去フィルター処理やシャープネス処理などが知
られている。
2. Description of the Related Art As a conventional image correction process of this type,
Noise removal filter processing and sharpness processing are known.

【0003】ノイズ除去フィルター処理は、周知のよう
に、原画像の各画素を順次注目画素とし、注目画素の濃
度データとその注目画素の周囲の周辺画素群を構成する
各画素の濃度データとの荷重平均値を、その注目画素に
対する修正画像の画素の濃度データとする処理であり、
この処理により原画像のノイズ成分を軽減することがで
きる。
As is well known, the noise removal filter process uses each pixel of the original image as a target pixel in order, and the density data of the target pixel and the density data of each pixel forming a peripheral pixel group around the target pixel. It is a process of using the weighted average value as the density data of the pixel of the corrected image with respect to the pixel of interest,
By this processing, the noise component of the original image can be reduced.

【0004】シャープネス処理は、周知のように、原画
像のボケ画像(アンシャープマスク)を求め、原画像と
前記ボケ画像との差分を対応する画素ごとに行って各画
素のエッジ成分を求め、原画像の各画素に、対応する画
素の前記エッジ成分を加える処理であり、この処理によ
り原画像のエッジ成分の尖鋭度を強調することができ
る。
As is well known, in the sharpness processing, a blurred image (unsharp mask) of the original image is obtained, and a difference between the original image and the blurred image is obtained for each corresponding pixel to obtain an edge component of each pixel, This is a process of adding the edge component of the corresponding pixel to each pixel of the original image. By this process, the sharpness of the edge component of the original image can be emphasized.

【0005】[0005]

【発明が解決しようとする課題】しかしながら、このよ
うな構成を有する従来例の場合には、次のような問題が
ある。例えば、図14に示すような原稿GGを、同図の
点線で示すようにCCDなどの撮像デバイスの各画素が
位置された状態で画像を取り込むと、取り込んだ画像
(原画像)OGは図15に示すようになる。なお、図
(a)は原画像OGを示し、同図(b)は原画像OG
の各画素の濃度データを数値で、同図(c)はグラフ化
して示したものであり、濃度データは0.00〜1.0
0の範囲に正規化されているとする。
However, the conventional example having such a structure has the following problems. For example, the original GG shown in FIG. 14, when capturing an image in a state in which each pixel of the imaging device is positioned, such as a CCD, as shown by the dotted line in the figure, captured image (original image) OG Figure 15 As shown in. It should be noted that, as shown in FIG. 1
5 (a) shows the original image OG, and FIG. 5 (b) shows the original image OG.
The density data of each pixel are numerical values, and FIG. 7C is a graph showing the density data, and the density data is 0.00 to 1.0.
It is assumed to be normalized to the range of 0.

【0006】 図15に示すように、原画像OGには画
像の取り込み段階でノイズ成分(図では(tX2
)の画素)が付加され、また、原稿GGのエッジE
Gが(tX6,t)の画素内を通過しているので、原
稿GGと比べてエッジEGの尖鋭度が低下している。
As shown in FIG. 15 , in the original image OG, noise components ((t X2 ,
t Y ) pixels) and the edge E of the original GG.
Since G passes through the pixel of (t X6 , t Y ), the sharpness of the edge EG is lower than that of the original GG.

【0007】 上記図15に示す原画像OGに対して、
注目画素の左右の画素を周辺画素群としてノイズ除去フ
ィルター処理を施すと図16(a)に示すようになり、
シャープネス処理を施すと図16(b)に示すようにな
る。
[0007] with respect to the original image OG shown in FIG. 15,
When the left and right pixels of the target pixel subjected to the noise removal filter as peripheral pixel group becomes as shown in FIG. 16 (a),
When subjected to sharpness processing as shown in FIG. 16 (b).

【0008】 図16に示すように、ノイズ除去フィル
ター処理の場合は、原画像の(tX2,t)の画素の
ノイズ成分は軽減されているが、同時にtX6近辺の画
素の濃度データが均されて原稿GGのエッジEG部分の
尖鋭度が原画像OGよりも一層低下している。また、シ
ャープネス処理の場合は、原稿GGのエッジEG部分の
尖鋭度は向上しているが、同時に原画像の(tX2,t
)の画素のノイズ成分も強調され画質が低下してい
る。
As shown in FIG. 16 , in the case of the noise removal filter processing, the noise component of the pixel of (t X2 , t Y ) of the original image is reduced, but at the same time, the density data of the pixel in the vicinity of t X6 is reduced. As a result, the sharpness of the edge EG portion of the original GG is further lowered than that of the original image OG. Further, in the case of the sharpness processing, the sharpness of the edge EG portion of the document GG is improved, but at the same time, (t X2 , t of the original image).
The noise component of the pixel of Y 2 ) is also emphasized and the image quality is degraded.

【0009】このように従来の画像修正では、ノイズ成
分を軽減させようとすると同時にエッジの尖鋭度が低下
し、一方、エッジの尖鋭度を向上させようとすると同時
にノイズ成分を強調するという問題があった。
As described above, in the conventional image correction, there is a problem that the sharpness of the edge is lowered at the same time as the noise component is reduced, while the noise component is emphasized while the sharpness of the edge is improved. there were.

【0010】本発明は、このような事情に鑑みてなされ
たものであって、1回の画像修正によってエッジの尖鋭
度を向上するとともにノイズ成分を軽減することができ
る画像修正方法及びその装置並びにプログラムを記録し
た記憶媒体を提供することを目的とする。
The present invention has been made in view of the above circumstances, and an image correction method and apparatus capable of improving the sharpness of an edge and reducing a noise component by a single image correction, and an apparatus thereof. It is an object to provide a storage medium recording a program.

【0011】[0011]

【課題を解決するための手段】本発明は、このような目
的を達成するために、次のような構成をとる。すなわ
ち、請求項1に記載の発明は、デジタルの原画像を修正
する画像修正方法において、(1−1)原画像の注目画
素付近のコントラスト量を算出する工程と、(1−2)
前記注目画素に隣接する隣設画素群を構成する各画素の
濃度データのうち、前記注目画素の濃度データに最も近
い濃度データ(以下、この濃度データを「修正値」とい
う)と、前記注目画素の濃度データと前記注目画素の周
囲の周辺画素群を構成する各画素の濃度データとの荷重
平均値(以下、この荷重平均値を単に「荷重平均値」と
いう)との混合比率を、前記コントラスト量の値が大き
くなるに従って前記修正値の混合比率分を大きくし、前
記コントラスト量の値が小さくなるに従って前記荷重平
均値の混合比率分を大きくするように、前記コントラス
ト量の値に応じて決める工程と、(1−3)前記決定さ
れた混合比率で前記修正値と前記荷重平均値とを混合し
た結果を、前記注目画素に対する修正画像の画素の濃度
データとする工程と、を備えて原画像の各画素を順次注
目画素として原画像を修正した修正画像を得ることを特
徴とするものである。
The present invention has the following constitution in order to achieve such an object. That is, the invention according to claim 1 is, in an image correction method for correcting a digital original image, (1-1) a step of calculating a contrast amount near a target pixel of the original image, and (1-2)
Among the density data of each pixel forming the adjacent pixel group adjacent to the target pixel, the density data closest to the density data of the target pixel (hereinafter, this density data is referred to as “correction value”), and the target pixel And the weighted average value (hereinafter, this weighted average value is simply referred to as “weighted average value”) of the density data of each of the pixels forming the peripheral pixel group around the pixel of interest and It is determined according to the value of the contrast amount so that the mixing ratio of the correction value increases as the value of the amount increases, and the mixing ratio of the weighted average value increases as the value of the contrast amount decreases. And (1-3) the result of mixing the correction value and the weighted average value with the determined mixing ratio as the density data of the pixel of the correction image with respect to the target pixel. , It is characterized in that to obtain a corrected image obtained by correcting the original image as a sequential pixel of interest of each pixel of the original image comprises a.

【0012】[0012]

【0013】 請求項に記載の発明は、デジタルの原
画像を修正する画像修正装置において、原画像を記憶す
る原画像記憶手段と、原画像を修正した修正画像を記憶
する修正画像記憶手段と、原画像の注目画素付近のコン
トラスト量を算出するコントラスト量算出手段と、前記
注目画素に隣接する隣設画素群を構成する各画素の濃度
データのうち、前記注目画素の濃度データに最も近い濃
度データ(以下、この濃度データを「修正値」という)
を抽出する修正値抽出手段と、前記注目画素の濃度デー
タと前記注目画素の周囲の周辺画素群を構成する各画素
の濃度データとの荷重平均値(以下、この荷重平均値を
単に「荷重平均値」という)を算出する荷重平均値算出
手段と、前記コントラスト量の値が大きくなるに従って
前記修正値の混合比率分を大きくし、前記コントラスト
量の値が小さくなるに従って前記荷重平均値の混合比率
分を大きくするように、前記コントラスト量の値に応じ
て前記修正値と前記荷重平均値との混合比率を決める混
合比率決定手段と、前記決定された混合比率で前記修正
値と前記荷重平均値とを混合した結果を、前記注目画素
に対する修正画像の画素の濃度データとして前記修正画
像記憶手段に記憶する混合手段と、原画像の各画素を順
次注目画素として前記修正画像を得るように制御する制
御手段と、を備えたことを特徴とするものである。
According to a second aspect of the present invention, in an image correction device that corrects a digital original image, an original image storage unit that stores the original image, and a corrected image storage unit that stores the corrected image obtained by correcting the original image. A contrast amount calculating means for calculating a contrast amount in the vicinity of the target pixel of the original image, and a density closest to the density data of the target pixel among the density data of each pixel forming an adjacent pixel group adjacent to the target pixel. Data (Hereafter, this density data is called "correction value")
And a weighted average value of the density data of the target pixel and the density data of each pixel forming a peripheral pixel group around the target pixel (hereinafter, this weighted average value is simply referred to as “weighted average”). Value)), a mixing ratio of the correction value is increased as the value of the contrast amount is increased, and a mixing ratio of the weight average value is decreased as the value of the contrast amount is decreased. So as to increase the amount, a mixing ratio determining means for determining a mixing ratio between the correction value and the weighted average value according to the value of the contrast amount, and the correction value and the weighted average value at the determined mixing ratio. And a mixing unit that stores the result of mixing the corrected image storage unit in the corrected image storage unit as density data of the pixel of the corrected image with respect to the target pixel, And control means for controlling so as to obtain the serial corrected image, is characterized in that it comprises a.

【0014】[0014]

【0015】 請求項に記載の発明は、デジタルの原
画像を修正する処理をコンピュータに実行させるための
プログラムを記録した記憶媒体であって、(1−1)原
画像の注目画素付近のコントラスト量を算出する工程
と、(1−2)前記注目画素に隣接する隣設画素群を構
成する各画素の濃度データのうち、前記注目画素の濃度
データに最も近い濃度データ(以下、この濃度データを
「修正値」という)と、前記注目画素の濃度データと前
記注目画素の周囲の周辺画素群を構成する各画素の濃度
データとの荷重平均値(以下、この荷重平均値を単に
「荷重平均値」という)との混合比率を、前記コントラ
スト量の値が大きくなるに従って前記修正値の混合比率
分を大きくし、前記コントラスト量の値が小さくなるに
従って前記荷重平均値の混合比率分を大きくするよう
に、前記コントラスト量の値に応じて決める工程と、
(1−3)前記決定された混合比率で前記修正値と前記
荷重平均値とを混合した結果を、前記注目画素に対する
修正画像の画素の濃度データとする工程と、を備えて原
画像の各画素を順次注目画素として原画像を修正した修
正画像を得る処理をコンピュータに実行させるためのプ
ログラムを記憶媒体に記録したものである。
According to a third aspect of the present invention, there is provided a storage medium in which a program for causing a computer to execute a process of correcting a digital original image is recorded. A step of calculating the amount, and (1-2) the density data closest to the density data of the pixel of interest (hereinafter referred to as density data) among the density data of each pixel forming the adjacent pixel group adjacent to the pixel of interest. Is referred to as a “correction value”) and a density average value of the density data of the pixel of interest and density data of each pixel forming a peripheral pixel group around the pixel of interest (hereinafter, this weighted average value is simply referred to as a “weighted average”). Value)) as the mixing ratio of the correction value increases as the value of the contrast amount increases, and the weighted average value of the weighted average value decreases as the value of the contrast amount decreases. A step of determining according to the value of the contrast amount so as to increase the mixing ratio,
(1-3) The step of setting the result of mixing the correction value and the weighted average value at the determined mixing ratio as the density data of the pixel of the correction image with respect to the pixel of interest, A program for causing a computer to execute a process for obtaining a corrected image in which an original image is corrected by sequentially setting pixels as a target pixel is recorded in a storage medium.

【0016】[0016]

【0017】[0017]

【作用】請求項1に記載の発明に係る画像修正方法は、
原画像の各画素を順次注目画素として、注目画素ごとに
以下の(1−1)〜(1−3)の工程を行い原画像を修
正した修正画像を得る。
The image correction method according to the invention described in claim 1 is
Using each pixel of the original image as a target pixel in sequence, the following steps (1-1) to (1-3) are performed for each target pixel to obtain a corrected image in which the original image is corrected.

【0018】(1−1)の工程では、原画像の現在の注
目画素付近のコントラスト量を算出する。
In step (1-1), the contrast amount in the vicinity of the current pixel of interest of the original image is calculated.

【0019】(1−2)の工程では、現在の注目画素に
隣接する隣設画素群を構成する各画素の濃度データのう
ち、その注目画素の濃度データに最も近い濃度データ
(修正値)と、その注目画素の濃度データとその注目画
素の周囲の周辺画素群を構成する各画素の濃度データと
の荷重平均値(荷重平均値)との混合比率を、(1−
1)の工程で算出したコントラスト量の値が大きくなる
に従って修正値の混合比率分を大きくし、上記コントラ
スト量の値が小さくなるに従って荷重平均値の混合比率
分を大きくするように、上記コントラスト量の値に応じ
て決める。
In the step (1-2), among the density data of each pixel forming the adjacent pixel group adjacent to the current target pixel, the density data (correction value) closest to the density data of the target pixel is obtained. , The weighted average value (weighted average value) of the density data of the target pixel and the density data of each pixel forming the peripheral pixel group around the target pixel is (1-
As the value of the contrast amount calculated in the step 1) increases, the mixing ratio of the correction value increases, and as the value of the contrast decreases, the mixing ratio of the weighted average value increases. Determine according to the value of.

【0020】(1−3)の工程では、(1−2)の工程
で決定された混合比率で修正値と荷重平均値とを混合し
た結果を、現在の注目画素に対する修正画像の画素の濃
度データとする。
In step (1-3), the result of mixing the correction value and the weighted average value with the mixing ratio determined in step (1-2) is used as the density of the pixel of the corrected image with respect to the current pixel of interest. Data.

【0021】原画像の注目画素内にエッジが通過してい
れば、その注目画素付近のコントラスト量が大きくな
り、一方、原画像の注目画素付近の画素の濃度データが
略同じ部分(平坦部)や、濃度データが滑らかに変化し
ている部分では、その注目画素付近のコントラスト量が
小さくなる。また、平坦部や濃度データが滑らかに変化
している部分にノイズ成分があれば、その付近のコント
ラスト量が若干大きくなるが、エッジによるコントラス
ト量に比べると小さい。
If the edge passes through the target pixel of the original image, the contrast amount near the target pixel becomes large, while the density data of the pixels near the target pixel of the original image are substantially the same (flat portion). Alternatively, the contrast amount in the vicinity of the target pixel becomes small in the portion where the density data changes smoothly. Further, if there is a noise component in the flat portion or the portion where the density data changes smoothly, the contrast amount in the vicinity thereof will be slightly larger, but it is smaller than the contrast amount due to the edge.

【0022】従って、上述したように注目画素付近のコ
ントラスト量に応じて修正値と荷重平均値との混合比率
を決めることで、原画像のエッジ部分の修正では、修正
値の混合比率分を大きくして(必要に応じて、荷重平均
値の混合比率分を「0」として)修正値と荷重平均値と
を混合して修正画像の画素の濃度データを求める。修正
値は、注目画素に隣接する隣設画素群を構成する各画素
の濃度データのうち、注目画素の濃度データに最も近い
濃度データである。この修正値の混合比率分を大きくす
ることにより、注目画素に対する修正画像の画素の濃度
データを、その隣接する1画素の濃度データと略同じす
ることになる。原画像の注目画素内にエッジが通過して
いれば、注目画素の一方側の隣接画素の濃度は濃く、他
方側の隣接画素の濃度は淡く、注目画素の濃度はその中
間であり、濃い、中間、淡い画素が並ぶことで原画像の
エッジの尖鋭度が低下していたのを、上記画像修正によ
り、修正画像では、濃い、濃い、淡い(または、濃い、
淡い、淡い)画素が並ぶことになり、エッジの尖鋭度を
向上させることができる。また、修正値として注目画素
の濃度データに最も近い隣接画素の濃度データを選択し
ているので、注目画素内のエッジの位置を反映させてエ
ッジの尖鋭度を強調させることがきる。
Therefore, as described above, by determining the mixture ratio of the correction value and the weighted average value according to the contrast amount in the vicinity of the pixel of interest, in the correction of the edge portion of the original image, the mixture ratio of the correction value is increased. Then, the correction value and the weighted average value are mixed (if necessary, the mixing ratio of the weighted average value is set to “0”) to obtain the density data of the pixel of the corrected image. The correction value is the density data closest to the density data of the target pixel among the density data of each pixel forming the adjacent pixel group adjacent to the target pixel. By increasing the mixture ratio of the correction values, the density data of the pixel of the corrected image with respect to the pixel of interest becomes substantially the same as the density data of the adjacent one pixel. If the edge passes through the target pixel of the original image, the density of the adjacent pixel on one side of the target pixel is dark, the density of the adjacent pixel on the other side is light, and the density of the target pixel is in the middle, dark, The sharpness of the edge of the original image was reduced by arranging the middle and light pixels, but by the above image correction, the corrected image is dark, dark, light (or dark,
Light (light) pixels are arranged, and the sharpness of the edge can be improved. Further, since the density data of the adjacent pixel closest to the density data of the pixel of interest is selected as the correction value, it is possible to emphasize the sharpness of the edge by reflecting the position of the edge in the pixel of interest.

【0023】一方、原画像の平坦部や濃度データが滑ら
かに変化している部分の修正では、荷重平均値の混合比
率分を大きくして(必要に応じて、修正値の混合比率分
を「0」として)修正値と荷重平均値とを混合して修正
画像の画素の濃度データを求めることにより、原画像の
平坦部や濃度データが滑らかに変化している部分のノイ
ズ成分は、注目画素の周辺の複数画素の略等しい濃度デ
ータと荷重平均されて軽減される。
On the other hand, in the correction of the flat part of the original image or the part where the density data is changing smoothly, the mixing ratio of the weighted average value is increased (if necessary, the mixing ratio of the correction value is changed to " (“0”), the correction value and the weighted average value are mixed to obtain the density data of the pixel of the corrected image, so that the noise component of the flat part of the original image or the part where the density data is smoothly changed is the pixel of interest. The weighted average of the density data of a plurality of pixels around the pixel is averaged and reduced.

【0024】また、注目画素付近のコントラスト量が中
間値の場合には、そのコントラスト量の値に応じた混合
比率で修正値と荷重平均値とが混合されるので、自然な
階調変化を損なわずに画像を修正することができ、トー
ンジャンプなどを発生させることもない。
When the contrast amount in the vicinity of the pixel of interest is an intermediate value, the correction value and the weighted average value are mixed at a mixing ratio according to the value of the contrast amount, so that a natural gradation change is impaired. The image can be corrected without causing any tone jump or the like.

【0025】[0025]

【0026】 請求項に記載の発明に係る画像修正装
置は、上記請求項1に記載の発明に係る画像修正方法を
好適に実施するためのものでその作用は以下のとおりで
ある。
The image correction apparatus according to the second aspect of the present invention is for suitably implementing the image correction method according to the first aspect of the invention, and its operation is as follows.

【0027】コントラスト量算出手段は、原画像記憶手
段に記憶されている原画像の必要な画素の濃度データを
用いて、原画像の注目画素付近のコントラスト量を算出
し、混合比率決定手段は、算出されたコントラスト量の
値が大きくなるに従って修正値の混合比率分を大きく
し、コントラスト量の値が小さくなるに従って荷重平均
値の混合比率分を大きくするように、コントラスト量の
値に応じて修正値と荷重平均値との混合比率を決める。
一方で、修正値抽出手段は、原画像記憶手段に記憶され
ている原画像の注目画素の濃度データと隣接画素群を構
成する各画素の濃度データとを用いて修正値を抽出し、
荷重平均値算出手段は、原画像記憶手段に記憶されてい
る原画像の注目画素の濃度データと周辺画素群を構成す
る各画素の濃度データとを用いてそれら画素の濃度デー
タの荷重平均値を算出する。そして、混合手段は、決定
された混合比率で修正値と荷重平均値とを混合した結果
を、注目画素に対する修正画像の画素の濃度データとし
て修正画像記憶手段に記憶する。制御手段は、原画像の
各画素を順次注目画素として修正画像を得るように各手
段を制御する。
The contrast amount calculation means calculates the contrast amount in the vicinity of the target pixel of the original image using the density data of necessary pixels of the original image stored in the original image storage means, and the mixture ratio determination means, Corrected according to the value of the contrast amount so that the mixed ratio of the correction value increases as the value of the calculated contrast amount increases, and the mixing ratio of the weighted average value increases as the value of the contrast amount decreases. Determine the mixing ratio of the value and the weighted average.
On the other hand, the correction value extraction means extracts the correction value using the density data of the target pixel of the original image stored in the original image storage means and the density data of each pixel forming the adjacent pixel group,
The weighted average value calculation means uses the density data of the target pixel of the original image stored in the original image storage means and the density data of each pixel forming the peripheral pixel group to calculate the weighted average value of the density data of those pixels. calculate. Then, the mixing unit stores the result of mixing the correction value and the weighted average value at the determined mixing ratio in the correction image storage unit as the density data of the pixel of the correction image with respect to the target pixel. The control unit controls each unit so that each pixel of the original image is sequentially set as a target pixel to obtain a corrected image.

【0028】[0028]

【0029】請求項に記載の発明によれば、記憶媒体
に記録されたプログラムをコンピュータに読み込ませる
ことにより、そのコンピュータが請求項に記載の発明
の方法による画像修正処理を実行する。
According to the third aspect of the present invention, by causing the computer to read the program recorded in the storage medium, the computer executes the image correction processing by the method of the first aspect of the present invention.

【0030】[0030]

【発明の実施の形態】以下、図面を参照して本発明の実
施の形態を説明する。図1は本発明に係る画像修正装置
をコンピュータシステムで構成した場合の装置構成の一
例を示すブロック図である。
BEST MODE FOR CARRYING OUT THE INVENTION Embodiments of the present invention will be described below with reference to the drawings. FIG. 1 is a block diagram showing an example of the apparatus configuration when the image correction apparatus according to the present invention is configured by a computer system.

【0031】図1の構成では、デジタルの原画像を修正
して修正画像を得る画像修正処理を実行するCPU10
が、バスライン20を介してRAMなどで構成される内
部メモリ30に接続されている。この内部メモリ30に
は、画像修正処理を実行する際にプログラムが移植され
るプログラムメモリ31、原画像を記憶する原画像メモ
リ32、修正画像を記憶する修正画像メモリ33、コン
トラスト値/混合比率テーブルを記憶するテーブルメモ
リ34などの各領域がそれぞれ設定されている。また、
CPU10は入出力インターフェイス40を介して、外
部記憶装置用のドライバ41、原画像入力器42、出力
器43、設定器44などと接続されている。
In the configuration of FIG. 1, the CPU 10 which executes the image correction process for correcting the digital original image to obtain the corrected image.
Is connected to the internal memory 30 configured by a RAM or the like via the bus line 20. In this internal memory 30, a program memory 31 into which a program is ported when executing image correction processing, an original image memory 32 for storing an original image, a corrected image memory 33 for storing a corrected image, a contrast value / mixture ratio table. Each area such as a table memory 34 for storing is set. Also,
The CPU 10 is connected via an input / output interface 40 to a driver 41 for an external storage device, an original image input device 42, an output device 43, a setting device 44, and the like.

【0032】ドライバ41には外部記憶装置45が装填
される。この外部記憶装置45には予め作成された画像
修正処理プログラムが保存されている。外部記憶装置4
5は、光磁気ディスク、CD−ROM、フロッピーディ
スク、ハードディスク、磁気テープその他の記憶媒体で
構成される。装置の電源がONされ、本実施例に係る画
像修正処理が起動されると、外部記憶装置45から画像
修正処理プログラムが読み込まれてプログラムメモリ3
1に記憶され、CPU10がその画像修正処理プログラ
ムに従って後述する画像修正処理を実行する。この画像
修正処理プログラムが記憶された外部記憶装置45は、
請求項5、6に記載の発明におけるプログラムを記録し
た記憶媒体に相当する。
An external storage device 45 is loaded in the driver 41. The external storage device 45 stores an image correction processing program created in advance. External storage device 4
Reference numeral 5 comprises a magneto-optical disk, a CD-ROM, a floppy disk, a hard disk, a magnetic tape and other storage media. When the power of the apparatus is turned on and the image correction processing according to the present embodiment is activated, the image correction processing program is read from the external storage device 45 and the program memory 3 is read.
1 and the CPU 10 executes the image correction processing described later according to the image correction processing program. The external storage device 45 in which this image correction processing program is stored is
It corresponds to a storage medium in which the program according to the invention described in claims 5 and 6 is recorded.

【0033】原画像入力器42は、原画像を入力する機
器で、例えば、デジタルカメラや入力スキャナ、特開平
3−16367号公報などに開示されたCCDなどのラ
インセンサを用いた画像取り込み装置などで構成され
る。この原画像入力器42で入力された原画像が原画像
メモリ32に記憶され、その原画像に対して後述する画
像修正処理が施され、得られた修正画像が修正画像メモ
リ33に記憶される。なお、予め入力された原画像を外
部記憶装置に記憶しておき、その外部記憶装置から原画
像を読み込んで原画像メモリ32に記憶して、その原画
像に対して画像修正処理を施すように構成してもよい。
The original image input device 42 is a device for inputting an original image, and is, for example, a digital camera, an input scanner, an image capturing device using a line sensor such as a CCD disclosed in Japanese Patent Laid-Open No. Hei 3-16367. Composed of. The original image input by the original image input device 42 is stored in the original image memory 32, the original image is subjected to image correction processing described later, and the obtained corrected image is stored in the corrected image memory 33. . An original image input in advance is stored in an external storage device, the original image is read from the external storage device, stored in the original image memory 32, and an image correction process is performed on the original image. You may comprise.

【0034】原画像メモリ32は、図2に示すように、
2次元のデジタルの原画像を記憶できるように構成され
ており、修正画像メモリ33は、図3に示すように、2
次元のデジタルの修正画像を記憶できるように構成され
ている。なお、図中のtX 、tY は、原画像及び修正画
像の各画素の座標値を示し、P(tX ,tY )は原画像
を構成する各画素の濃度データ、Q(tX ,tY )は修
正画像を構成する各画素の濃度データを示している。
The original image memory 32, as shown in FIG.
The two-dimensional digital original image is configured to be stored, and the modified image memory 33 stores the two-dimensional digital original image as shown in FIG.
It is configured to store a dimensional digital modified image. Note that t X and t Y in the figure represent coordinate values of each pixel of the original image and the corrected image, P (t X , t Y ) is density data of each pixel constituting the original image, and Q (t X , T Y ) indicates the density data of each pixel forming the corrected image.

【0035】出力器43は、修正画像メモリ33に生成
された修正画像を出力するためのもので、例えば、表示
器や記録用スキャナ、プリンタなどで構成される。な
お、修正画像を外部記憶装置に保存するように構成して
もよい。
The output device 43 is for outputting the corrected image generated in the corrected image memory 33, and is composed of, for example, a display device, a recording scanner, a printer and the like. The modified image may be stored in the external storage device.

【0036】設定器44は、各種の設定や指定、指示な
どを行うためのもので、キーボードやマウス、スイッ
チ、設定用モニタなどで構成されている。
The setting device 44 is for performing various settings, designations, instructions, etc., and is composed of a keyboard, a mouse, a switch, a setting monitor, and the like.

【0037】図4は後述する第1の画像修正処理を実行
するための第1の画像修正装置の機能ブロック図であ
る。コントラスト量算出部51、混合比率決定部52、
修正値抽出部53、荷重平均値算出部54、乗算部5
5、56、加算部57、制御部58は、図1の構成のC
PU10に対応する。なお、複数個のCPU10を備え
て、上記各部51〜58の処理を並行、例えば、コント
ラスト量算出部51の処理及び混合比率決定部52の処
理と、修正値抽出部53の処理と、荷重平均値算出部5
4の処理とを並行して行い、その後、乗算部56の処理
と乗算部57の処理とを並行して実行できるように構成
してもよい。この第1の画像修正装置は、請求項3に記
載の発明に係る画像修正装置に相当する。
FIG. 4 is a functional block diagram of a first image correction device for executing a first image correction process described later. A contrast amount calculation unit 51, a mixture ratio determination unit 52,
Correction value extraction unit 53, weighted average value calculation unit 54, multiplication unit 5
5, 56, the addition unit 57, and the control unit 58 are C in the configuration of FIG.
Corresponds to PU10. In addition, a plurality of CPUs 10 are provided, and the processes of the respective units 51 to 58 are performed in parallel, for example, the process of the contrast amount calculation unit 51, the process of the mixture ratio determination unit 52, the process of the correction value extraction unit 53, and the weighted average. Value calculator 5
4 may be performed in parallel, and thereafter, the processing of the multiplication unit 56 and the processing of the multiplication unit 57 may be performed in parallel. The first image correction device corresponds to the image correction device according to the third aspect of the invention.

【0038】以下、上記構成による第1の画像修正処理
を図5に示すフローチャートを参照して説明する。な
お、この第1の画像修正処理は、請求項1に記載の発明
に係る画像修正方法および請求項5に記載の発明に係る
画像修正処理に対応する。
The first image correction process with the above configuration will be described below with reference to the flowchart shown in FIG. The first image correction process corresponds to the image correction method according to the first aspect of the invention and the image correction process according to the fifth aspect of the invention.

【0039】処理が開始される時点で原画像は原画像メ
モリ32に記憶されているものとし、後述するコントラ
スト値/混合比率テーブルは、例えば予め設定器44か
ら設定されてテーブルメモリ34に記憶されているもの
とする。
It is assumed that the original image is stored in the original image memory 32 at the time when the processing is started, and a contrast value / mixing ratio table, which will be described later, is set in advance by the setting device 44 and stored in the table memory 34. It is assumed that

【0040】図5のステップS1:制御部58は、原画
像の注目画素の座標値tX 、tY それぞれに初期値(処
理を開始する画素の座標値)をセットする。
Step S1 of FIG. 5: The control unit 58 sets initial values (coordinate values of the pixel to start processing) to the coordinate values t X and t Y of the target pixel of the original image.

【0041】図5のステップS2(本発明の(1−1)
の工程に相当):コントラスト量算出部51は、原画像
メモリ32から必要な画素の濃度データを読み出して、
現在の注目画素(原画像の(tX ,tY )の画素)付近
のコントラスト量Ctを、例えば、以下の演算式(1)
〜(10)の任意の式で算出する。
Step S2 of FIG. 5 ((1-1) of the present invention)
(Corresponding to the process of)): The contrast amount calculation unit 51 reads out the density data of necessary pixels from the original image memory 32,
The contrast amount Ct in the vicinity of the current pixel of interest (pixel of (t X , t Y ) of the original image) is calculated, for example, by the following arithmetic expression (1)
Calculate using any formula from ~ (10).

【0042】 Ct=CtU-D … (1) Ct=CtL-R … (2) Ct=CtLU-RD … (3) Ct=CtRU-LD … (4) Ct=(CtU-D +CtL-R )/2 … (5) Ct=(CtLU-RD +CtRU-LD )/2 … (6) Ct=(CtU-D +CtL-R +CtLU-RD +CtRU-LD )/4 … (7) Ct=MAX〔CtU-D ,CtL-R 〕 … (8) Ct=MAX〔CtLU-RD ,CtRU-LD 〕 … (9) Ct=MAX〔CtU-D ,CtL-R ,CtLU-RD ,CtRU-LD 〕 … (10) なお、MAX〔A,B,…〕は、A,B,…から最大値
を抽出する関数である。
Ct = Ct UD (1) Ct = Ct LR (2) Ct = Ct LU-RD (3) Ct = Ct RU-LD (4) Ct = (Ct UD + Ct LR ) / 2 (5) Ct = (Ct LU-RD + Ct RU-LD ) / 2 (6) Ct = (Ct UD + Ct LR + Ct LU-RD + Ct RU-LD ) / 4 (7) Ct = MAX [Ct UD , Ct LR ] (8) Ct = MAX [Ct LU-RD , Ct RU-LD ] (9) Ct = MAX [Ct UD , Ct LR , Ct LU-RD , Ct RU-LD ] (10) , MAX [A, B, ...] Is a function for extracting the maximum value from A, B ,.

【0043】また、CtU-D は注目画素付近の上−下方
向のコントラスト量、CtL-R 、CtLU-RD 、Ct
RU-LD は注目画素付近の左−右方向、左上−右下方向、
右上−左下方向のコントラスト量であって以下のように
求める。
Ct UD is the amount of contrast in the up-down direction near the pixel of interest, Ct LR , Ct LU-RD , Ct.
RU-LD is in the left-right direction near the pixel of interest, upper left-lower right direction,
It is the contrast amount in the upper right-lower left direction and is calculated as follows.

【0044】CtU-D =ABS {(〔上近傍領域AU内の
全画素の濃度データの合計〕/〔上近傍領域AU内の画
素数〕)−(〔下近傍領域AD内の全画素の濃度データ
の合計〕/〔下近傍領域AD内の画素数〕)} CtL-R =ABS {(〔左近傍領域AL内の全画素の濃度
データの合計〕/〔左近傍領域AL内の画素数〕)−
(〔右近傍領域AR内の全画素の濃度データの合計〕/
〔右近傍領域AR内の画素数〕)} CtLU-RD =ABS {(〔左上近傍領域ALU内の全画素
の濃度データの合計〕/〔左上近傍領域ALU内の画素
数〕)−(〔右下近傍領域ARD内の全画素の濃度デー
タの合計〕/〔右下近傍領域ARD内の画素数〕)} CtRU-LD =ABS {(〔右上近傍領域ARU内の全画素
の濃度データの合計〕/〔右上近傍領域ARU内の画素
数〕)−(〔左下近傍領域ALD内の全画素の濃度デー
タの合計〕/〔左下近傍領域ALD内の画素数〕)} なお、ABS { }は、絶対値である。
Ct UD = ABS {([sum of density data of all pixels in upper neighborhood area AU] / [number of pixels in upper neighborhood area AU])-([density data of all pixels in lower neighborhood area AD] Of total] / [the number of pixels in the lower neighborhood area AD])} Ct LR = ABS {([total of density data of all pixels in the left neighborhood area AL] / [number of pixels in the left neighborhood area AL])-
([Sum of density data of all pixels in right neighborhood area AR] /
[Number of pixels in right neighboring area AR])} Ct LU-RD = ABS {([sum of density data of all pixels in upper left neighboring area ALU] / [number of pixels in upper left neighboring area ALU])-([ Sum of density data of all pixels in lower right neighborhood area ARD] / [number of pixels in lower right neighborhood area ARD]) Ct RU-LD = ABS {([of density data of all pixels in upper right neighborhood area ARU] Total] / [number of pixels in upper right neighborhood area ARU])-([sum of density data of all pixels in lower left neighborhood area ALD] / [number of pixels in lower left neighborhood area ALD])} where ABS {} is , Absolute value.

【0045】各近傍領域は、例えば、図6に示すように
設定される。図6(a)〜(d)は上近傍領域AUの設
定例を示しているが、右、下、左の各近傍領域AR、A
D、ALは、図6(a)〜(d)の上近傍領域AUを注
目画素APの中心CPを回転軸として時計周りに90
°、180°、270°回転させた領域である。また、
図6(e)〜(h)は左上近傍領域ALUの設定例を示
しているが、右上、右下、左下の各近傍領域ARU、A
RD、ALDは、図6(e)〜(h)の左上近傍領域A
LUを注目画素APの中心CPを回転軸として時計周り
に90°、180°、270°回転させた領域である。
Each neighboring area is set, for example, as shown in FIG. 6A to 6D show setting examples of the upper neighborhood area AU, the right, bottom, and left neighborhood areas AR and A are shown.
D and AL are 90 degrees clockwise in the upper neighborhood area AU of FIGS. 6A to 6D with the center CP of the target pixel AP as a rotation axis.
It is a region rotated by 180 °, 180 °, 270 °. Also,
6E to 6H show setting examples of the upper left neighborhood area ALU, the upper right neighborhood, the lower right neighborhood, and the lower left neighborhood neighborhood ARU, A
RD and ALD are the upper left neighborhood area A in FIGS. 6 (e) to 6 (h).
LU is a region rotated 90 °, 180 °, and 270 ° clockwise around the center CP of the pixel of interest AP as a rotation axis.

【0046】図6に示すように、各近傍領域は注目画素
APの周辺領域(周辺の画素)に設定してもよいし、注
目画素APとその周辺の画素を含んで設定してもよい。
なお、上−下、左−右、左上−右下、右上−左下の各対
の近傍領域はそれぞれ対称形となるように設定すること
が好ましく、各対の近傍領域はそれぞれ同数の画素を含
むように設定するのが好ましい。また、注目画素APの
中心CPからの各近傍領域の外側への広がりを規定する
距離LKは原画像のボケの程度に応じて、原画像のボケ
程度が大きくなるに従ってLKを長くとり、各近傍領域
の面積(近傍領域に含まれる画素数)は、原画像内のノ
イズの含有程度に応じて、原画像内のノイズの含有程度
が多くなるに従って各近傍領域の面積を広くとるように
各近傍領域を設定する。
As shown in FIG. 6, each neighboring area may be set in the peripheral area (peripheral pixel) of the target pixel AP, or may be set including the target pixel AP and its peripheral pixels.
In addition, it is preferable to set the neighboring regions of each pair of top-bottom, left-right, upper left-lower right, and upper right-lower left to be symmetrical, and each neighboring region of each pair includes the same number of pixels. It is preferable to set as follows. Further, the distance LK that defines the outward spread of each neighborhood area from the center CP of the pixel of interest AP depends on the extent of blurring of the original image, and as the extent of blurring of the original image increases, the distance LK becomes longer, and each neighborhood is larger. The area of the area (the number of pixels included in the neighborhood area) depends on the degree of noise contained in the original image, so that the area of each neighborhood area becomes wider as the extent of noise contained in the original image increases. Set the area.

【0047】図5のステップS3(本発明の(1−2)
の工程に相当):混合比率決定部52は、テーブルメモ
リ34に記憶されているコントラスト値/混合比率テー
ブルを参照して、修正値(CNとする)と荷重平均値
(HNとする)との混合比率〔km:(1−km)〕
を、ステップS3で算出したコントラスト量Ctの値が
大きくなるに従って修正値CNの混合比率分kmを大き
くし、コントラスト量Ctの値が小さくなるに従って荷
重平均値HNの混合比率分(1−km)を大きくするよ
うに、コントラスト量Ctの値に応じて決める。なお、
修正値CNと荷重平均値HNの詳細は後述する。
Step S3 of FIG. 5 ((1-2) of the present invention)
The mixing ratio determination unit 52 refers to the contrast value / mixing ratio table stored in the table memory 34, and sets the correction value (CN) and the weighted average value (HN). Mixing ratio [km: (1-km)]
Is increased with an increase in the contrast amount Ct calculated in step S3, and is increased with a decrease in the contrast amount Ct as a mixture ratio (1-km) of the weighted average value HN. Is determined according to the value of the contrast amount Ct. In addition,
Details of the correction value CN and the weighted average value HN will be described later.

【0048】コントラスト値/混合比率テーブルは、例
えば、図7に示すコントラスト量Ctの値とkmとの関
係をテーブルにしたものである。図7(a)〜(c)で
は、コントラスト量Ctの値がかなり小さい場合(図で
はCt1以下の場合)はノイズによるコントラストとみ
なしてkmをできるだけ小さく(図7(c)では「0.
0」)し、コントラスト量Ctの値が所定値(図ではC
t2)を越える場合はエッジによるコントラストとみな
してkmを最大値(1.0)にしている。上記Ct1、
Ct2は予め実験的に求めておけばよい。なお、図7
(b)のように混合比率を決めれば、図7(a)のよう
に混合比率を決めるよりも滑らかに画像修正することが
できる。また、図7(d)のようにkmを最大でもkm
1(km1<1.0であって、例えば、0.5)に抑え
ることで、自然画像などを修正した場合、修正画像が不
自然になるのを抑制できる。なお、図中のCtMAX はコ
ントラスト量Ctの最大値である。修正値CNと荷重平
均値HNとの混合比率を、コントラスト量Ctの値が大
きくなるに従って修正値CNの混合比率分を大きくし、
コントラスト量Ctの値が小さくなるに従って荷重平均
値HNの混合比率分を大きくするように、コントラスト
量Ctの値に応じて決めるためには、図7(a)〜
(e)の各グラフに示すようなコントラスト量Ctの値
とkmとの関係以外のグラフに従ってコントラスト量C
tの値に応じて混合比率を決めてもよい。
The contrast value / mixing ratio table is, for example, a table showing the relationship between the value of the contrast amount Ct and km shown in FIG. In FIGS. 7A to 7C, when the value of the contrast amount Ct is considerably small (Ct1 or less in the figure), it is regarded as the contrast due to noise, and km is as small as possible (“0.
0 ”), and the value of the contrast amount Ct is a predetermined value (C in the figure
When t2) is exceeded, it is regarded as the contrast due to the edge, and km is set to the maximum value (1.0). Ct1, above
Ct2 may be experimentally obtained in advance. Note that FIG.
If the mixing ratio is determined as shown in (b), the image can be corrected more smoothly than the mixing ratio is determined as shown in FIG. 7 (a). Moreover, as shown in FIG. 7D, the maximum km is km.
By suppressing the value to 1 (km1 <1.0, for example, 0.5), it is possible to prevent the corrected image from becoming unnatural when the natural image or the like is corrected. Note that Ct MAX in the figure is the maximum value of the contrast amount Ct. The mixing ratio of the correction value CN and the weighted average value HN is increased by the mixing ratio of the correction value CN as the value of the contrast amount Ct increases.
In order to increase the mixing ratio of the weighted average value HN as the value of the contrast amount Ct becomes smaller in accordance with the value of the contrast amount Ct, the values shown in FIG.
The contrast amount C according to the graphs other than the relationship between the value of the contrast amount Ct and km as shown in each graph of (e)
The mixing ratio may be determined according to the value of t.

【0049】図5のステップS4:修正値抽出部53
は、現在の注目画素に隣接する隣設画素群を構成する各
画素の濃度データのうち、現在の注目画素の濃度データ
に最も近い濃度データ(修正値CN)を抽出する。
Step S4 of FIG. 5: Correction value extraction unit 53
Extracts the density data (correction value CN) closest to the current density data of the target pixel from the density data of each pixel forming the adjacent pixel group adjacent to the current target pixel.

【0050】図8(a)に示すように、注目画素APに
対して左上、上、右上、左、右、左下、下、右下の8個
の隣接画素NPLU、NPU 、NPRU、NPL 、NPR
NP LD、NPD 、NPRDから、例えば、図8(b)に示
すように適宜の位置の複数画素を設定してこれら画素を
隣接画素群NPGとする。そして、設定した隣接画素群
NPGを構成する各画素の濃度データ(図8(c)参
照)のうち、注目画素APの濃度データ(P(tX ,t
Y ))に最も近い濃度データを修正値CNとして抽出す
る。例えば、隣接画素群をNPG={NPL ,NPR
と設定した場合、ABS {P(tX ,tY )−P(tX
1,tY )}とABS {P(tX ,tY )−P(tX
1,tY )}との大小を比較し、前者が小さい場合はP
(tX −1,tY )を修正値CNとし、後者が小さい場
合はP(tX +1,tY )を修正値CNとする。
As shown in FIG. 8A, the pixel of interest AP is
On the other hand, upper left, upper, upper right, left, right, lower left, lower, lower right 8
Adjacent pixel NPLU, NPU, NPRU, NPL, NPR,
NP LD, NPD, NPRDFrom, for example, as shown in FIG.
Set multiple pixels at appropriate positions so that these pixels
Adjacent pixel group NPG. Then, the set adjacent pixel group
Density data of each pixel forming the NPG (see FIG. 8 (c))
Of the density data (P (tX, T
Y)) The density data closest to
It For example, if the adjacent pixel group is NPG = {NPL, NPR}
If set to ABS {P (tX, TY) -P (tX
1, tY)} And ABS {P (tX, TY) -P (tX+
1, tY)} Is compared with the size, and if the former is small, P
(TX-1, tY) Is a modified value CN, and the latter is small
If P (tX+1, tY) Is the correction value CN.

【0051】なお、以下の3形態で隣設画素群を構成す
る各画素の濃度データ内に、注目画素の濃度データに対
して同じ近さの濃度データが複数個存在する場合があ
る。第1の形態は注目画素の濃度データよりも大きい2
つ以上の濃度データが注目画素の濃度データに対して同
じ近さである場合であり、第2の形態は、逆に注目画素
の濃度データよりも小さい2つ以上の濃度データが注目
画素の濃度データに対して同じ近さである場合である。
そして、第3の形態は注目画素の濃度データよりも大き
い濃度データと小さい濃度データとが注目画素の濃度デ
ータに対して同じ近さである場合である。第1、第2の
形態においては、注目画素の濃度データに対して同じ近
さの2つ以上の濃度データの値が全て同じであるので、
その濃度データを修正値CNとすればよい。一方、第3
の形態においては、注目画素の濃度データを挟んで大小
2種類の濃度データが注目画素の濃度データに対して同
じ近さであるので、大きい方の濃度データを選択するか
小さい方の濃度データを選択するかを予め決めておく
か、ランダム関数などを用いて各処理ごとにランダムに
選択する。
There may be a plurality of density data having the same proximity to the density data of the target pixel in the density data of each pixel forming the adjacent pixel group in the following three forms. The first form is larger than the density data of the pixel of interest 2
In the second mode, two or more density data smaller than the density data of the pixel of interest are the density of the pixel of interest. This is the case when they are the same close to the data.
The third mode is a case in which the density data larger than the density data of the pixel of interest and the density data smaller than the density data of the pixel of interest have the same proximity to the density data of the pixel of interest. In the first and second modes, since the values of two or more density data that have the same proximity to the density data of the pixel of interest are all the same,
The density data may be used as the correction value CN. On the other hand, the third
In the above form, since the density data of two types, large and small, are close to the density data of the pixel of interest across the density data of the pixel of interest, the density data of the larger one is selected or the density data of the smaller one is selected. Whether to select is determined in advance, or a random function or the like is used to randomly select each process.

【0052】図5のステップS5:荷重平均値算出部5
4は、現在の注目画素の濃度データ(P(tX
Y ))と、現在の注目画素の周囲の周辺画素群を構成
する各画素の濃度データとの荷重平均値HNを算出す
る。
Step S5 of FIG. 5: Weighted average value calculator 5
4 is the density data (P (t X ,
t Y )) and the weighted average value HN of the density data of each pixel forming the peripheral pixel group around the current target pixel are calculated.

【0053】例えば、図9(a)に示すように、注目画
素APを中心として3×3画素の範囲を対象とした場合
には、上記隣接画素群と同様に、注目画素APに隣接す
る8画素(斜線で示す画素)から適宜の位置の複数画素
を設定してこれら画素を周辺画素群とする。なお、周辺
画素群の画素は、隣接画素群の画素と同じ位置の画素を
選択してもよいし、異なる位置の画素を選択してもよ
い。また、上記隣接画素群は対象となる画素を注目画素
に隣接する8画素に限定しているが、この周辺画素群の
場合は、さらにその外側の画素、例えば、図9(b)に
示すように、注目画素APを中心として5×5画素の範
囲を対象として、注目画素APの周囲の24画素(斜線
で示す画素)から適宜の位置の複数画素を設定してこれ
ら画素を周辺画素群としてもよい。
For example, as shown in FIG. 9A, in the case of targeting a range of 3 × 3 pixels centering on the pixel of interest AP, 8 adjacent to the pixel of interest AP as in the above adjacent pixel group. A plurality of pixels at appropriate positions are set from the pixels (pixels indicated by diagonal lines), and these pixels are set as a peripheral pixel group. As the pixels of the peripheral pixel group, pixels at the same position as the pixels of the adjacent pixel group may be selected, or pixels at different positions may be selected. Further, although the target pixel of the adjacent pixel group is limited to eight pixels adjacent to the target pixel, in the case of this peripheral pixel group, pixels further outside thereof, for example, as shown in FIG. 9B. In addition, a plurality of pixels at appropriate positions are set from the 24 pixels (pixels indicated by diagonal lines) around the pixel of interest AP in the range of 5 × 5 pixels around the pixel of interest AP, and these pixels are set as a peripheral pixel group. Good.

【0054】これら画素の荷重平均は、荷重平均計算に
用いる各画素の荷重を全て同じ(1/〔荷重平均計算に
用いる画素の画素数〕)にして行ってもよいし、注目画
素の荷重を他の画素の荷重よりも大きくして行ってもよ
い。例えば、周辺画素群を{NPL ,NPR }(図8参
照)と設定したとき、荷重平均値HNは以下のように算
出する。
The weighted average of these pixels may be performed by setting the weights of the respective pixels used for the weighted average calculation to be the same (1 / [the number of pixels of the pixels used for the weighted average calculation]) or the weighted pixel of interest. It may be performed by making it larger than the weight of other pixels. For example, when the peripheral pixel group is set to {NP L , NP R } (see FIG. 8), the weighted average value HN is calculated as follows.

【0055】 HN=(1/3)×P(tX −1,tY ) +(1/3)×P(tX ,tY ) +(1/3)×P(tX +1,tY ) … (11) あるいは、 HN=(1/4)×P(tX −1,tY ) +(2/4)×P(tX ,tY ) +(1/4)×P(tX +1,tY ) … (12)HN = (1/3) × P (t X− 1, t Y ) + (1/3) × P (t X , t Y ) + (1/3) × P (t X +1, t Y) ... (11) or, HN = (1/4) × P (t X -1, t Y) + (2/4) × P (t X, t Y) + (1/4) × P ( t X +1, t Y ) (12)

【0056】図5のステップS6(本発明の(1−3)
の工程に相当):乗算部55、56、加算部57は、上
記ステップS4で抽出した修正値CNと上記ステップS
5で算出した荷重平均値HNとを上記ステップS3で決
めた混合比率で混合し、その結果をQ(tX ,tY )と
し、修正画像メモリ33に記憶する。式で表すと以下の
ようになる。 Q(tX ,tY )=km×CN+(1−km)×HN
Step S6 of FIG. 5 ((1-3) of the present invention)
(Corresponding to the process of step S): The multiplication units 55 and 56 and the addition unit 57 and the correction value CN extracted in step S4 and step S4.
The weighted average value HN calculated in step 5 is mixed at the mixing ratio determined in step S3, and the result is stored as Q (t X , t Y ) in the corrected image memory 33. The formula is as follows. Q (t X , t Y ) = km × CN + (1-km) × HN

【0057】図5のステップS7では、制御部58が画
像修正処理の終了を判定し、終了していなければ、ステ
ップS8でtX 、tY を次の注目画素の座標値にしてか
らステップS2に戻り、上記ステップS2〜S8の処理
を画像修正処理が終了するまで繰り返して各Q(tX
Y )を順次求めていき、原画像を修正した修正画像を
生成していく。
In step S7 of FIG. 5, the control unit 58 determines the end of the image correction process, and if not, sets t X and t Y to the coordinate values of the next target pixel in step S8, and then proceeds to step S2. And the steps S2 to S8 are repeated until the image correction process is completed, and each Q (t X ,
t Y ) is sequentially obtained, and a corrected image obtained by correcting the original image is generated.

【0058】なお、ステップS8の画像修正処理の終了
は、原画像OGの全画素を注目画素としたか否かで判定
するが、例えば、注目画素付近のコントラスト量を算出
するための各近傍領域や隣接画素群、周辺画素群の設定
の仕方によっては、図10の斜線で示すように原画像O
Gの外周部の各画素を注目画素として画像修正できない
場合があり、このような場合には、斜線の内側の各画素
を処理範囲としてこれら処理範囲内の全画素を注目画素
としたか否かでステップS8の画像修正処理の終了を判
定する。
The end of the image correction processing in step S8 is determined by whether or not all the pixels of the original image OG have been set as the target pixel. For example, each neighboring area for calculating the contrast amount near the target pixel is determined. Depending on the setting method of the pixel group, the adjacent pixel group, and the peripheral pixel group, the original image O
In some cases, it may not be possible to correct the image by using each pixel in the outer peripheral portion of G as the target pixel. In such a case, it is determined whether each pixel inside the diagonal line is the processing range and all the pixels within these processing ranges are the target pixels. Then, it is determined whether the image correction processing in step S8 is completed.

【0059】 図15の原画像を以下の処理条件で上記
第1の画像修正処理により画像修正すると、図11に示
すような結果となる。
When the original image of FIG. 15 is image-corrected by the first image correction process under the following processing conditions, the result shown in FIG. 11 is obtained.

【0060】<処理条件> (A) 注目画素付近のコントラスト量は上記(2)式で求
め、左近傍領域は注目画素の左の1画素、右近傍領域は
注目画素の右の1画素に設定する。 (B) 混合比率は図7(c)に基づき決める。ただし、C
t1=0.10、Ct2=0.50とする。 (C) 隣接画素群および周辺画素群は、注目画素の左側の
1画素と右側の1画素の合計2画素に設定する。 (D) 荷重平均値HNは、上記(11)式で算出する。
<Processing Condition> (A) The contrast amount near the target pixel is obtained by the above equation (2), and the left neighboring area is set to one pixel on the left side of the target pixel and the right neighboring area is set to one pixel on the right side of the target pixel. To do. (B) The mixing ratio is determined based on Fig. 7 (c). However, C
Let t1 = 0.10 and Ct2 = 0.50. (C) The adjacent pixel group and the peripheral pixel group are set to a total of two pixels, one pixel on the left side of the target pixel and one pixel on the right side. (D) The weighted average value HN is calculated by the above equation (11).

【0061】なお、図11(a)は、各画素を注目画素
としたときのコントラスト量Ctの算出結果を示し、図
11(b)〜(d)に処理結果を示している。また、図
11は、(tX1,tY )の左側の画素の濃度データを
「0.30」、(tX8,tY )の右側の画素の濃度デー
タを「0.80」として計算している。
FIG. 11A shows the calculation result of the contrast amount Ct when each pixel is the target pixel, and FIGS. 11B to 11D show the processing results. In addition, in FIG. 11, the density data of the pixel on the left side of (t X1 , t Y ) is calculated as “0.30”, and the density data of the pixel on the right side of (t X8 , t Y ) is calculated as “0.80”. ing.

【0062】図11より明らかなように、画像取り込み
時にノイズ成分が付加された(tX2,tY )の画素を注
目画素としたときの処理では、混合比率がkm=0.0
となり、(tX2,tY )の画素のノイズ成分は、周辺画
素群を構成する(tX1,tY)、(tX3,tY )の画素
との荷重平均により軽減されている。また、原稿GGの
エッジEGが通過している(tX6,tY )の画素を注目
画素としたときの処理では、混合比率がkm=1.0と
なり、(tX5,tY )の画素の濃度データを修正値CN
として、この修正値CNを修正画像の(tX6,tY )の
画素の濃度データにしているので、(tX6,tY )の画
素の濃度データと(tX7,tY )の画素の濃度データと
の間の濃度変化が急峻となり、原画像OGに比べて原稿
GGのエッジEG部分の尖鋭度が向上している。さら
に、(tX3,tY )や(tX5,tY)、(tX7,tY
を注目画素としたときの処理では、コントラスト値Ct
の値に応じて修正値Cと荷重平均値HNとの混合比率が
決めら、その混合比率で修正値Cと荷重平均値HNと混
合しているので、階調変化が滑らかに修正されている。
As is clear from FIG. 11, in the processing in which the pixel of (t X2 , t Y ) to which the noise component is added at the time of capturing the image is the target pixel, the mixture ratio is km = 0.0.
Therefore, the noise component of the pixel of (t X2 , t Y ) is reduced by the weighted average with the pixels of (t X1 , t Y ) and (t X3 , t Y ) forming the peripheral pixel group. Further, in the processing when the pixel of (t X6 , t Y ) through which the edge EG of the document GG has passed is the target pixel, the mixture ratio becomes km = 1.0, and the pixel of (t X5 , t Y ) Concentration data of the corrected value CN
As the correction value CN is used as the density data of the pixel of (t X6 , t Y ) of the correction image, the density data of the pixel of (t X6 , t Y ) and the pixel of (t X7 , t Y ) The density change with the density data becomes sharp, and the sharpness of the edge EG portion of the original GG is improved as compared with the original image OG. Furthermore, (t X3 , t Y ), (t X5 , t Y ), (t X7 , t Y ).
In the processing when the target pixel is, the contrast value Ct
Since the mixing ratio of the correction value C and the weighted average value HN is determined according to the value of, and the correction value C and the weighted average value HN are mixed at the mixing ratio, the gradation change is smoothly corrected. .

【0063】このように、上記第1の画像修正処理によ
れば、注目画素付近のコントラスト量Ctの値に応じて
修正値CNと荷重平均値HNとの混合比率を変えながら
修正画像の各画素の濃度データQ(tX ,tY )を求め
ているので、1回の修正処理により原画像OGのノイズ
成分を軽減できるとともに、エッジの尖鋭度を向上させ
ることができる。
As described above, according to the first image correction processing, each pixel of the corrected image is changed while changing the mixture ratio of the correction value CN and the weighted average value HN according to the value of the contrast amount Ct near the target pixel. Since the density data Q (t X , t Y ) of is obtained, the noise component of the original image OG can be reduced and the sharpness of the edge can be improved by one correction process.

【0064】また、原稿GGのエッジEGが、例えば、
図12(a)に示すように、濃度の濃い面積が多くなる
ように原画像OGの画素(図では、(tX ,tY )の画
素)を通過する場合、原稿GGのエッジEGの位置は、
原画像OGの(tX ,tY )の画素の中央線CLよりも
右側となるので、原稿GGのエッジEGに対応する修正
画像上のエッジが、原画像OGの(tX −1,tY )の
画素と(tX ,tY )の画素との境界に位置する場合
と、原画像OGの(tX ,tY )の画素と(tX+1,
Y )の画素との境界に位置する場合とを比べると、前
者の方が原稿GGのエッジEGの位置からのズレが大き
くなる。従って、図12(a)の場合、原稿GGのエッ
ジEGに対応する修正画像上のエッジEG’は、図12
(b)に示すように、原画像OGの(tX ,tY )の画
素と(tX +1,tY )の画素との境界に位置する方が
原稿GGのエッジEGの位置に近くなり、原稿GGのエ
ッジEGの位置を修正画像に反映する上でより好まし
い。同様に、図12(c)の場合には、図12(d)に
示すように修正されることが好ましい。ここで、上記第
1の画像修正処理では、修正値CNとして、隣設画素群
を構成する各画素の濃度データのうち、注目画素の濃度
データに最も近い濃度データ、すなわち、注目画素の濃
度の濃淡度に近い方の濃度データを選択しているので、
図12(a)の原画像OGに対する修正結果は図12
(b)になり、また、図12(c)の原画像OGに対す
る修正結果は図12(d)になって、原稿GGのエッジ
EGの位置を反映させてエッジの尖鋭度を強調させるこ
とがきる。
The edge EG of the original GG is, for example,
As shown in FIG. 12A, when passing through the pixels of the original image OG (pixels of (t X , t Y in the figure) so that the area of high density increases, the position of the edge EG of the document GG Is
Since it is on the right side of the center line CL of the pixel (t X , t Y ) of the original image OG, the edge on the corrected image corresponding to the edge EG of the original GG is (t X -1, t of the original image OG. pixel and (t X of Y), t Y) and when located at the boundary between the pixels of the original image OG of (t X, the pixel of t Y) (t X +1,
Compared with the case of being located at the boundary with the pixel of (t Y ), the former has a larger deviation from the position of the edge EG of the document GG. Therefore, in the case of FIG. 12A, the edge EG ′ on the corrected image corresponding to the edge EG of the original GG is
As shown in (b), the one located at the boundary between the (t X , t Y ) pixel and the (t X +1, t Y ) pixel of the original image OG is closer to the position of the edge EG of the original GG. It is more preferable to reflect the position of the edge EG of the document GG in the corrected image. Similarly, in the case of FIG. 12 (c), it is preferable to modify as shown in FIG. 12 (d). Here, in the first image correction process, as the correction value CN, the density data closest to the density data of the target pixel among the density data of each pixel forming the adjacent pixel group, that is, the density of the target pixel Since the density data closer to the intensity is selected,
The correction result for the original image OG in FIG.
12B, and the correction result for the original image OG in FIG. 12C is shown in FIG. 12D, and the sharpness of the edge can be emphasized by reflecting the position of the edge EG of the document GG. Wear.

【0065】なお、上記第1の画像修正処理において、
ステップS2、S3の処理と、ステップS4の処理と、
ステップS5の処理を並行して行ってもよい。
In the first image correction process,
The processing of steps S2 and S3, the processing of step S4,
The processing of step S5 but it may also be performed in parallel.

【0066】 また、混合比率として、kmが1.0ま
たは0.0を採り得る場合には、以下のように処理して
もよい。すなわち、ステップS3で混合比率を決めた結
果、0.0<km<1.0となった場合には、図5のフ
ローチャートと同様に修正値CNを抽出するとともに荷
重平均値HNを算出して、決定した混合比率で修正値C
Nと荷重平均値HNとを混合してQ(t,t)を求
める。一方、ステップS3で混合比率を決めた結果、k
m=1.0となった場合には、修正値CNと荷重平均値
HNとの混合演算は実質的にQ(t,t)=CNと
なり、この演算に荷重平均値HNを使用しないので、こ
の場合には、荷重平均値HNの算出を行わず、修正値C
Nの抽出のみを行い、また、ステップS3で混合比率を
決めた結果、km=0.0となった場合には、修正値C
Nと荷重平均値HNとの混合演算は実質的にQ(t
)=HNとなり、この演算に修正値CNを使用しな
いので、この場合には、修正値CNの抽出を行わず、荷
重平均値HNの算出のみを行うように処理する。画像修
正処理をソフトウエアで実現する場合、上記のように処
理すれば不要な処理を省くことができ、CPU10の負
荷の軽減を図れ、また、1個のCPU10で処理すると
きには処理時間を短縮することができる。
Further, when km can be 1.0 or 0.0 as the mixing ratio, the following processing may be performed. That is, as a result of determining the mixture ratio in step S3, when 0.0 <km <1.0, the correction value CN is extracted and the weighted average value HN is calculated as in the flowchart of FIG. , Correction value C with the determined mixture ratio
By mixing N and the weighted average value HN, Q (t X , t Y ) is obtained. On the other hand, as a result of determining the mixing ratio in step S3, k
When m = 1.0, the mixed calculation of the correction value CN and the weighted average value HN is substantially Q (t X , t Y ) = CN, and the weighted average value HN is not used in this calculation. Therefore, in this case, the weighted average value HN is not calculated, and the correction value C
When only N is extracted and the mixing ratio is determined in step S3 and km becomes 0.0, the correction value C
The mixed operation of N and the weighted average value HN is substantially Q (t X ,
Since t Y ) = HN, and the correction value CN is not used in this calculation, in this case, the correction value CN is not extracted and only the weighted average value HN is calculated. When the image correction processing is implemented by software, unnecessary processing can be omitted by performing the above processing, the load on the CPU 10 can be reduced, and the processing time can be shortened when processing is performed by one CPU 10. it is Ru can.

【0067】[0067]

【0068】[0068]

【0069】[0069]

【0070】[0070]

【0071】[0071]

【0072】[0072]

【0073】[0073]

【0074】[0074]

【0075】[0075]

【0076】[0076]

【0077】[0077]

【0078】[0078]

【0079】なお、例えば、ラインセンサを用いた画像
取り込み装置で各主走査方向の画素列が取り込まれると
すぐにその画素列を画像修正する場合には、原画像メモ
リ32を図13に示すように、主走査方向1画素列分の
濃度データを記憶できるように構成し、画像取り込み装
置で主走査方向1画素列分の濃度データが取り込まれる
たびにその濃度データを図13の原画像メモリ32に記
憶して上記第1の画像修正処理で順次画像修正して修正
画像メモリ33に記憶していくように構成してもよい。
[0079] Incidentally, for example, in the case of image correction to the pixel column as soon as the pixel columns of each main scan direction is captured by the image capture apparatus using a line sensor, an original image memory 32 as shown in FIG. 13 The density data for one pixel column in the main scanning direction can be stored in the original image memory 32 shown in FIG. 13 every time the density data for one pixel column in the main scanning direction is captured by the image capturing device. The image may be stored and sequentially corrected in the first image correction process and stored in the corrected image memory 33.

【0080】[0080]

【発明の効果】以上の説明から明らかなように、請求項
1に記載の発明によれば、原画像の注目画素付近のコン
トラスト量に応じて決めた混合比率で、修正値または最
大/最小選択値と荷重平均値とを混合して画像を修正す
るようにしたので、原画像のエッジ部分の尖鋭度を強調
できるとともに、原画像の平坦部や濃度データが滑らか
に変化している部分ではノイズ成分を軽減し、自然な階
調変化を損なうことなく画像を修正することができ、品
質の良い修正画像を得ることができる。
As is apparent from the above description, the claims
According to the invention described in 1 , the correction value or the maximum / minimum selection value and the weighted average value are mixed at a mixing ratio determined according to the contrast amount in the vicinity of the pixel of interest of the original image to correct the image. Therefore, the sharpness of the edge part of the original image can be emphasized, and the noise component is reduced in the flat part of the original image and the part where the density data changes smoothly, so that the image can be displayed without impairing the natural gradation change. It can be corrected, and a corrected image with good quality can be obtained.

【0081】 請求項に記載の発明によれば、請求項
1に記載の発明に係る画像修正方法を好適に実施できる
装置を実現することができる。
According to the invention of claim 2 ,
It is possible to realize an apparatus capable of suitably implementing the image correction method according to the invention described in item 1 .

【0082】 請求項に記載の発明によれば、請求項
に記載の発明の方法による画像修正処理をコンピュー
タに実行させることができる。
[0082] According to the invention described in claim 3, claim
The computer can be made to execute the image correction processing by the method of the invention described in 1 .

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

【図1】本発明に係る画像修正装置をコンピュータシス
テムで構成した場合の装置構成の一例を示すブロック図
である。
FIG. 1 is a block diagram showing an example of a device configuration when an image correction device according to the present invention is configured by a computer system.

【図2】原画像メモリの構成を示す図である。FIG. 2 is a diagram showing a configuration of an original image memory.

【図3】修正画像メモリの構成を示す図である。FIG. 3 is a diagram showing a configuration of a modified image memory.

【図4】第1の画像修正装置の機能ブロック図である。FIG. 4 is a functional block diagram of a first image correction device.

【図5】第1の画像修正処理の手順を示すフローチャー
トである。
FIG. 5 is a flowchart showing a procedure of first image correction processing.

【図6】コントラスト量を算出するのに用いる近傍領域
を説明するための図である。
FIG. 6 is a diagram for explaining a neighboring area used for calculating a contrast amount.

【図7】コントラスト値/混合比率テーブルの一例を示
す図である。
FIG. 7 is a diagram showing an example of a contrast value / mixing ratio table.

【図8】隣接画素群を説明するための図である。FIG. 8 is a diagram for explaining an adjacent pixel group.

【図9】周辺画素群を説明するための図である。FIG. 9 is a diagram for explaining a peripheral pixel group.

【図10】画像修正処理の処理範囲の一例を示す図であ
る。
FIG. 10 is a diagram illustrating an example of a processing range of image correction processing.

【図11】図15の原画像を第1の画像修正処理で修正
した結果を示す図である。
FIG. 11 is a diagram showing a result of correcting the original image of FIG. 15 by a first image correction process.

【図12】第1の画像修正処理の効果を説明するための
図である。
FIG. 12 is a diagram for explaining the effect of the first image correction processing.

【図13】原画像メモリの変形例の構成を示す図であ
る。
FIG. 13 is a diagram showing a configuration of a modified example of an original image memory.

【図14】画像取り込み時の原稿と撮像デバイスの各画
素との位置関係の一例を示す図である。
FIG. 14 is a diagram showing an example of a positional relationship between a document and each pixel of an image pickup device when an image is captured.

【図15】図14の位置関係で取り込んだ原画像を示す
図である。
15 is a diagram showing an original image captured in a positional relationship of FIG. 14.

【図16】従来方法の問題点を説明するための図であ
る。
FIG. 16 is a diagram for explaining a problem of the conventional method.

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

10:CPU 31:プログラムメモリ 32:原画像メモリ 33:修正画像メモリ 34:テーブルメモリ 45:外部記憶装置 51:コントラスト量算出部 52:混合比率決定部 53:修正値抽出部 54:荷重平均値算出部 55、56:乗算部 57:加算部 58:制御 (t,t):原画像の画素の濃度データ Q(t,t):修正画像の画素の濃度データ Ct:コントラスト量 CN:修正値 HN:荷重平均 km :修正値の混合比率分 (1−km):荷重平均値の混合比率分10: CPU 31: Program memory 32: Original image memory 33: Modified image memory 34: Table memory 45: External storage device 51: Contrast amount calculation unit 52: Mixing ratio determination unit 53: Correction value extraction unit 54: Weighted average value calculation part 55: multiplier 57: adder unit 58: control unit P (t X, t Y) : original image pixel density data Q (t X, t Y) : the pixels in the corrected image density data Ct: contrast Quantity CN: corrected value HN: weighted average value km : mixed value of corrected value (1-km): mixed ratio of weighted average value

───────────────────────────────────────────────────── フロントページの続き (56)参考文献 特開 平7−203193(JP,A) 特開 昭61−157162(JP,A) (58)調査した分野(Int.Cl.7,DB名) H04N 1/40 - 1/409 ─────────────────────────────────────────────────── ─── Continuation of front page (56) Reference JP-A-7-203193 (JP, A) JP-A-61-157162 (JP, A) (58) Fields investigated (Int.Cl. 7 , DB name) H04N 1/40-1/409

Claims (3)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】 デジタルの原画像を修正する画像修正方
法において、 (1−1)原画像の注目画素付近のコントラスト量を算
出する工程と、 (1−2)前記注目画素に隣接する隣設画素群を構成す
る各画素の濃度データのうち、前記注目画素の濃度デー
タに最も近い濃度データ(以下、この濃度データを「修
正値」という)と、前記注目画素の濃度データと前記注
目画素の周囲の周辺画素群を構成する各画素の濃度デー
タとの荷重平均値(以下、この荷重平均値を単に「荷重
平均値」という)との混合比率を、前記コントラスト量
の値が大きくなるに従って前記修正値の混合比率分を大
きくし、前記コントラスト量の値が小さくなるに従って
前記荷重平均値の混合比率分を大きくするように、前記
コントラスト量の値に応じて決める工程と、 (1−3)前記決定された混合比率で前記修正値と前記
荷重平均値とを混合した結果を、前記注目画素に対する
修正画像の画素の濃度データとする工程と、 を備えて原画像の各画素を順次注目画素として原画像を
修正した修正画像を得ることを特徴とする画像修正方
法。
1. An image correction method for correcting a digital original image, comprising: (1-1) calculating a contrast amount in the vicinity of a pixel of interest of the original image; and (1-2) adjoining the pixel of interest. Of the density data of each pixel forming the pixel group, the density data closest to the density data of the target pixel (hereinafter, this density data is referred to as “correction value”), the density data of the target pixel and the target pixel The mixing ratio of the density data of each pixel forming the surrounding peripheral pixel group and the weighted average value (hereinafter, this weighted average value is simply referred to as “weighted average value”) is set as the contrast amount increases. Increasing the mixing ratio of the correction value and increasing the mixing ratio of the weighted average value as the value of the contrast decreases, a step of determining according to the value of the contrast, (1-3) a step of setting a result of mixing the correction value and the weighted average value at the determined mixing ratio as density data of a pixel of the correction image with respect to the pixel of interest, An image correction method characterized by obtaining a corrected image in which an original image is corrected by sequentially setting pixels as a target pixel.
【請求項2】 デジタルの原画像を修正する画像修正装
置において、 原画像を記憶する原画像記憶手段と、 原画像を修正した修正画像を記憶する修正画像記憶手段
と、 原画像の注目画素付近のコントラスト量を算出するコン
トラスト量算出手段と、 前記注目画素に隣接する隣設画素群を構成する各画素の
濃度データのうち、前記注目画素の濃度データに最も近
い濃度データ(以下、この濃度データを「修正値」とい
う)を抽出する修正値抽出手段と、 前記注目画素の濃度データと前記注目画素の周囲の周辺
画素群を構成する各画素の濃度データとの荷重平均値
(以下、この荷重平均値を単に「荷重平均値」という)
を算出する荷重平均値算出手段と、 前記コントラスト量の値が大きくなるに従って前記修正
値の混合比率分を大きくし、前記コントラスト量の値が
小さくなるに従って前記荷重平均値の混合比率分を大き
くするように、前記コントラスト量の値に応じて前記修
正値と前記荷重平均値との混合比率を決める混合比率決
定手段と、 前記決定された混合比率で前記修正値と前記荷重平均値
とを混合した結果を、前記注目画素に対する修正画像の
画素の濃度データとして前記修正画像記憶手段に記憶す
る混合手段と、 原画像の各画素を順次注目画素として前記修正画像を得
るように制御する制御手段と、 を備えたことを特徴とする画像修正装置。
2. An image correction apparatus for correcting a digital original image, wherein an original image storage means for storing the original image, a corrected image storage means for storing a corrected image obtained by correcting the original image, and a target pixel vicinity of the original image Contrast amount calculating means for calculating the contrast amount of the target pixel, and density data closest to the density data of the target pixel among the density data of each pixel forming the adjacent pixel group adjacent to the target pixel (hereinafter, this density data Is referred to as a "correction value"), and a weighted average value of density data of the pixel of interest and density data of each pixel forming a peripheral pixel group around the pixel of interest (hereinafter, this weight) (The average value is simply called "weighted average value")
And a weighted average value calculating means for calculating a mixture ratio of the correction value as the value of the contrast amount increases, and a mixture ratio of the weighted average value as the value of the contrast amount increases. As described above, a mixing ratio determining unit that determines a mixing ratio of the correction value and the weighted average value according to the value of the contrast amount, and the correction value and the weighted average value are mixed at the determined mixing ratio. Mixing means for storing the result in the corrected image storage means as density data of the pixel of the corrected image with respect to the target pixel; control means for controlling so that each pixel of the original image is sequentially used as the target pixel to obtain the corrected image; An image correction device comprising:
【請求項3】 デジタルの原画像を修正する処理をコン
ピュータに実行させるためのプログラムを記録した記憶
媒体であって、 (1−1)原画像の注目画素付近のコントラスト量を算
出する工程と、 (1−2)前記注目画素に隣接する隣設画素群を構成す
る各画素の濃度データのうち、前記注目画素の濃度デー
タに最も近い濃度データ(以下、この濃度データを「修
正値」という)と、前記注目画素の濃度データと前記注
目画素の周囲の周辺画素群を構成する各画素の濃度デー
タとの荷重平均値(以下、この荷重平均値を単に「荷重
平均値」という)との混合比率を、前記コントラスト量
の値が大きくなるに従って前記修正値の混合比率分を大
きくし、前記コントラスト量の値が小さくなるに従って
前記荷重平均値の混合比率分を大きくするように、前記
コントラスト量の値に応じて決める工程と、 (1−3)前記決定された混合比率で前記修正値と前記
荷重平均値とを混合した結果を、前記注目画素に対する
修正画像の画素の濃度データとする工程と、 を備えて原画像の各画素を順次注目画素として原画像を
修正した修正画像を得る処理をコンピュータに実行させ
るためのプログラムを記録した記憶媒体。
3. A storage medium having a program for causing a computer to execute a process of correcting a digital original image, comprising: (1-1) calculating a contrast amount near a target pixel of the original image; (1-2) Of the density data of each pixel forming the adjacent pixel group adjacent to the target pixel, the density data closest to the density data of the target pixel (hereinafter, this density data is referred to as “correction value”) And a weighted average value (hereinafter, this weighted average value is simply referred to as “weighted average value”) of the density data of the pixel of interest and the density data of each pixel forming a peripheral pixel group around the pixel of interest. The proportion is increased as the value of the contrast amount is increased by the mixing ratio, and is increased as the value of the contrast amount is increased by the mixing ratio of the weighted average value. As described above, (1-3) the result of mixing the correction value and the weighted average value at the determined mixing ratio is used as a result of the pixel of the corrected image for the target pixel. A storage medium in which a program for causing a computer to execute a process of obtaining density data, in which each pixel of the original image is sequentially corrected as a target pixel to obtain a corrected image, is recorded.
JP14766997A 1997-06-05 1997-06-05 Image correction method and apparatus, and storage medium storing program Expired - Fee Related JP3480547B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP14766997A JP3480547B2 (en) 1997-06-05 1997-06-05 Image correction method and apparatus, and storage medium storing program

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP14766997A JP3480547B2 (en) 1997-06-05 1997-06-05 Image correction method and apparatus, and storage medium storing program

Publications (2)

Publication Number Publication Date
JPH10336451A JPH10336451A (en) 1998-12-18
JP3480547B2 true JP3480547B2 (en) 2003-12-22

Family

ID=15435602

Family Applications (1)

Application Number Title Priority Date Filing Date
JP14766997A Expired - Fee Related JP3480547B2 (en) 1997-06-05 1997-06-05 Image correction method and apparatus, and storage medium storing program

Country Status (1)

Country Link
JP (1) JP3480547B2 (en)

Families Citing this family (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US7433084B2 (en) * 2002-07-01 2008-10-07 Xerox Corporation Digital de-screening technique for scanned documents
JP4730121B2 (en) * 2006-02-07 2011-07-20 ソニー株式会社 Image processing apparatus and method, recording medium, and program

Also Published As

Publication number Publication date
JPH10336451A (en) 1998-12-18

Similar Documents

Publication Publication Date Title
US7844127B2 (en) Edge mapping using panchromatic pixels
US8594451B2 (en) Edge mapping incorporating panchromatic pixels
JP4626007B2 (en) Image processing method, machine-readable recording medium storing image processing program, and image processing apparatus
US7792384B2 (en) Image processing apparatus, image processing method, program, and recording medium therefor
EP1395041A2 (en) Colour correction of images
US20020159650A1 (en) Image processing apparatus and recording medium, and image processing apparatus
US20050041116A1 (en) Image processing apparatus and image processing program
US20040184671A1 (en) Image processing device, image processing method, storage medium, and program
JP2004334843A (en) Method of composting image from two or more images
JP3862621B2 (en) Image processing apparatus, image processing method, and program thereof
JP4035688B2 (en) False color removal apparatus, false color removal program, false color removal method, and digital camera
TW200822719A (en) Image processing device, image processing method, and program
JP2000003437A (en) Aberration correcting method, electronic still camera and image processing system
US7697775B2 (en) Image signal processing apparatus and method, and program and recording medium used therewith
JP4686624B2 (en) Information processing apparatus, image processing method, and program
JP3480547B2 (en) Image correction method and apparatus, and storage medium storing program
JP4369030B2 (en) Image correction method and apparatus, and computer-readable recording medium storing image correction program
JPH08255240A (en) Device and method for correcting image
JP2004023737A (en) Image processing apparatus and method thereof
JPH10208038A (en) Picture processing method and device therefor
JP3452460B2 (en) Image reduction method and apparatus, and storage medium storing program
JP2008107981A (en) Image processor and image processing method
JP3318248B2 (en) Image quality improvement device and recording medium
JPH10341334A (en) Image magnification method, device therefor and storage medium recording program
JPH10271340A (en) Image-processing method and device therefor

Legal Events

Date Code Title Description
R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

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

Free format text: PAYMENT UNTIL: 20071010

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20081010

Year of fee payment: 5

LAPS Cancellation because of no payment of annual fees