JPH0452776A - Plotting system for circle - Google Patents

Plotting system for circle

Info

Publication number
JPH0452776A
JPH0452776A JP15599790A JP15599790A JPH0452776A JP H0452776 A JPH0452776 A JP H0452776A JP 15599790 A JP15599790 A JP 15599790A JP 15599790 A JP15599790 A JP 15599790A JP H0452776 A JPH0452776 A JP H0452776A
Authority
JP
Japan
Prior art keywords
axis
symmetrical
circle
storage means
coordinate
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
JP15599790A
Other languages
Japanese (ja)
Inventor
Yasuhiko Isobe
礒辺 泰彦
Zenshi Hayashi
林 善嗣
Tadayuki Kajiwara
梶原 忠之
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.)
Panasonic Holdings Corp
Original Assignee
Matsushita Electric Industrial 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 Matsushita Electric Industrial Co Ltd filed Critical Matsushita Electric Industrial Co Ltd
Priority to JP15599790A priority Critical patent/JPH0452776A/en
Publication of JPH0452776A publication Critical patent/JPH0452776A/en
Pending legal-status Critical Current

Links

Abstract

PURPOSE:To easily calculate plotting dots on a periphery and to plot a circle at high speed only by means of the generation of dots on a 1/8 periphery by obtaining the dots on the periphery by the operation of an axial direction distance minimum method and obtaining the symmetrical dots on the 1/8 periphery. CONSTITUTION:A plotting data generation means by the operation of the axial direction distance minimum method, a Y=X axis symmetrical coordinate generation means 8 generating coordinate data symmetrical to a (Y=X) axis, a second storage means 5e, an X-axis symmetrical coordinate generation means 9 generating coordinate data symmetrical to the X-axis, a fourth storage means 5g, a Y-axis symmetrical coordinate generation means 10, and a sixth storage means 5i are used. The dots on the 1/8 periphery are sequentially generated, and the dots symmetrical to the (Y=X)-axis, the X-axis and the Y-axis are simultaneously or sequentially generated. Thus, the circle can be plotted by the operation of the 1/8 periphery and the arbitrary circle can be plotted at high speed with simple constitution.

Description

【発明の詳細な説明】 産業上の利用分野 本発明は、パーソナルコンピュータ等のグラフィクス出
力装置であるデイスプレィ、印字装置等における、特に
軸方向距離最小法(参考文献二EPNEWS誌DTPの
基礎技術)を利用した高速の円の描画方式に関する。
DETAILED DESCRIPTION OF THE INVENTION Field of Industrial Application The present invention is particularly applicable to the minimum axial distance method (Reference 2 EPNEWS magazine basic technology of DTP) in graphics output devices such as personal computers, such as displays and printing devices. Regarding the high-speed circle drawing method used.

従来の技術 パーソナルコンピュータ等のグラフィクス出力において
円を描画する場合、SIN、CO8等の演算を行うこと
により正確な描画データを求めることができる。しかし
、上記SIN、CO8等の演算を行っていては演算時間
がかかりすぎるために演算専用のプロセッサを用いるな
どして高速化を図っている。また、円の描画において近
似円が許される場合には、適当な角度の内接正多角形で
近似円を描画したシ、1/4円周ドツトを計算より求め
残シはX軸対称、Y軸対称、原点対称な点を求めたシ、
円の最左点と最古点を求めDDA(Digital D
ifferential Analyzer )演算に
より最左点、最右点よシ上方向、下方向同時に円周上の
点を発生させる方法(特公平1−20471号公報)な
どによって描画速度を向上するようにしている。
BACKGROUND ART When drawing a circle in the graphics output of a personal computer or the like, accurate drawing data can be obtained by performing calculations such as SIN and CO8. However, performing calculations such as SIN and CO8 takes too much time, so attempts are made to speed up the calculations by using a dedicated processor for calculations. In addition, if an approximate circle is allowed when drawing a circle, the approximate circle is drawn using an inscribed regular polygon with an appropriate angle, the 1/4 circumference dot is calculated and the remaining circle is symmetrical with the X axis, and the remaining circle is symmetrical with the Y axis. Find points that are axially symmetrical and symmetrical to the origin,
Find the leftmost point and oldest point of the circle and use DDA (Digital D
The drawing speed is improved by a method (Japanese Patent Publication No. 1-20471) in which points on the circumference are simultaneously generated upward and downward from the leftmost point and the rightmost point by calculation (iferential analyzer).

発明が解決しようとする課題 しかしながら、上記演算専用プロセッサを用いる方式は
、処理速度は速いがコヌトががかシ過ぎるという欠点を
有し、上記各近似円発生方式は、少なくとも1/4円周
上の点を発生することが必要であシ、描画速度が遅いと
いう欠点を有していた。
Problems to be Solved by the Invention However, the method using the processor dedicated to calculations has a drawback that the processing speed is fast, but the contour is too bulky. It is necessary to generate points, and the drawing speed is slow.

本発明は、上記の課題を解決すべくなされたもので、軸
方向距離最小法を用い円周上の描画ドツトを容易に算出
でき、かつ、178円周上の点のみの発生で円の発生が
完了でき高速描画が可能な円の描画方式を提供すること
を目的としている。
The present invention has been made to solve the above problems, and it is possible to easily calculate the drawn dots on the circumference using the minimum axial distance method, and to generate a circle by generating only points on the circumference of 178 circles. The purpose of this invention is to provide a circle drawing method that can be completed and drawn at high speed.

課題を解決するための手段 本発明の円の描画方式は上記目的を達成するために、軸
方向距離最小法の演算による描画データ生成手段と、(
Y=X)軸に対称の座標データを生成する手段およびそ
の格納手段と、X軸に対称の座標データを生成する手段
およびその格納手段と、Y軸に対称の座標データを生成
する手段およびその格納手段とを有し、1/8円周上の
点を順次発生しそれをさらに(Y=X)軸、X軸、Y軸
に対称な点を同時または順次に発生することにより円の
データを発生させるという構成を有する。
Means for Solving the Problems In order to achieve the above object, the circle drawing method of the present invention includes a drawing data generation means based on the calculation of the minimum axial distance method, and (
means for generating coordinate data symmetrical about the Y-axis (Y=X), and means for storing the same; means for generating coordinate data symmetrical about the data of a circle by sequentially generating points on the 1/8th circumference and then simultaneously or sequentially generating points symmetrical to the (Y=X) axis, the X axis, and the Y axis. It has a configuration that generates.

作  用 上記の構成により、軸方向距離最小法の利用によ91次
式の演算で円周上の点を発生することができるとともに
、178円周上の点のY=X軸対称な点、X軸対称な点
、Y軸対称な点を求めていくことにより簡易な構成で高
速に円の描画ができる。
Operation With the above configuration, it is possible to generate points on the circumference by calculating the 91st equation by using the minimum axial distance method, and also to generate points on the 178th circumference that are symmetrical about the Y=X axis, By finding points that are symmetrical about the X-axis and points that are symmetrical about the Y-axis, a circle can be drawn at high speed with a simple configuration.

実施例 以下、図面を参照して本発明の一実施例を説明する。本
発明は、軸方向距離最小法という円弧の発生手法を利用
したもので、まず、この軸方向距離最小法についてその
概略を説明する。第3図においてxY平面上の原点0を
中心とする半径Rの円Cは次式で表わされる。
Embodiment Hereinafter, an embodiment of the present invention will be described with reference to the drawings. The present invention utilizes a circular arc generation method called the minimum axial distance method, and first, an outline of the minimum axial distance method will be explained. In FIG. 3, a circle C having a radius R and centered on the origin 0 on the xY plane is expressed by the following equation.

x+y=R 円Cの内部の点P(Xp、Yp)はopの長さをRp、
X軸とのなす角をθとすれば、 P (Xp、Yp) =P (Rpcosθ、Rpsi
nθ)と表現できるので Xp2+ Yp2== (Rpcosθ)2+ (Rp
sinθ′)2==Rp2(cos2θ+5in2θ)
:Rp2(R2 が成シ立つ。そこで、 ’(!、7)=R2−(x2+y2) とおくと、f(x、y)<oなる点は円の内部の点であ
シ、i(x、y)>oなる点は円の外部の点である。い
ま、ドツトの配列を含むメモリ上で円を発生する方法を
考える。メモリ上にxY平面をドツトの中心に格子点が
重なるように導入し、格子点によって円を近似すること
により円を描画する方法とする。ただし、半径はドツト
数で表わされかつ整数値をとるものとする。
x+y=R Point P (Xp, Yp) inside circle C has the length of op as Rp,
If the angle with the X axis is θ, then P (Xp, Yp) = P (Rpcosθ, Rpsi
nθ), so Xp2+ Yp2== (Rpcosθ)2+ (Rp
sinθ′)2==Rp2(cos2θ+5in2θ)
:Rp2(R2 holds true. Then, if we set '(!, 7)=R2-(x2+y2), the point where f(x, y)<o is a point inside the circle, and i(x , y)>o is a point outside the circle.Now, let us consider a method of generating a circle on a memory containing an array of dots.On the memory, we draw the xY plane so that the lattice points overlap with the centers of the dots. This is a method of drawing a circle by approximating the circle using grid points.However, the radius is expressed by the number of dots and takes an integer value.

描画の開始点を第4図のようにX軸上の最古点P、(X
l、Y、)=P、(R、o ) トL、反時計opに円
を近似する格子点を選択していく。いま、p、1(xi
−1,y、1) が決定しティるとしてP。
Set the starting point of drawing to the oldest point P, (X
l, Y, )=P, (R, o) To L, select grid points that approximate a circle counterclockwise op. Now, p, 1(xi
-1,y,1) is determined and P.

(xi、y、)ヲ求メル。Pl(R,o)から反時計回
りに45度までの178円の性質よりPi−1(xニー
、。
(xi, y,) Want me. From the property of 178 circles from Pl(R,o) to 45 degrees counterclockwise, Pi-1(x knee,.

Yi−1)K対しテPi(Xi、Yi) トLテ選択可
能す点は第6図に示t SH(x、、、、1.y、、 
+ 1)、T、 (X、 −1−1,Yi−1+1)の
2点のみである。そこでこれらの中点Zi(X、、  
、、Yi−1+1)カ円(’)内部に位置するならばP
、としてS、、外部あるいは円周上に位置するならばP
iとしてTiを選択する。
Yi-1) The selectable points for K and Pi(Xi, Yi) are shown in Figure 6.
There are only two points: + 1), T, and (X, -1-1, Yi-1+1). Then, these midpoints Zi(X,,
,,Yi-1+1) If it is located inside the circle ('), then P
, as S, , if it is located outside or on the circumference, then P
Select Ti as i.

前記f(x、y)を用いて f (Z、) = f (Xi−1−、、Y、、 +1
)〉。
Using the above f(x, y), f (Z,) = f (Xi-1-,, Y,, +1
)〉.

ならば、Pi(Xi、y、)=si(xi、 、 Yi
−1−4−1)f (Zi) = f (Xi、、、1
− 、 、 Y、−、+1)≦0ならば、Pi(Xi、
 Yi)=T、(Xi−1−1,Yi−1+1)となる
。このとき、それぞれのf (Zi+1): f(xi
−i、 Y、+1)を計算しておくことは有用である。
Then, Pi(Xi, y,)=si(xi, , Yi
-1-4-1) f (Zi) = f (Xi, , 1
− , , Y, −, +1)≦0, then Pi(Xi,
Yi)=T, (Xi-1-1, Yi-1+1). At this time, each f (Zi+1): f(xi
-i, Y, +1) is useful.

f (Zi) >0(7)とき、p、=siヨp、t 
(Z、+1)=f(X、、−H,Y、−4−1−1−)
−1)=f(Z、)−(2Y、−1+1)f(Z、)≦
O(Dとき、pi=’r、ヨリ、f(z、+1)=f(
4−1−1−5,Yl、、、1+1+1)= f (Z
i) −(2Yi−1+1 ) + (2X、−1+1
 )テアル。ΔYi−1=2Y、−,+1 、 ΔX1
−1=2Xi−1+1 トおくと、 f (Zi) )oならば、 P、 = (X、−1,Y、1+1 )f(zi+1 
)= f(zi) −ΔY1−1ΔY、=ΔYi−1+
2 ΔX、=Δxi−1 f (Z、)≦0ならば、 P、=(x、−1−1,Yi+1十旬 f (Z、1)= f (Z)−ΔY、−1+1Xi−
1Δ7.=ΔYi−4+2 Δ](、=ΔX、−1−2 となシ、順次円周上の近似格子点が得られることが従来
より確かめられている。第3図の円Cにおける初期値は
、 P1=(R,o) f (Z2 ) =R2−((R) 2+ (0+ 1
 )2)=R−巨 ΔY1=1 ΔX1=2R+1 である。f(Zi)の項に分数を含むため、実際の演算
ではf(x、y)に関する式を全て4倍として実行する
When f (Zi) >0(7), p, = siyo p, t
(Z, +1) = f(X,, -H, Y, -4-1-1-)
-1)=f(Z,)-(2Y,-1+1)f(Z,)≦
O(When D, pi='r, twist, f(z,+1)=f(
4-1-1-5, Yl, , 1+1+1)=f (Z
i) -(2Yi-1+1) + (2X,-1+1
) Teal. ΔYi-1=2Y, -, +1, ΔX1
-1=2Xi-1+1 If f (Zi) )o, then P, = (X,-1,Y,1+1)f(zi+1
) = f(zi) -ΔY1-1ΔY, =ΔYi-1+
2 ΔX, = Δxi-1 f If (Z,) ≦ 0, then P, = (x, -1-1, Yi + 1 decade f (Z, 1) = f (Z) - ΔY, -1 + 1 Xi-
1Δ7. = ΔYi-4+2 Δ](, = ΔX, -1-2 It has been conventionally confirmed that approximate grid points on the circumference can be obtained sequentially. The initial value at circle C in Fig. 3 is P1=(R,o) f (Z2) =R2-((R) 2+ (0+ 1
)2)=R-giant ΔY1=1 ΔX1=2R+1. Since the term f(Zi) includes a fraction, in actual calculations, all expressions regarding f(x, y) are executed by multiplying by four.

本発明は、上記軸方向距離最小法を用いて簡易な構成で
高速に円を描画するものであシ、以下第1図によりその
具体的な実施例について説明する。
The present invention is to draw a circle at high speed with a simple configuration using the above-described minimum axial distance method, and a specific embodiment thereof will be described below with reference to FIG.

第1図において1は描画する円の中心座標(:r:、y
)および半径Rを入力するための入力装置、2は本発明
の円の描画方式を用いた円発生装置であシ、3は前記円
発生装置2を制御するCPU、4はCPU3のプログラ
ムを格納するプログラムROM、6aはf (Zi) 
[を格納すルf (Z、) il!格納手段、6bはl
Yi値を格納するΔYi値格納手段、5CはΔxi値を
格納するlxi値格納手段、5dはpi(xi、yi)
の座標値を格納する第1格納手段、6・は第1格納手段
6dに格納されている座標値のY=X軸対称な座標値を
格納する第2格納手段、6fは第1格納手段5dに格納
されている座標値のX軸対称な座標値を格納する第3格
納手段、5qは第2格納手段6eに格納されている座標
値のX軸対称な座標値を格納する第4格納手段、6hは
第1格納手段6dに格納されている座標値のY軸対称な
座標値を格納する第6格納手段、51は第2格納手段6
eに格納されている座標値のY軸対称な座標値を格納す
る第6格納手段、6jは第3格納手段6fに格納されて
いる座標値のY軸対称な座標値を格納する第7格納手段
、6には第4格納手段6qに格納されている座標値のY
軸対称な座標値を格納する第8格納手段、6はf (Z
、+1)の演算を行うf(zi+1)演算装置、7aは
f(Z、)カf (Zi) )oカf (Zl) ≦o
かを判断すル第1判断手段、7bは第1格納手段6dに
格納されるX座標、Y座標の関係がY)Xを満たすがど
うかを判断する第2判断手段、8は(Y=X)軸に対称
な座標値を生成する(Y=x)軸対称座標生成手段、9
はX軸対称な座標値を生成するX軸対称座標生成手段、
1oはY軸対称な座標値を生成するY軸対称座標生成手
段、11は前記入力装置1から与えられた円の中心座標
(+、y)を格納する中心座標格納手段、12は前記第
1格納手段6dから第8格納手段6kまでに格納されて
いる各座標を基に中心座標格納手段11に格納されてい
る円の中心座標(x、y)を加えメモリ上にドツトを描
画するためのドツト描画手段、13は1ピツトが1ドツ
トに対応するように配置されたメモリ、14は前記メモ
リ13上に描画された円図形をデイスプレィや記録用紙
上に出力するための出力装置である。
In Figure 1, 1 is the center coordinate of the circle to be drawn (:r:, y
) and an input device for inputting the radius R, 2 is a circle generator using the circle drawing method of the present invention, 3 is a CPU that controls the circle generator 2, and 4 stores a program for the CPU 3. Program ROM, 6a is f (Zi)
[Storing f (Z,) il! storage means, 6b is l
ΔYi value storage means for storing Yi values; 5C is lxi value storage means for storing Δxi values; 5d is pi (xi, yi)
6. is a first storage means for storing the coordinate value of the coordinate value stored in the first storage means 6d; 6f is a second storage means for storing the coordinate value symmetrical to the Y=X axis of the coordinate value stored in the first storage means 6d; and 6f is the first storage means 5d. 5q is a fourth storage means for storing the X-axis symmetric coordinate values of the coordinate values stored in the second storage means 6e. , 6h is a sixth storage means for storing Y-axis symmetrical coordinate values of the coordinate values stored in the first storage means 6d, and 51 is a second storage means 6.
A sixth storage means stores a Y-axis symmetrical coordinate value of the coordinate value stored in e, and a seventh storage means 6j stores a Y-axis symmetrical coordinate value of the coordinate value stored in the third storage means 6f. The means 6 stores the Y coordinate value stored in the fourth storage means 6q.
8th storage means for storing axially symmetrical coordinate values, 6 is f (Z
, +1), 7a is f(Z,)f(Zi))o(Zl)≦o
7b is a second determining means for determining whether the relationship between the X and Y coordinates stored in the first storage means 6d satisfies Y)X; 8 is a second determining means for determining whether (Y=X ) axis-symmetrical coordinate generation means for generating axis-symmetrical coordinate values (Y=x), 9
is an X-axis symmetric coordinate generation means for generating X-axis symmetric coordinate values,
1o is a Y-axis symmetrical coordinate generation means for generating Y-axis symmetrical coordinate values; 11 is a center coordinate storage means for storing the center coordinates (+, y) of a circle given from the input device 1; and 12 is the first Based on the coordinates stored in the storage means 6d to the eighth storage means 6k, the center coordinates (x, y) of the circle stored in the center coordinate storage means 11 are added to draw a dot on the memory. A dot drawing means, 13 is a memory arranged so that one pit corresponds to one dot, and 14 is an output device for outputting the circular figure drawn on the memory 13 onto a display or recording paper.

以上のように構成された本発明の円の描画方式を用いた
円発生装置において第2図のフローチャート図に従って
その動作を説明する。描画すべき円に関する中心座標(
” * ’l ) 、半径Rが入力装置1よ多入力され
る(ステップの)。入力された円の中心座標(!、7)
は、第12図に示されるようにメモリ13内に定義され
た!yX座標して表わされ、かつ、ドツトの中心と一致
するように配置される。次にこの中心座標(x、y)を
中心座標格納手段11に格納することにより以降の演算
に対する中心座標の影響を除去する(ステップ@)。入
力された円データよりf (Z2 ) =4 R5を求
めf(Z、)値格納手段6aへ格納、ΔY1−4をΔY
i値格納手段5bへ格納、ΔX1=8R+4を求めΔx
th値格納手段5cへ格納、第4図に示すように円の中
心を座標原点に移動させた場合の描画開始点p1=(R
,o)を第1格納手段6dへ格納する(ステップf3)
。第1格納手段5d内の座標値(R,O)を(Y=X)
軸対称座標生成手段8へ転送しくy=x)軸対称座標値
を求める(ステップO)。第6図に示すように求まった
(Y=X)軸に対称な座標値(0,R)を第2格納手段
6eへ格納する(ステップの)。つぎに第1格納手段6
d内の座標値(R,O)をX軸対称座標生成手段9へ転
送しX軸対称座標値を求める(ステップG)。求まった
X軸対称座標M(R,O)を第3格納手段6fへ格納す
る(ステップ■)。第2格納手段6e内の座標値(o、
R)をX軸対称座標生成手段9へ転送しX軸対称座標値
を求める(ステップの)。第7図に示すように求まった
X軸に対称な座標値(o、−R)を第4格納手段6qへ
格納する(ステップ■)。つぎに第1格納手段Sd内の
座標値(R,o)をX軸対称座標生成手段10へ転送し
Y軸対称座標を求める(ステップ■)。
The operation of the circle generating apparatus using the circle drawing method of the present invention constructed as described above will be explained with reference to the flowchart shown in FIG. Center coordinates regarding the circle to be drawn (
” * 'l), the radius R is input multiple times from the input device 1 (of the step). The center coordinates of the input circle (!, 7)
is defined in the memory 13 as shown in FIG. It is expressed as yX coordinates and is arranged to coincide with the center of the dot. Next, by storing the center coordinates (x, y) in the center coordinate storage means 11, the influence of the center coordinates on subsequent calculations is removed (step @). Determine f (Z2) = 4 R5 from the input yen data, store it in f (Z,) value storage means 6a, and convert ΔY1-4 to ΔY
Store in the i value storage means 5b, calculate ΔX1=8R+4, and calculate Δx
Stored in the th value storage means 5c, the drawing start point p1=(R
, o) in the first storage means 6d (step f3)
. The coordinate values (R, O) in the first storage means 5d are (Y=X)
Transfer to the axially symmetrical coordinate generating means 8 (y=x) to obtain the axially symmetrical coordinate value (step O). As shown in FIG. 6, the determined coordinate values (0, R) symmetrical to the (Y=X) axis are stored in the second storage means 6e (in step). Next, the first storage means 6
The coordinate values (R, O) in d are transferred to the X-axis symmetric coordinate generating means 9 to obtain the X-axis symmetric coordinate values (Step G). The determined X-axis symmetrical coordinates M(R, O) are stored in the third storage means 6f (step 2). Coordinate values (o,
R) is transferred to the X-axis symmetrical coordinate generating means 9 to obtain the X-axis symmetrical coordinate value (step). As shown in FIG. 7, the determined coordinate values (o, -R) symmetrical to the X axis are stored in the fourth storage means 6q (step 2). Next, the coordinate values (R, o) in the first storage means Sd are transferred to the X-axis symmetrical coordinate generating means 10 to obtain Y-axis symmetrical coordinates (step 2).

第8図に示すように求まったY軸に対称な座標値(−R
、O)を第6格納手段6hへ格納する(ステップ■)。
As shown in Figure 8, the coordinate values symmetrical to the Y axis (-R
, O) in the sixth storage means 6h (step ■).

第2格納手段5e内の座標値(o、R)をY軸対称座標
生成手段1oへ転送しY軸対称座標を求める(ステップ
■)。求まったY軸に対称な座標値(o、R)を第6格
納手段51へ格納する(ステップ◎)。第3格納手段5
f内の座標値(R,o)をX軸対称座標生成手段10へ
転送しY軸対称座標値を求める(ステップ[株])。求
まったY軸に対称な座標値(−R2O)を第7格納手段
5jへ格納する(ステップ0)。第4格納手段6q内の
座標(o 、 −R)をY軸対称座標生成手段1oへ転
送しY軸対称座標値を求める(ステップ@)。求まった
Y軸に対称な座標値(o、 −R)を第8格納手段6に
へ格納する(ステップ■)。
The coordinate values (o, R) in the second storage means 5e are transferred to the Y-axis symmetrical coordinate generating means 1o to obtain Y-axis symmetrical coordinates (step 2). The determined coordinate values (o, R) symmetrical to the Y axis are stored in the sixth storage means 51 (step ◎). Third storage means 5
The coordinate values (R, o) in f are transferred to the X-axis symmetrical coordinate generation means 10 to obtain the Y-axis symmetrical coordinate values (step [shares]). The determined Y-axis symmetrical coordinate value (-R2O) is stored in the seventh storage means 5j (step 0). The coordinates (o, -R) in the fourth storage means 6q are transferred to the Y-axis symmetrical coordinate generating means 1o to obtain the Y-axis symmetrical coordinate value (step @). The determined Y-axis symmetrical coordinate values (o, -R) are stored in the eighth storage means 6 (step 2).

Y=X軸、X軸、Y軸合々に対称な座標値が生成・格納
されたので第1格納手段6dがら第8格納手段6kまで
に格納されている各座標値に対応するドツトをドツト描
画手段12を介してメモリ13へ描画する。このときド
ツト描画手段12は中心座標手段11に格納されている
円の中心座標(X。
Y=X-axis, X-axis, Y-axis symmetrical coordinate values have been generated and stored, so dot the dots corresponding to each coordinate value stored from the first storage means 6d to the eighth storage means 6k. Drawing is performed on the memory 13 via the drawing means 12. At this time, the dot drawing means 12 uses the center coordinates (X) of the circle stored in the center coordinate means 11.

y)を参照しながら描画する各ドツトのアドレスを発生
する(ステップ(21)。つぎに描画すべき点P2を軸
方向距離最小法にょシ求めるためf (Z2)の値を第
1判断手段7aで判断しf(Z2)>OであればP2と
してP、の真上の点が選ばれるためステップ■へ進む(
ステップ■)。決定したP2の座標値(R,−1)を第
1格納手段6dへ格納する(ステップ■)。次回の描画
点のためf(Z3)をf (Zi+1)演算装置6によ
り演算する。(ステップの)。求まったf (Z3)=
4R−9ヲi (z、) g。
The address of each dot to be drawn is generated while referring to y) (step (21). Next, in order to find the point P2 to be drawn using the minimum axial distance method, the value of f (Z2) is determined by the first determining means 7a. If f(Z2) > O, the point directly above P is selected as P2, so proceed to step ■ (
Step ■). The determined coordinate value (R, -1) of P2 is stored in the first storage means 6d (step 2). For the next drawing point, f(Z3) is calculated by the f (Zi+1) calculation device 6. (of steps). Found f (Z3)=
4R-9woi (z,) g.

格納手段5aへ格納する(ステップの)。次回の演算の
ためΔY2を求めΔYi値格納手段6bへ格納する(ス
テップ0)。同じく次回の演算のためΔx2を求めdx
i値格納手段6cへ格納する(ステップ■)。前記ステ
ップ■でf (Z 2 ) (oであればステップ■に
進みP2としては左上の点が選ばれその座標値(R−1
,1)が第1格納手段5dへ格納される(ステップ■)
。次回の描画点のたメf (23) ’e f (Zi
+1)演算装置6により演算する(ステップ■)。求ま
ったf (Z3) : 12R−sをf(Zi)値格納
手段6aへ格納する(ステップ@)。次回の演算のため
ΔY2を求めΔY、値格納手段6bへ格納する(ステッ
プ■、)、とともにΔx2を求めΔxi値格納手段6c
へ格納する(ステップO)。ステップ■では1/8の描
画が完了(R,1)なのでY2くX2となVステップG
へ戻る(ステップの)。第9図に示す点P2の座標値(
R,1)をステップ@からステップ■まで実行すること
により第10図に示すようにP2のY=X軸に対称な座
標値(1,R)、それらのX軸に対称な座標値(R,−
1)、(1,−R)、それらのY軸に対称な座標値(−
R,1)、(−1,R)。
Store it in the storage means 5a (step). For the next calculation, ΔY2 is obtained and stored in the ΔYi value storage means 6b (step 0). Similarly, find Δx2 for the next calculation and use dx
The i value is stored in the i value storage means 6c (step ■). In step 2, if f (Z 2 )
, 1) are stored in the first storage means 5d (step ■)
. Next drawing point number f (23) 'e f (Zi
+1) Calculate by the calculation device 6 (step ■). The obtained f (Z3): 12R-s is stored in the f (Zi) value storage means 6a (step @). For the next calculation, ΔY2 is calculated and ΔY is stored in the value storage means 6b (step ■), and at the same time, Δx2 is calculated and Δxi value storage means 6c.
(Step O). In step ■, 1/8th drawing is completed (R, 1), so Y2 x X2 V step G
Return to (step of). The coordinate values of point P2 shown in Fig. 9 (
R, 1) from step @ to step ■, the coordinate values (1, R) symmetrical to the Y=X axis of P2 and the coordinate values symmetrical to the X axis (R ,−
1), (1, -R), their coordinate values symmetrical to the Y axis (-
R,1), (-1,R).

(R、−1)、(−1,−R)が求まり続くステップ■
でこれら8点がドツトとしてメモリ13に描画される。
(R, -1), (-1, -R) are found and the next step ■
Then, these eight points are drawn in the memory 13 as dots.

次に描画すべき点P3を決定すべくステップ■からステ
ップ■が実行される。以上のように1/8円の描画が完
了するまでステップ@からステップ■が順次実行される
。1/8円の描画完された点PiのX座標、Y座標の関
係がYi)X。
In order to determine the next point P3 to be drawn, steps 2 to 2 are executed. As described above, steps @ to step (2) are sequentially executed until the drawing of 1/8 circle is completed. The relationship between the X and Y coordinates of the point Pi at which the 1/8th circle has been drawn is Yi)X.

となったときステップ■で第2判断手段7′bからの信
号により円の描画は終了される。このときメモリ13内
には第11図に示す円が描かれ・ている。
When this occurs, the drawing of the circle is terminated in step (2) by a signal from the second determining means 7'b. At this time, a circle shown in FIG. 11 is drawn in the memory 13.

このメモリ13内に描かれた円は、出力装置14にて可
視化される。
The circle drawn in the memory 13 is visualized on the output device 14.

なお、上記実施例では、Y=X軸対称な座標値を生成し
たのち、X軸対称、Y軸対称の順番に座標生成したが、
Y=X軸対称な座標値を生成したのちは、Y軸対称、X
軸対称の順番に座標生成しても同様に実施できる。
In addition, in the above embodiment, after generating coordinate values that are symmetrical about the Y=X axis, coordinates are generated in the order of X axis symmetry and then Y axis symmetry.
After generating coordinate values that are symmetrical about the Y=X axis,
The same method can be implemented even if the coordinates are generated in an axially symmetrical order.

発明の効果 本発明の円の描画方式によれば、1/8円周分の演算で
円が描け、かつ、演算方式として軸方向距離最小法を利
用しているため1次式の演算のみですむため、簡易な構
成で高速に任意の円を描画することができる実用上優れ
たものである。
Effects of the Invention According to the circle drawing method of the present invention, a circle can be drawn with calculations for 1/8th of the circumference, and since the minimum axial distance method is used as the calculation method, only linear equation calculations are required. Therefore, it is excellent in practical use because it can draw arbitrary circles at high speed with a simple configuration.

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

第1図は本発明の円の描画方式の一実施例のブロック図
、第2・図は前記一実施例の動作フローチャート、第3
図、第4図、第5図は軸方向距離最小法による円発生手
段を説明するための説明図、第6図、第7図、第8図、
第9図、第10図、第11図は円の描画状態を示す説明
図、第12図は描画すべき円とメモリ内に配置された座
標系の説明図である。 1・・・・・・入力装置、2・・・・・・円発生装置、
3・・・・・・CPU、4・・・・・・プログラムRO
M、5a・・・・・・f(Z、)値格納手段、6b・・
・・・・ΔY、値格納手段、6c・・・・・・ΔX、X
整値手段、6d・・・・・・第1格納手段、6e・・・
・・・第2格納手段、6f・・・・・・第3格納手段、
6q・・・・・・第4格納手段、6h・・・・・・第6
格納手段、61・・・・・・第6格納手段、5j・・・
・・・第7格納手段、6k・・・・・・第8格納手段、
6・・・・・・f (Z 、 +1)演算装置、7a・
・・・・・第1判断手段、7b・・・・・・第2判断手
段、8・・・・・・Y=x軸対称座標生成手段、9・・
・・・・X軸対称座標生成手段、10・・・・・・Y軸
対称座標生成手段、11・・・・・・中心座標格納手段
、12・・・・・・ドツト描画手段、13・・・・・・
メモリ、14・・・・・・出力装置。 代理人の氏名 弁理士 粟 野 重 孝 ほか1名第2
図 第 図 第 圏 第 図 ?。 ↑ 糀−7−1 ↑ ×(−1 第 図 第 図 第 図 第 図 第11 図 イ 第10 図 第12 図 ノ[5
Fig. 1 is a block diagram of an embodiment of the circle drawing method of the present invention, Fig. 2 is an operation flowchart of the above embodiment, and Fig.
Figures 4 and 5 are explanatory diagrams for explaining the circle generation means based on the minimum axial distance method, Figures 6, 7, and 8.
FIGS. 9, 10, and 11 are explanatory diagrams showing the state of drawing a circle, and FIG. 12 is an explanatory diagram of the circle to be drawn and the coordinate system arranged in the memory. 1...Input device, 2...Yen generator,
3...CPU, 4...Program RO
M, 5a...f(Z,) value storage means, 6b...
...ΔY, value storage means, 6c...ΔX, X
Integer value means, 6d...First storage means, 6e...
...Second storage means, 6f...Third storage means,
6q...Fourth storage means, 6h...Sixth
Storage means, 61...Sixth storage means, 5j...
...Seventh storage means, 6k...Eighth storage means,
6...f (Z, +1) arithmetic device, 7a.
...First judgment means, 7b...Second judgment means, 8...Y=x axis symmetrical coordinate generation means, 9...
. . . X-axis symmetrical coordinate generation means, 10 . . . Y-axis symmetrical coordinate generation means, 11 . . . Center coordinate storage means, 12 . . . Dot drawing means, 13.・・・・・・
Memory, 14... Output device. Name of agent: Patent attorney Shigetaka Awano and 1 other person 2nd
Figure diagram circle diagram? . ↑ Koji-7-1 ↑ ×(-1 Figure Figure Figure Figure Figure 11 Figure A Figure 10 Figure 12 Figure No [5

Claims (1)

【特許請求の範囲】[Claims] 描画すべき円の中心座標データを格納する中心座標格納
手段と、円の中心座標データと半径データとから描画開
始点の座標データを求め格納する手段と、(Y=X)軸
に対称の座標データを生成する手段およびその格納手段
と、X軸に対称の座標データを生成する手段およびその
格納手段と、Y軸に対称の座標データを生成する手段お
よびその格納手段と、円を求める軸方向距離最小法の演
算により逐次1/8円周までの描画データを生成する手
段とを有し、当初の描画データから最初に(Y=X)軸
に対称な座標データを生成し、つぎにこれらのデータか
らX軸・Y軸に対称な座標データを同時または順次に生
成し、これを1/8円周分行なうことにより円の描画デ
ータを生成する円の描画方式。
center coordinate storage means for storing center coordinate data of a circle to be drawn; means for determining and storing coordinate data of a drawing start point from the center coordinate data and radius data of the circle; and coordinates symmetrical to the (Y=X) axis. A means for generating data and a storage means for the same; a means for generating coordinate data symmetrical about the X-axis and a storage means thereof; a means for generating coordinate data symmetrical about the Y-axis and a storage means thereof; and an axial direction for determining a circle. It has means for sequentially generating drawing data up to 1/8th of the circumference by calculating the minimum distance method, first generating coordinate data symmetrical to the (Y=X) axis from the initial drawing data, and then generating these coordinate data. A circle drawing method that generates coordinate data symmetrical about the X-axis and Y-axis from the data simultaneously or sequentially, and generates circle drawing data by performing this for 1/8th of the circumference.
JP15599790A 1990-06-14 1990-06-14 Plotting system for circle Pending JPH0452776A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP15599790A JPH0452776A (en) 1990-06-14 1990-06-14 Plotting system for circle

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP15599790A JPH0452776A (en) 1990-06-14 1990-06-14 Plotting system for circle

Publications (1)

Publication Number Publication Date
JPH0452776A true JPH0452776A (en) 1992-02-20

Family

ID=15618087

Family Applications (1)

Application Number Title Priority Date Filing Date
JP15599790A Pending JPH0452776A (en) 1990-06-14 1990-06-14 Plotting system for circle

Country Status (1)

Country Link
JP (1) JPH0452776A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0834836A2 (en) * 1996-08-29 1998-04-08 Nec Corporation Circle drawing method

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
EP0834836A2 (en) * 1996-08-29 1998-04-08 Nec Corporation Circle drawing method
US5874968A (en) * 1996-08-29 1999-02-23 Nec Corporation Circle drawing method
EP0834836A3 (en) * 1996-08-29 1999-10-06 Nec Corporation Circle drawing method

Similar Documents

Publication Publication Date Title
EP0577130B1 (en) System and method for rendering bézier splines
TWI728986B (en) A graphics processing system, a method of operating the graphics processing system, and a computer software code for performing the method
JP2006221650A (en) Method of removing index of geometric primitive, rasterization device, computer readable medium
JPH0452776A (en) Plotting system for circle
US5920324A (en) Character pattern producing apparatus capable of producing character pattern having connected character elements
JPH11274053A (en) Maximum theoretical yield automatic calculating device and computer readable recording medium with program for executing having computer execute automatic calculation of maximum theoretical input volume stored therein
CN111429549B (en) Route image generation method, device and storage medium
EP1315126A2 (en) Image processing method, image processing apparatus, image output apparatus and storage medium
JPS63140382A (en) Plotting method for polygonal approximation of circles
JPH05324921A (en) Method and device for forming curve
JP4834642B2 (en) Graphic change device, graphic change method, computer program, and recording medium
CN109934883B (en) Nine-mango-star fractal image generation method
JP2734649B2 (en) Intersection calculation method between curved surface and straight line
JPH0785266A (en) Image rotating device
JPH0664443B2 (en) Vector drawing method
CN115718935A (en) Method for manufacturing semiconductor device, electronic device, and method for operating electronic device
JPH10283390A (en) Data compressing method
JPS58166418A (en) Pattern generator
JPH10275240A (en) Circular arc interpolation processing method
JPH0822540A (en) Recognition method for circle and arc
JPS63251873A (en) Method for detecting rotational angle of character string
JPH0133851B2 (en)
JP2001228852A (en) Output data generator and storage medium
JP2000298729A (en) Two-dimensional image generation device
JP4376371B2 (en) Circle expansion processing method