JP2005222346A - Image processor and image processing method - Google Patents

Image processor and image processing method Download PDF

Info

Publication number
JP2005222346A
JP2005222346A JP2004030118A JP2004030118A JP2005222346A JP 2005222346 A JP2005222346 A JP 2005222346A JP 2004030118 A JP2004030118 A JP 2004030118A JP 2004030118 A JP2004030118 A JP 2004030118A JP 2005222346 A JP2005222346 A JP 2005222346A
Authority
JP
Japan
Prior art keywords
type
command
image
image processing
printer driver
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.)
Withdrawn
Application number
JP2004030118A
Other languages
Japanese (ja)
Inventor
Yoshihiro Takagi
義博 高木
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.)
Canon Inc
Original Assignee
Canon Inc
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 Canon Inc filed Critical Canon Inc
Priority to JP2004030118A priority Critical patent/JP2005222346A/en
Publication of JP2005222346A publication Critical patent/JP2005222346A/en
Withdrawn legal-status Critical Current

Links

Images

Landscapes

  • Processing Or Creating Images (AREA)

Abstract

<P>PROBLEM TO BE SOLVED: To provide an image processor and image processing method that can accurately decide the kind of an object. <P>SOLUTION: In the image processing method of discriminating the kind of an object to be drawn and drawing the object according to the discriminated kind of the object, the drawn object is discriminated not by a command instructing image drawing, but with the kind of the object specified by an external program. <P>COPYRIGHT: (C)2005,JPO&NCIPI

Description

本発明は画像処理装置およびその方法に関し、例えば、描画すべきオブジェクトの種類に応じた描画処理を行う画像処理装置およびその方法に関する。   The present invention relates to an image processing apparatus and method, for example, an image processing apparatus and method for performing drawing processing according to the type of object to be drawn.

最近のワークステーション(WS)やパーソナルコンピュータ(PC)、並びに、レーザビームプリンタ(LBP)およびインクジェットプリンタ(IJP)などに代表されるカラープリンタの普及により、アプリケーションソフトウェアによって作成および/または編集された各種のカラー文書が印刷出力されるようになった。   Various types created and / or edited by application software due to the spread of recent color printers such as workstations (WS), personal computers (PCs), and laser beam printers (LBP) and inkjet printers (IJP) Color documents are now printed out.

ただし、ユーザが望むカラー印刷出力が容易に得られるようにするには、以下に示す問題を解決しなければならない。   However, in order to easily obtain the color print output desired by the user, the following problems must be solved.

(1)ユーザがカラー文書を作成・編集するCRTなどのモニタと、プリンタとは色再現範囲(gamut)が異なる。一般にモニタの色再現範囲はプリンタの色再現範囲よりも広く、プリンタは、モニタにより表現される色のすべてを再現することはできない。このため、色空間の圧縮処理(色空間マッチング)が必要になり、色空間圧縮として幾つかの手法が提案されている。しかし、どの手法が適当であるかをユーザが判断することは難しい。   (1) The color reproduction range (gamut) is different between a monitor such as a CRT on which a user creates and edits a color document and a printer. In general, the color reproduction range of the monitor is wider than the color reproduction range of the printer, and the printer cannot reproduce all the colors represented by the monitor. For this reason, color space compression processing (color space matching) is required, and several methods have been proposed for color space compression. However, it is difficult for the user to determine which method is appropriate.

(2)上記(1)に関連するが、モニタの色はRGBの加色混法で表現され、プリンタの色はCMYKの減色混法であるから、モニタで確認された複数色の混合色と、プリンタによって得られる混合色とは異なる可能性がある。   (2) Although related to (1) above, the monitor color is expressed by RGB additive color mixing, and the printer color is CMYK subtractive color mixing. The mixed color obtained by the printer may be different.

(3)最近のプリンタは高解像度、例えば1200dpiや600dpiであり、72dpi程度のモニタによるプレビューに比べて、遥かに高精細な印刷を必要とし、用途に応じた適切なハーフトーニング(二値化、多値化、量子化など)を選択する必要がある。   (3) Recent printers have high resolution, for example, 1200 dpi or 600 dpi, and require much higher-definition printing than previews on a monitor of about 72 dpi, and appropriate halftoning (binarization, Multi-value quantization, quantization, etc.) must be selected.

(4)LBPに代表される電子写真方式のプリンタは、系時変化やエンジンの個体差により微妙に色味が異なる場合がある。色味の差異を制御する方法が幾つか提案されているが、ある種類のオブジェクト(データ)には有効であるが、別種のオブジェクト(データ)には副作用が出る場合などがある。   (4) An electrophotographic printer typified by LBP may have a slightly different color due to system changes or engine differences. Several methods for controlling the color difference have been proposed, but they are effective for one type of object (data), but may have side effects on another type of object (data).

また、カラー文書には、特徴が異なる各種オブジェクト、例えばテキスト、グラフィックス、イメージなどが含まれている。例えば、テキストには1バイトで示されるアルファニューメリック文字や、2バイトの漢字などがあり、イメージは二次元に配列された画素をもち、各画素毎に異なるカラー情報をもつ。そして、イメージは、効率化のために圧縮されている場合もある。また、グラフィックスは、ライン、並びに、多角形の輪郭および内部領域で表現される。   The color document includes various objects having different characteristics, such as text, graphics, and images. For example, text includes alphanumeric characters indicated by 1 byte and 2-byte kanji characters, and an image has pixels arranged two-dimensionally and has different color information for each pixel. The image may be compressed for efficiency. Graphics are represented by lines, polygonal outlines, and internal regions.

印刷出力において良好な色再現を実現するには、各オブジェクトの特徴に応じて、上記の問題を解決する処理が必要になる。具体的な解決策として、描画コマンドの形式に応じて、そのコマンドにより示されるオブジェクトの種類を判別する技術がある(特許文献1参照)。   In order to realize good color reproduction in the print output, a process for solving the above problem is required according to the characteristics of each object. As a specific solution, there is a technique for discriminating the type of object indicated by the command according to the format of the drawing command (see Patent Document 1).

その技術によれば、アプリケーションソフトウェアが発行するテキストコマンドに基づくオブジェクトはすべてテキストオブジェクトとして描画される。
特開平7−236066
According to this technique, all objects based on text commands issued by application software are drawn as text objects.
JP-A-7-236066

しかしながら、従来の手法ではプリンタドライバに渡される描画コマンドのみを手がかりに各種オブジェクトの種類を判別するため、正確なオブジェクトの識別が出来ないことがあった。以下、テキスト描画における具体例を示す。   However, in the conventional method, since the types of various objects are determined based on only the drawing command passed to the printer driver, there are cases where accurate object identification cannot be performed. A specific example of text drawing will be shown below.

図1は、Microsoft社のWindows(R)シリーズが稼動している印刷システムにおけるアプリケーションからプリンタドライバに到るテキスト描画の処理フローを例示している。図1の様にアプリケーションがGDI(Graphics Device Interface。以後GDIと称する)に対しテキスト描画を行い、それを受けてGDIがプリンタドライバへテキスト描画を指示すれば、プリンタドライバは正しくテキストオブジェクトと判別出来る。   FIG. 1 exemplifies a text drawing processing flow from an application to a printer driver in a printing system in which the Microsoft® Windows® series is operating. As shown in FIG. 1, if an application performs text drawing on GDI (Graphics Device Interface, hereinafter referred to as GDI), and GDI instructs the printer driver to draw the text, the printer driver can be correctly identified as a text object. .

一方、図2は図1と同様にアプリケーションがGDIに対しテキスト描画を行っているが、GDIはフォントのポイントが非常に大きいためプリンタドライバへグラフィック描画を指示している。このような場合、プリンタドライバは本来テキストオブジェクトと判別すべきものを誤ってグラフィックオブジェクトと判別してしまう。   On the other hand, FIG. 2 shows that the application draws text on the GDI as in FIG. 1, but the GDI has a very large font point and instructs the printer driver to draw graphics. In such a case, the printer driver erroneously determines what should be determined as a text object as a graphic object.

図3は、アプリケーションがテキストを描画を行う際、文字形状をビットマップとして抽出してイメージ描画を行うため、GDIはそれを受けてプリンタドライバへイメージ描画を行う。このような場合、プリンタドライバは本来テキストオブジェクトと判別すべきものを誤ってイメージオブジェクトと判別してしまう。   In FIG. 3, when the application draws text, the character shape is extracted as a bitmap and image drawing is performed. Therefore, the GDI receives the image and performs image drawing to the printer driver. In such a case, the printer driver erroneously determines what should be determined as a text object as an image object.

本発明は、上述の問題を個々にまたはまとめて解決するためのものであり、正確なオブジェクトの種類の判定を行う画像処理装置及びその方法を提供することを目的とする。   The present invention is for solving the above-described problems individually or collectively, and an object thereof is to provide an image processing apparatus and method for accurately determining the type of an object.

本発明は、前記の目的を達成する一手段として、以下の構成を備える。   The present invention has the following configuration as one means for achieving the above object.

本発明にかかる画像処理方法は、描画すべきオブジェクトの種類を識別し、識別したオブジェクトの種類に応じて描画を行う画像処理方法であって、オブジェクトの描画を指示するコマンドによらず、外部のプログラムより指定されたオブジェクトの種類によって描画オブジェクトを識別することを特徴とする。   An image processing method according to the present invention is an image processing method for identifying a type of an object to be drawn and performing drawing according to the identified type of the object, and without using a command for instructing drawing of the object. The drawing object is identified by the type of the object specified by the program.

また、描画を指示するコマンドを入力し、該入力コマンドによって指示される描画すべきオブジェクトの種類によらず、外部のプログラムより指定されたオブジェクトの種類によって描画オブジェクトを識別し、識別されたオブジェクトの種類に応じて描画を行うことを特徴とする。   In addition, a command for instructing drawing is input, the drawing object is identified by the type of object designated by an external program, regardless of the type of object to be drawn instructed by the input command, and the identified object Drawing is performed according to the type.

本発明にかかる画像処理装置は、描画すべきオブジェクトの種類を識別し、識別したオブジェクトの種類に応じて描画を行う画像処理装置であって、オブジェクトの描画を指示するコマンドによらず、外部のプログラムより指定されたオブジェクトの種類によって描画オブジェクトを識別する識別手段を有することを特徴とする。   An image processing apparatus according to the present invention is an image processing apparatus that identifies a type of an object to be drawn and performs drawing according to the identified type of the object. It has an identification means for identifying a drawing object according to the type of object specified by the program.

また、描画を指示するコマンドを入力する入力手段と、入力コマンドによって指示される描画すべきオブジェクトを識別されたオブジェクトの種類に応じて描画を行う描画手段とを有し、前記識別手段は、入力コマンドによって指示される描画すべきオブジェクトの種類によらず外部のプログラムより指定されたオブジェクトの種類によって描画オブジェクトを識別することを特徴とする。   And an input means for inputting a command for instructing drawing, and a drawing means for drawing an object to be drawn instructed by the input command in accordance with the type of the identified object. The drawing object is identified by the type of object specified by an external program regardless of the type of the object to be drawn specified by the command.

以上説明したように本発明によれば、正確な描画オブジェクトの種類の判定を行う画像処理が可能となる。   As described above, according to the present invention, it is possible to perform image processing for accurately determining the type of a drawing object.

以下添付図面を参照して、本発明にかかる第一実施形態を詳細に説明する。   Hereinafter, a first embodiment of the present invention will be described in detail with reference to the accompanying drawings.

なお、以下では、本発明をカラープリンタに適用する例を説明するが、モノクロプリンタに対しても同様に適用可能であることはいうまでもない。   In the following, an example in which the present invention is applied to a color printer will be described, but it is needless to say that the present invention can be similarly applied to a monochrome printer.

<第1実施形態>
[構成]
図4は第1実施形態のホストコンピュータシステムの構成例を示すブロック図である。
<First Embodiment>
[Constitution]
FIG. 4 is a block diagram illustrating a configuration example of the host computer system according to the first embodiment.

図4において、ホストコンピュータ502は、プリントデータおよび制御コードからなる印刷情報を印刷装置100に出力する。ホストコンピュータ502は、入力デバイスであるキーボード2100、ポインティングデバイスであるマウス2110、および、表示デバイスであるディスプレイモニタ2200などを組み合わせたホストコンピュータシステムとして構成され、例えばMicrosoft社のWindows(R)シリーズなどの基本オペレーティングシステム(OS)が稼動している。   In FIG. 4, the host computer 502 outputs print information including print data and a control code to the printing apparatus 100. The host computer 502 is configured as a host computer system that combines a keyboard 2100 that is an input device, a mouse 2110 that is a pointing device, a display monitor 2200 that is a display device, and the like, such as the Windows (R) series of Microsoft Corporation. A basic operating system (OS) is running.

ホストコンピュータ502について、本実施形態に関する機能的な部分にのみ注目し、基本OS上での機能を大きく分類すると、アプリケーションソフトウェア2010、画像情報処理手段であるグラフィックサブシステム2020、スプールサブシステム2030、および、ユーザインタフェイス処理部(UI)2040に分類される。   With regard to the host computer 502, focusing only on the functional part related to the present embodiment, and broadly classifying the functions on the basic OS, the application software 2010, the graphic subsystem 2020 as image information processing means, the spool subsystem 2030, and And a user interface processing unit (UI) 2040.

グラフィックサブシステム2020は、基本OSの機能の一部であるグラフィックスデバイスインタフェイス(Graphics Device Interface: GDI)2021、および、GDI2021から動的にリンクされるデバイスドライバであるプリンタドライバ2022によって構成される。   The graphics subsystem 2020 includes a graphics device interface (GDI) 2021 that is a part of the functions of the basic OS, and a printer driver 2022 that is a device driver dynamically linked from the GDI 2021. .

プリンタドライバ2022は、アプリケーションソフトウェア2010からGDI描画命令(関数)としてコールされる命令をページ記述言語(Page Description Language: PDL)に変換するのが大きな役割である。また、プリンタドライバ2022は、ユーザに指定されたモード、および、GDI描画命令の種類に応じて、カラーマネージメントシステム(Color Management System:CMS)モジュール2023、および、色調整モジュール2024に色処理を依頼する。   A major role of the printer driver 2022 is to convert an instruction called as a GDI drawing instruction (function) from the application software 2010 into a page description language (PDL). The printer driver 2022 requests color processing from the color management system (CMS) module 2023 and the color adjustment module 2024 in accordance with the mode designated by the user and the type of GDI rendering command. .

スプールサブシステム2030は、グラフィックサブシステム2020の後段に位置するプリンタデバイスに特有のサブシステムで、データ格納手段であるスプールファイル2031(実態はハードディスクなど)、および、スプールファイル2031に蓄えられたPDLコードを読み出して印刷装置100における処理の進行状況を監視するプロセスモニタ2034などから構成される。   The spool subsystem 2030 is a subsystem unique to the printer device located at the subsequent stage of the graphic subsystem 2020. The spool file 2031 (actually, a hard disk or the like) as data storage means, and the PDL code stored in the spool file 2031 And a process monitor 2034 for monitoring the progress of processing in the printing apparatus 100.

UI2040は、基本OSより提供される関数を利用しながら、印刷品位の制御パラメータを決定すべく、各種メニューボタンなどをディスプレイモニタ2200に表示し、キーボード2100やマウス2110を介したユーザアクションを解析する。   The UI 2040 displays various menu buttons and the like on the display monitor 2200 and analyzes user actions via the keyboard 2100 and the mouse 2110 in order to determine print quality control parameters using a function provided by the basic OS. .

上述した構成(モジュール)の名称や機能的な枠組みは、基本OSによって若干異なる場合があるが、各技術的手段が実現可能なモジュールであればよく、それらの名称や枠組みの差異は本実施形態の実施に影響を与えることはない。例えば、スプーラやスプールファイル2031は、他のOSにおいてはプリントキューと呼ばれるモジュールに処理を組み込むことによって実現可能である。   Although the names and functional frameworks of the above-described configurations (modules) may be slightly different depending on the basic OS, any module capable of realizing each technical means may be used. Will not affect the implementation of For example, the spooler and the spool file 2031 can be realized by incorporating processing into a module called a print queue in other OSs.

なお、一般に、これらの機能モジュールを含むホストコンピュータ502とは、図示しないCPU、ROM、RAM、ハードディスクドライブ(HDD)および各種入出力制御部(I/O)などから構成されるハードウェア上で、基本OSなどのソフトウェアがそれらハードウェアの制御を司り、基本OSの基でアプリケーションソフトウェア2010のプロセスやサブシステムのプロセスが機能モジュールとして動作するものである。   In general, the host computer 502 including these functional modules refers to hardware configured by a CPU, a ROM, a RAM, a hard disk drive (HDD), various input / output control units (I / O), and the like (not shown). Software such as a basic OS controls the hardware, and the process of the application software 2010 and the processes of the subsystem operate as function modules based on the basic OS.

[プリンタドライバの処理]
以下、プリンタドライバ2022が実行する処理を図5に示すフローチャートに従い説明する。
[Printer Driver Processing]
The processing executed by the printer driver 2022 will be described with reference to the flowchart shown in FIG.

ユーザが、ホストコンピュータ502上で稼動する、あるアプリケーションソフトウェア2010から印刷の開始を指示すると、UI2040により印刷の制御パラメータを設定するための印刷ダイアログがディスプレイモニタ2200に表示される(S4000)。そして、印刷ダイアログ上でユーザにより、出力プリンタ、記録紙サイズ、印刷部数および印刷品質などの各種設定が行われ、印刷が指示される(S4010)。   When the user gives an instruction to start printing from certain application software 2010 running on the host computer 502, a print dialog for setting printing control parameters is displayed on the display monitor 2200 by the UI 2040 (S4000). Then, various settings such as an output printer, recording paper size, number of copies, and print quality are made by the user on the print dialog, and printing is instructed (S4010).

印刷が指示されると、アプリケーションソフトウェア2010によって作成・編集された画像を示す描画データが、印刷ジョブとしてGDI2021を介してプリンタドライバ2022に渡され、プリンタドライバ2022は該印刷ジョブの初期化を行う(S4020)。   When printing is instructed, drawing data indicating an image created and edited by the application software 2010 is passed as a print job to the printer driver 2022 via the GDI 2021, and the printer driver 2022 initializes the print job ( S4020).

プリンタドライバ2022は次に該印刷ジョブのページ毎の初期化を行い(S4030)、続いて描画を行う(S4040)が、この描画の詳細については後述する。   Next, the printer driver 2022 initializes the print job for each page (S4030), and then performs drawing (S4040). Details of the drawing will be described later.

ページ単位の描画後は改ページ等の後処理を行い(S4050)、ステップS4060でまだ印刷すべきページが残っていればステップS4030へ戻って次ページの処理を行うが、ページの終端であればステップS4070に進んで印刷ジョブの後処理を行った後、印刷処理を終了する。   After drawing in units of pages, post-processing such as page break is performed (S4050). If there is still a page to be printed in step S4060, the process returns to step S4030 to process the next page. After proceeding to step S4070 to perform post-processing of the print job, the print processing is terminated.

以下、ステップS4040に示した描画処理について、図6を参照して説明する。図6は、アプリケーション2010とGDI2021とプリンタドライバ2022間におけるエスケープコマンドと各描画コマンド(テキストコマンド、イメージ・コマンド、グラフィックスコマンド)のインタフェースを示す図である。   Hereinafter, the drawing process shown in step S4040 will be described with reference to FIG. FIG. 6 is a diagram showing an interface between the escape command and each drawing command (text command, image command, graphics command) between the application 2010, the GDI 2021, and the printer driver 2022.

ここでアプリケーション2010は、説明を簡易化するために以後もアプリケーションと称するが、実際にはGDIに描画を要求できるモジュールならばアプリケーション以外でもかまわない。プリンタドライバとして提供されるモジュールの一部であっても一向にかまわない。   Here, the application 2010 will be referred to as an application for the sake of simplification of description. However, the application 2010 may actually be other than an application as long as it is a module that can request drawing to the GDI. Even a part of a module provided as a printer driver may be used.

エスケープコマンド5010は、プリンタドライバ2022の内部に実装されるエスケープコマンド処理関数DrvEscapeやDrvDrawEscapeを、GDI2021が呼び出すことを意味する。アプリケーションが、GDI2021に対しエスケープを発行すると、GDI2021をバイパスし、エスケープコードとデータはそのままプリンタドライバ2022に渡る。   The escape command 5010 means that the GDI 2021 calls an escape command processing function DrvEscape or DrvDrawEscape implemented in the printer driver 2022. When the application issues an escape to the GDI 2021, the GDI 2021 is bypassed, and the escape code and data are passed to the printer driver 2022 as they are.

なお、エスケープコマンド処理関数の名称は、Windows(R)NT/Windows(R)2000においてはDrvEscapeやDrvDrawEscapeだが、Windows(R)Me/98/95/3.1においてはControlである。基本OSによってこれらの名称や機能は若干異なるが、基本的な考え方は同様である。   The name of the escape command processing function is DrvEscape or DrvDrawEscape in Windows (R) NT / Windows (R) 2000, but is Control in Windows (R) Me / 98/95 / 3.1. Although these names and functions differ slightly depending on the basic OS, the basic concept is the same.

DrvEscape関数の呼び出しは、例えば、次のようになる。ここでは主なパラメータだけを紹介する。   The DrvEscape function is called as follows, for example. Only the main parameters are introduced here.

DrvEscape(p1、p2、p3、p4、p5)
パラメータp1:エスケープコード。
DrvEscape (p1, p2, p3, p4, p5)
Parameter p1: Escape code.

パラメータp2:入力データのサイズ。   Parameter p2: size of input data.

パラメータp3:入力データ。   Parameter p3: input data.

パラメータp4:出力データサイズ。   Parameter p4: output data size.

パラメータp5:出力データ。   Parameter p5: output data.

テキストコマンド5020は、プリンタドライバ2022の内部に実装されるテキスト処理関数DrvTextOutを、GDI2021が呼び出すことを意味する。アプリケーションが、GDI2021に対しテキスト描画を行うと、GDI2021はプリンタドライバのテキストコマンド(DrvTextOut関数)をコールすることが多い。また、このとき図2で例示したように、アプリケーション2010とGDI2021間と、GDI2021とプリンタドライバ間では、必ずしも対にならない。テキストコマンド5020は、プリンタドライバ2022に実装されたテキスト処理関数(DrvTextOut関数)のGDI2021による呼び出しを意味する。   A text command 5020 means that the GDI 2021 calls a text processing function DrvTextOut implemented in the printer driver 2022. When an application draws text on the GDI 2021, the GDI 2021 often calls a printer driver text command (DrvTextOut function). At this time, as illustrated in FIG. 2, there is not necessarily a pair between the application 2010 and the GDI 2021, and between the GDI 2021 and the printer driver. A text command 5020 means a call by the GDI 2021 of a text processing function (DrvTextOut function) implemented in the printer driver 2022.

なお、テキスト処理関数の名称は、Windows(R)NT/Windows(R)2000においてはDrvTextOutだが、Windows(R)Me/98/95/3.1においてはExtTextOutである。基本OSによってこれらの名称や機能は若干異なるが、基本的な考え方は同様である。   The name of the text processing function is DrvTextOut in Windows (R) NT / Windows (R) 2000, but is ExtTextOut in Windows (R) Me / 98/95 / 3.1. Although these names and functions differ slightly depending on the basic OS, the basic concept is the same.

DrvTextOut関数の呼び出しは、例えば、次のようになる。ここでは主なパラメータだけを紹介する。   For example, the DrvTextOut function is called as follows. Only the main parameters are introduced here.

DrvTextOut(p1、p2、p3、p4、p5、p6)
パラメータp1:文字列情報が格納された変数名。文字列が含まれる。
DrvTextOut (p1, p2, p3, p4, p5, p6)
Parameter p1: Variable name in which character string information is stored. Contains a string.

パラメータp2:フォント情報が格納された変数名。文字サイズが含まれる。   Parameter p2: Variable name in which font information is stored. Includes character size.

パラメータp3:文字装飾領域が格納された変数名。NULLの場合は装飾線なし。   Parameter p3: Variable name in which the character decoration area is stored. In case of NULL, there is no decorative line.

パラメータp4:文字背景領域が格納された変数名。NULLの場合は文字背景は透明。   Parameter p4: Variable name in which the character background area is stored. In the case of NULL, the character background is transparent.

パラメータp5:文字色が格納された変数名。   Parameter p5: Variable name in which the character color is stored.

パラメータp6:文字背景色が格納された変数名。   Parameter p6: Variable name in which the character background color is stored.

テキストコマンドと同様に、イメージ・コマンド5030は、プリンタドライバ2022に実装されたイメージ処理関数(DrvCopyBits、DrvBitBlt、DrvStretchBlt関数等)のGDI2021による呼び出しを意味し、グラフィックスコマンド5040は、プリンタドライバ2022に実装されたグラフィックス処理関数(DrvStrokePath、DrvFillPath、DrvStrokeAndFillPath関数等)のGDI2021による呼び出しを意味する。   Similar to the text command, the image command 5030 means a call by the GDI 2021 of an image processing function (DrvCopyBits, DrvBitBlt, DrvStretchBlt function, etc.) implemented in the printer driver 2022, and the graphics command 5040 is implemented in the printer driver 2022. The GDI 2021 calls a graphics processing function (DrvStrokePath, DrvFillPath, DrvStrokeAndFillPath function, etc.).

プリンタドライバ2022は、これら各コマンドに対応する各描画オブジェクトの種類に応じて、カラー調整やカラーマッチング処理を行う。そして、カラーマッチング処理が行われた色情報をPDLコマンドに変換することによって、描画処理が行われる。   The printer driver 2022 performs color adjustment and color matching processing according to the type of each drawing object corresponding to each of these commands. Then, the drawing process is performed by converting the color information subjected to the color matching process into a PDL command.

以下、ステップS4040における描画処理について、図7以降のフローチャートを参照して詳細に説明する。   Hereinafter, the drawing process in step S4040 will be described in detail with reference to the flowcharts in FIG.

次に、図6のエスケープコマンド処理部5010を図7に示すフローチャートに従い説明する。   Next, the escape command processing unit 5010 shown in FIG. 6 will be described with reference to the flowchart shown in FIG.

まず、アプリケーション2010とプリンタドライバ2022の間で認識可能なエスケープコード4つを規定する。   First, four escape codes that can be recognized between the application 2010 and the printer driver 2022 are defined.

#define UNKNOWN_OBJ0x2410
#define TEXT_OBJ0x2411
#define IMAGE_OBJ0x2412
#define GRAPHIC_OBJ0x2413
これらの値に特に意味は無く、GDIや一般のアプリケーションなどで定義済みのエスケープコードと重複しない限りどのような値を定義してもかまわない。
#Define UNKNOWN_OBJ0x2410
#Define TEXT_OBJ0x2411
#Define IMAGE_OBJ0x2412
#Define GRAPHIC_OBJ0x2413
These values have no particular meaning, and any values may be defined as long as they do not overlap with the escape codes already defined in GDI or general applications.

エスケープコードがTEXT_OBJのとき(S7010)、drawobj変数にTEXT_OBJを代入する(S7020)。このdrawobj変数は、印刷ジョブ中保持される。初期値はUNKNOWN_OBJである。エスケープコードがIMAGE_OBJのとき(S7030)、drawobj変数にIMAGE_OBJを代入する(S7040)。エスケープコードがGRAPHIC_OBJのとき(S7050)、drawobj変数にGRAPHIC_OBJを代入する(S7060)。エスケープコードがUNKNOWN_OBJのとき(S7070)、drawobj変数にUNKNOWN_OBJを代入する(S7080)。以上のエスケープコード以外のときは、本実施案と無関係な処理を行う(S7090)。   When the escape code is TEXT_OBJ (S7010), TEXT_OBJ is assigned to the drawobj variable (S7020). This drawobj variable is retained during the print job. The initial value is UNKNOWN_OBJ. When the escape code is IMAGE_OBJ (S7030), IMAGE_OBJ is assigned to the drawobj variable (S7040). When the escape code is GRAPHIC_OBJ (S7050), GRAPHIC_OBJ is assigned to the drawobj variable (S7060). When the escape code is UNKNOWN_OBJ (S7070), UNKNOWN_OBJ is substituted into the drawobj variable (S7080). In cases other than the above escape codes, processing unrelated to the present embodiment is performed (S7090).

次に、図6のテキストコマンド処理部5020を図8に示すフローチャートに従い説明する。   Next, the text command processing unit 5020 of FIG. 6 will be described according to the flowchart shown in FIG.

まず、drawobj変数がUNKNOWN_OBJと等しい値であるかどうか評価する(S8010)。等しい場合、テキストオブジェクトとみなし、CMSモジュール2023や色調整モジュール2024に色処理を依頼する(S8020)。drawobj変数がUNKNOWN_OBJ以外のときは、GRAPHIC_OBJと等しい値であるかどうか評価する(S8030)。等しい場合、グラフィックオブジェクトとみなし、CMSモジュール2023や色調整モジュール2024に色処理を依頼する(S8040)。drawobj変数がGRAPHIC_OBJ以外のときは、IMAGE_OBJと等しい値であるかどうか評価する(S8050)。等しい場合、イメージオブジェクトとみなし、CMSモジュール2023や色調整モジュール2024に色処理を依頼する(S8060)。以上の色処理を終えた後、テキストの描画処理を行う(S8070)。   First, it is evaluated whether or not the drawobj variable is equal to UNKNOWN_OBJ (S8010). If equal, it is regarded as a text object, and color processing is requested to the CMS module 2023 and the color adjustment module 2024 (S8020). When the drawobj variable is other than UNKNOWN_OBJ, it is evaluated whether the value is equal to GRAPHIC_OBJ (S8030). If equal, it is regarded as a graphic object, and the CMS module 2023 and the color adjustment module 2024 are requested to perform color processing (S8040). When the drawobj variable is other than GRAPHIC_OBJ, it is evaluated whether the value is equal to IMAGE_OBJ (S8050). If they are equal, it is regarded as an image object, and color processing is requested to the CMS module 2023 and the color adjustment module 2024 (S8060). After finishing the above color processing, text drawing processing is performed (S8070).

次に、図6のイメージ・コマンド処理部5030を図9に示すフローチャートに従い説明する。   Next, the image / command processing unit 5030 in FIG. 6 will be described with reference to the flowchart shown in FIG.

まず、drawobj変数がUNKNOWN_OBJと等しい値であるかどうか評価する(S9010)。等しい場合、イメージオブジェクトとみなし、CMSモジュール2023や色調整モジュール2024に色処理を依頼する(S9020)。drawobj変数がUNKNOWN_OBJ以外のときは、GRAPHIC_OBJと等しい値であるかどうか評価する(S9030)。等しい場合、グラフィックオブジェクトとみなし、CMSモジュール2023や色調整モジュール2024に色処理を依頼する(S9040)。drawobj変数がGRAPHIC_OBJ以外のときは、TEXT_OBJと等しい値であるかどうか評価する(S9050)。等しい場合、テキストオブジェクトとみなし、CMSモジュール2023や色調整モジュール2024に色処理を依頼する(S9060)。以上の色処理を終えた後、イメージの描画処理を行う(S9070)。   First, it is evaluated whether or not the drawobj variable is equal to UNKNOWN_OBJ (S9010). If they are equal, it is regarded as an image object, and color processing is requested to the CMS module 2023 and the color adjustment module 2024 (S9020). When the drawobj variable is other than UNKNOWN_OBJ, it is evaluated whether the value is equal to GRAPHIC_OBJ (S9030). If equal, it is regarded as a graphic object, and the CMS module 2023 and the color adjustment module 2024 are requested to perform color processing (S9040). When the drawobj variable is other than GRAPHIC_OBJ, it is evaluated whether the value is equal to TEXT_OBJ (S9050). If equal, it is regarded as a text object, and color processing is requested to the CMS module 2023 and the color adjustment module 2024 (S9060). After the above color processing is completed, image drawing processing is performed (S9070).

次に、図6のグラフィックコマンド処理部5040を図10に示すフローチャートに従い説明する。   Next, the graphic command processing unit 5040 of FIG. 6 will be described according to the flowchart shown in FIG.

まず、drawobj変数がUNKNOWN_OBJと等しい値であるかどうか評価する(S10010)。等しい場合、グラフィックオブジェクトとみなし、CMSモジュール2023や色調整モジュール2024に色処理を依頼する(S10020)。drawobj変数がUNKNOWN_OBJ以外のときは、TEXT_OBJと等しい値であるかどうか評価する(S10030)。等しい場合、テキストオブジェクトとみなし、CMSモジュール2023や色調整モジュール2024に色処理を依頼する(S10040)。drawobj変数がGRAPHIC_OBJ以外のときは、IMAGE_OBJと等しい値であるかどうか評価する(S10050)。等しい場合、イメージオブジェクトとみなし、CMSモジュール2023や色調整モジュール2024に色処理を依頼する(S10060)。以上の色処理を終えた後、グラフィックの描画処理を行う(S10070)。   First, it is evaluated whether or not the drawobj variable is equal to UNKNOWN_OBJ (S10010). If equal, it is regarded as a graphic object, and the CMS module 2023 and the color adjustment module 2024 are requested to perform color processing (S10020). When the drawobj variable is other than UNKNOWN_OBJ, it is evaluated whether or not the value is equal to TEXT_OBJ (S10030). If they are equal, it is regarded as a text object, and color processing is requested to the CMS module 2023 and the color adjustment module 2024 (S10040). When the drawobj variable is other than GRAPHIC_OBJ, it is evaluated whether or not the value is equal to IMAGE_OBJ (S10050). If they are equal, it is regarded as an image object, and color processing is requested to the CMS module 2023 and the color adjustment module 2024 (S10060). After finishing the above color processing, graphic drawing processing is performed (S10070).

アプリケーション2010がGDI2021に対し描画命令を発行したとき、プリンタドライバ2022のオブジェクトの識別はどのように行われるかを、図11に示す時系列の遷移状態例に従い説明する。   How the object of the printer driver 2022 is identified when the application 2010 issues a drawing command to the GDI 2021 will be described with reference to a time-series transition state example shown in FIG.

S11010でアプリケーション2010は、エスケープを使って以下に続く描画が全てテキストオブジェクトであることをプリンタドライバ2022に通知する。つまりエスケープコードTEXT_OBJがプリンタドライバ2022に届く。このため次のエスケープが発行されるまで(S11040)、プリンタドライバ2022はS11020とS11030の描画をテキストオブジェクトと判別する。もし、S11010を指定しないと、図2の例が示すようにプリンタドライバ2022はS11020をグラフィックオブジェクトと判別することがありえる。S11030は図3の例と同じである。アプリケーション2010はイメージ描画を行っているが、描画されるビットマップがテキストであるため、プリンタドライバ2022にテキストオブジェクトとみなすよう指示している。   In step S <b> 11010, the application 2010 notifies the printer driver 2022 that all the following drawing are text objects using escape. That is, the escape code TEXT_OBJ reaches the printer driver 2022. For this reason, until the next escape is issued (S11040), the printer driver 2022 determines that the rendering of S11020 and S11030 is a text object. If S11010 is not designated, the printer driver 2022 may determine that S11020 is a graphic object as shown in the example of FIG. S11030 is the same as the example of FIG. Although the application 2010 performs image drawing, the bitmap to be drawn is text, so the printer driver 2022 is instructed to be regarded as a text object.

S11040でアプリケーション2010は、エスケープを使って以下に続く描画が全てイメージオブジェクトであることをプリンタドライバ2022に通知する。つまりエスケープコードIMAGE_OBJがプリンタドライバ2022に届く。このため次のエスケープが発行されるまで(S11060)、プリンタドライバ2022はS11050の描画をイメージオブジェクトと判別する。   In step S <b> 11040, the application 2010 notifies the printer driver 2022 that all the following drawing are image objects using escape. That is, the escape code IMAGE_OBJ reaches the printer driver 2022. Therefore, until the next escape is issued (S11060), the printer driver 2022 determines that the rendering in S11050 is an image object.

S11060でアプリケーション2010は、エスケープを使って以下に続く描画が全てグラフィックオブジェクトであることをプリンタドライバ2022に通知する。つまりエスケープコードGRAPHIC_OBJがプリンタドライバ2022に届く。このため次のエスケープが発行されるまで(S11080)、プリンタドライバ2022はS11070の描画をイメージオブジェクトと判別する。   In step S <b> 11060, the application 2010 notifies the printer driver 2022 that the following drawing is a graphic object using escape. That is, the escape code GRAPHIC_OBJ reaches the printer driver 2022. Therefore, until the next escape is issued (S11080), the printer driver 2022 determines that the drawing in S11070 is an image object.

S11080でアプリケーション2010は、エスケープを使って以下に続く描画を判定しないようにプリンタドライバ2022に通知する。つまりエスケープコードUNKNOWN_OBJがプリンタドライバ2022に届く。このためプリンタドライバ2022はS11090の描画がグラフィックコマンドであるのでグラフィックオブジェクトと判別する。   In step S11080, the application 2010 notifies the printer driver 2022 not to determine the subsequent drawing using escape. That is, the escape code UNKNOWN_OBJ reaches the printer driver 2022. Therefore, the printer driver 2022 determines that the drawing in S11090 is a graphic object because the drawing is a graphic command.

(他の実施形態)
なお、本発明は、複数の機器(例えばホストコンピュータ、インタフェイス機器、リーダ、プリンタなど)から構成されるシステムに適用しても、一つの機器からなる装置(例えば、複写機、ファクシミリ装置など)に適用してもよい。
(Other embodiments)
Note that the present invention can be applied to a system including a plurality of devices (for example, a host computer, an interface device, a reader, and a printer), and a device (for example, a copying machine and a facsimile device) including a single device. You may apply to.

また、本発明の目的は、前述した実施形態の機能を実現するソフトウェアのプログラムコードを記録した記憶媒体(または記録媒体)を、システムあるいは装置に供給し、そのシステムあるいは装置のコンピュータ(またはCPUやMPU)が記憶媒体に格納されたプログラムコードを読み出し実行することによっても、達成されることは言うまでもない。この場合、記憶媒体から読み出されたプログラムコード自体が前述した実施形態の機能を実現することになり、そのプログラムコードを記憶した記憶媒体は本発明を構成することになる。また、コンピュータが読み出したプログラムコードを実行することにより、前述した実施形態の機能が実現されるだけでなく、そのプログラムコードの指示に基づき、コンピュータ上で稼働しているオペレーティングシステム(OS)などが実際の処理の一部または全部を行い、その処理によって前述した実施形態の機能が実現される場合も含まれることは言うまでもない。   Another object of the present invention is to supply a storage medium (or recording medium) in which a program code of software that realizes the functions of the above-described embodiments is recorded to a system or apparatus, and the computer (or CPU or CPU) of the system or apparatus. Needless to say, this can also be achieved by the MPU) reading and executing the program code stored in the storage medium. In this case, the program code itself read from the storage medium realizes the functions of the above-described embodiments, and the storage medium storing the program code constitutes the present invention. Further, by executing the program code read by the computer, not only the functions of the above-described embodiments are realized, but also an operating system (OS) running on the computer based on the instruction of the program code. It goes without saying that a case where the function of the above-described embodiment is realized by performing part or all of the actual processing and the processing is included.

さらに、記憶媒体から読み出されたプログラムコードが、コンピュータに挿入された機能拡張カードやコンピュータに接続された機能拡張ユニットに備わるメモリに書込まれた後、そのプログラムコードの指示に基づき、その機能拡張カードや機能拡張ユニットに備わるCPUなどが実際の処理の一部または全部を行い、その処理によって前述した実施形態の機能が実現される場合も含まれることは言うまでもない。   Furthermore, after the program code read from the storage medium is written into a memory provided in a function expansion card inserted into the computer or a function expansion unit connected to the computer, the function is determined based on the instruction of the program code. It goes without saying that the CPU or the like provided in the expansion card or the function expansion unit performs part or all of the actual processing and the functions of the above-described embodiments are realized by the processing.

印刷処理におけるGDIからプリンタドライバまでの描画処理例1。Drawing Example 1 from GDI to Printer Driver in Print Processing 印刷処理におけるGDIからプリンタドライバまでの描画処理例2。Drawing process example 2 from GDI to printer driver in print process. 印刷処理におけるGDIからプリンタドライバまでの描画処理例3。Drawing 3 from the GDI to the printer driver in the printing process 本実施形態におけるホストシステム構成図。The host system block diagram in this embodiment. プリンタドライバによる印刷処理フロー図。FIG. 7 is a flowchart of print processing by a printer driver. アプリケーションとGDIとプリンタドライバの構成図。The block diagram of an application, GDI, and a printer driver. 本発明の第一実施形態を示すエスケープ・コマンドの処理フロー図。The processing flow figure of the escape command which shows 1st embodiment of this invention. 本発明の第一実施形態を示すテキスト・コマンドの処理フロー図。The processing flow figure of the text command which shows 1st embodiment of this invention. 本発明の第一実施形態を示すイメージ・コマンドの処理フロー図。The processing flow figure of the image command which shows 1st embodiment of this invention. 本発明の第一実施形態を示すグラフィック・コマンドの処理フロー図。FIG. 3 is a processing flow diagram of a graphic command showing the first embodiment of the present invention. 描画処理の遷移状態例。Example of transition state of drawing process.

Claims (9)

描画すべきオブジェクトの種類を識別し、識別したオブジェクトの種類に応じて描画を行う画像処理方法であって、オブジェクトの描画を指示するコマンドによらず、外部のプログラムより指定されたオブジェクトの種類によって描画オブジェクトを識別することを特徴とする画像処理方法。   An image processing method for identifying the type of an object to be drawn and performing drawing according to the identified type of object, depending on the type of object specified by an external program, regardless of a command for drawing the object An image processing method characterized by identifying a drawing object. 描画を指示するコマンドを入力し、該入力コマンドによって指示される描画すべきオブジェクトの種類によらず、外部のプログラムより指定されたオブジェクトの種類によって描画オブジェクトを識別し、識別されたオブジェクトの種類に応じて描画を行うことを特徴とする画像処理方法。   A command for instructing drawing is input, the drawing object is identified by the type of object specified by an external program, regardless of the type of object to be drawn instructed by the input command, and the type of the identified object is determined. An image processing method characterized by performing drawing in response. 前記描画処理には色処理が含まれることを特徴とする請求項1又は請求項2に記載された画像処理方法。   The image processing method according to claim 1, wherein the drawing processing includes color processing. 描画すべきオブジェクトの種類を識別し、識別したオブジェクトの種類に応じて描画を行う画像処理装置であって、オブジェクトの描画を指示するコマンドによらず、外部のプログラムより指定されたオブジェクトの種類によって描画オブジェクトを識別する識別手段を有することを特徴とする画像処理装置。   An image processing apparatus that identifies the type of an object to be drawn and performs drawing according to the identified type of object, depending on the type of object specified by an external program, regardless of a command for drawing the object An image processing apparatus having an identification unit for identifying a drawing object. 描画を指示するコマンドを入力する入力手段と、入力コマンドによって指示される描画すべきオブジェクトの種類をよらず、外部のプログラムより指定されたオブジェクトの種類によって描画オブジェクトを識別することを特徴とする画像処理装置。   An image characterized by identifying a drawing object by an input means for inputting a command for instructing the drawing and an object type designated by an external program, regardless of the type of the object to be drawn instructed by the input command. Processing equipment. 前記描画処理には色処理が含まれることを特徴とする請求項4又は請求項5に記載された画像処理方法。   The image processing method according to claim 4, wherein the drawing processing includes color processing. 描画すべきオブジェクトの種類を識別する際、オブジェクトの描画を指示するコマンドによらず、外部のプログラムより指定されたオブジェクトの種類によって描画オブジェクトを識別することを特徴とするプログラム。   A program characterized in that, when identifying the type of an object to be drawn, a drawing object is identified by the type of object specified by an external program, without using a command for instructing the drawing of the object. 画像処理のプログラムであって、前記プログラムは少なくとも、描画オブジェクトの種類を指示するコマンドを入力するステップのコードと、描画を指示するコマンドを入力するステップのコードと、入力コマンドによって指示される描画すべきオブジェクトの種類を識別するステップのコードと、識別されたオブジェクトの種類に応じて描画を行うステップのコードとを有することを特徴とするプログラム。   An image processing program, wherein the program includes at least a code for inputting a command for instructing a type of a drawing object, a code for a step for inputting a command for instructing a drawing, and a drawing instructed by the input command. What is claimed is: 1. A program comprising: a code for identifying a type of an object to be processed; and a code for performing a drawing in accordance with the identified type of object. 請求項7又は請求項8に記載されたプログラムを記録したことを特徴とする媒体。   A medium on which the program according to claim 7 or 8 is recorded.
JP2004030118A 2004-02-06 2004-02-06 Image processor and image processing method Withdrawn JP2005222346A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2004030118A JP2005222346A (en) 2004-02-06 2004-02-06 Image processor and image processing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2004030118A JP2005222346A (en) 2004-02-06 2004-02-06 Image processor and image processing method

Publications (1)

Publication Number Publication Date
JP2005222346A true JP2005222346A (en) 2005-08-18

Family

ID=34997919

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2004030118A Withdrawn JP2005222346A (en) 2004-02-06 2004-02-06 Image processor and image processing method

Country Status (1)

Country Link
JP (1) JP2005222346A (en)

Similar Documents

Publication Publication Date Title
US7839531B2 (en) Printing control method
EP2109066B1 (en) Image output apparatus
US8054493B2 (en) Optimizing raster operation functions during print job processing
US8724153B2 (en) Information processing apparatus, method of information processing, and storage mediurn for performing scaling processing on image data
JP2002041261A (en) Information processing device, information processing method, and storage medium which stores computer- readable program
US20170364317A1 (en) Information processing apparatus, information processing method, and storage medium
JP2003320715A (en) Information processing apparatus, information processing system, method for controlling information output, storage medium, and program
JP2005084898A (en) Print data processing system and program for this system
EP1128329B1 (en) Image processing apparatus and method
US6912066B2 (en) Image processing method and apparatus for performing processing according to the type of rendering command, and program implementing image processing method
US10140558B2 (en) Print control system, print control apparatus, and program
US8804141B2 (en) Character output device, character output method and computer readable medium
US20180060003A1 (en) Control method and information processing apparatus
US8098385B2 (en) Spool file modifying device
JP6437076B2 (en) Information processing apparatus, control method therefor, and program
JP2005070957A (en) Conversion control unit and conversion control program
US20150262043A1 (en) Information processing apparatus, information processing method, and information processing system
JP2012155415A (en) Printing system
JP3927766B2 (en) Image processing apparatus and method
JP2005222346A (en) Image processor and image processing method
US7196812B2 (en) Information processing apparatus and control code generation method
JP3359317B2 (en) Image processing method and recording medium
JP4522006B2 (en) Information processing apparatus, information processing method, and printer driver program
JP2005222345A (en) Image processor and its method
US8358435B2 (en) Image processing device and recording medium containing program therefor

Legal Events

Date Code Title Description
A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20070501