JP2012213861A - Print data processor and print data processing program - Google Patents
Print data processor and print data processing program Download PDFInfo
- Publication number
- JP2012213861A JP2012213861A JP2011079015A JP2011079015A JP2012213861A JP 2012213861 A JP2012213861 A JP 2012213861A JP 2011079015 A JP2011079015 A JP 2011079015A JP 2011079015 A JP2011079015 A JP 2011079015A JP 2012213861 A JP2012213861 A JP 2012213861A
- Authority
- JP
- Japan
- Prior art keywords
- pixel
- character
- color tone
- background
- pixels
- 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
- Electronic Switches (AREA)
- Record Information Processing For Printing (AREA)
Abstract
Description
本発明は、複数の発熱素子が設けられたサーマルヘッドを備えるサーマルプリンタに好適に利用できる印刷データ処理装置及び印刷データ処理プログラムに関する。 The present invention relates to a print data processing apparatus and a print data processing program that can be suitably used in a thermal printer including a thermal head provided with a plurality of heating elements.
一般に、サーマルプリンタは複数の発熱素子を有したサーマルヘッドを備え、その各発熱素子に通電を行うことで発熱させ、感熱紙を発色させるか又は熱溶解性のインクを印刷媒体に所定のパターンに転写して印字を行う。 In general, a thermal printer includes a thermal head having a plurality of heating elements, and heat is generated by energizing each heating element to develop color on thermal paper or to form a heat-dissolving ink in a predetermined pattern on a printing medium. Transfer and print.
ところで、発熱素子は印字が進むにつれて熱を蓄える。故に例えば背景画像上に文字を重ねた画像を印刷する場合、文字を印字する際に文字に隣接する背景画素が発熱素子に蓄えられた熱によって発色し、文字と背景との境目において混色が生じることがある。ベタ領域が連続するような場合に蓄熱による色むらやにじみが発生することがあり、これを防止するためにベタ領域の間引きを行う方法が提案されている(例えば、特許文献1参照)。 By the way, a heat generating element accumulates heat as printing progresses. Therefore, for example, when printing an image in which characters are superimposed on a background image, the background pixels adjacent to the characters are colored by the heat stored in the heating element when the characters are printed, and color mixing occurs at the boundary between the characters and the background. Sometimes. When solid areas are continuous, color unevenness and blurring due to heat storage may occur. To prevent this, a method of thinning out the solid areas has been proposed (see, for example, Patent Document 1).
しかしながら、特許文献1に記載の方法は、ベタ領域が連続した際にベタ領域の間引きを行うだけである。故に文字と背景との境目において混色が生じることを防止できなかった。
However, the method described in
本発明の目的は、文字と背景との境目において混色が生じることを防ぐことができる印刷データ処理装置及び印刷データ処理プログラムを提供することである。 An object of the present invention is to provide a print data processing apparatus and a print data processing program that can prevent color mixing at the boundary between a character and a background.
本発明の第一態様に係る印刷データ処理装置は、サーマルプリンタを用いて印刷媒体に文字を印刷する為の画像データであって、前記文字を構成する文字画素と前記文字の背景を構成する背景画素とを含む画像データから、前記背景画素と境界をなす位置にある前記文字画素を輪郭画素として抽出する画素抽出手段と、前記画素抽出手段によって抽出された前記輪郭画素に沿って少なくとも1画素の幅で前記背景画素の色調を白色に変換する色調変換手段とを備える。本態様では、文字の輪郭に沿って白抜き部を形成できる。故に、文字と背景との境目において混色が生じるのを防止できる。 A print data processing apparatus according to a first aspect of the present invention is image data for printing a character on a print medium using a thermal printer, and a background constituting a character pixel constituting the character and a background of the character Pixel extraction means for extracting the character pixel at a position that makes a boundary with the background pixel from the image data including the pixel as a contour pixel; and at least one pixel along the contour pixel extracted by the pixel extraction means Color tone conversion means for converting the color tone of the background pixel to white by width. In this aspect, a white portion can be formed along the outline of the character. Therefore, color mixing can be prevented from occurring at the boundary between the character and the background.
また、第一態様において、前記サーマルプリンタが備えるサーマルヘッドの温度を検知する温度検知手段と、前記温度検知手段の検知結果に応じて、前記色調変換手段が前記背景画素の色調を白色に変換する幅分の画素数を算出する第一算出手段とを備え、前記色調変換手段は、前記第一算出手段が算出した画素数の幅で前記背景画素の色調を白色に変換するようにしても良い。本態様では、サーマルヘッドの温度に応じて色調を白色に変換する幅分の画素数が算出される。サーマルヘッドの温度が高い時は混色が発生しやすい。この場合、色調を白色に変換する幅分の画素数を増やす。故に文字と背景との境目において混色が生じるのを防止できる。 In the first aspect, the temperature detection means for detecting the temperature of the thermal head provided in the thermal printer, and the color tone conversion means converts the color tone of the background pixel to white according to the detection result of the temperature detection means. First color calculation means for calculating the number of pixels corresponding to the width, and the color tone conversion means may convert the color tone of the background pixel to white with the width of the pixel number calculated by the first calculation means. . In this aspect, the number of pixels corresponding to the width for converting the color tone to white is calculated according to the temperature of the thermal head. Color mixing is likely to occur when the temperature of the thermal head is high. In this case, the number of pixels corresponding to the width for converting the color tone to white is increased. Therefore, it is possible to prevent color mixing at the boundary between the character and the background.
また、第一態様において、前記サーマルプリンタによる印刷時の前記印刷媒体の送り方向を下流方向、その反対方向を上流方向とした場合、前記色調変換手段は、前記輪郭画素の前記上流方向に位置する前記背景画素の色調を白色に変換する幅分の画素数を、前記下流方向に位置する前記背景画素の色調を白色に変換する幅分の画素数より多くするようにしても良い。本態様では、混色が発生し易い上流方向に位置する背景画素において、色調を白色に変換する幅分の画素数を多くする。故に文字と背景との境目において混色が生じるのを防止できる。 In the first aspect, when the print medium feeding direction during printing by the thermal printer is a downstream direction, and the opposite direction is an upstream direction, the color tone conversion means is located in the upstream direction of the contour pixel. The number of pixels corresponding to the width for converting the color tone of the background pixel to white may be larger than the number of pixels corresponding to the width for converting the color tone of the background pixel located in the downstream direction to white. In this aspect, the number of pixels corresponding to the width for converting the color tone to white is increased in the background pixels located in the upstream direction where color mixing is likely to occur. Therefore, it is possible to prevent color mixing at the boundary between the character and the background.
また、第一態様において、前記サーマルプリンタによって印刷された印刷枚数を数える計数手段と、前記計数手段の計数結果に応じて、前記色調変換手段が前記背景画素の色調を白色に変換する幅分の画素数を算出する第二算出手段とを備え、前記色調変換手段は、前記第二算出手段が算出した画素数の幅で前記背景画素の色調を白色に変換するようにしても良い。本態様では、印刷枚数に応じて色調を白色にする幅分の画素数が算出される。故に連続印刷によりサーマルヘッドの温度が高くなっても、文字と背景との境目において混色が生じるのを防止できる。 Further, in the first aspect, the counting means for counting the number of printed sheets printed by the thermal printer, and the color conversion means converts the color tone of the background pixel to white according to the counting result of the counting means. A second calculation unit that calculates the number of pixels, and the color tone conversion unit may convert the color tone of the background pixel to white with a width of the number of pixels calculated by the second calculation unit. In this aspect, the number of pixels corresponding to the width that makes the color tone white is calculated according to the number of printed sheets. Therefore, even if the temperature of the thermal head increases due to continuous printing, color mixing can be prevented from occurring at the boundary between the character and the background.
本発明の第二態様に係る印刷データ処理プログラムは、サーマルプリンタを用いて印刷媒体に文字を印刷する為の画像データであって、前記文字を構成する文字画素と前記文字の背景を構成する背景画素とを含む画像データから、前記背景画素と境界をなす位置にある前記文字画素を輪郭画素として抽出する画素抽出ステップと、前記画素抽出ステップにおいて、抽出された前記輪郭画素に沿って少なくとも1画素の幅で前記背景画素の色調を白色に変換する色調変換ステップとをコンピュータに実行させる。本態様の印刷データ処理プログラムをコンピュータに実行させることで、文字の輪郭に沿って白抜き部を形成できる。故に、文字と背景との境目において混色が生じるのを防止できる。 A print data processing program according to a second aspect of the present invention is image data for printing a character on a print medium using a thermal printer, and a background constituting a character pixel constituting the character and a background of the character A pixel extraction step for extracting the character pixel at a position that forms a boundary with the background pixel from the image data including the pixel as a contour pixel; and at least one pixel along the contour pixel extracted in the pixel extraction step And a color tone conversion step of converting the color tone of the background pixel to white with a width of. By causing the computer to execute the print data processing program of this aspect, it is possible to form a white portion along the outline of the character. Therefore, color mixing can be prevented from occurring at the boundary between the character and the background.
以下、本発明の第1実施形態である印字装置1について、図面を参照して説明する。これらの図面は、本発明が採用しうる技術的特徴を説明するために用いられるものであり、記載されている装置、装置の構成、各種処理のフローチャートなどは単なる説明例である。
Hereinafter, a
図1を参照して、印字装置1の物理的構成について説明する。印字装置1は上面の前側に、キーボード6、液晶ディスプレイ7(以下LCD7という)を設けている。キーボード6は、文字入力キー2、印字キー3、リターンキー4、カーソルキー10等を備える。印字装置1は上面の後ろ側にカセット収納部8を設けている。カセット収納部8はテープカセット(図示略)を収納する。カセット収納部8は収納カバー8Aで覆われている。カセット収納部8には、サーマルヘッド9を設けてある。サーマルヘッド9は複数の発熱素子を備える。印字装置1は発熱素子の通電量を制御して発熱させる。発熱するサーマルヘッド9に対して感熱紙等の印字媒体が搬送される。サーマルヘッド9に接触した印字媒体に所定の印字が行われる。カセット収納部8の左側面部にはラベル排出口16が形成されている。ラベル排出口16は印字された印字媒体を排出する。キーボード6の下方には、制御基板12が配設されている。
A physical configuration of the
図2を参照して、印字装置1の電気的構成について説明する。印字装置1は、制御基板12(図1参照)上に制御回路部20を備えている。制御回路部20は、CPU21と、CPU21にデータバス22を介して接続した入出力インタフェース23、CGROM24、ドットパターン用のROM25、ROM26、及びRAM27等を備える。
The electrical configuration of the
CGROM24には、複数のキャラクタの各々について、表示用のドットパターンデータがコードデータに対応して記憶されている。ROM25には、アルファベット文字や記号等のキャラクタを印刷するための複数のキャラクタの各々について、印刷用ドットパターンデータが、書体(ゴシック系書体、明朝体書体等)毎に分類され、書体毎に6種類(16、24、32、48、64、96のドットサイズ)の印刷文字サイズ分、コードデータに対応して格納されている。ROM25には、グラフィック画像を印刷するためのグラフィックパターンデータも記憶されている。
The CGROM 24 stores dot pattern data for display corresponding to code data for each of a plurality of characters. The
ROM26には、文字入力キー2から入力された文字や数字等のキャラクタのコードデータに対応して後述するLCDC28を制御する表示駆動制御プログラム、後述する印字バッファ272のデータを読み出してサーマルヘッド9や後述するテープ送りモータ30を駆動する印字駆動制御プログラム等の各処理を実行するプログラムが記憶されている。
The
RAM27には、テキストメモリ271、印字バッファ272、ライン印字ドット数メモリ273、総印字ドット数メモリ274、画素メモリ275、及び印字枚数メモリ276等が設けられている。テキストメモリ271には、文字入力キー2から入力された文字データが格納される。印字バッファ272には、複数の文字や記号等の印字用ドットパターンや各ドットの形成エネルギ量である印加パルス数等がドットパターンデータとして記憶される。ライン印字ドット数メモリ273には、サーマルヘッド9により印字される1ライン分の印字ドット数のカウント値が格納される。総印字ドット数メモリ274には、サーマルヘッド9により印字される起動時からの総印字ドット数が記憶される。画素メモリ275には、後述する抽出された画素の座標データ等が記憶される。印字枚数メモリ276には、印字枚数センサ32によって計数された被印字媒体である用紙の印字枚数が記憶される。
The
入出力インタフェース23には、キーボード6、サーミスタ13、ディスプレイコントローラ(以下LCDCという)28、サーマルヘッド9を駆動するための駆動回路29と、テープ送りモータ30を駆動するための駆動回路31、及び印字枚数センサ32等が各々接続されている。サーミスタ13は、サーマルヘッド9の温度を検出する。LCDC28は、LCD7に表示データを出力するためのビデオRAM281を有する。印字枚数センサ32は、印字された用紙の枚数を検出する。キーボード6の文字キーを介して文字等が入力された場合、そのテキスト(文書データ)がテキストメモリ271に順次記憶されていくとともに、ドットパターン発生制御プログラム及び表示駆動制御プログラムに基づいてキーボード6を介して入力された文字等に対応するドットパターンがLCD7上に表示される。サーマルヘッド9は駆動回路29を介して駆動され、印字バッファ272に記憶されたドットパターンデータの印字を行い、これと同期してテープ送りモータ30が駆動回路31を介してテープの送り制御を行う。
The input /
図3のフローを参照して、CPU21が実行する印字処理について説明する。この処理はCPU21がROM26に記憶されているプログラムを実行することにより実現される。CPU21はRAM27の各メモリに記憶されているデータの初期化を行い(S11)、印字枚数メモリ276に記憶されている印字枚数を示す変数Nの値を0に設定する(S13)。次に、キーボード6を介して背景変更の指示がなされたか否かを判断する(S15)。背景変更の指示がなされたと判断した場合(S15:YES)、ROM25に記憶されているグラフィックパターンデータによって背景画像を変更し(S17)、印字枚数を示す変数Nを0に設定し(S19)、ステップS57に進む。
The printing process executed by the
一方、ステップS15で、背景変更の指示がなされなかったと判断した場合(S15:NO)、文字入力キー2から文字入力がなされたか否かを判断する(S21)。文字入力がなされたと判断した場合(S21:YES)、ROM25に記憶したドットパターンデータを用いて文字データを作成し(S23)、テキストメモリ271(図2参照)に記憶する。次に、印字枚数を示す変数Nを0に設定し(S25)、ステップS57に進む。一方、ステップS21で、文字入力がなされていないと判断した場合(S21:NO)、リターンキー4を介して文字の輪郭補正を行うデータ処理の指示がなされたか否かを判断する(S27)。データ処理の指示がなされたと判断した場合(S27:YES)、図4に示す印字データ処理を行う(S29)。次に、印字データ処理で処理された印字データをテキストメモリ271に送信し(S50)、ステップS57に進む。一方、データ処理の指示がなされなかったと判断した場合(S27:NO)、ユーザからの指示に従って内部データ変更等のその他の処理を実行し(S53)、印字枚数を示す変数Nの値を0にし(S55)、ステップ57に進む。 On the other hand, if it is determined in step S15 that an instruction to change the background has not been given (S15: NO), it is determined whether or not a character is input from the character input key 2 (S21). If it is determined that a character has been input (S21: YES), character data is created using the dot pattern data stored in the ROM 25 (S23) and stored in the text memory 271 (see FIG. 2). Next, a variable N indicating the number of prints is set to 0 (S25), and the process proceeds to step S57. On the other hand, if it is determined in step S21 that no character has been input (S21: NO), it is determined whether or not an instruction for data processing for correcting the contour of the character has been issued via the return key 4 (S27). If it is determined that the data processing instruction has been issued (S27: YES), the print data processing shown in FIG. 4 is performed (S29). Next, the print data processed in the print data processing is transmitted to the text memory 271 (S50), and the process proceeds to step S57. On the other hand, if it is determined that the data processing instruction has not been given (S27: NO), other processing such as internal data change is executed according to the instruction from the user (S53), and the value of the variable N indicating the number of prints is set to zero. (S55), the process proceeds to step 57.
図4のフローを参照して、図3のステップS29で行われる印字データ処理について説明する。この処理はCPU21がROM26に記憶されているプログラムを実行することにより実現される。背景画素とは、背景画像を構成する画素をいう。輪郭画素とは、文字画素であって隣接する上下左右の画素のいずれかが背景画素である画素をいう。CPU21は、先ずテキストメモリ271に文字データが記憶されているか否かを判断し(S31)、文字データが記憶されていないと判断した場合(S31:NO)、処理を終了し、図3のステップS29に戻る。一方、文字データが記憶されていると判断した場合(S31:YES)、各文字を構成する文字画素の中から輪郭画素を抽出する処理である輪郭画素抽出処理を行う(S33)。
The print data processing performed in step S29 in FIG. 3 will be described with reference to the flow in FIG. This process is realized by the
図5のフローを参照して、図4のステップS33で実行される輪郭画素抽出処理について説明する。この処理はCPU21がROM26に記憶されているプログラムを実行することにより実現される。CPU21は、先ずテキストメモリ271に記憶されている文字データを元に各文字を構成する文字画素を抽出し(S331)、画素メモリ275に記憶する。次に、画素メモリ275に記憶されている文字画素の1つに対して上下左右にある画素の全てが文字画素であるか否かを判断する(S333)。例えば、図6(a)に示す文字画素Lに対して、文字画素Lの上側にある画素L5、文字画素Lの右側にある画素L6、文字画素Lの下側にある画素L7、及び文字画素Lの左側にある画素L8の全てが文字画素であるか否かを判断する。なお、この判断は、画素L5の座標、画素L6の座標、画素L7の座標、及び画素L8の座標と文字画素の座標とを照合させることによって行われる。
With reference to the flow of FIG. 5, the outline pixel extraction process executed in step S33 of FIG. 4 will be described. This process is realized by the
抽出した文字画素の隣接する上下左右の画素のうち少なくとも1つが背景画素であった場合(S333:NO)、その抽出した文字画素を輪郭画素に設定し(S335)、座標をテキストメモリ271に記憶し、ステップ337に進む。一方、ステップS333で、隣接する上下左右の全ての画素が文字画素であると判断した場合(S333:YES)、ステップS337に進む。例えば、図6(a)に示す文字画素Lにおいて、画素L5及び画素L8は文字画素ではないので、画素Lは輪郭画素として設定され画素メモリ275に記憶される。CPU21は全ての文字画素を抽出したか否か判断する(S337)つまり、各文字を構成する文字画素の全てに対して上下左右にある画素の全てが文字画素であるか否かの判断を行ったか否かを判断する。この判断は、文字画素の座標に基づいて行われる。全ての文字画素の抽出を完了していないと判断した場合(S337:NO)、ステップS331に戻り、全ての文字画素を抽出するまでステップS331〜ステップS337を繰り返す。一方、全ての文字画素に対して行ったと判定した場合(S337:YES)、処理を終了し、図4のステップS33に戻る。次に、図4において、図5のステップS335で設定され画素メモリ275に記憶された輪郭画素の座標を画素メモリ275から読み出し(S35)、ステップS37の隣接画素補正処理1に進む。
When at least one of the upper, lower, left, and right pixels adjacent to the extracted character pixel is a background pixel (S333: NO), the extracted character pixel is set as a contour pixel (S335), and the coordinates are stored in the
図7のフローを参照して、隣接画素補正処理1について説明する。なお以下説明では、被印字媒体の搬送方向を下流方向、被印刷媒体の搬送方向と反対の方向を上流方向という。CPU21は、図6(a)に示すように、輪郭画素R1(Xn,Yn)に隣接する第1隣接画素A1の座標(Xn−1、Yn)を抽出する(S371)。第1隣接画素とは、背景画像を構成する画素であって、輪郭画素に隣接する画素をいう。次に、第1隣接画素A1の下流方向にある画素C1(X−2,Yn)が輪郭画素であるか否かを判断する(S373)。この判断は、画素C1の座標と画素メモリ275に記憶されている輪郭画素の座標とを照合することによって行われる。ここで、画素C1は輪郭画素でないので(S373:NO)、第1隣接画素A1のみ色調を白色に設定する(S383)。また、輪郭画素R1の隣接画素には、第1隣接画素A2もあるので(S381:NO)、第1隣接画素A2の座標(Xn、Yn+1)も抽出される(S371)。第1隣接画素A2の下流方向にある画素は輪郭画素ではないので(S373:NO)、第1隣接画素A2のみ色調を白色に設定する(S383)。なお、第1隣接画素A2は、輪郭画素R1と輪郭画素R2との共通の第1隣接画素であるが、第1隣接画素A2に対する処理は、輪郭画素R1と輪郭画素R2のそれぞれで行われるものとする。
The adjacent
一方、輪郭画素R3(Xn,Yn)に隣接する第1隣接画素A4の座標(Xn+1,Yn)を抽出すると(S371)、第1隣接画素A4の下流方向にある画素は輪郭画素R3であるので(S373:YES)、第1隣接画素A4の上流方向にある画素B1の座標(Xn+2,Yn)(以下、「第2隣接画素」という。)を抽出する(S375)。ここで、第2隣接画素とは第1隣接画素と隣接するが、輪郭画素とは隣接しない画素をいう。次に、第1隣接画素A4の色調を白色に設定し(S377)、第2隣接画素B1の色調を白色に設定し(S379)、ステップS381に進む。また、輪郭画素R3に隣接する画素には第1隣接画素A3(Xn,Yn+1)もあり、第1隣接画素A3の下流方向にある画素C2(Xn−1,Yn+1)は輪郭画素でないので(S373:NO)、第1隣接画素A3のみ色調を白色に設定し(S383)、ステップS381に進む。 On the other hand, when the coordinates (Xn + 1, Yn) of the first adjacent pixel A4 adjacent to the contour pixel R3 (Xn, Yn) are extracted (S371), the pixel in the downstream direction of the first adjacent pixel A4 is the contour pixel R3. (S373: YES), the coordinates (Xn + 2, Yn) of the pixel B1 in the upstream direction of the first adjacent pixel A4 (hereinafter referred to as “second adjacent pixel”) are extracted (S375). Here, the second adjacent pixel is a pixel adjacent to the first adjacent pixel, but not adjacent to the contour pixel. Next, the color tone of the first adjacent pixel A4 is set to white (S377), the color tone of the second adjacent pixel B1 is set to white (S379), and the process proceeds to step S381. Further, the pixels adjacent to the contour pixel R3 include the first adjacent pixel A3 (Xn, Yn + 1), and the pixel C2 (Xn-1, Yn + 1) in the downstream direction of the first adjacent pixel A3 is not a contour pixel (S373). : NO), the color tone of only the first adjacent pixel A3 is set to white (S383), and the process proceeds to step S381.
ステップ381では、全ての第1隣接画素を抽出したか否かを判断する(S381)。この判断は、第1隣接画素の座標に基づいて行われる。全ての第1隣接画素を抽出していない場合(S381:NO)、ステップS371に戻り、全ての第1隣接画素を抽出するまで、ステップS371〜ステップS383を繰り返す。一方、全ての第1隣接画素を抽出したと判断した場合(S381:YES)、処理を終了し、図4のステップS37に戻り、ステップS39に進む。なお、隣接画素補正処理1を行うことによって、図6(b)に示すように、輪郭画素の下流方向にある背景画素に対しては1画素分(例えば、第1隣接画素A1及び第1隣接画素A2)だけ白色に設定される。一方、輪郭画素の上流方向にある背景画素に対しては2画素分(例えば、第1隣接画素A4及び第2隣接画素B1)だけ白色に設定される。
In step 381, it is determined whether all the first adjacent pixels have been extracted (S381). This determination is made based on the coordinates of the first adjacent pixel. If all the first adjacent pixels have not been extracted (S381: NO), the process returns to step S371, and steps S371 to S383 are repeated until all the first adjacent pixels are extracted. On the other hand, if it is determined that all the first adjacent pixels have been extracted (S381: YES), the process ends, the process returns to step S37 in FIG. 4, and the process proceeds to step S39. By performing the adjacent
図4のステップS39では、全ての輪郭画素を抽出したか否かを判断し、全ての輪郭画素を抽出していないと判断した場合(S39:NO)、ステップS35に戻り、全ての輪郭画素を抽出するまでステップS35〜ステップS39を繰り返す。一方、全ての輪郭画素を抽出したと判断した場合(S39:YES)、背景画像と文字データとを合成して印字バッファ272に保存し(S41)、図3のステップS29に戻り、前述したステップS50の処理を行い、ステップS57に進む。 In step S39 of FIG. 4, it is determined whether or not all the contour pixels have been extracted. If it is determined that all the contour pixels have not been extracted (S39: NO), the process returns to step S35, and all the contour pixels are determined. Steps S35 to S39 are repeated until extraction. On the other hand, if it is determined that all the contour pixels have been extracted (S39: YES), the background image and the character data are combined and stored in the print buffer 272 (S41), and the process returns to step S29 in FIG. The process of S50 is performed, and the process proceeds to step S57.
ステップS57では、リターンキー4を介して印字指示があるか否かを判断し、印字指示がある場合(S57:YES)、印字バッファ272から印字データを読み出して印字を実行し(S59)、変数Nに1を加えて(S61)、ステップ63に進む。一方、印字指示がない場合(S57:NO)、ステップS15に戻って、処理を繰り返す。ステップ63では、ユーザによるキーボード6の操作により印字処理の終了指示があるか否かを判断する。CPU21は終了指示があったと判断した場合(S63:YES)、処理を終了する。一方、終了指示がないと判断した場合(S63:NO)、ステップS15に戻って、処理を繰り返す。
In step S57, it is determined whether or not there is a print instruction via the return key 4. If there is a print instruction (S57: YES), the print data is read from the
以上説明したように、第1実施形態の印字装置1では、サーマルヘッド9が蓄熱した場合でも、印字時にサーマルヘッド9に熱を加える必要のない白色領域が設定される。白色領域では、サーマルヘッド9が冷やされる。故に背景と文字との境目において生じる混色を防止できる。さらに、混色が発生し易い上流方向に位置する背景画素において、色調を白色に変換する幅分の画素数を多くする。これにより、文字と背景との境目に生じる混色をより確実に防止できる。
As described above, in the
次に、本発明の第2実施形態である印刷装置について説明する。第2実施形態の印刷装置のCPUは、図4の印字データ処理のS37において、隣接画素補正処理2を実行する。隣接画素補正処理2は、サーマルヘッド9の温度及び印字枚数に基づき、白色にする背景画素数を変化させる。なお、第2実施形態の印刷装置の外観的構成及び電気的構成は第1実施形態と同じである。
Next, a printing apparatus according to the second embodiment of the present invention will be described. The CPU of the printing apparatus according to the second embodiment executes the adjacent
図8のフローを参照して、CPUが実行する隣接画素補正処理2について説明する。この処理はCPUがROM26に記憶されているプログラムを実行することにより実現される。CPUは、図9(a)に示すように輪郭画素R(Xn,Yn)に隣接する第1隣接画素A1の座標(Xn−1、Yn)を抽出し(S400)、第1隣接画素A1の色調を白色に設定し(S401)、画素メモリ275に記憶する。次に、サーミスタ13によってサーマルヘッド9の温度を検知することにより、サーマルヘッド9の温度が65℃以上であるか否かの判断を行い(S402)、65℃以上であると判断した場合(S402:YES)、ステップS407に進む。一方、65℃未満であると判断した場合(S402:NO)、印字枚数センサ32(図2参照)によって数えられ印字枚数メモリ276に記憶されている印字枚数を示す変数Nの値が3以上であるか否かを判断する(S403)。Nの値が3未満である場合(S403:NO)、ステップS405に進む。一方、Nの値が3枚以上である場合(S403:YES)、ステップS407に進む。
The adjacent
ステップS407では、図9(a)に示すように第1隣接画素A1と下流方向で隣接する第2隣接画素B1の座標(Xn−2,Yn)を抽出し(S407)、抽出した第2隣接画素B1の色調を白色に設定し、画素メモリ275に記憶する(S408)。次に、第2隣接画素を全て抽出したか否かを判断する(S409)。例えば、図9(a)において、第1隣接画素A1に隣接する第2隣接画素B2があるので(S409:NO)、ステップS407に戻り、ステップS407〜ステップS409を実行する。一方、全ての第2隣接画素を抽出したと判断した場合(S409:YES)、ステップS405に進む。 In step S407, as shown in FIG. 9A, the coordinates (Xn-2, Yn) of the second adjacent pixel B1 adjacent to the first adjacent pixel A1 in the downstream direction are extracted (S407), and the extracted second adjacent The color tone of the pixel B1 is set to white and stored in the pixel memory 275 (S408). Next, it is determined whether all the second adjacent pixels have been extracted (S409). For example, in FIG. 9A, since there is a second adjacent pixel B2 adjacent to the first adjacent pixel A1 (S409: NO), the process returns to step S407, and steps S407 to S409 are executed. On the other hand, if it is determined that all the second adjacent pixels have been extracted (S409: YES), the process proceeds to step S405.
ステップS405では、全ての第1隣接画素を抽出したか否かの判断を行い、全ての第1隣接画素を抽出していないと判断した場合(S405:NO)、ステップS400に戻り、全ての第1隣接画素を抽出するまで、ステップS400〜ステップS405、ステップS407〜ステップS409を繰り返す。一方、全ての第1隣接画素を抽出したと判断した場合(S405:YES)、図4のステップS37に戻る。隣接画素補正処理2を実行することにより、図9(b)に示すように、輪郭画素に隣接する背景画素のうち2画素分(第1隣接画素A1及び第2隣接画素B1、第1隣接画素A2及び第2隣接画素B2)だけ色調が白色に設定される。
In step S405, it is determined whether all the first adjacent pixels have been extracted. If it is determined that all the first adjacent pixels have not been extracted (S405: NO), the process returns to step S400, and all the first adjacent pixels have been extracted. Steps S400 to S405 and steps S407 to S409 are repeated until one adjacent pixel is extracted. On the other hand, when it is determined that all the first adjacent pixels have been extracted (S405: YES), the process returns to step S37 in FIG. By performing the adjacent
以上説明したように、第2実施形態の印刷装置では、サーマルヘッド9の温度に応じて、色調を白色に変換する幅分の画素数が算出される。サーマルヘッド9の温度が高い場合、文字と背景との境目において混色が発生し易い状況である。そこで第2実施形態は、サーマルヘッド9の温度が高い場合、色調を白色に変換する幅分の画素数を多くする。これにより、文字と背景との境目に生じる混色を防止できる。また、連続印刷によりサーマルヘッド9の温度は高くなる。そこで第2実施形態は、印字枚数が所定枚数以上となった場合、色調を白色にする幅分の画素数を多くする。これにより、文字と背景との境目に生じる混色を防止できる As described above, in the printing apparatus according to the second embodiment, the number of pixels corresponding to the width for converting the color tone to white is calculated according to the temperature of the thermal head 9. When the temperature of the thermal head 9 is high, color mixing tends to occur at the boundary between the character and the background. Therefore, in the second embodiment, when the temperature of the thermal head 9 is high, the number of pixels corresponding to the width for converting the color tone to white is increased. This prevents color mixing that occurs at the boundary between the character and the background. Moreover, the temperature of the thermal head 9 becomes high by continuous printing. Therefore, in the second embodiment, when the number of printed sheets exceeds a predetermined number, the number of pixels corresponding to the width that makes the color tone white is increased. This prevents color mixing that occurs at the boundary between the character and the background.
なお本発明は上記第1、第2実施形態に限定されず、種々の変更が可能である。例えば、図8のフローにおいて、温度を65度以上(S402:YES)、及び印字枚数が3枚以上(S403:YES)の少なくとも一つを満たす場合に、背景画素において抽出した第2隣接画素までも白色に設定するものとしている。これには限定されず、任意の温度、若しくは任意の印字枚数としても良い。また、色調を白色に設定する画素数を1画素又は2画素としたが、これには限定されず任意の画素数の色調を白色に設定するものとしても良い。 The present invention is not limited to the first and second embodiments, and various modifications can be made. For example, in the flow of FIG. 8, when the temperature satisfies 65 degrees or more (S402: YES) and the number of printed sheets satisfies 3 or more (S403: YES), up to the second adjacent pixel extracted in the background pixel Is also set to white. However, the present invention is not limited to this, and any temperature or any number of printed sheets may be used. Further, although the number of pixels for setting the color tone to white is 1 pixel or 2 pixels, the present invention is not limited to this, and the color tone of an arbitrary number of pixels may be set to white.
また上記実施形態では、図1に示す印字装置1を本発明の「印刷データ処理装置」として説明したが、印字装置に接続したPC(パーソナルコンピュータ)であってもよく、単体の装置としてもよい。
In the above embodiment, the
なお、上記説明において、図4のステップS33を実行するCPU21は「画像抽出手段」の一例である。図7のステップS377、ステップS379、ステップS383を実行するCPU21、及び図8のステップS401、ステップS408を実行するCPUは「色調変換手段」の一例である。また、図2に示すサーミスタ13は「温度検知手段」の一例であり、図8のステップS402:YES、S407を実行するCPUは「第一算出手段」の一例である。図2に示す印字枚数センサ32は「計数手段」の一例であり、図8のステップS403:YES、S407を実行するCPUは「第二算出手段」の一例である。
In the above description, the
1 印字装置
9 サーマルヘッド
13 サーミスタ
21 CPU
26 ROM
27 RAM
32 印字枚数センサ
1 Printing Device 9
26 ROM
27 RAM
32 Print number sensor
Claims (5)
前記画素抽出手段によって抽出された前記輪郭画素に沿って少なくとも1画素の幅で前記背景画素の色調を白色に変換する色調変換手段と
を備えたことを特徴とする印刷データ処理装置。 Image data for printing a character on a print medium using a thermal printer, the image data including character pixels constituting the character and background pixels constituting the background of the character, the background pixel and the boundary are defined. Pixel extracting means for extracting the character pixel at a position to be formed as a contour pixel;
A print data processing apparatus comprising: a color tone conversion unit that converts the color tone of the background pixel to white with a width of at least one pixel along the contour pixel extracted by the pixel extraction unit.
前記温度検知手段の検知結果に応じて、前記色調変換手段が前記背景画素の色調を白色に変換する幅分の画素数を算出する第一算出手段と
を備え、
前記色調変換手段は、前記第一算出手段が算出した画素数の幅で前記背景画素の色調を白色に変換することを特徴とする請求項1に記載の印刷データ処理装置。 Temperature detecting means for detecting the temperature of a thermal head provided in the thermal printer;
In accordance with the detection result of the temperature detection unit, the color tone conversion unit includes a first calculation unit that calculates the number of pixels corresponding to a width for converting the color tone of the background pixel to white,
2. The print data processing apparatus according to claim 1, wherein the color tone conversion unit converts the color tone of the background pixel into white with a width of the number of pixels calculated by the first calculation unit.
前記計数手段の計数結果に応じて、前記色調変換手段が前記背景画素の色調を白色に変換する幅分の画素数を算出する第二算出手段と
を備え、
前記色調変換手段は、前記第二算出手段が算出した画素数の幅で前記背景画素の色調を白色に変換することを特徴とする請求項1から3のいずれかに記載の印刷データ処理装置。 Counting means for counting the number of printed sheets printed by the thermal printer;
According to the counting result of the counting means, the color tone conversion means comprises second calculation means for calculating the number of pixels corresponding to the width for converting the color tone of the background pixels to white,
4. The print data processing apparatus according to claim 1, wherein the color tone converting unit converts the color tone of the background pixel into white with a width of the number of pixels calculated by the second calculating unit. 5.
前記画素抽出ステップにおいて、抽出された前記輪郭画素に沿って少なくとも1画素の幅で前記背景画素の色調を白色に変換する色調変換ステップと
をコンピュータに実行させることを特徴とする印刷データ処理プログラム。 Image data for printing a character on a print medium using a thermal printer, the image data including character pixels constituting the character and background pixels constituting the background of the character, the background pixel and the boundary are defined. A pixel extraction step of extracting the character pixel at a position to be formed as a contour pixel;
In the pixel extraction step, a print data processing program causing a computer to execute a color tone conversion step of converting the color tone of the background pixel to white with a width of at least one pixel along the extracted outline pixel.
Priority Applications (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2011079015A JP2012213861A (en) | 2011-03-31 | 2011-03-31 | Print data processor and print data processing program |
Applications Claiming Priority (1)
Application Number | Priority Date | Filing Date | Title |
---|---|---|---|
JP2011079015A JP2012213861A (en) | 2011-03-31 | 2011-03-31 | Print data processor and print data processing program |
Publications (1)
Publication Number | Publication Date |
---|---|
JP2012213861A true JP2012213861A (en) | 2012-11-08 |
Family
ID=47267173
Family Applications (1)
Application Number | Title | Priority Date | Filing Date |
---|---|---|---|
JP2011079015A Pending JP2012213861A (en) | 2011-03-31 | 2011-03-31 | Print data processor and print data processing program |
Country Status (1)
Country | Link |
---|---|
JP (1) | JP2012213861A (en) |
Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPS6199460A (en) * | 1984-10-22 | 1986-05-17 | Toray Ind Inc | Color signal control system of color printer |
JPH0372781A (en) * | 1989-05-10 | 1991-03-27 | Canon Inc | Picture processor |
JPH06127011A (en) * | 1992-10-15 | 1994-05-10 | Fuji Photo Film Co Ltd | Profile emphasizing device in thermal printer |
JP2000190548A (en) * | 1998-12-25 | 2000-07-11 | Toshiba Tec Corp | Thermal printer and printing method of thermal printer |
-
2011
- 2011-03-31 JP JP2011079015A patent/JP2012213861A/en active Pending
Patent Citations (4)
Publication number | Priority date | Publication date | Assignee | Title |
---|---|---|---|---|
JPS6199460A (en) * | 1984-10-22 | 1986-05-17 | Toray Ind Inc | Color signal control system of color printer |
JPH0372781A (en) * | 1989-05-10 | 1991-03-27 | Canon Inc | Picture processor |
JPH06127011A (en) * | 1992-10-15 | 1994-05-10 | Fuji Photo Film Co Ltd | Profile emphasizing device in thermal printer |
JP2000190548A (en) * | 1998-12-25 | 2000-07-11 | Toshiba Tec Corp | Thermal printer and printing method of thermal printer |
Similar Documents
Publication | Publication Date | Title |
---|---|---|
US7965398B2 (en) | Character rendering device, display device, and printing device | |
CN111857611A (en) | Print preview method, device, equipment and storage medium | |
JP2012190420A (en) | Image processing device, image processing system, and image processing method | |
US20090051977A1 (en) | Image processing to reduce image printing time | |
JP7183642B2 (en) | Data generation system, communication terminal, image forming apparatus and program | |
JP2023069952A (en) | Print data editing device, print data editing method and print data editing program | |
US11782660B2 (en) | Information processing apparatus, information processing method, and non-transitory computer-readable storage medium storing an information processing program | |
JP2012213861A (en) | Print data processor and print data processing program | |
JP2009223846A (en) | Imposition print control unit, imposition print system, imposition print method and program | |
JP6799972B2 (en) | Ink consumption estimation method | |
JP2011115999A (en) | Printer | |
JP2006309354A (en) | Digital pen input system | |
JP6242138B2 (en) | Printing apparatus, printing method, and program | |
JPH0443396A (en) | Character pattern generating device | |
JP2012192601A (en) | Printed layer formation processing device, and printed layer formation processing method | |
JPH01275152A (en) | Dot printer | |
JPH0752496A (en) | Printer | |
JP2014051064A (en) | Label printing device and its printing method | |
JP2637921B2 (en) | Character symbol generator | |
JPH0752495A (en) | Printer | |
TW200532566A (en) | System, method, and program for generating barcode data | |
JP6265042B2 (en) | Printing device | |
JP5494541B2 (en) | Image editing apparatus and image editing program | |
KR100988308B1 (en) | Print control method and apparatus of document | |
JP3479359B2 (en) | Tape printer |
Legal Events
Date | Code | Title | Description |
---|---|---|---|
A621 | Written request for application examination |
Free format text: JAPANESE INTERMEDIATE CODE: A621 Effective date: 20130225 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20131112 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20140109 |
|
A131 | Notification of reasons for refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A131 Effective date: 20140430 |
|
A521 | Written amendment |
Free format text: JAPANESE INTERMEDIATE CODE: A523 Effective date: 20140529 |
|
A02 | Decision of refusal |
Free format text: JAPANESE INTERMEDIATE CODE: A02 Effective date: 20140708 |