JPH1115985A - Plotting device - Google Patents

Plotting device

Info

Publication number
JPH1115985A
JPH1115985A JP16361797A JP16361797A JPH1115985A JP H1115985 A JPH1115985 A JP H1115985A JP 16361797 A JP16361797 A JP 16361797A JP 16361797 A JP16361797 A JP 16361797A JP H1115985 A JPH1115985 A JP H1115985A
Authority
JP
Japan
Prior art keywords
rectangular
point
graphic
points
forming
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
Application number
JP16361797A
Other languages
Japanese (ja)
Inventor
Hiroshi Kawamoto
浩史 川本
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Fujifilm Business Innovation Corp
Original Assignee
Fuji Xerox Co Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Fuji Xerox Co Ltd filed Critical Fuji Xerox Co Ltd
Priority to JP16361797A priority Critical patent/JPH1115985A/en
Publication of JPH1115985A publication Critical patent/JPH1115985A/en
Pending legal-status Critical Current

Links

Landscapes

  • Image Generation (AREA)

Abstract

PROBLEM TO BE SOLVED: To plot a high definition line graphic by forming a graphic which includes a point that moves an outer connection point of rectangular graphics toward a rectangular graphic only by small distance and a point which moves a connection point of linear segments in the expanding direction of an angle that includes a segment in-between by small distance as vertexes. SOLUTION: A coordinate point group of a rectangular graphic that is calculated by a rectangular forming part is a point (d), a point (e), a point (f) and a point (g) about a rectangular graphic 11, and is points (h), (i), (j) and (k) about a rectangular graphic 12. Also, about a connection graphic 13 that is calculated by a joint graphic forming part, it is points (d'), (m), (h') and (b'). In such cases, a graphic is formed which includes a point that moves an outer connection point of rectangular graphics toward a rectangular graphic only by small distance and a point which moves a connection point of linear segments in the expanding direction of an angle that includes a segment in-between by small distance as vertexes. Because the sought connection graphic 13 has overlapping parts to the graphics 11 and 12, there is no gap at connecting side parts between itself and the graphics 11 and 12.

Description

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

【0001】[0001]

【発明の属する技術分野】本発明は、線分データを受け
取って所定の幅をもつ線図形を描画する描画装置に関
し、特に、屈曲部を有する線図形を良好に描画可能な描
画装置に関するものである。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a drawing apparatus which receives line segment data and draws a line figure having a predetermined width, and more particularly to a drawing apparatus which can draw a line figure having a bent portion. is there.

【0002】[0002]

【従来の技術】一定の幅をもつ連結された線分群(すな
わち折れ線)を描画する技術が特開平6−168339
号公報に開示されている。この文献では、短線分を矩形
で描き、短線分の連結する折れ点にくさび状もしくは扇
状の図形を接続図形として与えて連続な折れ線を描画し
ている。この技術は、直線群だけでなく、微小直線によ
って曲線を描画する際にも利用される。
2. Description of the Related Art Japanese Patent Laid-Open No. 6-168339 discloses a technique for drawing a connected group of line segments having a fixed width (that is, a polygonal line).
No. 6,086,045. In this document, a continuous line is drawn by drawing a short line in a rectangle and giving a wedge-shaped or fan-shaped figure as a connection figure to a break point connecting the short lines. This technique is used not only for drawing a straight line group but also for drawing a curve by a minute straight line.

【0003】上記の技術により折れ線を描画した場合、
まれに、屈曲部に線の割れを生ずる場合がある。図5
は、従来の描画装置における問題点の一例の説明図であ
る。図中、11,12は矩形、13は接続図形である。
図5において、矩形11は線分a−bを幅Wで描画した
ものであり、矩形12は線分c−bを幅Wで描画したも
のである。線分a−bと線分c−bは点bにおいて結合
されており、点bを結合点と呼ぶ。線分a−bを幅Wだ
け幅付けして形成される矩形11は、点bを線分a−b
の法線方向に互いに反対向きにそれぞれW/2だけ移動
させた点d,d’を頂点にもつ。同様に、線分c−bを
幅Wだけ幅付けして形成される矩形12は、点bを線分
c−bの法線方向に互いに反対向きにそれぞれW/2だ
け移動させた点e,e’を頂点にもつ。なお、点d,e
を外側結合点と呼び、点d’,e’を内側結合点と呼ぶ
ことにする。
When a polygonal line is drawn by the above technique,
In rare cases, the wire may be broken at the bent portion. FIG.
FIG. 4 is an explanatory diagram of an example of a problem in a conventional drawing apparatus. In the figure, 11 and 12 are rectangles, and 13 is a connection figure.
In FIG. 5, a rectangle 11 is a line segment ab drawn with a width W, and a rectangle 12 is a line segment cb drawn with a width W. The line segment ab and the line segment cb are connected at a point b, and the point b is called a connection point. A rectangle 11 formed by width of the line segment ab by the width W is represented by
Have points d and d ′, which are moved by W / 2 in opposite directions to each other in the direction of the normal line. Similarly, a rectangle 12 formed by dividing the line segment c-b by the width W has a point e obtained by moving the point b by W / 2 in directions opposite to each other in the normal direction of the line segment c-b. , E ′ at the vertices. Note that points d and e
Are called outer connection points, and points d 'and e' are called inner connection points.

【0004】矩形11および矩形12を描画しただけで
は、結合点bよりも外側結合点d,e側で連続しないた
め、上述の文献などに記載されている技術によって接続
図形13を描画している。このようにして図5で描画さ
れる図形は、矩形11、矩形12、および屈曲部におけ
る接続図形13である。
[0004] If the rectangles 11 and 12 are merely drawn, they are not continuous at the connection points d and e outside the connection point b. Therefore, the connection graphic 13 is drawn by the technique described in the above-mentioned literature. . The figures drawn in FIG. 5 in this manner are rectangles 11, rectangles 12, and connection figures 13 at the bent portions.

【0005】ここで問題となるのは、座標計算における
数値演算誤差により、線分d−d’もしくは線分e−
e’(あるいはその両方)が、必ずしもその計算起点で
あった点bを通るとは保証されないことにある。そのた
めに、接続図形13の頂点のひとつである点b’(これ
は元々の線分の結合点bである)と、矩形11及び矩形
12の交点bとが一致しないケースが発生する。さらに
そのとき、点b’が矩形11もしくは矩形12の外側に
位置している場合には、矩形11もしくは矩形12と接
続図形13との間に、本来意図しない空隙が生じてしま
う。
The problem here is that the line segment dd 'or the line segment e-
e '(or both) is not necessarily guaranteed to pass through point b, which was the calculation starting point. Therefore, a point b ′, which is one of the vertices of the connection graphic 13 (this is the original connection point b of the line segment), does not coincide with the intersection b of the rectangles 11 and 12. Further, at that time, if the point b 'is located outside the rectangle 11 or the rectangle 12, an unintended gap is generated between the rectangle 11 or the rectangle 12 and the connection graphic 13.

【0006】さらにまた、これらの座標点計算が充分な
精度をもっていて、点bと点b’とが実質的に同一の座
標値と算定された場合であっても、これらの座標データ
を利用する図形塗りつぶし装置の仕様によっては、接す
る辺と辺(同一辺)の間に1ドットの空隙があいてしま
う可能性があった。
Furthermore, even if these coordinate point calculations have sufficient accuracy and the point b and the point b 'are calculated to have substantially the same coordinate value, these coordinate data are used. Depending on the specifications of the figure filling device, there is a possibility that a gap of 1 dot may be left between the contacting sides and the sides (the same side).

【0007】図6は、従来の描画装置における問題点の
回避案の一例の説明図である。上述のような問題に対す
る簡便な対策として、各線分を微小量εだけ長く描画す
るという作画方式が考えられる。このような作画方式で
描画した図形の一例を図6に示している。図6におい
て、ハッチングを施して示した部分が、各線分を微小量
εだけ延長して描画した部分である。
FIG. 6 is an explanatory diagram of an example of a solution to the problem in the conventional drawing apparatus. As a simple countermeasure against the above-described problem, there is a drawing method in which each line segment is drawn long by a minute amount ε. FIG. 6 shows an example of a figure drawn by such a drawing method. In FIG. 6, hatched portions are portions drawn by extending each line segment by a small amount ε.

【0008】このような作画方法を用いることによっ
て、確かに接続図形13を描画していた部分は埋められ
る。しかし、ここで延長して描画された部分は、線分の
なす角度が水平(180度)に近づくにつれて、埋める
べき領域を超えて飛び出してしまう。例えば図6の点d
および点e付近は外側に飛び出しており、不要な突起状
の図形を生じてしまうという問題がある。
By using such a drawing method, the part where the connection graphic 13 was drawn is certainly filled. However, the portion drawn here by extension extends beyond the area to be filled as the angle between the line segments approaches horizontal (180 degrees). For example, point d in FIG.
In addition, the vicinity of the point e protrudes outward, and there is a problem that an unnecessary projection-like figure is generated.

【0009】一方、直線と曲線あるいは曲線と曲線の連
結部における線分の空隙を埋める別の技術として、例え
ば特開平8−263671号公報や特開平8−2636
72号公報において開示されているように、直線と曲線
の連結部の接線方向を揃えることによって、曲線−直線
間の空隙、すなわち本来接続図形を描画すべき空隙を排
除する技術もある。しかしこの技術は、線分と他の線分
との間を補間するための接続図形周辺に生じる空隙を解
消していない。例えば上述の文献でも曲線を構成する微
小直線間の割れは補間部で埋めているが、その埋めた接
続図形周辺に空隙が生じることは示唆されていないし、
解決もされていない。
On the other hand, as another technique for filling the gap of a line segment at a connecting portion between a straight line and a curved line or a curved line and a curved line, for example, JP-A-8-263671 and JP-A-8-2636.
As disclosed in Japanese Patent Publication No. 72-72, there is also a technique for eliminating a gap between a curve and a straight line, that is, a gap in which a connected figure is to be drawn, by aligning the tangent directions of a connecting portion between the straight line and the curve. However, this technique does not eliminate a gap generated around a connection graphic for interpolating between a line segment and another line segment. For example, even in the above-mentioned literature, cracks between minute straight lines constituting a curve are filled in by an interpolation unit, but it is not suggested that a void is generated around the filled connection graphic,
There is no solution.

【0010】[0010]

【発明が解決しようとする課題】本発明は、上述した事
情に鑑みてなされたもので、線幅をもつ連結線分群をそ
の接続点において空隙を生ずることなく高品位に描画す
ることができる描画装置を提供することを目的とするも
のである。
SUMMARY OF THE INVENTION The present invention has been made in view of the above-described circumstances, and is capable of drawing a connecting line group having a line width with high quality without generating a gap at a connection point. It is intended to provide a device.

【0011】[0011]

【課題を解決するための手段】請求項1に記載の発明
は、接続図形として、矩形図形の外側結合点を矩形図形
の側に微小距離だけ移動した点、および、直線線分の接
続点を線分はさみ角の広がる方向に微小距離だけ移動し
た点を頂点として含む図形を形成する。形成される接続
図形は、矩形図形と微小距離だけ重なるように描画領域
が計算されるので、たとえ誤差が発生しても、空隙を生
じることはない。また、塗りつぶしの際の空隙も埋めら
れる。
According to a first aspect of the present invention, as the connection graphic, a point obtained by moving the outer joint point of the rectangular graphic by a small distance to the rectangular graphic side and a connection point of a straight line segment. A figure is formed which includes, as vertices, a point moved by a small distance in the direction in which the line segment scissor angle spreads. Since the drawing area is calculated so that the formed connection graphic overlaps the rectangular figure by a very small distance, even if an error occurs, no gap is generated. In addition, the gap at the time of filling is filled.

【0012】請求項2に記載の発明は、矩形図形を形成
する際に、直線線分の屈曲部の内側の辺が微小距離だけ
長くなるように形成する。また、接続図形を形成する際
には、矩形図形の外側結合点を前記矩形図形の側に微小
距離だけ移動した点を頂点に含む図形として形成する。
このように矩形図形と接続図形の両者の描画領域を微小
領域ずつ増加させて重ねることにより、たとえ計算誤差
が発生しても重複して描画される領域によって埋めら
れ、空隙を生じることはない。また、矩形図形の内側の
辺のみを長くすることにより、図6に示すような突起が
生じることはない。さらに、塗りつぶしの際の空隙も埋
められる。
According to a second aspect of the present invention, when a rectangular figure is formed, the side inside the bent portion of the straight line segment is formed to be elongated by a minute distance. In addition, when forming the connection graphic, the outer joint point of the rectangular graphic is formed as a graphic including at its vertices a point moved a small distance toward the rectangular graphic.
In this way, by increasing the drawing area of both the rectangular figure and the connection figure by a small area and overlapping them, even if a calculation error occurs, it is filled with the overlapped drawing area and no gap is generated. Further, by extending only the inner side of the rectangular figure, the projection as shown in FIG. 6 does not occur. In addition, voids during filling are filled.

【0013】請求項3に記載の発明は、矩形図形を形成
する際に、直線線分の2両端点および該2点それぞれを
直線の法線方向に線幅の1/2だけ移動した4点の計6
点により構成される前記矩形図形(厳密には6角形)を
形成する。図5に示したように、矩形図形と接続図形の
間の空隙は直線線分の結合点における計算誤差であった
ので、接続図形の頂点の一つである結合点を矩形図形を
形成する際の頂点として含ませれば、計算誤差による影
響は完全に排除できる。これによって、計算誤差による
空隙は発生しない。
According to a third aspect of the present invention, in forming a rectangular figure, two end points of a straight line segment and four points obtained by moving each of the two points by half the line width in the normal direction of the straight line. A total of 6
The rectangular figure (strictly, a hexagon) constituted by points is formed. As shown in FIG. 5, since the gap between the rectangular figure and the connection figure was a calculation error at the connection point of the straight line segment, the connection point which is one of the vertices of the connection figure is used to form the rectangular figure. If they are included as vertices, the effects of calculation errors can be completely eliminated. As a result, no gap is generated due to a calculation error.

【0014】[0014]

【発明の実施の形態】図1は、本発明の描画装置の実施
の一形態を示す基本構成図である。図中、1は矩形形成
部、2はジョイント図形形成部である。線幅をつけるべ
き少なくとも2線分の座標点(すなわち2線分であれば
3点)の値および線幅Wの値が、矩形形成部1に渡され
る。矩形形成部1は、各線分を構成する基本図形である
矩形図形の4つの頂点の座標を、それぞれの線分につい
て1組ずつ計算する。ジョイント図形形成部2は、2つ
の矩形図形をなめらかに接続するための接続図形の頂点
群を算出する。このようにして算出された矩形図形およ
び接続図形の座標点群は、例えばそのまま蓄積された
り、図示しない塗りつぶし処理部等を経て出力装置にお
いて作画される。
FIG. 1 is a basic configuration diagram showing one embodiment of a drawing apparatus according to the present invention. In the figure, reference numeral 1 denotes a rectangle forming unit, and 2 denotes a joint figure forming unit. The values of the coordinate points of at least two lines to be given a line width (that is, three points for two lines) and the value of the line width W are passed to the rectangle forming unit 1. The rectangle forming unit 1 calculates the coordinates of the four vertices of the rectangular figure which is the basic figure constituting each line segment, one set for each line segment. The joint figure forming unit 2 calculates a vertex group of a connected figure for smoothly connecting the two rectangular figures. The coordinate point group of the rectangular graphic and the connected graphic calculated in this way is stored as it is, for example, or drawn on the output device via a paint processing unit (not shown).

【0015】矩形形成部1またはジョイント図形形成部
2、あるいは、矩形形成部1およびジョイント図形形成
部2が協働して、矩形図形と接続図形の間に空隙が発生
しないように、矩形図形の座標群または接続図形の座標
群、あるいは、矩形図形および接続図形の座標群を算出
する。以下、これらの具体的計算方法についていくつか
説明する。
The rectangular figure 1 or the joint figure forming unit 2 or the rectangular figure 1 and the joint figure forming unit 2 cooperate with each other so that no void is generated between the rectangular figure and the connected figure. The coordinate group of the coordinate group or the connected figure, or the coordinate group of the rectangular figure and the connected figure is calculated. Hereinafter, some of these specific calculation methods will be described.

【0016】図2は、本発明の描画装置の実施の一形態
における第1の動作例の説明図である。図2は、線分a
−bと線分b−cを点bにおいて接続して幅Wで描画す
る場合を示している。矩形形成部1で求められる矩形図
形の座標点群は、矩形図形11については点d,点e,
点f,点gであり、矩形図形12については点h,点
i,点j,点kである。また、ジョイント図形形成部2
で求められる接続図形13については点d’,点m,点
h’,点b’である。それぞれの構成法を以下に順を追
って説明する。
FIG. 2 is an explanatory diagram of a first operation example in the embodiment of the drawing apparatus of the present invention. FIG. 2 shows a line segment a
The drawing illustrates a case in which −b and a line segment bc are connected at a point b and drawn with a width W. The coordinate points of the rectangular figure obtained by the rectangular forming unit 1 are points d, e,
Points f and g, and points h, i, j and k for the rectangular figure 12. Also, the joint figure forming unit 2
Are the points d ′, m, h ′, and b ′. Each configuration method will be described below in order.

【0017】まず、矩形形成部1において矩形図形11
および矩形図形12の座標点群を構成する方法について
説明する。線分a−bの方向をもつ単位ベクトルEab
を求める。線分a−bのベクトルをVabとすると、単
位ベクトルEabは、 Eab=Vab/|Vab| である。ここで、|V|はベクトルVの長さを表わして
いる。以下同じである。
First, in the rectangle forming section 1, a rectangular figure 11
A method of configuring a coordinate point group of the rectangular graphic 12 will be described. A unit vector Eab having the direction of the line segment ab
Ask for. Assuming that the vector of the line segment ab is Vab, the unit vector Eab is Eab = Vab / | Vab |. Here, | V | represents the length of the vector V. The same applies hereinafter.

【0018】単位ベクトルEabから、単位ベクトルE
abの法線単位ベクトルEOabおよびEOab’を求
める。法線単位ベクトルEOabは、単位ベクトルEa
bを反時計回りにπ/2回転させたものであり、法線単
位ベクトルEOab’は、単位ベクトルEabを時計回
りにπ/2回転させた単位ベクトルである。すなわち 、Eab=(x,y)とすると、 EOab =(−y,x), EOab’=(y,−x) である。
From the unit vector Eab, the unit vector Eab
The normal unit vectors EOab and EOab ′ of ab are obtained. The normal unit vector EOab is the unit vector Ea
b is rotated by π / 2 counterclockwise, and the normal unit vector EOab ′ is a unit vector obtained by rotating the unit vector Eab by π / 2 clockwise. That is, when Eab = (x, y), EOab = (− y, x) and EOab ′ = (y, −x).

【0019】得られた法線単位ベクトルEOabおよび
EOab’から、法線単位ベクトルEOabおよびEO
ab’をW/2倍した変位ベクトルEOWab,EOW
ab’を求める。すなわち、変位ベクトルEOWab,
EOWab’は、 EOWab =(W/2)・EOab EOWab’=(W/2)・EOab’ である。点bの位置ベクトルをOVbとすると、 OVd=OVb+EOWab OVe=OVb+EOWab’ で算出されるベクトルOVd,OVeであらわされる点
が、図2の点dおよび点eである。
From the obtained normal unit vectors EOab and EOab ′, normal unit vectors EOab and EOab
displacement vector EOWab, EOW obtained by multiplying ab 'by W / 2
Find ab '. That is, the displacement vector EOWab,
EOWab 'is: EOWab = (W / 2) .EOab EOWab' = (W / 2) .EOab '. Assuming that the position vector of the point b is OVb, the points represented by the vectors OVd and OVe calculated by OVd = OVb + EOWab OVe = OVb + EOWab 'are points d and e in FIG.

【0020】同様に、点aに変位ベクトルEOWab,
EOWab’を作用させて移動したものが点gおよび点
fである。以上の4点、すなわち点d,点e,点f,点
gから矩形図形11が構成される。矩形図形12につい
ても、線分b−cから、上述の方法とまったく同様にし
て4点、すなわち点h,点i,点j,点kを得ることが
できる。
Similarly, a displacement vector EOWab,
Points moved by the action of EOWab 'are points g and f. The above four points, that is, the point d, the point e, the point f, and the point g form the rectangular figure 11. Regarding the rectangular figure 12, four points, that is, points h, i, j, and k can be obtained from the line segment bc in exactly the same manner as described above.

【0021】次に、ジョイント図形形成部2において接
続図形13の座標点群を構成する方法について述べる。
まず、点dをベクトルVabの逆方向に微小量εだけ移
動した点d’を求める。すなわち、 OVd’=OVd−ε・Eab として求める。ここで、OVdおよびOVd’は座標原
点から点dおよび点d’それぞれへの位置ベクトルであ
り、εはあらかじめ定められた定数である。同様に、点
hをベクトルVbc方向に微小量εだけ移動した点h’
を求める。ベクトルVbcは線分b−cの変位ベクトル
である。なお、定数εは、線分長以下ならいかなる値で
もよい。しかし、あらかじめ最短線分長を知ることは困
難であるため、例えば線幅Wの1/10程度などといっ
た定め方でもよい。
Next, a method for forming a group of coordinate points of the connecting graphic 13 in the joint graphic forming section 2 will be described.
First, a point d ′ obtained by moving the point d in the opposite direction of the vector Vab by a small amount ε is obtained. That is, it is obtained as OVd ′ = OVd−ε · Eab. Here, OVd and OVd ′ are position vectors from the coordinate origin to points d and d ′, respectively, and ε is a predetermined constant. Similarly, a point h ′ obtained by moving the point h by a small amount ε in the direction of the vector Vbc.
Ask for. The vector Vbc is a displacement vector of the line segment bc. Note that the constant ε may be any value as long as it is equal to or less than the line segment length. However, since it is difficult to know the shortest line segment length in advance, it may be determined, for example, about 1/10 of the line width W.

【0022】次に折れ点の頂点mを求める。線分abお
よび線分cb方向の単位ベクトルEabおよびEcbを
用いると、点mへの位置ベクトルOVmは、 OVm=OVb+{W/(2sinθ)}・(Eab+
Ecb) により求められる。ここで、OVbは点bの位置ベクト
ル、θはEabとEcbのなす角である。ここで、si
nθは、ベクトルEabとEcbの外積により簡便に算
出できる。
Next, the vertex m of the break point is obtained. Using the unit vectors Eab and Ecb in the direction of the line segment ab and the line segment cb, the position vector OVm to the point m is obtained as follows: OVm = OVb + {W / (2 sin θ)} · (Eab +
Ecb). Here, OVb is the position vector of point b, and θ is the angle between Eab and Ecb. Where si
nθ can be easily calculated by the cross product of the vectors Eab and Ecb.

【0023】次に点bを微小量εだけ移動した点b’を
以下の式で求める。 OVb’=OVb−ε・(Eab+Ecb) このようにして求めた4点、すなわち、点d’,点m,
点h’,点b’を連結した四角形が接続図形13であ
る。
Next, a point b 'obtained by moving the point b by a small amount ε is obtained by the following equation. OVb ′ = OVb−ε · (Eab + Ecb) The four points obtained in this way, that is, the points d ′, m,
A rectangle connecting the points h ′ and b ′ is the connection graphic 13.

【0024】以上のようにして、矩形形成部1およびジ
ョイント図形形成部2における座標計算により、矩形図
形11および矩形図形12と、接続図形13を構成する
座標点群を求めることができた。求めた接続図形13
は、矩形図形11および矩形図形12に対して重複部分
をもつため、接続図形13と矩形図形11および矩形図
形12との接続辺部に空隙を生ずることはない。また、
塗りつぶし処理の仕様などによって接する辺と辺の間に
1ドットの空隙があいてしまう可能性がある場合であっ
ても、重複部分を有するので空隙が発生することはな
い。
As described above, by the coordinate calculation in the rectangle forming unit 1 and the joint figure forming unit 2, the coordinate points forming the rectangular figure 11, the rectangular figure 12, and the connection figure 13 can be obtained. Connection figure 13 found
Has an overlapping portion with respect to the rectangular graphic 11 and the rectangular graphic 12, so that no gap is generated at the connection side portion between the connecting graphic 13 and the rectangular graphic 11 and the rectangular graphic 12. Also,
Even if there is a possibility that there is a gap of one dot between sides that are in contact with each other due to the specifications of the filling process or the like, there is no gap due to the overlapping portion.

【0025】図3は、本発明の描画装置の実施の一形態
における第2の動作例の説明図である。この例では、ジ
ョイント図形形成部2において接続図形を微小量だけ変
形するとともに、矩形形成部1で形成する矩形図形も変
形して、矩形図形と接続図形の間の空隙を解消する方法
を示している。
FIG. 3 is an explanatory diagram of a second operation example in the embodiment of the drawing apparatus of the present invention. In this example, a method is shown in which a joint figure is deformed by a very small amount in the joint figure forming unit 2 and a rectangular figure formed by the rectangle forming unit 1 is also deformed to eliminate the gap between the rectangular figure and the connecting figure. I have.

【0026】この例において矩形形成部1で形成する矩
形図形11および矩形図形12は台形である。これらの
台形の座標群の構成方法について説明する。まず、線分
a−bの方向をもつ単位ベクトルEabを求める。線分
a−bのベクトルをVabとすると、単位ベクトルEa
bは Eab=Vab/|Vab| である。次に、単位ベクトルEabの法線単位ベクトル
EOabおよびEOab’を求める。法線単位ベクトル
EOabは、単位ベクトルEabを反時計回りにπ/2
回転させたものであり、法線単位ベクトルEOab’
は、単位ベクトルEabを時計回りにπ/2回転させた
ものである。すなわち、Eab=(x,y)とすると、 EOab =(−y,x), EOab’=(y,−x) である。次に、法線単位ベクトルEOabおよびEOa
b’をW/2倍した変位ベクトルEOWab,EOWa
b’を求める。変位ベクトルEOWab,EOWab’
は、 EOWab =(w/2)・EOab EOWab’=(w/2)・EOab’ で求めることができる。点bへこれらの変位ベクトルを
加えた点が、点dおよび点eとなる。
In this example, the rectangular figures 11 and 12 formed by the rectangular forming section 1 are trapezoids. A method of configuring these trapezoidal coordinate groups will be described. First, a unit vector Eab having the direction of the line segment ab is obtained. If the vector of the line segment ab is Vab, the unit vector Ea
b is Eab = Vab / | Vab |. Next, a normal unit vector EOab and EOab ′ of the unit vector Eab are obtained. The normal unit vector EOab is obtained by dividing the unit vector Eab counterclockwise by π / 2.
Rotated normal vector EOab '
Is obtained by rotating the unit vector Eab clockwise by π / 2. That is, if Eab = (x, y), EOab = (− y, x) and EOab ′ = (y, −x). Next, the normal unit vectors EOab and EOa
displacement vectors EOWab, EOWa obtained by multiplying b ′ by W / 2
Find b '. Displacement vectors EOWab, EOWab '
EOWab = (w / 2) · EOab EOWab ′ = (w / 2) · EOab ′ The points obtained by adding these displacement vectors to the point b are the points d and e.

【0027】ここでさらに、点eをベクトルEab方向
に微小量δだけ移動する。点eおよび移動した点e’の
位置ベクトルをそれぞれOVeおよびOVe’とする
と、位置ベクトルOVe’は、 OVe’=OVe+δ・Eab である。ここで、δは点eの移動量であり、任意に設定
可能である。例えば第1の動作例における微小量εと同
様に、線幅の1/10程度に設定してもよい。
Here, the point e is further moved by a small amount δ in the direction of the vector Eab. Assuming that the position vectors of the point e and the moved point e ′ are OVe and OVe ′, respectively, the position vector OVe ′ is OVe ′ = OVe + δ · Eab. Here, δ is the movement amount of the point e, and can be set arbitrarily. For example, similarly to the minute amount ε in the first operation example, it may be set to about 1/10 of the line width.

【0028】一方、点aを変位ベクトルEOWab,E
OWab’で移動したものが点gおよび点fである。以
上の4点、すなわち、点d,点e’,点f,点gによっ
て、台形状の矩形図形11の座標群が構成される。な
お、台形状の矩形図形12についても、まったく同様に
計算することができ、点h,点i,点jと、点kをベク
トルEcb方向に微小量δだけ移動させた点k’の4点
によって台形状の矩形図形12の座標群が構成される。
On the other hand, the point a is defined as a displacement vector EOWab, E
Points g and f are moved by OWab '. The above four points, that is, the point d, the point e ′, the point f, and the point g constitute a coordinate group of the trapezoidal rectangular figure 11. The trapezoidal rectangular figure 12 can be calculated in exactly the same way. The four points h, i, j, and k ′, which is obtained by moving the point k by a small amount δ in the direction of the vector Ecb. Thus, a coordinate group of the trapezoidal rectangular figure 12 is formed.

【0029】次に、ジョイント図形形成部2において接
続図形13の座標群を構成する方法について説明する。
この例における接続図形13は、点d’,点m,点
h’,点bの4点で構成する図形である。まず、点dを
Vabの逆方向に微小量εだけ移動した点d’を求め
る。すなわち、 OVd’=OVd−ε・Eab として求める。ここで、OVdおよびOVd’は、原点
から点d及び点d’それぞれへの位置ベクトル、εはあ
らかじめ定められた定数であり、任意に設定可能であ
る。上述の第1の動作例と同様に、やはり線幅Wの1/
10程度に設定することができる。また、矩形形成部1
で用いた微小量δとは、必ずしも同じ値でなくてよい。
点d’と同様に、点hをベクトルVbc方向に微小量ε
だけ移動した点h’を求める。次に頂点mを求める。線
分a−bおよび線分c−b方向の単位ベクトルEabお
よびEcbを用いると、点mへの位置ベクトルVmは、
次式により求められる。 Vm=OVb+{W/(2sinθ)}・(Eab+E
cb) ここで、OVbは点bの位置ベクトル、θはベクトルE
abとEcbのはさみ角である。以上の座標計算によ
り、接続図形13を構成する4つの座標、すなわち点
d’,点m,点h’,点bを求めることができる。
Next, a method of forming a coordinate group of the connection graphic 13 in the joint graphic formation unit 2 will be described.
The connection graphic 13 in this example is a graphic composed of four points d ', m, h', and b. First, a point d ′ obtained by moving the point d in the opposite direction of Vab by a small amount ε is obtained. That is, it is obtained as OVd ′ = OVd−ε · Eab. Here, OVd and OVd ′ are position vectors from the origin to points d and d ′, respectively, and ε is a predetermined constant and can be set arbitrarily. As in the first operation example, the line width W is also 1 /
It can be set to about 10. Also, the rectangular forming part 1
Is not necessarily the same value.
Similarly to the point d ′, the point h is shifted by a small amount ε in the vector Vbc direction.
The point h 'moved by the distance is obtained. Next, a vertex m is obtained. Using the unit vectors Eab and Ecb in the line segment ab and the line segment cb direction, the position vector Vm to the point m is
It is obtained by the following equation. Vm = OVb + {W / (2 sin θ)} · (Eab + E
cb) where OVb is the position vector of point b and θ is the vector E
The angle between ab and Ecb. By the above coordinate calculation, four coordinates constituting the connection graphic 13, that is, the points d ′, m, h ′, and b can be obtained.

【0030】このようにして矩形形成部1で求められた
台形状の矩形図形11および矩形図形12と、ジョイン
ト図形形成部2で求められた接続図形13の3図形によ
り幅を有する折れ線が描画できる。このとき、図3にハ
ッチングを施して示すように、矩形図形11の一部であ
る三角形d−e−e’、矩形図形12の一部である三角
形h−k−k’、接続図形13の一部である三角形b−
d−d’と三角形b−h−h’が他の図形と重複する。
そのため、各矩形図形と接続図形との接続部における空
隙の発生を排除することができる。
In this manner, a polygonal line having a width can be drawn by the three figures of the trapezoidal rectangular figure 11 and the rectangular figure 12 obtained by the rectangle forming unit 1 and the connection figure 13 obtained by the joint figure forming unit 2. . At this time, as shown by hatching in FIG. 3, a triangle dee-e 'which is a part of the rectangular figure 11, a triangle hkk' which is a part of the rectangular figure 12, and a Triangle b- which is a part
dd 'and the triangle bhhh' overlap with other figures.
For this reason, it is possible to eliminate the occurrence of voids at the connection between each rectangular figure and the connection figure.

【0031】なお、図3に示した例では、各矩形図形に
おける内側結合点を矩形図形外へずらし、接続図形の頂
点のうち外側結合点に対応する頂点を矩形図形内へずら
した。これに限らず、例えば各矩形図形の外側結合点を
矩形図形外へずらし、接続図形の結合点を線分のはさみ
角の開く側にずらしてもよい。ただしこの場合、微小量
εの大きさによっては、外側結合点をずらした際に図6
に示すように突き出てしまう可能性があるので、微小量
εをそのような不具合が発生しないように設定する必要
がある。
In the example shown in FIG. 3, the inside connection point of each rectangular figure is shifted out of the rectangular figure, and the vertices corresponding to the outside connection points among the vertices of the connected figure are shifted into the rectangular figure. However, the present invention is not limited to this. For example, the outside connection point of each rectangular figure may be shifted to the outside of the rectangular figure, and the connection point of the connection figure may be shifted to the open side of the line segment. However, in this case, depending on the size of the minute amount ε, when the outer joint point is shifted, FIG.
Therefore, it is necessary to set the minute amount ε so that such a problem does not occur.

【0032】図4は、本発明の描画装置の実施の一形態
における第3の動作例の説明図である。この例において
も、線分a−bと線分b−cとが点bにおいて接続し、
幅Wをもって描画されるとする。矩形図形11を構成す
る点d,点e,点f,点g、および矩形図形12を構成
する点h,点i,点j,点k、それに接続図形13の1
つの頂点である点mの算出方法は、上述の第1の動作例
と同様であるため、ここでは説明を省略する。また、接
続図形13の他の頂点は、矩形図形11および矩形図形
12の点d,点b,点hを共有する。このまま描画する
と、従来のように、矩形図形11,12と接続図形13
との接続部に空隙が生じる可能性があった。
FIG. 4 is an explanatory diagram of a third operation example in the embodiment of the drawing apparatus of the present invention. Also in this example, the line segment ab and the line segment bc are connected at the point b,
It is assumed that the image is drawn with the width W. Point d, point e, point f, point g forming the rectangular figure 11, point h, point i, point j, point k forming the rectangular figure 12, and one of the connecting figures 13
The method of calculating the point m, which is one vertex, is the same as in the above-described first operation example, and a description thereof will not be repeated. The other vertices of the connection graphic 13 share the points d, b, and h of the rectangular graphic 11 and the rectangular graphic 12. If drawing is performed as it is, rectangular figures 11 and 12 and connection figures 13
There was a possibility that a gap might be formed at the connection portion with.

【0033】この例では、矩形形成部1で形成する矩形
図形を、4点ではなく、6点で構成する。すなわち、図
4に示す矩形図形11を、点d,点b,点e,点f,点
a,点gで構成される矩形(正確には6角形)として生
成する。同様に、矩形図形12は、点h,点i,点c,
点j,点k,点bの6角形として構成する。なお、接続
図形13は、点d,点m,点h,点bの四角形として構
成する。
In this example, the rectangular figure formed by the rectangular forming section 1 is composed of six points instead of four points. That is, the rectangular graphic 11 shown in FIG. 4 is generated as a rectangle (exactly, a hexagon) composed of points d, b, e, f, a, and g. Similarly, the rectangular figure 12 has points h, i, c,
It is configured as a hexagon of points j, k and b. Note that the connection graphic 13 is configured as a quadrangle of points d, m, h, and b.

【0034】この方法により、接続図形13における点
bは、矩形図形11および矩形図形12の頂点と全く同
一のものが与えられるため、数値計算誤差は原理的に発
生しない。点d,点hについても同様である。したがっ
て数値計算誤差による空隙発生を完全に排除することが
できる。
According to this method, since the point b in the connection graphic 13 is exactly the same as the vertices of the rectangular graphic 11 and the rectangular graphic 12, a numerical calculation error does not occur in principle. The same applies to points d and h. Therefore, the generation of voids due to numerical calculation errors can be completely eliminated.

【0035】ただし、上述の図形塗りつぶし装置の仕様
等によって同一辺間に生ずる1ドット程度の空隙の可能
性は、この第3の動作例のみでは排除されない。そのた
め、図形塗りつぶし装置にその可能性があるとわかって
いる場合には、例えば上述の第1の動作例あるいは第2
の動作例を併用することにより、完全に間隙の発生しな
い描画が実現できる。その場合の微小量εはきわめて微
小(1ドットに相当する距離)でよい。
However, the possibility of a gap of about one dot occurring between the same sides due to the above-described specification of the figure filling device or the like is not excluded only in the third operation example. Therefore, if it is known that the figure filling apparatus has the possibility, for example, the first operation example or the second operation example described above is performed.
By using the operation example (2) together, it is possible to realize a drawing in which no gap is completely generated. In this case, the minute amount ε may be extremely small (a distance corresponding to one dot).

【0036】上述の各動作例では、接続図形が鋭い頂点
をもつ、いわゆるマイター接続による線分描画を行なう
場合について示した。線分の接続種類は、この他に、例
えば外側結合点(例えば図4における点dと点h)を直
線でつないだり、あるいは円弧や曲線でつなぐもの等が
ある。しかし、線分d−b上および線分d−h上の空隙
の排除という問題に対しては、接続種類は関係がないた
め、他の接続種類を用いる場合にも、上述の各例をまっ
たく同様に適用できる。
In each of the above-described operation examples, a case has been described in which a line drawing is performed by a so-called miter connection in which a connected figure has a sharp vertex. Other types of line segments include, for example, those connecting outer connection points (for example, points d and h in FIG. 4) with straight lines, or connecting them with arcs or curves. However, since the connection type has no relation to the problem of eliminating the gaps on the line segment db and the line segment dh, even when using other connection types, the above-described respective examples are completely eliminated. The same applies.

【0037】[0037]

【発明の効果】以上の説明から明らかなように、本発明
によれば、非常に精密でかつ太い幅をもった線図形を描
画する場合においても、直線の屈曲点に全く割れ(空
隙)のない高品位な線図形を描画することができるとい
う効果がある。
As is apparent from the above description, according to the present invention, even when a line figure having a very precise and wide width is drawn, no crack (gap) is formed at the bending point of the straight line. There is an effect that it is possible to draw no high-quality line figures.

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

【図1】 本発明の描画装置の実施の一形態を示す基本
構成図である。
FIG. 1 is a basic configuration diagram illustrating an embodiment of a drawing apparatus according to the present invention.

【図2】 本発明の描画装置の実施の一形態における第
1の動作例の説明図である。
FIG. 2 is an explanatory diagram of a first operation example in the embodiment of the drawing apparatus of the present invention.

【図3】 本発明の描画装置の実施の一形態における第
2の動作例の説明図である。
FIG. 3 is an explanatory diagram of a second operation example in the embodiment of the drawing apparatus of the present invention.

【図4】 本発明の描画装置の実施の一形態における第
3の動作例の説明図である。
FIG. 4 is an explanatory diagram of a third operation example in the embodiment of the drawing apparatus of the present invention.

【図5】 従来の描画装置における問題点の一例の説明
図である。
FIG. 5 is an explanatory diagram of an example of a problem in a conventional drawing apparatus.

【図6】 従来の描画装置における問題点の回避案の一
例の説明図である。
FIG. 6 is an explanatory diagram of an example of a solution to a problem in a conventional drawing apparatus.

【符号の説明】[Explanation of symbols]

1…矩形形成部、2…ジョイント図形形成部。 Reference numeral 1 denotes a rectangle forming unit, and 2 denotes a joint figure forming unit.

Claims (3)

【特許請求の範囲】[Claims] 【請求項1】 屈曲部を有する線図形を描画可能な描画
装置において、幅をもつ直線線分を矩形図形として少な
くとも2つ形成する矩形形成手段と、前記直線線分の連
結部における接続図形を形成するジョイント図形形成手
段を有し、前記ジョイント図形形成手段は、前記矩形形
成手段の形成する前記矩形図形の外側結合点を前記矩形
図形の側に微小距離だけ移動した点および前記直線線分
の接続点を線分はさみ角の広がる方向に微小距離だけ移
動した点を頂点として含む前記接続図形を形成すること
を特徴とする描画装置。
1. A drawing apparatus capable of drawing a line figure having a bent portion, wherein a rectangle forming means for forming at least two straight line segments having a width as a rectangular figure; A joint graphic forming means for forming the joint graphic forming means, wherein the joint graphic forming means moves a connecting point outside the rectangular graphic formed by the rectangular forming means by a small distance to the side of the rectangular graphic and the straight line segment. A drawing apparatus characterized by forming the connection figure including, as a vertex, a point at which a connection point is moved by a minute distance in a direction in which a line segment intersects widens.
【請求項2】 屈曲部を有する線図形を描画可能な描画
装置において、幅をもつ直線線分を矩形図形として少な
くとも2つ形成する矩形形成手段と、前記直線線分の連
結部における接続図形を形成するジョイント図形形成手
段を有し、前記矩形形成手段は、前記直線線分の折れ曲
がり内側の辺が微小距離だけ長くなるように前記矩形図
形を形成し、前記ジョイント図形形成手段は、前記矩形
形成手段の形成する前記矩形図形の外側結合点を前記矩
形図形の側に微小距離だけ移動した点を頂点に含む前記
接続図形を形成することを特徴とする描画装置。
2. A drawing apparatus capable of drawing a line figure having a bent portion, wherein: a rectangle forming means for forming at least two straight line segments having a width as a rectangular figure; A joint figure forming unit that forms the rectangular figure such that a side inside the bend of the straight line segment becomes longer by a small distance, and the joint figure forming unit forms the rectangular figure. A drawing apparatus, wherein the connected figure including a point at a vertex at which an outer joint point of the rectangular figure formed by a means is moved by a minute distance to the side of the rectangular figure is formed.
【請求項3】 屈曲部を有する線図形を描画可能な描画
装置において、幅をもつ直線線分を矩形図形として少な
くとも2つ形成する矩形形成手段と、前記直線線分の連
結部における接続図形を形成するジョイント図形形成手
段を有し、前記矩形形成手段は、前記直線線分の2両端
点および該2点それぞれを直線の法線方向に線幅の1/
2だけ移動した4点の計6点により構成される前記矩形
図形を形成することを特徴とする描画装置。
3. A drawing apparatus capable of drawing a line figure having a bent portion, wherein a rectangle forming means for forming at least two straight line segments having a width as a rectangular figure; And forming the joint figure forming means, wherein the rectangular forming means sets two end points of the straight line segment and each of the two points in the normal direction of the straight line to 1/1/2 of the line width.
A drawing apparatus for forming the rectangular figure constituted by a total of six points of four points moved by two.
JP16361797A 1997-06-20 1997-06-20 Plotting device Pending JPH1115985A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP16361797A JPH1115985A (en) 1997-06-20 1997-06-20 Plotting device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP16361797A JPH1115985A (en) 1997-06-20 1997-06-20 Plotting device

Publications (1)

Publication Number Publication Date
JPH1115985A true JPH1115985A (en) 1999-01-22

Family

ID=15777340

Family Applications (1)

Application Number Title Priority Date Filing Date
JP16361797A Pending JPH1115985A (en) 1997-06-20 1997-06-20 Plotting device

Country Status (1)

Country Link
JP (1) JPH1115985A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011044050A (en) * 2009-08-22 2011-03-03 Oki Data Corp Image processor
US9202148B2 (en) 2013-08-27 2015-12-01 Canon Kabushiki Kaisha Image processing apparatus and method for generating stencil data of a stroke based on shape information, connection-point information, and end-point information

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2011044050A (en) * 2009-08-22 2011-03-03 Oki Data Corp Image processor
US9202148B2 (en) 2013-08-27 2015-12-01 Canon Kabushiki Kaisha Image processing apparatus and method for generating stencil data of a stroke based on shape information, connection-point information, and end-point information

Similar Documents

Publication Publication Date Title
JP3318914B2 (en) System and method for rendering Bezier splines
JPH04220780A (en) Method and apparatus for decomposing arbitrary polygon into trapezoid
JPH1115985A (en) Plotting device
JP2012503809A (en) Method and apparatus for simplifying complex paths
JPH08504984A (en) Method of forming technical curves or contours of a plane
JPH11175740A (en) Method and device for drawing thin line
JP4248325B2 (en) Graphic processing device
JPH06168339A (en) Plotting device
US7099806B2 (en) Sizing processing system and computer program for the same
JP3402110B2 (en) Curve generator and CAD system with curve generator
JP5438432B2 (en) Image processing device
EP4362057A1 (en) Electron beam rendering device, electron beam rendering method, and recording medium
JPH08194816A (en) Segment approximation method and its system
JP3731221B2 (en) Thick line drawing apparatus and thick line drawing method
JP3485055B2 (en) Trapezoidal drawing method and trapezoidal drawing device
JPH06118940A (en) Device and method for editing image data
JP3697753B2 (en) Graphic editing apparatus and graphic editing method
JP4554313B2 (en) Offset processing apparatus, program, and recording medium
JP3139431B2 (en) Connection determination device, method and recording medium
JPH0785293A (en) Information processor
JP2720809B2 (en) Image display device
JPH02275591A (en) Graphic generator
JPH11297603A (en) Electron beam writing pattern forming method
JPH0581437A (en) Picture processing device
JP2011248700A (en) Image processing device and image processing program