JPS60100266A - Shading system - Google Patents

Shading system

Info

Publication number
JPS60100266A
JPS60100266A JP58207406A JP20740683A JPS60100266A JP S60100266 A JPS60100266 A JP S60100266A JP 58207406 A JP58207406 A JP 58207406A JP 20740683 A JP20740683 A JP 20740683A JP S60100266 A JPS60100266 A JP S60100266A
Authority
JP
Japan
Prior art keywords
shading
pattern
memory
work memory
frame information
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
JP58207406A
Other languages
Japanese (ja)
Inventor
Shogo Ono
小野 正吾
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.)
Hitachi Ltd
Original Assignee
Hitachi Ltd
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Hitachi Ltd filed Critical Hitachi Ltd
Priority to JP58207406A priority Critical patent/JPS60100266A/en
Publication of JPS60100266A publication Critical patent/JPS60100266A/en
Pending legal-status Critical Current

Links

Classifications

    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T15/003D [Three Dimensional] image rendering
    • G06T15/50Lighting effects

Landscapes

  • Engineering & Computer Science (AREA)
  • Computer Graphics (AREA)
  • Physics & Mathematics (AREA)
  • General Physics & Mathematics (AREA)
  • Theoretical Computer Science (AREA)
  • Image Generation (AREA)
  • Controls And Circuits For Display Device (AREA)

Abstract

PURPOSE:To enable the titled system to reduce work memory by depicting a shading pattern between the start point and the end point in pair on the work memory and by modifying the shading pattern on the work memory according to frame information. CONSTITUTION:A graphic processor 102 reads a command from a graphic process command buffer 101, depicts the pattern of a frame line on a display memory 104, and depicts patterns of shading start and end points on a work memory 103 to store the frame information in a frame information memory 105. After executing necessary modification to the shading patterns according to the frame information, the processor writes the modified shading patterns in the display memory 104.

Description

【発明の詳細な説明】 〔発明の利用分野〕 本発明は、画像処理装置における図形のシェーディング
の処理方式に関する。
DETAILED DESCRIPTION OF THE INVENTION [Field of Application of the Invention] The present invention relates to a graphic shading processing method in an image processing apparatus.

〔発明の背景〕[Background of the invention]

画像処理の−っにシェーディング処−理があるが、従来
の画像処理装置は、このシェーディング処理を以下に述
べるような方式で行っている。
Shading processing is part of image processing, and conventional image processing apparatuses perform this shading processing in the following manner.

まず、枠情報(シェーディング処理すべき閉図形の頂点
座標や閉図形の枠線の種類等)に従って。
First, according to the frame information (vertex coordinates of the closed figure to be shaded, type of frame line of the closed figure, etc.).

枠線のパターンを表示メモリとワークメモリa上に、枠
線の反転パターンをワークメモリb上に、シェーディン
グの始点および終点のパターンをワークメモリ(、」二
に、それぞれ描く。
The frame line pattern is drawn on the display memory and work memory a, the inverted frame line pattern is drawn on the work memory b, and the shading start and end point patterns are drawn on the work memory (2).

次に、シェーディング処理の単位である各ライン(たと
えば縦方向のライン)について、ワークメモリCを走に
することによりシェーディングパターンを表示メモリに
描いていくが、その始点、終点は必づしも適切でない場
合がある。これは、円形図形等の場合、枠線を一定方向
に追跡することによって始点と終点のパターンを描く関
係上、始点と終点の位置が上下にずれることがあるほか
、枠線が連続線(実線)の場合は、枠線パターンと各ラ
インの交差点のうちで最も内側の2点を始点と終点とす
ればよいのに対し、枠線が破線のような不連続線の場合
、線のある部分では実線の場合と同様であるが、線のな
い部分では枠線の反転パターンの中央を始点または終点
としなければならない等の問題があるからである。そこ
で、ワークメモリCの走査によって検出した始点と終点
の部分の枠線パターンとその反転パターンをワークメモ
リa、bから読み取り、妥当な始点と終点を確定する。
Next, for each line (for example, a vertical line) that is a unit of shading processing, a shading pattern is drawn in the display memory by making a run in the work memory C, but the starting and ending points are not always appropriate. It may not be. This is because in the case of circular shapes, etc., the start and end point patterns are drawn by tracing the frame line in a certain direction, so the positions of the start and end points may shift up and down, and the frame line is a continuous line (solid line). ), the two innermost points of the intersection of the frame line pattern and each line can be used as the start and end points, whereas if the frame line is a discontinuous line such as a broken line, the part where the line is This is the same as in the case of a solid line, but there are problems such as the center of the inverted pattern of the frame line must be set as the starting point or ending point in a portion without a line. Therefore, the frame line pattern of the start point and end point portion detected by scanning the work memory C and its inverted pattern are read from the work memories a and b, and appropriate start and end points are determined.

このようにして確定した始点と終点の間につし1て、表
示メモリ上にシェーディングパターンを描く。以上の処
理を繰り返すことにより、シェーディング図形を表示メ
モリに得る。
A shading pattern is drawn on the display memory between the start point and end point determined in this way. By repeating the above processing, a shading figure is obtained in the display memory.

」二連のシェーディング処理方式は高速処理がiJ能で
あるが、ワークメモリを3面も必要とするという欠点が
ある。なお、枠線パターンタ表示メモリと別にワークメ
モリaに描くのは、表示メモリには枠線以外の文字等の
パターンも存在することが多く、表示メモリ上の枠線パ
ターンを始、終点の確定に利用するのは好ましくないか
らである。
Although the dual shading processing method is capable of high-speed processing, it has the disadvantage of requiring three levels of work memory. Note that the reason why the frame line pattern is drawn in work memory a separately from the display memory is because the display memory often contains patterns such as characters other than frame lines, and the frame line pattern on the display memory is used to determine the starting and ending points. This is because it is not desirable to use it for

〔発明の目的〕[Purpose of the invention]

本発明の目的は、ワークメモリを削−減できるシェーデ
ィング処理方式を提供することにある。
An object of the present invention is to provide a shading processing method that can reduce work memory.

〔発明の概要〕[Summary of the invention]

本発明のシェーディング処理方式は、ワークメモリを1
面だし)用いて処理を実行するものであり、まず枠情報
に従って枠線パターンを表示メモリ上に描き、シェープ
インクの始点と終点のパターンをワークメモリー1−に
描き、次にワークメモリ上において対を成す始点と終点
の間にシェーディングパターンを描いた後、このシェー
ディングパターンにワークメ干り」二において枠情報に
従って必要な修正を施し、この修正後のシェーディング
パターンを表示メ[りに書き込むことを特徴とするもの
である。
The shading processing method of the present invention reduces the work memory to 1
First, the frame line pattern is drawn on the display memory according to the frame information, the pattern of the start and end points of the shape ink is drawn on the work memory 1-, and then the corresponding pattern is drawn on the work memory. After drawing a shading pattern between the starting point and the ending point forming the shading pattern, necessary corrections are made to this shading pattern according to the frame information in the work menu, and the corrected shading pattern is written on the display screen. That is.

〔発明の実施例〕[Embodiments of the invention]

図面を参照し、本発明の実施例につき以下に説明する。 Embodiments of the present invention will be described below with reference to the drawings.

第1図は本発明の一実施例を示す概略ブロック図である
。 この図において、101は図形処理コマンドバッフ
ァ、1.02は図形プロセッサ、103はワークメモリ
、104は表示メモリ、10・5は枠情報メモリ、10
6は表示装置である。
FIG. 1 is a schematic block diagram showing one embodiment of the present invention. In this figure, 101 is a graphics processing command buffer, 1.02 is a graphics processor, 103 is a work memory, 104 is a display memory, 10.5 is a frame information memory, 10
6 is a display device.

第2図は図形プロセッサ102によるシェーディング処
理の流れを示すフローチャー1−である。
FIG. 2 is a flowchart 1- showing the flow of shading processing by the graphic processor 102.

この図に従って、シェーディング処理の内容を説明する
The details of the shading process will be explained according to this figure.

まず、図形プロセッサ102は図形処理コマンドバッフ
ァ101から一つのコマンドを読み込み(■)、そのコ
マンドがシェーディング開始コマンドであるか判定する
(■)。判定結果がNoならば、そのコマンドは枠情報
コマンドであるから。
First, the graphic processor 102 reads one command from the graphic processing command buffer 101 (■), and determines whether the command is a shading start command (■). If the determination result is No, the command is a frame information command.

図形プロセッサ102はその枠情報に従って、枠線のパ
ターンを表示メモリ104上に描き(■)、シェーディ
ングの始点と終点のパターンをワークメモリ103上に
描き(■)、枠情報(コード情報)を105に格納しく
■)、ステップ■へ戻り、次のコマンドを読み込む。
In accordance with the frame information, the graphic processor 102 draws a frame line pattern on the display memory 104 (■), draws a shading start point and end point pattern on the work memory 103 (■), and writes the frame information (code information) in the display memory 104 (■). ■), return to step ■, and read the next command.

シェーディング開始コマンドを読み込み、ステップ■の
判定結果がYESとなった場合、図形プロセッサ102
は実際のシェーディング処理を開始する。この処理は、
シェーディングすべき図形を横切るライン毎に行われる
If the shading start command is read and the determination result in step ■ is YES, the graphic processor 102
starts the actual shading process. This process is
This is done for each line that crosses the figure to be shaded.

まず図形プロセッサ102は1木目のラインについてワ
ークメモリ103を走査し、始、終点パターンを最初に
検出した位置を始点、最後に検出した位置を終点とし、
この始、終点間についてワークメモリ1.03 J二に
シェーディングパターンを描く(■)。図形プロセッサ
102は枠情報メモリ105から枠情報を読み込み(■
)、この枠情報から枠線の有無を判定しく■)、枠線が
ない場合は枠情報から当該ラインにおける枠線パターン
の中央点に相当する2点を算出し、その2点(修正され
た始点と終点)までワークメモリ103」二に描かれた
シェープインクパターンを延長する(■)。枠線がある
場合、図形プロセッサ102は当該ラインの位置に枠線
パターンがあるか判定しく■)、なければステップ0を
実行してシェープインクパターンの延長を行い、枠線パ
ターンがあるときは、ワークメモリ103に描かれたシ
ェーディングパターンの枠線パターンと重なる部分を消
去する(4!I))。
First, the graphic processor 102 scans the work memory 103 for the first grain line, and sets the position where the start and end point patterns are first detected as the start point, and the position where the last point pattern is detected as the end point.
Draw a shading pattern in work memory 1.03 J2 between the start and end points (■). The graphic processor 102 reads frame information from the frame information memory 105 (■
), determine the presence or absence of a frame line from this frame information■), and if there is no frame line, calculate two points corresponding to the center point of the frame line pattern on the relevant line from the frame information, and calculate the two points (corrected The shape ink pattern drawn in the work memory 103 is extended to the starting point and ending point (■). If there is a frame line, the graphic processor 102 determines whether there is a frame line pattern at the position of the line (■); if not, executes step 0 to extend the shape ink pattern, and if there is a frame line pattern, The portion of the shading pattern drawn in the work memory 103 that overlaps with the frame line pattern is erased (4!I)).

図形プロセッサ102は最後のラインまで上記の処理を
行ったか判定しく■)、未処理のラインが残っている場
合はステップ■に戻り次のラインの処理を開始し、終わ
りならば、ワークメモリ103に得られたシェーディン
グパターンと表示メモリ104上のパターンの論理和を
め、そわを表示メモリ104に書は込む(0)。
The graphic processor 102 determines whether the above processing has been performed up to the last line (■), and if there are unprocessed lines remaining, it returns to step ■ and starts processing the next line. The obtained shading pattern and the pattern on the display memory 104 are logically summed, and the shading pattern is written in the display memory 104 (0).

第3図は、ステップ■において始点と終点を選ぶ方法を
真理値表形式で示している。点P、と点P、−1のX方
向の変位ΔX、−,,およびP、と点Pi++の方向の
変位ΔX、の条件によって、点P、を始点または終点と
するか判定される。1と表記されたP、は始点または終
点として選択され、0と表記された点P、は選択されな
い。
FIG. 3 shows the method for selecting the starting point and ending point in step (2) in the form of a truth table. It is determined whether the point P is to be the starting point or the ending point according to the conditions of the displacement ΔX in the X direction of the point P and the point P, -1, -, and the displacement ΔX in the direction of P and the point Pi++. A point P denoted as 1 is selected as a starting point or an end point, and a point P denoted as 0 is not selected.

なお、枠線のない場合(但し、枠線に相当するシェーデ
ィング範囲は枠情報で指定される)、ステップ■では表
示メモリ104に何も書き込まない。枠情報メモリ10
5は独立したメモリでなくてもよく、たとえばワークメ
モリ+03または表示メモリ104の空きエリアを用い
てりよい。また、ステップ[相]等の処理はハードウェ
アで実行してもよい。
Note that if there is no frame line (however, the shading range corresponding to the frame line is specified by the frame information), nothing is written to the display memory 104 in step (3). Frame information memory 10
5 does not need to be an independent memory; for example, an empty area of the work memory +03 or the display memory 104 may be used. Moreover, processing such as step [phase] may be executed by hardware.

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

以上詳述した如く、本発明によれば、シェーディング処
理に従来3面必要であったワークメモリが1面で間に合
うようになり、シェーディング処理のためのハードウェ
アコストを大幅に削減できるという効果を得られる。
As described in detail above, according to the present invention, the work memory that conventionally required three areas can be used for shading processing, but now only one area can be used, and the hardware cost for shading processing can be significantly reduced. It will be done.

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

第1図は本発明の一実施例を示す概略ブロック図、第2
図は1゛ス1形プロセツサによるシェープインク処理の
流れずで示すフローチャート、第3図はシェープインク
の始点と終点の選択方法の説明図である 1、 01・・図形% 理コマンドバッファ、102・
・・図形プロセッサ、1.03・・・ワークメモリ、1
04・・・表示メモリ、105・・枠情報メモリ。 第1図 第3図 第2図
FIG. 1 is a schematic block diagram showing one embodiment of the present invention, and FIG.
The figure is a flowchart showing the flow of shape ink processing by the 1.1 type processor, and Figure 3 is an explanatory diagram of how to select the start and end points of shape ink.
...Graphic processor, 1.03...Work memory, 1
04... Display memory, 105... Frame information memory. Figure 1 Figure 3 Figure 2

Claims (1)

【特許請求の範囲】[Claims] (1)枠情報に従って枠線のパターンとシェーディング
の始点および終点のパターンを表示メモリ上とワークメ
モリ上にそれぞれ描き、該ワークメモリ上において対を
成す始点と終点の間にシェーディングパターンを描いた
後、該シェーディングパターンに該ワークメモリ上にお
いて該枠情報に従って必要な修正を施し、該修正後のシ
ェーディングパターンを該表示メモリに書き込むことを
特徴とするシェーディング処理方式。
(1) After drawing a frame line pattern and shading start and end point patterns on the display memory and work memory, respectively, according to the frame information, and drawing a shading pattern between the paired start and end points on the work memory. , a shading processing method characterized in that the shading pattern is subjected to necessary modification on the work memory according to the frame information, and the modified shading pattern is written to the display memory.
JP58207406A 1983-11-07 1983-11-07 Shading system Pending JPS60100266A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP58207406A JPS60100266A (en) 1983-11-07 1983-11-07 Shading system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP58207406A JPS60100266A (en) 1983-11-07 1983-11-07 Shading system

Publications (1)

Publication Number Publication Date
JPS60100266A true JPS60100266A (en) 1985-06-04

Family

ID=16539207

Family Applications (1)

Application Number Title Priority Date Filing Date
JP58207406A Pending JPS60100266A (en) 1983-11-07 1983-11-07 Shading system

Country Status (1)

Country Link
JP (1) JPS60100266A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6413589A (en) * 1987-07-08 1989-01-18 Mitsubishi Electric Corp Graphic display device

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS6413589A (en) * 1987-07-08 1989-01-18 Mitsubishi Electric Corp Graphic display device

Similar Documents

Publication Publication Date Title
US6731291B2 (en) Image processing device and system using the same
KR950001544A (en) Draw processor for high performance 3D graphics accelerators
JP2631946B2 (en) Knit design system
TW509879B (en) Method and apparatus for minimizing the idle time of a graphics engine by using rendering control before flipping frame buffer
JPH06309395A (en) Picture preparing device
JPS6327983A (en) Rotating graphic form generating device
JPH09259290A (en) Drawing method
JPS60100266A (en) Shading system
JPH01276380A (en) Picture processor
JP2773127B2 (en) Image editing method
JPH08272994A (en) Device and method for information processing
JP2768370B2 (en) Drawing method
JPH03209499A (en) Forming method for outline font and drawing device for the same
JPH0991451A (en) Image edit device
JP3139805B2 (en) Image processing method and apparatus
JPH05225354A (en) Method and device for three-dimensional graphic display processing and graphic display method
JP2782904B2 (en) Polygon fill method
JP2783090B2 (en) Drawing method
JP2000298729A (en) Two-dimensional image generation device
JP3407310B2 (en) Ruled line output method and ruled line output device
JP2956692B1 (en) Graphics display device
JPS62200475A (en) Closed area coloring system for graphic
JPS6136787A (en) Character pattern generation processing system
JPS63218993A (en) Character/graphics expander
JPH0695645A (en) Method for processing character shadowing in full dot character