JPH0410179A - printing device - Google Patents
printing deviceInfo
- Publication number
- JPH0410179A JPH0410179A JP11466190A JP11466190A JPH0410179A JP H0410179 A JPH0410179 A JP H0410179A JP 11466190 A JP11466190 A JP 11466190A JP 11466190 A JP11466190 A JP 11466190A JP H0410179 A JPH0410179 A JP H0410179A
- Authority
- JP
- Japan
- Prior art keywords
- data
- coordinate
- straight line
- output
- terminal
- Prior art date
- Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
- Pending
Links
- 238000004364 calculation method Methods 0.000 claims abstract description 22
- 238000000034 method Methods 0.000 description 37
- 238000010586 diagram Methods 0.000 description 32
- 230000006870 function Effects 0.000 description 12
- 238000010187 selection method Methods 0.000 description 7
- 230000015654 memory Effects 0.000 description 5
- 230000000694 effects Effects 0.000 description 3
- 238000007796 conventional method Methods 0.000 description 2
- 238000001514 detection method Methods 0.000 description 2
- 102100023696 Histone-lysine N-methyltransferase SETDB1 Human genes 0.000 description 1
- 101710168120 Histone-lysine N-methyltransferase SETDB1 Proteins 0.000 description 1
- 239000013256 coordination polymer Substances 0.000 description 1
- 238000005429 filling process Methods 0.000 description 1
- 230000003252 repetitive effect Effects 0.000 description 1
- 230000000717 retained effect Effects 0.000 description 1
- 230000001360 synchronised effect Effects 0.000 description 1
- 230000010356 wave oscillation Effects 0.000 description 1
Landscapes
- Dot-Matrix Printers And Others (AREA)
- Image Generation (AREA)
Abstract
Description
【発明の詳細な説明】 [産業上の利用分野] 本発明は、印刷装置に関する。[Detailed description of the invention] [Industrial application field] The present invention relates to a printing device.
[従来の技術]
従来のプリンタにおいて例をとると、第2図(a)の2
4.25,26.27で示す平行四辺形を表示する場合
。[Prior Art] Taking an example of a conventional printer, 2 in Fig. 2(a)
4. When displaying parallelograms shown in 25 and 26.27.
例えば、 1965年発行のIBMSystem Jo
umal、 vol、4゜no、1.の25頁から3
0頁に記載されている。 J、E。For example, IBM System Jo published in 1965.
umal, vol, 4°no, 1. 3 from page 25 of
It is written on page 0. J.E.
Bresenham氏によるアルゴリズム(以下、プレ
ゼンハムアルゴリズムという)を使って、第2図(a)
に点線の矢印で示す 30,31,32,33,34,
35,36.37 のそれぞれの整数のX座標において
、そのX座標によって決定される水平線と実際の直線と
の交点が、どのビットの上にあるか計算して、第2図(
a)において28に示すような、灰色に着色して示すと
ころの、実際の直線に最も近いビットをオンにすること
によって表示していた。また、これらの処理は全て、ソ
フトウェアによって行われていた。なお。Using Mr. Bresenham's algorithm (hereinafter referred to as the Presentham algorithm), Figure 2 (a)
30, 31, 32, 33, 34, indicated by dotted arrows.
For each integer X coordinate of 35, 36.37, calculate which bit the intersection point between the horizontal line determined by the X coordinate and the actual straight line is on, and use the method shown in Figure 2 (
In a), as shown in 28, the bits closest to the actual straight line, which are colored gray, are turned on. Furthermore, all of these processes were performed by software. In addition.
ここで、21.22はそれぞれy軸、y軸を示し。Here, 21 and 22 indicate the y-axis and the y-axis, respectively.
23はX、yともに整数である座標点を示す。23 indicates a coordinate point where both X and y are integers.
[発明が解決しようとする課題]
しかし、このような従来の方法では、第2図(b)に示
すように、 42.43,44.45で示される細長
い図形を表示する場合、実際には連続した図形であるの
に2表示すると途切れてしまうことがある。なお。[Problems to be Solved by the Invention] However, in such a conventional method, when displaying the elongated shapes indicated by 42.43 and 44.45, as shown in FIG. Even though the figures are continuous, they may be interrupted when displayed twice. In addition.
ここで、 40.41はそれぞれy軸、y軸であり、4
6.47゜4g、49,50,51.52 は整数の
X座標を示す水平線である。Here, 40.41 are the y-axis and y-axis, respectively, and 4
6.47°4g, 49,50,51.52 are horizontal lines indicating integer X coordinates.
本発明はかかる課題に鑑みて成されたものであり、その
目的とするところは、従来のアルゴリズムの本質的な部
分を変更せずにさらに発展させ。The present invention has been made in view of these problems, and its purpose is to further develop the conventional algorithm without changing its essential parts.
任意の直線が全て連続して表示されるように、直線が通
過するビットは全てオンにして、なおかつ。Turn on all the bits that the straight line passes through so that any straight line will be displayed continuously.
塗りつぶしを行う部分を一部電子回路に置き換えること
により、アルゴリズムの実行時間を、大幅に短縮するこ
とにある。By replacing part of the filling part with an electronic circuit, the execution time of the algorithm can be significantly shortened.
[課題を解決するための手段]
本発明の印刷装置は1文字や図形を2輪郭を表す整数で
あるxy座標データとして扱い、用紙に印刷する。印刷
装置において、前記文字や図形のデータの入出力を行う
、データ入出力手段と、前記図形や文字の2輪郭を表す
整数であるxy座標データに含まれている2曲線のデー
タを、直線の整数のxy座標データに近似する。直線近
似部と。[Means for Solving the Problems] The printing device of the present invention treats one character or figure as xy coordinate data, which is an integer representing two outlines, and prints it on paper. In the printing device, a data input/output means inputs and outputs the data of the characters and figures, and data of two curves included in the xy coordinate data, which are integers representing the two outlines of the figures and characters, is input and outputted as a straight line. Approximate to integer xy coordinate data. With the straight line approximation part.
前記直線近似部によって1曲線のデータを近似した。前
記直線の整数のxy座標データと、入力されたままの直
線の整数であるxy座標データを使って、それら前記直
線を、前記印刷装置の離散的なビットに対応させる際に
、前記直線が通過する前記ビットを前記直線に対応させ
るように、前記直線で構成される前記図形や文字を塗り
つぶす範囲を決定するのに必要なデータを算出して出力
する。塗りつぶしデータ計算部と、前記塗りつぶしデー
タ計算部の出力を使って、塗りつぶしを行う範囲を決定
する。塗りつぶし範囲決定回路と、前記塗りつぶし範囲
決定回路の出力に従って、ビットマツプディジタルデー
タを作成して、用紙に転写する用紙転写装置を有するこ
とを特徴とする。Data of one curve was approximated by the linear approximation section. Using the integer xy coordinate data of the straight line and the integer xy coordinate data of the straight line as input, the straight line passes through when the straight line is made to correspond to the discrete bits of the printing device. data necessary for determining the range of filling in the figure or character made up of the straight line is calculated and output so that the bit corresponding to the straight line corresponds to the straight line. A range to be filled is determined using a fill data calculation section and the output of the fill data calculation section. The present invention is characterized by comprising a filling range determining circuit and a paper transfer device for creating bitmap digital data and transferring it to paper according to the output of the filling range determining circuit.
[作用] 本発明の印刷装置の作用について説明すると。[Effect] The operation of the printing apparatus of the present invention will be explained.
第1図の機能ブロック図に示すように、lのデータ入出
力手段にデータが入力されると、2の直線近似部におい
て、入力されたデータに曲線が含まれていた場合、直線
に近似される2次に、3の塗りつぶしデータ計算部にお
いて、直線が通過したビットがオンになるように、塗り
つぶしを行う場合に必要になるデータを求める。尚、こ
れらのデータについては後述する。ここで、塗りつぶし
を行う場合、どの様にビットを選択するかについて説明
する。As shown in the functional block diagram of Figure 1, when data is input to the data input/output means 1, in the linear approximation section 2, if the input data includes a curve, it is approximated to a straight line. Second, in the filling data calculation section 3, data necessary for filling is obtained so that the bits through which the straight line passes are turned on. Note that these data will be described later. Here, we will explain how to select bits when filling.
基本的に、塗りつぶしは向かい合った2本の辺の間にあ
るビットを全てオンにすることである。Basically, filling is turning on all the bits between two opposite sides.
また、印刷装置においては、印刷される面は離散的なビ
ットで構成されているから、整数の任意のX座標におい
て、向かい合った2本の辺の各々の整数のX座標を求め
ればよい、この様子を第3図に示す、ここで、第3図(
a)は、向がい合った辺のうち、左側にある辺(以下、
左辺という)について、整数の各X座標に於て、とのX
座標に対応するビットが、塗りつぶしを行う最も左側の
ビットとして選択されるかを示している1図中、3o2
で示すような、灰色に着色されたビットが、その整数の
X座標に於て最も左側にあると判断されたビットである
。303は、任意のビットにおけるそのビットの中心の
座標を示している。尚、303で示される座標は+
X+’lともに整数である。 304,305はそれぞ
れ、y軸、y軸である。In addition, in a printing device, the surface to be printed is made up of discrete bits, so at any integer X coordinate, it is sufficient to find the integer X coordinate of each of the two opposing sides. The situation is shown in Figure 3. Here, Figure 3 (
a) is the left side of the opposing sides (hereinafter referred to as
(referred to as the left side), at each integer X coordinate, and
3o2 in the figure 1 shows whether the bit corresponding to the coordinate is selected as the leftmost bit for filling.
The bit colored gray as shown in is the bit determined to be the leftmost bit in the X coordinate of the integer. 303 indicates the coordinates of the center of an arbitrary bit. Furthermore, the coordinates indicated by 303 are +
Both X+'l are integers. 304 and 305 are the y-axis and the y-axis, respectively.
第3図(b)は、右側にある辺(以下、右辺という)に
ついて、同様に示したものである。ここで、灰色に着色
したビットは、各整数のy座標に於て最も右側にあると
判断されたビットである。FIG. 3(b) similarly shows the side on the right side (hereinafter referred to as the right side). Here, the bit colored gray is the bit determined to be the rightmost bit in the y-coordinate of each integer.
そして、このように、高速に塗りつぶしを行うために必
要なデータを、4の塗りつぶし範囲決定回路に送り、塗
りつぶしを行う範囲を決定する。In this way, the data necessary for performing the filling at high speed is sent to the filling range determination circuit 4, which determines the range to be filled.
塗りつぶし範囲決定回路によって求められた塗りつぶし
を行う範囲のデータは、5の用紙転写装置に送られ、そ
のデータを基に、ビットマツプデータを作成して用紙に
転写される。The data of the range to be filled determined by the filling range determination circuit is sent to the paper transfer device 5, and based on the data, bitmap data is created and transferred onto the paper.
[実施例]
以下に1本発明の印刷装置の詳細を図示した実施例に基
づいて、説明する。[Example] Details of a printing apparatus of the present invention will be described below based on an illustrated example.
第10図は本発明の実施例を示すシステム構成図である
。FIG. 10 is a system configuration diagram showing an embodiment of the present invention.
図中符号111は、112のマイクロプロセサ(以下。Reference numeral 111 in the figure indicates a microprocessor 112 (hereinafter referred to as "microprocessor").
CPUという) 、 113のリードオンリメモリ
(以下。CPU), 113 read-only memory
(below.
romという) 、 114のランダムアクセスメモリ
(以下、ワークメモリという) 、115のアイ・オー
(以下、Iloという)から成るマイクロコンピュータ
で、116の用紙転写装置と、117の塗りつぶし範囲
決定回路と接続されている。ROM), 114 random access memories (hereinafter referred to as work memories), and 115 ILOs (hereinafter referred to as ILOs), which are connected to 116 paper transfer devices and 117 fill-in range determination circuits. ing.
111のマイクロコンピュータは、116の用紙転写装
置とのデータ入出力機能、直線近似機能、塗りつぶしデ
ータ計算機能を有し、これらの機能は113のromに
入っているプログラムにしたがって。The microcomputer 111 has a data input/output function with the paper transfer device 116, a linear approximation function, and a filling data calculation function, and these functions are performed according to the program contained in the ROM 113.
112のCPUが働いて、115のIloや、114の
ワークメモリを操作することによって実現する。This is achieved by operating the CPU 112 and operating the Ilo 115 and work memory 114.
第16図は、117の塗りつぶし範囲決定回路のブロッ
ク図であり、 CPUと用紙転写装置との接続状態も同
時に示しである。91Oで示す点線で囲んだ部分が塗り
つぶし範囲決定回路である。912゜913が高速に塗
りつぶしを行うために必要な。FIG. 16 is a block diagram of the filling range determination circuit 117, and also shows the connection state between the CPU and the paper transfer device. A portion surrounded by a dotted line indicated by 91O is a filling range determining circuit. 912° and 913 are necessary for high-speed filling.
左辺のデータを演算する回路ブロックである。This is a circuit block that calculates the data on the left side.
914.915は、高速に塗りつぶしを行うために必要
な、右辺のデータを演算する回路ブロックである。これ
らデータについては、後述する。914 and 915 are circuit blocks that calculate data on the right side, which is necessary for high-speed filling. These data will be described later.
911はCPUであり、916は用紙転写装置である。911 is a CPU, and 916 is a paper transfer device.
尚1本実施例では、座標は8ビツトの符号付きの整数で
表されるとしているが、座標は何ビットであっても構わ
ない。In this embodiment, the coordinates are expressed as 8-bit signed integers, but the coordinates may have any number of bits.
次にこの様に構成した装置の動作を、第11図と第12
図と第13図と第14図と第15図に示したフローチャ
ートと、第17図と第18図と第19図と第20図に示
した回路図、及び、第3図と第4図と第5図と第6図と
第7図と第8図に示した概念図に基づいて説明する。Next, the operation of the device configured in this way is shown in Figures 11 and 12.
13, 14, and 15, circuit diagrams shown in FIGS. 17, 18, 19, and 20, and FIGS. 3 and 4. The explanation will be based on the conceptual diagrams shown in FIGS. 5, 6, 7, and 8.
尚9本実施例では2図形や文字を印刷する位置をxy座
標で表現するものとする。In this embodiment, it is assumed that the positions at which figures and characters are printed are expressed in terms of x and y coordinates.
本印刷装置が動き出すと、111のマイクロコンピュー
タの113のromに記憶されているプログラムに従っ
て、116の用紙転写装置からの入力待になる。When the printing apparatus starts operating, it waits for input from the paper transfer device 116 according to the program stored in the ROM 113 of the microcomputer 111.
(ステップ1) 116の用紙転写装置から、115の工/○に対して。(Step 1) From 116 paper transfer devices to 115 work/○.
実行要求と文字や図形のデータが入力されると。When an execution request and text or graphic data are input.
(ステップ1)まず2曲線があるか調べる。 (ステッ
プ2)曲線があるなら、直線に近似する。(Step 1) First, check whether there are two curves. (Step 2) If there is a curve, approximate it to a straight line.
(ステップ3)
ステップ4では、高速に塗りつぶしを行う場合に必要な
データを計算する。これらのデータについて詳細に説明
する。尚9辺の始点の座標を(Xl。(Step 3) In step 4, data necessary for high-speed filling is calculated. These data will be explained in detail. Note that the coordinates of the starting point of the 9th side are (Xl.
yl)とし、終点の座標を(x2.y2) とする。yl) and the coordinates of the end point are (x2.y2).
また、ylくy2とする。Also, let yl be y2.
まず、左辺のデータの算出法、及び、ビットの選択法に
ついて、第4図に示す概念図をもとに説明する。第4図
(a)に、401で示される左辺、及び、各y座標に於
て、最も左にあると判断されたビットを、402で示さ
れる様に、灰色に着色して示す、404はy軸、4o5
はy軸である・第4図(b)は、第4図(a)の403
で示される円内を拡大して示したものである。ここで、
421゜422はX方向のビット境界、 451,
452,453,454はX方向のビット境界である。First, a method for calculating data on the left side and a method for selecting bits will be explained based on the conceptual diagram shown in FIG. 4. In FIG. 4(a), the left side indicated by 401 and the bit determined to be the leftmost position at each y-coordinate are shown colored gray as indicated by 402, and 404 indicates y-axis, 4o5
is the y-axis ・Figure 4(b) is 403 in Figure 4(a)
This is an enlarged view of the inside of the circle indicated by . here,
421°422 are bit boundaries in the X direction, 451,
452, 453, and 454 are bit boundaries in the X direction.
そして、 410.411,412で示したX方向のビ
ット境界からの距離(以下。Then, the distance from the bit boundary in the X direction indicated by 410, 411, and 412 (hereinafter).
errという)が、ビット選択の基準になる。X方向の
ビット境界から見て、 errが負ならば左のビット
。err) is the criterion for bit selection. Viewed from the bit boundary in the X direction, if err is negative, the left bit.
正ならば右のビットを選択する。第4図(b)の場合、
431のy座標に於て410のerrを調べると、負で
あるから、441のビットを最も左側にあるビットとす
る0次にerrに(x2−x 1) / (y2−y
1)という値を加えることによって、452のX方向の
ビット境界に於ける。411で示すerrを求める。こ
のerrは正だから、442で示すビットを選択する。If positive, select the right bit. In the case of Figure 4(b),
When we check the err of 410 at the y-coordinate of 431, it is negative, so the err of the 0th order with the bit of 441 as the leftmost bit is (x2-x 1) / (y2-y
1) at the bit boundary in the X direction of 452. The err indicated by 411 is determined. Since this err is positive, the bit indicated by 442 is selected.
そして、基準とするX方向のビット境界を422に移し
。Then, the reference bit boundary in the X direction is moved to 422.
411のerrに1− (x2−xl)/ (y2
yl)を加えることによって、412のerrを求め、
ビット選択の判断を繰り返す。1- (x2-xl)/(y2
Find the err of 412 by adding yl),
Repeat the bit selection decision.
e汀は、この手順を実行する前に1回だけ初期値を計算
し、その後は、定数c2 = (x2−xl)/(y
2−yl)あるいは、 cl = 1−(x2−xi
)/(y2−yl)を加えるだけでよい。eTing calculates the initial value only once before performing this procedure, and then uses the constant c2 = (x2-xl)/(y
2-yl) or cl = 1-(x2-xi
)/(y2-yl).
次に、左辺のerrの初期値の求め方を説明する。Next, how to obtain the initial value of err on the left side will be explained.
第5図は、errの初期値の計算例を示す概念図である
。第5図(a)は、501で示される辺の傾きが正の場
合について示し、第5図(b)は、521で示される辺
の傾きが負の場合について示している。FIG. 5 is a conceptual diagram showing an example of calculating the initial value of err. FIG. 5(a) shows the case where the slope of the side indicated by 501 is positive, and FIG. 5(b) shows the case where the slope of the side indicated by 521 is negative.
505.526で示した四角に囲まれた部分が1つのビ
ットに対応し、506,527は、ビットの中心座標を
示す。A portion surrounded by a square indicated by 505 and 526 corresponds to one bit, and 506 and 527 indicate the center coordinates of the bit.
尚、ビットの中心座標は整数であり、また、直線の始点
を(X 1+ y 1) 、終点を(x2.y2)と
する6 ここで、yl〈y2であるとする。Note that the center coordinates of the bits are integers, and the starting point of the straight line is (X 1 + y 1) and the ending point is (x2.y2). 6 Here, it is assumed that yl<y2.
まず、第5図(a)について説明する。First, FIG. 5(a) will be explained.
第5図(a)は501で示す直線の始点付近を表示した
ものである。507のX方向の境界から、502に示す
ような、直線の始点までの距離を求める。直線の始点の
xy座標は整数だから、この距離は−0,5である。こ
の値に503に示す距離を加えて、504に示すerr
の初期値を求める。ここで、503に示す距離は、 y
2−ylを deltay とおき、 x2−xlを
deltaXとおくと、503に示す距離は。FIG. 5(a) shows the vicinity of the starting point of the straight line indicated by 501. The distance from the boundary in the X direction of 507 to the starting point of a straight line as shown in 502 is determined. Since the xy coordinates of the starting point of the straight line are integers, this distance is -0,5. Add the distance shown in 503 to this value and get the err shown in 504.
Find the initial value of. Here, the distance shown at 503 is y
Set 2-yl as deltay and x2-xl as
If we set deltaX, the distance shown in 503 is.
0.5 X deltax / deltayであ
る。従って。0.5 x deltax/deltay. Therefore.
err = 0.5 X deltax / del
tay −0,5である。だたし、このままでは2割
り算や小数が存在するため、これを、整数のみで演算で
きるようにする。即ち2両辺に2 X deltay
をかけて。err = 0.5 x deltax / del
tay -0.5. However, as it is, there will be division by 2 and decimal numbers, so we will make it possible to perform calculations using only integers. In other words, 2 X deltay on both sides
Apply.
2 X deltay X err= delt
ax −deltay
とする。 errは正負の判断しかしないから、新た
に。2 X deltay X err= delt
Let ax −deltay. err only makes positive and negative decisions, so it's new.
2 X deltay X errを、 err
とおきなおす、よって。2 X deltay X err, err
I'll keep it that way.
err = deltax −deltayとなる
。err = deltax - deltay.
また、前述したerrに加える値。Also, the value added to err mentioned above.
c2 = (x2−xl)/(y2−yl)即ち。c2 = (x2-xl)/(y2-yl), ie.
c2 = deltax / deltayあるい
は。c2 = deltax/deltay or.
cl = 1−(x2−xl)/(y2−yl)即ち
。cl = 1-(x2-xl)/(y2-yl), ie.
cl = 1− deltax / delta
yにも 2 X deltay をかけなければなら
ないから。cl = 1-deltax/delta
Because y must also be multiplied by 2 X deltay.
c2 = 2 X deltax
cl = 2 X (deltay −delta
x)となる。c2 = 2 x deltax cl = 2 x (deltay - delta
x).
これで、傾きが正の左辺についてのデータが求まった。Now we have found the data for the left side with a positive slope.
次に、傾きが負の左辺のデータの求め方を、第5図(b
)を使って、説明する。Next, Figure 5 (b
) to explain.
第5図(b)は521で示す直線の始点付近を表示した
ものである。524のX方向の境界から、521に示す
ような、直線の始点までの距離を求める。直線の始点の
xy座標は整数だから、この距離は0.5である。この
値に523に示す距離(負の値)を加えて、524に示
すen−の初期値を求める。ここで、523に示す距離
は、 y2−ylを deltay とおき、 x2
−xiを deltaxとおくと、523に示す距離は
。FIG. 5(b) shows the vicinity of the starting point of the straight line indicated by 521. The distance from the boundary in the X direction of 524 to the starting point of a straight line as shown in 521 is determined. Since the xy coordinates of the starting point of the straight line are integers, this distance is 0.5. The distance (negative value) shown at 523 is added to this value to obtain the initial value of en- shown at 524. Here, the distance shown in 523 is set as deltay for y2-yl, and x2
If −xi is set as deltax, the distance shown in 523 is.
0.5 X deltax / deltayであ
る。従って。0.5 x deltax/deltay. Therefore.
err = 0.5 X deltax / del
tay + 0.5である。だたし、このままでは2割
り算や小数が存在するため、これを、整数のみで演算で
きるようにする。即ち2両辺に2 X deltay
をがけて。err = 0.5 x deltax / del
tay + 0.5. However, as it is, there will be division by 2 and decimal numbers, so we will make it possible to perform calculations using only integers. In other words, 2 X deltay on both sides
Go over it.
2 X deltay X err= delt
ax + deltayとする。 errは正負の
判断しかしないから、新たに。2 X deltay X err= delt
Let ax + deltay. err only makes positive and negative decisions, so it's new.
2 X deltay X errを、 err
とおきなおす、よって。2 X deltay X err, err
I'll keep it that way.
err = deltax +deltayとなる。err = deltax + deltay.
さらに。moreover.
m= deltax div deltayを求め
る。ここで、 divは整数の割り算を示す、そして。Find m=deltax div deltay. Here, div indicates integer division, and.
ml = m + 1 ml=m を求める。ml = m + 1 ml=m seek.
これで、左辺のデータが求まった。 (ステップ次に、
右辺のデータの算出法、及び、ビットの選択法について
、第6図に示す概念図をもとに説明する。第6図(a)
に、601で示される右辺、及び、各X座標に於て、最
も右にあると判断されたビットを、602で示される様
に、灰色に着色して示す、6o4はy軸、605はX軸
である。Now we have found the data on the left side. (Step next,
The method of calculating the data on the right side and the method of selecting bits will be explained based on the conceptual diagram shown in FIG. Figure 6(a)
, the right side indicated by 601 and the bit determined to be the rightmost at each X coordinate are colored gray as indicated by 602, 6o4 is the y axis, and 605 is the X coordinate. It is the axis.
第6図(b)は、第6図(a)の603で示される円内
を拡大して示したものである。ここで、 621゜62
2はX方向のビット境界、 651,652,653
,654はX方向のビット境界である。そして、 61
0.611,612で示したX方向のビット境界からの
距離(以下。FIG. 6(b) is an enlarged view of the inside of the circle indicated by 603 in FIG. 6(a). Here, 621°62
2 is the bit boundary in the X direction, 651, 652, 653
, 654 are bit boundaries in the X direction. And 61
Distance from the bit boundary in the X direction indicated by 0.611, 612 (hereinafter).
errという)が、ビット選択の基準になる。X方向の
ビット境界から見て、 errが負ならば左のビット
。err) is the criterion for bit selection. Viewed from the bit boundary in the X direction, if err is negative, the left bit.
正ならば右のビットを選択する。第6図(b)の場合、
631のX座標に於て610のerrを調べると、負で
あるから、641のビットを最も左側にあるビットとす
る0次にerrに(x2−xl)/ (y2 yl)
という値を加えることによって、652のX方向のビッ
ト境界に於ける。611で示すerrを求める。このe
汀は正だから、642で示すビットを選択する。そして
、基準とするX方向のビット境界を622に移し。If positive, select the right bit. In the case of Figure 6(b),
When we check the err of 610 at the X coordinate of 631, it is negative, so we set the bit of 641 as the leftmost bit to the 0th order err: (x2-xl)/(y2 yl)
By adding the value 652 at the bit boundary in the X direction. The err indicated by 611 is determined. This e
Since the value is positive, the bit indicated by 642 is selected. Then, the reference bit boundary in the X direction is moved to 622.
611のerrに1− (x2−xl)/ (y2−y
l)を加えることによって、612のerrを求め、ビ
ット選択の判断を繰り返す。611 err 1- (x2-xl)/(y2-y
1), the err of 612 is obtained and the bit selection judgment is repeated.
このように、右辺のデータも左辺のデータと全く同様に
計算できる。 (ステップ6)以上、説明してきたビッ
トの選択法を、左辺と右辺の違いに焦点を当ててまとめ
ると、第7図の概念図に示すように、左辺と右辺の処理
の違いは。In this way, the data on the right side can be calculated in exactly the same way as the data on the left side. (Step 6) To summarize the bit selection method explained above, focusing on the difference between the left side and the right side, as shown in the conceptual diagram of Fig. 7, the difference in processing between the left side and the right side is as follows.
最も左側のビット、あるいは、最も右側のビットを決め
る際、傾きが正であれば、第7図(a)に示すように、
左辺はelTをみて、その上のビットを決定するのに対
し、第7図(c)に示すように。When determining the leftmost bit or the rightmost bit, if the slope is positive, as shown in Figure 7(a),
The left side looks at elT and determines the bit above it, as shown in FIG. 7(c).
右辺はerrをみて、その下のビットを決定するという
ことである。また、傾きが負であれば、第7図(b)に
示すように、左辺はerrをみて、その下のビットを決
定するのに対し、第7図(d)に示すように、右辺はe
rrをみて、その上のビットを決定する。The right side looks at err and determines the bit below it. Also, if the slope is negative, as shown in Figure 7(b), the left side looks at err and determines the bit below it, while the right side looks at err and determines the bit below it, as shown in Figure 7(d). e
Look at rr and determine the bit above it.
なお2便宜上、左辺のerrをerrl、clをell
、c2をc21.mlをmll、m2をm12とする。2.For convenience, err on the left side is errl and cl is ell.
, c2 to c21. Let ml be ml and m2 be m12.
右辺についても、同様に、右辺のerrをerrr、c
lをclr、c2をc2r。Similarly, for the right side, err on the right side is errr, c
l is clr, c2 is c2r.
mlをmrl、m2をmr 2とする。Let ml be mrl and m2 be mr2.
このようにして左辺のerrl 、 cll 、 c
21 、 mll 。In this way, errl, cll, c on the left side
21, mll.
m12.及び右辺のerrr 、 clr 、 c2
r 、 mrl 、 mr2を計算したら、これらのデ
ータを塗りつぶし範囲決定回路に送る。(ステップ7)
このことについて、第12図に示したフローチャートと
、第8図に示した概念図に基づいて説明する。m12. and errr, clr, c2 on the right side
After calculating r, mrl, and mr2, these data are sent to the filling range determining circuit. (Step 7) This will be explained based on the flowchart shown in FIG. 12 and the conceptual diagram shown in FIG.
第8図に於て、太線は塗りつぶすべき多角形の輪郭を示
す、ここでは2便宜上、803で示した左上隅を座標軸
原点とし、801をX軸、802をy軸とする。また、
810で示した点が、ビットに於ける概念的な中心座標
であり、その値は整数である。さらに、ビットは、概念
的に、隙間なく並んだ正方形として表現し、オンになる
ビットは灰色に着色して表す、804’、805,80
6゜807.808,809は多角形の各々の辺である
。さらに、841,842,843,844゜845.
846,847,848,849で示した目盛りは整数
のX座標を表し、851,852゜853.854,8
56,857,858,859゜860で示した目盛り
は整数のX座標を示す、なお、821,822,823
の白抜きの矢印は。In FIG. 8, the thick line indicates the outline of the polygon to be filled in. For convenience, the upper left corner indicated by 803 is the coordinate axis origin, 801 is the X axis, and 802 is the y axis. Also,
The point indicated by 810 is the conceptual center coordinate of the bit, and its value is an integer. Furthermore, bits are conceptually expressed as squares lined up without gaps, and bits that are turned on are colored gray, 804', 805, 80.
6°807, 808, 809 are each side of the polygon. Furthermore, 841,842,843,844°845.
The scales marked 846, 847, 848, 849 represent integer X coordinates, 851,852°853.854,8
56,857,858,859゜The scale shown at 860 indicates the integer X coordinate, and 821,822,823
The white arrow is.
805の辺のそれぞれのerrを示し、831゜832
.833,834で示した白抜きの矢印は。Indicates the err of each side of 805, 831°832
.. The white arrows shown at 833 and 834 are.
804の辺のそれぞれのerrを示す。The err of each side of 804 is shown.
まず、各辺の始点のX座標の小さい順に並べる。First, arrange them in descending order of the X coordinate of the starting point of each side.
始点のX座標の等しい辺については、ここでは考えない
、 (ステップ18)
次に、最も小さい始点、あるいは、終点を持つ辺のX座
標値を取り出し、カレントのX座標とする。ここでは、
851で示したX座標になる。The sides with the same X coordinate of the starting point are not considered here. (Step 18) Next, the X coordinate value of the side having the smallest starting point or end point is taken out and set as the current X coordinate. here,
The X coordinate is indicated by 851.
(ステップ19) ステップ20では、塗りつぶし範囲決定回路に。(Step 19) In step 20, a filling range determining circuit is provided.
初期化信号を送って初期化する。Initialize by sending an initialization signal.
ステップ21では、全部の辺に対して、処理を終了した
か、即ち、塗りつぶしを完了したか調べる。塗りつぶし
が完了したら、ステップ30へ行く、そうでなければ、
ステップ22へ行く。In step 21, it is checked whether processing has been completed for all sides, that is, whether filling has been completed. If filling is completed, go to step 30, otherwise,
Go to step 22.
ステップ22では、カレントのX座標に始点がある全て
の辺について、X座標の小さい順に並べ換えをする。X
座標が同じなら、 deltax / deltay
で表される辺の傾きの小さい順に並べる。851のX座
標では804..805の辺が始点を持ち。In step 22, all sides whose starting point is at the current X coordinate are rearranged in descending order of X coordinate. X
If the coordinates are the same, deltax / deltay
Arrange the sides in descending order of slope, expressed by . The X coordinate of 851 is 804. .. Side 805 has the starting point.
同じX座標を持っているので、傾きの小さい順である。Since they have the same X coordinate, they are ordered in descending order of slope.
804,805の順に並べる。Arrange in the order of 804 and 805.
そして、左側にある辺を左辺、右側にある辺を右辺とす
る。804が左辺、805が右辺になる。Then, let the side on the left side be the left side, and the side on the right side be the right side. 804 is the left side, and 805 is the right side.
(ステップ23)
ステップ24では、塗りつぶし範囲決定回路のリセット
端子にリセット信号を送り2回路をリセットする。(Step 23) In step 24, a reset signal is sent to the reset terminal of the filling range determining circuit to reset the two circuits.
ステップ25では、塗りつぶしデータ計算部で計算され
た。 errl 、 cll 、 c21 、 m
ll 、 m12と。In step 25, the filling data calculation unit calculates the data. errl, cll, c21, m
ll, m12 and.
左辺の始点のX座標と、終点のX座標(以下、X5EN
Dと云う)と、左辺のdeltayを127から引いた
値(以下、ENDYIと云う)と、左辺の傾きが表され
ているdeltaxの符号ビット (以下、 s 5
lopelと云う)と、 errr 、 clr
、 c2r 、 mrl 、 mr2と、右辺の始点の
X座標と、終点のX座標(以下、XeENDと云う)と
右辺のdeltayを127から引いた値(以下、 E
ND Yrと云う)と、右辺の傾きが表されているde
ltaxの符号ビット(以下、 s 5loperと
云う)と、カレントのX座標と、左辺と右辺の終点のX
座標のうち。The X coordinate of the starting point on the left side and the X coordinate of the ending point (hereinafter, X5EN
D), the value obtained by subtracting delt on the left side from 127 (hereinafter referred to as ENDYI), and the sign bit of deltax that represents the slope of the left side (hereinafter referred to as s 5
lopel), errr, clr
, c2r, mrl, mr2, the X coordinate of the starting point on the right side, the X coordinate of the ending point (hereinafter referred to as XeEND), and the value obtained by subtracting the deltay on the right side from 127 (hereinafter referred to as E
ND Yr) and de where the slope of the right side is expressed.
The sign bit of ltax (hereinafter referred to as s5loper), the current X coordinate, and the end point X of the left and right sides.
Of the coordinates.
小さい方の値(以下、Yendと云う)に1を加えてカ
レントのX座標を引いた値を、塗りつぶし範囲決定回路
にセットし、ロード信号を送る。このことについて第1
3図に示すフローチャートと第17図と第18図と第1
9図と第20図に示す回路図に従って、詳しく説明する
。A value obtained by adding 1 to the smaller value (hereinafter referred to as "Yend") and subtracting the current X coordinate is set in the filling range determining circuit, and a load signal is sent. Regarding this, the first
The flowchart shown in Fig. 3, Fig. 17, Fig. 18, and Fig. 1
This will be explained in detail with reference to the circuit diagrams shown in FIGS. 9 and 20.
第17図は、左辺上にあるビットを表す座標を求める回
路である。ステップ20で送る初期化信号は、216の
INITIAL端子に加えられる。この信号は、217
のオアゲートを通って、221と。FIG. 17 shows a circuit for determining the coordinates representing the bits on the left side. The initialization signal sent in step 20 is applied to the INITIAL terminal of 216. This signal is 217
221 through the or gate.
227と、238を除く、各フリップフロップ。Each flip-flop except 227 and 238.
及び、ラッチのCLR端子に加えられる。これによって
2回路が初期化される。and is applied to the CLR terminal of the latch. This initializes the two circuits.
ステップ25で行われる各データのセットについて、左
辺と右辺各々について説明する。The left side and the right side of each data set performed in step 25 will be explained.
まず、左辺について説明すると、第17図の。First, the left side of FIG. 17 will be explained.
201の端子にs 5lopelを、202の端子に
errlを、204の端子にallを、205の端子に
c21を、207の端子にXs endを。Put s 5lopel on the 201 terminal, errl on the 202 terminal, all on the 204 terminal, c21 on the 205 terminal, and Xs end on the 207 terminal.
208の端子にmllを、209の端子に而2を、21
0の端子にXsを、211の端子にEND Ylを送
る。201の端子は、221,222のラッチと接続さ
れている。221と222は非同期のラッチであり、C
LR信号が入力されるか、あるいは、新たなデータが入
力されるまでは、データを保持している。202,20
4,205,207゜208.209,210の端子は
、各々、227゜218.219,220,232,2
34,238゜のラッチと接続されている。 22
7,218゜219.220,232,234,238
は非同期のラッチであり、CLR信号が入力されるか。mll to the 208 terminal, 2 to the 209 terminal, 21
Send Xs to the 0 terminal and END Yl to the 211 terminal. The terminal 201 is connected to latches 221 and 222. 221 and 222 are asynchronous latches, and C
The data is held until the LR signal is input or new data is input. 202,20
Terminals 4, 205, 207° 208, 209, 210 are 227° 218.219, 220, 232, 2, respectively.
It is connected to a 34,238° latch. 22
7,218°219.220,232,234,238
Is it an asynchronous latch and receives the CLR signal?
あるいは、新たなデータが入力されるまでは、データを
保持している。211の端子は、247のデータ保持機
能を持ったカウンタに接続されている。247のカウン
タは、入力されたデータを一旦記憶しておいて、ロード
信号(以下、LDという)が入力されたときに、入力さ
れたデータに従ったカウントを開始する。Alternatively, the data is held until new data is input. The terminal 211 is connected to a counter 247 having a data holding function. The counter of 247 temporarily stores input data and starts counting according to the input data when a load signal (hereinafter referred to as LD) is input.
次に、右辺について説明すると、第18図の。Next, the right side of FIG. 18 will be explained.
251の端子にs 5loperを、252の端子に
errrを、254の端子にclrを、255の端子に
c2rを、257の端子にXe endを、258の端
子にmrlを、259の端子にmr2を、260の端子
にXeを、261の端子にEND Yrを送る。s 5loper to the 251 terminal, errr to the 252 terminal, clr to the 254 terminal, c2r to the 255 terminal, Xe end to the 257 terminal, mrl to the 258 terminal, mr2 to the 259 terminal. , sends Xe to the terminal 260, and sends END Yr to the terminal 261.
251の端子は、271,272のラッチと接続されて
いる。271と272は非同期のラッチであり、CLR
信号が入力されるか、あるいは、新たなデータが入力さ
れるまでは、データを保持している。252,254,
255,257,258゜259.260の端子は、各
々、277.269゜270.293,282,284
,288.のラッチと接続されている。277.269
,270゜293.282,284,288は非同期の
ラッチであり、CLR信号が入力されるか、あるいは。The terminal 251 is connected to latches 271 and 272. 271 and 272 are asynchronous latches, and CLR
Data is held until a signal is input or new data is input. 252, 254,
255, 257, 258° 259.260 terminals are 277.269° 270.293, 282, 284, respectively.
, 288. connected with the latch. 277.269
, 270° 293, 282, 284, and 288 are asynchronous latches to which the CLR signal is input, or.
新たなデータが入力されるまでは、データを保持してい
る。261の端子は、297のデータ保持機能を持った
カウンタに接続されている。297のカウンタは、入力
されたデータを一旦記憶しておいて、LDが入力された
ときに、入力されたデータに従ったカウントを開始する
。The data is retained until new data is input. The terminal of 261 is connected to a counter of 297 having a data holding function. The counter 297 temporarily stores the input data and starts counting according to the input data when the LD is input.
さらに、第19図の922の端子に。Furthermore, to the terminal 922 in FIG.
Yend+1−current y
をセットする。この値は、塗りつぶしを行うy座標の範
囲を示す、922の端子は、926のカウンタに接続さ
れている。926のカウンタは、第18図の297のカ
ウンタと同様の機能を持つ。Set Yend+1-current y. This value indicates the y-coordinate range to be filled in. A terminal 922 is connected to a counter 926. The counter 926 has the same function as the counter 297 in FIG.
そして、第20図の951の端子にcurrent y
をセットする。951の端子は955のラッチに接続さ
れている。955のラッチは第18図の288のラッチ
と同様な機能を持つ。Then, connect the current y to the terminal 951 in Figure 20.
Set. The terminal of 951 is connected to the latch of 955. The latch 955 has a similar function to the latch 288 in FIG.
このようにして、塗りつぶし範囲決定回路にデータをセ
ットした後、CPUはこれらのデータを0にして、ステ
ップ26へ行く、ステップ26では、現在の処理が最初
の辺の処理であるか判断する。第8図に於いては、80
4と805の辺の処理が最初の辺の処理である。ステッ
プ26で最初の辺の処理と判断された場合、ステップ2
7へ行き、塗りつぶし範囲決定回路に、 INIT L
OAD信号とLOAD信号を送る。そうでない場合、ス
テップ28へいき、 LOAD信号を塗りつぶし範囲決
定回路に送る。塗りつぶし範囲決定回路は、 LOAI
)信号を受けると、CPUに対してホルト信号を出し、
塗りつぶし処理が一段落するまで、CPUの動作を一旦
停止させる。After setting the data in the filling range determination circuit in this manner, the CPU sets these data to 0 and proceeds to step 26. In step 26, it is determined whether the current processing is processing of the first side. In Figure 8, 80
The processing of edges 4 and 805 is the processing of the first edge. If it is determined in step 26 that the first edge is to be processed, step 2
Go to 7 and enter INIT L in the filling range determination circuit.
Send OAD signal and LOAD signal. If not, go to step 28 and send a LOAD signal to the fill range determining circuit. The filling range determining circuit is LOAI
) signal, sends a halt signal to the CPU,
The CPU operation is temporarily stopped until the filling process is completed.
ここで、塗りつぶし範囲決定回路の動作について、第1
2図に示したフローチャートと、第17図と第18図と
第19図と第20図に示した回路図に従って、詳細に説
明する。Here, regarding the operation of the filling range determining circuit, the first
This will be explained in detail with reference to the flowchart shown in FIG. 2 and the circuit diagrams shown in FIGS. 17, 18, 19, and 20.
まず、第17図に示した回路図の、全体の機能について
説明する。First, the overall function of the circuit diagram shown in FIG. 17 will be explained.
第17図は左辺上の座標点を求める回路図である。20
2の端子に与えられたerrlは227のラッチに一旦
記憶され、228のオアゲートを通じて、229のフリ
ップフロップに送られる。FIG. 17 is a circuit diagram for determining coordinate points on the left side. 20
errl applied to the terminal 2 is temporarily stored in the latch 227 and sent to the flip-flop 229 through the OR gate 228.
尚、227のラッチは、errlを229のフリップフ
ロップに送った後、203の端子に加えられるclea
r信号によってリセットされる。このことについては後
述する。229のフリップフロップに加えられ、206
の端子に加えられているクロックによって、サンプリン
グされたerrlは230の加算器に加えられ、all
、あるいは。In addition, the latch 227 sends errl to the flip-flop 229, and then clear is applied to the terminal 203.
It is reset by the r signal. This will be discussed later. Added to 229 flip-flops, 206
The sampled errl is added to the adder of 230 by the clock applied to the terminal of all
,or.
c21との和が求められる。The sum with c21 is calculated.
ellとc21は、各々、204,205の端子に加え
られ、各々、218,219のラッチに一旦記憶される
。そして、223,224のセレクタに送られ、err
lが正の時にcllをerr 1に加えてerrlが負
の時にc21を加えるか。ell and c21 are applied to terminals 204 and 205, respectively, and temporarily stored in latches 218 and 219, respectively. Then, it is sent to selectors 223 and 224, and err
Should cll be added to err 1 when l is positive, and c21 be added when errl is negative?
あるいは、errlが正の時にc21を加えて負の時に
cllを加えるかを、201の端子に加えられ、222
のラッチを経て223,224のセレクタのSEL端子
に加えられるs 5lopelの値によって2選択され
る。さらに、225のセレクタに送られ、ここで、er
rlの符号ビットによって、ellを出力するか、c2
1を出力するか選択されて、226のフリップフロップ
に送られる。Alternatively, whether to add c21 when errl is positive and add cll when errl is negative can be added to the terminal of 201 and 222
2 is selected by the value of s5lopel applied to the SEL terminals of selectors 223 and 224 through the latch. Furthermore, it is sent to the selector of 225, where er
Depending on the sign bit of rl, output ell or c2
It is selected whether to output 1 and sent to 226 flip-flops.
ここで、クロックでサンプリングされた後、230の加
算器に送られる。Here, after being sampled with a clock, it is sent to an adder at 230.
230の加算器で、errlと、all、あるいは、c
21の和を計算したら、その計算結果は231のフリッ
プフロップを通って228のオアゲートを通じて229
のフリップフロップに戻って、計算を繰り返す。230 adders, errl, all, or c
After calculating the sum of 21, the calculation result passes through the flip-flop of 231 and passes through the OR gate of 228 to 229.
Go back to the flip-flop and repeat the calculation.
210の端子に加えられたXSは、238のラッチに一
旦記憶され、239のオアゲートを通って240のフリ
ップフロップに送られる。240のフリップフロップで
は、クロックでサンプリングされて、241の加算器に
加えられる、ここでは、左辺の傾き、あるいは、err
lの値によって9m11またはm12との和が求められ
る。The XS applied to the terminal 210 is temporarily stored in the latch 238 and sent to the flip-flop 240 through the OR gate 239. In the flip-flop 240, the slope of the left side, or err
The sum with 9m11 or m12 is determined depending on the value of l.
m 11とm12は、各々、208,209の端子に加
えられ、各々、232,234のラッチに一旦記憶され
る。そして、233,235のセレクタに送られ、er
rlが正の時にmllをXSに加えてerrlが負の時
にm12を加えるか、あるいは、errlが正の時にm
L2を加えて負の時にmllを加えるかを、201の端
子に加えられ。m11 and m12 are applied to terminals 208 and 209, respectively, and temporarily stored in latches 232 and 234, respectively. Then, it is sent to selectors 233 and 235, and er
Add mll to XS when rl is positive and add m12 when errl is negative, or m when errl is positive.
Add L2 and add mll when it is negative to the 201 terminal.
222のラッチを経て233,235のセレクタのSE
L端子に加えられるs 5lopelの値によって。SE of selector 233, 235 via latch 222
By the value of s5lopel applied to the L terminal.
選択される。さらに、236のセレクタに送られ。selected. Furthermore, it is sent to the selector of 236.
ここで、errlの符号ビットによって、mllを出力
するか、m12を出力するか選択されて。Here, the sign bit of errl selects whether to output mll or m12.
237のフリップフロップに送られる。ここで。237 flip-flops. here.
クロックでサンプリングされた後、241の加算器に送
られる。After being sampled by the clock, it is sent to a 241 adder.
241の加算器で、xsと、mll、あるいは。241 adder, xs, mll, or.
m12の和を計算したら、その計算結果は246のフリ
ップフロップと、242のセレクタに送られる。246
のフリップフロップの出力は、228のオアゲートに送
られ、229のフリップフロップに戻って、計算を繰り
返す。After calculating the sum of m12, the calculation result is sent to 246 flip-flops and 242 selectors. 246
The output of the flip-flop is sent to the OR gate 228 and returns to the flip-flop 229 to repeat the calculation.
242のセレクタでは、左辺の終点のX座標であるXs
ENDとXSとの選択が行われる。これは、左辺の
終点のX座標の補正のためである。In the selector of 242, Xs which is the X coordinate of the end point of the left side
A selection is made between END and XS. This is to correct the X coordinate of the end point on the left side.
左辺の終点は、247のカウンタが検出する。このこと
については後述する。The end point of the left side is detected by the counter 247. This will be discussed later.
242のセレクタの出力は、245のフリップフロップ
に入力され、クロックでサンプリングされた後、215
の出力端子から用紙転写装置に送られる。The output of the selector 242 is input to the flip-flop 245, and after being sampled with the clock, the output of the selector 215
is sent to the paper transfer device from the output terminal of.
尚、247のカウンタはEND Ylからカウントを
開始し、出力がすべて1になるとりプルキャリを出力す
るが、247のカウンタのリプルキャリ出力によって、
LOAD信号と、リセット信号を、各々、249,25
0のアンドゲートでゲートしている。このため、247
のカウンタのリプルキャリ信号が出ていない、即ち、1
本の左辺の処理が終了するまでは、LO,AD倍信号リ
セット信号も受は付けないようになっている。また。Note that the counter 247 starts counting from END Yl, and when all outputs become 1, it outputs a pull carry, but due to the ripple carry output of the counter 247,
The LOAD signal and reset signal are 249 and 25, respectively.
It is gated with an AND gate of 0. For this reason, 247
The ripple carry signal of the counter is not output, that is, 1
The LO and AD double signal reset signals are not accepted until the processing of the left side of the book is completed. Also.
clear信号も、同様に991のアンドゲートでゲー
トされている。The clear signal is also gated with a 991 AND gate.
第18図は右辺上の座標点を求める回路図である。25
2の端子に与えられたerrrは277のラッチに一旦
記憶され、278のオアゲートを通じて、279のフリ
ップフロップに送られる。FIG. 18 is a circuit diagram for determining coordinate points on the right side. 25
errr applied to the terminal 2 is temporarily stored in the latch 277 and sent to the flip-flop 279 through the OR gate 278.
尚、277のラッチは、errrを279のフリップフ
ロップに送った後、253の端子に加えられるclea
r信号によってリセットされる。このことについては後
述する。279のフリップフロップに加えられ、256
の端子に加えられているクロックによって、サンプリン
グされたerrrは280の加算器に加えられ、clr
、あるいは。In addition, the latch 277 sends errr to the flip-flop 279, and then clear is applied to the terminal 253.
It is reset by the r signal. This will be discussed later. Added to 279 flip-flops, 256
With the clock being applied to the terminal of clr, the sampled errr is added to the adder of 280 and clr
,or.
c2rとの和が求められる。The sum with c2r is calculated.
clrとc2rは、各々、254,255の端子に加え
られ、各々、269,270のラッチに一旦記憶される
。そして、273,274のセレクタに送られ、err
rが正の時にclrをerrrに加えてerrrが負の
時にc2rを加えるか。clr and c2r are applied to terminals 254 and 255, respectively, and temporarily stored in latches 269 and 270, respectively. Then, it is sent to selectors 273 and 274, and err
Should clr be added to errr when r is positive, and c2r be added when errr is negative?
あるいは、errrが正の時にc2rを加えて負の時に
clrを加えるかを、251の端子に加えられ、272
のラッチを経て273,274のセレクタのSEL端子
に加えられるs 5loperの値によって2選択され
る。さらに、275のセレクタに送られ、ここで、er
rrの符号ビットによって、clrを出力するか、c2
rを出力するか選択されて、276のフリップフロップ
に送られる。Alternatively, whether to add c2r when errr is positive and add clr when errr is negative can be added to the terminal of 251 and 272
2 is selected by the value of s5loper applied to the SEL terminals of selectors 273 and 274 through latches. Furthermore, it is sent to the selector of 275, where er
Depending on the sign bit of rr, output clr or output c2
It is selected whether to output r and sends it to 276 flip-flops.
ここで、クロックでサンプリングされた後、280の加
算器に送られる。Here, after being sampled with a clock, it is sent to a 280 adder.
280の加算器で、errrと、clr、あるいは、c
2rの和を計算したら、その計算結果は281のフリッ
プフロップを通って278のオアゲートを通じて279
のフリップフロップに戻って、計算を繰り返す。280 adder, errr, clr, or c
After calculating the sum of 2r, the calculation result passes through the flip-flop of 281 and passes through the OR gate of 278 to 279.
Go back to the flip-flop and repeat the calculation.
260の端子に加えられたxeは、288のラッチに一
旦記憶され、289のオアゲートを通って290のフリ
ップフロップに送られる。290のフリップフロップで
は、クロックでサンプリングされて、291の加算器に
加えられる。ここでは、右辺の傾き、あるいは、err
rの値によって、mrlまたはmr2との和が求められ
る。The xe applied to the terminal of 260 is temporarily stored in the latch of 288, and sent to the flip-flop of 290 through the OR gate of 289. In the flip-flop 290, it is sampled by the clock and added to the adder 291. Here, the slope of the right side or err
Depending on the value of r, the sum with mrl or mr2 is determined.
mrlとm r 2は、各々、258,259の端子に
加えられ、各々、282,284のラッチに一旦記憶さ
れる。そして、283,285のセレクタに送られ、e
rrrが正の時にmrlをxeに加えてerrrが負の
時にmr2を加えるか、あるいは、errrが正の時に
mr2を加えて負の時にmrlを加えるかを、251の
端子に加えられ。mrl and m r 2 are applied to terminals 258 and 259, respectively, and temporarily stored in latches 282 and 284, respectively. Then, it is sent to selectors 283 and 285, and e
Add mrl to xe when rrr is positive and mr2 when errr is negative, or add mr2 when errr is positive and mrl when it is negative, to the terminal of 251.
272のラッチを経て283,285のセレクタのSE
L端子に加えられるs 5loperの値によって。SE of selector 283, 285 via latch 272
By the value of s 5loper applied to the L terminal.
選択される。さらに、286のセレクタに送られ。selected. Furthermore, it is sent to the 286 selector.
ここで、errrの符号ビットによって、mrlを出力
するか、mr2を出力するか選択されて。Here, depending on the sign bit of errr, it is selected whether to output mrl or mr2.
287のフリップフロップに送られる。ここで。287 flip-flop. here.
クロックでサンプリングされた後、291の加算器に送
られる。After being sampled by the clock, it is sent to the adder 291.
291の加算器で、xeと、mrl、あるいは。291 adder, xe, mrl, or.
mr2の和を計算したら、その計算結果は296のフリ
ップフロップと、292のセレクタに送られる。296
のフリップフロップの出力は289のオアゲートに送ら
れ、290のフリップフロップに戻って、計算を繰り返
す。After calculating the sum of mr2, the calculation result is sent to flip-flop 296 and selector 292. 296
The output of the flip-flop is sent to the OR gate 289 and returns to the flip-flop 290 to repeat the calculation.
292のセレクタでは、右辺の終点のX座標であるXe
ENDとxeとの選択が行われる。これは、右辺の
終点のX座標の補正のためである。In the selector of 292, Xe which is the X coordinate of the end point of the right side
A selection is made between END and xe. This is to correct the X coordinate of the end point on the right side.
右辺の終点は、297のカウンタが検出する。このこと
については後述する。The end point of the right side is detected by the counter 297. This will be discussed later.
292のセレクタの出力は、295のフリップフロップ
に入力され、クロックでサンプリングされた後、266
の出力端子から用紙転写装置に送られる。The output of the selector 292 is input to the flip-flop 295, and after being sampled by the clock, the output of the selector 292 is
is sent to the paper transfer device from the output terminal of.
尚、297のカウンタはEND Yrからカウントを
開始し、出力がすべてlになるとりプルキャリを出力す
るが、297のカウンタのリプルキャリ出力によって、
LOAD信号と、リセット信号を、各々、299,26
5のアンドゲートでゲートしている。このため、297
のカウンタのリプルキャリ信号が出ていない、即ち、1
本の右辺の処理が終了するまでは、LOAD信号もリセ
ット信号も受は付けないようになっている。また。Note that the counter 297 starts counting from END Yr and outputs a pull carry when all outputs become 1, but due to the ripple carry output of the counter 297,
The LOAD signal and reset signal are 299 and 26, respectively.
It is gated with an AND gate of 5. For this reason, 297
The ripple carry signal of the counter is not output, that is, 1
Neither the LOAD signal nor the reset signal is accepted until the processing of the right side of the book is completed. Also.
clear信号も同様に992のアンドゲートでゲート
されている。The clear signal is similarly gated with a 992 AND gate.
第17図と第18図に示した回路は共にクロックに同期
して動作する。そのためのクロックを制御する回路が第
19図に示した回路である。The circuits shown in FIGS. 17 and 18 both operate in synchronization with a clock. The circuit for controlling the clock for this purpose is the circuit shown in FIG.
921はLOAD信号を入力する端子、922はYen
d+1−current yを入力する端子、923
はMASTERCLOCKを入力する端子、924はリ
セット端子である。ここで。921 is a terminal for inputting the LOAD signal, 922 is a Yen
d+1-current y input terminal, 923
is a terminal for inputting MASTER CLOCK, and 924 is a reset terminal. here.
MASTERCLOCKとは、クロックを発生するため
の矩形波発振回路の出力である。 LOAD信号は、ス
テップ27.あるいは、ステップ28で送られる信号で
ある。 Yend+1−current yは、ステ
ップ25でセットされるデータである。リセット信号は
、ステップ24で送られる信号である。MASTERCLOCK is the output of a rectangular wave oscillation circuit for generating a clock. The LOAD signal is output in step 27. Alternatively, it is the signal sent in step 28. Yend+1-current y is data set in step 25. The reset signal is the signal sent in step 24.
926のカウンタは、LOAD信号が送られると、
Yend+1−Current−yからクロックをカウ
ントし。When the LOAD signal is sent to the 926 counter,
Count the clock from Yend+1-Current-y.
出力がすべてlになったらリプルキャリを出力する。リ
プルキャリは926のENABLE端子に入力されてお
り、リプルキャリが出力されるとカウンタは動作を停止
する。When all outputs become l, a ripple carry is output. The ripple carry is input to the ENABLE terminal of 926, and when the ripple carry is output, the counter stops operating.
また、リプルキャリは938のオアゲートを通って、9
27のインバータで反転されて、929のフリップフロ
ップに入力される。929のフリップフロップでは、M
ASTERCLOCKを928のインバータで反転した
クロックで、入力信号をサンプリングしている。929
のフリップフロップの非反転出力は、930のアンドゲ
ートでMASTERCLOCKとのアンドをとって。Also, ripple carry passes through the or gate of 938, and
It is inverted by 27 inverters and input to 929 flip-flops. In the 929 flip-flop, M
The input signal is sampled using a clock obtained by inverting ASTERCLOCK using a 928 inverter. 929
The non-inverted output of the flip-flop is ANDed with MASTERCLOCK by the AND gate of 930.
931の出力端子から、CLOCKとして出力される。It is output from the output terminal of 931 as CLOCK.
このCLOCKが各回路ブロックに入力されている。こ
のようにMASTERCLOCKを、リプルキャリでゲ
ートしているため、各回路は、 (Yend+1−c
urrent y )クロックの間しか動作しない、さ
らに、929のフリップフロップの反転出力はそのまま
、HALT信号としてCPUに送られる。この信号がア
クティブの間、CPUは動作を停止している。つまり、
CPUが動作を停止している間、塗りつぶし範囲決定回
路は動作し。This CLOCK is input to each circuit block. In this way, since MASTERCLOCK is gated by ripple carry, each circuit is (Yend+1-c
The inverted output of the flip-flop 929 is sent as is to the CPU as a HALT signal. While this signal is active, the CPU is not operating. In other words,
While the CPU is not operating, the filling range determining circuit is operating.
CPUが動作している間、塗りつぶし範囲決定回路は動
作を停止している。このようにしてCPUとの同期をと
っている。While the CPU is operating, the filling range determining circuit is not operating. In this way, synchronization with the CPU is achieved.
以上のようにして、XSとxeが求められるが。In the above manner, XS and xe can be obtained.
この他に、y座標の値も求めなければならない。In addition to this, the value of the y coordinate must also be determined.
この、y座標を求める回路が第20図に示した回路であ
る。The circuit for calculating this y-coordinate is the circuit shown in FIG.
951には、 current yがセットされ、そ
して。In 951, current y is set, and.
955のラッチに一時記憶される。955のラッチの出
力は、956のフリップフロップに送られる。956の
フリップフロップはCLOCKが人力されないとデータ
を出力しないため、 CLOCKが入力されるまで、加
算器にデータが送られることはない、952には、LO
AD信号が加えられる。It is temporarily stored in the latch of 955. The output of latch 955 is sent to flip-flop 956. Since the flip-flop of 956 does not output data unless CLOCK is input manually, no data is sent to the adder until CLOCK is input.
An AD signal is added.
LOAD信号は、959のカウンタに伝えられ。The LOAD signal is transmitted to the 959 counter.
LOAD信号が入力されると、959のカウンタは、デ
ータを内部に取り込む、このデータはOである。953
はCLOCKが人力される端子である。ここに入力され
るCLOCKは第19図の回路で制御されたCLOCK
である。従って1回路が動作するときしかCLOCKは
入力されない、954はリセット端子である。When the LOAD signal is input, the counter 959 takes in data, and this data is O. 953
is a terminal to which CLOCK is input manually. The CLOCK input here is the CLOCK controlled by the circuit in Figure 19.
It is. Therefore, CLOCK is input only when one circuit is operating, and 954 is a reset terminal.
955のラッチに記憶されたcurrent yは95
6のフリップフロップに送られ、CLOCKが入力され
ると、957の加算器に送られる。959のカウンタの
出力は、960のフリップフロップに加えられ、960
のフリップフロップの出力は。The current y stored in the latch of 955 is 95.
It is sent to the flip-flop No. 6, and when CLOCK is input, it is sent to the adder No. 957. The output of the counter at 959 is added to the flip-flop at 960, and the output from the counter at 960 is
The output of the flip-flop is .
957の加算器に送られる。957の加算器で。957 adder. With 957 adders.
current yとカウンタの出力との和が計算さ
れ、961の端子からyの値が出力される。The sum of current y and the output of the counter is calculated, and the value of y is output from the terminal 961.
なお、current yが人力されてから出力され
るまでの回路構成は、XSあるいはxeを計算する回路
と同様な構成になっている。従って。Note that the circuit configuration from when current y is manually input until it is output is similar to the circuit for calculating XS or xe. Therefore.
各出力端子に於けるデータ間の同期がとれている。Data at each output terminal is synchronized.
次に、塗りつぶし範囲決定回路の動作について。Next, let's talk about the operation of the filling range determining circuit.
第12図と第13図と第14図と第15図に示したフロ
ーチャートと、第8図に示した概念図と。The flowcharts shown in FIGS. 12, 13, 14, and 15, and the conceptual diagram shown in FIG. 8.
第17図と第18図と第19図と第20図に示した回路
図に従って、詳細に説明する。This will be explained in detail with reference to the circuit diagrams shown in FIGS. 17, 18, 19, and 20.
ステップ31では、新規の辺があった場合、その始点の
補正を行う、このことを、第14図に示すフローチャー
トに従って、詳しく説明する。In step 31, if there is a new side, its starting point is corrected. This will be explained in detail with reference to the flowchart shown in FIG.
ステップ51では、左辺が新規の辺であるか判断する。In step 51, it is determined whether the left side is a new side.
ここで、新規の辺とは、その辺の始点のy座標がカレン
トのy座標である辺である。第8図では、804が新規
の左辺である。新規の辺で有ればステップ52へ行き、
そうでなければステップ56へ行<、第17図の回路に
於いて、この判断は、247のカウンタのリプルキャリ
出力と。Here, a new side is a side whose starting point's y-coordinate is the current y-coordinate. In FIG. 8, 804 is the new left side. If it is a new edge, go to step 52,
If not, go to step 56<, In the circuit of FIG. 17, this judgment is the ripple carry output of the counter 247.
INITIAL信号と、INIT LOAD信号によ
って行う、 INITIAL信号、あるいは、INIT
LOAD信号が入力されたときは、最初の辺の処理で
あるから、左辺は新規の辺であると判断される。また。INITIAL signal or INIT performed by INITIAL signal and INIT LOAD signal
When the LOAD signal is input, since the first side is being processed, the left side is determined to be a new side. Also.
LOAD信号が入力された直後に新規の辺の処理を行う
、しかし、リプルキャリ信号が出力されていないときは
、まだ、1本の左辺の処理を終了していないから、LO
AD信号、CLEAR信号。Immediately after the LOAD signal is input, a new edge is processed. However, if the ripple carry signal is not output, processing of one left edge has not yet been completed, so the LOAD signal is input.
AD signal, CLEAR signal.
RESET信号を受は付けない、従って、新規の辺の処
理は行わない。It does not accept the RESET signal, so no new edges are processed.
ステップ52では、左辺の傾きが正かどうか調べる。傾
きが正ならばステップ56へ行く、そうでなければ、ス
テップ53へ行<、804の辺の傾きは負であるので、
ステップ53へ行く、第17図に於いては、221のラ
ッチの出力によって。In step 52, it is checked whether the slope of the left side is positive. If the slope is positive, go to step 56; otherwise, go to step 53. Since the slope of the side 804 is negative,
Go to step 53, in FIG. 17, by the output of the latch 221.
226のフリップフロップと237のフリップフロップ
にCLR信号を入力することによって実現する。即ち、
傾きが正の場合、傾きの符号ビットであるs 5lop
elは0であるから2221のラッチの反転出力は1で
ある。従って、226,237のフリップフロップはク
リアされ、0が出力される。This is realized by inputting the CLR signal to the flip-flops 226 and 237. That is,
If the slope is positive, the sign bit of the slope, s 5lop
Since el is 0, the inverted output of the latch 2221 is 1. Therefore, flip-flops 226 and 237 are cleared and 0 is output.
故に230,241の加算器では、各々err 1とX
SにOが加えられる。これによって、ステップ52から
ステップ56へ行ぐルートが実現される。Therefore, for 230 and 241 adders, err 1 and X
O is added to S. This implements the route from step 52 to step 56.
ステップ53では、 errlが正であるか調べる。In step 53, it is checked whether errl is positive.
errlが正ならば、ステップ54へ行き、そうでなけ
ればステップ55へ行く、ステップ54゜ステップ55
では前述したように、各々、 errlの修正とxs
の決定を行う、804の辺のerr 1は、第8図の8
31に示すように、正であるからステップ54へ行く、
ここで、errlを補正し。If errl is positive, go to step 54, otherwise go to step 55, step 54゜step 55
Then, as mentioned above, fix errl and xs
err 1 on side 804 is 8 in FIG.
As shown in 31, since it is positive, go to step 54.
Here, correct errl.
832で示すerrlを求める。また、xsは804の
辺の始点のX座標となる。 (ステップ54)ステップ
53.ステップ54.ステップ55の機能の実現方法に
ついては後述する。errl indicated by 832 is obtained. Moreover, xs is the X coordinate of the starting point of the side 804. (Step 54) Step 53. Step 54. A method for realizing the function of step 55 will be described later.
ステップ56では、右辺が新規の辺であるか調べる。右
辺が新規の辺で有れば、ステップ57へ行き、そうでな
ければステップ61へ行<、第18図の回路に於いて、
この判断は、297のカウンタのリプルキャリ出力と、
INITIAL信号と。In step 56, it is determined whether the right side is a new side. If the right side is a new side, go to step 57, otherwise go to step 61<, In the circuit of FIG.
This judgment is based on the ripple carry output of the counter 297,
INITIAL signal.
INIT LOAD信号によって行う、 INITI
AL信号、あるいは、INIT LOAD信号が入力さ
れたときは。INITI performed by INIT LOAD signal
When the AL signal or INIT LOAD signal is input.
最初の辺の処理であるから、右辺は新規の辺であると判
断される。また、LOAD信号が入力された直後に新規
の辺の処理を行う、しかし、リプルキャリ信号が出力さ
れていないときは、まだ、1本の右辺の処理を終了して
いないから、LOAD信号、CLEAR信号、RESE
T信号を受は付けない、従って、新規の辺の処理は行わ
ない。Since this is the first side to be processed, the right side is determined to be a new side. Also, immediately after the LOAD signal is input, a new side is processed.However, if the ripple carry signal is not output, the processing of one right side has not yet been completed, so the LOAD signal, CLEAR signal , RESE
The T signal is not accepted, so no new edge processing is performed.
ステップ57では、右辺の傾きが正であるが調べる。右
辺の傾きが正であるならばステップ58へ行き、そうで
なければ、ステップ59へ行く。In step 57, it is checked whether the slope of the right side is positive. If the slope of the right side is positive, the process goes to step 58; otherwise, the process goes to step 59.
805で示される右辺の傾きは正であるので、ステップ
58へ行く、第18図に於いては、271のラッチの出
力によって、276のフリップフロップと287のフリ
ップフロップにCLR信号を入力することによって実現
する。即ち、傾きが負の場合、傾きの符号ビットである
s 5loperは1であるから、271のラッチの非
反転出力には1が出力される。従って、276.287
のフリップフロップはクリアされOが出力される。故に
、280゜291の加算器では、各々、errrとxe
にOが加えられる。これによって、ステップ57からス
テップ61へ行くルートが実現される。Since the slope of the right side indicated by 805 is positive, the process goes to step 58. In FIG. Realize. That is, when the slope is negative, the sign bit of the slope, s5loper, is 1, so 1 is output to the non-inverting output of the latch 271. Therefore, 276.287
The flip-flop is cleared and O is output. Therefore, in the 280°291 adder, errr and xe
O is added to. This implements the route from step 57 to step 61.
ステップ58では、errrが正であるか調べる。er
rrが正ならばステップ60へ行き、そうでなければ、
ステップ59へ行く。In step 58, it is checked whether errr is positive. er
If rr is positive, go to step 60; otherwise,
Go to step 59.
ステップ59.ステップ60では、前述したように、そ
れぞれerrrの修正とxeの決定を行う、821で示
される。805の右辺のerrrはOなので、ステップ
59へ行き、821のemにclrを加えることにより
、822のerrrを求める。xeは805の辺の始点
になる。ステップ58.ステップ59.ステップ60の
機能の実現方法については後述する。Step 59. In step 60, as described above, errr is corrected and xe is determined, as indicated by 821. Since errr on the right side of 805 is O, go to step 59 and add clr to em of 821 to find errr of 822. xe becomes the starting point of side 805. Step 58. Step 59. A method for implementing the function of step 60 will be described later.
ステップ61では、第17図で求まったXsと。In step 61, the Xs obtained in FIG.
第18図で求まったXeと、第20図で求まったyの値
を用紙転写装置に送る。この値を基にして。The values of Xe determined in FIG. 18 and y determined in FIG. 20 are sent to the paper transfer device. Based on this value.
用紙転写装置は、851のX座標に於て、 xsとxe
の間のビットをオンにする。第8図に於いては。The paper transfer device has xs and xe at the X coordinate of 851.
Turn on the bits between. In Figure 8.
(845のX座標、851のX座標)と(845のX座
標、851のX座標)の間、即ち、 (845のX座標
、851のX座標)のビットをオンにする。カレントの
X座標は。Turn on the bit between (X coordinate of 845, X coordinate of 851) and (X coordinate of 845, X coordinate of 851), that is, (X coordinate of 845, X coordinate of 851). The current X coordinate is.
959のカウンタが1カウントアツプするので。The counter of 959 increases by 1.
自動的に1増える。なお、ここでは、Yendは854
のX座標である。Automatically increases by 1. In addition, here, Yend is 854
is the X coordinate of
このようにして、新規の辺の補正が終了したら。In this way, once the new side has been corrected.
第13図のフローチャートのステップ32へ行く。Go to step 32 in the flowchart of FIG.
ステップ32では、カレントのX座標(以下。In step 32, the current X coordinate (hereinafter referred to as
yという、)がYendより小さいが調べる。小さけれ
ば、ステップ33へ行き、そうでなければステップ48
へ行く、現在処理を行っているX座標は825のX座標
であるから、ステップ33へ行く、この機能は第19図
に示す回路で実現している。即ち926のカウンタが、
yena+t−current yまでカウントして、
リプルキャリを出力することによって、Yendまで処
理をしたことが解る。y) is smaller than Yend. If it is smaller, go to step 33, otherwise go to step 48
Since the X coordinate currently being processed is the X coordinate of 825, the process goes to step 33. This function is realized by the circuit shown in FIG. That is, the counter of 926 is
Count up to yena+t-current y,
By outputting a ripple carry, it can be seen that processing up to Yend has been completed.
そうすると、リプルキャリ出力によって、 CLOCK
が停止し、塗りつぶし範囲決定回路は動作を停止する。Then, due to ripple carry output, CLOCK
stops, and the filling range determining circuit stops operating.
そして、 HALTが解除されることによって、 CP
Uが動作を開始する。Then, by releasing HALT, CP
U starts working.
ステップ33では、左辺の傾きが正かどうか調べる。正
ならば、ステップ34へ行き、そうでなければ、ステッ
プ35へ行く、現在処理している左辺である804の辺
の傾きは負であるから、ステップ35へ行く。In step 33, it is checked whether the slope of the left side is positive. If it is positive, go to step 34; otherwise, go to step 35. Since the slope of the side 804, which is the left side currently being processed, is negative, go to step 35.
ステップ34.ステップ36.ステップ37は傾きが正
の左辺に対して、前述したビットの選択法の手順を示し
たものである。またステップ35゜ステップ38.ステ
ップ39は傾きが負の左辺に対して、前述したビットの
選択法の手順を示したものである。Step 34. Step 36. Step 37 shows the procedure of the bit selection method described above for the left side with a positive slope. Also, step 35° and step 38. Step 39 shows the procedure of the bit selection method described above for the left side with a negative slope.
ステップ35では、 804の左辺において。In step 35, on the left side of 804.
832で示されるerrlの値を調べると、負であるか
ら、ステップ39へ行く。When the value of errl indicated by 832 is checked, it is negative, so the process goes to step 39.
ステップ39で、832のerrlを833のerrl
になおして、845のX座標にあったxsを、844の
X座標にする。In step 39, errl of 832 is changed to errl of 833.
Then, xs, which was at the X coordinate of 845, is changed to the X coordinate of 844.
ステップ33.ステップ34.ステップ35゜ステップ
36.ステップ37.ステップ38.ステップ39の実
現方法について説明する。ステップ33での判断の違い
で何が異なるか考えると。Step 33. Step 34. Step 35° Step 36. Step 37. Step 38. A method for implementing step 39 will be explained. Thinking about the difference in the judgment made in step 33.
辺の傾きが正か負で、errlとOとの大小判断が逆に
なることである。If the slope of the side is positive or negative, the determination of the magnitude of errl and O is reversed.
第17図では、errlの大小判断は固定し。In FIG. 17, the determination of the size of errl is fixed.
errl、あるいは、XSに加える値を入れ換えること
によって実現している。cll、c21は。This is achieved by replacing the values added to errl or XS. cll, c21.
各々、218,219のラッチを通って223゜224
のセレクタに送られる。223,224゜225のセレ
クタは、SEL端子の入力が0のとき、Aの端子に入力
されたデータを出力Yに送る。223°224 through latches 218 and 219, respectively.
is sent to the selector of The selectors 223, 224 and 225 send the data input to the A terminal to the output Y when the input to the SEL terminal is 0.
辺の傾きが正の時、 s 5lopelはOだから、
223゜224のセレクタはAの端子の入力を出力する
。When the slope of the side is positive, s 5lopel is O, so
The selectors 223 and 224 output the input of the A terminal.
そのため、225のセレクタのAの入力端子にはall
が、Bの入力端子にはc21が送られる。Therefore, the A input terminal of the selector 225 has all
However, c21 is sent to the input terminal of B.
225のセレクタもSELがOのとき、Aを出力し、S
ELが1のときBを出力するから、傾きが正の場合、e
rrlが負でないならば、cllを226のフリップフ
ロップを通じて230の加算器に送り、errlが負の
ならば、c21を同様に加算器に送る。mll、m12
についても全く同じ動作をする。The selector of 225 also outputs A when SEL is O, and outputs S.
Since B is output when EL is 1, if the slope is positive, e
If rrl is non-negative, cll is sent through flip-flops 226 to adder 230, and if errl is negative, c21 is sent to the adder as well. mll, m12
It works exactly the same way.
ステップ40では、右辺の傾きが正であるか調べる。正
ならば、ステップ41へ行き、そうでなければ、ステッ
プ42へ行く、現在処理している右辺である805の辺
の傾きは正であるから、ステップ41へ行く。In step 40, it is checked whether the slope of the right side is positive. If it is positive, go to step 41; otherwise, go to step 42. Since the slope of the right side currently being processed, 805, is positive, go to step 41.
ステップ41.ステップ43.ステップ44は傾きが正
の右辺に対して、前述したビットの選択法の手順を示し
たものである。またステップ42゜ステップ45.ステ
ップ46は傾きが負の右辺に対して、前述したビットの
選択法の手順を示したものである。Step 41. Step 43. Step 44 shows the procedure of the bit selection method described above for the right side with a positive slope. Also, step 42° and step 45. Step 46 shows the procedure of the bit selection method described above for the right side with a negative slope.
ステップ41では、822で示される。805の右辺の
errrの値を調べると、0より犬で有るから、ステッ
プ43へ行く。Step 41 is indicated by 822. When the value of errr on the right side of 805 is checked, it is a dog than 0, so the process goes to step 43.
ステップ43で、822のerrrを823のerrr
になおして、845のX座標にあったxeを、846の
X座標にする。In step 43, 822 errr is changed to 823 errr.
Then, xe, which was at the X coordinate of 845, is changed to the X coordinate of 846.
ステップ40.ステップ41.ステップ42゜ステップ
43.ステップ44.ステップ45.ステップ46の実
現方法については、左辺の場合と全く同様である。Step 40. Step 41. Step 42゜Step 43. Step 44. Step 45. The method for implementing step 46 is exactly the same as the case on the left side.
そして、XSとxeの値とyを用紙転写装置に送る。
(ステップ47)
その後、ステップ32へもどって、カレントのyがYe
ndより小さい間、即ち、247.あるいは、297の
カウンタのリプルキャリが出力されるまで、ステップ3
2からステップ47を繰り返す。Then, the values of XS, xe, and y are sent to the paper transfer device.
(Step 47) After that, return to step 32 and change the current y to Ye.
nd, i.e., 247. Alternatively, until the ripple carry of the counter 297 is output, step 3
Repeat steps 2 to 47.
カレントのyがYendより小さくなくなって。Current y is no longer smaller than Yend.
247、あるいは、297のカウンタのリプルキャリが
出力されたら、ステップ48へ行く、第8図の804と
805の辺に対しては、yが845のX座標になったき
、ステップ48へ行く。When the ripple carry of the counter 247 or 297 is output, the process goes to step 48.For sides 804 and 805 in FIG. 8, when y becomes the X coordinate of 845, the process goes to step 48.
ステップ48では、そのX座標で、処理を終了する辺、
つまり、そのX座標に終点がある辺について、終了点の
補正を行う。In step 48, the side on which processing is to be completed at the X coordinate,
In other words, the end point of the side whose end point is at the X coordinate is corrected.
このことについて、第15図のフローチャートに従って
、説明する。This will be explained according to the flowchart in FIG. 15.
まず、左辺の処理が終了したか調べる。 (ステップ7
1)左辺の処理が終了していないなら、ステップ72へ
行く、ステップ72では通常の処理を行う、ここで言う
通常の処理とは、第13図のフローチャートのステップ
33からステップ29に示す処理と全く同じ処理である
。そして、この通常の処理を行ったら、ステップ77へ
行<、804の左辺の場合、まだ、処理が終了していな
いので。First, check whether processing on the left side has finished. (Step 7
1) If the processing on the left side has not been completed, go to step 72. In step 72, normal processing is performed. The normal processing here refers to the processing shown in steps 33 to 29 in the flowchart of FIG. The process is exactly the same. After performing this normal processing, go to step 77. If the line is <, on the left side of 804, the processing has not yet ended.
ステップ72の通常の処理を行い、XSには、842の
X座標の値を代入する。The normal process of step 72 is performed, and the value of the X coordinate of 842 is substituted for XS.
ステップ71で、左辺の処理が終了したと判断されたら
、ステップ73へ行き、左辺の傾きが正であるか調べる
。左辺の傾きが正ならば、ステップ75へ行き、そうで
なければ、ステップ74へ行く。If it is determined in step 71 that the processing of the left side has been completed, the process proceeds to step 73 to check whether the slope of the left side is positive. If the slope of the left side is positive, the process goes to step 75; otherwise, the process goes to step 74.
ステップ74では、XSに左辺の終点のX座標を代入す
る。In step 74, the X coordinate of the end point of the left side is substituted for XS.
ステップ75では、errlが正がどうが調べる。er
rlが正ならば、ステップ74へ行く。In step 75, it is determined whether errl is positive. er
If rl is positive, go to step 74.
そうでなければ、ステップ77へ行く。Otherwise, go to step 77.
次に、右辺の処理が終了したか調べる。 (ステップ7
7)右辺の処理が終了していないなら、ステップ78へ
行く、ステップ78では通常の処理を行う、ここで言う
通常の処理とは、第13図のフローチャートのステップ
40からステップ46に示す処理と全く同じ処理である
。そして、この通常の処理を行ったら、ステップ83へ
行く。Next, check whether the processing on the right side has finished. (Step 7
7) If the processing on the right side has not been completed, go to step 78. In step 78, normal processing is performed. The normal processing here refers to the processing shown in steps 40 to 46 in the flowchart of FIG. The process is exactly the same. After performing this normal processing, the process proceeds to step 83.
ステップ77で、右辺の処理が終了したと判断されたら
、ステップ79へ行き、右辺の傾きが正であるか調べる
。右辺の傾きが正ならば、ステップ80へ行き、そうで
なければ、ステップ81へ行く。If it is determined in step 77 that the processing of the right side has been completed, the process proceeds to step 79 to check whether the slope of the right side is positive. If the slope of the right side is positive, go to step 80; otherwise, go to step 81.
ステップ80では、xeに右辺の終点のX座標を代入す
る。In step 80, the X coordinate of the end point of the right side is substituted for xe.
ステップ81では、errrが正かどうか調べる。er
rrが正ならば、ステップ80へ行く。In step 81, it is checked whether errr is positive. er
If rr is positive, go to step 80.
そうでなければ、ステップ83へ行く。Otherwise, go to step 83.
805の右辺は、処理が終了するので、ステップ79へ
行き、傾きが正なので、ステップ8oへ行く、そして、
x6に805の辺の終点の848のX座標を代入する。On the right side of 805, the process ends, so go to step 79, and since the slope is positive, go to step 8o, and
Assign the X coordinate of 848 of the end point of side 805 to x6.
ステップ83では、XSとxeとyを用紙転写装置に送
る。第8図では、854のX座標に於いて、xsからx
e、即ち、 (842のX座標、854のX座標)と(
848のX座標、854のX座標)を送る。In step 83, XS, xe, and y are sent to the paper transfer device. In Figure 8, at the X coordinate of 854, from xs to x
e, that is, (X coordinate of 842, X coordinate of 854) and (
848 X coordinate, 854 X coordinate).
この動作の実現方法につl、)て第17図と第18図で
説明する。A method for realizing this operation will be explained with reference to FIGS. 17 and 18.
左辺の終点の検出は、前述したように247のカウンタ
で行う、左辺の終点になると、247のカウンタからリ
プルキャリが出力される。これが。The end point of the left side is detected by the counter 247 as described above. When the end point of the left side is reached, the counter 247 outputs a ripple carry. This is.
244と993のアンドゲートに入力されるため。Because it is input to the AND gate of 244 and 993.
各々のゲートはりプルキャリ以外の信号を9通過させる
ことができるようになる。このとき244のアンドゲー
トは、左辺の傾きが負の時に1を出力する。この出力が
、994のノアゲートで反転されてOになり、242の
セレクタのSEL端子に入力される。SEL端子がOに
なると、242のセレクタはAの入力を出力する。これ
によって、Xs ENDが出力され、ステップ71.
ステップ73、ステップ74の流れが実現できる。ステ
ツブ71.ステップ73.ステップ75.ステップ74
の流れを実現するには、243のインバータで、左辺の
、傾きが正の時、1を993のアンドゲートに入力し、
995のインバータでerrlが正の時、1を993の
アンドゲートに入力する。そして、993のアンドゲー
トの出力を、994のノアゲートで反転して、242の
セレクタのSEL端子に入力することによって、Xs
endを出力させる。Each gate allows nine signals other than pull-carry to pass through. At this time, the AND gate 244 outputs 1 when the slope of the left side is negative. This output is inverted by the NOR gate 994 to become O, and is input to the SEL terminal of the selector 242. When the SEL terminal becomes O, the selector 242 outputs the input of A. As a result, Xs END is output, and step 71.
The flow of steps 73 and 74 can be realized. Steve 71. Step 73. Step 75. Step 74
To realize the flow of 243 inverter, when the slope on the left side is positive, input 1 to 993 AND gate,
When errl is positive in the 995 inverter, 1 is input to the 993 AND gate. Then, by inverting the output of the AND gate 993 with the NOR gate 994 and inputting it to the SEL terminal of the selector 242,
Output end.
右辺の終点の検出は、左辺の終点の検出と同様に、29
7のカウンタで行う、右辺の終点になると、297のカ
ウンタがらリプルキャリが出力される。これが、294
と997のアンドゲートに入力されるため、各々のゲー
トはりプルキャリ以外の信号を2通過させることができ
るようになる。Detection of the end point of the right side is similar to detection of the end point of the left side.
When the right side reaches the end point performed by the counter 7, a ripple carry is output from the counter 297. This is 294
and 997 AND gates, each gate can allow two signals other than pull-carry to pass through.
このとき294のアンドゲートは、右辺の傾きが正の時
に、996のインバータによって1を入力され、1を出
力する。この出力が、998のノアゲートで反転されて
Oになり、292のセレクタのSEL端子に入力される
。SEL端子が0になると、292のセレクタはAの入
力を出力する。これによって、 Xe endが出力さ
れ、ステップ77、ステップ79.ステップ80の流れ
が実現できる。ステップ77、ステップ79.ステップ
81.ステップ80の流れを実現するには、右辺の傾き
が負の時21を997のアンドゲートに入力し、emが
負の時、1を997のアンドゲートに入力する。At this time, the AND gate 294 receives 1 from the inverter 996 and outputs 1 when the slope of the right side is positive. This output is inverted by the NOR gate 998 to become O, and is input to the SEL terminal of the selector 292. When the SEL terminal becomes 0, the selector 292 outputs the input of A. As a result, Xe end is output, and steps 77, 79 . The flow of step 80 can be realized. Step 77, Step 79. Step 81. To implement the flow of step 80, when the slope of the right side is negative, 21 is input to the AND gate of 997, and when em is negative, 1 is input to the AND gate of 997.
そして、997のアンドゲートの出力を、998のノア
ゲートで反転して、292のセレクタのSEL端子に入
力することによって、Xe endを出力させる。Then, the output of the AND gate 997 is inverted by the NOR gate 998 and inputted to the SEL terminal of the selector 292, thereby outputting Xe end.
以上のようにして、Yendまで処理すると。Processing up to Yend as described above.
第19図の926のカウンタのリプルキャリが出力され
、カウントが停止する。そして、このリプルキャリが9
38のオアゲートと927のインバータを経て、929
のフリップフロップから930のアンドゲートに加えら
れると、CLOCKが停止する。また、 HALTも解
除され、 CPUがプログラムの実行を再開する。 C
PUは、第12図のステップ29を実行する。ステップ
29では、YendO値をカレントのy座標の値として
、ステップ21に戻る。The ripple carry of the counter 926 in FIG. 19 is output, and counting is stopped. And this ripple carry is 9
After 38 OR gates and 927 inverters, 929
CLOCK is stopped when applied from the flip-flop to the AND gate of 930. HALT is also released and the CPU resumes program execution. C
The PU executes step 29 in FIG. In step 29, the YendO value is set as the current y-coordinate value, and the process returns to step 21.
そして、全ての辺を処理し終わるまで、ステップ21か
らステップ29を繰り返す。Steps 21 to 29 are then repeated until all edges have been processed.
全部の辺の処理を終了したら、第11図のステップ1に
戻り、入力を待つ。After processing all edges, return to step 1 in FIG. 11 and wait for input.
[発明の効果]
以上説明したように2本発明によれば、塗りつぶしを行
う図形の辺が通過するビットをすべてオンにできるため
、従来の方法では正しく塗りつぶしができなかった第2
図に示すような図形も、第9図に示すように、正しく塗
りつぶすことができる。さらに、複雑な繰り返し処理を
回路化したため、処理が大幅に高速化される。また2回
路も。[Effects of the Invention] As explained above, according to the present invention, all the bits through which the sides of the figure to be filled can be turned on, so that the second
The figure shown in the figure can also be filled in correctly, as shown in FIG. Furthermore, since complex repetitive processing is implemented as a circuit, processing speed is significantly increased. Also 2 circuits.
−船釣な回路素子のみで構成されているので2回路を実
現するのが容易で、ゲートアレイ等LSI化しやすく1
本発明の効果は多大である。- It is easy to realize two circuits because it is composed of only basic circuit elements, and it is easy to implement LSI such as gate array.
The effects of the present invention are significant.
【図面の簡単な説明】
第1図は2本発明の印刷装置の構成を示す機能ブロック
図。
第2図は、従来例に於ける問題点を示す概念図。
第3図は1本発明の塗りつぶしに於ける。ビットの選択
法の基本方針を示した概念図。
第4図は2本発明の、左辺の塗りつぶしに必要なデータ
を示す概念図。
第5図は2本発明の、左辺の塗りつぶしに必要なデータ
の求め方を示す概念図。
第6図は2本発明の、右辺の塗りつぶしに必要なデータ
を示す概念図。
第7図は1本発明の、塗りつぶしに於けるビットの選択
法について、左辺と右辺の各々の傾きに応じた違いを示
す概念図。
第8図は9本発明による多角形の塗りつぶし方を示す概
念図。
第9図は2本発明によって、第2図に示した従来例の問
題点が、解消されることを示した概念図。
第10図は2本発明の実施例を示すシステム構成図。
第11図は2本発明の印刷装置の実施例を示すフローチ
ャート。
第12図は1本発明の印刷装置の実施例のうち。
ビットデータを作成する部分の全体の流れを示すフロー
チャート。
第13図は2本発明の印刷装置の実施例のうち。
塗りつぶしを行ってビットデータを作成する部分の詳細
な流れを示すフローチャート。
第14図は1本発明の印刷装置の実施例の、塗りつぶし
を行ってビットデータを作成する部分の詳細な流れを示
すフローチャートのうち、新規の辺の座標点の補正の流
れを示すフローチャート。
第15図は2本発明の印刷装置の実施例の、塗りつぶし
を行ってビットデータを作成する部分の詳細な流れを示
すフローチャートのうち、処理を終了する辺の座標点の
補正の流れを示すフローチャート。
第16図は2本発明の印刷装置の実施例のうち。
塗りつぶし範囲決定回路の構成、及び、 CPU、用紙
転写装置との接続を示すブロック図。
第17図は9本発明の印刷装置の実施例のうち。
塗りつぶし範囲決定回路の、左辺の処理を行う回路の実
現例を示した回路図。
第18図は2本発明の印刷装置の実施例のうち。
塗りつぶし範囲決定回路の、右辺の処理を行う回路の実
現例を示した回路図。
第19図は2本発明の印刷装置の実施例のうち。
塗りつぶし範囲決定回路の動作を制御する回路の実現例
を示した回路図。
第20図は9本発明の印刷装置の実施例のうち。
塗りつぶし範囲決定回路のy座標の値を計算する回路の
実現例を示した回路図。
1 ・・・
2 ・・・
3 ・・・
4 ・・・
5 ・・・
データ人。出力手段
直線近似部
塗りつぶしデータ計算部
ビットデータ作成部
用紙転写装置
21・・・X軸
22・・・y軸
23・・・ビットの中心座標
24.25,27.26 ・・・塗りつぶしを行う多
角形28・・・塗りつぶされたビットの例
30.31,32,33,34,35,36,37
・・・整数のy座標を示す直線
40・・・X軸
41・・・y軸
42.43,44,45 ・・・従来の方法では問題
が発生する。
塗りつぶされる多角形
46.47,48,49,50,51.52 ・・・
整数のy座標を示す直線
301 ・・・
302・・・
303.307
304.309
305.310
306 ・・・
308・・・
左辺を示す直線
左辺として選択されるビットを示す例
・・・ビットの中心座標
・・・y軸
・・・X軸
右辺として選択されるビットを示す例
右辺を示す直線
401・・・左辺を示す直線
402・・・左辺として選択されるピッ403・・・拡
大図の範囲を示す円
404・・・y軸
405・・・X軸
410.411,412
421.422・・・
431.432,433
441.442,443
451.452,453
・・・左辺のerrを示す矢印
X軸方向のビット境界
・・・整数のy座標を示す矢印
・・・左辺として選択されるビット
・・・y軸方向のビット境界
トを示す例
501・・・左辺の始点付近を示す傾きが正の直線50
2・・・X軸方向のビット境界からの距離503・・・
傾きが正の左辺とy軸方向のビット境界との交点と、傾
きが正の左辺の始点との、X軸方向の距離
504・・・傾きが正の左辺のerrの初期値505.
526・・・ 1つのビットを示す凡例506.527
・・・ビットの中心座標507.524・・・X軸方向
のビット境界521・・・左辺の始点付近を示す傾きが
負の直線522・・・X軸方向のビット境界からの距離
523・・・傾きが負の左辺とy軸方向のビット境界と
の交点と、傾きが負の左辺の始点との、X軸方向の距離
525・・・傾きが負の左辺のerrの初期値601・
・・右辺を示す直線
602・・・右辺として選択されるビットを示す例60
3・・・拡大図の範囲を示す円
604・・・y軸
605・・・X軸
610.611,612 ・・・右辺のerrを示す矢
印621.622・・・X軸方向のビット境界631.
632,633 ・・・整数のy座標を示す矢印64
1.642,643 ・・・右辺として選択されるビ
ット651.652,653,654 ・・・ y軸
方向のビット境界801・・・X軸
802・・・y軸
803・・・座標軸原点
804.805,806,807,808,809
・・・辺で表される塗りつぶしをする多角形
810・・・ビットの中心座標
821.822,823 ・805の辺の各々のer
r831.832,833,834 ・804の辺の
各々のerr841.842,843,844,845
,846,847,848,849・・・y軸の整数座
標
851.852,853,854,855,856,8
57,858,859,860・・・y軸の整数座標
901.902,903,904 ・・・第2図に示
す、従来の方法では問題が発生する。塗りつぶされる多
角形910・・・
911 ・・・
912・・・
913 ・・・
914・・・
塗りつぶし範囲決定回路
CPU
errl計算回路
xs計算回路
errr計算回路
915・・・ xe計算回路
916・・・用紙転写装置
201− s s 1ope 1入力端子202・・
・ errl入力端子
203.253− c l e a r入力端子204
・・・all入力端子
205・・・c21入力端子
206.256,953 ・・・CLOCK入力端子
207・・・Xs END入力端子
208・・・m11入力端子
209・・・m12入力端子
210・・・Xs入力端子
211・・・END Yl入力端子
212.262・・・ INIT LOAD入力端子
213.263,921,952 ・・・ LOAD
入力端子214.264,924,954 ・・・R
ESET入力端子215・・・Xs出力端子
216.267・・・ INITIAL入力端子251
・・・
252・・・
254・・・
255 ・・・
257 ・・・
258・・・
259・・・
260・・・
261 ・・・
266 ・・・
922・・・
923 ・・・
931 ・・・
936 ・・・
933 ・・・
951 ・・・
961 ・・・
s 5loper入力端子
errr入力端子
clr入力端子
c2r入力端子
Xe END入力端子
mr1入力端子
mr2入力端子
Xe入力端子
END Yr入力端子
Xe出力端子
Yend+1−current y入力端子MASTE
R−CLOCK入力端子
CLOCK出力端子
HALT出力端子
c、l e a r出力端子
Current−y入力端子
y出力端子
221.222,227,218.219.220,2
32,234,238.271.277 。
272.269,270,293,282,284,2
88,925,937,955・・・ラッチ
229.226,231,237,240,245,2
46,279,276.281.287゜290.29
6,295,929,932,956,960,958
・・・フリップフロップ
223.224,225.233.235.236,2
42,273.274,275.283 。
285.286,292 ・・・セレクタ230.2
41,280,291,957 ・・・加算器247
.297,926,959 ・・・カウンタ228.
239,217,248,278,289,268,2
98,938・・・オアゲート
243.994,996,927,928 ・・・イ
ンバータ244.249,250,265.294,2
99,991.992,993.997,930゜93
4・・・アンドゲート
994.998・・・ノアゲート
111・・・マイクロコンピュータ
112・・・CPU
113・・・rom
114・・・ワークメモリ
116・・・
117 ・・・
O
用紙転写装置
塗りつぶし範囲決定回路
以上BRIEF DESCRIPTION OF THE DRAWINGS FIG. 1 is a functional block diagram showing the configuration of a printing apparatus according to the present invention. FIG. 2 is a conceptual diagram showing problems in the conventional example. FIG. 3 shows one example of filling in the present invention. A conceptual diagram showing the basic policy of bit selection method. FIG. 4 is a conceptual diagram showing data necessary for filling in the left side according to the present invention. FIG. 5 is a conceptual diagram showing how to obtain data necessary for filling in the left side according to the present invention. FIG. 6 is a conceptual diagram showing data necessary for filling in the right side according to the present invention. FIG. 7 is a conceptual diagram showing the difference in the bit selection method for filling according to the present invention depending on the slope of each of the left side and right side. FIG. 8 is a conceptual diagram showing how to fill in a polygon according to the present invention. FIG. 9 is a conceptual diagram showing that the problems of the conventional example shown in FIG. 2 are solved by the present invention. FIG. 10 is a system configuration diagram showing two embodiments of the present invention. FIG. 11 is a flowchart showing two embodiments of the printing apparatus of the present invention. FIG. 12 shows one embodiment of the printing apparatus of the present invention. Flowchart showing the overall flow of creating bit data. FIG. 13 shows two embodiments of the printing apparatus of the present invention. A flowchart showing the detailed flow of filling in and creating bit data. FIG. 14 is a flowchart showing the flow of correcting the coordinate points of a new side among the flowcharts showing the detailed flow of filling in and creating bit data in an embodiment of the printing apparatus of the present invention. FIG. 15 is a flowchart showing the flow of correcting the coordinate point of the side where the process ends, among the flowcharts showing the detailed flow of the portion of filling in and creating bit data in the second embodiment of the printing apparatus of the present invention. . FIG. 16 shows two embodiments of the printing apparatus of the present invention. FIG. 2 is a block diagram showing the configuration of a filling range determining circuit and connections with a CPU and a paper transfer device. FIG. 17 shows nine embodiments of the printing apparatus of the present invention. FIG. 3 is a circuit diagram showing an implementation example of a circuit that processes the left side of a filling range determining circuit. FIG. 18 shows two embodiments of the printing apparatus of the present invention. FIG. 3 is a circuit diagram illustrating an implementation example of a circuit that processes the right side of a filling range determining circuit. FIG. 19 shows two embodiments of the printing apparatus of the present invention. FIG. 3 is a circuit diagram showing an implementation example of a circuit that controls the operation of a filling range determining circuit. FIG. 20 shows nine embodiments of the printing apparatus of the present invention. FIG. 3 is a circuit diagram showing an implementation example of a circuit that calculates a y-coordinate value of a filling range determining circuit. 1 ... 2 ... 3 ... 4 ... 5 ... Data person. Output means Linear approximation section Fill data calculation section Bit data creation section Paper transfer device 21... Square 28...Example of filled bits 30.31, 32, 33, 34, 35, 36, 37
. . . Straight line 40 indicating an integer y-coordinate. . . Polygons to be filled 46.47, 48, 49, 50, 51.52...
Straight line showing the y-coordinate of an integer 301...302...303.307 304.309 305.310 306...308... Straight line showing the left side Example showing the bits selected as the left side... Center coordinates...Y axis...Example showing the bits selected as the right side of the X axis Straight line 401 showing the right side...Straight line 402 showing the left side...Pitch 403 selected as the left side...Enlarged view Circle indicating range 404...Y axis 405...X axis 410.411,412 421.422...431.432,433 441.442,443 451.452,453...Indicating err on the left side Arrow Bit boundary in the X-axis direction...Arrow indicating the y-coordinate of an integer...Bit selected as the left side...Example 501 showing the bit boundary in the y-axis direction...Slope indicating the vicinity of the starting point of the left side is a positive straight line 50
2...Distance from the bit boundary in the X-axis direction 503...
Distance in the X-axis direction between the intersection of the left side with a positive slope and the bit boundary in the y-axis direction and the start point of the left side with a positive slope 504... Initial value of err on the left side with a positive slope 505.
526... Legend 506.527 indicating one bit
...Bit center coordinates 507.524...Bit boundary in the X-axis direction 521...A straight line with a negative slope indicating the vicinity of the starting point of the left side 522...Distance from the bit boundary in the X-axis direction 523...・Distance in the X-axis direction between the intersection of the left side with a negative slope and the bit boundary in the y-axis direction and the starting point of the left side with a negative slope 525 ... Initial value of err on the left side with a negative slope 601 ・
... Straight line 602 indicating the right side...Example 60 indicating the bits selected as the right side
3...Circle 604 indicating the range of the enlarged view...Y axis 605...X axis 610, 611, 612...Arrow indicating err on the right side 621, 622...Bit boundary in the X axis direction 631 ..
632, 633 ...Arrow 64 indicating the y-coordinate of an integer
1.642,643...Bits selected as the right side 651.652,653,654...Bit boundary in the y-axis direction 801...X-axis 802...y-axis 803...Coordinate axis origin 804. 805, 806, 807, 808, 809
...Polygon 810 to be filled represented by sides...Center coordinates of bits 821, 822, 823 er of each side of 805
r831.832,833,834 err841.842,843,844,845 for each side of 804
, 846, 847, 848, 849... Integer coordinates of the y-axis 851.852, 853, 854, 855, 856, 8
57,858,859,860...integer coordinates on the y-axis 901,902,903,904...A problem occurs with the conventional method shown in FIG. Polygon to be filled 910... 911... 912... 913... 914... Filling range determination circuit CPU errl calculation circuit xs calculation circuit errr calculation circuit 915... xe calculation circuit 916... paper Transfer device 201-ss1ope1 input terminal 202...
・ errl input terminal 203.253-cl e a r input terminal 204
...all input terminal 205...c21 input terminal 206,256,953...CLOCK input terminal 207...Xs END input terminal 208...m11 input terminal 209...m12 input terminal 210... Xs input terminal 211...END Yl input terminal 212.262... INIT LOAD input terminal 213.263,921,952...LOAD
Input terminal 214.264, 924, 954...R
ESET input terminal 215...Xs output terminal 216.267...INITIAL input terminal 251
... 252 ... 254 ... 255 ... 257 ... 258 ... 259 ... 260 ... 261 ... 266 ... 922 ... 923 ... 931 ...・ 936 ... 933 ... 951 ... 961 ... s 5loper input terminal errr input terminal clr input terminal c2r input terminal Xe END input terminal mr1 input terminal mr2 input terminal Xe input terminal END Yr input terminal Xe output terminal Yend+1-current y input terminal MASTE
R-CLOCK input terminal CLOCK output terminal HALT output terminal c, l e a r output terminal Current-y input terminal y output terminal 221.222, 227, 218.219.220, 2
32,234,238.271.277. 272.269,270,293,282,284,2
88,925,937,955...Latch 229.226,231,237,240,245,2
46,279,276.281.287゜290.29
6,295,929,932,956,960,958
...Flip-flop 223.224, 225.233.235.236, 2
42,273.274,275.283. 285.286,292...Selector 230.2
41,280,291,957...Adder 247
.. 297,926,959...Counter 228.
239, 217, 248, 278, 289, 268, 2
98,938...OR gate 243.994,996,927,928...Inverter 244.249,250,265.294,2
99,991.992,993.997,930°93
4...AND gate 994.998...Noah gate 111...Microcomputer 112...CPU 113...ROM 114...Work memory 116...117...O Paper transfer device filling range determination More than a circuit
Claims (1)
タとして扱い、用紙に印刷する、印刷装置において、 b)前記文字や図形のデータの入出力を行う、データ入
出力手段と、 c)前記図形や文字の、輪郭を表す整数であるxy座標
データに含まれている、曲線のデータを、直線の整数の
xy座標データに近似する、直線近似部と、 d)前記直線近似部によって、曲線のデータを近似した
、前記直線の整数のxy座標データと、入力されたまま
の直線の整数であるxy座標データを使って、それら前
記直線を、前記印刷装置の離散的なビットに対応させる
際に、前記直線が通過する前記ビットを前記直線に対応
させるように、前記直線で構成される前記図形や文字を
塗りつぶす範囲を決定するのに必要なデータを算出して
出力する、塗りつぶしデータ計算部と、 e)前記塗りつぶしデータ計算部の出力を使って、塗り
つぶしを行う範囲を決定する、塗りつぶし範囲決定回路
と、 f)前記塗りつぶし範囲決定回路の出力に従って、ビッ
トマップディジタルデータを作成して、用紙に転写する
用紙転写装置を有することを特徴とする印刷装置。[Scope of Claims] a) A printing device that handles characters and figures as xy coordinate data, which are integers representing outlines, and prints them on paper; b) A data input device that inputs and outputs the data of the characters and figures. output means; c) a linear approximation unit that approximates curve data included in the integer xy coordinate data representing the contour of the figure or character to the integer xy coordinate data of a straight line; d) The linear approximation unit uses the integer xy coordinate data of the straight line that approximates the curve data and the integer xy coordinate data of the straight line as input, and converts the straight line into a discrete image of the printing device. When making the bits that the straight line passes correspond to the bits that the straight line passes through, calculate the data necessary to determine the range of filling in the figure or character that is made up of the straight line. e) a fill range determination circuit that determines a range to be filled using the output of the fill data calculation unit; and f) a bitmap digital output according to the output of the fill range determination circuit. A printing device characterized by having a paper transfer device that creates data and transfers it onto paper.
Priority Applications (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP11466190A JPH0410179A (en) | 1990-04-27 | 1990-04-27 | printing device |
Applications Claiming Priority (1)
| Application Number | Priority Date | Filing Date | Title |
|---|---|---|---|
| JP11466190A JPH0410179A (en) | 1990-04-27 | 1990-04-27 | printing device |
Publications (1)
| Publication Number | Publication Date |
|---|---|
| JPH0410179A true JPH0410179A (en) | 1992-01-14 |
Family
ID=14643407
Family Applications (1)
| Application Number | Title | Priority Date | Filing Date |
|---|---|---|---|
| JP11466190A Pending JPH0410179A (en) | 1990-04-27 | 1990-04-27 | printing device |
Country Status (1)
| Country | Link |
|---|---|
| JP (1) | JPH0410179A (en) |
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US10908612B2 (en) | 2018-03-29 | 2021-02-02 | Toyota Research Institute, Inc. | Systems and methods for an autonomous cart robot |
-
1990
- 1990-04-27 JP JP11466190A patent/JPH0410179A/en active Pending
Cited By (1)
| Publication number | Priority date | Publication date | Assignee | Title |
|---|---|---|---|---|
| US10908612B2 (en) | 2018-03-29 | 2021-02-02 | Toyota Research Institute, Inc. | Systems and methods for an autonomous cart robot |
Similar Documents
| Publication | Publication Date | Title |
|---|---|---|
| KR950012083B1 (en) | Character / Shape Generator and Information Processing Unit | |
| JPS63198174A (en) | Graphic processor | |
| JPH0410179A (en) | printing device | |
| JP2634851B2 (en) | Image processing device | |
| JPH03233689A (en) | Outline data drawing device | |
| JP3087427B2 (en) | Contour data converter | |
| JPH01303489A (en) | Character output system | |
| JP3059189B2 (en) | Fill circuit | |
| JPH0589251A (en) | Image drawing device | |
| JPH01191192A (en) | High quality character generating device | |
| JP3238202B2 (en) | Character / graphic generating apparatus and information processing apparatus | |
| KR920002471B1 (en) | Graphic controller | |
| EP0838786A1 (en) | Method of producing polygon data, image processor to which the method is applied, and expanded function board | |
| JPS63303477A (en) | Vector character and graphic processing system | |
| JPS62285188A (en) | Display method for segment | |
| JP3457336B2 (en) | Outline data processing device | |
| JPH0451284A (en) | Pattern expanding and converting device | |
| JP3072756B2 (en) | Drawing equipment | |
| JP3067137B2 (en) | Information processing device with line drawing function | |
| EP0229694A2 (en) | Vector graphics generator set-up | |
| JPS6383823A (en) | Compiling system for printed output | |
| JPS62205479A (en) | Special figure generation circuit for CRT display device | |
| JPH04162092A (en) | Outline font character generation method | |
| McCormac | Design and implementation of a PostScript compatible system of graphics primitive procedures | |
| JPH0384680A (en) | Document preparing device |