JP4057662B2 - Image processing apparatus and image processing method - Google Patents

Image processing apparatus and image processing method Download PDF

Info

Publication number
JP4057662B2
JP4057662B2 JP01468396A JP1468396A JP4057662B2 JP 4057662 B2 JP4057662 B2 JP 4057662B2 JP 01468396 A JP01468396 A JP 01468396A JP 1468396 A JP1468396 A JP 1468396A JP 4057662 B2 JP4057662 B2 JP 4057662B2
Authority
JP
Japan
Prior art keywords
representative color
unit
color
output
representative
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
JP01468396A
Other languages
Japanese (ja)
Other versions
JPH09214785A (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 JP01468396A priority Critical patent/JP4057662B2/en
Publication of JPH09214785A publication Critical patent/JPH09214785A/en
Application granted granted Critical
Publication of JP4057662B2 publication Critical patent/JP4057662B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Landscapes

  • Facsimile Image Signal Circuits (AREA)
  • Color Image Communication Systems (AREA)
  • Image Analysis (AREA)

Description

【0001】
【発明の属する技術分野】
この発明は、カラー原稿画像を文字領域と絵柄領域に分離し、各領域に適した画像処理を施す画像処理装置に関する。
【0002】
【従来の技術】
スキャナ等によって読み取られた入力画像あるいはファクシミリ等で送信されてきた入力画像をハードコピーとして再生することが一般的に行われるが、その際に入力画像に文字部・線画部・写真部・網点部等が混在している場合がある。この場合、文字部・線画部などの文字領域に対しては解像度を重視した処理を施し、写真部・網点部などの絵柄領域に対しては階調性を重視した処理を施して再生を行いことにより高画質な再生画像を得ることが可能となる。
【0003】
このような入力画像に含まれる文字領域・絵柄領域に対し、解像度重視の処理または階調性重視の処理のうち適切なものを適用するためには、それに先立って入力画像を文字領域と絵柄領域とに精度良く分離する必要があり(以下、文字領域・絵柄領域の分離のことを像域分離と言う)、この像域分離に関しては種々の提案がなされている。
【0004】
その一例として、画像をある一定の大きさのブロックに分割し、各ブロックごとにそのブロックに含まれる画素の最大濃度と最小濃度を求め、最大濃度と最小濃度の差をあらかじめ決められた閾値と比較し、閾値より大きいブロックは文字領域・小さいブロックは絵柄領域と判定する方法があった。
【0005】
【発明が解決しようとする課題】
ところで、入力画像中の写真などの中間調を含む絵柄領域には濃度差の激しい領域も存在する場合が多い。従って、上記方法を採用した場合には、ブロック内の濃度差のみに基づいて文字ブロックか絵柄ブロックかを判定するため、絵柄ブロックであるにも拘わらず文字ブロックであると誤認し、解像度を重視した処理を誤って適用してしまうことがあり、かかる場合には画質を劣化させてしまうという欠点があった。
【0006】
また、上記方法を含めて従来のほとんどの像域分離技術は、白黒画像を想定したものであり、カラー画像を対象とした像域分離技術として適当な技術はなかった。そこで、白黒画像を対象とした像域分離技術をカラー画像に対応させるために、例えば次のような方法が採られていた。
a.カラー画像の各色成分ごとに像域分離処理を施し、その結果の論理和に基づいて文字領域と絵柄領域を分離する。
b.カラー画像の色空間内における成分を表す情報をL***などの明度成分を持つ情報に変換し、この明度成分に対して像域分離処理を施す。
【0007】
しかしながら、上記方法aは、各色成分ごとの判定結果の論理和をとるため誤判定が多くなるという問題があった。また、上記方法bは、白背景中の明度の高い文字部や、あるいは色背景中で背景と同等の明度を持つ文字を抽出することが困難であるという問題があった。
【0008】
また、従来の像域分離技術は、再生対象たる画像が網点部を含んでいる場合にはさらに別な問題が生じる。すなわち、再生画像が網点部を含んでいる場合には、網点部は絵柄領域と判定されるため、網点部中に存在する文字部に対しても絵柄領域と同じ画像再現処理がなされてしまうのである。
【0009】
本発明は、上記した従来技術の欠点を除くためになされたものであり、白背景中の黒文字のみならず、白背景中の色文字や色背景中の文字を精度良く抽出することができる画像処理装置を提供することを目的とするものである。また、本発明の他の目的は、網点部などの絵柄領域中に存在する文字を精度良く抽出することができる画像処理装置を提供することにある。
【0010】
【課題を解決するための手段】
上記課題を解決するため、請求項1に係る発明は、原稿の入力カラー画像を構成する各画素に対し、複数の代表色のうち当該画素の色に近似した代表色を割当てる代表色割当手段と、前記代表色割当手段によって各画素に割り当てられた代表色に基づき、前記入力カラー画像を各々代表色の異なった複数の像域に区切る境界を検出する境界検出手段とを有することを特徴とする画像処理装置を提供するものである。
【0011】
また、請求項2に係る発明は、画像処理装置が、原稿の入力カラー画像を構成する各画素に対し、複数の代表色のうち当該画素の色に近似した代表色を割当てる代表色割当ステップと、前記代表色割当ステップにおいて各画素に割り当てられた代表色に基づき、前記入力カラー画像を各々代表色の異なった複数の像域に区切る境界を検出する境界検出ステップとを有することを特徴とする画像処理方法を提供するものである。
【0012】
【発明の実施の形態】
以下、本発明を更に理解しやすくするため、実施の形態について説明する。
【0013】
A.第1の実施形態
(1)全体構成
図1は、本発明の第1の実施形態である画像処理装置の構成を示すブロック図である。図1において、画像入力部1は、CCDカメラ等の光量変換素子を使用したイメージスキャナ等により構成されている。この画像入力部1により原稿のカラー画像情報が色別に読み取られ、例えば各色8ビットからなるRGB画像信号(ディジタル信号)に変換されて出力される。このRGB画像信号は、入力階調補正部2によって階調が補正される。色信号変換部3では、このようにして階調補正のなされたRGB画像信号が、他の色信号、例えばL***画像信号に変換される。
【0014】
色信号変換部3から出力されたL***画像信号は色信号変換部4に供給され、色信号変換部4により、他の色信号、例えばYMC画像信号に変換される。そして、墨版生成部5により、YMC画像信号から墨版が生成され、YMC画像信号がこの墨版を含んだYMCK画像信号に変換される。
【0015】
墨版生成部5から出力されるYMCK画像信号は空間フィルタ部6に供給され、各色毎に空間フィルタリング処理が施される。また、空間フィルタ部6には後述の像域分離部9からの領域判定結果が入力され、その領域判定結果に対応して、例えばフィルタリング係数の切り替え等、空間フィルタリング処理の処理内容の切り替えが行われる。この結果、空間フィルタ部6では、文字部・線画部などの文字領域に対応したYMCK画像信号が入力されるときには解像度を重視したフィルタ処理が施され、一方、写真部・網点部などの絵柄領域に対したYMCK画像信号が入力されるときには階調性を重視したフィルタ処理が行われることとなる。
【0016】
空間フィルタリング処理がなされたYMCK画像信号は出力階調補正部7に供給され、各色毎に画像出力階調特性にあうように出力階調補正がなされる。この出力階調補正部7に対しても後述の像域分離部9からの領域判定結果が入力される。出力階調補正部7では、YMCK画像信号に対し、領域判定結果に対応した出力階調補正が施される。
【0017】
画像出力部8には、このようにして出力階調が補正されたYMCK画像信号が供給されると共に、後述する像域分離部9からの領域判定結果が供給される。画像出力部8では、この領域判定結果に対応して、例えばスクリーンなどが切り替えられ、画像が出力される。
【0018】
像域分離部9には、色信号変換部3から出力されるL***画像信号が供給される。この像域分離部9は、L***画像信号によって表された各画素毎に文字部に属するか絵柄部に属するかの領域判定を行う。この領域判定結果は、前述の空間フィルタ部6、出力階調補正部7、および画像出力部8に供給され、前述したように領域判定結果に対応した処理が施される。
【0019】
(2)像域分離部
次に、像域分離部9について説明する。像域分離部9は、図2に示すように、代表色割当部11、変化点抽出部12およびエッジ検出部13により構成されている。前述した色信号変換部3から出力されるL***画像信号は、代表色割当部11に入力される。代表色割当部11では、各画素ごとにその信号値(画素値)に応じて代表色が割当てられる。そして、割り当てられた代表色に対応する番号(以下、代表色番号と言う)が出力される。なお、代表色の割当方法については後述する。
【0020】
代表色割当部11から出力された代表色番号は変化点抽出部12に供給される。変化点抽出部12では、入力される代表色番号から、代表色番号の変化点を抽出する。この変化点の抽出方法についても後述する。
【0021】
エッジ検出部13では、変化点抽出部12で抽出された代表色番号の変化点からエッジ部を検出し、このエッジ部検出結果をエッジ判定信号として出力する。このエッジ部の検出方法についても後述する。本実施形態においては、このエッジ検出部13と上記変化点抽出部12により、L***画像信号によって表された入力画像を各々代表色の異なった複数の像域に区切る境界を検出する境界検出手段が構成されている。
【0022】
▲1▼代表色割当部11
次に、代表色割当部11について説明する。
a.代表色割当部の第1の例
図3は代表色割当部11の第1の例である代表色割当部11aを示すものである。同図に示すように、この代表色割当部11aは、代表色発生部21、距離演算部22および最短距離判定部23により構成されている。
【0023】
代表色発生部21は、例えばRAMまたはROMで構成されたルックアップテーブル(以下、LUTと称する)を有しており、このLUTには複数の代表色の信号値(その代表色を表すL***画像信号の各成分の値)と各代表色に対応した代表色番号が記憶されている。なお、代表色は、複数の固定された代表色でも構わないし、あらかじめ入力された画像から複数の特徴的な色を選び出して代表色としても構わない。複数の固定された代表色の例としては、Y(黄)・M(マゼンタ)・C(シアン)・R(赤)・G(緑)・B(青)・Bk(黒)・W(白)の8色などがある。
【0024】
代表色発生部21には不図示のクロック信号が供給される。そして、このクロック信号に同期し、LUT内に記憶された代表色の信号値と対応する代表色番号が順次読み出され、代表色の信号値は距離演算部22に、代表色番号は最短距離判定部23に供給される。
【0025】
距離演算部22は、代表色発生部21から複数の代表色の信号値を順次受け取り、これらの各代表色の信号値について、前述した色信号変換部3から出力されるL***画像信号との間の距離を演算する。
【0026】
ここで、距離演算部22の詳細構成を図4を参照し説明する。図4において、35−1〜35−3は減算器であり、色信号変換部3から出力されたL***画像信号の各成分と、代表色発生部21から出力された代表色のL***各成分との差を出力する。36−1〜36−3は乗算器であり、減算器35−1〜35−3から出力された各値を各々2乗して出力する。37は加算器であり、乗算器36−1〜36−3から出力された値を合計して出力する。従って加算器37から出力される値は、L***色空間内での入力画像データと代表色データのユークリッド距離の2乗になる。すなわち、入力された画像信号を(L0、a0、b0)、代表色信号を(L1、a1、b1)とすると、下記式(1)の演算が行われ、その値が加算器37から出力される。
【0027】
(L0−L12+(a0−a12+(b0−b12 ・・・(1)
【0028】
この距離演算部22に対しては、上述した通り、複数の代表色の各信号値がクロック信号に同期して順次供給される。この結果、距離演算部22では、各代表色について、色信号変換部3からのL***画像信号に対応した色との間との距離が順次演算され、演算結果が最短距離判定部23に順次供給される。一方、各代表色に対応した距離の演算結果が最短距離判定部23に順次供給されるのと同期し、各代表色の代表色番号が代表色発生部21から最短距離判定部23に供給される。最短距離判定部23では、順次供給される距離の演算結果のうち、最も小さい値(距離の短いもの)を判定し、その距離に対応する代表色番号を選び出し出力する。
【0029】
b.代表色割当部の第2の例
図5は代表色割当部11の第2の例である代表色割当部11bを示すものである。この代表色割当部11bにおいては、複数の代表色の信号値がそれぞれ異なる距離演算部25−1〜25−8に供給される。そして、各距離演算部25−1〜25−8により各代表色とL***画像信号によって表された色との間の距離の演算が並列実行される。これらの各代表色についての距離の演算結果は、最短距離判定部26に供給される。そして、最短距離判定部26により、これらの距離の演算結果の中から最短のものが判定され、その最短距離に対応した代表色の番号が出力される。
【0030】
c.代表色割当部の第3の例
図6は代表色割当部11の第3の例である代表色割当部11cを示すものである。この代表色割当部11cにおいては、色信号変換部3からのL***画像信号の各成分のうちL*成分は比較器27によって閾値th1と比較される。そして、L*成分が閾値th1よりも高いときは白色に対応した代表色番号が比較器27から出力され、低い場合には黒色に対応した代表色番号が出力される。
【0031】
また、色信号変換部3から供給された他のa*成分とb*成分はLUT29に入力され、このLUT29により当該a*成分およびb*成分に対応した色相が判定され、その色相を代表する代表色番号(例えば、Y、M、C、R、G、Bに対応した代表色番号)が出力される。
【0032】
また、画像信号a*およびb*は、それぞれ乗算器30−1,30−2にも入力され、乗算器30−1,30−2によりa*の2乗とb*の2乗が各々演算され、各演算結果が加算器31によって加算される。この結果、加算器31からa*とb*のそれぞれの2乗の和、すなわち、入力画像の彩度の2乗に相当する値が出力される。比較器32においては、この入力画像の彩度の2乗に相当する値が閾値th2と比較され、閾値th2以上の時は入力画像が有彩色であることを示す情報「1」が、閾値th2未満の時は入力画像が無彩色であることを示す情報「0」が出力される。
【0033】
選択器28では、この比較器32からの出力情報に応じて、比較器27の出力またはLUT29の出力のいずれかが選択され、代表色番号として出力される。すなわち、比較器32の出力が「0」のとき(無彩色と判定したとき)は、比較器27の出力である白または黒の代表色番号が出力され、比較器32の出力が「1」のときは彩度が高いと判定されて、LUT29の出力である代表色番号(例えば、Y、M、C、R、G、Bの代表色番号)が出力される。
【0034】
d.代表色割当部の第4の例
図7は代表色割当部11の第4の例である代表色割当部11dを示すものである。上述した第1〜第3の例による代表色割当部11a〜cは、色信号としてL***信号を取扱った。これに対し、図7に示す第4の例による代表色割当部11dは、RGB色信号が入力された場合にその代表色を求めるものである。この代表色割当部11dを像域分離部9内に用いた場合には、図1において入力階調補正部2の出力信号を像域分離部9に直接入力することが可能である。
【0035】
図7において、入力階調補正部2から供給されるR,G,Bの各色信号は比較器33−1〜33−3に供給される。比較器33−1〜33−3では、R,G,Bの各色信号値が閾値th3、th4、th5と各々比較され、各色毎に、閾値未満である場合は「0」、閾値以上である場合は「1」が出力される。このようにして比較器33−1〜33−3から得られる3色分の2値化信号はLUT34に入力される。図8はこのLUT34の記憶内容を例示するものである。上記3色分の2値化信号がこのLUT34に入力されることにより、図8に示す表に従って代表色が選択され、その代表色番号が出力される。
【0036】
例えば、入力階調補正部2から供給されるR,G,Bの各色信号の信号値が(R,G,B)=(200,215,84)であり、閾値th3、th4、th5が全て128であるとすると、比較器33−1〜33−3からはそれぞれ「1」、「1」、「0」が出力される。この結果、LUT34では図8の表により黄色が選択されて、その代表色番号である「3」が出力される。
【0037】
なお、上記第4の例ではRGB信号が入力された場合について説明したが、YMCあるいはYMCK色信号が入力された場合でも同様に代表色を割り当てることが可能である。
【0038】
▲2▼変化点抽出部12
次に、変化点抽出部12について説明する。入力画像は縦横に並んだ多数の画素によって構成されているが、上述した代表色割当部11はこれらの各画素に対し代表色番号を割当てる処理を行うものである。変化点抽出部12は、このようにして求められた各画素の代表色番号に基づき、画像内における画素の代表色の変化点を判定・抽出するものである。本実施形態における変化点抽出部12においては、入力画像を構成する各画素を注目画素として順次選択し、注目画素の代表色番号とその注目画素を中心とした所定範囲内の周辺画素の代表色番号を比較し、代表色番号が等しいか否かを判定することにより代表色番号の変化点の判定・抽出を行う。
【0039】
図9は上記所定の範囲を注目画素を中心とした3×3ウィンドウとする変化点抽出部12の構成例を示すものである。代表色割当部11から順次出力される各画素の代表色番号データは、1ラインメモリ(ラインバッファ)41−1を通過することにより1ライン周期遅延され、次いで1ラインメモリ41−2を通過することによりさらに1ライン周期遅延される。また、代表色割当部11から供給される代表色番号データはラッチ回路42−1により、1ラインメモリ41−1が出力する代表色番号はラッチ回路42−3により、1ラインメモリ41−2が出力する代表色番号はラッチ回路42−5により、各々1画素周期ずつ遅延される。さらにラッチ回路42−1,42−3および42−5が出力する各代表色番号はラッチ回路42−2,42−4および42−6により各々1画素周期ずつ遅延される。
【0040】
以上の構成により、図10(a)に示すような3×3画素からなるブロックの各画素Pa〜Piの代表色番号データが得られる。すなわち、代表色割当部11から現在出力された代表色番号データ、ラッチ回路42−1から出力された代表番号データおよびラッチ回路42−2から出力された代表色番号データは、最新の1ラインを構成する連続した3画素Pa、PbおよびPcの代表色番号データである。また、1ラインメモリ41−1から出力された代表色番号データ、ラッチ回路42−3から出力された代表番号データおよびラッチ回路42−4から出力された代表色番号データは、現在よりも1ラインだけ前のラインを構成する連続した3画素Pd、PeおよびPfの代表色番号データである。これらのうち画素Peがブロックの中心に位置する注目画素である。そして、1ラインメモリ41−2から出力された代表色番号データ、ラッチ回路42−5から出力された代表番号データおよびラッチ回路42−6から出力された代表色番号データが、現在よりも2ラインだけ前のラインを構成する連続した3画素Pg、PhおよびPiの代表色番号データである。
【0041】
そして、各画素Pa〜Piについて、このようにして得られた各々の代表色番号データがブロックの中心の注目画素Peの代表色番号データと一致しているか否かを示す色判定データDa〜Diが生成され、エッジ検出部13に供給される。すなわち、画素Pa〜Pd,Pf〜Piの各代表色番号データと注目画素Peの代表色番号データとが比較器43−1〜43−8によって比較され、各画素Pa〜Pd,Pf〜Piのうち注目画素Peの代表色番号データと一致した代表色番号データを有するものについては色判定データとして「1」が出力され、そうでない画素については色判定データとして「0」が出力される。なお、注目画素Peについては比較をする意味がないので、これに対応する色判定データDeとして「1」がエッジ検出部13に供給される。
【0042】
例えば、ブロックを構成する各画素Pa〜Piの各代表色番号データが図10(b)に示すものであるとすると、これらの各代表色データと注目画素Peの代表色番号との比較により得られる各色判定データDa〜Diは図10(c)に示すものとなる。この例では注目画素Peの代表色番号「6」であるため、3×3ウィンドウ内で代表色番号「6」をもつ画素については色判定データが「1」となり、「6」以外の代表色番号をもった画素については色判定データが「0」となる。このようにして得られた色判定データDa〜Diがエッジ検出部13に供給される。
【0043】
▲3▼エッジ検出部
以上のように変化点抽出部12により注目画素を中心とした所定範囲内の画素に対応した色判定データが得られる。エッジ検出部13では、この所定範囲内の画素に対応した色判定データに基づき、注目画素が文字領域・絵画領域の境界の一部であるエッジを構成しているか否かを判定する。このエッジ検出部13の構成例を以下に説明する。
【0044】
a.エッジ検出部13の第1の例
この第1の例では、パターンマッチングにより注目画素がエッジを構成しているか否かを判定する。すなわち、このエッジ検出部13は、変化点抽出部12から出力された3×3画素分の色判定データDa〜Diのパターンと、あらかじめ登録された複数のパターンの各々と比較し、いずれかのパターンと一致していれば注目画素がエッジ部を構成していると判定し、エッジ判定信号として「1」を出力する。一方、色判定データDa〜Diのパターンがいずれのパターンとも一致しない場合にはエッジ部ではない(非エッジ部である)と判定し、エッジ判定信号として「0」を出力する。エッジ検出部13に予め登録するパターンの例を図11(a)〜(e)に示す。
【0045】
b.エッジ検出部13の第2の例
エッジ検出部13の第2の例を図12を用いて説明する。変化点抽出部12からの出力される3×3画素分の色判定データDa〜Diはカウンタ51−1,51−2に入力される。カウンタ51−1では入力された色判定データDa〜Diのうち「1」であるデータの個数を数える。また、カウンタ51−2では、同じく入力された色判定データDa〜Diのうち「0」であるデータの個数を数える。
【0046】
このカウンタ51−1,51−2のカウント結果はそれぞれ比較器52−1,52−2に入力される。そして、比較器52−1では、色判定データDa〜Diのうち「1」であるデータの個数と閾値th6が比較され、「1」の個数が閾値th6以上の時は「1」が出力され、閾値th6未満の場合は「0」が出力される。同様に、比較器52−2では、色判定データDa〜Diのうち「0」であるデータの個数と閾値th7が比較され、「0」の個数が閾値th7以上の時は「1」が出力され、閾値th7未満の場合は「0」が出力される。
【0047】
比較器52−1、52−2の出力はAND回路53に供給され、その論理積がエッジ判定信号として出力される。すなわち、このエッジ検出部13の第2の例では、変化点抽出部12から供給される3×3画素分の色判定データDa〜Diの「0」と「1」の個数(画素数)を算出し、その画素数がいずれも所定の閾値以上の時にエッジと判定し、注目画素に対するエッジ判定信号として、「1」を出力する。逆に少なくとも一方が閾値未満の時は、エッジ部ではないと判定し、エッジ信号として「0」を出力する。
【0048】
c.エッジ検出部13の第3の例
エッジ検出部13の第3の例を図13を用いて説明する。変化点抽出部12から供給される3×3画素分の色判定データDa〜Diは、乗算器54−1〜54−9に入力され、図14(a)に示すフィルタ係数との乗算(Da×Xa〜Di×Xi)がそれぞれ計算される。また、色判定データDa〜Diは、乗算器55−1〜55−9にも入力され、図14(b)に示すフィルタ係数との乗算(Da×Ya〜Di×Yi)がそれぞれ計算される。乗算器54−1〜54−9の出力は加算器56−1に入力され、また乗算器55−1〜55−9の出力は加算器56−2に入力され、それぞれ和(Σ(Dn×Xn)、Σ(Dn×Yn))が計算される。加算器56−1の出力Σ(Dn×Xn)は、乗算器57−1に入力され、また加算器56−2の出力Σ(Dn×Yn)は、乗算器57−2に入力されて、((Σ(Dn×Xn))2および(Σ(Dn×Yn))2が計算される。そして、これらの乗算器57−1,57−2の出力は加算器58に入力され、その和(Σ(Dn×Xn))2+(Σ(Dn×Yn))2が計算され、その結果が比較器59によって所定の閾値th8と比較される。そして、(Σ(Dn×Xn))2+(Σ(Dn×Yn))2が閾値以上の時はエッジ部であると判定され、エッジ信号(本例では「1」)が出力される。逆に閾値未満の時は、エッジ部ではないと判定され、非エッジ信号(本例では「0」)が出力される。
【0049】
例えば、変化点抽出部12から供給される3×3画素分の色判定データDa〜Diが前掲図10(c)に示すものであり、乗算器54−1〜54−9に入力されるフィルタ係数が図14(c)に示すものであり、乗算器55−1〜55−9に入力されるフィルタ係数が図14(d)に示すものであり、比較器59の閾値th8が「16」である場合について具体的に説明する。ちなみに図14(c)(d)に示す各フィルタ係数はSobelのオペレータである。図10(c)に示す色判定データDa〜Diについては、乗算器54−1〜54−9および加算器56−1により下記式(2)に示す演算が行われ、その結果が乗算器57−1に送られる。同様に乗算器55−1〜55−9および加算器56−2により下記式(3)に示す演算が行われ、その結果が乗算器57−2に送られる。
【0050】

Figure 0004057662
【0051】
Figure 0004057662
【0052】
次に乗算器57−1,57−2及び加算器58により、下記式(4)に示すように、加算器56−1,56−2の演算結果の2乗和が計算される。
2+32=18 ・・・(4)
この加算器58で算出された結果は比較器59に入力されて閾値th8((=16)と比較され、閾値以上であるのでエッジ部であると判定され、エッジ信号(本例では「1」)が出力される。
【0053】
なお、この例では、ブロックの大きさを3×3、フィルタの個数を2個、フィルタ係数はSobelのオペレータを用いて説明しているが、これに限るものではない。
【0054】
以上のようにして、入力画像の画像信号から代表色を求め、その代表色から代表色の変化点を抽出し、抽出された変化点からエッジ部を検出し、検出されたエッジ部を領域判定結果とすることにより像域分離が可能となる。
【0055】
B.第2の実施形態
本実施形態においては、上記第1の実施形態における像域分離部9(図1)として図15に示すものを使用する。なお、この図15に示す像域分離部において前掲図2に示したものと同一機能を持つものについては同一の符号を付し、その説明を省略する。
【0056】
図15において、画像信号は代表色割当部61に入力される。代表色割当部61では、入力された画像信号の各画素ごとに代表色を割当て、その代表色に対応する番号(以下、代表色番号と言う)を出力する。また、1つの代表色を割当てることができなかった場合は、代表色を割り当てることができなかったことを表す番号(以下、非代表色番号と言う)あるいは、複数の代表色の中間色を表す番号(以下、準代表色番号)を出力する。
【0057】
代表色番号、非代表色番号あるいは準代表色番号は代表色再割当部62に供給される。代表色再割当部62は、非代表色番号あるいは準代表色番号が供給されると、その非代表色番号等が割り当てられた画素の周辺画素に割り当てられた代表色番号を参照することにより、当該画素の代表色を決定し、その代表色番号を非代表色番号等の代りに当該画素に割り当てる。
【0058】
代表色再割当部62の出力は代表色修正部63に供給され、注目画素に割り当てられた代表色番号を、その周辺画素に割り当てられた代表色番号を参照して修正する。
【0059】
代表色修正部63の出力は変化点検出部12に供給される。変化点検出部12およびエッジ検出部13は第1の実施形態において説明したので、ここでは省略する。
【0060】
エッジ検出部13で検出されたエッジ信号はエッジ修正部64に入力され、エッジ信号に修正が加えられる。エッジ修正部64で修正が加えられたエッジ信号はエッジ再生成部65に送られてエッジ信号の再生成が行われ、エッジ信号として出力される。
【0061】
▲1▼代表色割当部61の構成例
a.代表色割当部61の第1の例
図16は代表色割当部61の第1の例である代表色割当部61aを示すものである。図16において、L***画像信号は距離演算部22に入力され、また代表色発生部21から順次発生する代表色番号も距離演算部22に入力されて、距離演算部22でL***画像信号によって表された色と代表色との距離計算が行われ、代表色近傍判定部71に送られる。代表色近傍判定部71では、代表色発生部21から供給された代表色番号と距離演算部22から供給された距離とに基づき、L***画像信号によって表された画素の色が代表色発生部21から供給された代表色番号に対応する代表色の近傍に属するか否かを判定する。そして、ある代表色の近傍に属すると判定した場合はその代表色番号を、どの代表色の近傍にも属さないと判定した場合は非代表色番号を出力する。代表色番号と非代表色番号の例を図17に示す。この図17に示す例では、「0」〜「7」が代表色番号、「9」が非代表色番号である。
【0062】
代表色近傍判定部71の構成例を図18に示す。この図において、LUT72には、各代表色毎に、どの範囲までの色を当該代表色の近傍色とみなすかを指定する情報が記憶されている。さらに詳述すると、本実施形態においては、各代表色毎に、当該代表色を中心とした所定距離の範囲内の色を当該代表色の近傍色とみなすこととしており、このような近傍色の範囲を表す距離(以下、近傍距離という。)が各代表色毎にLUT72に格納されているのである。
【0063】
そして、図16に示す代表色発生部21から出力された代表色番号iはこのLUT72に入力される。この結果、この代表色番号iに対応する近傍距離EiがLUT72から出力される。そして、距離演算部22(図6)から入力された距離Fpと、LUT72から出力された近傍距離Eiは比較器73に入力されて比較される。比較器73において、Fp<Eiの時は、対象となっている画素は代表色番号iに対応する代表色の近傍に属すると判定され、判定結果「1」が出力される。逆に、Fp≧Eiの時は、近傍に属さないと判定され、判定結果「0」が出力される。
【0064】
各代表色に対応した比較器73の判定結果は、選択回路74に順次入力され、選択回路74では比較器73の判定結果が「1」であったものに対応する代表色番号iを出力する。また、比較器73の出力が全て「0」であった場合には、対象となっている画素はどの代表色の近傍にも属さないと判定され、非代表色番号(本例では「9」)が出力される。
【0065】
b.代表色割当部61の第2の例
図19は代表色割当部61の第2の例である代表色割当部61bを示すものである。この図において、L***画像信号は、距離演算部25−1〜25−8に入力される。また、代表色発生部24に記憶されている複数の代表色の画像信号はそれぞれ距離演算部25−1〜25−8に入力される。そして、距離演算部25−1〜25−8においては、L***画像信号によって表された色と全ての代表色信号との距離F1〜F8が並行して計算され、各々比較器72−1〜72−8に送られる。
【0066】
比較器72−1〜72−8では、入力された距離F1〜F8と閾値th10−1〜th10−8とがそれぞれ比較される。そして、ある代表色番号iについて距離Fi<閾値th10−iが成立する場合には、L***画像信号によって表された色は代表色番号iに対応した代表色の代表色の近傍に属することとなり、比較器72−iから判定結果「1」が出力される。逆に、距離Fi≧閾値th10−iの場合には、L***画像信号によって表された色は代表色番号iに対応した代表色の代表色の近傍に属さないこととなり、比較器72−iから判定結果「0」が出力される。このように各比較器72−1〜72−8により、L***画像信号によって表された色が各代表色の近傍色か否かの判定が並行して行われ、各判定結果が代表色番号決定部73に送られる。
【0067】
代表色番号決定部73では比較器72−1〜72−8から送られてきた判定結果に基づいて代表色番号が決定され、出力される。例えば、比較器72−1〜72−8から送られてきた判定結果のうち1つだけが「1」であり、残りが「0」である場合は、判定結果「1」に対応する代表色番号が出力される。また、判定結果が全て「0」の場合は、どの代表色の近傍にも属さないということで非代表色番号が出力される。複数の判定結果が「1」の場合には、判定結果が「1」であった複数の代表色の中間色であることを表す番号(準代表色番号)を出力する。準代表色番号の例を図20に示す。この例によれば、代表色を白とした場合の判定結果が「1」であり、かつ、代表色を黒とした場合の判定結果も「1」である場合には、白と黒の中間色に対応した準代表色番号「10」が代表色番号決定部73によって出力されることとなる。
【0068】
▲2▼代表色再割当部62
代表色再割当部62の構成例を図21に示す。代表色割当部61から供給された代表色番号データ・非代表色番号データ・準代表色番号データは、それぞれデータを1ライン周期遅延させるための1ラインメモリ(ラインバッファ)81−1〜81−4と、それぞれデータを1画素周期遅延させるためのラッチ回路82−1〜82−20とによって順次遅延される。そして、これらの1ラインメモリおよびラッチ回路を使用した構成により、図22(a)に示すような注目画素Pmを中心とする5×5画素である画素Pa〜Pyに対応した代表色番号データ等が得られる。
【0069】
そして、画素Pmを除く画素Pa〜Pl、Pn〜Pyに対応したデータは、選別器83−1〜83−24に送られ、各データが代表色番号データであるのか、非代表色番号データであるのか、それとも準代表色番号データであるのかが選別される。そして、代表色番号データのみが画素数計測回路84に送られる。
【0070】
画素数計測回路84は、選別器83−1〜83−24から供給された代表色番号データを各代表色番号毎に集計し、5×5画素内のうち何個の画素が当該代表色番号の割り当てられた画素かを各代表色番号毎に求める。最大値選択回路85は、画素数計測回路84で計測された代表色番号ごとの画素数から、画素数が最大である代表色番号を選択し、その代表色番号を出力する。
【0071】
また、2者最大値選択回路86は、ラッチ回路82−10から出力される注目画素Pmに対応したデータが代表色番号データであるのか、非代表色番号データであるのか、それとも準代表色番号データであるのかを判定し、準代表色番号データであった場合にはどの複数の代表色の中間色であるかを判定し、画素数計測回路84で計測された代表色番号毎の画素数から前記複数の代表色のうち最も画素数の多い代表色を選択し、その代表色番号を出力する。
【0072】
ラッチ回路82−10から出力される注目画素Pmのデータは判定回路87にも入力され、判定回路87では入力された注目画素Pmが代表色番号データ、非代表色番号データ、あるいは準代表色番号データのいずれかであるかを判定し、その判定結果を選択器88に供給する。選択器88には最大値選択回路85の出力、2者最大値選択回路86の出力、ラッチ回路82−10の出力、および判定回路87の出力が供給され、判定回路87の判定結果から最大値選択回路85の出力、2者最大値選択回路86の出力、ラッチ回路82−10の出力のいずれかを選択し、その結果を出力する。すなわち、判定回路87の判定結果が代表色番号データである場合はラッチ回路82−10の出力、判定結果が非代表色番号データである場合は最大値選択回路85の出力、判定結果が準代表色番号データである場合は2者最大値選択回路86の出力を選択し、その結果を出力する。
【0073】
次に代表色再割当部62の処理内容について具体例をあげて説明する。例えば、代表色再割当部62に図22(b)のようなデータ群が入力されたとする。この場合、注目画素Pmに対応したデータとして代表色番号データ「6」(青)が入力されているため、判定回路87では注目画素に対応したデータが代表色番号データであると判定され、その結果が選択器88に送られる。この結果、選択器88はラッチ回路82−10の出力を選択し、「6」を出力する。
【0074】
また、代表色再割当部62に図22(c)のようなデータ群が入力されたとする。この場合、画素数計測回路84によって代表色番号毎の画素数が図22(f)に示すように測定される。そして、最大値選択回路85によって画素数が最大の代表色番号「6」(青)が選択器88に送られる。そして、注目画素Pmに対応したデータとして非代表色番号データ「9」が入力されているため、判定回路87は非代表色番号であると判定し、選択器88は最大値選択回路85の出力を選択し、「6」を出力する。
【0075】
また、代表色再割当部62に図22(d)のようなデータ群が入力されたとする。この場合、画素数計測回路84によって代表色番号毎の画素数が図22(g)に示すように測定される。そして、2者最大値選択回路86は、注目画素Pmに対応したデータが準代表色番号たる「60」であることから、注目画素Pmに対応した色が代表色番号「0」に対応した代表色と代表色番号「6」に対応した代表色の中間色であると判定する。そして、代表色番号「0」と「6」のうち画素数の多い方の代表色番号「6」を選択して出力する。そして、判定回路87は、注目画素Pmに対応したデータは「60」なので、準代表色番号データであると判定し、それに従い選択器88は2者最大値選択回路86の出力を選択し、代表色番号「6」を出力する。
【0076】
▲3▼代表色修正部63
次に代表色修正部63について図23を参照して説明する。図23において、代表色再割当部62から供給されるた代表色番号データは、1ラインメモリ91−1,91−2とラッチ回路92−1〜92−6によって遅延される。そして、これらの1ラインメモリおよびラッチ回路からなる構成により、3×3画素からなるブロックを構成する各画素の代表色番号データが得られる。3×3画素ブロックを構成する各画素の代表色番号データは、画素数測定回路93により、各代表色番号毎に個数(すなわち、当該代表色番号の割り当てられた画素数)が測定される。
【0077】
最大数番号検出回路94では、画素数測定回路93において測定された代表色番号ごとの画素数から、その画素数が最大である代表色番号を検出し、その代表色番号を出力する。また、画素数抽出回路95には、画素数測定回路93において測定された代表色番号ごとの画素数および注目画素(3×3画素の中心画素)の代表色番号が入力され、注目画素の代表色番号と同一代表色番号を持つ画素が3×3画素内に何画素あるかを抽出し(注目画素を含む)、その画素数を出力する。比較器96では入力された画素数データと「1」を比較し、画素数が1の場合は「1」、1より多い場合は「0」を選択回路97に出力する。
【0078】
選択回路97では、画素数抽出回路95から供給されるデータが「1」の時は、注目画素は孤立点であると判定し、最大数番号検出回路94から供給される代表色番号を選択し、その代表色番号を出力する。また、画素数抽出回路95から供給されるデータが「0」の時は、ラッチ回路92−3の出力、すなわち注目画素の代表色番号のデータを選択し、その代表色番号を出力する。このようにして、代表色番号の孤立点を除去することが可能となる。
【0079】
▲4▼エッジ修正部64
次に、エッジ修正部64を、図24を用いて説明する。エッジ修正部64では、エッジの孤立点を除去する。図24において、エッジ検出部13から入力されたエッジ信号は、1ラインメモリ101−1,101−2とラッチ回路102−1〜102−6によって3×3画素にブロック化される。ブロック化された3×3画素のうち中心画素を除く8画素のデータはOR回路103に供給され、8画素のOR演算が行われ、その結果は選択回路104に出力される。選択回路104は、OR回路103から入力されたデータが「0」の時すなわち8近傍画素全てが「0」の時は「0」を出力し、OR回路103から入力された信号が「1」の時は注目画素(3×3画素の中心画素)のデータを出力する。
【0080】
▲5▼エッジ再生成部65
次に、エッジ再生成部65について説明する。エッジ再生成部65では、エッジ修正部64から入力されたエッジ部より文字領域を生成し出力する。領域の生成の方法として、例えば注目画素を中心とした所定の大きさ(例えば3×3や5×5など)のウィンドウを用い、注目画素(ウィンドウの中心画素)がエッジ部ならばウィンドウ全体を文字領域とする方法がある。また別の方法として、所定の大きさの範囲でエッジ部の連結を追跡し(輪郭追跡)、エッジ部が閉じた領域(閉領域)を形成している場合にそのエッジ部及び閉領域の内部を文字領域として抽出する方法などがある。
【0081】
以上のようにして、本実施形態においては、入力画像の画像信号から各画素の代表色を求め、その代表色を周囲の代表色を参照することにより修正し、修正された代表色から代表色の変化点を抽出し、抽出された変化点からエッジ部を検出し、検出されたエッジ部の孤立点を除去するなどしてエッジ部を修正し、修正されたエッジ部を膨らますなどしてエッジ部の再生成を行い、そして再生成されたエッジ部を用いて像域分離を行う。従って、第1の実施形態に比べ処理の規模は大きくなるものの、より正確な領域判定が可能となる。
【0082】
C.第3の実施形態
図25を用いて、本発明第3の実施形態について説明する。なお、本実施形態の説明において、第1の実施形態及び第2の実施形態で説明したものと同一機能を持つものについては同一の符号を付し、その説明を省略する。
【0083】
色信号変換部3から出力された色信号は、色信号変換部4に入力されるとともに、網点領域識別部111および像域分離部112にも入力される。
【0084】
網点領域識別部111では、入力された画像信号より網点領域を識別し、その識別結果を像域分離部112に出力する。網点領域識別部111での網点識別方法については、パターンマッチングによる方法や、ピーク値をとる画素の周期性から識別する方法などがあるが、その詳細については本発明の主旨ではないので、ここではその説明は割愛する。
【0085】
像域分離部112では、色信号変換部3から入力された画像信号と、網点領域識別部111から入力された網点領域信号より、網点領域の像域分離および非網点領域の像域分離処理を行う。
【0086】
像域分離部112から出力された像域分離信号は、空間フィルタ部6、出力階調補正部7、画像出力部8に供給され、網点内の文字領域・絵柄領域及び非網点内の文字領域・絵柄領域の各領域毎にそれぞれ最適な再現処理が施され画像が出力される。
【0087】
次に、像域分離部112について、図26を用いて説明する。図26において、画像信号は平滑化部121に入力される。平滑化部121では、網点領域識別部111から入力された網点領域信号に応じて画像信号の平滑化を行い、代表色割当部11に出力する。
【0088】
代表色割当部11では、入力された画像信号に代表色を割当てるが、その際、網点領域信号に応じて代表色の割当方法や閾値などを切り替える。
【0089】
割り当てられた代表色の信号(代表色信号)は変化点抽出部12において代表色の変化点が抽出され、エッジ検出部13に送られる。
【0090】
エッジ検出部13では、変化点抽出部12から供給された変化点の信号からエッジを検出するが、その際、網点領域信号に応じてエッジ検出のパラメータ、例えばフィルタの係数、パターンマッチングのためのパターン、あるいは閾値などを切り替えてエッジを検出し、エッジ信号を出力する。
なお、代表色割当部11、変化点抽出部12、エッジ検出部13に関しては第1の実施形態において説明したので、ここではその詳説は省略する。
【0091】
平滑化部121では、入力された網点領域信号が網点領域を表す場合、画像信号の平滑化を行う。平滑化は、所定の範囲(例えば3×3や5×5)の画素値の単純平均あるいは重み付け平均を算出し、注目画素の画素値とする。
【0092】
以上のようにして、本実施形態においては、網点領域を識別し、網点領域か否かによってパラメータを切り替えて代表色を求め、求められた代表色から代表色の変化点を抽出し、代表色の変化点から網点領域信号によってパラメータを切り替えながらエッジを検出する。これにより、無背景部の文字領域抽出だけではなく、網点領域の文字領域抽出も可能となる。そして、これらの領域判定結果を用いることにより、高精度な画像再現処理が可能となるため、より高品位な出力画像を得ることが可能となる。
【0093】
【発明の効果】
以上説明したように本発明によれば、入力画像を構成する各画素に対して代表色を割当て、入力画像を代表色の異なった複数の像域に区分する境界を検出するようにしたので、カラー画像信号を有効に活用した高精度な像域分離が可能となる。また、本発明では各画素の色の変化に基づいて像域分離を行うために、誤判定を少なくすることができ、背景と同等の明度成分を持つ文字部をも正確に抽出することが可能である。
【図面の簡単な説明】
【図1】 本発明の第1の実施形態である画像処理装置の構成を示すブロック図である。
【図2】 同実施形態における像域分離部9の構成を示すブロック図である。
【図3】 同実施形態における代表色割当部11aの構成を示すブロック図である。
【図4】 同実施形態における距離演算部22の構成を示すブロック図である。
【図5】 同実施形態における代表色割当部11bの構成を示すブロック図である。
【図6】 同実施形態における代表色割当部11cの構成を示すブロック図である。
【図7】 同実施形態における代表色割当部11dの構成を示すブロック図である。
【図8】 同代表色割当部11dにおけるLUT34の内容を示す図である。
【図9】 同実施形態における変化点抽出部12の構成を示すブロック図である。
【図10】 同変化点抽出部12の動作を説明する図である。
【図11】 同実施形態におけるエッジ検出部13の第1の例を示す図である。
【図12】 同実施形態におけるエッジ検出部13の第2の例を示すブロック図である。
【図13】 同実施形態におけるエッジ検出部13の第3の例を示すブロック図である。
【図14】 同エッジ検出部の動作を説明する図である。
【図15】 この発明の第2の実施形態における像域分離部の構成を示すブロック図である。
【図16】 同実施形態における代表色割当部61の第1の例の構成を示すブロック図である。
【図17】 同実施形態における代表色番号および非代表色番号の例を示す図である。
【図18】 代表色割当部61における代表色近傍判定部71の構成を示すブロック図である。
【図19】 同実施形態における代表色割当部61の第2の例の構成を示すブロック図である。
【図20】 第2の例において使用する準代表色番号の例を示す図である。
【図21】 同実施形態における代表色再割当部62の構成を示すブロック図である。
【図22】 同代表色再割当部62の動作を示す図である。
【図23】 同実施形態における代表色修正部63の構成を示すブロック図である。
【図24】 同実施形態におけるエッジ修正部64の構成を示すブロック図である。
【図25】 この発明の第3の実施形態による画像処理装置の構成を示すブロック図である。
【図26】 同実施形態における像域分離部112の構成を示すブロック図である。
【符号の説明】
11・・・・・・・・・・・・・・・・・代表色割当部
12・・・・・・・・・・・・・・・・・変化点抽出部
13・・・・・・・・・・・・・・・・・エッジ検出部
111・・・・・・・・・・・・・・・・網点領域識別部[0001]
BACKGROUND OF THE INVENTION
The present invention relates to an image processing apparatus that separates a color original image into a character area and a picture area and performs image processing suitable for each area.
[0002]
[Prior art]
Generally, an input image read by a scanner or an input image transmitted by a facsimile or the like is reproduced as a hard copy. At that time, the input image includes a character portion, a line drawing portion, a photographic portion, and a halftone dot. There may be some parts. In this case, character areas such as text and line drawings are processed with an emphasis on resolution, and image areas such as photographs and dots are processed with an emphasis on gradation. This makes it possible to obtain a high-quality reproduced image.
[0003]
In order to apply an appropriate one of resolution-oriented processing or gradation-oriented processing to the character region / design region included in such an input image, the input image is first converted into the character region and the design region. (Hereinafter, the separation of the character area and the picture area is referred to as image area separation), and various proposals have been made regarding this image area separation.
[0004]
As an example, the image is divided into blocks of a certain size, the maximum density and the minimum density of the pixels included in the block are obtained for each block, and the difference between the maximum density and the minimum density is determined with a predetermined threshold value. In comparison, there was a method of determining a block larger than the threshold as a character area and a smaller block as a picture area.
[0005]
[Problems to be solved by the invention]
By the way, there are many areas where the density difference is intense in the pattern area including a halftone such as a photograph in the input image. Therefore, when the above method is adopted, since it is determined whether it is a character block or a picture block based only on the density difference in the block, it is mistakenly recognized as a character block even though it is a picture block, and importance is attached to the resolution. However, there is a drawback in that the image quality is deteriorated.
[0006]
In addition, most of the conventional image area separation techniques including the above method are assumed to be monochrome images, and there is no technique suitable as an image area separation technique for color images. Therefore, in order to make the image area separation technique for black and white images corresponding to color images, for example, the following method has been adopted.
a. Image area separation processing is performed for each color component of the color image, and the character area and the picture area are separated based on the logical sum of the results.
b. Information representing the component in the color space of the color image is L * a * b * Is converted into information having a lightness component, and image area separation processing is performed on the lightness component.
[0007]
However, the method a has a problem in that erroneous determination increases because a logical sum of determination results for each color component is calculated. Further, the method b has a problem that it is difficult to extract a character portion having a high lightness in a white background or a character having a lightness equivalent to the background in a color background.
[0008]
Further, the conventional image area separation technique has another problem when an image to be reproduced includes a halftone dot portion. That is, when a reproduced image includes a halftone dot portion, the halftone dot portion is determined to be a picture area, and therefore, the same image reproduction processing as that for the picture area is performed on the character part existing in the halftone dot part. It will end up.
[0009]
The present invention has been made to eliminate the above-described drawbacks of the prior art, and is an image that can accurately extract not only the black characters in the white background but also the color characters in the white background and the characters in the color background. The object is to provide a processing apparatus. Another object of the present invention is to provide an image processing apparatus capable of accurately extracting characters existing in a pattern area such as a halftone dot portion.
[0010]
[Means for Solving the Problems]
In order to solve the above problem, the invention according to claim 1 Manuscript input Color Based on the representative color assignment means for assigning a representative color approximate to the color of the pixel among a plurality of representative colors to each pixel constituting the image, and the representative color assigned to each pixel by the representative color assignment means, input Color It is an object of the present invention to provide an image processing apparatus comprising boundary detection means for detecting a boundary that divides an image into a plurality of image areas each having a different representative color.
[0011]
In the invention according to claim 2, the image processing apparatus is Manuscript input Color A representative color assignment step for assigning a representative color that approximates the color of the pixel among a plurality of representative colors to each pixel constituting the image, and based on the representative color assigned to each pixel in the representative color assignment step, input Color And a boundary detecting step for detecting a boundary that divides the image into a plurality of image areas each having a different representative color.
[0012]
DETAILED DESCRIPTION OF THE INVENTION
Embodiments will be described below for easier understanding of the present invention.
[0013]
A. First embodiment
(1) Overall configuration
FIG. 1 is a block diagram showing a configuration of an image processing apparatus according to the first embodiment of the present invention. In FIG. 1, an image input unit 1 is constituted by an image scanner using a light quantity conversion element such as a CCD camera. The image input unit 1 reads the color image information of the original for each color, and converts the color image information into, for example, an RGB image signal (digital signal) composed of 8 bits for each color and outputs the RGB image signal. The RGB image signal is corrected in gradation by the input gradation correction unit 2. In the color signal conversion unit 3, the RGB image signal subjected to gradation correction in this way is converted into another color signal, for example, L * a * b * Converted to image signal.
[0014]
L output from the color signal converter 3 * a * b * The image signal is supplied to the color signal conversion unit 4, and is converted by the color signal conversion unit 4 into another color signal, for example, a YMC image signal. Then, the black plate generation unit 5 generates a black plate from the YMC image signal, and the YMC image signal is converted into a YMCK image signal including the black plate.
[0015]
The YMCK image signal output from the black plate generation unit 5 is supplied to the spatial filter unit 6 and subjected to spatial filtering processing for each color. Also, the spatial filter unit 6 receives a region determination result from an image region separation unit 9 (to be described later), and the processing content of the spatial filtering process, such as switching of a filtering coefficient, is switched according to the region determination result. Is called. As a result, in the spatial filter unit 6, when a YMCK image signal corresponding to a character area such as a character part or a line drawing part is input, filter processing is performed with emphasis on resolution. When a YMCK image signal for a region is input, a filter process that emphasizes gradation is performed.
[0016]
The YMCK image signal that has been subjected to the spatial filtering process is supplied to the output tone correction unit 7 and output tone correction is performed so as to meet the image output tone characteristics for each color. A region determination result from an image region separation unit 9 described later is also input to the output tone correction unit 7. The output tone correction unit 7 performs output tone correction corresponding to the region determination result on the YMCK image signal.
[0017]
The image output unit 8 is supplied with the YMCK image signal whose output gradation has been corrected in this way, and is also supplied with the region determination result from the image region separation unit 9 described later. In the image output unit 8, for example, a screen or the like is switched in accordance with the region determination result, and an image is output.
[0018]
The image area separation unit 9 includes L output from the color signal conversion unit 3. * a * b * An image signal is supplied. This image area separation unit 9 is L * a * b * For each pixel represented by the image signal, it is determined whether it belongs to the character part or the picture part. The region determination result is supplied to the above-described spatial filter unit 6, output tone correction unit 7, and image output unit 8, and processing corresponding to the region determination result is performed as described above.
[0019]
(2) Image area separation unit
Next, the image area separation unit 9 will be described. As shown in FIG. 2, the image area separation unit 9 includes a representative color assignment unit 11, a change point extraction unit 12, and an edge detection unit 13. L output from the color signal converter 3 described above. * a * b * The image signal is input to the representative color assignment unit 11. In the representative color assignment unit 11, a representative color is assigned to each pixel according to the signal value (pixel value). Then, a number corresponding to the assigned representative color (hereinafter referred to as a representative color number) is output. A method for assigning representative colors will be described later.
[0020]
The representative color number output from the representative color assignment unit 11 is supplied to the change point extraction unit 12. The change point extraction unit 12 extracts a change point of the representative color number from the input representative color number. This change point extraction method will also be described later.
[0021]
The edge detection unit 13 detects an edge portion from the change point of the representative color number extracted by the change point extraction unit 12, and outputs the edge portion detection result as an edge determination signal. This edge detection method will also be described later. In the present embodiment, the edge detection unit 13 and the change point extraction unit 12 perform L * a * b * Boundary detection means for detecting a boundary that divides the input image represented by the image signal into a plurality of image areas each having a different representative color is configured.
[0022]
(1) Representative color assignment unit 11
Next, the representative color assignment unit 11 will be described.
a. First example of representative color assignment unit
FIG. 3 shows a representative color assignment unit 11a which is a first example of the representative color assignment unit 11. As shown in the figure, the representative color allocating unit 11a includes a representative color generating unit 21, a distance calculating unit 22, and a shortest distance determining unit 23.
[0023]
The representative color generation unit 21 has a look-up table (hereinafter referred to as LUT) composed of, for example, a RAM or a ROM, and the LUT includes a plurality of representative color signal values (L representing the representative color). * a * b * The value of each component of the image signal) and the representative color number corresponding to each representative color are stored. The representative color may be a plurality of fixed representative colors, or a plurality of characteristic colors selected from an image input in advance may be used as the representative colors. Examples of a plurality of fixed representative colors are Y (yellow), M (magenta), C (cyan), R (red), G (green), B (blue), Bk (black), W (white) ) 8 colors.
[0024]
A clock signal (not shown) is supplied to the representative color generator 21. Then, in synchronization with this clock signal, the representative color number corresponding to the representative color signal value stored in the LUT is sequentially read out, the representative color signal value is sent to the distance calculation unit 22, and the representative color number is the shortest distance. It is supplied to the determination unit 23.
[0025]
The distance calculation unit 22 sequentially receives signal values of a plurality of representative colors from the representative color generation unit 21, and outputs the signal values of these representative colors from the color signal conversion unit 3 described above. * a * b * Calculate the distance to the image signal.
[0026]
Here, a detailed configuration of the distance calculation unit 22 will be described with reference to FIG. In FIG. 4, reference numerals 35-1 to 35-3 denote subtracters, and L output from the color signal conversion unit 3. * a * b * Each component of the image signal and the L of the representative color output from the representative color generator 21 * a * b * The difference with each component is output. Reference numerals 36-1 to 36-3 denote multipliers, which square out the respective values output from the subtractors 35-1 to 35-3 and output the result. Reference numeral 37 denotes an adder that sums and outputs the values output from the multipliers 36-1 to 36-3. Therefore, the value output from the adder 37 is L * a * b * This is the square of the Euclidean distance between the input image data and the representative color data in the color space. That is, the input image signal is expressed as (L 0 , A 0 , B 0 ), The representative color signal (L 1 , A 1 , B 1 ), The following equation (1) is calculated, and the value is output from the adder 37.
[0027]
(L 0 -L 1 ) 2 + (A 0 -A 1 ) 2 + (B 0 -B 1 ) 2 ... (1)
[0028]
As described above, signal values of a plurality of representative colors are sequentially supplied to the distance calculation unit 22 in synchronization with the clock signal. As a result, in the distance calculation unit 22, the L from the color signal conversion unit 3 is obtained for each representative color. * a * b * The distance to the color corresponding to the image signal is sequentially calculated, and the calculation result is sequentially supplied to the shortest distance determination unit 23. On the other hand, the representative color number of each representative color is supplied from the representative color generation unit 21 to the shortest distance determination unit 23 in synchronization with the distance calculation result corresponding to each representative color being sequentially supplied to the shortest distance determination unit 23. The The shortest distance determination unit 23 determines the smallest value (one with the shortest distance) among the calculation results of the distances that are sequentially supplied, and selects and outputs a representative color number corresponding to the distance.
[0029]
b. Second example of representative color assignment unit
FIG. 5 shows a representative color assignment unit 11 b which is a second example of the representative color assignment unit 11. In the representative color assignment unit 11b, signal values of a plurality of representative colors are supplied to different distance calculation units 25-1 to 25-8. Then, each of the representative colors and L is calculated by the distance calculation units 25-1 to 25-8. * a * b * Calculation of the distance between the colors represented by the image signal is performed in parallel. The distance calculation results for each of these representative colors are supplied to the shortest distance determination unit 26. Then, the shortest distance determination unit 26 determines the shortest one among the calculation results of these distances, and outputs the representative color number corresponding to the shortest distance.
[0030]
c. Third example of representative color assignment unit
FIG. 6 shows a representative color assignment unit 11 c which is a third example of the representative color assignment unit 11. In the representative color allocation unit 11c, the L from the color signal conversion unit 3 * a * b * L of each component of the image signal * The component is compared with the threshold th1 by the comparator 27. And L * When the component is higher than the threshold th1, the representative color number corresponding to white is output from the comparator 27, and when the component is lower, the representative color number corresponding to black is output.
[0031]
In addition, other a supplied from the color signal conversion unit 3 * Ingredients and b * The component is input to the LUT 29, and the a * Ingredients and b * A hue corresponding to the component is determined, and a representative color number representing the hue (for example, a representative color number corresponding to Y, M, C, R, G, B) is output.
[0032]
The image signal a * And b * Are also input to multipliers 30-1 and 30-2, respectively. * Squared and b * Are calculated, and the results of the calculation are added by the adder 31. As a result, the adder 31 outputs a * And b * Of each square, that is, a value corresponding to the square of the saturation of the input image is output. In the comparator 32, a value corresponding to the square of the saturation of the input image is compared with the threshold value th2. When the value is equal to or greater than the threshold value th2, information “1” indicating that the input image is a chromatic color is the threshold value th2. If it is less than the value, information “0” indicating that the input image is achromatic is output.
[0033]
In the selector 28, either the output of the comparator 27 or the output of the LUT 29 is selected according to the output information from the comparator 32 and is output as the representative color number. That is, when the output of the comparator 32 is “0” (when it is determined as an achromatic color), the representative color number of white or black that is the output of the comparator 27 is output, and the output of the comparator 32 is “1”. In this case, it is determined that the saturation is high, and representative color numbers (for example, representative color numbers of Y, M, C, R, G, and B) that are output from the LUT 29 are output.
[0034]
d. Fourth example of representative color assignment unit
FIG. 7 shows a representative color assignment unit 11 d which is a fourth example of the representative color assignment unit 11. The representative color assignment units 11a to 11c according to the first to third examples described above are L as color signals. * a * b * Handled the signal. On the other hand, the representative color assignment unit 11d according to the fourth example shown in FIG. 7 obtains a representative color when an RGB color signal is input. When the representative color allocating unit 11d is used in the image area separating unit 9, the output signal of the input gradation correcting unit 2 in FIG. 1 can be directly input to the image area separating unit 9.
[0035]
In FIG. 7, the R, G, and B color signals supplied from the input tone correction unit 2 are supplied to the comparators 33-1 to 33-3. In the comparators 33-1 to 33-3, the R, G, and B color signal values are respectively compared with the threshold values th3, th4, and th5. If each color is less than the threshold value, the value is “0”, which is equal to or greater than the threshold value. In this case, “1” is output. The binarized signals for the three colors obtained from the comparators 33-1 to 33-3 in this way are input to the LUT 34. FIG. 8 illustrates the stored contents of the LUT 34. When the binarized signals for the three colors are input to the LUT 34, a representative color is selected according to the table shown in FIG. 8, and the representative color number is output.
[0036]
For example, the signal values of the R, G, and B color signals supplied from the input tone correction unit 2 are (R, G, B) = (200, 215, 84), and the threshold values th3, th4, and th5 are all set. If it is 128, “1”, “1”, and “0” are output from the comparators 33-1 to 33-3, respectively. As a result, in the LUT 34, yellow is selected from the table of FIG. 8, and the representative color number “3” is output.
[0037]
In the fourth example, the case where an RGB signal is input has been described, but a representative color can be similarly assigned even when a YMC or YMCK color signal is input.
[0038]
(2) Change point extraction unit 12
Next, the change point extraction unit 12 will be described. The input image is composed of a large number of pixels arranged vertically and horizontally, and the representative color assignment unit 11 described above performs a process of assigning a representative color number to each of these pixels. The change point extraction unit 12 determines and extracts a change point of the representative color of the pixel in the image based on the representative color number of each pixel thus obtained. In the change point extraction unit 12 according to the present embodiment, each pixel constituting the input image is sequentially selected as a target pixel, and the representative color number of the target pixel and the representative colors of peripheral pixels within a predetermined range centered on the target pixel. The change point of the representative color number is determined and extracted by comparing the numbers and determining whether the representative color numbers are equal.
[0039]
FIG. 9 shows a configuration example of the change point extraction unit 12 in which the predetermined range is a 3 × 3 window centered on the target pixel. The representative color number data of each pixel sequentially output from the representative color assigning unit 11 is delayed by one line cycle by passing through the one line memory (line buffer) 41-1, and then passes through the one line memory 41-2. This further delays one line cycle. The representative color number data supplied from the representative color allocating unit 11 is output by the latch circuit 42-1, and the representative color number output from the one-line memory 41-1 is determined by the latch circuit 42-3. The representative color number to be output is delayed by one pixel period by the latch circuit 42-5. Further, the representative color numbers output from the latch circuits 42-1, 42-3, and 42-5 are delayed by one pixel period by the latch circuits 42-2, 42-4, and 42-6, respectively.
[0040]
With the above configuration, each pixel P of a block composed of 3 × 3 pixels as shown in FIG. a ~ P i The representative color number data is obtained. That is, the representative color number data currently output from the representative color assignment unit 11, the representative number data output from the latch circuit 42-1, and the representative color number data output from the latch circuit 42-2 are the latest one line. Consecutive 3-pixel P a , P b And P c Representative color number data. The representative color number data output from the one-line memory 41-1, the representative number data output from the latch circuit 42-3, and the representative color number data output from the latch circuit 42-4 are one line from the current level. 3 consecutive pixels P constituting only the previous line d , P e And P f Representative color number data. Of these, the pixel P e Is the pixel of interest located at the center of the block. The representative color number data output from the one-line memory 41-2, the representative number data output from the latch circuit 42-5, and the representative color number data output from the latch circuit 42-6 are two lines from the current level. 3 consecutive pixels P constituting only the previous line g , P h And P i Representative color number data.
[0041]
And each pixel P a ~ P i For each of the representative color number data thus obtained, the pixel of interest P at the center of the block e Color determination data D indicating whether or not it matches the representative color number data of a ~ D i Is generated and supplied to the edge detector 13. That is, the pixel P a ~ P d , P f ~ P i Each representative color number data and target pixel P e Are compared by the comparators 43-1 to 43-8, and each pixel P a ~ P d , P f ~ P i Pixel of interest P e “1” is output as the color determination data for those having the representative color number data matching the representative color number data, and “0” is output as the color determination data for the other pixels. Note that the pixel of interest P e Since there is no meaning to compare, the color determination data D corresponding to this e “1” is supplied to the edge detector 13.
[0042]
For example, each pixel P constituting the block a ~ P i Assuming that each representative color number data is as shown in FIG. 10B, each representative color data and the pixel of interest P e Each color determination data D obtained by comparison with the representative color number of a ~ D i Is as shown in FIG. In this example, the target pixel P e Therefore, for the pixel having the representative color number “6” in the 3 × 3 window, the color determination data is “1”, and the pixel having the representative color number other than “6” is used. The color determination data is “0”. The color determination data D obtained in this way a ~ D i Is supplied to the edge detector 13.
[0043]
(3) Edge detector
As described above, the change point extraction unit 12 obtains color determination data corresponding to pixels within a predetermined range centered on the target pixel. The edge detection unit 13 determines whether or not the pixel of interest forms an edge that is a part of the boundary between the character area and the picture area based on the color determination data corresponding to the pixels within the predetermined range. A configuration example of the edge detection unit 13 will be described below.
[0044]
a. First example of the edge detection unit 13
In this first example, it is determined whether or not the target pixel constitutes an edge by pattern matching. That is, the edge detection unit 13 outputs 3 × 3 pixel color determination data D output from the change point extraction unit 12. a ~ D i Is compared with each of a plurality of patterns registered in advance, and if it matches any of the patterns, it is determined that the pixel of interest constitutes an edge portion, and “1” is output as an edge determination signal To do. On the other hand, color determination data D a ~ D i If the pattern does not match any pattern, it is determined that the pattern is not an edge (non-edge) and “0” is output as an edge determination signal. Examples of patterns registered in advance in the edge detection unit 13 are shown in FIGS.
[0045]
b. Second example of edge detection unit 13
A second example of the edge detection unit 13 will be described with reference to FIG. Color determination data D for 3 × 3 pixels output from the change point extraction unit 12 a ~ D i Are input to the counters 51-1 and 51-2. In the counter 51-1, the input color determination data D a ~ D i The number of data “1” is counted. In addition, the counter 51-2 receives the same color determination data D. a ~ D i The number of data that is “0” is counted.
[0046]
The count results of the counters 51-1 and 51-2 are input to the comparators 52-1 and 52-2, respectively. Then, in the comparator 52-1, the color determination data D a ~ D i Of these, the number of data “1” is compared with the threshold th6, and “1” is output when the number of “1” is equal to or greater than the threshold th6, and “0” is output when the number is less than the threshold th6. Similarly, in the comparator 52-2, the color determination data D a ~ D i Of these, the number of data “0” is compared with the threshold th7, and “1” is output when the number of “0” is equal to or greater than the threshold th7, and “0” is output when the number is less than the threshold th7.
[0047]
The outputs of the comparators 52-1 and 52-2 are supplied to the AND circuit 53, and the logical product is output as an edge determination signal. That is, in the second example of the edge detection unit 13, the color determination data D for 3 × 3 pixels supplied from the change point extraction unit 12. a ~ D i The number (number of pixels) of “0” and “1” is calculated, and when both the number of pixels is equal to or greater than a predetermined threshold, an edge is determined, and “1” is output as an edge determination signal for the target pixel. Conversely, when at least one is less than the threshold, it is determined that the edge portion is not present, and “0” is output as the edge signal.
[0048]
c. Third example of the edge detection unit 13
A third example of the edge detection unit 13 will be described with reference to FIG. Color determination data D for 3 × 3 pixels supplied from the change point extraction unit 12 a ~ D i Is input to the multipliers 54-1 to 54-9 and multiplied by the filter coefficient (D) shown in FIG. a × X a ~ D i × X i ) Is calculated respectively. Also, the color determination data D a ~ D i Are also input to the multipliers 55-1 to 55-9 and multiplied by the filter coefficient (D) shown in FIG. a × Y a ~ D i × Y i ) Is calculated respectively. The outputs of the multipliers 54-1 to 54-9 are input to the adder 56-1, and the outputs of the multipliers 55-1 to 55-9 are input to the adder 56-2, and each sum (Σ (D n × X n ), Σ (D n × Y n )) Is calculated. Output Σ (D of adder 56-1 n × X n ) Is input to the multiplier 57-1, and the output Σ (D n × Y n ) Is input to the multiplier 57-2 and ((Σ (Dn × Xn)) 2 And (Σ (Dn × Yn)) 2 Is calculated. The outputs of these multipliers 57-1 and 57-2 are input to an adder 58 and the sum (Σ (D n × X n )) 2 + (Σ (D n × Y n )) 2 Is calculated, and the result is compared with a predetermined threshold th8 by the comparator 59. And (Σ (D n × X n )) 2 + (Σ (D n × Y n )) 2 Is equal to or greater than the threshold, it is determined that the edge portion is present, and an edge signal (“1” in this example) is output. Conversely, when it is less than the threshold value, it is determined that it is not an edge portion, and a non-edge signal (“0” in this example) is output.
[0049]
For example, color determination data D for 3 × 3 pixels supplied from the change point extraction unit 12 a ~ D i 10 (c), the filter coefficients inputted to the multipliers 54-1 to 54-9 are shown in FIG. 14 (c), and the multipliers 55-1 to 55-9 are connected to the multipliers 55-1 to 55-9. The case where the input filter coefficient is shown in FIG. 14D and the threshold value th8 of the comparator 59 is “16” will be specifically described. Incidentally, each filter coefficient shown in FIGS. 14C and 14D is a Sobel operator. Color determination data D shown in FIG. a ~ D i , The multipliers 54-1 to 54-9 and the adder 56-1 perform the operation shown in the following equation (2), and the result is sent to the multiplier 57-1. Similarly, the multiplier 55-1 to 55-9 and the adder 56-2 perform the calculation shown in the following equation (3), and the result is sent to the multiplier 57-2.
[0050]
Figure 0004057662
[0051]
Figure 0004057662
[0052]
Next, the multipliers 57-1 and 57-2 and the adder 58 calculate the square sum of the calculation results of the adders 56-1 and 56-2 as shown in the following equation (4).
3 2 +3 2 = 18 (4)
The result calculated by the adder 58 is input to the comparator 59 and compared with a threshold value th8 ((= 16)). Since the result is equal to or greater than the threshold value, it is determined as an edge portion, and an edge signal (“1” in this example) is determined. ) Is output.
[0053]
In this example, the block size is 3 × 3, the number of filters is two, and the filter coefficient is a Sobel operator. However, the present invention is not limited to this.
[0054]
As described above, the representative color is obtained from the image signal of the input image, the change point of the representative color is extracted from the representative color, the edge portion is detected from the extracted change point, and the detected edge portion is determined as a region. As a result, image area separation is possible.
[0055]
B. Second embodiment
In the present embodiment, the image area separation unit 9 (FIG. 1) in the first embodiment is the one shown in FIG. 15 having the same functions as those shown in FIG. 2 described above are denoted by the same reference numerals and description thereof is omitted.
[0056]
In FIG. 15, the image signal is input to the representative color assignment unit 61. The representative color assignment unit 61 assigns a representative color to each pixel of the input image signal and outputs a number corresponding to the representative color (hereinafter referred to as a representative color number). If one representative color could not be assigned, a number indicating that the representative color could not be assigned (hereinafter referred to as a non-representative color number) or a number indicating an intermediate color among a plurality of representative colors (Hereinafter, quasi-representative color number) is output.
[0057]
The representative color number, the non-representative color number, or the quasi-representative color number is supplied to the representative color reassignment unit 62. When the non-representative color number or the quasi-representative color number is supplied, the representative color reassignment unit 62 refers to the representative color number assigned to the peripheral pixels of the pixel to which the non-representative color number or the like is assigned. The representative color of the pixel is determined, and the representative color number is assigned to the pixel instead of the non-representative color number.
[0058]
The output of the representative color reassignment unit 62 is supplied to the representative color correction unit 63, and the representative color number assigned to the pixel of interest is corrected with reference to the representative color numbers assigned to the peripheral pixels.
[0059]
The output of the representative color correction unit 63 is supplied to the change point detection unit 12. Since the change point detector 12 and the edge detector 13 have been described in the first embodiment, they are omitted here.
[0060]
The edge signal detected by the edge detection unit 13 is input to the edge correction unit 64, and the edge signal is corrected. The edge signal corrected by the edge correction unit 64 is sent to the edge regeneration unit 65, where the edge signal is regenerated and output as an edge signal.
[0061]
(1) Configuration example of representative color allocation unit 61
a. First example of representative color assignment unit 61
FIG. 16 shows a representative color assignment unit 61 a which is a first example of the representative color assignment unit 61. In FIG. 16, L * a * b * The image signal is input to the distance calculation unit 22, and the representative color numbers sequentially generated from the representative color generation unit 21 are also input to the distance calculation unit 22. * a * b * The distance between the color represented by the image signal and the representative color is calculated and sent to the representative color neighborhood determining unit 71. Based on the representative color number supplied from the representative color generator 21 and the distance supplied from the distance calculator 22, the representative color neighborhood determination unit 71 * a * b * It is determined whether or not the pixel color represented by the image signal belongs to the vicinity of the representative color corresponding to the representative color number supplied from the representative color generation unit 21. If it is determined that it belongs to the vicinity of a certain representative color, the representative color number is output. If it is determined not to belong to the vicinity of any representative color, a non-representative color number is output. Examples of representative color numbers and non-representative color numbers are shown in FIG. In the example shown in FIG. 17, “0” to “7” are representative color numbers, and “9” is a non-representative color number.
[0062]
A configuration example of the representative color neighborhood determining unit 71 is shown in FIG. In this figure, the LUT 72 stores information for designating which range of colors to consider as the vicinity of the representative color for each representative color. More specifically, in the present embodiment, for each representative color, a color within a predetermined distance centered on the representative color is regarded as a neighboring color of the representative color. The distance representing the range (hereinafter referred to as the neighborhood distance) is stored in the LUT 72 for each representative color.
[0063]
Then, the representative color number i output from the representative color generator 21 shown in FIG. 16 is input to this LUT 72. As a result, the neighborhood distance E corresponding to the representative color number i i Is output from the LUT 72. Then, the distance F input from the distance calculation unit 22 (FIG. 6). p And the neighborhood distance E output from the LUT 72 i Are input to the comparator 73 for comparison. In the comparator 73, F p <E i In this case, it is determined that the target pixel belongs to the vicinity of the representative color corresponding to the representative color number i, and the determination result “1” is output. Conversely, F p ≧ E i In this case, it is determined that it does not belong to the vicinity, and the determination result “0” is output.
[0064]
The determination result of the comparator 73 corresponding to each representative color is sequentially input to the selection circuit 74, and the selection circuit 74 outputs the representative color number i corresponding to the determination result of the comparator 73 being “1”. . If all the outputs of the comparator 73 are “0”, it is determined that the target pixel does not belong to the vicinity of any representative color, and a non-representative color number (“9” in this example). ) Is output.
[0065]
b. Second example of representative color assignment unit 61
FIG. 19 shows a representative color assignment unit 61 b which is a second example of the representative color assignment unit 61. In this figure, L * a * b * The image signal is input to the distance calculation units 25-1 to 25-8. In addition, the plurality of representative color image signals stored in the representative color generation unit 24 are input to the distance calculation units 25-1 to 25-8, respectively. In the distance calculation units 25-1 to 25-8, L * a * b * Distance F between the color represented by the image signal and all representative color signals 1 ~ F 8 Are calculated in parallel and sent to the comparators 72-1 to 72-8, respectively.
[0066]
In the comparators 72-1 to 72-8, the inputted distance F 1 ~ F 8 And threshold values th10-1 to th10-8 are respectively compared. And the distance F for a certain representative color number i i <If threshold value th10-i holds, L * a * b * The color represented by the image signal belongs to the vicinity of the representative color of the representative color corresponding to the representative color number i, and the determination result “1” is output from the comparator 72-i. Conversely, distance F i If ≧ threshold th10-i, L * a * b * The color represented by the image signal does not belong to the vicinity of the representative color corresponding to the representative color number i, and the determination result “0” is output from the comparator 72-i. In this way, each of the comparators 72-1 to 72-8 makes L * a * b * Whether or not the color represented by the image signal is a color near each representative color is determined in parallel, and each determination result is sent to the representative color number determination unit 73.
[0067]
The representative color number determination unit 73 determines and outputs a representative color number based on the determination results sent from the comparators 72-1 to 72-8. For example, if only one of the determination results sent from the comparators 72-1 to 72-8 is "1" and the remaining is "0", the representative color corresponding to the determination result "1" A number is output. When all the determination results are “0”, a non-representative color number is output because it does not belong to the vicinity of any representative color. When the plurality of determination results are “1”, a number (quasi-representative color number) indicating that the determination result is an intermediate color between the plurality of representative colors with “1” is output. An example of the quasi-representative color number is shown in FIG. According to this example, when the determination result when the representative color is white is “1” and the determination result when the representative color is black is also “1”, an intermediate color between white and black The quasi representative color number “10” corresponding to is output by the representative color number determination unit 73.
[0068]
(2) Representative color reassignment unit 62
A configuration example of the representative color reassignment unit 62 is shown in FIG. The representative color number data, non-representative color number data, and quasi-representative color number data supplied from the representative color allocation unit 61 are each one line memory (line buffer) 81-1 to 81- for delaying the data by one line period. 4 and the latch circuits 82-1 to 82-20 for delaying the data by one pixel period, respectively. Then, with the configuration using these one-line memories and latch circuits, representative color number data corresponding to the pixels Pa to Py that are 5 × 5 pixels centered on the pixel of interest Pm as shown in FIG. Is obtained.
[0069]
Data corresponding to the pixels Pa to P1 and Pn to Py excluding the pixel Pm is sent to the selectors 83-1 to 83-24, and whether each data is representative color number data or non-representative color number data. It is selected whether it is quasi-representative color number data or not. Then, only representative color number data is sent to the pixel number measuring circuit 84.
[0070]
The pixel number measuring circuit 84 counts the representative color number data supplied from the selectors 83-1 to 83-24 for each representative color number, and how many pixels in the 5 × 5 pixels are the representative color number. For each representative color number. The maximum value selection circuit 85 selects the representative color number having the maximum number of pixels from the number of pixels for each representative color number measured by the pixel number measurement circuit 84, and outputs the representative color number.
[0071]
Further, the two-party maximum value selection circuit 86 determines whether the data corresponding to the target pixel Pm output from the latch circuit 82-10 is representative color number data, non-representative color number data, or quasi-representative color number. If it is quasi-representative color number data, it is determined which of the representative colors is an intermediate color, and from the number of pixels for each representative color number measured by the pixel number measuring circuit 84 A representative color having the largest number of pixels is selected from the plurality of representative colors, and the representative color number is output.
[0072]
The data of the target pixel Pm output from the latch circuit 82-10 is also input to the determination circuit 87. In the determination circuit 87, the input target pixel Pm is representative color number data, non-representative color number data, or quasi representative color number. It is determined whether the data is one of the data, and the determination result is supplied to the selector 88. The selector 88 is supplied with the output of the maximum value selection circuit 85, the output of the two-party maximum value selection circuit 86, the output of the latch circuit 82-10, and the output of the determination circuit 87. The maximum value is determined from the determination result of the determination circuit 87. Either the output of the selection circuit 85, the output of the two-party maximum value selection circuit 86, or the output of the latch circuit 82-10 is selected, and the result is output. That is, when the determination result of the determination circuit 87 is representative color number data, the output of the latch circuit 82-10, and when the determination result is non-representative color number data, the output of the maximum value selection circuit 85 and the determination result is quasi-representative. In the case of color number data, the output of the two-party maximum value selection circuit 86 is selected and the result is output.
[0073]
Next, the processing content of the representative color reassignment unit 62 will be described with a specific example. For example, assume that a data group as shown in FIG. 22B is input to the representative color reassignment unit 62. In this case, since the representative color number data “6” (blue) is input as data corresponding to the target pixel Pm, the determination circuit 87 determines that the data corresponding to the target pixel is representative color number data. The result is sent to the selector 88. As a result, the selector 88 selects the output of the latch circuit 82-10 and outputs “6”.
[0074]
Further, it is assumed that a data group as shown in FIG. 22C is input to the representative color reassignment unit 62. In this case, the pixel number measuring circuit 84 measures the number of pixels for each representative color number as shown in FIG. Then, the maximum value selection circuit 85 sends the representative color number “6” (blue) having the maximum number of pixels to the selector 88. Since the non-representative color number data “9” is input as data corresponding to the target pixel Pm, the determination circuit 87 determines that it is a non-representative color number, and the selector 88 outputs the maximum value selection circuit 85. And “6” is output.
[0075]
Further, it is assumed that a data group as shown in FIG. 22D is input to the representative color reassignment unit 62. In this case, the number of pixels for each representative color number is measured by the pixel number measuring circuit 84 as shown in FIG. Then, since the data corresponding to the target pixel Pm is “60” which is the quasi-representative color number, the two-party maximum value selection circuit 86 represents the representative corresponding to the representative color number “0”. The color is determined to be an intermediate color between the representative color corresponding to the representative color number “6”. Then, the representative color number “6” having the larger number of pixels among the representative color numbers “0” and “6” is selected and output. Then, since the data corresponding to the target pixel Pm is “60”, the determination circuit 87 determines that the data is quasi-representative color number data, and the selector 88 selects the output of the two-party maximum value selection circuit 86 accordingly. The representative color number “6” is output.
[0076]
(3) Representative color correction unit 63
Next, the representative color correcting unit 63 will be described with reference to FIG. In FIG. 23, the representative color number data supplied from the representative color reassignment unit 62 is delayed by the 1-line memories 91-1 and 91-2 and the latch circuits 92-1 to 92-6. Then, with the configuration composed of these one-line memory and latch circuit, representative color number data of each pixel constituting a block composed of 3 × 3 pixels is obtained. The number of representative color number data of each pixel constituting the 3 × 3 pixel block is measured by the pixel number measuring circuit 93 for each representative color number (that is, the number of pixels to which the representative color number is assigned).
[0077]
The maximum number number detection circuit 94 detects the representative color number having the maximum number of pixels from the number of pixels for each representative color number measured by the pixel number measurement circuit 93 and outputs the representative color number. Also, the pixel number extraction circuit 95 receives the number of pixels for each representative color number measured by the pixel number measurement circuit 93 and the representative color number of the target pixel (the central pixel of 3 × 3 pixels). The number of pixels having the same representative color number as the color number in 3 × 3 pixels is extracted (including the target pixel), and the number of pixels is output. The comparator 96 compares the input pixel number data with “1”, and outputs “1” when the pixel number is 1 and “0” when greater than 1 to the selection circuit 97.
[0078]
When the data supplied from the pixel number extraction circuit 95 is “1”, the selection circuit 97 determines that the pixel of interest is an isolated point and selects a representative color number supplied from the maximum number number detection circuit 94. The representative color number is output. When the data supplied from the pixel number extraction circuit 95 is “0”, the output of the latch circuit 92-3, that is, the data of the representative color number of the target pixel is selected and the representative color number is output. In this way, it is possible to remove the isolated point of the representative color number.
[0079]
(4) Edge correction unit 64
Next, the edge correction unit 64 will be described with reference to FIG. The edge correction unit 64 removes isolated points of the edge. In FIG. 24, the edge signal input from the edge detector 13 is blocked into 3 × 3 pixels by the 1-line memories 101-1 and 101-2 and the latch circuits 102-1 to 102-6. The data of 8 pixels excluding the central pixel among the 3 × 3 pixels that are formed into blocks are supplied to the OR circuit 103, the OR operation of 8 pixels is performed, and the result is output to the selection circuit 104. The selection circuit 104 outputs “0” when the data input from the OR circuit 103 is “0”, that is, when all eight neighboring pixels are “0”, and the signal input from the OR circuit 103 is “1”. In this case, data of the target pixel (a central pixel of 3 × 3 pixels) is output.
[0080]
(5) Edge regeneration unit 65
Next, the edge regeneration unit 65 will be described. The edge regeneration unit 65 generates and outputs a character region from the edge portion input from the edge correction unit 64. As a method for generating the region, for example, a window having a predetermined size (for example, 3 × 3 or 5 × 5) centered on the pixel of interest is used. If the pixel of interest (center pixel of the window) is an edge portion, the entire window is displayed. There is a method of using a character area. As another method, the connection of the edge portion is tracked within a predetermined size range (contour tracking), and when the edge portion forms a closed region (closed region), the inside of the edge portion and the closed region is formed. There is a method for extracting a character area.
[0081]
As described above, in this embodiment, the representative color of each pixel is obtained from the image signal of the input image, the representative color is corrected by referring to surrounding representative colors, and the representative color is corrected from the corrected representative color. Edge is detected by extracting the change point of the edge, detecting the edge part from the extracted change point, correcting the edge part by removing the isolated point of the detected edge part, and expanding the corrected edge part, etc. The image is separated, and the image area is separated using the regenerated edge. Therefore, although the scale of processing is larger than that in the first embodiment, more accurate region determination is possible.
[0082]
C. Third embodiment
A third embodiment of the present invention will be described with reference to FIG. In the description of this embodiment, components having the same functions as those described in the first embodiment and the second embodiment are denoted by the same reference numerals, and description thereof is omitted.
[0083]
The color signal output from the color signal conversion unit 3 is input to the color signal conversion unit 4 and also to the halftone dot region identification unit 111 and the image region separation unit 112.
[0084]
The halftone dot region identification unit 111 identifies a halftone dot region from the input image signal and outputs the identification result to the image region separation unit 112. As for the halftone dot identification method in the halftone dot region identification unit 111, there are a method by pattern matching and a method for identification from the periodicity of the pixel taking the peak value, but the details are not the gist of the present invention. The explanation is omitted here.
[0085]
In the image area separation unit 112, the image area separation of the halftone dot area and the image of the non-halftone area are determined based on the image signal input from the color signal conversion unit 3 and the halftone area signal input from the halftone area identification unit 111. Perform area separation processing.
[0086]
The image area separation signal output from the image area separation unit 112 is supplied to the spatial filter unit 6, the output tone correction unit 7, and the image output unit 8, and the character area / picture area in the halftone dot and the non-halftone dot area. An optimal reproduction process is performed for each of the character area and the pattern area, and an image is output.
[0087]
Next, the image area separation unit 112 will be described with reference to FIG. In FIG. 26, the image signal is input to the smoothing unit 121. The smoothing unit 121 smoothes the image signal in accordance with the halftone dot region signal input from the halftone dot region identification unit 111 and outputs the smoothed image signal to the representative color assignment unit 11.
[0088]
The representative color assignment unit 11 assigns a representative color to the input image signal. At this time, the representative color assignment method, the threshold value, and the like are switched in accordance with the halftone area signal.
[0089]
From the assigned representative color signal (representative color signal), a change point of the representative color is extracted by the change point extraction unit 12 and sent to the edge detection unit 13.
[0090]
The edge detection unit 13 detects an edge from the signal of the change point supplied from the change point extraction unit 12, and at that time, for edge detection parameters such as filter coefficients and pattern matching according to the dot area signal. The edge is detected by switching the pattern or threshold value, and an edge signal is output.
Since the representative color assignment unit 11, the change point extraction unit 12, and the edge detection unit 13 have been described in the first embodiment, detailed descriptions thereof are omitted here.
[0091]
The smoothing unit 121 smoothes the image signal when the input halftone area signal represents a halftone area. In the smoothing, a simple average or a weighted average of pixel values within a predetermined range (for example, 3 × 3 or 5 × 5) is calculated and used as the pixel value of the target pixel.
[0092]
As described above, in the present embodiment, the halftone dot region is identified, the parameter is switched depending on whether or not it is the halftone dot region, the representative color is obtained, and the change point of the representative color is extracted from the obtained representative color, Edges are detected while switching parameters from the change point of the representative color according to the halftone area signal. As a result, it is possible to extract not only the character area of the backgroundless portion but also the character area of the halftone dot area. By using these region determination results, highly accurate image reproduction processing can be performed, so that a higher-quality output image can be obtained.
[0093]
【The invention's effect】
As described above, according to the present invention, a representative color is assigned to each pixel constituting the input image, and the boundary that divides the input image into a plurality of image areas having different representative colors is detected. High-precision image area separation using color image signals effectively becomes possible. Further, in the present invention, since image area separation is performed based on the color change of each pixel, erroneous determination can be reduced, and a character portion having a lightness component equivalent to the background can be accurately extracted. It is.
[Brief description of the drawings]
FIG. 1 is a block diagram illustrating a configuration of an image processing apparatus according to a first embodiment of the present invention.
FIG. 2 is a block diagram showing a configuration of an image area separation unit 9 in the same embodiment.
FIG. 3 is a block diagram showing a configuration of a representative color assignment unit 11a in the same embodiment.
FIG. 4 is a block diagram showing a configuration of a distance calculation unit 22 in the same embodiment.
FIG. 5 is a block diagram showing a configuration of a representative color assignment unit 11b in the same embodiment.
FIG. 6 is a block diagram showing a configuration of a representative color assignment unit 11c in the same embodiment.
FIG. 7 is a block diagram showing a configuration of a representative color assignment unit 11d in the same embodiment.
FIG. 8 is a diagram showing the contents of an LUT 34 in the representative color assignment unit 11d.
FIG. 9 is a block diagram showing a configuration of a change point extraction unit 12 in the same embodiment.
FIG. 10 is a diagram for explaining the operation of the change point extraction unit 12;
FIG. 11 is a diagram showing a first example of an edge detection unit 13 in the same embodiment.
FIG. 12 is a block diagram showing a second example of the edge detection unit 13 in the same embodiment.
FIG. 13 is a block diagram showing a third example of the edge detector 13 in the embodiment.
FIG. 14 is a diagram illustrating the operation of the edge detection unit.
FIG. 15 is a block diagram illustrating a configuration of an image area separation unit according to a second embodiment of the present invention.
FIG. 16 is a block diagram showing a configuration of a first example of a representative color assignment unit 61 in the embodiment.
FIG. 17 is a diagram illustrating an example of representative color numbers and non-representative color numbers in the embodiment.
18 is a block diagram showing a configuration of a representative color neighborhood determining unit 71 in the representative color assigning unit 61. FIG.
FIG. 19 is a block diagram showing a configuration of a second example of the representative color assignment unit 61 in the embodiment.
FIG. 20 is a diagram illustrating an example of quasi-representative color numbers used in the second example.
FIG. 21 is a block diagram showing a configuration of a representative color reassignment unit 62 in the same embodiment.
FIG. 22 is a diagram illustrating an operation of the representative color reassignment unit 62;
FIG. 23 is a block diagram showing a configuration of a representative color correction unit 63 in the same embodiment.
FIG. 24 is a block diagram showing a configuration of an edge correction unit 64 in the same embodiment.
FIG. 25 is a block diagram showing a configuration of an image processing apparatus according to a third embodiment of the present invention.
FIG. 26 is a block diagram showing a configuration of an image area separation unit 112 in the same embodiment.
[Explanation of symbols]
11 ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ Representative color assignment unit
12 ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ Change point extraction unit
13 ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ ・ Edge detector
111 ············.

Claims (2)

原稿の入力カラー画像を構成する各画素に対し、複数の代表色のうち当該画素の色に近似した代表色を割当てる代表色割当手段と、
前記代表色割当手段によって各画素に割り当てられた代表色に基づき、前記入力カラー画像を各々代表色の異なった複数の像域に区切り、文字領域を抽出するための境界を検出する境界検出手段とを有することを特徴とする画像処理装置。
Representative color assigning means for assigning, to each pixel constituting the input color image of the document, a representative color that approximates the color of the pixel among a plurality of representative colors;
Based on the representative color assigned to each pixel by the representative color assigning means, the input color image delimit a plurality of image regions each different of the representative color, boundary detecting means for detecting a boundary for extracting character regions An image processing apparatus comprising:
画像処理装置が、
原稿の入力カラー画像を構成する各画素に対し、複数の代表色のうち当該画素の色に近似した代表色を割当てる代表色割当ステップと、
前記代表色割当ステップにおいて各画素に割り当てられた代表色に基づき、前記入力カラー画像を各々代表色の異なった複数の像域に区切り、文字領域を抽出するための境界を検出する境界検出ステップとを有することを特徴とする画像処理方法。
The image processing device
A representative color assigning step for assigning a representative color approximate to the color of the pixel among a plurality of representative colors to each pixel constituting the input color image of the document ;
Based on the representative color assigned to each pixel in the representative color assigning step, the input color image delimit a plurality of image regions each different of the representative color, boundary detection step of detecting a boundary for extracting character regions And an image processing method.
JP01468396A 1996-01-30 1996-01-30 Image processing apparatus and image processing method Expired - Fee Related JP4057662B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP01468396A JP4057662B2 (en) 1996-01-30 1996-01-30 Image processing apparatus and image processing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP01468396A JP4057662B2 (en) 1996-01-30 1996-01-30 Image processing apparatus and image processing method

Publications (2)

Publication Number Publication Date
JPH09214785A JPH09214785A (en) 1997-08-15
JP4057662B2 true JP4057662B2 (en) 2008-03-05

Family

ID=11868019

Family Applications (1)

Application Number Title Priority Date Filing Date
JP01468396A Expired - Fee Related JP4057662B2 (en) 1996-01-30 1996-01-30 Image processing apparatus and image processing method

Country Status (1)

Country Link
JP (1) JP4057662B2 (en)

Families Citing this family (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
KR20030026683A (en) * 2001-09-26 2003-04-03 한국전자통신연구원 The Apparatus and Method for Manufacturing Animation-Image Using Digital-Image
JP2005303953A (en) * 2004-04-16 2005-10-27 Fuji Xerox Co Ltd Image processing apparatus, image processing method and program
JP4623104B2 (en) * 2008-02-06 2011-02-02 コニカミノルタビジネステクノロジーズ株式会社 Image compression device
JP5312166B2 (en) * 2009-04-13 2013-10-09 キヤノン株式会社 Image processing apparatus, control method, and program
JP7049292B2 (en) * 2019-06-18 2022-04-06 キヤノン株式会社 Image processing equipment, image processing methods and programs

Also Published As

Publication number Publication date
JPH09214785A (en) 1997-08-15

Similar Documents

Publication Publication Date Title
US5331442A (en) Identification of graphic and character areas in color image processor
US7742194B2 (en) Image processing device, image processing method, image forming apparatus, image processing program, and storage medium
US20020114513A1 (en) Color image processing device and color image processing method
JPH05227425A (en) Improvement in automatic image segmentation
JPH0497657A (en) Area separating device for color picture
JP6740612B2 (en) Image processing apparatus, image processing method and program
JP4057662B2 (en) Image processing apparatus and image processing method
JP6676962B2 (en) Image processing apparatus, image processing method, and program
JP3334047B2 (en) IMAGE PROCESSING APPARATUS, IMAGE READING APPARATUS AND IMAGE FORMING APPARATUS EQUIPPED WITH THE SAME, IMAGE PROCESSING METHOD, AND COMPUTER-READABLE STORAGE MEDIUM CONTAINING IMAGE PROCESSING PROCEDURE
JP3754736B2 (en) Image processing apparatus and method
JP3495743B2 (en) Image processing apparatus and image processing method
JP3847565B2 (en) Image processing apparatus, image forming apparatus including the same, and image processing method
JPH07298074A (en) Image processing unit
JP3789243B2 (en) Image processing apparatus and method
JP6641982B2 (en) Image processing apparatus, image processing method, and program
JP4176053B2 (en) Image processing method, image processing apparatus, image forming apparatus, and computer program
JP2004088663A (en) Image processing apparatus, image forming apparatus, and image processing method
JP2000357237A (en) Image processor, image reading device and image forming device mounted with the processor, image processing method, and computer-readable storage medium stored with image processing procedure
JP4086537B2 (en) Image processing method, image processing apparatus, image forming apparatus, computer program, and recording medium
JPH1173503A (en) Picture processor
JP3262834B2 (en) Color image processing equipment
JP2003224718A (en) Image processing method and image processor
JP3262773B2 (en) Method and apparatus for detecting pixel color of color image
JP2003264693A (en) Image processing method, image processing apparatus, and image forming device provided with the same
JP2001144954A (en) Image processing unit and image processing method

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20040331

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20040413

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20040614

A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 20050105

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20050307

A911 Transfer to examiner for re-examination before appeal (zenchi)

Free format text: JAPANESE INTERMEDIATE CODE: A911

Effective date: 20050404

A912 Re-examination (zenchi) completed and case transferred to appeal board

Free format text: JAPANESE INTERMEDIATE CODE: A912

Effective date: 20050422

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20071214

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

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20111221

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20111221

Year of fee payment: 4

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

Free format text: PAYMENT UNTIL: 20121221

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20121221

Year of fee payment: 5

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

Free format text: PAYMENT UNTIL: 20131221

Year of fee payment: 6

LAPS Cancellation because of no payment of annual fees