JPH09305792A - Hidden surface processing method - Google Patents

Hidden surface processing method

Info

Publication number
JPH09305792A
JPH09305792A JP8148387A JP14838796A JPH09305792A JP H09305792 A JPH09305792 A JP H09305792A JP 8148387 A JP8148387 A JP 8148387A JP 14838796 A JP14838796 A JP 14838796A JP H09305792 A JPH09305792 A JP H09305792A
Authority
JP
Japan
Prior art keywords
buffer
display
processing
hidden surface
polygon
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.)
Abandoned
Application number
JP8148387A
Other languages
Japanese (ja)
Inventor
Mutsuhiro Omori
睦弘 大森
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.)
Sony Corp
Original Assignee
Sony 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 Sony Corp filed Critical Sony Corp
Priority to JP8148387A priority Critical patent/JPH09305792A/en
Publication of JPH09305792A publication Critical patent/JPH09305792A/en
Abandoned legal-status Critical Current

Links

Landscapes

  • Image Generation (AREA)

Abstract

PROBLEM TO BE SOLVED: To easily and surely perform the hidden surface processing by selecting successively the objects at the forward side of a visual point in a prescribed range based on the Z coordinate value representing every object and forming a display image based on the Z coordinate value of every image. SOLUTION: A Z sort processing circuit 3 decreases the processing objects and also performs the hidden surface processing to the rectangular areas which are successively inputted at the forward side of a visual point by a Z buffer method. Under such conditions, the rectangular areas which are not necessary for display are excluded from the processing objects in the circuit 3. Accordingly, the access frequency of memory interface 6 is reduced to a display buffer 7 and a Z buffer 8. At the same time, the vertex data on the rectangular areas are successively outputted at the forward side of the visual point. As a result, the image data are stored in the buffer 7 in the order of higher possibility of display.

Description

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

【0001】[0001]

【発明の属する技術分野】本発明は、隠面処理方法に関
し、例えばグラフィックス描画装置に適用して、各オブ
ジェクトを代表するZ座標値を基準にして、所定の範囲
で、視点に対して手前側のオブジェクトを順次選択し、
各画素のZ座標値を基準にして表示画像を形成すること
により、簡易かつ確実に隠面処理できるようにする。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a hidden surface processing method, which is applied to, for example, a graphics drawing device, and a Z coordinate value representing each object is used as a reference in a predetermined range in front of a viewpoint. Side by side select objects,
By forming the display image based on the Z coordinate value of each pixel, the hidden surface processing can be performed easily and reliably.

【0002】[0002]

【従来の技術】従来、グラフィックス描画装置において
は、いわゆるZソート法又はZバッファ法による隠面処
理により、例えばポリゴンにより表現される3次元オブ
ジェクトを表示するようになされている。
2. Description of the Related Art Conventionally, in a graphics drawing device, a three-dimensional object represented by, for example, a polygon is displayed by a hidden surface process by the so-called Z sort method or Z buffer method.

【0003】すなわちZソート法によるグラフィックス
描画装置において、例えば複数のポリゴンを処理する場
合、各ポリゴンを代表する代表点のZ座標値を基準にし
てこれら複数のポリゴンをソートし、視点に対して奥に
位置するポリゴンより、順次ディスプレイバッファの内
容を更新する。これによりZソート法によるグラフィッ
クス描画装置は、奥に表示される画像の上から、手前側
の画像を順次描画して表示画像を形成する。
That is, in the case of processing a plurality of polygons in a graphics drawing apparatus using the Z sort method, the plurality of polygons are sorted based on the Z coordinate value of a representative point representing each polygon, and the polygons are sorted with respect to the viewpoint. The contents of the display buffer are sequentially updated from the polygon located at the back. As a result, the graphics drawing device by the Z sort method sequentially draws the image on the front side from the image displayed in the back to form a display image.

【0004】すなわち図2に示すように、長方形形状、
円形形状、三角形形状のポリゴンP1、P2、P3を奥
から順に配置する場合、このZソート法のグラフィック
ス描画装置においては、始めに長方形形状のポリゴンP
1を選択し、このポリゴンP1の画像データをディスプ
レイバッファに格納する(図2(A))。続いて、この
ポリゴンP1の手前に位置する円形形状のポリゴンP2
を選択し、このポリゴンP2によりディスプレイバッフ
ァの内容を更新し、ポリゴンP1にポリゴンP2を重ね
てなる画像を形成する(図2(B))。さらに最も手前
に位置する三角形形状のポリゴンP3を選択し、このポ
リゴンP3によりディスプレイバッファの内容を更新
し、ポリゴンP1、P2、P3を順次重ねてなる画像を
形成する(図2(C))。
That is, as shown in FIG. 2, a rectangular shape,
When arranging circular-shaped and triangular-shaped polygons P1, P2, and P3 in order from the back, in the graphics drawing device of the Z sort method, first, the rectangular-shaped polygon P
1 is selected and the image data of this polygon P1 is stored in the display buffer (FIG. 2 (A)). Then, a circular polygon P2 located in front of this polygon P1
Is selected, the contents of the display buffer are updated with this polygon P2, and an image in which the polygon P2 is superimposed on the polygon P1 is formed (FIG. 2B). Further, the triangle-shaped polygon P3 located closest to the front is selected, the contents of the display buffer are updated by this polygon P3, and an image in which the polygons P1, P2, and P3 are sequentially overlapped is formed (FIG. 2C).

【0005】これに対してZバッファ法によるグラフィ
ックス描画装置においては、ディスプレイバッファに加
えて別途Zバッファを配置し、ディスプレイバッファに
格納した各画像データのZ座標値をこのZバッファに保
持する。さらにこのZバッファ法によるグラフィックス
描画装置においては、新たに描画する画像データについ
ては、このZバッファのZ座標値との比較結果により手
前側の画像データについてのみディスプレイバッファ及
びZバッファの内容を更新して表示する。
On the other hand, in a graphics drawing apparatus using the Z buffer method, a Z buffer is separately arranged in addition to the display buffer, and the Z coordinate value of each image data stored in the display buffer is held in this Z buffer. Further, in the graphics drawing apparatus using the Z buffer method, for the image data to be newly drawn, the contents of the display buffer and the Z buffer are updated only for the front side image data according to the comparison result with the Z coordinate value of the Z buffer. And display it.

【0006】すなわち図3に示すように、このグラフィ
ックス描画装置は、Z座標値がそれぞれ値R、C、Tの
ポリゴンP1、P2、P3を表示する際に、始めに最も
奥に位置するポリゴンP1を処理する場合、ディスプレ
イバッファMG及びZバッファMZにこのポリゴンP1
の画像データとZ座標値をそれぞれ格納する(図3
(A))。
That is, as shown in FIG. 3, in this graphics drawing apparatus, when displaying polygons P1, P2, and P3 whose Z coordinate values are values R, C, and T, the polygon located at the innermost position at the beginning is displayed. When processing P1, the polygon P1 is stored in the display buffer MG and the Z buffer MZ.
The image data and the Z coordinate value are stored respectively (see FIG. 3).
(A)).

【0007】続いて手前に位置するポリゴンP2を処理
する場合、このグラフィックス描画装置は、Zバッファ
MZに格納されたZ座標値との比較結果によりポリゴン
P1及びP2が重なり合う部分については、ポリゴンP
2のZ座標値によりZバッファMZの内容を更新し、ポ
リゴンP2の他の部分についても、この場合ポリゴンP
2のZ座標値をZバッファMZに格納する(図3
(B))。これに対応してポリゴンP1及びP2が重な
り合う部分についてはポリゴンP2の画像データにより
ディスプレイバッファMGの内容を更新し、ポリゴンP
2の他の部分については、このポリゴンP2の画像デー
タをディスプレイバッファMGに格納する。
When processing the polygon P2 located in front of the polygon P2, the graphics drawing apparatus uses the polygon P1 for the portion where the polygons P1 and P2 overlap each other according to the result of comparison with the Z coordinate value stored in the Z buffer MZ.
The content of the Z buffer MZ is updated with the Z coordinate value of 2 and the polygon P2 is also updated in this case for other parts of the polygon P2.
The Z coordinate value of 2 is stored in the Z buffer MZ (see FIG. 3).
(B)). Correspondingly, for the portion where the polygons P1 and P2 overlap, the contents of the display buffer MG are updated with the image data of the polygon P2,
For the other part of 2, the image data of the polygon P2 is stored in the display buffer MG.

【0008】さらに最も手前のポリゴンP3を処理する
場合、このグラフィックス描画装置は、同様に、Zバッ
ファMZに格納されたZ座標値との比較結果によりポリ
ゴンP2及びP3が重なり合う部分については、ポリゴ
ンP3のZ座標値によりZバッファMZの内容を更新
し、ポリゴンP3の他の部分については、この場合ポリ
ゴンP3のZ座標値をZバッファMZに格納する(図3
(C))。これに対応してポリゴンP2及びP3が重な
り合う部分についてはポリゴンP3の画像データにより
ディスプレイバッファMGの内容を更新し、ポリゴンP
3の他の部分については、このポリゴンP3の画像デー
タをディスプレイバッファMGに格納する。
In the case of further processing the foremost polygon P3, this graphics drawing apparatus similarly regards a portion where the polygons P2 and P3 overlap each other as a result of comparison with the Z coordinate value stored in the Z buffer MZ. The contents of the Z buffer MZ are updated with the Z coordinate value of P3, and in other parts of the polygon P3, the Z coordinate value of the polygon P3 is stored in the Z buffer MZ in this case (see FIG. 3).
(C)). Correspondingly, for the portion where the polygons P2 and P3 overlap, the contents of the display buffer MG are updated with the image data of the polygon P3, and the polygon P3 is updated.
The image data of the polygon P3 is stored in the display buffer MG with respect to the other portions of No. 3.

【0009】[0009]

【発明が解決しようとする課題】ところでZソート法に
よる隠面処理においては、ポリゴン数が増大するとその
分ソートの負担が増大し、処理に時間を要する問題があ
る。また図4に示すように、ポリゴンP1及びP2が交
差するような場合には、この交差する境界を違和感なく
表示することが困難になる問題もある。さらに奥に位置
するポリゴンより順次ディスプレイバッファの内容を更
新することにより、表示に供しない画像データについて
も、ディスプレイバッファに無駄に書き込む問題もあ
る。
By the way, in the hidden surface processing by the Z sort method, there is a problem that the load of sorting increases as the number of polygons increases, and the processing takes time. Further, as shown in FIG. 4, when the polygons P1 and P2 intersect each other, there is a problem that it becomes difficult to display the intersecting boundary without a sense of discomfort. Further, by updating the contents of the display buffer sequentially from the polygons located in the back, there is also a problem that image data not used for display is unnecessarily written in the display buffer.

【0010】これに対してZバッファ法による隠面処理
においては、画素を単位にしてディスプレイバッファの
内容を更新することにより、ポリゴンが交差するような
場合についても、確実に隠面処理することができる。す
なわち図4の場合は、各画素のZ座標値が値5でなる菱
形形状のポリゴンP1(図4(A))と、斜めに傾いて
画像データのZ座標値が値8から値2でなる平行四辺形
形状のポリゴンP2(図4(B))とが交差している場
合であり、Zバッファ法によれば、交差する境界を違和
感なく表示することができる。
On the other hand, in the hidden surface processing by the Z buffer method, the hidden surface processing can be reliably performed even in the case where polygons intersect by updating the contents of the display buffer in units of pixels. it can. That is, in the case of FIG. 4, the rhombus-shaped polygon P1 (FIG. 4A) in which the Z coordinate value of each pixel is the value 5 and the Z coordinate value of the image data that is obliquely inclined is from the value 8 to the value 2. This is a case where the parallelogram-shaped polygon P2 (FIG. 4B) intersects, and the Z buffer method can display the intersecting boundary without a sense of discomfort.

【0011】ところがZバッファ法による隠面処理にお
いても、ポリゴンの選択順序によっては、表示に供しな
い画像データをディスプレイバッファに無駄に書き込む
ことになる。すなわち奥に配置されたポリゴンを処理し
た後、手前のポリゴンを処理する場合、結局奥に配置さ
れたポリゴンについては、ディスプレイバッファ及びZ
バッファを無駄に書き込み処理することになる。またそ
の分メモリに格納したZ座標値を無駄にアクセスする問
題もある。
However, even in the hidden surface processing by the Z-buffer method, the image data not to be displayed is unnecessarily written in the display buffer depending on the selection order of polygons. That is, when processing the polygons arranged in the back and then processing the polygons in the front, as for the polygons arranged in the back, the display buffer and Z
The buffer is wastefully written. Further, there is a problem that the Z coordinate value stored in the memory is wastefully accessed.

【0012】本発明は以上の点を考慮してなされたもの
で、簡易かつ確実に隠面処理することができる隠面処理
方法を提案しようとするものである。
The present invention has been made in consideration of the above points, and it is an object of the present invention to propose a hidden surface treatment method capable of easily and surely performing hidden surface treatment.

【0013】[0013]

【課題を解決するための手段】かかる課題を解決するた
め本発明においては、各オブジェクトを代表するZ座標
値を比較して、所定範囲内で、視点に対して手前側のオ
ブジェクトを複数のオブジェクトより順次選択した後、
これらのオブジェクトについて、各画素のZ座標値を順
次比較して表示画像を形成する。
In order to solve such a problem, in the present invention, the Z coordinate values representing each object are compared and a plurality of objects in front of the viewpoint within a predetermined range are compared. After selecting more sequentially,
For these objects, the display image is formed by sequentially comparing the Z coordinate values of each pixel.

【0014】各オブジェクトを代表するZ座標値を比較
して、所定範囲内で、視点に対して手前側のオブジェク
トを複数のオブジェクトより順次選択すれば、その分全
てのオブジェクトをZソートする場合に比して簡易に不
必要なオブジェクトを処理対象より除去することができ
る。従って、続いて各画素のZ座標値を順次比較する処
理においては、不必要なオブジェクトが省略されること
になる。これによりその分簡易に隠面処理することがで
きる。
When the Z-coordinate values representing each object are compared and the object on the front side with respect to the viewpoint is sequentially selected from a plurality of objects within a predetermined range, when all objects are Z-sorted by that amount. In comparison, unnecessary objects can be easily removed from the processing target. Therefore, in the process of successively comparing the Z coordinate values of the respective pixels, unnecessary objects are omitted. As a result, the hidden surface can be easily processed.

【0015】また各画素のZ座標値を順次比較して表示
画像を形成することにより、ポリゴンが交差するような
場合についても、確実に隠面処理することができる。ま
た視点に対して手前側のオブジェクトより、順次選択し
て各画素のZ座標値を比較することにより、表示に必要
な画素より順次処理することになり、ビデオメモリに対
する無駄な書き込み処理を省略することもできる。
Further, by sequentially comparing the Z coordinate values of the respective pixels to form a display image, it is possible to surely perform the hidden surface processing even when the polygons intersect each other. Further, by sequentially selecting from the object on the front side with respect to the viewpoint and comparing the Z coordinate values of the respective pixels, it is possible to sequentially process the pixels required for display, thereby omitting unnecessary writing processing to the video memory. You can also

【0016】[0016]

【発明の実施の形態】以下、適宜図面を参照しながら本
発明の実施の形態を詳述する。
Embodiments of the present invention will be described below in detail with reference to the drawings.

【0017】図1は、本発明の実施の形態に係るグラフ
ィックス描画装置を示すブロック図である。ここでこの
種のグラフィックス描画装置1では、3次元オブジェク
トでなるポリゴンの表面に対して、コンピュータにより
マトリックス状に代表点を設定し、各代表点により透視
変換法を適用した演算処理を実行する。さらに隣接する
各代表点により各ポリゴンを順次三角形領域に切り出す
ように、各三角形領域の頂点に対応する代表点データを
メインメモリ2に記録する。これによりグラフィックス
描画装置1では、各ポリゴンについて、これら代表点間
の補間演算処理により画像データを生成する。かくする
につき、メインメモリ2は、このコンピュータのメイン
メモリで、各代表点の座標データX、Y、Z、赤色、緑
色、青色の輝度値R、G、Bを、各三角形領域毎に記録
する(以下この三角形領域の代表点のデータを頂点デー
タと呼ぶ)。
FIG. 1 is a block diagram showing a graphics drawing device according to an embodiment of the present invention. Here, in this type of graphics drawing device 1, representative points are set in a matrix by a computer on the surface of a polygon which is a three-dimensional object, and the arithmetic processing applying the perspective transformation method is executed by each representative point. . Further, representative point data corresponding to the vertices of each triangular area is recorded in the main memory 2 so that each polygon is sequentially cut out into triangular areas by adjacent representative points. As a result, the graphics drawing apparatus 1 generates image data for each polygon by performing interpolation calculation processing between these representative points. In doing so, the main memory 2 is the main memory of this computer and records the coordinate data X, Y, Z, red, green, and blue luminance values R, G, B of each representative point for each triangular area. (Hereinafter, the data of the representative points of this triangular area are called the vertex data).

【0018】Zソート処理回路3は、メインメモリ2に
記録された頂点データを検索し、視点に対して最も手前
側に位置する三角形領域を選択し、この三角形領域の頂
点データを続く初期値演算回路4に出力する。続いてZ
ソート処理回路3は、この三角形領域を検索対象より除
外して、残る三角形領域の頂点データを検索し、続いて
視点に対して手前側に位置する三角形領域の頂点データ
を初期値演算回路4に出力する。このようにしてZソー
ト処理回路3は、視点に対して最も手前側に位置する三
角形領域より、順次、頂点データを選択して初期値演算
回路4に出力し、各三角形領域の残り数が、検索開始時
の1/2になると、この検索の処理を終了する。
The Z sort processing circuit 3 searches the vertex data recorded in the main memory 2, selects the triangle area closest to the viewpoint, and calculates the initial value of the vertex data of this triangle area. Output to circuit 4. Then Z
The sort processing circuit 3 excludes this triangular area from the search target, searches for the vertex data of the remaining triangular area, and then sets the vertex data of the triangular area located in front of the viewpoint to the initial value calculation circuit 4. Output. In this way, the Z sort processing circuit 3 sequentially selects the vertex data from the triangular area located closest to the viewpoint and outputs the selected vertex data to the initial value calculation circuit 4, and the remaining number of each triangular area becomes When the search starts at 1/2, the search process ends.

【0019】これによりZソート処理回路3は、メイン
メモリ2に記録された三角形領域について、視点に対し
て手前側より、三角形領域の数にして1/2の範囲で、
順次頂点データを選択し、例えば実際には描画の必要の
ない裏側に存在するような三角形領域については、続く
処理対象より除外する。また透視変換法により視点に対
して遠くに存在し、殆ど表示する必要のない小さな三角
形領域についても、同様に続く処理対象より除外する。
As a result, the Z sort processing circuit 3 sets the triangular area recorded in the main memory 2 in the range of 1/2 of the triangular area from the front side with respect to the viewpoint.
The vertex data is sequentially selected, and, for example, a triangular area that does not actually need to be drawn and exists on the back side is excluded from the subsequent processing targets. In addition, a small triangular area that exists far from the viewpoint and that is hardly required to be displayed by the perspective transformation method is also excluded from the subsequent processing targets.

【0020】初期値演算回路4は、このようにしてZソ
ート処理回路3より出力される三角形領域の頂点データ
より、続く補間演算処理回路5の補間演算処理に必要な
初期値を計算する。ここで補間演算処理回路5は、DD
A(Digital Differential Anarizer )演算による線型
補間により、三角形領域内の座標値X、Yをパラメータ
にしたZ座標値、輝度値R、G、Bを演算する。このた
め初期値演算回路4は、Y座標値を順次切り換えて、三
角形領域両端の座標値X、Z、輝度値R、G、Bの各変
化分のデータを計算し、これらのデータを初期値のデー
タとして補間演算処理回路5に出力する。補間演算処理
回路5は、X座標値を順次切り換えて、この初期値のデ
ータを巡回加算処理することにより線型補間処理し、上
述した三角形領域のデータを生成する。これにより初期
値演算回路4及び補間演算処理回路5は、各三角形領域
の画像データ(R、G、B)、Z座標値のデータを各X
Y座標値毎に生成して出力する。
The initial value calculation circuit 4 calculates the initial value required for the interpolation calculation processing of the subsequent interpolation calculation processing circuit 5 from the vertex data of the triangular area thus output from the Z sort processing circuit 3. Here, the interpolation calculation processing circuit 5 is
By linear interpolation by A (Digital Differential Anarizer) calculation, Z coordinate values and brightness values R, G, B using the coordinate values X, Y in the triangular area as parameters are calculated. Therefore, the initial value calculation circuit 4 sequentially switches the Y coordinate values, calculates data for each change in the coordinate values X, Z, and the brightness values R, G, B at both ends of the triangular area, and uses these data as the initial values. Is output to the interpolation calculation processing circuit 5. The interpolation calculation processing circuit 5 sequentially switches the X coordinate values, performs linear interpolation processing by performing cyclic addition processing on the data of this initial value, and generates the above-mentioned triangular area data. As a result, the initial value calculation circuit 4 and the interpolation calculation processing circuit 5 convert the image data (R, G, B) of each triangular area and the data of the Z coordinate value into each X.
Generate and output for each Y coordinate value.

【0021】メモリインターフェース6は、この補間演
算処理回路5より出力される輝度値R、G、Bをディス
プレイバッファ7に格納すると共に、対応するZ座標値
をZバッファ8に格納する。このときメモリインターフ
ェース6は、Z座標値を基準にしてディスプレイバッフ
ァ7及びZバッファ8への格納処理を中止することによ
りZバッファ法を適用した隠面処理を実行する。すなわ
ちメモリインターフェース6は、補間演算処理回路5よ
り入力されるXY座標値を基準にして、Zバッファ8よ
り対応するZ座標値をロードし、このZ座標値を内蔵の
Z値比較回路10に入力する。
The memory interface 6 stores the brightness values R, G, B output from the interpolation calculation processing circuit 5 in the display buffer 7 and the corresponding Z coordinate values in the Z buffer 8. At this time, the memory interface 6 executes the hidden surface processing to which the Z buffer method is applied by stopping the storage processing in the display buffer 7 and the Z buffer 8 based on the Z coordinate value. That is, the memory interface 6 loads the corresponding Z coordinate value from the Z buffer 8 based on the XY coordinate value input from the interpolation calculation processing circuit 5, and inputs this Z coordinate value to the built-in Z value comparison circuit 10. To do.

【0022】Z値比較回路10は、補間演算処理回路5
より入力されるZ座標値と、Zバッファ8よりロードし
たZ座標値を比較することにより、ディスプレイバッフ
ァ7に格納された画像データと、補間演算処理回路5よ
り出力される画像データとの間で、何れの画像データが
手前側に存在するか判断する。ここで補間演算処理回路
5より出力される画像データの方が手前に存在するとの
比較結果が得られた場合、メモリインターフェース6
は、ディスプレイバッファ7にこの画像データR、G、
Bを格納してディスプレイバッファ7の内容を更新す
る。また対応する画像データのZ座標値をZバッファ8
に格納する。これに対してディスプレイバッファ7に格
納された画像データの方が手前に存在するとの比較結果
が得られた場合、ディスプレイバッファ7への格納を中
止する。
The Z value comparison circuit 10 includes an interpolation calculation processing circuit 5.
By comparing the Z coordinate value input from the Z buffer with the Z coordinate value loaded from the Z buffer 8, the image data stored in the display buffer 7 and the image data output from the interpolation calculation processing circuit 5 are compared. , Which image data exists on the near side. Here, when the comparison result that the image data output from the interpolation calculation processing circuit 5 is present on the front side is obtained, the memory interface 6
Display image data R, G,
B is stored and the contents of the display buffer 7 are updated. In addition, the Z coordinate value of the corresponding image data is set to the Z buffer 8
To be stored. On the other hand, when the comparison result that the image data stored in the display buffer 7 is present on the front side is obtained, the storage in the display buffer 7 is stopped.

【0023】これによりメモリインターフェース6は、
図4について上述したような、Z座標値が値5に設定さ
れた菱形形状のポリゴンP1(図4(A))と、斜めに
傾いたZ座標値が値8から値1の平行四辺形形状のポリ
ゴンP2(図4(B))とを処理する場合、2つのポリ
ゴンP1及びP2で共通する値5のZ座標値を境界にし
て、これらポリゴンP1及びP2を隠面処理してなる画
像データ(図4(C))をディスプレイバッファ7に蓄
積する。
As a result, the memory interface 6 is
As described above with reference to FIG. 4, the diamond-shaped polygon P1 (FIG. 4A) in which the Z coordinate value is set to the value 5 and the parallelogram shape in which the diagonally tilted Z coordinate value is the value 8 to the value 1 Image data obtained by performing hidden surface processing on these polygons P1 and P2 with the Z coordinate value of 5 common to the two polygons P1 and P2 as a boundary when processing the polygon P2 (FIG. 4B). (FIG. 4C) is accumulated in the display buffer 7.

【0024】さらにメモリインターフェース6は、ディ
スプレイコントローラ12からのリクエストに応答して
ディスプレイバッファ7の画像データを所定のブロック
単位でディスプレイコントローラ12に転送する。
Further, the memory interface 6 transfers the image data of the display buffer 7 to the display controller 12 in a predetermined block unit in response to a request from the display controller 12.

【0025】ディスプレイコントローラ12は、このグ
ラフィックス描画装置1に接続されるモニタ装置の水平
垂直同期信号に同期したタイミングで、メモリインター
フェース6に表示アドレスを発行し、画像データの転送
をリクエストする。さらにディスプレイコントローラ1
2は、このリクエストに応答してメモリインターフェー
ス6より転送される画像データを内蔵のバッファメモリ
に保持し、所定周期で続く出力回路13に出力する。
The display controller 12 issues a display address to the memory interface 6 at a timing synchronized with the horizontal and vertical synchronizing signals of the monitor device connected to the graphics drawing device 1 to request the transfer of image data. Further display controller 1
2 holds the image data transferred from the memory interface 6 in the built-in buffer memory in response to this request, and outputs it to the output circuit 13 that follows in a predetermined cycle.

【0026】出力回路13は、この画像データをモニタ
装置の表示に供するディジタル値に変換した後、アナロ
グ信号に変換して出力する。これによりグラフィックス
描画装置1では、種々の3次元画像をモニタ装置に表示
する。
The output circuit 13 converts the image data into a digital value to be displayed on the monitor device, and then converts it into an analog signal for output. As a result, the graphics drawing device 1 displays various three-dimensional images on the monitor device.

【0027】以上の構成において、グラフィックス描画
装置では、3次元オブジェクトでなるポリゴンの表面に
代表点が設定され、これにより隣接する代表点により囲
まれる三角形領域が各ポリゴン上に設定される。これら
代表点は、予めコンピュータによる透視変換法を適用し
た演算処理により、座標値が計算され、これら代表点の
座標値X、Y、Zが、各代表点の輝度値R、G、Bと共
に、各三角形領域毎にメインメモリ2に格納される。
With the above arrangement, in the graphics drawing apparatus, a representative point is set on the surface of a polygon which is a three-dimensional object, whereby a triangular area surrounded by adjacent representative points is set on each polygon. The coordinate values of these representative points are calculated in advance by a calculation process to which a perspective transformation method is applied by a computer, and the coordinate values X, Y, and Z of these representative points are calculated along with the brightness values R, G, and B of the respective representative points. It is stored in the main memory 2 for each triangular area.

【0028】このようにして予めメインメモリに格納さ
れた三角形領域の頂点データは、三角形領域の残り数
が、検索開始時の1/2になるまでの範囲で、Zソート
処理回路3による検索処理により、視点に対して最も手
前側に位置する三角形領域より順次選択されて、続く初
期値演算回路4に出力される。これによりこれら三角形
領域の頂点データは、単なるZソート法による隠面処理
の場合に比して、負担を軽減した簡易な処理により、例
えば実際に描画の必要のない裏側の存在するような三角
形領域、さらには透視変換法により視点に対して遠くに
存在して殆ど表示する必要のない小さな三角形領域等
が、続く処理対象より除外され、表示の可能性の高い視
点側より順に続く初期値演算回路4に出力される。
In this way, the vertex data of the triangular area stored in the main memory in advance is searched for by the Z sort processing circuit 3 within a range in which the number of remaining triangular areas becomes 1/2 of the time when the search is started. Thus, the triangular areas located closest to the viewpoint are sequentially selected and output to the subsequent initial value calculation circuit 4. As a result, the vertex data of these triangular areas can be processed, for example, by a simple process that reduces the burden compared to the case of hidden surface processing by the Z-sort method. In addition, a small triangular area or the like that is distant from the viewpoint and hardly needs to be displayed by the perspective transformation method is excluded from the subsequent processing target, and the initial value calculation circuit continues in order from the viewpoint side with high possibility of display. 4 is output.

【0029】実際上、透視変換法を適用した場合、視点
より奥に存在する三角形領域程、表示される面積が小さ
くなり、手前側の三角形領域ほど面積が大きくなる。こ
れによりこの実施の形態のように、検索開始時の1/2
になるまでの範囲で、順次手前側の三角形領域より出力
して実用上十分な範囲で、表示に不必要な三角形領域を
処理対象より除外することができる。なおこのように表
示の可能性の高い視点側より順に続く初期値演算回路4
に出力すれば、処理時間の都合で、Zソート処理回路3
における処理を途中で打ち切っても、目立ち易い手前側
のオブジェクトについては表示することができ、その分
表示画像の画質劣化を有効に回避して、時間管理を簡略
化することも可能になる。
In practice, when the perspective transformation method is applied, the displayed area becomes smaller in the triangular area existing farther from the viewpoint and becomes larger in the triangular area on the front side. As a result, as in this embodiment, 1/2 of the time when the search is started
In the range up to, the triangular area on the near side is sequentially output, and the triangular area unnecessary for display can be excluded from the processing target in a practically sufficient range. It should be noted that the initial value calculation circuit 4 continues in this order from the viewpoint side having a high display possibility.
Output to the Z sort processing circuit 3 for processing time convenience.
Even if the processing in (3) is terminated midway, the object on the near side, which is easily noticeable, can be displayed, and the deterioration of the image quality of the displayed image can be effectively avoided by that amount, and the time management can be simplified.

【0030】このようにして初期値演算回路4に出力さ
れた三角形領域の頂点データは、初期値のデータが生成
され、続く補間演算処理回路5において、この初期値の
データにより線型補間の処理が実行され、これにより各
三角形領域のピクセルについて、Z座標値、赤色、緑
色、青色の輝度値R、G、Bが生成される。
In this way, the vertex data of the triangular area output to the initial value calculation circuit 4 is generated as initial value data, and in the subsequent interpolation calculation processing circuit 5, linear interpolation processing is performed using this initial value data. Then, the Z coordinate values, the red, green, and blue luminance values R, G, and B are generated for the pixels in each triangular area.

【0031】これらのデータは、メモリインターフェー
ス6のZ値比較回路10において、Zバッファ8に格納
されたZ値との間で比較処理が実行されることにより、
ディスプレイバッファ7に格納された画像データとの間
で、何れが手前側に存在するか判断され、ディスプレイ
バッファ7に格納された画像データに隠れる画像データ
については続く一連の処理対象より除外される。これと
は逆に、ディスプレイバッファ7に格納された画像デー
タより手前に存在すると判断された場合、このZ座標値
によりZバッファ8の内容が更新され、また赤色、緑
色、青色の輝度値R、G、Bがディスプレイバッファ7
に格納される。
These data are compared with the Z value stored in the Z buffer 8 in the Z value comparison circuit 10 of the memory interface 6, whereby
It is determined which of the image data stored in the display buffer 7 exists on the front side, and the image data hidden in the image data stored in the display buffer 7 is excluded from the subsequent series of processing targets. On the contrary, when it is determined that the image data stored in the display buffer 7 exists before the image data, the contents of the Z buffer 8 are updated by the Z coordinate value, and the red, green, and blue luminance values R, Display buffer 7 for G and B
Stored in.

【0032】これによりZソート処理回路3より、処理
対象を低減して、かつ手前側より順次入力される三角形
領域に対して、Zバッファ法による隠面処理が実行され
る。このときZソート処理回路3において、表示に不必
要な三角形領域が処理対象より除外されることにより、
その分メモリインターフェース6におけるディスプレイ
バッファ7、Zバッファ8へのアクセス頻度が低減さ
れ、無駄な描画が低減される。また視点に対して手前側
より順次三角形領域の頂点データが出力されることによ
り、表示の可能性の高い順序でディスプレイバッファ7
に画像データを格納することになる。従って一旦ディス
プレイバッファ7に格納した画像データについては、従
来のZバッファ法による場合に比して、書き換えの頻度
を各段的に低減でき、その分処理に要する負担を軽減し
て、Z座標値の比較に余った時間を配分することができ
る。さらに交差するポリゴンについては、境界を違和感
なく表示することができる。
As a result, the Z sort processing circuit 3 performs the hidden surface processing by the Z buffer method on the triangular areas which are sequentially input from the front side while reducing the processing targets. At this time, the Z sort processing circuit 3 excludes a triangular area unnecessary for display from the processing target,
The access frequency to the display buffer 7 and the Z buffer 8 in the memory interface 6 is reduced by that amount, and unnecessary drawing is reduced. Further, since the vertex data of the triangular area is sequentially output from the front side with respect to the viewpoint, the display buffer 7 is displayed in the order of high display possibility.
Image data will be stored in. Therefore, with respect to the image data once stored in the display buffer 7, the frequency of rewriting can be reduced stepwise as compared with the case of the conventional Z buffer method, and the load required for processing can be reduced accordingly, and the Z coordinate value can be reduced. It is possible to allocate the time left for comparison. Further, regarding intersecting polygons, the boundaries can be displayed without a sense of discomfort.

【0033】このようにしてディスプレイバッファ7に
格納された画像データは、ディスプレイコントローラ1
2を介して出力回路13に出力され、この出力回路13
を介してモニタ装置に表示される。
The image data stored in the display buffer 7 in this way is displayed by the display controller 1.
2 is output to the output circuit 13 and the output circuit 13
Is displayed on the monitor device via.

【0034】以上の構成によれば、Zソート処理回路3
において、三角形領域の残り数が、検索開始時の1/2
になるまでの範囲で、視点に対して最も手前側に位置す
る三角形領域より順次三角形領域の頂点データを選択し
て出力し、メモリインターフェース6において、Zバッ
ファ法による隠面処理を実行したことにより、表示に不
必要な三角形領域を処理対象より除外してZバッファ法
により隠面処理することができ、その分簡易かつ確実に
隠面処理することができる。
According to the above configuration, the Z sort processing circuit 3
In, the remaining number of triangular areas is 1/2 of the beginning of the search
Up to, the vertex data of the triangular area is sequentially selected from the triangular area located closest to the viewpoint and output, and the hidden surface processing by the Z buffer method is executed in the memory interface 6. The triangular area unnecessary for display can be excluded from the processing target and the hidden surface processing can be performed by the Z buffer method, and the hidden surface processing can be performed simply and surely.

【0035】すなわちZソート処理回路3においては、
三角形領域の残り数が、検索開始時の1/2になるまで
の範囲で検索の処理を実行することにより、三角形領域
の数が増大した場合でも、従来のZソート法による場合
に比して負担を軽減することができる。さらに交差する
ポリゴンについては、境界を違和感なく表示することが
できる。
That is, in the Z sort processing circuit 3,
Even when the number of triangular areas increases by performing the search processing within a range in which the number of remaining triangular areas becomes ½ of that at the start of the search, compared with the case of the conventional Z sort method. The burden can be reduced. Further, regarding intersecting polygons, the boundaries can be displayed without a sense of discomfort.

【0036】また表示に不必要な三角形領域が処理対象
より除外されることにより、その分メモリインターフェ
ース6におけるディスプレイバッファ7、Zバッファ8
へのアクセス頻度が低減され、無駄な描画が低減され
る。また視点に対して手前側より順次三角形領域の頂点
データが出力されることにより、一旦ディスプレイバッ
ファ7に格納した画像データについては、従来のZバッ
ファ法による場合に比して、書き換えの頻度を各段的に
低減でき、その分処理に要する負担を軽減して、Z座標
値の比較に余った時間を配分することができる。
Further, since the triangular area unnecessary for display is excluded from the processing target, the display buffer 7 and the Z buffer 8 in the memory interface 6 are correspondingly removed.
The frequency of access to is reduced, and unnecessary drawing is reduced. Further, since the vertex data of the triangular area is sequentially output from the front side with respect to the viewpoint, the image data once stored in the display buffer 7 has a rewriting frequency higher than that of the conventional Z buffer method. It is possible to reduce the number of steps, and the load required for the processing can be reduced accordingly, and the time remaining for comparison of Z coordinate values can be distributed.

【0037】なお上述の実施の形態においては、Zソー
ト処理回路3において、三角形領域の残り数が、検索開
始時の1/2になるまでの範囲で検索の処理を実行する
場合について述べたが、本発明はこれに限らず、実用上
十分な範囲でこれらの範囲を種々に設定することがで
き、また必要に応じて可変することができる。
In the above embodiment, the case where the Z sort processing circuit 3 executes the search processing within the range in which the number of remaining triangular areas becomes ½ of the search start time has been described. However, the present invention is not limited to this, and these ranges can be variously set within a practically sufficient range, and can be varied as necessary.

【0038】さらに上述の実施の形態においては、頂点
データにより規定される三次元オブジェクトを単に隠面
処理して表示する場合について述べたが、本発明はこれ
に限らず、これに加えて例えばマッピング処理する場合
等に広く適用することができる。
Further, in the above-described embodiment, the case where the three-dimensional object defined by the vertex data is simply subjected to the hidden surface processing and displayed is described, but the present invention is not limited to this, and in addition to this, for example, mapping is performed. It can be widely applied to processing.

【0039】また上述の実施の形態においては、演算処
理回路によりグラフィックス描画装置を構成する場合に
ついて述べたが、本発明はこれに限らず、パーソナルコ
ンピュータ等における演算処理によりグラフィックス画
像を作成する場合にも広く適用することができる。
Further, in the above-mentioned embodiment, the case where the graphics drawing device is constituted by the arithmetic processing circuit has been described, but the present invention is not limited to this, and a graphics image is created by arithmetic processing in a personal computer or the like. It can also be widely applied in cases.

【0040】[0040]

【発明の効果】上述のように本発明によれば、各オブジ
ェクトを代表するZ座標値を基準にして、所定の範囲
で、視点に対して手前側のオブジェクトを順次選択し、
各画素のZ座標値を基準にして表示画像を形成すること
により、不必要な描画処理を低減してZバッファ法によ
り隠面処理することができ、これにより簡易かつ確実に
隠面処理することができる。
As described above, according to the present invention, the object on the front side with respect to the viewpoint is sequentially selected within a predetermined range with reference to the Z coordinate value representing each object.
By forming a display image with the Z coordinate value of each pixel as a reference, unnecessary drawing processing can be reduced and hidden surface processing can be performed by the Z buffer method. This enables simple and reliable hidden surface processing. You can

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

【図1】本発明の実施の形態におけるグラフィックス描
画装置を示すブロック図である。
FIG. 1 is a block diagram showing a graphics drawing device according to an embodiment of the present invention.

【図2】従来のZソート法による隠面処理の説明に供す
る略線図である。
FIG. 2 is a schematic diagram for explaining a hidden surface process by a conventional Z sort method.

【図3】従来のZバッファ法による隠面処理の説明に供
する略線図である。
FIG. 3 is a schematic diagram for explaining a hidden surface processing by a conventional Z buffer method.

【図4】Zバッファ法による隠面処理における境界の処
理の説明に供する略線図である。
FIG. 4 is a schematic diagram for explaining the processing of a boundary in the hidden surface processing by the Z buffer method.

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

1……グラフィックス描画装置、2……メインメモリ、
3……Zソート処理回路、4……初期値演算回路、5…
…補間演算処理回路、6……メモリインターフェース、
7……ディスプレイバッファ、8…Zバッファ、10…
…Z値比較回路、12……ディスプレイコントローラ
1 ... Graphics drawing device, 2 ... Main memory,
3 ... Z sort processing circuit, 4 ... Initial value calculation circuit, 5 ...
... Interpolation calculation processing circuit, 6 ... Memory interface,
7 ... Display buffer, 8 ... Z buffer, 10 ...
… Z value comparison circuit, 12 …… Display controller

Claims (1)

【特許請求の範囲】[Claims] 【請求項1】 3次元座標により表現した複数のオブジ
ェクトの隠面処理方法において、 前記各オブジェクトを代表するZ座標値を比較して、所
定範囲内で、視点に対して手前側のオブジェクトを前記
複数のオブジェクトより順次選択した後、 前記オブジェクトの各画素のZ座標値を順次比較して表
示画像を形成することを特徴とする隠面処理方法。
1. A hidden surface processing method for a plurality of objects represented by three-dimensional coordinates, wherein Z coordinate values representing each of the objects are compared, and the object on the near side with respect to the viewpoint within the predetermined range is said. A hidden surface processing method, comprising: sequentially selecting from a plurality of objects, and then sequentially comparing Z coordinate values of respective pixels of the object to form a display image.
JP8148387A 1996-05-17 1996-05-17 Hidden surface processing method Abandoned JPH09305792A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP8148387A JPH09305792A (en) 1996-05-17 1996-05-17 Hidden surface processing method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP8148387A JPH09305792A (en) 1996-05-17 1996-05-17 Hidden surface processing method

Publications (1)

Publication Number Publication Date
JPH09305792A true JPH09305792A (en) 1997-11-28

Family

ID=15451640

Family Applications (1)

Application Number Title Priority Date Filing Date
JP8148387A Abandoned JPH09305792A (en) 1996-05-17 1996-05-17 Hidden surface processing method

Country Status (1)

Country Link
JP (1) JPH09305792A (en)

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6603474B1 (en) 1999-05-27 2003-08-05 International Business Machines Corporation Method and apparatus for occlusion culling of objects in a data processing system
US6900806B2 (en) 1999-04-09 2005-05-31 Sony Computer Entertainment Inc. Method and apparatus for performing perspective transformation

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
US6900806B2 (en) 1999-04-09 2005-05-31 Sony Computer Entertainment Inc. Method and apparatus for performing perspective transformation
US6603474B1 (en) 1999-05-27 2003-08-05 International Business Machines Corporation Method and apparatus for occlusion culling of objects in a data processing system

Similar Documents

Publication Publication Date Title
US4225861A (en) Method and means for texture display in raster scanned color graphic
EP0104431B1 (en) Image display system
US6961065B2 (en) Image processor, components thereof, and rendering method
US5877769A (en) Image processing apparatus and method
US20080211816A1 (en) Multiple parallel processor computer graphics system
EP0307019B1 (en) Apparatus for modifying pixel data stored in a random access memory
US20080273030A1 (en) Drawing apparatus and drawing method
JPH11259678A (en) Image display device and image display method by the same
JP2002519769A (en) Improved method and apparatus for pixel-by-pixel MIP mapping and three-line filtering
US6313844B1 (en) Storage device, image processing apparatus and method of the same, and refresh controller and method of the same
JP2005122361A (en) Image processor, its processing method, computer program, and recording medium
CA2298081C (en) Image processing apparatus and method of same
US6084591A (en) Method and apparatus for deferred video rendering
US5448264A (en) Method and apparatus for separate window clipping and display mode planes in a graphics frame buffer
JPH10320573A (en) Picture processor, and method for processing picture
US5761400A (en) Method and system for increasing the speed of a Z-buffer process
JPH09305792A (en) Hidden surface processing method
US6900804B1 (en) Method of forming polygon image and image processing apparatus using the same
JPH09319892A (en) Image processor and its processing method
JPH09282485A (en) Image processing method
JP3741053B2 (en) Image processing device
EP0791209A1 (en) Image texture mapping using texel caches
US6489967B1 (en) Image formation apparatus and image formation method
JPH10187124A (en) Plotting device and plotting method
JP3074912B2 (en) 3D image generation device

Legal Events

Date Code Title Description
A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20050831

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20050913

A762 Written abandonment of application

Free format text: JAPANESE INTERMEDIATE CODE: A762

Effective date: 20051019