JP2023000217A - Image processing apparatus, image processing method, and program - Google Patents
Image processing apparatus, image processing method, and program Download PDFInfo
- Publication number
- JP2023000217A JP2023000217A JP2021100911A JP2021100911A JP2023000217A JP 2023000217 A JP2023000217 A JP 2023000217A JP 2021100911 A JP2021100911 A JP 2021100911A JP 2021100911 A JP2021100911 A JP 2021100911A JP 2023000217 A JP2023000217 A JP 2023000217A
- Authority
- JP
- Japan
- Prior art keywords
- color
- image data
- color information
- transparent
- image processing
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
Images
Landscapes
- Facsimile Image Signal Circuits (AREA)
- Color Image Communication Systems (AREA)
- Color, Gradation (AREA)
- Image Processing (AREA)
Abstract
Description
本開示は、カラー画像データをモノクロ画像データに色変換する画像処理技術に関する。 The present disclosure relates to image processing technology for color-converting color image data into monochrome image data.
ドキュメントやプレゼンテーションの文書は、フルカラーで作成される場合であっても、モノクロ(単色)で印刷されることがある。このようにカラーで作成された文書をモノクロで印刷する場合、カラー画像データをモノクロ画像データに変換するモノクロ変換処理が必要となる。しかし、カラー画像データをモノクロ画像データに変換すると、カラー画像データでは異なる色が同じ又は似たグレー値に変換されることがあり、色の見分けがつかなくなり、弁別性が低下することがある。 Documents and presentation documents may be printed in monochrome (single color) even when they are created in full color. When printing a document created in color in this way in monochrome, monochrome conversion processing for converting color image data into monochrome image data is required. However, when color image data is converted to monochrome image data, different colors may be converted to the same or similar gray values in the color image data, making the colors indistinguishable and less distinguishable.
この点、特許文献1には、カラー画像データから変換されたグレー値を互いに離れた値に割り当てられるようにカラー画像データをモノクロ画像データに変換するテーブルを作成する技術が開示されている。
In this regard,
ところで、カラー画像データにおいて、オブジェクトが複数あり、このうち、あるオブジェクトが透過指定され、しかも、それが他のオブジェクトと重なる場合がある。このように透過指定オブジェクトが他のオブジェクトと重なる部分では、透過指定オブジェクトの色情報と、それが重なる他のオブジェクトの色情報とを用いて、重なる部分の色値を表す場合がある。重なる部分の色値は、RIP処理後、透過指定オブジェクトと、当該透過指定オブジェクトと重なる他のオブジェクトとで色値を合成して初めて定まる。このようなカラー画像データをモノクロ画像データに変換する際、特許文献1の技術を適用しても、重なる部分について、モノクロ画像データの色情報に変換できない場合があった。
By the way, in color image data, there are a plurality of objects, and among them, there is a case where a certain object is specified to be transparent and overlaps with another object. In such a portion where the transparency-designating object overlaps with another object, the color value of the overlapping portion may be expressed using the color information of the transparency-designating object and the color information of the other object on which it overlaps. The color value of the overlapping portion is determined only after the RIP processing, by synthesizing the color values of the transparency-designating object and another object that overlaps with the transparency-designating object. When converting such color image data into monochrome image data, even if the technique of
本開示は、透過指定オブジェクトが他のオブジェクトと重なる部分について、モノクロ画像データの色情報に変換させる技術を提供することを目的とする。 An object of the present disclosure is to provide a technique for converting a portion where a transparency-designated object overlaps another object into color information of monochrome image data.
本開示の一態様に係る画像処理装置は、カラー画像データをモノクロ画像データに変換する画像処理装置であって、前記カラー画像データに含まれるオブジェクトのうち、透過指定された透過オブジェクトの色情報と、当該透過オブジェクトと重なる他のオブジェクトの色情報とを用いて、当該透過オブジェクトが当該他のオブジェクトと重なる部分の色情報を算出する算出手段と、前記重なる部分について、前記算出手段で算出した前記色情報に基づいて、前記モノクロ画像データの色情報に変換する変換手段と、を有することを特徴とする。 An image processing device according to an aspect of the present disclosure is an image processing device that converts color image data into monochrome image data, and includes color information of a transparent object specified to be transparent among objects included in the color image data, and a calculating means for calculating color information of a portion where the transparent object overlaps with the other object by using color information of another object which overlaps with the transparent object; conversion means for converting the monochrome image data into color information based on the color information.
本開示によれば、透過指定オブジェクトが他のオブジェクトと重なる部分について、モノクロ画像データの色情報に変換させることができる。 According to the present disclosure, it is possible to convert a portion where a transparency-designated object overlaps another object into color information of monochrome image data.
以下、本開示を実施するための形態について図面を用いて説明する。ただし、この実施形態に記載されている構成要素はあくまで例示であり、発明の範囲をそれらに限定する趣旨のものではない。また、実施形態で説明されている構成要素の組み合わせのすべてが、課題を解決するための手段に必須のものとは限らず、種々の変形及び変更が可能である。同一の構成については、同じ符号を付して説明する。 Embodiments for implementing the present disclosure will be described below with reference to the drawings. However, the components described in this embodiment are merely examples, and are not intended to limit the scope of the invention. Moreover, not all combinations of the constituent elements described in the embodiments are essential to the means for solving the problems, and various modifications and changes are possible. The same configuration will be described with the same reference numerals.
<画像処理システム>
本実施形態に係る画像処理システムについて、図を用いて説明する。図1は、本実施形態に係る画像処理システムの概略構成例を示す図である。画像処理システム117は、画像形成装置101と、ホストPC119とを有する。
<Image processing system>
An image processing system according to this embodiment will be described with reference to the drawings. FIG. 1 is a diagram showing a schematic configuration example of an image processing system according to this embodiment. The
画像形成装置101は、本実施形態に係る画像処理装置の一例であり、例えば、スキャン機能やプリンタ機能等、複数の機能が一体化された複合機(MFP:Multi-Function Peripheral)である。画像形成装置101は、制御部110と、画像読取部108と、画像出力部109と、操作部118とを有する。制御部110は、画像形成装置101を統括的に制御しており、CPU105、ROM106、RAM107、HDD111、操作部I/F112、プリンタI/F113、スキャナI/F114、ネットワークI/F115を含む。一方で、ホストPC119もまた、CPU120、ROM121、RAM122、HDD123を有する。
The
CPU(Central Processing Unit)105は、ROM106に記憶されているプログラムをRAM107に展開し、それを実行することにより、この画像形成装置101の動作を制御している。RAM(Random Access Memory)107は、一時記憶メモリであり、画像データやプログラム等を一時的に記憶することが可能である。ROM(Read Only Memory)106は、この画像形成装置101を制御するためのパラメータや、本実施形態に係る制御を実現するためのアプリケーションやプログラムやOSなどを記憶している。HDD(ハードディスクドライブ)111は、スキャンした画像データなどを保存する。
A CPU (Central Processing Unit) 105 develops a program stored in a
また、操作部I/F112は、操作部118と制御部110とを接続するインタフェースである。操作部118は、タッチパネル機能を有するディスプレイ、キーボードやハードウェアキー等を含む。操作部118は、ユーザからの指示や設定の操作等の各種入力操作を受け付けるとともに、画像形成装置101の装置情報やジョブの進捗情報、各種ユーザインタフェース画面を表示するユーザインタフェース機能を担う。操作部118で受け付けた設定情報などは、操作部I/F112を介してRAM107に格納される。同様に、プリンタI/F113は、画像出力部109と制御部110とを接続するインタフェースである。画像出力部109で出力処理される画像データは、プリンタI/F113を介して制御部110から入力される。画像出力部109は、例えばプリンタである。スキャナI/F114は、画像読取部108と制御部110とを接続するインタフェースである。画像読取部108は、例えばスキャナであり、不図示の原稿台上の原稿や、ADF(自動給紙装置)から給紙された原稿の画像を読み取って画像データ(スキャン画像データ)を生成する。生成されたスキャン画像データは、スキャナI/F114を介して制御部110に入力される。
An operation unit I/
ネットワークI/F115は、制御部110(画像形成装置101)をLAN116に接続するインタフェースである。ネットワークI/F115は、LAN116上のホストPC119や不図示の外部装置(例えば、クラウドサーバ)に画像データや各種情報を送信したり、LAN116上のホストPC119や外部装置から画像データや各種情報を受信したりする。
Network I/F 115 is an interface that connects control unit 110 (image forming apparatus 101 ) to
CPU105がROM106に記憶されているプログラムをRAM107に展開し、それを実行することにより、次の機能が実現される。すなわち、画像読取部108が読み取った原稿の画像データを取得するスキャン機能や、画像出力部109を介して画像を用紙等の記録媒体やモニタなどへ出力する出力機能が実現される。
The
<画像形成装置のソフトウェア構成>
本実施形態に係る画像形成装置のソフトウェア構成例について、図を用いて説明する。図2は、ホストPC119からプリント機能を動作させる、画像形成装置101のソフトウェア構成例を示すブロック図である。画像形成装置101は、コマンド処理部103と画像処理部104を備える。各機能部は、画像形成装置101が有しているCPU105がROM106またはHDD111に記憶されているプログラムをRAM107に展開し、それを実行することにより制御される。または、図2の各部の一部または全部の機能をASICまたは電子回路等のハードウェアで実現してもよい。
<Software Configuration of Image Forming Apparatus>
A software configuration example of the image forming apparatus according to the present embodiment will be described with reference to the drawings. FIG. 2 is a block diagram showing a software configuration example of the
コマンド処理部103は、後述するホストPC119のプリンタドライバ202からの画像データを判別、解析、実行し、ラスタ画像と属性情報を作成しRAM107に保存する。なお、コマンド処理部103内の各処理部については後述する。画像処理部104は、RAM107に記憶されたラスタ画像と属性情報を読み出し、パラメータに従ってそのラスタ画像を最適化するための画像処理が行われる。
The
なお、画像処理部104内の各処理部については後述する。また、操作部118から通知された設定情報に基づいた画像処理も行われる。なお、カラーのラスタ画像(カラー画像)をグレーのラスタ画像(モノクロ画像)に変換する処理もここで行われる。
Each processing unit in the
<プリント処理>
本実施形態に係る画像処理装置によるプリント処理の流れについて、図2を用いて説明する。ホストPC119は、アプリケーション201と、プリンタドライバ202とがインストールされている。アプリケーション201、プリンタドライバ202はホストPC119のROM121に搭載されており、CPU105がROM106に記憶されているプログラムをRAM107に展開し、それを実行することにより制御される。
<Print processing>
The flow of print processing by the image processing apparatus according to this embodiment will be described with reference to FIG. The host PC 119 has an
ホストPC119では、アプリケーション201を使用して、ドキュメント文書やプレゼンテーション文書などの電子データが作成される。プリンタドライバ202は、画像形成装置101に、例えばカラー画像のデータなどを含む印刷データを出力して印刷させるためのドライバである。プリンタドライバ202で作成された印刷データは、画像形成装置101へ送られる。そして、この印刷データは、画像形成装置101のコマンド処理部103で処理され、その処理結果に応じて画像形成装置101の画像処理部104で画像処理が行われ画像出力部109で印字される。
The host PC 119 uses the
次に、画像形成装置101のコマンド処理部103の構成について説明する。コマンド処理部103は、コマンド判別部203と、コマンド解析部204と、コマンド実行部205とを有する。
Next, the configuration of the
コマンド判別部203は、ホストPC119から出力された印刷データのPDL種別を判別する。PDL(Page Description Language)はページ記述言語の略称である。また、PDL種別には、PostScript(PS)、PDF、PrinterCommandLanguage(PCL)などがある。プリンタドライバ202の設定を切り替えるか、または利用するプリンタドライバ202自体を切り替えることにより、PDL種別は切り替えられる。
A
コマンド解析部204は、PDL種別ごとに存在し、コマンド判別部203で特定されたPDL種別のコマンドの抽出及び解析を実行する。また、コマンド解析部204は、詳細につき後述する色値リストを作成する。
The
コマンド実行部205は、コマンド解析部204の解析結果に応じて描画し、RIP(ラスターイメージプロセッサー)でRIP処理を実行することでラスタ画像および属性の情報を記した属性情報を生成する。
A
画像処理部104の構成例について説明する。画像処理部104は、色変換処理部206と、フィルタ処理部207と、ガンマ処理部208と、ディザ処理部209とを有する。
A configuration example of the
色変換処理部206は、コマンド実行部205により生成されたラスタ画像および属性情報を用いて、RGB色空間からCMYK色空間への色変換の処理を行う。これにより、CMYKの画像データが生成される。
A color
フィルタ処理部207は、CMYKの画像データに対してシャープネス処理などのエッジ強調などを行う。なお、フィルタ処理部207は、RGBの画像データに対してエッジ強調を行ってもよい。この場合は、その後、色変換処理部206で色変換処理を行い、RGBの画像データからCMYKの画像データに変換する必要がある。
A
ガンマ処理部208は、画像データに対してプリンタの特性に応じて1次元のLUT(ルックアップテーブル)を用いたガンマ処理を行う。
A
ディザ処理部209は、ガンマ処理された画像データに対してディザ処理を行う。
A
図3(a)(b)は、図2で説明したコマンド解析部204、コマンド実行部205がコマンドを解析して描画しRIPすることでラスタ画像を生成した例を説明する図である。印刷データに含まれるコマンドには、描画コマンドと制御コマンドがあり、図3(a)に描画コマンド例を示し、図3(b)に図3(a)に示す描画コマンドに基づき描画された画像を示す。以下、コマンド解析部204がコマンドの解析を行い、コマンド実行部205が、コマンド解析部204の解析結果に応じて描画し不図示のRIP(ラスターイメージプロセッサー)を介してラスタ画像を生成するまでの例を挙げて説明する。まず、コマンドには描画コマンドと制御コマンドがあり、描画コマンド例について説明する。
FIGS. 3A and 3B are diagrams for explaining an example in which the
描画コマンドには、ジョブのカラーモードを設定するカラーモード設定コマンド、色を設定する色設定コマンドがある。さらに、オブジェクトを描画するオブジェクト描画コマンド、文字のサイズを設定する文字サイズ設定コマンド、文字のフォントを設定するフォント設定コマンド、文字を描画する文字描画コマンドがある。これら一連のコマンドの構成は、他のオブジェクト、文字列の場合も同様である。この他にも、座標および線の太さを設定するコマンド、イメージを描画するコマンド等も含まれるが、それらは省略している。なお、オブジェクトは、例えば、文字以外のイラストや図形、写真などの画像の領域である。 Drawing commands include a color mode setting command for setting the color mode of a job and a color setting command for setting colors. Further, there are object drawing commands for drawing objects, character size setting commands for setting character sizes, font setting commands for setting character fonts, and character drawing commands for drawing characters. The configuration of these series of commands is the same for other objects and character strings. In addition, commands for setting coordinates and line thickness, commands for drawing images, etc. are also included, but they are omitted. Note that the object is, for example, an area of an image other than characters, such as an illustration, a figure, or a photograph.
次に、図3(a)に示される描画コマンド310の内容を簡単に説明する。なお、以降の描画コマンド310における色値データは、8bit画像を前提とする。
Next, the content of the
描画コマンド310の2番目のコマンドであるカラーモード設定コマンド311「Set Page Color(CL)」は、以下のコマンドがカラーで展開されることを示している。
A color
3番目のコマンドである色設定コマンド312「Set Color(255,128,128)」は、RGB値がR=255、G=128、B=128の赤であることを示している。4番目のコマンドであるオブジェクト描画コマンド313「Draw Box(座標(X1,Y1),座標(X2,Y2) 塗りつぶし)」は、座標P11(X1,Y1)から座標P12(X2,Y2)にかけて長方形のオブジェクトを描画することを示している。その結果、図3(b)に示すように、画像320には、オブジェクト321がR=255、G=128、B=128の赤で描画される。
The third command, the
同様に、5番目のコマンドである色設定コマンド314「Set Color(153,153,255)」は、RGB値がR=153、G=153、B=255の青であることを示している。6番目のコマンドであるオブジェクト描画コマンド315「Draw Box(座標(X2,Y1),座標(X3,Y2) 塗りつぶし)」は、次の位置に長方形のオブジェクト322を描画することを示している。すなわち、オブジェクト描画コマンド315は、座標P21(X2,Y1)から座標P22(X3,Y2)にかけて長方形のオブジェクト322をオブジェクト321の隣に描画することを示している。その結果、図3(b)に示すように、画像320には、赤の長方形であるオブジェクト321の隣にて、オブジェクト322がR=153、G=153、B=255の青で描画される。
Similarly, the fifth command, the
次に、コマンド解析部204による描画コマンド310の解析に応じてコマンド実行部205が描画しRIPして生成されたラスタ画像320について説明を行う。
Next, a
描画コマンド310の説明で前述した3番目と4番目のコマンド312、313により描画されRIPされた画像が赤色の長方形を示すオブジェクト321である。5番目と6番目のコマンド314、315により描画されRIPされた画像が、青色の長方形を示すオブジェクト322である。
An
以上によりコマンド解析部204、コマンド実行部205についての説明を終える。
The explanation of the
前記コマンド解析部204、コマンド実行部205の説明は通常、ユーザによってカラーと設定された場合である。しかし、本実施形態に係る、弁別性を向上させる処理ではモノクロで指定されていてもカラーと同じ処理が行われ、その後、コマンド実行部205以降においてグレー変換が行われモノクロで出力される。
The description of the
<弁別性向上処理>
次に、コマンド解析部204、コマンド実行部205による弁別性向上処理S400について図を用いて説明する。図4は、弁別性向上処理の流れを示すフローチャートである。図4のフローチャートに示される一連の処理は、画像形成装置101のCPU105がROM106に記憶されているプログラムコードを読み出しRAM107に展開し実行することにより行われる。また、図4におけるステップの一部または全部の機能をASICまたは電子回路等のハードウェアで実現してもよい。なお、各処理の説明における記号「S」は、当該フローチャートにおけるステップであることを意味し、以後のフローチャートにおいても同様とする。
<Discriminability improvement processing>
Next, the distinguishability improvement processing S400 by the
S401では、コマンド解析部204は、色値リスト作成処理を実行する。具体的には、コマンド解析部204は、画像内の各オブジェクトに対して色設定コマンドで指定されている色値を抽出する。コマンド解析部204は、抽出した色値を色値リスト、例えば、図5(a)に示す色値リスト501に追加する。すなわち、色値リスト501には、抽出された色値であるRGB値が保持されることになる。そして、コマンド解析部204は、RGBの各値を重みづけた演算で得たグレー値を色値リストに追加し、画像内の全てのオブジェクトの色値およびグレー値を示す色値リスト501が完成すると、完成した色値リスト501をRAM107に保存する。RGB値をグレー値に変換する変換方法として、例えば、RGB値を0.299R+0.587G+0.114Bのように重み付けし合算して得られた値をRGB値に対応するグレー値とする、NTSC加重平均法とよばれる変換則がある。以下、NTSC変換と呼ぶ。変換則は、NTSC変換に限定されず、RGB値を均等に重みづけることでグレー値に変換する変換則や、その他に重みづけを変える変換則などを用いることも可能である。
In S401, the
S402では、コマンド解析部204は、弁別性向上処理を実行する。具体的には、コマンド解析部204は、RAM107に保存された色値リスト501にある全てのグレー値を弁別性がつくグレー値に修正する。すなわち、コマンド解析部204は、S401で作成された、修正後の色値リストを基に、オブジェクトに紐づく色情報それぞれを、対応する単色であるグレーの濃度情報に変換する変換テーブルを作成するともいえる。ここで、弁別性向上処理について、図を用いて説明する。図5は、RAMに保存された色値リスト例を示す図であって、図5(a)に修正前の色値リスト例を示し、図5(b)に修正後の色値リスト例を示す。例えば、図5(a)に示す色値リスト501では、オブジェクト321のグレー値が166である一方で、オブジェクト322のグレー値は165であり、これらオブジェクトのグレー値の差が小さいことから、弁別性がつかないと判定される。そこで、これらオブジェクトのグレー値に対して弁別性向上処理を行うことにより、例えば、図5(b)に示すように、オブジェクト321のグレー値が190に修正される一方、オブジェクト322のグレー値が120に修正されることになる。ここでグレー値の差と弁別性の関係性としてはグレー値の差が大きいほど弁別性が高いと言え、一方で、最低必要なグレー値の差としては、画像形成装置101の性能にもよるが、例えば15~20の差があれば弁別はつけることができる。
In S402, the
S403では、コマンド実行部205は、RIP処理を実行する。具体的には、コマンド実行部205は、PDLデータからラスタ画像データへの変換を行う。このとき、コマンド実行部205は、色値リスト501を参照しながら、RGBの値をグレー値に変換する。
In S403, the
以上のように、RIP処理が行われる前にRGBからグレーに変換する色値リストを作成しておき、弁別性が悪い場合には、弁別性が向上するようにRGBからグレーへ変換する色値リストを修正する。そして、RIP処理を行うときに、修正後の色値リストを参照しながら、RGB値をグレー値に変換することで、弁別性を向上させることができる。 As described above, a color value list for conversion from RGB to gray is created before RIP processing is performed. Fix the list. Then, when performing the RIP process, by converting the RGB values into gray values while referring to the corrected color value list, it is possible to improve the distinguishability.
<透過オブジェクト>
次に、透過オブジェクトについて説明する。背景のオブジェクト(以下、背景オブジェクトと呼ぶ)に別のオブジェクトを透過させて(以下、透過オブジェクトと呼ぶ)重ね合わせる方法は大きく分けて2つある。
<Transparent object>
Next, transparent objects will be described. There are roughly two methods of superimposing a background object (hereinafter referred to as a background object) by making another object transparent (hereinafter referred to as a transparent object).
1つ目の方法は、RIP処理を行うときに、背景オブジェクトに対して、指定されている透過率で透過オブジェクトを重みづける方法である。例えば、背景オブジェクト1が(R1,G1,B1)で、透過率がαで指定されている透過オブジェクト2が(R2,G2,B2)であるとき、合成後の(R3,G3,B3)は、以下に示す透過合成の式で表すことができる。
・R3=α×R1+(1-α)×R2
・G3=α×G1+(1-α)×G2
・B3=α×B1+(1-α)×B2
The first method is a method of weighting a transparent object with a specified transparency with respect to a background object when performing RIP processing. For example, when the
・R3=α×R1+(1−α)×R2
・G3=α×G1+(1−α)×G2
・B3=α×B1+(1−α)×B2
この演算により、背景オブジェクトの色と、透過オブジェクトの色と、指定された透過率とにより混ぜ合わせたRGB値が算出され、算出後のRGB値を用いることで透過オブジェクトが透過されたように見せることができる。 By this operation, the RGB values are calculated by mixing the color of the background object, the color of the transparent object, and the specified transparency, and the calculated RGB values are used to make the transparent object look transparent. be able to.
2つ目の方法は、RIP処理を行うときに、背景オブジェクトと透過オブジェクトとを画素単位で論理演算するROP(Raster Operation)と呼ばれる方法である。 The second method is a method called ROP (Raster Operation) in which a logical operation is performed on a background object and a transparent object on a pixel-by-pixel basis when RIP processing is performed.
この方法では、透過オブジェクトとして、透過率に応じて網目状に加工した画像を作成し、作成した画像を背景のオブジェクトと論理合成する。この論理合成によって、次に示すように見せることができる。即ち、網目の抜けた箇所では背景のオブジェクトの色が見え、網目部分では透過オブジェクトの色となることで、遠目から見ると1つ目の方法と同様に背景オブジェクトの色と透過オブジェクトの色が指定された透過率で混ぜ合わされたように見せることができる。2つ目の方法では、ROP演算後には、網目部と白く抜けている箇所とRGB値を2つ保持することになるが、見た目の色値は1つ目の方法と同じように算出することができる。すなわち、RIP処理を行うときに、透過率に応じた網目状のオブジェクトとしてRIP処理を行って背景オブジェクトと合成するのではなく、背景オブジェクトとの透過率で合成してRIP処理を行うことで1つ目の方法と同じように扱うことができる。そのため、本実施形態では上記2つの透過オブジェクトを同じように扱う。 In this method, a mesh-like image is created as a transparent object according to the transparency, and the created image is logically synthesized with the background object. By this logic synthesis, it can be shown as follows. In other words, the color of the background object can be seen in the part where the mesh is missing, and the color of the transparent object is seen in the mesh part, so that when viewed from a distance, the color of the background object and the color of the transparent object are the same as in the first method. Can be made to appear blended with a specified transmittance. In the second method, after the ROP calculation, two RGB values are retained, such as the mesh portion, the white void portion, and the RGB values, but the apparent color value is calculated in the same way as in the first method. can be done. That is, when RIP processing is performed, instead of performing RIP processing as a mesh-like object according to the transmittance and merging it with the background object, it is combined with the background object at the transmittance and then RIP processing is performed. It can be treated in the same way as the first method. Therefore, in this embodiment, the above two transparent objects are handled in the same way.
上記では、透過オブジェトの色値は、RIP処理を行うときに初めて確定される。一方で、先述した弁別性向上処理S400では、RIP処理を行う前に、オブジェクトの色値は変更される。そのため、弁別性向上処理S400により弁別性を向上させても透過オブジェクトがあると、RIP処理を行うときにさらに色値が変わるため、弁別性が低下してしまうなどの弊害を発生してしまう場合がある。 In the above, the color values of transparent objects are determined only when performing RIP processing. On the other hand, in the above-described distinguishability improvement processing S400, the color values of the object are changed before performing the RIP processing. Therefore, even if the distinguishability is improved by the distinguishability improvement processing S400, if there is a transparent object, the color value will change further when the RIP process is performed, which may cause a problem such as a decrease in distinguishability. There is
ここで、透過オブジェクトを含む場合の弁別性向上処理について、図3(c)(d)を用いて説明する。なお、図3(c)に示す2番目と3番目の描画コマンド331、332は、図3(a)に示す2番目と3番目の描画コマンド311、312と同じであり、その説明を割愛する。 Here, distinguishability improvement processing when a transparent object is included will be described with reference to FIGS. 3(c) and 3(d). Note that the second and third drawing commands 331 and 332 shown in FIG. 3C are the same as the second and third drawing commands 311 and 312 shown in FIG. .
図3(c)に示す4番目のコマンドであるオブジェクト描画コマンド333「Draw Box(座標(X1,Y1),座標(X4,Y2) 塗りつぶし)」は、次に示すような位置にオブジェクトを描画することを示している。すなわち、座標P31(X1,Y1)から座標P32(X4,Y2)にかけて長方形のオブジェクトを描画することを示している。その結果、図3(c)の描画コマンド330の3番目と4番目のコマンド332、333によれば、図3(d)に示すように、画像340には、オブジェクト341がR=255、G=128、B=128の赤で描画される。
The
一方で、5番目のコマンドである色設定コマンド334「Set Color(0,0,255)」は、RGB値がR=0、G=0、B=255の青であることを示している。描画コマンド330の6番目のコマンドである透過コマンド335「Set Composite(60%)」は、透過率を60%に指定していることを示している。7番目のコマンドであるオブジェクト描画コマンド336「Draw Box(座標(X5,Y1),座標(X3,Y2) 塗りつぶし)」は、座標P41(X5,Y1)から座標P42(X3,Y2)にかけて長方形のオブジェクトを描画することを示している。その結果、図3(c)の描画コマンド330の5番目から7番目のコマンド334、335、336によれば、図3(d)に示すように、画像340には、オブジェクト342が60%透過したR=0、G=0、B=255の青で描画される。そのため、オブジェクト341とオブジェクト342とで重なる部分343では、オブジェクト342の色値と、オブジェクト342の色値とが、透過率60%で合成された色値となる。
On the other hand, the fifth command, the color setting command 334 “Set Color (0, 0, 255)” indicates that the RGB values are blue with R=0, G=0, and B=255. A
このような画像の場合、弁別性向上処理により作成される色値リストは描画コマンド上、2つのオブジェクトしかないため、図6(a)に示すように、2つの画像341、342に対応した2つの色値が格納される。画像341にて、R=255、G=128、B=128であることから、NTSC変換では、グレー値が166となる。一方で、画像342にて、R=0、G=0、B=255であることから、NTSC変換では、グレー値が29となる。そのため、色値リスト上では、グレー値はそれぞれ166と29となり、差が20より大きくなるため、すでに弁別性があると判断することができる。
In the case of such an image, the color value list created by the distinguishability improvement process has only two objects in terms of drawing commands. Therefore, as shown in FIG. Contains one color value. In
しかしながら、実際には、画像342が透過指定されているため、背景が白地(R,G,B)=(255,255,255)である箇所では、前記透過合成の式より以下のように算出される。ただし、RGBの各値は、小数点について四捨五入することとする。
R=0.6×255+0.4×0=153
G=0.6×255+0.4×0=153
B=0.6×255+0.4×255=255
すなわち、(R,G,B)=(153,153,255)となる。NTSC変換によって得られたグレー値は165となる。このように、画像342のグレー値は、165であり、画像341のグレー値の166とほぼ同じ値になっているため、画像342と画像341とは実際には弁別性がないことになる。ゆえに、本来は弁別性を向上させなくてはならないにもかかわらず、弁別性の向上ができなかったことになってしまう。
However, in reality, since the
R = 0.6 x 255 + 0.4 x 0 = 153
G = 0.6 x 255 + 0.4 x 0 = 153
B = 0.6 x 255 + 0.4 x 255 = 255
That is, (R, G, B)=(153, 153, 255). The gray value obtained by NTSC conversion is 165. Thus, since the gray value of
次に、色値リストに色値を格納する際、透過コマンドをみて、背景が白地であると想定して図6(b)に示すように、RGBの各値を、(R,G,B)=(153,153,255)と予め設定しておくこともできる。その場合は、上述した弁別性向上処理の例と同じなので、図6(c)に示すように、画像341のグレー値は190となり、画像342のグレー値は120となる。しかし、背景の画像341と透過の画像342とが重なった箇所の画像343は、RIP処理を行った後に合成されるため、前記透過合成の式より以下のように算出される。ただし、RGBの各値は、小数点について四捨五入することとする。
R=0.6×255+0.4×0=153
G=0.6×128+0.4×0=77
B=0.6×128+0.4×255=179
すなわち、(R,G,B)=(153,77,179)となる。NTSC変換によって得られたグレー値は111となる。このように、画像343のグレー値は、111であり、画像342のグレー値の120と近い値になっているため、画像342と画像343とは弁別性が悪いことになる。
Next, when storing the color values in the color value list, assuming that the background is a white background by looking at the transparency command, each value of RGB is set to (R, G, B )=(153, 153, 255). In that case, the gray value of the
R = 0.6 x 255 + 0.4 x 0 = 153
G = 0.6 x 128 + 0.4 x 0 = 77
B = 0.6 x 128 + 0.4 x 255 = 179
That is, (R, G, B)=(153, 77, 179). The gray value obtained by NTSC conversion is 111. As described above, the gray value of the
このように、弁別性向上処理は、透過オブジェクトが背景オブジェクトと合成される前の色値のグレー値で弁別性を向上させても、その後に透過オブジェクトが合成されることで弁別性が悪くなってしまうことがある。また、背景オブジェクトが予め白地であると断定して色値を算出したとしても、背景が白地でなければ、合成前に弁別性を向上させる手法と同様、弁別性が悪くなってしまうことがある。 In this way, in the distinguishability improvement processing, even if the distinguishability is improved by the gray value of the color value before the transparent object is combined with the background object, the distinguishability deteriorates after the transparent object is combined. Sometimes I end up In addition, even if the background object is preliminarily determined to be white and the color value is calculated, if the background is not white, the distinguishability may be degraded in the same way as the technique for improving the distinguishability before synthesis. .
<実施形態1>
そこで、上記のように透過オブジェクトがあっても弁別性向上処理を所望の通り動作させるためには、色値リスト作成時に透過オブジェクトがある場合に、透過オブジェクトを背景と合成した色値を予め求めておく必要がある。
<
Therefore, in order to operate the distinguishability improvement processing as desired even if there is a transparent object as described above, if there is a transparent object when creating the color value list, the color value that combines the transparent object with the background is obtained in advance. need to keep
そのため、弁別性向上処理の中で色値リスト作成処理S401において、透過オブジェクトの有無を判定し、透過オブジェクトがある場合は、その背景にあたるオブジェクトを探索する。そして、透過オブジェクトと背景オブジェクトと透過率とから合成後の色値を算出し、算出結果を基に色値リストに対し追加処理および修正処理を行う。そのうえで、弁別性向上処理S402を行うことで解決を図る。 Therefore, in the color value list creation processing S401 of the distinguishability improvement processing, it is determined whether or not there is a transparent object. Then, a color value after composition is calculated from the transparent object, the background object, and the transmittance, and addition processing and correction processing are performed on the color value list based on the calculation result. After that, the distinguishability improvement processing S402 is performed to solve the problem.
<色値リスト作成処理>
以下、本実施形態に係る色値リスト作成処理について図を用いて説明する。図7は、色値リスト作成処理の流れを示すフローチャートである。図7のフローチャートに示される一連の処理は、画像形成装置101のCPU105がROM106に記憶されているプログラムコードを読み出しRAM107に展開し実行することにより行われる。また、図7におけるステップの一部または全部の機能をASICまたは電子回路等のハードウェアで実現してもよい。なお、探索対象にオブジェクトが存在するものとする。また、S401の処理が開始されると、原稿に対するオブジェクトの探索が開始されるものとする。
<Color value list creation processing>
The color value list creating process according to this embodiment will be described below with reference to the drawings. FIG. 7 is a flowchart showing the flow of color value list creation processing. A series of processes shown in the flowchart of FIG. 7 is performed by the
初めに、S1001では、コマンド解析部204は、探索したオブジェクトについて色値、オブジェクトの位置、透過オブジェクトであるか否かを示す情報を抽出する。オブジェクトの色値を示す色情報は色設定コマンドから抽出される。オブジェクトの位置を示す位置情報は、オブジェクト描画コマンドから抽出される。さらに、透過オブジェクトであるか否かを示す透過情報は透過コマンドから抽出される。そして、コマンド解析部204は、処理対象のオブジェクトに関して抽出した各種情報を、オブジェクトと、当オブジェクトの色情報、位置情報および透過情報との対応関係を示す色値リストに追加する。
First, in S1001, the
次に、S1002では、コマンド解析部204は、原稿中の全てのオブジェクトの色値・透過情報・位置を抽出したか否かを判定する。例えば、S1001の処理対象が図3(c)に示すコマンド336であり、次のコマンドラインが”Page End”を含む場合、全てのオブジェクトに関し色情報、位置情報および透過情報を抽出したと判定し、処理がS1004に移行される。他方、S1001の処理対象が図3(c)に示すコマンド333であり、次のコマンドラインが”Page End”を含まない場合、全てのオブジェクトに関し色情報、位置情報および透過情報を未だ抽出していないと判定し、処理がS1003に移行される。そして、S1003にて、コマンド解析部204は、処理対象として次のオブジェクトを設定した後、処理がS1001に移行され、S1001にて、新たな処理対象である次のオブジェクトに対する処理が実行される。他方、全てのオブジェクトの色値・透過情報・位置を抽出したとの判定結果を得た場合(S1002のYES)、処理がS1004へ移行される。
Next, in S1002, the
S1004では、原稿中に透過オブジェクトがあるか否かを判定する。ここでは、S1001で作成した色値リスト中の透過情報を参照することで判定する。透過オブジェクトがないとの判定結果を得た場合(S1004のNO)、図7に示す色値リスト作成処理を終える。他方、透過オブジェクトがあるとの判定結果を得た場合(S1004のYES)、処理がS1005へ移行される。 In S1004, it is determined whether or not there is a transparent object in the document. Here, the determination is made by referring to the transparency information in the color value list created in S1001. If it is determined that there is no transparent object (NO in S1004), the color value list creation process shown in FIG. 7 ends. On the other hand, if it is determined that there is a transparent object (YES in S1004), the process proceeds to S1005.
S1005では、コマンド解析部204は、背景を検知する処理を実行する。すなわち、コマンド解析部204は、透過オブジェクトの背景となるオブジェクトを探索する。先ず、コマンド解析部204は、色値リストに抽出した透過オブジェクトの位置とそのほかのオブジェクトの位置とを比べ、重なるか否かを一つ一つチェックする。そして、この条件に該当するオブジェクトがあり、透過オブジェクトと重なる他のオブジェクトがあるとのチェック結果を得ると、コマンド解析部204は、該当するオブジェクトを背景オブジェクトとして抽出する。他方、この条件に該当するオブジェクトが無く、透過オブジェクトと重なる他のオブジェクトが無いとのチェック結果を得ると、コマンド解析部204は、原稿の白地が背景であると判断する。ここでは、2つ以上のオブジェクトが背景となることも想定される。
In S1005, the
S1006では、コマンド解析部204は、S1005で抽出された背景オブジェクトと透過オブジェクトの透過情報から合成後の色値を算出する。背景オブジェクトが複数ある場合は、複数の色値が算出されることになる。
In S1006, the
S1007では、コマンド解析部204は、S1006で算出された値を、S1001でオブジェクトに関する情報が追加された色値リストに対して、追加および修正を行う。
In S1007, the
S1008では、コマンド解析部204は、処理対象の色値リストに存在する全ての透過オブジェクトの色値に対して追加処理および修正処理を実行したか否かを判定する。処理対象の色値リストに存在する全ての透過オブジェクトの色値に対する追加処理および修正処理が未だ終わっておらず、未処理の透過オブジェクトの色値があるとの判定結果を得た場合(S1008のNO)、処理がS1009へ移行される。そして、S1009にて、コマンド解析部204は、処理対象の色値リストに存在し、未処理の透過オブジェクトの中から次の処理対象となる透過オブジェクトを特定する。次の処理対象が特定されると、処理がS1005を戻され、S1009で特定した新たな処理対象の透過オブジェクトに対してS1005の処理が行われる。
In S1008, the
一方、処理対象の色値リストに存在する全ての透過オブジェクトの色値に対する追加処理および修正処理が行われたとの判定結果を得た場合(S1008のYES)、図8に示す色値リストの作成処理のフローを終える。 On the other hand, if it is determined that the color values of all transparent objects in the color value list to be processed have been added and corrected (YES in S1008), the color value list shown in FIG. 8 is created. End the processing flow.
ここで、S1005の透過オブジェクトの背景となるオブジェクトの探索と、S1006の透過オブジェクトと背景オブジェクトとで合成した色値の算出と、S1007の色値リストの修正の3点について、図を用いて説明する。図8は、図3(c)に対応した画像に関する情報を基にした色値リスト例を示す図である。図8(a)に抽出したオブジェクトの色情報を含む色値リストを示し、図8(b)に重なるオブジェクトの色情報を含む色値リストを示し、図8(c)に図8(b)の色値リストの色情報に対して弁別性向上処理を行った後の色情報を含む色値リストを示す。 Here, the following three points will be described with reference to the drawings: searching for an object that serves as the background of the transparent object in S1005, calculation of the color value combined with the transparent object and the background object in S1006, and correction of the color value list in S1007. do. FIG. 8 is a diagram showing an example of a color value list based on information about an image corresponding to FIG. 3(c). FIG. 8(a) shows a color value list including the color information of the extracted object, FIG. 8(b) shows the color value list including the color information of the overlapping object, and FIG. 8(c) shows the color value list of FIG. 10 shows a color value list including color information after the color information in the color value list of 1 is subjected to discrimination improvement processing.
S1005では、コマンド解析部204は、色値リストを参照して透過率が0より大きい値が設定されているオブジェクトを透過オブジェクトと判定する。コマンド解析部204は、例えば、図8(a)に示す色値リスト501を参照すると、透過率として60が設定されているオブジェクト(入力画像)342を透過オブジェクトであると判定する。
In S<b>1005 , the
透過オブジェクト342の始点が(X5,Y1)であり、終点が(X3,Y2)であり、そのとき、他のオブジェクト341の始点が(X1,Y1)であり、終点が(X4,Y2)である。横方向を示すX座標に関し、X1<X5<X4<X3の関係があり、縦方向のY座標は等しいので重なっているのはX5からX4の間であり、X4からX3は白地が背景であることがわかる。なお、X5からX4の間の箇所がオブジェクト343である。
The start point of the
次に、S1006では、コマンド解析部204は、透過オブジェクト342と背景オブジェクトとで色値を合成する。
Next, in S1006, the
初めに、透過オブジェクト342に対する背景オブジェクトがオブジェクト341である箇所では先の例より(R,G,B)=(153,77,179)と算出される。透過オブジェクト342に対する背景オブジェクトが白地である箇所では先の例より(R,G,B)=(153,153,255)と算出される。ここで、どちらの箇所も、合成後なので透過率が0に変更される。
First, where the background object for the
S1007では、コマンド解析部204は、S1005およびS1006で求めた情報を用いて、色値リストに対して追加・修正処理を実行する。コマンド解析部204は、S1005およびS1006で求めた情報を基に、例えば、色値リスト501に対して追加・修正処理を実行して、図8(b)に示すように、処理後の色値リスト501を生成する。
In S1007, the
以上により色値リストの作成処理の説明を終える。 This concludes the description of the color value list creation processing.
色値リストに透過オブジェクトがあった場合、背景にあたるオブジェクトを探索し、RIP処理を行う前に合成後の色値を算出する。そのため、その後の弁別性向上処理S402でグレー値の濃淡を示す濃度情報を、弁別性を持つように適切に調整する(修正する)ことができる。調整後のグレー値は、図8(c)に示すように、オブジェクト341で210となり、オブジェクト342で160となり、オブジェクト343で100となる。よって、全てのオブジェクト間のグレー値の差が20以上となり弁別性のある色値リスト501を生成できることがわかる。これは、変換後のモノクロ画像データにおける色が識別可能となるように、モノクロ画像データ(グレースケール画像データ)の色情報に変換しているといえる。
If there is a transparent object in the color value list, an object corresponding to the background is searched, and the color value after composition is calculated before performing the RIP process. Therefore, the density information indicating the gradation of the gray value can be appropriately adjusted (corrected) so as to have distinctiveness in subsequent distinguishability improvement processing S402. The gray value after adjustment is 210 for
すなわち、本実施形態では、透過オブジェクトの背景にあたるオブジェクトを各オブジェクトの位置を調べることで原稿内のオブジェクトの中から背景にあたるオブジェクトを探索し、透過オブジェクトと背景オブジェクトから合成後に表れる色値を算出した。例えば、図8のS1004で透過オブジェクトがある場合、S1005にて2つの長方形を例に挙げて透過オブジェクトの背景となるオブジェクトを探索し、S1006にて重なりを算出した色値をS1007でリストに追加・修正を行った。 That is, in this embodiment, the object corresponding to the background of the transparent object is searched for the object corresponding to the background from among the objects in the document by checking the position of each object, and the color value that appears after compositing from the transparent object and the background object is calculated. . For example, if there is a transparent object in S1004 of FIG. 8, two rectangles are used as an example in S1005 to search for the background object of the transparent object.・Fixed.
以上説明した通り、本実施形態によれば、カラーデータ(カラー画像データ)をグレーデータ(モノクロ画像データ)に変換する際に、次に示す色値リストを生成できる。すなわち、原稿内に透過指定されたオブジェクトのように背景のオブジェクトと合成するオブジェクトがある場合、次の処理を行うことで弁別性を向上させた色値リストを生成できる。すなわち、RIP処理を行う前に、背景のオブジェクトと合成した色値を予め算出する。そして、その色値を加味して濃淡をつけることで、弁別性を向上させることが可能になる。これにより、画像出力部109は、印刷データを基づき、弁別性を向上させたモノクロ印刷を行うことができる。
As described above, according to this embodiment, the following color value list can be generated when color data (color image data) is converted into gray data (monochrome image data). That is, when there is an object to be combined with a background object, such as an object designated as transparent, in the document, a color value list with improved discrimination can be generated by performing the following processing. That is, before performing the RIP process, the color value synthesized with the background object is calculated in advance. Then, it is possible to improve the distinguishability by adding the color values and adding shading. Accordingly, the
なお、上述したように原稿中に透過オブジェクトがある場合、背景にあたるオブジェクトを探索するが、透過オブジェクトが多いと、探索に多大な時間を要することが想定される。また、8bit画像データを前提とすればグレー値は0-255までの値しかとりえないため、異なる色のオブジェクト数が多い場合は弁別性を向上させるにも限界がある。例えば、原稿中に異なる色が256色あった場合、一つ一つの色はそれぞれ0,1,2,…,255のグレー値をとるため、グレー値の差は1となり弁別性があるとは言えない。 As described above, if there is a transparent object in the document, the object corresponding to the background is searched for. In addition, assuming that 8-bit image data is used, gray values can only take values from 0 to 255. Therefore, if there are many objects of different colors, there is a limit to the improvement in distinguishability. For example, if there are 256 different colors in the document, each color has a gray value of 0, 1, 2, . I can not say.
ただし、このように異なる色のオブジェクト数が多く、所定数以上である場合は、カラーで出力されたとしても原稿内に異なる色が無数にありユーザにとってはそもそも弁別性を上げたいという意図は少ないと考えられる。 However, when the number of objects with different colors is large and is equal to or greater than a predetermined number, there are countless different colors in the document even if it is output in color, and the user has little intention of increasing the distinguishability in the first place. it is conceivable that.
そこで、透過オブジェクトの数が予め決められた所定数以上である場合は、上述の色値リストの追加・修正を行わず終了することで弁別性の向上に時間をかけすぎることを防止する態様について、図を用いて説明する。図9は、色値リスト作成処理の流れを示すフローチャートである。なお、S2001~S2004、S2006~S2010は、それぞれS1001~S1004、S1005~S1009と同じ処理であり、詳細な説明を割愛する。先述したステップと同じ構成でちがいはS2005のみであるのでS2005のみを説明する。図9のフローチャートに示される一連の処理も、画像形成装置101のCPU105がROM106に記憶されているプログラムコードを読み出しRAM107に展開し実行することにより行われる。また、図9におけるステップの一部または全部の機能をASICまたは電子回路等のハードウェアで実現してもよい。なお、探索対象にオブジェクトが存在するものとする。
Therefore, when the number of transparent objects is equal to or greater than a predetermined number, the process ends without adding or modifying the color value list, thereby preventing the process from taking too much time to improve the distinguishability. , will be described with reference to the drawings. FIG. 9 is a flowchart showing the flow of color value list creation processing. Note that S2001 to S2004 and S2006 to S2010 are the same processes as S1001 to S1004 and S1005 to S1009, respectively, and detailed description thereof will be omitted. Since the configuration is the same as that of the steps described above and the only difference is S2005, only S2005 will be described. A series of processes shown in the flowchart of FIG. 9 is also performed by the
S2005では、コマンド解析部204は、原稿中に透過オブジェクトが所定数のN個以上あるか否かを判定する。所定数Nは、例えば、グレー値の差分の上限値の「20」を採用した場合には12としてもよいし、グレー値の差分の下限値の「15」を採用した場合には17としてもよいが、これに限定されない。ここでは、作成した色値リスト中の透過オブジェクトの個数をカウントし、予め定められた所定数のN個以上であるか否かを判定する。透過オブジェクトが所定数のN個以上であるとの判定結果を得た場合(S2005のYES)、図9に示す色値リスト作成処理のフローを終える。他方、透過オブジェクトが所定数のN個未満であるとの判定結果を得た場合(S2005のNO)、処理がS2006に移行される。
In S2005, the
以上説明した通り、原稿中の透過オブジェクトの個数に基づき、透過オブジェクトと背景オブジェクトの合成した色値を加味して色値リストを修正するか否かを切り替え、それにより背景のオブジェクトを探索する処理時間を削減することが可能になる。 As described above, based on the number of transparent objects in the original, the process of searching for the background object by switching whether or not to modify the color value list in consideration of the combined color value of the transparent object and the background object. time can be reduced.
また、今回は透過オブジェクトの数だけで判断したが、透過オブジェクトの数に他のオブジェクトの数を加味してもよい。 Also, although the number of transparent objects alone is used for determination this time, the number of other objects may be added to the number of transparent objects.
<実施形態2>
本実施形態では、透過オブジェクトと原稿内の各オブジェクトが重なるか否かについて描画の位置から判定できないが、透過オブジェクトの背景となるオブジェクトを簡易的に探索し、色値リストを追加および修正する態様ついて説明する。
<
In this embodiment, it is not possible to determine from the drawing position whether or not the transparent object and each object in the document overlap. explain about.
先ず、透過オブジェクトの背景となるオブジェクトを探索する際に、オブジェクトの位置情報から、明らかに接していないとわかるものは背景ではないと判定する。一方で、それ以外は透過オブジェクトと一部重なる背景オブジェクトである可能性が高いと判定し、想定される色の組み合わせを全て色値リストに追加する。以下、詳細について図10の処理フローを用いて説明する。図10は、色値リスト作成処理の他例の詳細な流れを示すフローチャートである。なお、図10のフローは、図7のS1003までと同じなのでS1004での透過オブジェクトがあるか否かの判定でYESとなった後のステップであって、図7のS1005以降に相当する処理の流れについて説明する。また、実施形態1と同じ構成については説明を省略する。図10のフローチャートに示される一連の処理も、画像形成装置101のCPU105がROM106に格納されているプログラムコードを読み出しRAM107に展開し実行することにより行われる。
First, when searching for an object to be the background of a transparent object, it is determined from the position information of the object that it is not the background if it is clearly not in contact with the object. On the other hand, other than that, it is determined that there is a high possibility that it is a background object that partially overlaps with the transparent object, and all possible color combinations are added to the color value list. Details will be described below using the processing flow of FIG. 10 . FIG. 10 is a flowchart showing a detailed flow of another example of color value list creation processing. Note that the flow of FIG. 10 is the same as the steps up to S1003 in FIG. 7, so it is the step after YES in the determination of whether or not there is a transparent object in S1004, and is the step corresponding to the processing after S1005 in FIG. Explain the flow. Also, the description of the same configuration as that of the first embodiment is omitted. A series of processes shown in the flowchart of FIG. 10 is also performed by the
まず、S3001では、コマンド解析部204は、対象となる透過オブジェクトの描画位置を示す位置情報を抽出する。例えば、透過オブジェクトが長方形であれば、位置情報として透過オブジェクトの始点および終点を抽出し、透過オブジェクトが円であれば、位置情報として透過オブジェクトの中心および半径を抽出する。
First, in S3001, the
S3002では、コマンド解析部204は、対象となる透過オブジェクトと比較するオブジェクトの描画位置を示す位置情報を抽出する。
In S3002, the
S3003では、コマンド解析部204は、対象となる透過オブジェクトの位置とS3002で抽出したオブジェクトの位置が近いか否かを判定する。ここで、背景オブジェクトの検知方法について図を用いて説明する。図11は背景オブジェクトの検知例を示す図である。S3003では厳密に重なるか否かを判定するのではなく、例えば、図11に示すように、透過オブジェクトの長方形Aの位置がオブジェクトの円Bの位置からX、Y方向それぞれLの距離だけ離れているか簡易的な検証でよい。前記Lは、例えば、10ピクセルから20ピクセルの大きさとしてよいが、これに限定されない。図11では、透過オブジェクトの長方形A(始点、終点)=((X1,Y1)、(X2,Y2))であり、オブジェクトの円B(中心、半径)=((X3,Y3)、r)であり、点線が長方形AのX方向、Y方向にLだけ大きいことを示しているとする。ここでは、円Bの中心(X3,Y3)から(X2+L、Y2+L)までの距離がrより大きいか否かを調べればよい。
In S3003, the
ここでは明らかに離れているものを重ならないと判定できればよく、それ以外は重なると判断する。そして、近いとの判断結果を得た場合(S3003のYES)、処理がS3004に移行される。他方、重ならないと判断されて、近くないとの判断結果を得た場合(S3003のNO)、処理がS3009に移行される。 Here, it suffices if it can be judged that objects that are clearly separated do not overlap, and other objects are judged to overlap. Then, if the result of the judgment is that it is close (YES in S3003), the process proceeds to S3004. On the other hand, if it is determined that they do not overlap and the determination result is that they are not close (NO in S3003), the process proceeds to S3009.
S3004では、コマンド解析部204は、比較するオブジェクトが透過オブジェクトを包含しているか否か判定する。すなわち、比較するオブジェクトが透過オブジェクトを含み比較するオブジェクトの方が透過オブジェクトより大きいかを判断する。包含しているとの判定結果を得た場合(S3004のYES)、処理がS3007へ移行される。他方、包含していないとの判定結果を得た場合(S3004のNO)、処理がS3005へ移行される。
In S3004, the
S3005では、対象となる透過オブジェクトと背景オブジェクトの色の組み合わせを全て算出する。ここでは、対象となる透過オブジェクトと背景オブジェクトの2つのオブジェクトなので、想定される組み合わせは透過オブジェクトの背景が下地の白い色である部分、背景がオブジェクトと重なり合う部分の2つの場合が考えられる。なお、背景オブジェクトの色はすでに色値リストに記載されているので、ここでは取り上げない。よって、ここではその2つの場合の色値を算出する。 In S3005, all color combinations of target transparent objects and background objects are calculated. Here, since there are two objects of interest, a transparent object and a background object, two possible combinations are conceivable: a portion where the background of the transparent object is the white color of the background, and a portion where the background overlaps the object. Note that the color of the background object is already listed in the color value list, so we won't cover it here. Therefore, the color values for these two cases are calculated here.
S3006では、コマンド解析部204は、色値リストの記載されていた透過オブジェクトの色値を削除し、S3005で算出した想定される2つの色値を色値リストに追加する修正処理を実行する。なお、修正処理を実行した後は、処理がS3009に移行される。
In S3006, the
S3007では、コマンド解析部204は、透過オブジェクトと背景オブジェクトを合成した色値を算出する。ここでは、対象となる透過オブジェクトは完全に背景オブジェクトに包含されるので、透過オブジェクトと比較するオブジェクトとを重ねた色値を算出する。なお、算出後は、処理がS3008に移行される。
In S3007, the
S3008では、コマンド解析部204は、色値リストに記載されている透過オブジェクトの色値を、S3007で算出した色値に修正する処理を実行する。なお、修正処理を実行した後は、処理がS3009に移行される。
In S3008, the
S3009では、コマンド解析部204は、全てのオブジェクトと比較したか否か判定する。全てのオブジェクトと比較していないとの判定結果を得た場合(S3009のNO)、処理がS3010へ移行される。S3010にて、コマンド解析部204は、処理対象として次のオブジェクトを設定する。なお、S3010の処理を終えると、処理がS3002に移行され、処理対象として新たに設定された次のオブジェクトに対してS3002の処理が実行される。一方、全てのオブジェクトと比較したとの判定結果を得た場合(S3009のYES)、処理がS3011に移行される。
In S3009, the
S3011では、コマンド解析部204は、全ての透過オブジェクトに対して背景オブジェクトとの合成処理を行ったか否かを判定する。全ての透過オブジェクトに対して背景オブジェクトとの合成処理を行っていないとの判定結果を得た場合(S3011のNO)、処理がS3012に移行される。S3012にて、コマンド解析部204は、処理対象として次の透過オブジェクトを設定する。なお、S3012の処理を終えると、処理がS3001に移行され、処理対象として新たに設定された次の透過オブジェクトに対してS3001の処理が実行される。一方、全ての透過オブジェクトに対して背景オブジェクトとの合成処理を行ったとの判定結果を得た場合(S3011のYES)、図10に示す、重なるオブジェクトの抽出と重なる色値算出処理を終える。
In S<b>3011 , the
以上、透過オブジェクトの背景となるオブジェクトを簡易的に探索する方法について述べた。 A method for simply searching for an object that is the background of a transparent object has been described above.
本実施形態では、透過オブジェクトと他のオブジェクトが近い位置にあれば重なっている可能性があるとして想定できる色値を算出する。そのため、仮に実際には重なっていないために想定した色値が出現しない場合は、弁別性の間隔がそれだけ小さくなることを意味する。例えば、3つの色をグレーで弁別したい場合、弁別性向上処理において最も弁別性を高めた場合のグレー値として0、128、255の3つ値がとりえて、グレー値の差分は128となる。一方で、重なったと仮定して想定できる色値を追加した場合は、4つの色で弁別することになるのでグレー値として0、85、170、255の4つ値がとりえて、グレー値の差分は85となる。したがって、色数は少ないほど弁別性を高めることができるといえる。一方で、透過オブジェクトと背景オブジェクトが厳密に重なっているか否かを確認していくことは大きな負荷につながる。 In this embodiment, a color value is calculated that can be assumed assuming that a transparent object and another object may overlap if they are located close to each other. Therefore, if the expected color values do not appear because they do not actually overlap, it means that the discriminability interval will be reduced accordingly. For example, when it is desired to distinguish three colors with gray, three values of 0, 128, and 255 can be taken as gray values when the distinguishability is enhanced most in the distinguishability improvement processing, and the gray value difference is 128. . On the other hand, if we add color values that can be assumed to overlap, we can discriminate with four colors, so four values of 0, 85, 170, and 255 can be taken as gray values. The difference is 85. Therefore, it can be said that the smaller the number of colors, the higher the distinguishability can be. On the other hand, checking whether the transparent object and the background object exactly overlap leads to a heavy load.
以上説明した通り、本実施形態によれば、原稿内に透過オブジェクト等のRIP処理時に背景オブジェクトと合成することで色値がわかるオブジェクトがあったとしても、処理速度も落とさずにRIP処理前に背景オブジェクトを探索することができる。この探索結果を基に透過オブジェクトと背景オブジェクトから色値を算出し色値リストを更新して弁別性向上処理S402により濃淡をつけることで通常の変換処理より弁別性を向上させることが可能になる。また、透過オブジェクトの背景となるオブジェクトが星形等、さまざまな形状であっても、探索に要する時間を抑えることができる。 As described above, according to the present embodiment, even if there is an object such as a transparent object whose color value is known by compositing it with a background object during RIP processing in the document, the processing speed is not lowered and the color value can be determined before RIP processing. Background objects can be searched. Based on this search result, the color value is calculated from the transparent object and the background object, the color value list is updated, and the gradation is added by the distinguishability improvement processing S402. . In addition, even if the object that becomes the background of the transparent object has various shapes such as a star, the time required for searching can be reduced.
[その他の実施形態]
上記では、カラーデータとしてRGBの色空間で表される画像データを例に説明したが、これに限定されず、他の色空間で表される画像データであってもよい。
[Other embodiments]
In the above description, the image data represented by the RGB color space is used as the color data.
上記では、カラー画像データをモノクロ画像データに変換する態様について説明したが、これに限定されない。例えば、カラー画像データの各色情報を、例えば、マゼンタなどのモノクロ画像データの色情報に変換することも可能である。 Although a mode of converting color image data into monochrome image data has been described above, the present invention is not limited to this. For example, each color information of color image data can be converted into color information of monochrome image data such as magenta.
本開示は、上述の実施形態の1以上の機能を実現するプログラムを、ネットワーク又は記憶媒体を介してシステム又は装置に供給し、そのシステム又は装置のコンピュータにおける1つ以上のプロセッサーがプログラムを読出し実行する処理でも実現可能である。また、1以上の機能を実現する回路(例えば、ASIC)によっても実現可能である。 The present disclosure provides a program that implements one or more functions of the above-described embodiments to a system or device via a network or storage medium, and one or more processors in a computer of the system or device reads and executes the program. It can also be realized by processing to It can also be implemented by a circuit (for example, ASIC) that implements one or more functions.
Claims (13)
前記カラー画像データに含まれるオブジェクトのうち、透過指定された透過オブジェクトの色情報と、当該透過オブジェクトと重なる他のオブジェクトの色情報とを用いて、当該透過オブジェクトが当該他のオブジェクトと重なる部分の色情報を算出する算出手段と、
前記重なる部分について、前記算出手段で算出した前記色情報に基づいて、前記モノクロ画像データの色情報に変換する変換手段と、
を有することを特徴とする画像処理装置。 An image processing device for converting color image data into monochrome image data,
Of the objects included in the color image data, color information of a transparent object designated to be transparent and color information of another object overlapping with the transparent object are used to determine a portion where the transparent object overlaps with the other object. a calculation means for calculating color information;
conversion means for converting the overlapping portion into color information of the monochrome image data based on the color information calculated by the calculation means;
An image processing device comprising:
ことを特徴とする請求項1に記載の画像処理装置。 Based on the color information calculated by the calculation means and the color information of an object included in the color image data, the conversion means performs the 2. The image processing apparatus according to claim 1, wherein the image processing apparatus converts the color information of monochrome image data.
前記変換手段は、前記算出手段で算出した前記全ての色情報、および、前記カラー画像データに含まれるオブジェクトそれぞれの色情報に基づいて、変換後の前記モノクロ画像データにおける色が識別可能となるように、前記モノクロ画像データの色情報に変換する
ことを特徴とする請求項2に記載の画像処理装置。 If the overlapping portion of the transparent object and the other object is a part of the other object, the calculation means calculates all of the combined colors of the transparent object and the other object, which are assumed to be combined. Calculate the color information,
The conversion means is configured to make the colors in the converted monochrome image data identifiable based on all the color information calculated by the calculation means and the color information of each object included in the color image data. 3. The image processing apparatus according to claim 2, wherein the color information of the monochrome image data is converted into color information.
前記算出手段は、前記リストに基づいて、前記透過オブジェクトが前記他のオブジェクトと重なる部分の色情報を算出する
ことを特徴とする請求項2または3に記載の画像処理装置。 further comprising generating means for analyzing the color image data and generating a list showing correspondence between objects included in the color image data and color information of the objects;
4. The image processing apparatus according to claim 2, wherein the calculation means calculates color information of a portion where the transparent object overlaps the other object based on the list.
前記変換手段は、前記カラー画像データに含まれるオブジェクトの色情報に基づいて、前記モノクロ画像データの色情報に変換する
ことを特徴とする請求項2に記載の画像処理装置。 The calculation means does not calculate color information of a portion where the transparent object overlaps with the other object when there are a predetermined number or more of the transparent objects,
3. The image processing apparatus according to claim 2, wherein the converting means converts the color information of the object included in the color image data into the color information of the monochrome image data.
前記変換手段は、前記リストに含まれる色情報に基づいて、前記モノクロ画像データの色情報を変換する、ことを特徴とする請求項5に記載の画像処理装置。 further comprising generating means for analyzing the color image data and generating a list showing correspondence between objects included in the color image data and color information of the objects;
6. The image processing apparatus according to claim 5, wherein said converting means converts the color information of said monochrome image data based on the color information included in said list.
ことを特徴とする請求項1から6の何れか一項に記載の画像処理装置。 7. The image processing apparatus according to claim 1, wherein the monochrome image data is grayscale image data.
前記所定の変換則は、NTSC加重平均法による変換則である
ことを特徴とする請求項8に記載の画像処理装置。 wherein the color image data is data expressed in an RGB color space;
9. The image processing apparatus according to claim 8, wherein said predetermined conversion rule is a conversion rule based on the NTSC weighted average method.
前記変換手段は、前記変換テーブルを用いて、前記モノクロ画像データの色情報に変換する、ことを特徴とする請求項1から9の何れか一項に記載の画像処理装置。 further comprising creating means for creating a conversion table for converting each color information into color information of the monochrome image data;
10. The image processing apparatus according to claim 1, wherein the converting means converts the monochrome image data into color information using the conversion table.
前記印刷データに基づき、モノクロ印刷を行う印刷手段をさらに有する
ことを特徴とする請求項1から10の何れか一項に記載の画像処理装置。 The color image data is included in print data,
11. The image processing apparatus according to claim 1, further comprising printing means for performing monochrome printing based on said print data.
前記カラー画像データに含まれるオブジェクトのうち、透過指定された透過オブジェクトの色情報と、当該透過オブジェクトと重なる他のオブジェクトの色情報とを用いて、当該透過オブジェクトが当該他のオブジェクトと重なる部分の色情報を算出する算出工程と、
前記重なる部分について、前記算出工程で算出した前記色情報に基づいて、前記モノクロ画像データの色情報に変換する変換工程と、
を含むことを特徴とする画像処理方法。 An image processing method for converting color image data into monochrome image data,
Of the objects included in the color image data, color information of a transparent object designated to be transparent and color information of another object overlapping with the transparent object are used to determine a portion where the transparent object overlaps with the other object. a calculation step of calculating color information;
a converting step of converting the overlapping portion into color information of the monochrome image data based on the color information calculated in the calculating step;
An image processing method comprising:
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2021100911A JP2023000217A (en) | 2021-06-17 | 2021-06-17 | Image processing apparatus, image processing method, and program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2021100911A JP2023000217A (en) | 2021-06-17 | 2021-06-17 | Image processing apparatus, image processing method, and program |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2023000217A true JP2023000217A (en) | 2023-01-04 |
Family
ID=84687278
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2021100911A Pending JP2023000217A (en) | 2021-06-17 | 2021-06-17 | Image processing apparatus, image processing method, and program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2023000217A (en) |
-
2021
- 2021-06-17 JP JP2021100911A patent/JP2023000217A/en active Pending
Similar Documents
Publication | Publication Date | Title |
---|---|---|
JP5060502B2 (en) | Image processing apparatus and image processing apparatus control method | |
JP4498233B2 (en) | Image processing apparatus and image processing method | |
US10592766B2 (en) | Image processing apparatus and medium storing program executable by image processing apparatus | |
JP5932313B2 (en) | Printing apparatus, print preview display method and program thereof | |
US11706371B2 (en) | Apparatus and method for performing enhancement processing on color information | |
JP6628279B2 (en) | Image processing apparatus, image processing method, image processing program, and recording medium | |
JP2008154106A (en) | Concealing method, image processor and image forming apparatus | |
JP5893379B2 (en) | Image compression apparatus, image compression method, and computer program | |
JP5409137B2 (en) | Image processing apparatus, image processing method, and program | |
JP5607344B2 (en) | Method for identifying trapping candidates, computer-readable medium, and program | |
JP4418826B2 (en) | Image output apparatus and control method thereof | |
US10582088B2 (en) | Information processing apparatus, method, and storage medium for causing printer driver to generate drawing command | |
JP2023000217A (en) | Image processing apparatus, image processing method, and program | |
US20200322503A1 (en) | Image processing apparatus, image processing method, and storing medium | |
US20230224421A1 (en) | Image processing apparatus, image processing method, and storage medium | |
JP7297603B2 (en) | Image processing device, image processing method, and program | |
JP6145877B2 (en) | Color mode determination apparatus and program | |
JP2019111677A (en) | Image processing device, image processing device control method, image forming device and program | |
US11704519B2 (en) | Printer driver for processing PDL data, image forming apparatus, control method of image forming apparatus, and storage medium | |
JP2001024872A (en) | Method and device for image processing, image processing system and recording medium | |
JP2023018850A (en) | program | |
US20210281715A1 (en) | Adaptive autocolor detection based on media color | |
JP2023008251A (en) | Image processing apparatus, image processing method, and program | |
JP2023033977A (en) | Image forming device, image forming device control method and program | |
JP2024034772A (en) | Image processing device, image processing method, and program |