JP3085396B2 - Vector font development method and device - Google Patents

Vector font development method and device

Info

Publication number
JP3085396B2
JP3085396B2 JP02269444A JP26944490A JP3085396B2 JP 3085396 B2 JP3085396 B2 JP 3085396B2 JP 02269444 A JP02269444 A JP 02269444A JP 26944490 A JP26944490 A JP 26944490A JP 3085396 B2 JP3085396 B2 JP 3085396B2
Authority
JP
Japan
Prior art keywords
vector font
point
node
line
bitmap
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Expired - Lifetime
Application number
JP02269444A
Other languages
Japanese (ja)
Other versions
JPH04146484A (en
Inventor
龍夫 笠原
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Ricoh Co Ltd
Original Assignee
Ricoh Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Ricoh Co Ltd filed Critical Ricoh Co Ltd
Priority to JP02269444A priority Critical patent/JP3085396B2/en
Publication of JPH04146484A publication Critical patent/JPH04146484A/en
Application granted granted Critical
Publication of JP3085396B2 publication Critical patent/JP3085396B2/en
Anticipated expiration legal-status Critical
Expired - Lifetime legal-status Critical Current

Links

Landscapes

  • Image Generation (AREA)
  • Document Processing Apparatus (AREA)
  • Controls And Circuits For Display Device (AREA)
  • Dot-Matrix Printers And Others (AREA)

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

〔産業上の利用分野〕 本発明は、ワードプロセッサやDTP(デスク・トップ
・パブリッシング)などにおいて、ベクトルフォントを
任意の変倍率でビットマップに展開するための展開方法
および装置に関する。 〔従来の技術〕 ワードプロセッサやDTPの場合、文字の印字はラスタ
スキャン形式で行うのが普通である。したがって、文字
をベクトルフォントで持っている場合、印字に際してベ
クトルフォントをビットマップに展開する必要がある。
また、この展開に際しては、印字の要求に応じて任意の
変倍率で拡大・縮小して展開する必要もある。 〔発明が解決しようとする課題〕 ところで、ベクトルフォントは、n×nのマトリック
スを1文字単位とし、このマトリックス内において統一
された幅のストロークで所定の文字を形成している。こ
のようなベクトルフォントを任意の変倍率でビットマッ
プに展開した場合、変倍した位置座標はその少数点以下
を四捨五入されるため、展開後の文字はその線の位置に
よってストローク幅(線幅)がまちまちになってしま
う。 そこで、展開後の文字のストローク幅が文字全体で一
定になるように位置座標を補正しながら変倍する必要が
あるが、フォント中に曲線部がある場合、曲線部のベク
トルフォントデータは曲線の制御点(コントロールポイ
ント)を用いて記述されているため、局線部と直線部と
では補正の影響が異なり、変倍後の曲線部と直線部のス
トローク幅が異なったものとなってしまい、文字の品質
低下をきたすという問題があった。 本発明は、上記事情に基づきなされたもので、その目
的とするところは、ベクトルフォントを任意の変倍率で
ビットマップに展開した場合においても、直線部と曲線
部のストローク幅を同じにし、直線部と局線部を滑らか
につなぐようにしたベクトルフォントの展開方法および
装置を提供することである。 〔課題を解決するための手段〕 本発明は、前記目的を達成するため、第1の発明にお
いては、ベクトルフォントを任意の変倍率でビットマッ
プに展開する方法において、辞書中のベクトルフォント
をその直線部のストローク幅が一定となるように補正し
ながら変倍した後、ベクトルフォントの節点が曲線部と
曲線部の接続点である場合には、該節点に接続する曲線
部を近似する曲線の制御点を該節点に接続する直線部の
延長線上に乗るように位置補正するようにしたものであ
る。 また第2の発明においては、ベクトルフォントを任意
の変倍率でビットマップに展開する方法において、 辞書中のベクトルフォントをその直線部のストローク
幅が一定となるように補正しながら変倍する手段と、 ベクトルフォントの節点が曲線部と曲線部の接続点で
ある場合には、該節点に接続する曲線部を近似する曲線
の制御点を該節点に接続する直線部の延長線上に乗るよ
うに位置補正する手段と、 を備える。 〔作 用〕 まず、ベクトルフォント中の直線部(縦線と横線)に
注目し、直線部のストローク幅が線の位置にかかわらず
一定となるように、その位置座標を補正しながら変倍す
る。これにより、変倍後の文字は直線部のストローク幅
が文字全体で均一になるように変倍される。 次いで、ベクトルフォントデータからベクトルフォン
トの各節点が曲線部と直線部との接続点であるか否かを
調べ、節点が接続点である場合には、該節点に接続され
る曲線部を近似する曲線の制御点が該節点に接続する直
線部の延長線上に乗るように、その曲線の制御点の位置
座標を補正する。これにより、変倍後の曲線と直線の位
置関係が展開前のベクトルフォントにおける位置関係と
同じになる。この結果、変倍後の曲線部と直接部のスト
ローク幅が同じに維持され、曲線部と直線部が滑らかに
つながった高品質の拡大・縮小文字が得られる。 〔実施例〕 以下、図面を参照して本発明の実施例につき説明す
る。 まず、第2図にベクトルフォントの例を示す。図
(a)はベクトルフォント辞書に格納されたベクトルフ
ォントデータ、図(b)は図(a)のベクトルフォント
データによって表される文字フォントの字形を示す。な
お、図(b)中の左右端の半円曲線はベジェ(Bezier)
曲線により描かれているものとする。 図(a)のベクトルフォント辞書中のベクトルフォン
トデータは、各節点P1〜P8について、識別子iD,xy座標
値Pxi,Pyi、接続情報SMTを、図(a)中に矢印で示す順
に次々と並べて記述することにより格納されている。識
別子iDは、各節点がどのような点であるかを表すもの
で、その値によって次の意味を有する。 iD 1:line(直接) 4:pset(始点) 5:該当するインデクスの点の座標値を参照する 6:end (終点) 7:ベジェ曲線の制御点 また、接続情報SMT(:SMOOTHの略)は、その節点がベ
ジェ曲線と直線との接続点であるか否かを表すもので、
その値によって次の意味を有する。 SMT 1:接続点である 0:接続点でない 進んで、第1図により本発明展開方式の処理動作の一
例につき説明する。 第1図において、まず最初に、ベクトルフォントの輪
郭線中の
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a method and apparatus for developing a vector font into a bitmap at an arbitrary magnification in a word processor, desktop publishing (DTP), or the like. [Prior Art] In the case of a word processor or DTP, characters are usually printed in a raster scan format. Therefore, when a character has a vector font, it is necessary to develop the vector font into a bitmap when printing.
In this development, it is also necessary to expand and reduce the image at an arbitrary magnification ratio in accordance with a printing request. [Problems to be Solved by the Invention] By the way, the vector font forms an n × n matrix as one character unit, and forms a predetermined character with a stroke having a uniform width in the matrix. When such a vector font is expanded to a bitmap at an arbitrary scaling ratio, the scaled position coordinates are rounded off to the decimal point, and the expanded character is stroke width (line width) depending on the position of the line. Will be mixed. Therefore, it is necessary to change the magnification while correcting the position coordinates so that the stroke width of the expanded character is constant throughout the character.If there is a curved part in the font, the vector font data of the curved part Since the description is made using control points (control points), the effect of correction is different between the local line portion and the straight line portion, and the stroke width of the curved portion and the straight line portion after scaling is different. There is a problem that the quality of characters is deteriorated. The present invention has been made based on the above circumstances, and an object thereof is to make the stroke width of a straight line portion and a curved portion the same even when a vector font is developed into a bitmap at an arbitrary scaling ratio, and It is an object of the present invention to provide a method and apparatus for developing a vector font in which a section and a local line section are smoothly connected. [Means for Solving the Problems] In order to achieve the above object, the present invention provides, in the first invention, a method of expanding a vector font into a bitmap at an arbitrary scaling factor, the method comprising: After scaling while correcting the stroke width of the linear portion to be constant, if the node of the vector font is a connection point between the curved portions, the curve approximating the curved portion connected to the node is obtained. The position is corrected so that the control point is on an extension of a straight line portion connected to the node. According to a second aspect of the present invention, there is provided a method of developing a vector font into a bitmap at an arbitrary scaling factor, wherein the vector font in the dictionary is scaled while correcting the stroke width of the linear portion to be constant. If the node of the vector font is a connection point between the curved portions, the control point of the curve approximating the curved portion connected to the node is positioned on the extension of the straight line connected to the node. Correction means. [Operation] First, pay attention to the linear part (vertical and horizontal lines) in the vector font, and adjust the position coordinates so that the stroke width of the linear part is constant regardless of the position of the line. . Thus, the scaled character is scaled so that the stroke width of the linear portion is uniform throughout the character. Next, it is checked from the vector font data whether or not each node of the vector font is a connection point between the curved portion and the straight line portion. If the node is a connection point, the curve portion connected to the node is approximated. The position coordinates of the control point of the curve are corrected so that the control point of the curve is on the extension of the straight line connected to the node. As a result, the positional relationship between the curved line and the straight line after scaling becomes the same as the positional relationship in the vector font before expansion. As a result, the stroke width of the curved portion and the direct portion after scaling are maintained the same, and a high-quality enlarged / reduced character in which the curved portion and the straight portion are smoothly connected is obtained. Hereinafter, embodiments of the present invention will be described with reference to the drawings. First, FIG. 2 shows an example of a vector font. FIG. 1A shows vector font data stored in a vector font dictionary, and FIG. 1B shows the character shape of a character font represented by the vector font data in FIG. The semicircular curve at the left and right ends in FIG.
It shall be drawn by a curve. Vector font data in the vector font dictionary of FIG (a), for each node P 1 to P 8, one after another identifier iD, xy coordinate values Pxi, Pyi, the connection information SMT, in the order indicated by arrows in FIG. (A) Are stored side by side. The identifier iD indicates what each node is, and has the following meaning depending on its value. iD 1: line (direct) 4: pset (start point) 5: Refer to the coordinate value of the corresponding index point 6: end (end point) 7: Control point of Bezier curve Also, connection information SMT (short for: SMOOTH) Represents whether the node is a connection point between the Bezier curve and the straight line,
The value has the following meaning. SMT 1: Connection point 0: Not connection point Next, an example of the processing operation of the present invention will be described with reference to FIG. In FIG. 1, first, the outline of the outline of the vector font

【水平な直線】を抽出し、これを横線YLiとす
る。 YL0:P0−P7 YL1:P3−P4 次いで、この抽出した横線YLi中から、
Extracting [horizontal line], which is the horizontal line YL i. YL 0 : P 0 −P 7 YL 1 : P 3 −P 4 Then, from the extracted horizontal line YLi,

【y座標距離
が一番近く、かつ、x座標が少なくとも一部重複してい
るYLとYL(i≠j)】を選択し、これを横黒線
対YBiとする。第1図の場合、 YB0(YL1,YL0) となる。 なお、前記YB0の( )内は、y座標の小のものが右
側とし、この右側に位置する横線YL0を横黒線対YB0にお
ける基準線(第1図中の黒太線)と呼び、左側に位置す
る横線YL1を横黒線対YB0における補正線と呼ぶものとす
る。 なお、第1図では説明を簡単とするために水平な直線
(横線)しか存在しないフォントを例示したが、フォン
ト中に垂直な直線(縦線)が存在するときには、縦線に
ついても、前記と同様にして縦黒線対TBを抽出する。 上記のようにして、第1図のベクトルフォント中から
横黒線対YB0を抽出したら、この抽出結果に基づいて、
補正線YL1上の点P3,P4に対応する基準線上の点を
[YL i and YL j (i ≠ j)] whose y-coordinate distance is the shortest and x-coordinates at least partially overlap each other are selected as horizontal black line pairs YB i . In the case of FIG. 1 , it becomes YB 0 (YL 1 , YL 0 ). In the parentheses of the YB 0 , the smaller one of the y-coordinates is on the right side, and the horizontal line YL 0 located on the right side is referred to as the reference line (black thick line in FIG. 1) in the horizontal black line YB 0 . , it is referred to as a correction line in Okokusen pair YB 0 horizontal lines YL 1 located on the left side. Although FIG. 1 illustrates a font having only a horizontal straight line (horizontal line) for simplicity of explanation, when a vertical straight line (vertical line) exists in the font, the vertical line is also referred to as described above. Similarly, a vertical black line pair TB is extracted. As described above, after extracting the Okokusen pair YB 0 from in vector font of FIG. 1, on the basis of the extraction result,
The point of reference line corresponding to the correction line YL points on 1 P 3, P 4

【対と
なる座標】として、また、各制御点(第1図中の×印の
点)に対応する接続点の座標値を
The coordinate value of the connection point corresponding to each control point (the point marked with “x” in FIG. 1)

【SMT対象の座標イ
ンデクス】としてそれぞれ書き加えることにより、第2
図(a)のベクトルフォントデータを第3図に示す記述
形式のベクトルフォントデータに書き換える。 前記
By adding each as [coordinate index for SMT object], the second
The vector font data in FIG. 3A is rewritten to the vector font data in the description format shown in FIG. Said

【対となる座標】Mxi,Myiは、具体的には次のよ
うにして求める。すなわち、いま注目している点をPi
すると、この点PiのMxiは、その点Piが縦黒線対を構成
する一対の縦線のうちの補正線上の点である場合に、そ
の対となる基準線上の点のx座標値をMxiとして選ぶ。
点Piが縦黒線対の補正線上の点でない場合、Mxiは0と
置く。また、注目している点PiのMyiは、その点Piが横
黒線対YBを構成する一対の横線のうちの補正線上の点で
ある場合に、その対となる基準線上の点のy座標値をM
yiとして選ぶ。点Piが横黒線対の補正線上の点でない場
合、Myiは0と置く。 例えば、点P3についてのMxi,Myiの求め方を例示する
と、第1図のフォントでは縦黒線対は存在しない。した
がって、点P3についてのMxiは0である。一方、点P3
横黒線対YB0の補正線YL1上の点である。したがって、点
P3についてのMyiは、この補助線YL1と対となる基準線YL
0上の点P0のy座標値Py0(=P7のy座標値Py7)とな
る。したがって、P3
[Coordinates to be paired] M xi and My y are specifically determined as follows. That is, a point of interest now When P i, M xi this point P i, if the point P i is a point of the correction line of the pair of vertical lines constituting the vertical black line pair chooses x-coordinate value of a point of reference line serving as the pair as M xi.
If the point P i is not the point of the vertical black line pair of the correction line, we put M xi is zero. Further, M yi of the point P i of interest, if the point P i is a point of the correction line of a pair of horizontal lines constituting the Okokusen pair YB, points of the reference line to be the pair The y coordinate value of
Choose as yi . If the point P i is not the point of the correction line pair Okokusen put M yi is zero. For example, to illustrate the M xi, Determination of M yi for the point P 3, the vertical black line pair does not exist in the font of FIG. 1. Therefore, the M xi about the point P 3 is zero. On the other hand, the point P 3 is a point on the correction line YL 1 of Okokusen pair YB 0. Therefore, the point
M yi for P 3, the reference line YL serving as the auxiliary line YL 1 pair
The y coordinate value P y0 of point P 0 on 0 (= y coordinate value P y7 of P 7 ) is obtained. Therefore, P 3

【対となる座標】Mxi,Myiは、第
3図に示すように(0,Py0)となる。点P4についても、
同様にして(0,Py0)となる。 また、各制御点P1,P2,P5,P6についての
[Coordinates to be paired] M xi and My y are (0, P y0 ) as shown in FIG. For even point P 4,
Similarly, it becomes (0, P y0 ). In addition, each control point P 1 , P 2 , P 5 , P 6

〔発明の効果〕〔The invention's effect〕

以上述べたところから明らかなように、本発明による
ときは、ベクトルフォントを任意の変倍率でビットマッ
プに展開した場合でも、直線部と曲線部のストローク幅
を同一にして滑らかにつなぐことができ、変倍時の文字
品質の低下を防止することができる。
As is apparent from the above description, according to the present invention, even when a vector font is developed into a bitmap at an arbitrary scaling ratio, the stroke width of the straight line portion and the curved line portion can be made the same and smoothly connected. In addition, it is possible to prevent a decrease in character quality at the time of zooming.

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

第1図は本発明方式の1実施例の説明図、 第2図は辞書中に格納されたベクトルフォントの例を示
す図、 第3図は本発明方式により書き換えられたベクトルフォ
ントデータの例を示す図である。
FIG. 1 is an explanatory diagram of one embodiment of the method of the present invention, FIG. 2 is a diagram showing an example of a vector font stored in a dictionary, and FIG. 3 is an example of vector font data rewritten by the method of the present invention. FIG.

Claims (2)

(57)【特許請求の範囲】(57) [Claims] 【請求項1】ベクトルフォントを任意の変倍率でビット
マップに展開する方法において、 辞書中のベクトルフォントをその直線部のストローク幅
が一定となるように補正しながら変倍した後、 ベクトルフォントの節点が曲線部と曲線部の接続点であ
る場合には、該節点に接続する曲線部を近似する曲線の
制御点を該節点に接続する直線部の延長線上に乗るよう
に位置補正すること を特徴とするベクトルフォントの展開方法。
In a method for developing a vector font into a bitmap at an arbitrary scaling factor, the vector font in the dictionary is scaled while correcting so that the stroke width of its linear portion is constant, and then the vector font is converted to a bitmap. When the node is a connection point between the curved portions, the position is corrected so that the control point of the curve approximating the curved portion connected to the node is on an extension of the straight line connected to the node. Characteristic vector font development method.
【請求項2】ベクトルフォントを任意の変倍率でビット
マップに展開する装置において、 辞書中のベクトルフォントをその直線部のストローク幅
が一定となるように補正しながら変倍する手段と、 ベクトルフォントの節点が曲線部と曲線部の接続点であ
る場合には、該節点に接続する曲線部を近似する曲線の
制御点を該節点に接続する直線部の延長線上に乗るよう
に位置補正する手段と、 を備えたことを特徴とするベクトルフォントの展開装
置。
2. An apparatus for developing a vector font into a bitmap at an arbitrary scaling factor, means for scaling the vector font in the dictionary while correcting the stroke width of its linear portion to be constant, and a vector font. Means for correcting the position so that the control point of the curve approximating the curve connected to the node is on the extension of the straight line connected to the node, when the node is a connection point between the curves. A vector font development device, comprising:
JP02269444A 1990-10-09 1990-10-09 Vector font development method and device Expired - Lifetime JP3085396B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP02269444A JP3085396B2 (en) 1990-10-09 1990-10-09 Vector font development method and device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP02269444A JP3085396B2 (en) 1990-10-09 1990-10-09 Vector font development method and device

Related Child Applications (1)

Application Number Title Priority Date Filing Date
JP2000002324A Division JP3260733B2 (en) 2000-01-01 2000-01-11 Vector font dictionary

Publications (2)

Publication Number Publication Date
JPH04146484A JPH04146484A (en) 1992-05-20
JP3085396B2 true JP3085396B2 (en) 2000-09-04

Family

ID=17472522

Family Applications (1)

Application Number Title Priority Date Filing Date
JP02269444A Expired - Lifetime JP3085396B2 (en) 1990-10-09 1990-10-09 Vector font development method and device

Country Status (1)

Country Link
JP (1) JP3085396B2 (en)

Also Published As

Publication number Publication date
JPH04146484A (en) 1992-05-20

Similar Documents

Publication Publication Date Title
JP2634851B2 (en) Image processing device
JP3085396B2 (en) Vector font development method and device
JP3260733B2 (en) Vector font dictionary
US20060119897A1 (en) Output apparatus and program thereof
JP3055187B2 (en) Contour data processing device
JP3029135B2 (en) Character processing apparatus and method
JP3146771B2 (en) Font rasterizing apparatus and method
JP3243293B2 (en) Contour correction method
JP3057959B2 (en) Data converter
JP3024479B2 (en) Data converter
JP3055306B2 (en) Data output device
JPH10198333A (en) Outline character drawing device
JP3359166B2 (en) Printer device and line segment division drawing method of printer device
JP2985260B2 (en) Character processor
JPH0511736A (en) Character pattern output device
JPH0580741A (en) System and device for character font generation
JPH04104296A (en) Character/graphic plotter
JP2792102B2 (en) Character font drawing method
JP2611476B2 (en) Image data enlargement processing method
JPH06110444A (en) Character processor and character output method
Zahir et al. A near exact image expansion scheme for bi-level images
JPH03290691A (en) Reduction method for vector font
JPH0493994A (en) Character processor
JP2000235651A (en) Compiling method/device for raster data
JPH05313634A (en) Outline font developing device

Legal Events

Date Code Title Description
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20070707

Year of fee payment: 7

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

Free format text: PAYMENT UNTIL: 20080707

Year of fee payment: 8

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

Free format text: PAYMENT UNTIL: 20090707

Year of fee payment: 9

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

Free format text: PAYMENT UNTIL: 20090707

Year of fee payment: 9

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

Free format text: PAYMENT UNTIL: 20100707

Year of fee payment: 10

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

Free format text: PAYMENT UNTIL: 20110707

Year of fee payment: 11

EXPY Cancellation because of completion of term
FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20110707

Year of fee payment: 11