JPH08129648A - Hatching method for two-dimensional polygon - Google Patents

Hatching method for two-dimensional polygon

Info

Publication number
JPH08129648A
JPH08129648A JP26702194A JP26702194A JPH08129648A JP H08129648 A JPH08129648 A JP H08129648A JP 26702194 A JP26702194 A JP 26702194A JP 26702194 A JP26702194 A JP 26702194A JP H08129648 A JPH08129648 A JP H08129648A
Authority
JP
Japan
Prior art keywords
line segment
dimensional
vertical
pattern
area
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
JP26702194A
Other languages
Japanese (ja)
Inventor
Kazuko Sonobe
和子 園部
Masami Sasaki
まさみ 佐々木
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.)
NIIGATA NIPPON DENKI SOFTWARE KK
NEC Corp
NEC Software Niigata Ltd
Original Assignee
NIIGATA NIPPON DENKI SOFTWARE KK
NEC Corp
NEC Software Niigata 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 NIIGATA NIPPON DENKI SOFTWARE KK, NEC Corp, NEC Software Niigata Ltd filed Critical NIIGATA NIPPON DENKI SOFTWARE KK
Priority to JP26702194A priority Critical patent/JPH08129648A/en
Publication of JPH08129648A publication Critical patent/JPH08129648A/en
Pending legal-status Critical Current

Links

Landscapes

  • Image Generation (AREA)

Abstract

PURPOSE: To shorten the time required to generate a continuous segment pattern in a two-dimensional polygonal area. CONSTITUTION: Longitudinal intervals (a) as pattern elements and lateral intervals (b) as pattern elements are obtained from a previously equipped input means, and lateral pattern element segments in the two-dimensional polygonal area are generated by 1st algorithm from equal-interval lateral segments which are generated at the longitudinal intervals (a) and longitudinal pattern element segments (L1, L2..., L9) in the two-dimensional polygonal area are generated by 2nd algorithm from equal-interval longitudinal segments which are generated at the lateral intervals (b).

Description

【発明の詳細な説明】Detailed Description of the Invention

【0001】[0001]

【産業上の利用分野】本発明は2次元多角形領域内に連
続的な線分模様をハッチングする場合のハッチング処理
方法に関する。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a hatching method for hatching continuous line segment patterns in a two-dimensional polygonal area.

【0002】[0002]

【従来の技術】従来、建築図面などにおいて、図1に示
すような連続的な線分模様を2次元多角形領域内にハッ
チングする場合のハッチング処理は、特開昭63−18
8281公報に詳述されているように、2次元多角形領
域を線分要素に分解し、その領域線分要素とY軸に平行
な直線との交点を求めることによって生成される線分、
および領域線分要素とX軸に平行な直線との交点を求め
ることによって生成される線分から、2次元多角形領域
内の縦の線分と、模様要素となる横の線分をそれぞれ求
め、その後に、縦の線分と横の線分の交点を求めて模様
要素となる縦の線分を求めていた。
2. Description of the Related Art Conventionally, in a construction drawing or the like, a hatching process for hatching a continuous line pattern as shown in FIG. 1 in a two-dimensional polygonal area is disclosed in Japanese Patent Laid-Open No. 63-18.
As described in detail in Japanese Patent No. 8281, a line segment generated by decomposing a two-dimensional polygonal region into line segment elements and obtaining an intersection of the region line segment element and a straight line parallel to the Y axis,
And a vertical line segment in the two-dimensional polygonal region and a horizontal line segment to be a pattern element are obtained from the line segments generated by obtaining the intersections of the region line segment element and the straight line parallel to the X axis, After that, the intersection of the vertical line segment and the horizontal line segment was obtained to obtain the vertical line segment as the pattern element.

【0003】[0003]

【発明が解決しようとする課題】上述した従来の2次元
多角形の連続的な線分模様のハッチング方法では、模様
要素の線分の生成を、すべて線分どうしの交点を求める
ことによって生成するため、2次元多角形領域が大きく
なればなるほど模様要素の線分の生成に要する時間が増
大するという欠点があった。
In the above-described conventional method of hatching continuous line segment patterns of a two-dimensional polygon, the line segments of the pattern element are all generated by obtaining the intersection points of the line segments. Therefore, there is a drawback that the time required to generate the line segment of the pattern element increases as the size of the two-dimensional polygonal area increases.

【0004】[0004]

【課題を解決するための手段】第1の発明は、2次元多
角形領域内に連続的な線分模様をハッチングする場合の
2次元多角形のハッチング処理方法において、模様要素
となる縦方向の間隔aと模様要素となる横方向の間隔b
を予め備えた入力手段から取得し、次に、縦方向の前記
間隔aで生成された等間隔の横の線分から第1のアルゴ
リズムにより前記2次元多角形領域内の予め規定された
横方向の模様要素線分を生成し、次に横方向の前記間隔
bで生成された等間隔の縦の線分から第2のアルゴリズ
ムにより前記2次元多角形領域内の予め規定された縦方
向の模様要素線分を生成することを特徴とする。
According to a first aspect of the present invention, in a two-dimensional polygon hatching processing method in which a continuous line pattern is hatched in a two-dimensional polygonal area, a pattern element in the vertical direction is used as a pattern element. Spacing a and lateral spacing b, which is a pattern element
From the input means provided in advance, and then from the evenly-spaced horizontal line segments generated at the vertical spacing a by the first algorithm in the predetermined horizontal direction within the two-dimensional polygonal area. A pattern element line segment is generated, and then a predetermined vertical pattern element line in the two-dimensional polygonal area is generated by a second algorithm from the vertically-spaced vertical line segments generated at the interval b in the horizontal direction. It is characterized by generating minutes.

【0005】また、第2の発明は、2次元多角形領域内
に連続的な線分模様をハッチングする場合の2次元多角
形のハッチング処理方法において、まず、予め備えた入
力手段から模様要素となる縦方向の間隔aを取得し(ス
テップ2−1)、次に前記入力手段から模様要素となる
横方向の間隔bを取得し(ステップ2−2)、次に前記
2次元多角形領域の最小座標および最大座標を計算によ
り取得し(ステップ2−3)、次に前記2次元多角形領
域を各頂点座標から線分要素に分解し(ステップ2−
4)、次に前記ステップ2−3にて得られた前記2次元
多角形の前記最小座標および前記最大座標からできる矩
形領域内に前記ステップ2−1で得た前記縦方向の間隔
aの等間隔の横の線分を生成し(ステップ2−5)、次
に前記ステップ2−4で分解した前記2次元多角形領域
の前記領域要素線分と前記ステップ2−5で求めた前記
等間隔aの前記横の線分との交点を求め前記交点により
分割された前記2次元多角形領域の内側の線分を横方向
の模様要素線分とし(ステップ2−6)、さらに、前記
ステップ2−3で得た前記矩形両域内に前記ステップ2
−2で得た横方向の前記間隔bの等間隔の縦の線分を生
成し(ステップ2−7)、次に前記ステップ2−4で得
られた前記領域要素線分と前記ステップ2−7で求めた
前記等間隔bの前記縦線分との交点を求め前記交点によ
り分割された前記2次元多角形領域の内側の線分から予
め定められたアルゴリズムを用いて前記ステップ2−1
で得た前記縦方向の間隔aごとに求められる線分を縦方
向の模様要素線分とする(ステップ2−8)ことを特徴
とする。
The second aspect of the present invention is a two-dimensional polygon hatching processing method for hatching a continuous line pattern in a two-dimensional polygonal area. Is obtained (step 2-1), then the horizontal distance b, which is a pattern element, is obtained from the input means (step 2-2), and then the two-dimensional polygonal area is obtained. The minimum coordinates and the maximum coordinates are obtained by calculation (step 2-3), and then the two-dimensional polygonal area is decomposed from each vertex coordinate into line segment elements (step 2-
4) Next, in the rectangular area formed from the minimum coordinates and the maximum coordinates of the two-dimensional polygon obtained in step 2-3, the vertical spacing a obtained in step 2-1 is equal. A horizontal line segment is generated (step 2-5), and then the area element line segment of the two-dimensional polygonal area decomposed in step 2-4 and the equal interval obtained in step 2-5. The intersection of a with the horizontal line segment is obtained, and the line segment inside the two-dimensional polygonal area divided by the intersection is set as a horizontal pattern element line segment (step 2-6), and further, the step 2 -3, the step 2
-2 generates vertical line segments at equal intervals in the horizontal direction of the space b (step 2-7), and then the area element line segment obtained in step 2-4 and the step 2- Step 2-1 is performed using a predetermined algorithm from the line segments inside the two-dimensional polygonal area obtained by obtaining the intersections with the vertical line segments at the equal intervals b obtained in Step 7 above.
It is characterized in that the line segment obtained for each of the vertical direction intervals a obtained in (1) is set as a vertical pattern element line segment (step 2-8).

【0006】[0006]

【実施例】次に、本発明について図面を参照して説明す
る。
Next, the present invention will be described with reference to the drawings.

【0007】図1は2次元多角形の連続的な線分模様の
ハッチング例を示す図、図2は本発明の一実施例を示す
処理フロー図、図3は本実施例における2次元多角形領
域の最小−最大座標および2次元多角形領域データを示
す図、図4は最小−最大領域内の横線分の生成方法を示
す図、図5は2次元多角形領域の横線分の模様要素の生
成方法を示す図、図6は最小−最大領域内の縦線分の生
成方法を示す図、図7は2次元多角形領域の縦線分の模
様要素の生成方法および2次元領域要素と最小−最大領
域内の縦線分との交点テーブルの生成方法を示す図、図
8は2次元多角形両域内の縦線分の模様要素を生成する
場合の参考図である。
FIG. 1 is a diagram showing an example of hatching of continuous line segment patterns of a two-dimensional polygon, FIG. 2 is a processing flow chart showing one embodiment of the present invention, and FIG. 3 is a two-dimensional polygon in this embodiment. FIG. 4 is a diagram showing a minimum-maximum coordinate of a region and two-dimensional polygon region data, FIG. 4 is a diagram showing a method of generating a horizontal line segment in the minimum-maximum region, and FIG. 5 is a pattern element of a horizontal line segment of a two-dimensional polygon region. FIG. 6 is a diagram showing a generation method, FIG. 6 is a diagram showing a generation method of a vertical line segment in a minimum-maximum region, and FIG. 7 is a generation method of a vertical line segment pattern element of a two-dimensional polygon region and a two-dimensional region element and a minimum. FIG. 8 is a diagram showing a method of generating an intersection table with vertical line segments in the maximum area, and FIG. 8 is a reference diagram for generating pattern elements of vertical line segments in both areas of a two-dimensional polygon.

【0008】本実施例の2次元多角形のハッチング方法
は、図2に示すように、まず、ステップ2−1において
予め備えた入力手段から模様要素となる縦方向の間隔a
を取得し、ステップ2−2において、模様要素となる横
方向の間隔bを取得する。次に、ステップ2−3におい
て、図3に示すような2次元多角形領域の最小座標(x
1,y1)−最大座標(x2,y2)を取得する。
In the two-dimensional polygonal hatching method of the present embodiment, as shown in FIG. 2, first, in step 2-1 the vertical spacing a from the input means provided in advance becomes pattern elements.
Is acquired, and in step 2-2, a horizontal interval b that is a pattern element is acquired. Next, in step 2-3, the minimum coordinates (x
1, y1) -Get the maximum coordinate (x2, y2).

【0009】次に、ステップ2−4において、図3に示
すように、2次元多角形領域を各頂点座標から線分要素
に分解する。次のステップ2−5では、図4に示すよう
に、ステップ2−3にて得られた2次元多角形の最小座
標(x1,y1)−最大座標(x2,y2)からできる
矩形領域内に、ステップ2−1で得た縦方向の間隔aの
等間隔の線分(y=aN+y1…NはN>0)を生成す
る。
Next, in step 2-4, as shown in FIG. 3, the two-dimensional polygonal area is decomposed from each vertex coordinate into line segment elements. In the next step 2-5, as shown in FIG. 4, within the rectangular area formed from the minimum coordinates (x1, y1) -maximum coordinates (x2, y2) of the two-dimensional polygon obtained in step 2-3. , The line segments (y = aN + y1 ... N is N> 0) at equal intervals of the vertical interval a obtained in step 2-1 are generated.

【0010】次のステップ2−6では、図5に示すよう
に、ステップ2−4で分解した領域要素線分と、ステッ
プ2−5で求めた等間隔aの2次元多角形領域内の横の
線分との交点を求めて、各線分を交点で複数の線分に分
割し、2次元多角形領域の内側の線分を模様要素線分と
して生成する。
At the next step 2-6, as shown in FIG. 5, the area element line segment decomposed at step 2-4 and the horizontal line in the two-dimensional polygonal area having the equal interval a obtained at step 2-5. Then, each line segment is divided into a plurality of line segments at the intersections, and the line segment inside the two-dimensional polygonal area is generated as a pattern element line segment.

【0011】さらに、ステップ2−7では、図6に示す
ように、ステップ2−3で得た2次元多角形の最小座標
(x1,y1)−最大座標(x2,y2)からできる矩
形両域内に、ステップ2−2で得た横方向の間隔bの等
間隔の縦線分(x=bN+x1…ここでN>0)を生成
する。
Further, in step 2-7, as shown in FIG. 6, within the rectangular both regions formed from the minimum coordinates (x1, y1) -maximum coordinates (x2, y2) of the two-dimensional polygon obtained in step 2-3. Then, vertical line segments (x = bN + x1 ... where N> 0) at equal intervals of the horizontal distance b obtained in step 2-2 are generated.

【0012】次のステップ2−8では、ステップ2−4
で分解した領域要素線分と、ステップ2−7で求めた等
間隔bの2次元多角形領域内の縦線分との交点を求め
て、各線分を交点で複数の線分に分割し、2次元多角形
領域の内側の線分を生成する。生成した線分の始点座標
を始点座標値テーブルに、終点座標を終点座標値テーブ
ルにそれぞれ設定する。
In the next step 2-8, step 2-4
The intersections of the region element line segments decomposed in step 2 and the vertical line segments in the two-dimensional polygonal region of equal intervals b obtained in step 2-7 are obtained, and each line segment is divided into a plurality of line segments at the intersections, Generate a line segment inside the two-dimensional polygonal area. The starting point coordinates of the generated line segment are set in the starting point coordinate value table, and the ending point coordinates are set in the ending point coordinate value table.

【0013】さらに、ステップ2−9で、ステップ2−
8で生成した始点座標値テーブルと終点座標値テーブル
を用いて、2次元両域内の縦の模様線分を生成する。
Further, in step 2-9, step 2-
Using the starting point coordinate value table and the ending point coordinate value table generated in step 8, vertical pattern line segments in both two-dimensional areas are generated.

【0014】ここで、ステップ2−8の2次元領域と縦
線分の交点テーブル生成を図7を参照して説明する。ま
ず、分図7−1に示すLの線分(x=b+x1)と2次
元多角形領域の交点を求める。次に、図7−2に示すよ
うに、求められた交点p1,p2で線分L1,L2,L
3に分割し、線分L1,L2,L3のうち2次元多角形
領域の内側となる線分L2を生成する。次に、図7−3
に示すように、L1の始点座標値p1を始点座標値デー
ブルS(図示していない)に、終点座標値P2を終点座
標値テーブルE(図示していない)に設定する。線分
M,Nも同様である。
The generation of the intersection table of the two-dimensional area and the vertical line segment in step 2-8 will be described with reference to FIG. First, the intersection of the line segment (x = b + x1) of L shown in the segment diagram 7-1 and the two-dimensional polygonal area is obtained. Next, as shown in FIG. 7B, line segments L1, L2, L are obtained at the obtained intersections p1, p2.
Then, the line segment L2 that is inside the two-dimensional polygonal area is generated among the line segments L1, L2, and L3. Next, FIG.
As shown in, the start point coordinate value p1 of L1 is set in the start point coordinate value table S (not shown), and the end point coordinate value P2 is set in the end point coordinate value table E (not shown). The same applies to the line segments M and N.

【0015】次に、ステップ2−9の2次元多角形領域
内縦線分の生成を図8を用いて説明する。
Next, the generation of vertical line segments in the two-dimensional polygonal area in step 2-9 will be described with reference to FIG.

【0016】図8における線分L1〜L9の生成順序
は、a0〜a1間に生成すべき模様線分L1,L2,L
3、a1〜a2間に生成すべき模様線分L4,L5,L
6、a2〜a3間に生成すべき模様線分L7,L8、a
3〜a4間に生成すべき模様線分L9の順に、それぞれ
の模様線分の始点終点座標を決定して生成する。
The generation order of the line segments L1 to L9 in FIG. 8 is as follows: pattern line segments L1, L2, L to be generated between a0 to a1.
3, pattern line segments L4, L5, L to be generated between a1 and a2
6, pattern line segments L7, L8, a to be generated between a2 and a3
The start point and end point coordinates of each pattern line segment are determined and generated in the order of the pattern line segment L9 to be generated between 3 and a4.

【0017】線分の始点終点座標値は、縦方向の間隔a
と横方向の間隔b、始点座標テーブル、終点座標テーブ
ルとから決定する。
The coordinate value of the start point and end point of the line segment is the vertical interval a.
And the horizontal interval b, the start point coordinate table, and the end point coordinate table.

【0018】a0〜a1間の模様線分L1,L2,L3
の場合のx座標値は、始点終点ともに初期値をx1+
b、x方向オフセット値をb*2とし、L1はx1+
b、L2はx1+b+b*2、L3はx1+b+b*2
+b*2と設定する。
Pattern line segments L1, L2, L3 between a0 to a1
In the case of, the x coordinate value is x1 +
The offset values in the b and x directions are b * 2, and L1 is x1 +
b and L2 are x1 + b + b * 2, L3 is x1 + b + b * 2
Set as + b * 2.

【0019】また、a1〜a2間の場合は、初期値をx
1+b*2、x方向のオフセット値をb*2とし、a2
〜a3間の場合は、初期値をx1+b、x方向オフセッ
ト値をb*2とする。
In the case of between a1 and a2, the initial value is x
1 + b * 2, the offset value in the x direction is b * 2, and a2
In the case of between -a3, the initial value is x1 + b and the x-direction offset value is b * 2.

【0020】模様線分のy座標値の決定方法は、a0〜
a1間の場合の始点座標値をy1、終点座標値をy1+
a、a1〜a2間の場合の始点座標値をa0〜a1間の
始点座標値+a、終点座標値をa0〜a1間の終点座標
値+aとして設定し、設定した始点座標値とステップ2
−8で設定した始点座標値テーブルと終点座標値テーブ
ルとの関係から生成すべき線分であるかを判定する。
The method for determining the y coordinate value of the pattern line segment is a0 to a0.
In the case of a1, the start point coordinate value is y1 and the end point coordinate value is y1 +
In the case of a and a1 to a2, the start point coordinate value is set as the start point coordinate value + a between a0 to a1 and the end point coordinate value is set as the end point coordinate value + a between a0 to a1.
Based on the relationship between the start point coordinate value table and the end point coordinate value table set in -8, it is determined whether the line segment is a line segment to be generated.

【0021】判定の結果、生成すべき線分である場合
は、始点座標値と始点座標値テーブルの値を比較して、
始点座標値テーブルの値の方が大きい場合には、始点座
標値を始点座標値テーブルの値に変更する。また、終点
座標値と終点座標値テーブルの値を比較して、終点座標
値テーブルの値の方が小さい場合には、終点座標値を終
点座標値テーブルの値に変更する。
If the result of determination is that the line segment is to be generated, the start point coordinate value and the value in the start point coordinate value table are compared,
When the value in the starting point coordinate value table is larger, the starting point coordinate value is changed to the value in the starting point coordinate value table. Further, the end point coordinate value is compared with the value of the end point coordinate value table, and if the value of the end point coordinate value table is smaller, the end point coordinate value is changed to the value of the end point coordinate value table.

【0022】上述した方法で決定した座標値で、模様要
素の線分として生成する。
The coordinate value determined by the above-described method is generated as a line segment of the pattern element.

【0023】縦の模様線分の清々を修了したとき、図1
に示すような2次元多角形両域内に連続的な線分の模様
が表示される。
When the cleanliness of the vertical pattern line segment is completed, FIG.
A continuous line segment pattern is displayed in both areas of the two-dimensional polygon as shown in FIG.

【0024】以上述べたように、本発明は、連続的な線
分模様を2次元多角形領域内にハッチングする場合に、
模様要素となる縦の線分を、横の模様線分との交点を求
めずに縦方向の間隔aと横方向の間隔bから定まるアル
ゴリズムにより生成することができる。
As described above, according to the present invention, when a continuous line pattern is hatched in a two-dimensional polygon area,
A vertical line segment that is a pattern element can be generated by an algorithm that is determined from a vertical interval a and a horizontal interval b without obtaining an intersection with the horizontal pattern line segment.

【0025】[0025]

【発明の効果】以上説明したように、連続的な線分模様
を2次元多角形領域内にハッチングする場合に、模様要
素となる縦の線分を、縦方向の間隔aと横方向の間隔b
から定まるアルゴリズムにより生成することができるよ
うにしたことにより、連続的な線分模様の生成に要する
時間を短縮することができる効果がある。
As described above, when a continuous line pattern is hatched in a two-dimensional polygonal area, vertical line segments that are pattern elements are separated by a vertical space a and a horizontal space. b
Since it can be generated by the algorithm defined by, there is an effect that the time required to generate a continuous line segment pattern can be shortened.

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

【図1】2次元多角形の連続的な線分模様のハッチング
例を示す図である。
FIG. 1 is a diagram showing an example of hatching of continuous line segment patterns of a two-dimensional polygon.

【図2】本発明の一実施例を示す処理フロー図である。FIG. 2 is a processing flow chart showing an embodiment of the present invention.

【図3】本発明における2次元多角形領域の最小−最大
座標および2次元多角形領域データを示す図である。
FIG. 3 is a diagram showing minimum-maximum coordinates of a two-dimensional polygon area and two-dimensional polygon area data according to the present invention.

【図4】本発明における最小−最大領域内の横線分の生
成方法を示す図である。
FIG. 4 is a diagram showing a horizontal line segment generation method in the minimum-maximum region according to the present invention.

【図5】本発明における2次元多角形領域の横線分の模
様要素の生成方法を示す図である。
FIG. 5 is a diagram showing a method of generating a pattern element of a horizontal line segment of a two-dimensional polygonal area according to the present invention.

【図6】本発明における最小−最大領域内の縦線分の生
成方法を示す図である。
FIG. 6 is a diagram showing a method for generating a vertical line segment in a minimum-maximum region according to the present invention.

【図7】2次元多角形領域内の縦線分の生成および2次
元領域要素と最小−最大領域内の縦線分との交点テーブ
ルの生成方法を示す図である。
FIG. 7 is a diagram showing a method of generating a vertical line segment in a two-dimensional polygonal area and a method of generating an intersection table of a two-dimensional area element and a vertical line segment in a minimum-maximum area.

【図8】本発明による2次元多角形両域内の縦線分の模
様要素を生成する場合の参考図である。
FIG. 8 is a reference diagram in the case of generating a pattern element of a vertical line segment in both areas of a two-dimensional polygon according to the present invention.

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

ステップ2−1 縦方向の間隔取得ステップ ステップ2−2 横方向の間隔取得ステップ ステップ2−3 最小−最大座標の取得ステップ ステップ2−4 2次元領域要素の生成ステップ ステップ2−5 最小−最大領域内の横線分の生成ス
テップ ステップ2−6 2次元多角形領域内の横線分の生成
ステップ ステップ2−7 最小−最大領域内の縦線分の生成ス
テップ ステップ2−8 2次元領域と縦線分の交点テーブル
生成ステップ ステップ2−9 2次元多角形領域内の縦線分の生成
ステップ
Step 2-1 Vertical-direction interval acquisition step Step 2-2 Horizontal-direction interval acquisition step Step 2-3 Minimum-maximum coordinate acquisition step Step 2-4 Two-dimensional area element generation step Step 2-5 Minimum-maximum area Step of generating horizontal line segment in step 2-6 Step of generating horizontal line segment in two-dimensional polygonal area Step 2-7 Step of generating vertical line segment in minimum-maximum area Step 2-8 Two-dimensional area and vertical line segment Intersection table generation step Step 2-9 Generation step of vertical line segment in two-dimensional polygon area

Claims (2)

【特許請求の範囲】[Claims] 【請求項1】 2次元多角形領域内に連続的な線分模様
をハッチングする場合の2次元多角形のハッチング処理
方法において、模様要素となる縦方向の間隔aと模様要
素となる横方向の間隔bを予め備えた入力手段から取得
し、次に、縦方向の前記間隔aで生成された等間隔の横
の線分から第1のアルゴリズムにより前記2次元多角形
領域内の予め規定された横方向の模様要素線分を生成
し、次に横方向の前記間隔bで生成された等間隔の縦の
線分から第2のアルゴリズムにより前記2次元多角形領
域内の予め規定された縦方向の模様要素線分を生成する
ことを特徴とする2次元多角形のハッチング方法。
1. A method of hatching a two-dimensional polygon in which a continuous line pattern is hatched in a two-dimensional polygonal area, wherein a vertical interval a which is a pattern element and a horizontal direction which is a pattern element are used. The interval b is obtained from the input means provided in advance, and then the predetermined horizontal line segment in the two-dimensional polygonal region is calculated by the first algorithm from the equally-spaced horizontal line segments generated at the vertical interval a. Direction pattern element line segments are generated, and then the predetermined vertical pattern in the two-dimensional polygonal area is generated by the second algorithm from the equally-spaced vertical line segments generated at the horizontal distance b. A two-dimensional polygonal hatching method characterized by generating element line segments.
【請求項2】 2次元多角形領域内に連続的な線分模様
をハッチングする場合の2次元多角形のハッチング処理
方法において、まず、予め備えた入力手段から模様要素
となる縦方向の間隔aを取得し(ステップ2−1)、次
に前記入力手段から模様要素となる横方向の間隔bを取
得し(ステップ2−2)、次に前記2次元多角形領域の
最小座標および最大座標を計算により取得し(ステップ
2−3)、次に前記2次元多角形領域を各頂点座標から
線分要素に分解し(ステップ2−4)、次に前記ステッ
プ2−3にて得られた前記2次元多角形の前記最小座標
および前記最大座標からできる矩形領域内に前記ステッ
プ2−1で得た前記縦方向の間隔aの等間隔の横の線分
を生成し(ステップ2−5)、次に前記ステップ2−4
で分解した前記2次元多角形領域の前記領域要素線分と
前記ステップ2−5で求めた前記等間隔aの前記横の線
分との交点を求め前記交点により分割された前記2次元
多角形領域の内側の線分を横方向の模様要素線分とし
(ステップ2−6)、さらに、前記ステップ2−3で得
た前記矩形両域内に前記ステップ2−2で得た横方向の
前記間隔bの等間隔の縦の線分を生成し(ステップ2−
7)、次に前記ステップ2−4で得られた前記領域要素
線分と前記ステップ2−7で求めた前記等間隔bの前記
縦線分との交点を求め前記交点により分割された前記2
次元多角形領域の内側の線分から予め定められたアルゴ
リズムを用いて前記ステップ2−1で得た前記縦方向の
間隔aごとに求められる線分を縦方向の模様要素線分と
する(ステップ2−8)ことを特徴とする2次元多角形
のハッチング処理方法。
2. A method of hatching a two-dimensional polygon when a continuous line pattern is hatched in a two-dimensional polygonal area, wherein first, a vertical spacing a which becomes a pattern element from an input means provided in advance. Is obtained (step 2-1), then the horizontal interval b which is a pattern element is obtained from the input means (step 2-2), and then the minimum and maximum coordinates of the two-dimensional polygonal area are obtained. It is obtained by calculation (step 2-3), then the two-dimensional polygonal area is decomposed from the coordinates of each vertex into line segment elements (step 2-4), and then the step obtained in step 2-3 is performed. In the rectangular area formed by the minimum coordinates and the maximum coordinates of the two-dimensional polygon, horizontal line segments at equal intervals of the vertical interval a obtained in step 2-1 are generated (step 2-5), Next, the above step 2-4
The two-dimensional polygon obtained by finding the intersections of the area element line segments of the two-dimensional polygonal region decomposed in step 3 and the horizontal line segments of the equal interval a obtained in step 2-5. The line segment inside the area is used as a pattern element line segment in the horizontal direction (step 2-6), and the space in the horizontal direction obtained in step 2-2 is further included in both the rectangular regions obtained in step 2-3. Generate vertical line segments at equal intervals of b (step 2-
7) Next, the intersections of the area element line segments obtained in step 2-4 and the vertical line segments of the equal interval b obtained in step 2-7 are obtained, and the two divided by the intersection points.
The line segment obtained for each of the vertical intervals a obtained in step 2-1 by using a predetermined algorithm from the line segment inside the three-dimensional polygonal area is set as the vertical pattern element line segment (step 2 -8) A method for hatching a two-dimensional polygon, characterized in that
JP26702194A 1994-10-31 1994-10-31 Hatching method for two-dimensional polygon Pending JPH08129648A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP26702194A JPH08129648A (en) 1994-10-31 1994-10-31 Hatching method for two-dimensional polygon

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP26702194A JPH08129648A (en) 1994-10-31 1994-10-31 Hatching method for two-dimensional polygon

Publications (1)

Publication Number Publication Date
JPH08129648A true JPH08129648A (en) 1996-05-21

Family

ID=17438960

Family Applications (1)

Application Number Title Priority Date Filing Date
JP26702194A Pending JPH08129648A (en) 1994-10-31 1994-10-31 Hatching method for two-dimensional polygon

Country Status (1)

Country Link
JP (1) JPH08129648A (en)

Similar Documents

Publication Publication Date Title
JPH08129648A (en) Hatching method for two-dimensional polygon
JP2774653B2 (en) Character processor
JPH11175740A (en) Method and device for drawing thin line
JPH0769966B2 (en) Image processing method
JP2611007B2 (en) Image processing device
JP2904994B2 (en) Coordinate connection display method
JP3681240B2 (en) Three-dimensional shape display method and three-dimensional CAD system using the method
JPS625482A (en) Hidden-line processing method for three-dimensional wire frame model
JPH0449474A (en) Method and device for generating thick line
JPH03185568A (en) Method and device for plotting printed substrate mask
JP2003317112A (en) Method and system for contour line plotting using three- dimensional point group data
JPH02144781A (en) Method and device for painting out
JPS61256483A (en) Painting out circuit of sector graphic
JP2965021B2 (en) Coating processing method, coating processing method, and recording medium storing coating processing program
JPH05282401A (en) Method for correcting pattern of printed circuit board
JP3869982B2 (en) Image processing method
JPS63213091A (en) Depth map preparing device
JPH02202013A (en) Forming method of drawing pattern for exposure device
JPS6330983A (en) Graphic processor
JPH07121735A (en) Method and device for processing graphic
JPH05298409A (en) Mash generating method
JPH0689346A (en) Image generating device
JPS6336486A (en) Device for painting out polygon
JPH0747336B2 (en) Enlargement correction device for character patterns
JPH0696160A (en) Area setting method for printed circuit board

Legal Events

Date Code Title Description
A02 Decision of refusal

Free format text: JAPANESE INTERMEDIATE CODE: A02

Effective date: 19971125