JPH02183877A - Graphic display device - Google Patents

Graphic display device

Info

Publication number
JPH02183877A
JPH02183877A JP451989A JP451989A JPH02183877A JP H02183877 A JPH02183877 A JP H02183877A JP 451989 A JP451989 A JP 451989A JP 451989 A JP451989 A JP 451989A JP H02183877 A JPH02183877 A JP H02183877A
Authority
JP
Japan
Prior art keywords
straight line
distance
inclination
pixels
plotted
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
JP451989A
Other languages
Japanese (ja)
Inventor
Kimihiko Fukuda
福田 公彦
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.)
NEC Corp
Original Assignee
NEC Corp
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 NEC Corp filed Critical NEC Corp
Priority to JP451989A priority Critical patent/JPH02183877A/en
Publication of JPH02183877A publication Critical patent/JPH02183877A/en
Pending legal-status Critical Current

Links

Landscapes

  • Digital Computer Display Output (AREA)
  • Image Generation (AREA)

Abstract

PURPOSE:To attain linear plotting at high speed by obtaining the maximum number of picture elements to have the same coordinates securely exists on a straight line to be plotted, based on inclination obtained by an inclination arithmetic means. CONSTITUTION:A long axis computation circuit 2 compares a distance DELTAx in the (x) coordinate between the start point and end point of the straight line to be plotted with a distance DELTAy in the (y) coordinate. Based on the result of this comparison, an inclination arithmetic circuit 3 executes division with the larger distance, out of the distances DELTAx and DELTAy, as a denominator and the smaller distance as a numerator and obtains inclination (m) of the straight line to be plotted. The maximum number of picture elements to have the same coordinates securely exists on the straight line to be plotted is obtained based on the inclination (m) which is obtained by this inclination arithmetic means. Thus, the whole time of the drawing can be decreased and as a result, the high-speed linear plotting can be promoted.

Description

【発明の詳細な説明】 〔産業上の利用分野〕 本発明は、ビソトマフプ表示装置を有し直線などの図形
を表示可能な図形表示装置に関し、特に直線描画を高速
で行い得る図形表示装置に関するものである。
DETAILED DESCRIPTION OF THE INVENTION [Field of Industrial Application] The present invention relates to a graphic display device having a bisotomaph display device and capable of displaying figures such as straight lines, and particularly to a graphic display device capable of drawing straight lines at high speed. It is.

〔従来の技術〕[Conventional technology]

従来、この種の図形表示装置においては、直線を描画す
る場合、直線上の画素のアドレス計算と描画を1画素ず
つ行っていた。
Conventionally, in this type of graphic display device, when drawing a straight line, address calculation and drawing of pixels on the straight line were performed pixel by pixel.

〔発明が解決しようとする課題〕[Problem to be solved by the invention]

しかしながら、このような従来の図形表示装置によると
、直線上の画素のアドレス計算と描画を1画素ずつ行っ
ているため、直線の描画に際しその描画速度が遅いとい
う欠点がある。
However, such conventional graphic display devices have the disadvantage that the drawing speed of straight lines is slow because address calculation and drawing of pixels on a straight line are performed pixel by pixel.

〔課題を解決するための手段〕[Means to solve the problem]

本発明はこのような課題を解決するためになされたもの
で、連続したアドレスをもつN(N=2以上の自然数)
画素を1単位として同時に描画する描画手段と、N画素
内の任意の画素に対する描画を禁止するマスク手段と、
描画する直線の始点/終点間のX座標における距離Δx
とy座標における距離Δyとを比較する比較手段と、こ
の比較手段における比較結果に基づき上記ΔxおよびΔ
yのうちその距離の大なる方を分母とし小なる方を分子
として除算を行い描画する直線の傾きmを求める傾演算
手段と、この傾演算手段により求められる傾きmに基づ
き描画する直線上において同一座標を持つ画素が確実に
存在する最大数を求める手段とを備えている。
The present invention was made in order to solve such problems, and it has N (N = natural number of 2 or more) with consecutive addresses.
a drawing means that simultaneously draws pixels as one unit; a masking means that prohibits drawing on any arbitrary pixel within the N pixels;
Distance Δx in the X coordinate between the start point and end point of the straight line to be drawn
and a comparison means for comparing the distance Δy in the y coordinate, and the above-mentioned Δx and Δ
A slope calculation means for calculating the slope m of a straight line to be drawn by dividing the distance between y using the larger one as the denominator and the smaller one as the numerator; and means for determining the maximum number of pixels having the same coordinates that reliably exist.

〔作用〕[Effect]

したがってこの発明によれば、全体の描画回数を減少さ
せることが可能となる。
Therefore, according to the present invention, it is possible to reduce the total number of times of drawing.

〔実施例〕〔Example〕

以下、本発明に係る図形表示装置を詳細に説明する。 Hereinafter, the graphic display device according to the present invention will be explained in detail.

図はこの図形表示装置の一実Jtti例を示すブロック
構成図である。同図において、lは描画する直線の始点
/終点のx、Xアドレス(xs、ys)/(xe、y、
)を保持する入力レジスタ、2はΔx(Δx=lx、−
x、l)とΔy(Δy=IVsy、1)とを比較し、Δ
x≧ΔyなるときX軸長軸ΔxくΔyなるときY軸長軸
として判定する長軸計算回路、3はY軸長軸の場合(x
S−x、)/(ys −y−) 、X軸長軸の場合(y
、−y、)/(x、−x、)の値を傾きmとして求め出
力する傾き計算回路、4はII/mlの整数部から1を
引いた値をkとして出力する水平画素数計算回路、5は
長軸情報、傾きm、始点Xアドレスgs、P。
The figure is a block configuration diagram showing an example of this graphic display device. In the same figure, l is x of the start point/end point of the straight line to be drawn, X address (xs, ys)/(xe, y,
), 2 is Δx (Δx=lx, −
x, l) and Δy (Δy=IVsy, 1), Δ
When x≧Δy, the long axis of the X axis is Δx, and when Δy, the long axis of the Y axis is determined. 3 is the long axis of the Y axis (x
S-x, )/(ys -y-), for the long axis of the X axis (y
, -y, )/(x, -x,) as a slope m and outputs the value. 4 is a horizontal pixel number calculation circuit that outputs the value obtained by subtracting 1 from the integer part of II/ml as k. , 5 is long axis information, slope m, starting point X address gs, P.

点Xアドレスx0により1画素ずつXアドレスを計算し
マスク生成回路7へ出力するXアドレス計算回路、6は
長軸情報、傾きm、始点yアドレスys、終点yアドレ
スy、により1画素ずつXアドレスを計算しフレームバ
ッファメモリ8へ出力するXアドレス計算回路、9はフ
レームバッファメモリ8の内容を順次読み出し表示する
表示部である。なお、水平画素数計算回路4は、If/
mlの整数部から1を引いた値kが負またはOであれば
に=1として、またm=0の場合にはに=Iysyal
として出力する機能を備えている。
An X address calculation circuit that calculates the X address for each pixel based on the point 9 is a display unit that sequentially reads and displays the contents of the frame buffer memory 8. Note that the horizontal pixel number calculation circuit 4 has If/
If the value k obtained by subtracting 1 from the integer part of ml is negative or O, then = 1, and if m = 0, = Iysyal
It has a function to output as .

次に、Xアドレス計算回路5.マスク生成回路7および
フレームバッファメモリ8の機能ヲ、それに関連する動
作を交えながら説明する。
Next, the X address calculation circuit 5. The functions of the mask generation circuit 7 and the frame buffer memory 8 will be explained together with the operations related thereto.

すなわち、Xアドレス計算回路5は、X軸長軸の場合、
始点または画素アドレス計算中、Yアドレスが1つ前の
画素のYアドレスに対し変化した点のとき、連続描画指
示をマスク生成回路7に指示すると共に、計算中の次の
画素のXアドレスは前のXアドレスにkを加えて求める
。この時、Yアドレスはm−kを加えて求める。マスク
生成回路7は、Xアドレス、におよび連続描画Iレボの
有無を参照し、N (Nは2以上の自然数)bitのマ
スク情仰を作成して必要な画素の描画を行う。
That is, in the case of the long axis of the X-axis, the X-address calculation circuit 5 calculates
During starting point or pixel address calculation, when the Y address changes from the Y address of the previous pixel, a continuous drawing instruction is given to the mask generation circuit 7, and the X address of the next pixel being calculated is set to the previous pixel. Find it by adding k to the X address of . At this time, the Y address is obtained by adding m-k. The mask generation circuit 7 refers to the X address and the presence or absence of continuous drawing I-rev, creates a mask information of N (N is a natural number of 2 or more) bits, and draws the necessary pixels.

マスク生成回路7からは、連続したアドレスをもつNb
1tを1単位として同時に描画することが可能であるが
、1回の描画で必要な画素数を描画できなかった場合に
は、再度マスク情報を作り直し描画を行う。これを繰り
返すことにより、必要な画素数分描画を行う。この時、
描画回数が最小となるようにマスク情報を決定する。な
お、マスク生成回路7は、上記Nb1t内の任意のbi
tに対する描画を禁止する機能を備えている。
From the mask generation circuit 7, Nb
Although it is possible to draw at the same time with 1t as one unit, if the required number of pixels cannot be drawn in one drawing, the mask information is recreated and the drawing is performed again. By repeating this, drawing is performed for the required number of pixels. At this time,
Mask information is determined so that the number of drawings is minimized. Note that the mask generation circuit 7 generates any bi in the above Nb1t.
It has a function to prohibit drawing for t.

フレームバッファメモリ8は、Xアドレス、Yアドレス
で指示された画素アドレスに対しマスク情報Nb1tを
参照して必要な画素に対しデータを取り込む。フレーム
バッファメモリ8の内容は順次読み出され表示部9に出
力され表示される。
The frame buffer memory 8 refers to the mask information Nb1t for the pixel address specified by the X address and the Y address and takes in data for the necessary pixel. The contents of the frame buffer memory 8 are sequentially read out and output to the display section 9 for display.

このように本実施例による図形表示装置によれば、直線
描画の際に、同−Yアドレスで確実に連続発生する最大
画素数kを求め、複数画素を同時描画し、少ない描画回
数でに画素描画することにより、全体の描画回数を減ら
すことができ、結果として直線描画の高速化を促進する
ことができるようになる。
As described above, according to the graphic display device according to the present embodiment, when drawing a straight line, the maximum number k of pixels that reliably occur continuously at the same -Y address is determined, multiple pixels are drawn simultaneously, and pixels can be drawn in a small number of times. By drawing, the total number of drawings can be reduced, and as a result, the speed of straight line drawing can be accelerated.

〔発明の効果〕〔Effect of the invention〕

以上説明したように本発明による図形表示装置によれば
、連続したアドレスをもつN (Nは2以上の自然数)
画素を1単位として同時に描画する描画手段と、N画素
内の任意の画素に対する描画を禁止するマスク手段と、
描画する直線の始点/終点間のX座標における距離Δx
とy座標における距離Δyとを比較する比較手段と、こ
の比較手段における比較結果に基づき上記ΔxおよびΔ
yのうちその距離の大なる方を分母とし小なる方を分子
として除算を行い描画する直線の傾きmを求める傾演算
手段と、この傾演算手段により求められる傾きmに基づ
き描画する直線上において同一座標を持つ画素が確実に
存在する最大数を求める手段とを備えたので、全体の描
画回数を減少させ、結果として直線描画の高速化を促進
することが可能となる効果を奏する。
As explained above, according to the graphic display device according to the present invention, N (N is a natural number of 2 or more) having consecutive addresses.
a drawing means that simultaneously draws pixels as one unit; a masking means that prohibits drawing on any arbitrary pixel within the N pixels;
Distance Δx in the X coordinate between the start point and end point of the straight line to be drawn
and a comparison means for comparing the distance Δy in the y coordinate, and the above-mentioned Δx and Δ
A slope calculation means for calculating the slope m of a straight line to be drawn by dividing the distance between y using the larger one as the denominator and the smaller one as the numerator; Since the present invention includes means for determining the maximum number of pixels having the same coordinates, the overall number of times of drawing can be reduced, and as a result, the speed of straight line drawing can be accelerated.

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

図は本発明に係る図形表示装置の一実施例を示すブロッ
ク構成図である。 l・・・入力レジスタ、2・・・長軸計算回路、3・・
・傾き計算回路、4・・・水平画素数計算回路、5・・
・Xアドレス計算回路、6・・・Yアドレス計算回路、
7・・・マスク生成回路、8・・・フレームバッファメ
モリ、9・・・表示部。
The figure is a block diagram showing an embodiment of a graphic display device according to the present invention. l...Input register, 2...Long axis calculation circuit, 3...
・Inclination calculation circuit, 4...Horizontal pixel number calculation circuit, 5...
・X address calculation circuit, 6...Y address calculation circuit,
7... Mask generation circuit, 8... Frame buffer memory, 9... Display unit.

Claims (1)

【特許請求の範囲】[Claims] 連続したアドレスをもつN(Nは2以上の自然数)画素
を1単位として同時に描画する描画手段と、前記N画素
内の任意の画素に対する描画を禁止するマスク手段と、
描画する直線の始点/終点間のx座標における距離Δx
とy座標における距離Δyとを比較する比較手段と、こ
の比較手段における比較結果に基づき前記ΔxおよびΔ
yのうちその距離の大なる方を分母とし小なる方を分子
として除算を行い前記直線の傾きmを求める傾演算手段
と、この傾演算手段により求められる傾きmに基づき前
記直線上において同一座標を持つ画素が確実に存在する
最大数を求める手段とを備えてなる図形表示装置。
a drawing means for simultaneously drawing N pixels (N is a natural number of 2 or more) having consecutive addresses as one unit; a masking means for prohibiting drawing on any pixel within the N pixels;
Distance Δx in the x coordinate between the start point and end point of the straight line to be drawn
and a comparison means for comparing the distance Δy in the y coordinate, and the said Δx and Δy based on the comparison result of this comparison means.
a slope calculating means for calculating the slope m of the straight line by dividing the distance between y using the larger distance as the denominator and the smaller distance as the numerator; A graphic display device comprising means for determining the maximum number of pixels having a certain value.
JP451989A 1989-01-11 1989-01-11 Graphic display device Pending JPH02183877A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP451989A JPH02183877A (en) 1989-01-11 1989-01-11 Graphic display device

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP451989A JPH02183877A (en) 1989-01-11 1989-01-11 Graphic display device

Publications (1)

Publication Number Publication Date
JPH02183877A true JPH02183877A (en) 1990-07-18

Family

ID=11586299

Family Applications (1)

Application Number Title Priority Date Filing Date
JP451989A Pending JPH02183877A (en) 1989-01-11 1989-01-11 Graphic display device

Country Status (1)

Country Link
JP (1) JPH02183877A (en)

Similar Documents

Publication Publication Date Title
KR900006042B1 (en) Display control apparatus for use in composite document processing apparatus
JPH05307610A (en) Texture mapping method and its device
JP4630482B2 (en) Apparatus for generating representation tree and apparatus for rendering raster pixel image
JPH04246790A (en) Vector/conic section/area file primitive generator
US4945497A (en) Method and apparatus for translating rectilinear information into scan line information for display by a computer system
JPH02183877A (en) Graphic display device
US20010055015A1 (en) Area and span based Z-buffer
US8576219B2 (en) Linear interpolation of triangles using digital differential analysis
JP3587105B2 (en) Graphic data processing device
JPS642953B2 (en)
JPH0588838A (en) Multi window display device
JP2780496B2 (en) Clipping method for drawing equipment
JPS62297975A (en) Control system for multi-window display
JPS63113785A (en) Graphic pattern displaying method
JP2836617B2 (en) Rendering processor
JP3311905B2 (en) Image processing device
JP2903514B2 (en) High-speed drawing method
JP2787497B2 (en) Graphic drawing method and apparatus
JPH01166177A (en) Thick line drawing system for dda circuit
JPH0350686A (en) Graphic processing system
JPH0896148A (en) Graphic plotting device
JP2787487B2 (en) Circuit for determining the position of a line segment displayed and operated on a computer system
EP0163872A2 (en) Method of correlating on straight lines in an interactive display system
JPH05205070A (en) Graphic plotting method
JPH08221544A (en) Image deformation processor