WO1998006065A1 - Three-dimensional image processor - Google Patents

Three-dimensional image processor Download PDF

Info

Publication number
WO1998006065A1
WO1998006065A1 PCT/JP1996/002199 JP9602199W WO9806065A1 WO 1998006065 A1 WO1998006065 A1 WO 1998006065A1 JP 9602199 W JP9602199 W JP 9602199W WO 9806065 A1 WO9806065 A1 WO 9806065A1
Authority
WO
WIPO (PCT)
Prior art keywords
pixel
luminance
pattern
storage device
depth
Prior art date
Application number
PCT/JP1996/002199
Other languages
French (fr)
Japanese (ja)
Inventor
Masahiro Shiraishi
Takatoshi Ueno
Kazunori Oniki
Original Assignee
Hitachi, Ltd.
Hitachi Process Computer Engineering, Inc.
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., Hitachi Process Computer Engineering, Inc. filed Critical Hitachi, Ltd.
Priority to PCT/JP1996/002199 priority Critical patent/WO1998006065A1/en
Publication of WO1998006065A1 publication Critical patent/WO1998006065A1/en

Links

Classifications

    • GPHYSICS
    • G09EDUCATION; CRYPTOGRAPHY; DISPLAY; ADVERTISING; SEALS
    • G09GARRANGEMENTS OR CIRCUITS FOR CONTROL OF INDICATING DEVICES USING STATIC MEANS TO PRESENT VARIABLE INFORMATION
    • G09G5/00Control arrangements or circuits for visual indicators common to cathode-ray tube indicators and other visual indicators
    • G09G5/36Control arrangements or circuits for visual indicators common to cathode-ray tube indicators and other visual indicators characterised by the display of a graphic pattern, e.g. using an all-points-addressable [APA] memory
    • G09G5/39Control of the bit-mapped memory
    • G09G5/393Arrangements for updating the contents of the bit-mapped memory
    • GPHYSICS
    • G06COMPUTING; CALCULATING OR COUNTING
    • G06TIMAGE DATA PROCESSING OR GENERATION, IN GENERAL
    • G06T15/003D [Three Dimensional] image rendering
    • G06T15/10Geometric effects

Definitions

  • the present invention relates to a three-dimensional image processing apparatus that performs high-quality ghost display by anti-aliasing processing.
  • the anti-aliasing process is performed by shifting the coordinates of the same figure a plurality of times and setting the brightness as the brightness when displaying the average of all the brightnesses.
  • This method requires processing time for the number of times of drawing.
  • a method that draws a figure in units of sub-pixels and uses the luminance to display the average of the luminance of the sub-pixels included in one pixel requires a device to store luminance and depth information for each sub-pixel. There is. For example, dividing one pixel into 4x4 sub-pixels to perform this method would require 16 times as much storage.
  • An object of the present invention is to realize processing equivalent to the above-described antialiasing processing with a short processing time and a small number of storage devices. Disclosure of the invention
  • information such as luminance and depth is stored in units of one pixel. Then, in the unit of sub-pixel, only whether or not it is included in the graphic area to be drawn is stored as an occupation pattern. Then, based on the occupation pattern, the ratio of the region of the foreground figure and the background is calculated, and the luminance of the figure of the foreground and the luminance of the background are blended according to the ratio, so that one drawing is performed. To achieve anti-aliasing.
  • the luminance of a drawing pixel constituting the figure, the depth of the drawing pixel, and the occupation pattern of the drawing pixel are calculated.
  • the depth of the drawing pixel is compared with the depth of the drawing pixel in the total occupied depth storage device, and if the depth of the drawing pixel is deeper, the drawing of the view is drawn. Abort. If the depth of the drawing pixel is nearer or equal, the occupancy pattern of the same coordinates as the drawing pixel in the occupation pattern storage device is compared with the occupancy pattern of the drawing pixel. However, if even some of the graphic areas overlap, it is determined that the foreground pixel that has already been rendered on the pixel of the same coordinates and the pixel of the rendered pixel are not continuous.
  • the luminance of the luminance storage device at the same coordinates as the drawing pixel is compared with the luminance of the drawing pixel. If the occupied patterns are approximate values, the drawing is already performed at the same coordinates. It is determined that the foreground pixel and the drawing pixel are continuous. As a result of the comparison, if the values are not approximate values, the most recently drawn at the same coordinates It is determined that the previous pixel and the pixel of the drawing pixel are not continuous. After determining whether or not the pixel is a continuous pixel as described above, the ratio of the figure area of the occupation pattern of the drawing pixel and the occupation pattern of the occupation pattern storage device having the same coordinates as the drawing pixel is determined. The luminance and the luminance of the luminance storage device having the same coordinates as the drawing pixel are rendered and stored in the frame buffer.
  • the occupation pattern of the occupation pattern storage device and the graphic area of the occupation pattern of the drawing pixel are combined and stored in the occupation pattern storage device. If it is determined that the drawing pixel is not continuous, the drawing force is stored in the occupation pattern storage device if the drawing force is closer to the depth force of the drawing pixel. Pixel Depth Force If the depth of the z-buffer at the same coordinate is farther than the depth, the occupation pattern of the occupation pattern storage device is stored as it is.
  • the occupation pattern of the occupation pattern storage device is used as a blend ratio when drawing a figure with respect to the pixel having the same coordinates later, the occupation pattern to the occupation pattern storage device described above is used. Remembering is a necessary process.
  • an object with a complicated shape is displayed by continuously combining small polygons.
  • a series of multiple polygons Combine, treat as one polygon, and blend in brightness.
  • FIG. 1 is a diagram showing an overall block diagram of hardware of the present embodiment
  • FIG. 2 is a diagram showing an overall flow of hardware of the present embodiment
  • FIG. Fig. 4 shows each image memory.
  • FIG. 5 is a diagram showing a process of a pixel comparison operation unit
  • FIG. 6 is a diagram showing a block diagram of a luminance approximate value determination
  • FIG. 8 is a diagram showing a selection of a process of the ghost information calculation unit.
  • FIG. 8 is a diagram showing a detailed flow of the pixel comparison calculation unit.
  • FIG. 9 is a calculation procedure of an occupation pattern in the pixel information calculation unit.
  • FIG. 10 is a diagram illustrating the role of the total occupied depth storage device, FIG.
  • FIG. 11 is a diagram illustrating determination of continuous pixels based on the occupation pattern
  • FIG. 12 is a diagram illustrating FIG. 13 is a diagram illustrating an example of a luminance calculation process.
  • FIG. 13 is a diagram illustrating another example of a luminance calculation process.
  • FIG. 14 is a diagram illustrating an example of obtaining an occupation pattern.
  • FIG. 15 is a diagram showing an example of erroneously determining a continuous pixel.
  • FIG. 1 is an overall block diagram of the hardware according to the present invention
  • FIG. 2 is a flowchart showing an outline of the processing in the hardware.
  • This hardware consists of a central processing unit (100) connected to the system bus (100), a rendering processor (200), and a display for displaying the processing results of the rendering processor (200). It consists of control means (400) and CRT (500).
  • the rendering processor (200) is connected to an image memory (300) for storing the processing results and intermediate processing results, and the display control means is stored in this image memory. The processing result is displayed on the CRT (500).
  • the vertex coordinates, vertex luminance, and vertex depth of the three-dimensional figure to be rendered are calculated by a central processing unit (100) having a CPU and a memory, and issued to a rendering processor via a system bus ( 1) and the rendering processor
  • a central processing unit (100) having a CPU and a memory
  • the rendering processor issues the pixel information calculation unit (2100) of (200)
  • the pixel comparison operation unit (220) of the rendering processor (200) the luminance to be displayed is calculated from the calculated pixel information.
  • a ghost image memory (300) is used, and the calculated brightness is stored in the image memory (300).
  • the luminance information stored in the frame buffer (310) in the image memory (300) is displayed on the CRT (500) by the display control means (400) (4).
  • FIG. 3 shows the configuration of the image memory (300), and FIG. 4 shows the role of each memory.
  • the image memory (300) stores a frame buffer (311) in which the averaged luminance (311) of the pixel (31) viewed from the viewpoint direction (30) is displayed for display on the CRT. 3 10 0), Z buffer (3 2 0) that records the depth of the nearest pixel (3 2 1), and the occupancy pattern of the nearest pixel
  • An occupancy pattern storage device (340) that stores (331), a brightness storage device (340) that stores the brightness (334) of the foremost pixel, and a figure of the occupation pattern It consists of an occupied depth storage device ('350) which stores the depth (351) of the foremost pixel such that the area is 100%.
  • each memory corresponding to one pixel is as follows: the frame buffer (310) has 24 bits, the Z buffer (320) has 24 bits, and the occupied pattern storage device (330) has 1 bit.
  • the 6-bit luminance storage device (340) has 24 bits, and the total occupied depth storage device (350) has 24 bits.
  • the occupation pattern storage device (330) stores information of 16 sub-pixels included in one pixel as an occupation pattern of 16 bits.
  • the memory configuration is about 2.3 times as large as that of the frame buffer (310) and the Z buffer (320) only when the anti-aliasing process is performed. To achieve.
  • the detailed block diagrams of the rendering processor (200) are shown in Figs. 5, 6, and 7, and the detailed flow is shown in Fig. 8.
  • the occupancy pattern of the image information calculation unit (210) is shown in Figs. Fig. 9 shows the processing in the calculation unit.
  • the CPU (100) issues the vertex coordinates, vertex depth, and IS point luminance of the figure (triangle in this embodiment) from the CPU (100), and the hardware of the rendering processor (200) executes the operation.
  • the screen information calculation unit (210) receives these vertex information.
  • the rendering processor (200) calculates the coordinates of the pixels constituting the figure, the luminance of the drawing pixels, A pixel information calculation unit for calculating the depth of the drawing pixel and the occupation pattern of the drawing pixel in the sub-pixel
  • a pixel comparison operation unit (220) for calculating information to be stored in the image memory (300) from the pixel information.
  • the pixel information calculation unit (210) supplements the X value between vertices in the Y coordinate direction in quarter pixel units based on the received vertex information. Calculate the frame of the area (41). Next, the subpixel whose center point is equal to or greater than the left frame and less than the right frame is set to “0”, and if not included, is set to “1” (42). After calculating the values of all the sub-pixels in one pixel constituting the figure, the value is transferred to the pixel comparison operation unit (220) as a 16-bit occupation pattern (43). At the same time, the luminance of the pixel at the same coordinate and the depth of the pixel at the same coordinate are transferred to the pixel comparison operation unit (2220). In the following, unless otherwise specified, the information of each memory in the image memory (300) is the information of the memory having the same coordinates as the drawing pixel.
  • the pixel comparison operation unit (220) first stores the depth Z (33) of the picture pixel (35) and the total occupied depth storage device (350). ) Is compared with the depth AB (3 5 2) (2 2 1).
  • the drawing pixel (35) is deeper (when CO becomes 0)
  • the state of the pixel (36) viewed from the viewpoint direction (32) is changed to the pixel (34) in front.
  • the drawing pixel (35) is hidden and invisible. Therefore, the information of the frame buffer (310) needs to be updated, and the drawing of the pixel is stopped (17). If the drawing pixel (35) is closer or equal in depth (when CO becomes 1), then the occupation pattern P of the drawing pixel and the occupation pattern storage device (330) are stored. A logical sum (P
  • the result (56) of the bit-wise OR of the occupation pattern (54) of (53) and the occupation pattern (55) of the pixel (53) in the figure (52) is (56) in which all bits are '1'.
  • the pixel (59) overlapping the figure (57) and the figure (58) is the occupied pattern (60) of the pixel (59) in the figure (57) and the figure (58).
  • the result (62) of the bit-wise OR of the pixel (59) with the occupation pattern (61) of the pixel (59) at the point becomes the bit power '' 0 'of the overlapped portion.
  • the occupation pattern of the drawing pixel by calculating the bit-wise logical OR, the occupation pattern of the drawing pixel and the It is possible to determine whether or not the graphic area portion overlaps with the occupation pattern stored in the occupation pattern storage device (330).
  • the brightness I of the drawing pixel is compared with the brightness IB of the brightness storage device (340) (223), and it is determined whether or not these values are approximate values. Is determined.
  • IT is performed using a threshold value preset in a threshold value register (230) as shown in FIG.
  • the R, G, and B components of the luminance of the picture pixel are Rl, GI, and BI, respectively, and the R, G, and B components of the luminance of the luminance storage device (340) are RIB, GIB, BIB.
  • the absolute value of the difference from the luminance of (340) is calculated as R S, G S, and B S for each RGB component (227). Then, the threshold value R preset in the threshold value register (230) is compared with the absolute value of the difference for each of the RGB components (228). If all of R S, G S, and B S are smaller than the threshold value R, it is determined to be an approximate value. If at least one of R S, G S, and B S is larger than the threshold value R, it is determined that the value is not an approximate value.
  • the value set in the threshold register (230) sets the upper limit of the absolute value of the difference in luminance considered as an approximate value.
  • about 30% of the maximum luminance value of the frame buffer (310) is set as the upper limit of the luminance difference that is regarded as an approximate value. That is, since each component of the luminance of the frame buffer (310) is 8 bits and the maximum luminance is 255, the threshold value is set to 76.
  • the bit unit is If the result of the logical product (P & SB) (2 25) is all '0' for all 16 bits (C 4 is 1), the pixel information calculation unit (2 26) The processing corresponding to (10) in Fig. 7 and Fig. 8 (the following processing (8) (() (0) () ( ⁇ )) is performed, and the result of bitwise logical AND (225) If all of the 16 bits are not '0', the pixel information calculation unit (226) performs the processing corresponding to (11) in FIGS. 7 and 8 (the following processing (A)). (C) (D) (F)).
  • the result of the depth comparison (2 2 4) indicates that the drawing pixel is at the depth (when C3 is 0)
  • the result of the bit-wise logical AND (2 25) will be all 16 bits If '0' (C4 becomes 1), the pixel information calculation unit
  • drawing has already been performed It is determined that the foreground pixel and the pixel to be rendered are not continuous.
  • the depth of the drawing pixel is compared with the Z buffer (320) (224), followed by the occupation pattern P of the drawing pixel and the occupancy of the occupation pattern storage device (330). Performs a bit-wise AND operation with the pattern (SB) (225).
  • the pixel information calculation unit (2 26) performs processing corresponding to (14) in FIGS. 7 and 8 (the following processing (A) (C) (E) (F) (G) ), And if the result of the bit-wise logical AND (2 25) is not all “0” for both 16 bits, the pixel information calculation unit (2 26) performs the operations shown in FIGS. The processing corresponding to (15) in the figure (the following processing (A) (C) (E) (F)) is performed.
  • the depth comparison (2 24) if the drawing pixel is located at the depth, the pixel information calculation unit (2 26) performs processing corresponding to (15) in FIG. 7 and FIG. The following processing (B)) is performed.
  • each memory in the image memory (300) that has not been updated stores the information before drawing the drawing pixel as it is.
  • the occupation pattern of the drawing pixel is “P”
  • the occupation pattern stored in the occupation pattern storage device (330) is “P”. Expressed as 'SB'.
  • Ra2 Percentage of '0' in (SBI 1 ⁇ ⁇ ⁇ (?))
  • Ra3 1.0-Ral ⁇ Ra2
  • the outline of the process (A) will be described with reference to the example of FIG.
  • the processing (A) is performed when the depth (75) of the drawing pixel is closer to or equal to the depth (32) read out from the Z buffer (320). ) Is a process of calculating the luminance to be stored.
  • the regions (71), (72), and (73) in a subpixel of a certain pixel viewed from the viewpoint direction (70) are weighted by the ratio of occupying the subpixel by each luminance and averaged.
  • the area (71) viewed from the line-of-sight direction (70) occupies 9Z16, which is the ratio of '0' in the pattern (76) occupied by the drawing pixel, due to the luminance (74) of the drawing pixel. ing.
  • the area (72) viewed from the line-of-sight direction (70) is read from the occupancy pattern storage device (330) by the brightness (333) read from the brightness storage device (340).
  • Occupancy pattern (3 4 3) Occupies 3 16 which is the proportion of '0' in INOT (occupation pattern (76) of drawing pixels) 76.
  • the brightness of the frame buffer (310) is calculated by averaging the brightness of the area (73) when the pixel was previously drawn, using the brightness of the area (73).
  • the brightness of the original region (73) can be reflected to some extent.
  • the area (81) viewed from the line-of-sight direction (80) is determined by the drawing pixel luminance (84) (drawing pixel occupation pattern (86) [NOT (read from occupation pattern storage device (330)).
  • the occupation pattern (3 4 4)) occupies 5 to 16 which is the ratio of '0'.
  • the area (8 2) viewed from the line of sight (80) is the luminance storage device (3 4 0).
  • the luminance of the frame buffer (310) is averaged using the luminance of the area (83) when the pixel was previously drawn, the luminance of the frame buffer (310) is calculated as follows. By setting the brightness of the area (83), the brightness of the original area (83) can be reflected to some extent. Processing (C)
  • the processing (C) stores and updates the depth of the drawing pixel in the Z buffer (320) when the depth of the drawing pixel is closer or equal to the depth read from the Z buffer (320). It is processing.
  • Occupancy pattern storage device (330) P & S B
  • the process (D) is a process of synthesizing an occupation pattern and storing the occupation pattern in the occupation pattern storage device (330) when it is determined that the drawing pixel and the foremost pixel that has been previously drawn are continuous. is there.
  • the occupation pattern (91) of the drawing pixel and the occupation pattern (92) read from the occupation pattern storage device (330) are bit-wise ANDed with each other to perform the logical AND operation.
  • This is a process of synthesizing the graphic area (area of '0') (93) and storing it as a graphic area of one pixel in the occupation pattern storage device (330).
  • the drawing pixel is connected to the foremost pixel that has been previously drawn. Occupied pattern storage device (330) when it is determined that the connection is not continuous and the depth of the drawing pixel is closer to or equal to the depth of the Z buffer (320). This is a process of storing a pattern. Processing (F)
  • the processing (F) stores the brightness of the drawing m in the luminance storage device (340) when the depth of the drawing pixel is closer or equal to the depth of the Z buffer (320). This is the process to do.
  • the occupation pattern storage device (330) is updated by the process (D) or the process (E), and the occupation pattern (P) of the drawing pixel and the occupation pattern storage device (330) are updated.
  • the bit-wise AND with the occupation pattern (SB) read from) is 16 bits, the total occupied depth storage device (35%) becomes “0” (100% of the pixel graphic area). 0) is a process of storing the depth of the drawing element.
  • Fig. 13 if the depth of the pixel (85) to be drawn is the second closest to the front of the depth of the previously drawn pixel, the ideal brightness is If it is the third or later from the front, that is, the pixel to be drawn (85) and the foremost pixel that has been previously drawn If there is another pixel that has been previously drawn between the depths of (3 2 4), the result will be different from the ideal luminance.
  • the occupation pattern (64) of the drawing pixel and the occupation pattern storage device Since the result (66) of the bitwise OR of the occupation pattern (65) of (330) is all '1', the pixel is erroneously determined to be continuous. Also, if the luminance is not an approximate value while two M elements are adjacent, it is erroneously determined that the pixels are not continuous. As described above, if the determination as to whether or not they are continuous is incorrect, the determination as to whether or not to combine the graphic area of the occupied pattern is also erroneously made, resulting in the occupation of the wrong occupied pattern.
  • the pattern storage device (330) It is stored in the pattern storage device (330). Therefore, when the pixel is drawn later at the same coordinates, the luminance is calculated from the ratio of '0' of the wrong occupation pattern, so that the luminance power of the frame buffer (310) does not become the ideal luminance. There are cases. In particular, when the depth of the drawing pixel is deeper than the depth of the Z buffer (320), the occupied pattern of the occupied pattern storage device (330) is located at the foreground. Since the ratio of the occupation pattern of the occupation pattern storage device to be seen is likely to be large, the ratio of the occupation pattern is greatly involved in calculating the luminance.
  • the anti-aliasing process is performed by one drawing by performing the brightness calculation using the foreground occupation pattern held in one element unit, so that the conventional method is used. It is faster to draw and is suitable for performing anti-aliasing with less memory.

Abstract

A three-dimensional image processor which performs antialiasing with a small memory capacity in a short time. The image processor is provided with an image memory (300) comprising an occupying pattern storage (330) in which occupying patterns are stored, a luminance storage (340) in which the luminance of the first picture element is stored, an all occupation depth storage (350) in which the depth of the first picture element whose occupying pattern is 100 % is stored, a frame buffer in which the information on these individual picture elements is stored, and a Z-buffer (320), a picture element information calculating section (210) which calculates occupying patterns in units of one picture element, and a picture element comparing and calculating section (220) which calculates the information to be stored in the memory (300). Since this image processor performs antialiasing at a high speed for one image, an increase of the capacity of memory per picture element is suppressed and the manufacturing cost of the image processor is low.

Description

明 細 書  Specification
3次元画像処理装置 技術分野  3D image processing equipment
本発明は、 アンチエイ リァス処理による高品位な幽 Ί象表示を行う 3次 元画像処理装置に関する。 背景技術  The present invention relates to a three-dimensional image processing apparatus that performs high-quality ghost display by anti-aliasing processing. Background art
図形をラスタ一スキャンディスプレイなどの表示装置に表示させると, 図形の斜めの辺がぎざぎざになる。 これは表示装置を構成する画素が、 図形の領域に含まれるか否かによリ、 その画素を図形の輝度で表示する 力、、 または図形の枠外の背景の輝度で表示するかを決定するために起こ る現象である。 この現象を解決するために、 図形を描画した際に発生す る斜めの辺のぎざぎざを E1立たなくするアンチエイ リアス処理として、 図形の領域が、 画素に対してどれだけ含まれているかで、 図形の輝度と、 背景の輝度をブレン ドする方法が取られてきた。  When a graphic is displayed on a display device such as a raster-scan display, diagonal sides of the graphic are jagged. This depends on whether or not the pixels that make up the display device are included in the graphic area, and determines whether the pixel is displayed with the luminance of the graphic or the luminance of the background outside the frame of the graphic. This is a phenomenon that occurs due to To solve this phenomenon, as an anti-aliasing process that eliminates jagged edges on the diagonal side that occurs when drawing a figure, the shape of the figure is determined by how much the area of the figure is included in the pixel. The method of blending the brightness of the background and the brightness of the background has been adopted.
例えば日本特開平 4 - 233086号では、 同一図形を複数回座標をずらして 描画が全ての輝度の平均を表示する際の輝度とすることでアンチエイ リ ァス処理を行う。 この方式は描画の'回数分だけ処理時間がかかる。  For example, in Japanese Patent Application Laid-Open No. Hei 4-233086, the anti-aliasing process is performed by shifting the coordinates of the same figure a plurality of times and setting the brightness as the brightness when displaying the average of all the brightnesses. This method requires processing time for the number of times of drawing.
また、 各サブピクセル単位で図形の描画を行い、 1 画素に含まれるサ ブピクセルの輝度の平均を表示する輝度とする方式は、 各サブピクセル 毎に輝度と奥行きの情報を記憶する装置を設ける必要がある。 例えば、 1 画素を 4 X 4のサブピクセルに分割してこの方式を行うには、 1 6倍 の記憶装置が必要となる。  In addition, a method that draws a figure in units of sub-pixels and uses the luminance to display the average of the luminance of the sub-pixels included in one pixel requires a device to store luminance and depth information for each sub-pixel. There is. For example, dividing one pixel into 4x4 sub-pixels to perform this method would require 16 times as much storage.
このように従来の例では、 処理時間が多くかかるため処理速度をあげ にく く、 また記憶装置が多く必要なためコス 卜がかかる等の問題点があ つた。 As described above, in the conventional example, the processing time is long, so the processing speed is increased. In addition, there were problems such as the fact that it was costly because many storage devices were required.
本発明の目的は、 短い処理時間で、 かつ少ない記憶装置で、 上述のァ ンチエイ リァス処理と同等の処理を実現することにある。 発明の開示  An object of the present invention is to realize processing equivalent to the above-described antialiasing processing with a short processing time and a small number of storage devices. Disclosure of the invention
本発明では、 輝度や、 奥行きなどの情報は 1 画素単位で記憶する。 そ して、 サブピクセル単位では、 描画する図形領域に含まれるか否かのみ を、 占有パターンと して記憶する。 そして占有パターンに基づいて、 最 も手前の図形の領域と、 背景の領域の割合を算出し、 該割合で最も手前 の図形の輝度と、 背景の輝度をブレン ドすることにより、 1 回の描画で アンチエイ リァス処理を達成する。  In the present invention, information such as luminance and depth is stored in units of one pixel. Then, in the unit of sub-pixel, only whether or not it is included in the graphic area to be drawn is stored as an occupation pattern. Then, based on the occupation pattern, the ratio of the region of the foreground figure and the background is calculated, and the luminance of the figure of the foreground and the luminance of the background are blended according to the ratio, so that one drawing is performed. To achieve anti-aliasing.
図形を描画する際に、 図形を構成する描画画素の輝度と、 該描画画素 の奥行きと、 該描画画素の占有パターンを算出する。 最初に、 全占有奥 行き記憶装置における該描画画素と同座標の奥行きと該描画画素の奥行 きとで比較を行い、 該描画画素の奥行きの方が奥であればその画索の描 画を中止する。 該描画画素の奥行きの方が手前、 又は等しい奥行きであ る場合は、 占有パターン記憶装置における該描画画素と同座標の占有パ タ一ンと該描画画素の占有バタ一ンとの比較を行い、 互いの図形領域の 一部でも重なる場合は、 同座標の画素に既に描画が行われた最も手前の 画素と該描画画素の画素とは、 連続ではないと判定する。 前記占有バタ —ンが重ならない場合は、 該描画画素と同座標の輝度記憶装置の輝度と、 該描画画素の輝度の比較を行い、 近似値である場合は、 同座標に既に描 画が行われた最も手前の画素と該描画画素とは、 連続であると判定する。 前記比較の結果、 近似値でない場合は、 同座標に既に描画が行われた最 も手前の画素と、 該描画画素の画素とは、 連続ではないと判定する。 以上の連続の画素か否かの判定後、 該描画画素の占有バタ一ンと該描 画画素と同座標の占有パターン記憶装置の占有バタ一ンとの図形領域の 割合により、 該描画画素の輝度と、 該描画画素と同座標の輝度記憶装置 の輝度とのプレン ドを行い、 フレームバッファへ記憶する。 When drawing a figure, the luminance of a drawing pixel constituting the figure, the depth of the drawing pixel, and the occupation pattern of the drawing pixel are calculated. First, the depth of the drawing pixel is compared with the depth of the drawing pixel in the total occupied depth storage device, and if the depth of the drawing pixel is deeper, the drawing of the view is drawn. Abort. If the depth of the drawing pixel is nearer or equal, the occupancy pattern of the same coordinates as the drawing pixel in the occupation pattern storage device is compared with the occupancy pattern of the drawing pixel. However, if even some of the graphic areas overlap, it is determined that the foreground pixel that has already been rendered on the pixel of the same coordinates and the pixel of the rendered pixel are not continuous. When the occupied patterns do not overlap, the luminance of the luminance storage device at the same coordinates as the drawing pixel is compared with the luminance of the drawing pixel. If the occupied patterns are approximate values, the drawing is already performed at the same coordinates. It is determined that the foreground pixel and the drawing pixel are continuous. As a result of the comparison, if the values are not approximate values, the most recently drawn at the same coordinates It is determined that the previous pixel and the pixel of the drawing pixel are not continuous. After determining whether or not the pixel is a continuous pixel as described above, the ratio of the figure area of the occupation pattern of the drawing pixel and the occupation pattern of the occupation pattern storage device having the same coordinates as the drawing pixel is determined. The luminance and the luminance of the luminance storage device having the same coordinates as the drawing pixel are rendered and stored in the frame buffer.
連続であると判定されたものは、 占有バタ一ン記憶装置の占有バタ一 ンと該描画画素の占有パタ一ンの図形領域を合成したものを、 占有バタ ーン記憶装置へ記憶する。 連続ではないと判定されたものは、 該描画画 素の奥行き力'、 同座標の zバッファの奥行きより手前である場合は、 該 描画画素の占有バターンを占有パターン記憶装置に記憶し、 該描画画素 の奥行き力 同座標の zバッファの奥行きよリ奥である場合は、 占有パ ターン記憶装置の占有パターンをそのまま記憶する。  If the pattern is determined to be continuous, the occupation pattern of the occupation pattern storage device and the graphic area of the occupation pattern of the drawing pixel are combined and stored in the occupation pattern storage device. If it is determined that the drawing pixel is not continuous, the drawing force is stored in the occupation pattern storage device if the drawing force is closer to the depth force of the drawing pixel. Pixel Depth Force If the depth of the z-buffer at the same coordinate is farther than the depth, the occupation pattern of the occupation pattern storage device is stored as it is.
後に同座標の画素に対して、 更に図形の描画を行う際に、 ブレン ドの 割合と して占有パターン記憶装置の占有パターンを使用するため、 以上 の占有パタ一ン記憶装置への占有バターンの記憶は、 必要な処理である。  Since the occupation pattern of the occupation pattern storage device is used as a blend ratio when drawing a figure with respect to the pixel having the same coordinates later, the occupation pattern to the occupation pattern storage device described above is used. Remembering is a necessary process.
3次元画像処理装置において、 複雑な形の物体は小さな多角形を連続 で組み合わせて表示を行っている。 複数連続した多角形において、 隣接 した多角形は互いに重ならないことと、 輝度が近似値である可能性が高 いことを利用して、 連続した複数の多角形は互いの占有パターンの図形 領域を合成し、 1つの多角形として扱い、 輝度のブレン ドを行う。 図面の簡単な説明  In a three-dimensional image processing device, an object with a complicated shape is displayed by continuously combining small polygons. By taking advantage of the fact that adjacent polygons do not overlap each other and that the luminance is likely to be an approximate value, a series of multiple polygons Combine, treat as one polygon, and blend in brightness. BRIEF DESCRIPTION OF THE FIGURES
第 1 図は、 本実施例のハー ドウエアの全体ブロック図を示す図であり、 第 2図は、 本実施例のハー ドウェアの全体フローを示す図であり、 第 3 図は、 画像メモリの構成を示す図であり、 第 4図は、 画像メモリの各メ モリの役割を示す図であり、 第 5図は、 画素比較演算部における処理を 示す図であり、 第 6図は、 輝度の近似値判定のブロック図を示す図であ リ、 第 7図は、 幽素情報演算部の処理の選択を示す図であり、 第 8図は, 画素比較演算部の詳細フローを示す図であり、 第 9図は、 画素情報算出 部での占有パターンの算出手順を示す図であり、 第 1 0図は、 全占有奥 行き記憶装置の役割を示す図であり、 第 1 1 図は、 占有パターンによる 連続画素の判定を示す図であり、 第 1 2図は、 輝度算出処理の一例を示 す図であり、 第 1 3図は、 輝度算出処现の他の例を示す図であり、 第 1 4図は、 占有パターンを求める一例を示す図であり、 第 1 5図は、 連 続画素の判定を誤る例を示す図である。 FIG. 1 is a diagram showing an overall block diagram of hardware of the present embodiment, FIG. 2 is a diagram showing an overall flow of hardware of the present embodiment, and FIG. Fig. 4 shows each image memory. FIG. 5 is a diagram showing a process of a pixel comparison operation unit, FIG. 6 is a diagram showing a block diagram of a luminance approximate value determination, and FIG. FIG. 8 is a diagram showing a selection of a process of the ghost information calculation unit. FIG. 8 is a diagram showing a detailed flow of the pixel comparison calculation unit. FIG. 9 is a calculation procedure of an occupation pattern in the pixel information calculation unit. FIG. 10 is a diagram illustrating the role of the total occupied depth storage device, FIG. 11 is a diagram illustrating determination of continuous pixels based on the occupation pattern, and FIG. 12 is a diagram illustrating FIG. 13 is a diagram illustrating an example of a luminance calculation process. FIG. 13 is a diagram illustrating another example of a luminance calculation process. FIG. 14 is a diagram illustrating an example of obtaining an occupation pattern. FIG. 15 is a diagram showing an example of erroneously determining a continuous pixel.
発明を実施するための最良の形態 BEST MODE FOR CARRYING OUT THE INVENTION
本発明を実施する最良の形態を、 第 1 図〜第 1 5図を用いて説明する。 本発明に関わるハー ドウェアの全体ブロック図を第 1 図に、 またこの ハー ドウエアにおける処理の概略を表すフローを第 2図に示す。  The best mode for carrying out the present invention will be described with reference to FIGS. 1 to 15. FIG. 1 is an overall block diagram of the hardware according to the present invention, and FIG. 2 is a flowchart showing an outline of the processing in the hardware.
このハー ドウェアは、 システムバスによリ接続された中央処理装置 ( 1 0 0 ) とレンダリ ングプロセッサ ( 2 0 0 ) 、 およびこのレンダリ ングプロセッサ ( 2 0 0 ) による処理結果を表示するための表示制御手 段 ( 4 0 0 ) と C R T ( 5 0 0 ) からなる。 また、 レンダリングプロセ ッサ ( 2 0 0 ) には処理結果、 および処理の途中結果を記憶するための 画像メモリ ( 3 0 0 ) が接続されており、 表示制御手段はこの画像メモ リに記憶された処理結果を C R T ( 5 0 0 ) に表示する。 描画処理を行 う 3次元図形の頂点座標と頂点輝度と頂点奥行きとが、 C P Uとメモリ を有する中央処理装置 ( 1 0 0 ) で算出され、 システムバスを介してレ ンダリングプロセッサに発行される ( 1 ) と、 レンダリングプロセッサ ( 2 0 0 ) の画素情報算出部 ( 2 1 0 ) において、 これら頂点座標と頂 点輝度と頂点奥行きより図形を構成する画素の座標と描画する画素の輝 度と描画画素の奥行きとこの描幽幽素の占有パターンを算出する ( 2 )。 次に、 レンダリ ングプロセッサ ( 2 0 0 ) の画素比較演算部 ( 2 2 0 ) において、 これら算出された画素情報から表示する輝度を算出する。 画 案-比較演算部( 2 0 0 )で表示輝度を算出する際には幽像メモリ ( 3 0 0 ) を使用し、 また算出された輝度は画像メモリ ( 3 0 0 ) に記憶されるThis hardware consists of a central processing unit (100) connected to the system bus (100), a rendering processor (200), and a display for displaying the processing results of the rendering processor (200). It consists of control means (400) and CRT (500). The rendering processor (200) is connected to an image memory (300) for storing the processing results and intermediate processing results, and the display control means is stored in this image memory. The processing result is displayed on the CRT (500). The vertex coordinates, vertex luminance, and vertex depth of the three-dimensional figure to be rendered are calculated by a central processing unit (100) having a CPU and a memory, and issued to a rendering processor via a system bus ( 1) and the rendering processor In the pixel information calculation unit (2100) of (200), the coordinates of the pixels constituting the figure from the vertex coordinates, the vertex luminance, and the vertex depth, the brightness of the pixel to be drawn, the depth of the drawing pixel, and the Calculate the occupancy pattern of ghosts (2). Next, in the pixel comparison operation unit (220) of the rendering processor (200), the luminance to be displayed is calculated from the calculated pixel information. When calculating the display brightness in the design-comparison operation unit (200), a ghost image memory (300) is used, and the calculated brightness is stored in the image memory (300).
( 3 ) 。 そして、 表示制御手段 ( 4 0 0 ) により、 画像メモリ( 3 0 0 ) 中のフレームバッファ( 3 1 0 )に格納された輝度情報を C R T ( 5 0 0 ) に表示する ( 4 ) 。 (3). Then, the luminance information stored in the frame buffer (310) in the image memory (300) is displayed on the CRT (500) by the display control means (400) (4).
画像メモリ ( 3 0 0 ) の構成図を第 3図に、 各メモリの役割を第 4図 に示す。 画像メモリ ( 3 0 0 ) は、 C R Tへ表示を行うために、 視点方 向 ( 3 0 ) よ り見た画素 ( 3 1 ) の平均化した輝度 ( 3 1 1 ) を記憶す るフレームバッファ ( 3 1 0 ) と、 最も手前の画素の奥行き ( 3 2 1 ) を記億する Zバッファ ( 3 2 0 ) と、 最も手前の画素の占有パターン FIG. 3 shows the configuration of the image memory (300), and FIG. 4 shows the role of each memory. The image memory (300) stores a frame buffer (311) in which the averaged luminance (311) of the pixel (31) viewed from the viewpoint direction (30) is displayed for display on the CRT. 3 10 0), Z buffer (3 2 0) that records the depth of the nearest pixel (3 2 1), and the occupancy pattern of the nearest pixel
( 3 3 1 ) を記憶する占有バタ一ン記憶装置 ( 3 3 0 ) と、 最も手前の 画素の輝度( 3 4 1 ) を記憶する輝度記憶装置( 3 4 0 ) と、 占有パター ンの図形領域が 1 0 0 %となるような最も手前の画素の奥行き( 3 5 1 ) を記憶する全占有奥行き記憶装置 ('3 5 0 ) より構成される。 An occupancy pattern storage device (340) that stores (331), a brightness storage device (340) that stores the brightness (334) of the foremost pixel, and a figure of the occupation pattern It consists of an occupied depth storage device ('350) which stores the depth (351) of the foremost pixel such that the area is 100%.
1 画素に対応する各メモリの構成は、 フレームバッファ ( 3 1 0 ) は 2 4 ビッ ト、 Zバッファ ( 3 2 0 ) は 2 4 ビッ ト、 占有パターン記億装 置 ( 3 3 0 ) は 1 6 ビッ ト、 輝度記憶装置 ( 3 4 0 ) は 2 4 ビッ ト、 全 占有奥行き記憶装置 ( 3 5 0 ) は 2 4 ビッ トとする。 フレームバッファ The configuration of each memory corresponding to one pixel is as follows: the frame buffer (310) has 24 bits, the Z buffer (320) has 24 bits, and the occupied pattern storage device (330) has 1 bit. The 6-bit luminance storage device (340) has 24 bits, and the total occupied depth storage device (350) has 24 bits. Frame buffer
( 3 1 0 ) と、 輝度記憶装置 ( 3 4 0 ) とは、 2 3〜 1 6 ビッ ト目の輝 度 R成分、 1 5〜 8 ビッ ト 目の輝度 G成分、 7〜 0ビッ ト目の輝度 B成 分から構成されている。 占有パターン記憶装置 ( 3 3 0 ) は 1 画素内に 含まれる 1 6のサブピクセルの情報を 1 6 ビッ 卜の占有パターンと して 記憶する。 本実施例では、 アンチエイ リアス処理を行わない時の、 フレ 一ムバッファ ( 3 1 0 ) と Zバッファ ( 3 2 0 ) のみの構成と比較して、 約 2. 3 倍のメモリ構成でアンチエイ リアス処理を実現する。 (310) and the luminance storage device (340) are the luminance R component of the 23rd to 16th bits, the luminance G component of the 15th to 8th bits, and the 7th to 0th bits. Brightness B Consist of minutes. The occupation pattern storage device (330) stores information of 16 sub-pixels included in one pixel as an occupation pattern of 16 bits. In the present embodiment, when the anti-aliasing process is not performed, the memory configuration is about 2.3 times as large as that of the frame buffer (310) and the Z buffer (320) only when the anti-aliasing process is performed. To achieve.
レンダリ ングプロセッサ ( 2 0 0 ) の詳細ブロック図を第 5図, 第 6 図, 第 7図に、 詳細フローを第 8図に、 画像情報算出部 ( 2 1 0 ) が有 する占有バタ一ン算出部における処理を第 9図に示す。 本実施例のハー ドウエアの動作として、 まず C P U ( 1 0 0 ) より図形 (本実施例では 3角形) の頂点座標, 頂点奥行き, IS点輝度が発行され、 レンダリ ング プロセッサ ( 2 0 0 ) の画尜情報算出部 ( 2 1 0 ) がこれらの頂点情報 を受け取る。 レンダリングプロセッサ ( 2 0 0 ) は、 C P U ( 1 0 0 ) から受けた頂点の座標と、 頂点の輝度と、 項点の奥行きよ り、 図形を構 成する画素の座標と、 描画画素の輝度と、 描画画素の奥行きと、 描画画 素のサブピクセルにおける占有パターンとを算出する画素情報算出部  The detailed block diagrams of the rendering processor (200) are shown in Figs. 5, 6, and 7, and the detailed flow is shown in Fig. 8. The occupancy pattern of the image information calculation unit (210) is shown in Figs. Fig. 9 shows the processing in the calculation unit. First, the CPU (100) issues the vertex coordinates, vertex depth, and IS point luminance of the figure (triangle in this embodiment) from the CPU (100), and the hardware of the rendering processor (200) executes the operation. The screen information calculation unit (210) receives these vertex information. From the coordinates of the vertices received from the CPU (100), the vertex luminance, and the depth of the term, the rendering processor (200) calculates the coordinates of the pixels constituting the figure, the luminance of the drawing pixels, A pixel information calculation unit for calculating the depth of the drawing pixel and the occupation pattern of the drawing pixel in the sub-pixel
( 2 1 0 ) と、 前記画素情報から画像メモリ ( 3 0 0 ) へ記億する情報 の算出を行う画素比較演算部 ( 2 2 0 ) より構成される。  (210) and a pixel comparison operation unit (220) for calculating information to be stored in the image memory (300) from the pixel information.
第 9図に示す様に、 画素情報算出部 ( 2 1 0 ) では、 受け取った頂点 の情報を元に、 頂点間の X値を、 Y座標方向へ 1 /4画素単位に補閒を 行い図形領域の枠を算出する ( 4 1 ) 。 次にサブピクセルの中心点が、 左枠以上、 右枠未満に含まれたサブピクセルを ' 0' とし、 含まれない 場合は ' 1 ' とする ( 4 2 ) 。 図形を構成するある 1 画素内の全てのサ ブピクセルの値を算出したら、 1 6 ビッ 卜の占有パターンとして画素比 較演算部 ( 2 2 0 ) へ受け渡す ( 4 3 ) 。 同時に、 同座標の画素の輝度 と、 同座標の画素の奥行きとを、 画素比較演算部 ( 2 2 0 ) へ受け渡す。 なお、 以後特に断りがない場合は、 画像メモリ ( 3 0 0 ) 内の各メモリ の情報は、 描画画素と同座標のメモリの情報とする。 As shown in Fig. 9, the pixel information calculation unit (210) supplements the X value between vertices in the Y coordinate direction in quarter pixel units based on the received vertex information. Calculate the frame of the area (41). Next, the subpixel whose center point is equal to or greater than the left frame and less than the right frame is set to “0”, and if not included, is set to “1” (42). After calculating the values of all the sub-pixels in one pixel constituting the figure, the value is transferred to the pixel comparison operation unit (220) as a 16-bit occupation pattern (43). At the same time, the luminance of the pixel at the same coordinate and the depth of the pixel at the same coordinate are transferred to the pixel comparison operation unit (2220). In the following, unless otherwise specified, the information of each memory in the image memory (300) is the information of the memory having the same coordinates as the drawing pixel.
第 5図及び第 1 0図の様に、 画素比較演算部 ( 2 2 0 ) は、 最初に描 画画素 ( 3 5 ) の奥行き Z ( 3 3 ) と、 全占有奥行き記憶装置 ( 3 5 0 ) の奥行き A B ( 3 5 2 ) との比較を行う ( 2 2 1 ) 。 該描画画素 ( 3 5 ) の方が奥である場合 (C Oが 0となる場合) は、 視点方向 ( 3 2 ) から 見た画素の状態 ( 3 6 ) は、 手前の画素 ( 3 4 ) によ り、 該描画画素 As shown in FIGS. 5 and 10, the pixel comparison operation unit (220) first stores the depth Z (33) of the picture pixel (35) and the total occupied depth storage device (350). ) Is compared with the depth AB (3 5 2) (2 2 1). When the drawing pixel (35) is deeper (when CO becomes 0), the state of the pixel (36) viewed from the viewpoint direction (32) is changed to the pixel (34) in front. The drawing pixel
( 3 5 ) は隠されて見えない。 そのためフレームバッファ ( 3 1 0 ) の 情報は更新する必要がなので、 その画素の描画を中止する ( 1 7 ) 。 該描画画素 ( 3 5 ) の方が手前、 又は等しい奥行きである場合 (C O が 1 となる場合) は、 次に該描画画素の占有パターン Pと、 占有パター ン記憶装置 ( 3 3 0 ) に格納された占有パターン S Bとの間で、 ビッ ト 単位で論理和 ( P | S B) を求め ( 2 2 2 ) 、 互いの占有パターンの図 形領域部分 (占有パターンのビッ ト力' ' 0' となる部分) が重なるか否 力、、 即ちビッ ト単位論理和を求めた結果の全てのビッ ト力 ' 1 ' となる か否かを判定する。 第 1 1 図に示すように、 図形 ( 5 1 ) と図形( 5 2 ) において隣接する画素 ( 5 3 ) については、 図形 ( 5 1 ) における画素(35) is hidden and invisible. Therefore, the information of the frame buffer (310) needs to be updated, and the drawing of the pixel is stopped (17). If the drawing pixel (35) is closer or equal in depth (when CO becomes 1), then the occupation pattern P of the drawing pixel and the occupation pattern storage device (330) are stored. A logical sum (P | SB) is obtained for each bit between the stored occupation pattern SB (2 2 2), and the figure area portion of each occupation pattern (the bit force of the occupation pattern '0') Is determined as to whether or not they overlap, ie, whether or not all the bit forces '1' as a result of the bit-wise OR are obtained. As shown in FIG. 11, as for the pixel (53) adjacent to the figure (51) and the figure (52), the pixel (53) in the figure (51)
( 5 3 ) の占有パターン ( 5 4 ) と、 図形 ( 5 2 ) における画素( 5 3 ) の占有パターン ( 5 5 ) とのビッ 卜単位論理和の結果 ( 5 6 ) は全ての ビッ トが ' 1 ' となる。 また、 図形 ( 5 7 ) と図形 ( 5 8 ) において重 なる画素 ( 5 9 ) は、 図形 ( 5 7 ) における画素 ( 5 9 ) の占有バタ一 ン( 6 0 ) と、 図形 ( 5 8 ) における画素( 5 9 ) の占有バタ一ン( 6 1 ) とのビッ 卜単位論理和の結果 ( 6 2 ) は重なつた部分のビッ 卜力' ' 0 ' となる。 The result (56) of the bit-wise OR of the occupation pattern (54) of (53) and the occupation pattern (55) of the pixel (53) in the figure (52) is (56) in which all bits are '1'. The pixel (59) overlapping the figure (57) and the figure (58) is the occupied pattern (60) of the pixel (59) in the figure (57) and the figure (58). The result (62) of the bit-wise OR of the pixel (59) with the occupation pattern (61) of the pixel (59) at the point becomes the bit power '' 0 'of the overlapped portion.
つま りビッ 卜単位論理和を求めることで、 描画画素の占有バタ一ンと、 占有パターン記憶装置 ( 3 3 0 ) に格納された占有パターンとの図形領 域部分が重なるか否かを判定することが可能となる。 In other words, by calculating the bit-wise logical OR, the occupation pattern of the drawing pixel and the It is possible to determine whether or not the graphic area portion overlaps with the occupation pattern stored in the occupation pattern storage device (330).
ビッ ト単位で論理和を求めた ( 2 2 2 ) 結果、 1 6ビッ ト全てのビッ 卜力 ' 1 ' である場合 (〇 1カ 1 となる場合) は、 互いの占有パターン の図形領域部分が重ならないとし、 次に該描画画素の輝度 I と、 輝度記 憶装置 ( 34 0 ) の輝度 I Bとで比較を行い ( 2 2 3 ) 、 これらの値が 近似値の関係であるか否かを判定する。 この判) ITは第 6図に示すように, しきい値レジスタ ( 2 3 0 ) に予め設定したしきい値を用いて行う。 描 画画素の輝度の R成分, G成分, B成分をそれぞれ R l, G I, B I と し、 輝度記憶装置 ( 3 4 0 ) の輝度の R成分, G成分, B成分をそれぞ れ R I B, G I B, B I Bとする。 描画画素の輝度と輝度記憶装置  As a result of calculating the logical sum in units of bits (2 2 2), if the bit power of all 16 bits is '1' (〇 1 1), the figure area of the occupied pattern of each other Are not overlapped, the brightness I of the drawing pixel is compared with the brightness IB of the brightness storage device (340) (223), and it is determined whether or not these values are approximate values. Is determined. In this judgment, IT is performed using a threshold value preset in a threshold value register (230) as shown in FIG. The R, G, and B components of the luminance of the picture pixel are Rl, GI, and BI, respectively, and the R, G, and B components of the luminance of the luminance storage device (340) are RIB, GIB, BIB. Drawing pixel brightness and brightness storage device
( 34 0 ) の輝度との差分の絶対値を、 各 R G B成分毎に R S, G S , B Sと して算出する ( 2 2 7 ) 。 そして、 しきい値レジスタ ( 2 3 0 ) で予め設定しておいたしきい値 Rと、 該各 R G B成分毎の差分の絶対値 とを比較する ( 2 2 8 ) 。 R S, G S , B S全てがしきい値 Rより小さ い場合は近似値と判定し、 R S, G S , B Sの内 1つでもしきい値 Rよ りも大きい場合は近似値ではないと判定する。  The absolute value of the difference from the luminance of (340) is calculated as R S, G S, and B S for each RGB component (227). Then, the threshold value R preset in the threshold value register (230) is compared with the absolute value of the difference for each of the RGB components (228). If all of R S, G S, and B S are smaller than the threshold value R, it is determined to be an approximate value. If at least one of R S, G S, and B S is larger than the threshold value R, it is determined that the value is not an approximate value.
しきい値レジスタ ( 2 3 0 ) の設定値は、 近似値と見なす輝度の差分 の絶対値の上限を設定する。 本実施例では、 フレームバッファ( 3 1 0 ) の最大輝度値の約 3割の値を近似値と見なす輝度の差分の上限値とする。 つまり、 フレームバッファ ( 3 1 0 ) の輝度の各成分は 8ビッ トで最大 輝度が 2 5 5であるため、 7 6 をしきい値として設定する。  The value set in the threshold register (230) sets the upper limit of the absolute value of the difference in luminance considered as an approximate value. In this embodiment, about 30% of the maximum luminance value of the frame buffer (310) is set as the upper limit of the luminance difference that is regarded as an approximate value. That is, since each component of the luminance of the frame buffer (310) is 8 bits and the maximum luminance is 255, the threshold value is set to 76.
前記判定 ( 2 2 3 ) で近似値であると判定した場合 (C 2が 1 となる 場合) は、 既に描画が行われた最も手前の画素と、 これから描画を行う 画素が、 連続であると判定する。 次に、 該描画画素の奥行き Zと、 Zバ ッファ ( 3 2 0 ) の奥行き Z Bとの比較を行い ( 2 2 4 ) 、 続けて描画 画素の占有パターン Pと、 占有パターン記焙装置 ( 3 3 0 ) の占有バタ ーン S Bとのビッ ト単位論理積を行う ( 2 2 5 ) 。 If it is determined in the above determination (2 2 3) that the value is an approximate value (when C 2 is 1), it is determined that the foremost pixel that has already been drawn and the pixel to be drawn are continuous. judge. Next, the depth Z of the drawing pixel and the Z After comparing the depth (ZB) of the buffer (320) with the occupation pattern P of the drawing pixel and the occupation pattern SB of the occupation pattern recording device (330), Perform a logical AND operation (2 2 5).
奥行きの比較 ( 2 2 4 ) の結果、 該描画鹵素が Zバッファ ( 3 2 0 ) の奥行きよ りも手前、 又は等しい奥行きである場合 (C 3が 1 となる場 合) に、 ビッ 卜単位論理積 ( P & S B) ( 2 2 5 ) の結果が 1 6 ビッ 卜とも全て ' 0 ' となる場合 (C 4が 1 となる場合) は、 画素情報演算 部 ( 2 2 6 ) において、 第 7図及び第 8図の ( 1 0 ) に対応する処理 (以下の処理(八)(〇)(0) ( )(〇))を行ぃ、 ビッ 卜単位論理積( 2 2 5 ) の結果が 1 6 ビッ トとも全てが ' 0 ' とならない場合は、 画素情報演算 部 ( 2 2 6 ) において、 第 7図及び第 8図の ( 1 1 ) に対応する処理 (以下の処理(A) (C)(D)(F)) を行う。  As a result of the comparison of the depths (2 2 4), if the drawn image is shorter than or equal to the depth of the Z buffer (3 2 0) (when C 3 is 1), the bit unit is If the result of the logical product (P & SB) (2 25) is all '0' for all 16 bits (C 4 is 1), the pixel information calculation unit (2 26) The processing corresponding to (10) in Fig. 7 and Fig. 8 (the following processing (8) (() (0) () (〇)) is performed, and the result of bitwise logical AND (225) If all of the 16 bits are not '0', the pixel information calculation unit (226) performs the processing corresponding to (11) in FIGS. 7 and 8 (the following processing (A)). (C) (D) (F)).
奥行きの比較 ( 2 2 4 ) の結果、 該描画画素が奥である場合 (C 3が 0となる場合) は、 ビッ 卜単位論理積 ( 2 2 5 ) の結果が 1 6 ビッ トと も全て ' 0 ' となる場合 (C 4が 1 となる場合) は、 画素情報演算部 If the result of the depth comparison (2 2 4) indicates that the drawing pixel is at the depth (when C3 is 0), the result of the bit-wise logical AND (2 25) will be all 16 bits If '0' (C4 becomes 1), the pixel information calculation unit
( 2 2 6 ) において、 第 7図及び第 8図の ( 1 2 ) に対応する処理 (以 下の処理(B)(D)(G)) を行い、 ビッ ト単位論理積 ( 2 2 5 ) の結果が 1 6 ビッ トとも全てが ' 0 ' とならない場合 ( C 4が 0となる場合) は、 画素情報演算部 ( 2 2 6 ) において、' 第 7図及び第 8図の ( 1 3 ) に対 応する処理 (以下の処理(B)(D) ) を行う。 In (2 26), the processing corresponding to (1 2) in FIGS. 7 and 8 (the following processing (B), (D), and (G)) is performed, and the bit-wise logical AND (2 25 If the result of (16) does not become all “0” in all 16 bits (when C4 becomes 0), the pixel information calculation unit (2226) sets “(1)” in FIG. 7 and FIG. The processing corresponding to 3) (the following processing (B) and (D)) is performed.
一方、 前記判定 ( 2 2 3 ) で近似値ではないと判定した場合 (C 2力 0 となる場合) 、 又は ( 2 2 2 ) において、 該描.画画素の占有パターン Pと、 占有パターン記憶装置 ( 3 3 0 ) に格納された占有パターン S B とで、 ビッ 卜単位で論理和を行った結果、 1 6 ビッ 卜全てのビッ 卜が On the other hand, when it is determined in the above determination (2 2 3) that the value is not an approximate value (when the C 2 force becomes 0), or in (2 2 2), the occupation pattern P of the drawing pixel and the occupation pattern storage As a result of performing a logical OR on a bit-by-bit basis with the occupation pattern SB stored in the device (330), all of the 16 bits are
' 1 ' とならない場合 (C 1 が 0となる場合) は、 既に描画が行われた 最も手前の画素と、 これから描画を行う画素が、 連続ではないと判定す る。 次に、 該描画画素の奥行きと、 Zバッファ ( 3 2 0 ) との比較を行 い ( 2 2 4 ) 、 続けて描画画素の占有パターン Pと、 占有パターン記憶 装置 ( 3 3 0 ) の占有パターン ( S B) とのビッ 卜単位論理積を行う ( 2 2 5 ) 。 If it does not become '1' (C 1 becomes 0), drawing has already been performed It is determined that the foreground pixel and the pixel to be rendered are not continuous. Next, the depth of the drawing pixel is compared with the Z buffer (320) (224), followed by the occupation pattern P of the drawing pixel and the occupancy of the occupation pattern storage device (330). Performs a bit-wise AND operation with the pattern (SB) (225).
奥行きの比較 ( 2 2 4 ) の結果、 該描画画素が手前、 又は等しい奥行 きである場合に、 ビッ 卜単位論理お ΐ ( 2 2 5 ) の結果が 1 6 ビッ トとも 全て ' 0 ' となる場合は、 画素情報演算部 ( 2 2 6 ) において、 第 7図 及び第 8図の ( 1 4 ) に対応する処理 (以下の処理 (A) (C)(E) (F) (G)) を行い、 ビッ 卜単位論理積 ( 2 2 5 ) の結果が 1 6 ビッ トとも全 てが ' 0 ' とならない場合は、 画素情報演算部 ( 2 2 6 ) において、 第 7図及び第 8図の ( 1 5 ) に対応する処理 (以下の処理(A)(C)(E) (F)) を行う。 又、 奥行き比較 ( 2 2 4 ) の結果、 該描画画素が奥であ れば、 画素情報演算部 ( 2 2 6 ) において、 第 7図及び第 8図の( 1 5 ) に対応する処理 (以下の処理(B)) を行う。  As a result of the comparison of the depths (2 24), if the drawing pixel is the front or the same depth, the result of the bit unit logic 2 (2 25) is all '0' for both 16 bits. If this is the case, the pixel information calculation unit (2 26) performs processing corresponding to (14) in FIGS. 7 and 8 (the following processing (A) (C) (E) (F) (G) ), And if the result of the bit-wise logical AND (2 25) is not all “0” for both 16 bits, the pixel information calculation unit (2 26) performs the operations shown in FIGS. The processing corresponding to (15) in the figure (the following processing (A) (C) (E) (F)) is performed. As a result of the depth comparison (2 24), if the drawing pixel is located at the depth, the pixel information calculation unit (2 26) performs processing corresponding to (15) in FIG. 7 and FIG. The following processing (B)) is performed.
以上の処理で、 更新を行わなかった画像メモリ ( 3 0 0 ) 内の各メモ リは、 該描画画素の描画を行う前の情報をそのまま記憶しておく ものと する。  In the above processing, each memory in the image memory (300) that has not been updated stores the information before drawing the drawing pixel as it is.
以下に、 画素情報演算部 ( 2 2 6 ) における処理 (A)〜(G) とその 概要を示す。  The processing (A) to (G) in the pixel information calculation unit (226) and the outline thereof are described below.
またここで、 ( a & b )は aと bのビッ ト単位論理積、 ( a | b)は a と bのビッ 卜単位論理和、 N 0 T ( a )は aのビッ 卜単位否定を表すも のとする。  Where (a & b) is the bitwise AND of a and b, (a | b) is the bitwise OR of a and b, and N 0 T (a) is the bitwise negation of a. Shall be represented.
また以下の各処理の説明においては、 描画画素の占有パターンを 'P' 、 占有パターン記憶装置 ( 3 3 0 ) に記憶されている占有パターンを ' S B' と表す。 In the following description of each process, the occupation pattern of the drawing pixel is “P”, and the occupation pattern stored in the occupation pattern storage device (330) is “P”. Expressed as 'SB'.
処理 (A) Processing (A)
Ral : Pの ' 0 ' の割合  Ral: percentage of P '0'
Ra2 : ( S B I 1^〇丁(?))の ' 0 ' の割合  Ra2: Percentage of '0' in (SBI 1 ^ 〇 〇 (?))
Ra3 : 1. 0 - Ral― Ra2  Ra3: 1.0-Ral― Ra2
フレームバッファ ( 3 1 0 ) の R成分 ―  R component of frame buffer (310)-
描画画素の輝度の R成分 X Ral  R component of luminance of drawing pixel X Ral
+ 輝度記憶装置 ( 3 4 0 ) の婶度の R成分 X Ra2 + フレームバッファ ( 3 1 0 ) の輝度の R成分 X Ra3 フレームバッファ ( 3 1 0 ) の G成分 ―  + The luminance R component of the luminance storage device (340) X Ra2 + The luminance R component of the frame buffer (310) X Ra3 The G component of the frame buffer (310)-
描画画素の輝度の G成分 X Ral  G component of drawing pixel luminance X Ral
+ 輝度記憶装置 ( 3 4 0 ) の輝度の G成分 X Ra2 + フレームバッファ ( 3 1 0 ) の輝度の G成分 X Ra3 フレームバッファ ( 3 1 0 ) の B成分 ―  + G component of luminance of luminance storage device (340) X Ra2 + G component of luminance of frame buffer (310) X B component of Ra3 frame buffer (310)-
描画画素の輝度の B成分 X Ral  B component of drawing pixel luminance X Ral
+ 輝度記憶装置 ( 3 4 0 ) の) ¾i度の B成分 X Ra2 十 フレームバッファ ( 3 1 0 ) の輝度の B成分 X Ra3 処理 (A) の概要  + Luminance storage device (3440) B component of 度 i degree X Ra2 tens B component of luminance of frame buffer (310) X Ra3 Outline of processing (A)
第 1 2図の例により、 処理 (A) の概要を説明する。 処理 (A) は、 Zバッファ ( 3 2 0 ) から読み出した奥行き ( 3 2 3 ) よりも描画画素 の奥行き ( 7 5 ) の方が手前、 又は等しい奥行きにある時にフレームバ ッファ ( 3 1 0 ) に記憶する輝度を算出する処理である。  The outline of the process (A) will be described with reference to the example of FIG. The processing (A) is performed when the depth (75) of the drawing pixel is closer to or equal to the depth (32) read out from the Z buffer (320). ) Is a process of calculating the luminance to be stored.
視点方向 ( 7 0 ) から見えるある画素のサブピクセルにおける領域 ( 7 1 ) と ( 7 2 ) と ( 7 3 ) とを、 各々の輝度によリサブピクセルを 占有する割合で重み付けし、 平均化した輝度 ( 3 1 3 ) をフレームバッ ファ ( 3 1 0 ) に記憶する。 The regions (71), (72), and (73) in a subpixel of a certain pixel viewed from the viewpoint direction (70) are weighted by the ratio of occupying the subpixel by each luminance and averaged. The brightness (3 1 3) (3 1 0).
視線方向 ( 7 0 ) から見た領域 ( 7 1 ) は描画画素の輝度 ( 7 4 ) に よ り、 描画画素の占有パターン ( 7 6 ) の ' 0 ' の割合である 9 Z 1 6 を占めている。 視線方向 ( 7 0 ) から見た領域 ( 7 2 ) は、 輝度記憶装 置 ( 3 4 0 ) から読み出した輝度 ( 3 3 3 ) により、 (占有パターン記 憶装置 ( 3 3 0 ) から読み出した占有パターン ( 3 4 3 ) I N O T (描画画素の占有パターン( 7 6 ))の ' 0 ' の割合である 3 1 6 を占め ている。 領域( 7 3 ) の割合は、 1. 0— 9ノ 1 6 - 3 / 1 6 = 4 / 1 6 となる力 領域 ( 7 3 ) の輝度はわからないため、 現在のフレームバッ ファ ( 3 1 0 ) から読み出した輝度とする。 フレームバッファ( 3 1 0 ) の輝度は、 以前に画素の描画を行った時に領域 ( 7 3 ) の輝度を用いて 平均化を行っているため、 フレームバッファ ( 3 1 0 ) の輝度を領域 The area (71) viewed from the line-of-sight direction (70) occupies 9Z16, which is the ratio of '0' in the pattern (76) occupied by the drawing pixel, due to the luminance (74) of the drawing pixel. ing. The area (72) viewed from the line-of-sight direction (70) is read from the occupancy pattern storage device (330) by the brightness (333) read from the brightness storage device (340). Occupancy pattern (3 4 3) Occupies 3 16 which is the proportion of '0' in INOT (occupation pattern (76) of drawing pixels) 76. The proportion of area (73) is 1.0-9 Since the brightness of the force region (73) where 16-3/16 = 4/16 is not known, the brightness read from the current frame buffer (310) is used. The brightness of the frame buffer (310) is calculated by averaging the brightness of the area (73) when the pixel was previously drawn, using the brightness of the area (73).
( 7 3 ) の輝度とすることにより、 本来の領域 ( 7 3 ) の輝度をいく ら か反映させることが出来る。 By setting the brightness of (73), the brightness of the original region (73) can be reflected to some extent.
処理 ( B ) Processing (B)
R b 1 : ( P I N 0 T ( S B ) )の ' 0 ' の割合  R b 1: Ratio of '0' in (PIN 0 T (S B))
Rb2 : S Bの ' 0 ' の割合  Rb2: ratio of '0' in SB
Rb3 : 1. 0 - Rbl - Rb2  Rb3: 1.0-Rbl-Rb2
フレームバッファ ( 3 1 0 ) の R成分  R component of the frame buffer (310)
描画画素の輝度の R成分 X Rbl  R component of drawing pixel luminance X Rbl
+ 輝度記憶装置 ( 3 4 0 ) の輝度の R成分 X Rb2  + R component of luminance of luminance storage device (340) X Rb2
+ フレームバッファ ( 3 1 0 ) の輝度の. R成分 X Rb3 フレームバッファ ( 3 1 0 ) の G成分 ―  + R component of the luminance of the frame buffer (310). X Rb3 G component of the frame buffer (310).
描画画素の輝度の G成分 X Rbl  G component of drawing pixel luminance X Rbl
+ 輝度記憶装置 ( 3 4 0 ) の輝度の G成分 X Rb2 + フ レームバッファ ( 3 1 0 ) の輝度の G成分 X Rb3 + G component of luminance of luminance storage device (340) X Rb2 + G component of frame buffer (310) luminance X Rb3
フ レームバッファ ( 3 1 0 ) の B成分 ―  B component of frame buffer (310)-
描画画素の輝度の B成分 X Rbl  B component of drawing pixel luminance X Rbl
+ 輝度記憶装置 ( 3 4 0 ) の輝度の B成分 X Rb2  + B component of luminance of luminance storage device (340) X Rb2
+ フレームバッファ ( 3 1 0 ) の輝度の B成分 X Rb3 処理 ( 13 ) の概要  + Overview of B component X Rb3 processing (13) of luminance of frame buffer (310)
第 1 3図の例により、 処理 (B ) の概要を説明する。 第 1 3図の例は、 これから描画を行う画素が、 以前に描画を行った画素の中で手前から 2 番目に位置するものとし、 それ以外の場合は例外と して後述する,, 処理 ( B ) は、 Zバッフ ァ ( 3 2 0 ) から読み出した奥行き ( 3 2 4 ) より、 描 (ij画素の奥行き( 8 5 )の方が奥である時にフレームバッファ( 3 1 0 ) に記 ΐδする輝度を算出する処理である。  An outline of the process (B) will be described with reference to the example of FIG. The example in Fig. 13 assumes that the pixel to be rendered is located second from the front of the pixels that have been rendered before, and otherwise, B) is stored in the frame buffer (310) when the depth (85) of the ij pixel is deeper than the depth (324) read from the Z buffer (320). This is the process of calculating the brightness to be performed.
視点方向 ( 8 0 ) から見えるある画素のサブピクセルにおける領域  Area in a sub-pixel of a certain pixel seen from the viewpoint direction (80)
( 8 1 ) と ( 8 2 ) と ( 8 3 ) とを、 各々の輝度によりサブピクセルを 占有する割合で重み付けし、 平均化した輝度 ( 3 1 4 ) をフレームバッ ファ ( 3 1 0 ) に記憶する。  (81), (82), and (83) are weighted by the ratio of occupying sub-pixels by their respective intensities, and the averaged intensity (3, 14) is assigned to the frame buffer (3, 10). Remember.
視線方向 ( 8 0 ) から見た領域 ( 8 1 ) は、 描画画素の輝度 ( 8 4 ) により (描画画素の占有パターン ( 8 6 ) [ N O T (占有パターン記 億装置 ( 3 3 0 ) から読み出した占有パターン(3 4 4 ))の ' 0 ' の割 合である 5ノ 1 6 を占めている。 視線方向( 8 0 ) から見た領域( 8 2 ) は、 輝度記憶装置 ( 3 4 0 ) から読み出した輝度 ( 3 3 4 ) により、 占 有パターン記憶装置 ( 3 3 0 ) から読み出した占有パターン ( 3 4 4 ) の ' 0' の割合である 7 / 1 6 を占めている。 領域 ( 8 3 ) の割合は、 1. 0 - 5 / 1 6 - 7 / 1 6 = 4 / 1 6 となるが、 領域 ( 8 3 ) の輝度 はわからないため、 現在のフレームバッファ ( 3 1 0 ) から読み出した 輝度とする。 フ レームバッファ ( 3 1 0 ) の輝度は、 以前に画素の描画 を行った時に領域 ( 8 3 ) の輝度を用いて平均化を行っているため、 フ レームバッファ ( 3 1 0 ) の輝度を領域 ( 8 3 ) の輝度とすることによ り、 本来の領域 ( 8 3 ) の輝度をいく らか反映させることが出来る。 処理 (C) The area (81) viewed from the line-of-sight direction (80) is determined by the drawing pixel luminance (84) (drawing pixel occupation pattern (86) [NOT (read from occupation pattern storage device (330)). The occupation pattern (3 4 4)) occupies 5 to 16 which is the ratio of '0'.The area (8 2) viewed from the line of sight (80) is the luminance storage device (3 4 0). ) Occupies 7/16 of the occupied pattern (3444) read from the occupied pattern storage device (330), which is the ratio of '0'. The ratio of (83) is 1.0-5/16-7/16 = 4/16, but the brightness of the area (83) is not known, so the current frame buffer (310) Read from Let it be luminance. Since the luminance of the frame buffer (310) is averaged using the luminance of the area (83) when the pixel was previously drawn, the luminance of the frame buffer (310) is calculated as follows. By setting the brightness of the area (83), the brightness of the original area (83) can be reflected to some extent. Processing (C)
Zバッファ ( 3 2 0 ) ― 描画画素の奥行き  Z buffer (320)-Depth of drawing pixel
処理 (C) の概要 Overview of processing (C)
処理 (C) は、 Zバッファ ( 3 2 0 ) から読み出した奥行きより、 描 画画素の奥行きの方が手前又は等しい時に、 Zバッファ ( 3 2 0 ) に描 画画素の奥行きを記憶し更新する処现である。  The processing (C) stores and updates the depth of the drawing pixel in the Z buffer (320) when the depth of the drawing pixel is closer or equal to the depth read from the Z buffer (320). It is processing.
処理 (D) Processing (D)
占有パターン記憶装置 ( 3 3 0 ) ( P & S B)  Occupancy pattern storage device (330) (P & S B)
処理 (D) の概要 Overview of processing (D)
第 1 4図の例により、 処理 (D) の概要を説明する。 処理 (D) は、 描画画素と以前に描画を行った最も手前の画素とが連続であると判定し た時に、 占有パターンの合成を行い占有パターン記憶装置 ( 3 3 0 ) へ 記憶する処理である。 画素 ( 9 0 ) において、 描画画素の占有パターン ( 9 1 ) と占有パターン記憶装置 ( 3 3 0 ) から読み出した占有パター ン ( 9 2 ) とで、 ビッ ト単位論理積を行うことで互いの図形領域 ( ' 0 ' の領域) を合成し ( 9 3 ) 、 1つの画素の図形領域として占有パターン 記憶装置 ( 3 3 0 ) に記憶する処理である。  The outline of the process (D) will be described with reference to the example of FIG. The process (D) is a process of synthesizing an occupation pattern and storing the occupation pattern in the occupation pattern storage device (330) when it is determined that the drawing pixel and the foremost pixel that has been previously drawn are continuous. is there. In the pixel (90), the occupation pattern (91) of the drawing pixel and the occupation pattern (92) read from the occupation pattern storage device (330) are bit-wise ANDed with each other to perform the logical AND operation. This is a process of synthesizing the graphic area (area of '0') (93) and storing it as a graphic area of one pixel in the occupation pattern storage device (330).
処理 (E) Processing (E)
占有パターン記憶装置 ( 3 3 0 ) ― P  Occupancy pattern storage device (330)-P
処理 (E) の概要 Overview of processing (E)
処理 ( E) は、 描画画素と以前に描画を行った最も手前の画素とが連 続ではないと判定し、 且つ Zバッファ ( 3 2 0 ) の奥行きよりも描画画 素の奥行きの方が手前または等しい奥行きである時に、 占有パターン記 憶装置 ( 3 3 0 ) に描画画素の占有パターンを記憶する処理である。 処理 ( F) In the processing (E), the drawing pixel is connected to the foremost pixel that has been previously drawn. Occupied pattern storage device (330) when it is determined that the connection is not continuous and the depth of the drawing pixel is closer to or equal to the depth of the Z buffer (320). This is a process of storing a pattern. Processing (F)
輝度記憶装置 ( 3 4 0 ) ― 描画画素の輝度  Luminance storage device (340)-luminance of drawing pixel
処理 ( F) の概要  Overview of processing (F)
処理 ( F) は、 Zバッファ ( 3 2 0 ) の奥行きよりも描画画素の奥行 きの方が手前または等しい奥行きである時に、 輝度記' It装置 ( 3 4 0 ) に描画 m の輝度を記憶する処理である。  The processing (F) stores the brightness of the drawing m in the luminance storage device (340) when the depth of the drawing pixel is closer or equal to the depth of the Z buffer (320). This is the process to do.
処理 (G) Processing (G)
全占有奥行き記憶装置 ( 3 5 0 ) ― 描画画素の奥行き  Total occupied depth storage device (350)-Depth of drawing pixel
処理 (G) の概要 Overview of processing (G)
処理 (G) は、 処理 (D) 又は処理 (E) により占有パターン記憶装 置 ( 3 3 0 ) の更新処理を行い、 且つ描画画素の占有パターン ( P) と 占有パターン記憶装置 ( 3 3 0 ) から読み出した占有パターン ( S B) とのビッ ト単位論理積が、 1 6 ビッ ト全て力 ' 0 ' (画素の図形領域が 1 0 0 %) となる時に、 全占有奥行き記憶装置 ( 3 5 0 ) に描画要素の 奥行きを記憶する処理である。  In the process (G), the occupation pattern storage device (330) is updated by the process (D) or the process (E), and the occupation pattern (P) of the drawing pixel and the occupation pattern storage device (330) are updated. When the bit-wise AND with the occupation pattern (SB) read from) is 16 bits, the total occupied depth storage device (35%) becomes “0” (100% of the pixel graphic area). 0) is a process of storing the depth of the drawing element.
以上の演算を、 図形を構成する全ての画素に対して行うことで、 アン チェイ リァス処理が可能となる。  By performing the above operation on all the pixels constituting the figure, an unchained process can be performed.
以上の処理を行う上で、 例外として以下のような場合が起こる可能性 がある。 第 1 3図において、 これから描画を行う画素 ( 8 5 ) の奥行き が、 以前に描画を行った画素の奥行きの中で、 手前から 2番目に位置す るときの輝度を理想的な輝度とすると、 手前から 3番目以降である場合、 つま り描画を行う画素 ( 8 5 ) と、 以前に描画を行った最も手前の画素 の奥行き ( 3 2 4 ) の間に、 以前に描画を行った他の画素が存在する場 合は、 理想的な輝度とは異なった結采となる。 In performing the above processing, the following cases may occur as exceptions. In Fig. 13, if the depth of the pixel (85) to be drawn is the second closest to the front of the depth of the previously drawn pixel, the ideal brightness is If it is the third or later from the front, that is, the pixel to be drawn (85) and the foremost pixel that has been previously drawn If there is another pixel that has been previously drawn between the depths of (3 2 4), the result will be different from the ideal luminance.
第 1 5図のように 2つの画素の輝度が近似値で、 隣接していながらわ ずかに隙間がある画素( 6 3 )において、 描画画素の占有パターン( 6 4 ) と占有パターン記憶装置 ( 3 3 0 ) の占有パターン ( 6 5 ) との、 ビッ 卜単位の論理和の結果 ( 6 6 ) は全て ' 1 ' となるため、 画素は速続で あると誤って判定してしまう。 又、 2つの M素が隣接していながら輝度 が近似値でない場合は、 画素が連続ではないと誤って判定してしまう。 以上の様に連続であるか否かの判定を誤った場合は、 占有バタ一ンの図 形領域の合成を行うか否かの判定も誤るため、 結果的に誤った占有バタ —ンを占有パターン記憶装置 ( 3 3 0 ) に記憶してしまう。 そのため、 後に同座標に画素の描画を行った際に、 誤った占有パターンの ' 0 ' の 割合から輝度の計算を行うため、 フレームバッファ ( 3 1 0 ) の輝度力、 理想的な輝度にならない場合がある。 特に、 描画画素の奥行きが、 Zバ ッファ ( 3 2 0 ) の奥行きより、 奧である場合において、 占有パターン 記憶装置 ( 3 3 0 ) の占有パターンは最も手前に位置するため、 視点方 向から見た占有パターン記憶装置の占有バターンの割合は大きくなる可 能性が高いため、 輝度を算出する際にこの占有パターンの割合が大きく 関わってくる。  As shown in Fig. 15, in the pixel (63) where the brightness of two pixels is an approximate value and there is a slight gap between adjacent pixels, the occupation pattern (64) of the drawing pixel and the occupation pattern storage device ( Since the result (66) of the bitwise OR of the occupation pattern (65) of (330) is all '1', the pixel is erroneously determined to be continuous. Also, if the luminance is not an approximate value while two M elements are adjacent, it is erroneously determined that the pixels are not continuous. As described above, if the determination as to whether or not they are continuous is incorrect, the determination as to whether or not to combine the graphic area of the occupied pattern is also erroneously made, resulting in the occupation of the wrong occupied pattern. It is stored in the pattern storage device (330). Therefore, when the pixel is drawn later at the same coordinates, the luminance is calculated from the ratio of '0' of the wrong occupation pattern, so that the luminance power of the frame buffer (310) does not become the ideal luminance. There are cases. In particular, when the depth of the drawing pixel is deeper than the depth of the Z buffer (320), the occupied pattern of the occupied pattern storage device (330) is located at the foreground. Since the ratio of the occupation pattern of the occupation pattern storage device to be seen is likely to be large, the ratio of the occupation pattern is greatly involved in calculating the luminance.
しかし、 この様な誤判定がおこることは確率的に少なく、 また で見 てもほとんど認識できないレベルであるため、 以上の様な誤差は通常は 問題とならない。  However, since such erroneous determinations occur with a low probability and are at a level that is hardly recognizable even when viewed from above, such errors are usually not a problem.
更に精度の高い画像を得る方法として、 画素比較演算部 ( 2 2 0 ) に おいて奥の画素から、 手前の画素の順に描画を行う Zソー ト法を用いる ことが挙げられる。 Zソー ト法により、 描画画素の奥行きは、 必ず Zバ ッファ ( 3 2 0 ) の奥行きより手前、 又は等しいため、 処理 ( B) を実 行しなくなる。 その結果、 画素の速続か否かの判定を誤っても、 フレー ムバッファ ( 3 1 0 ) の輝度が、 理想的な輝度に近くなる。 産業上の利用可能性 As a method of obtaining an image with higher accuracy, there is a method of using a Z-sort method in which the pixel comparison operation unit (220) draws in order from the pixel at the back to the pixel at the front. By the Z-sort method, the depth of the drawing pixel must be Since the depth of the buffer (320) is shorter than or equal to the depth of the buffer (320), the processing (B) is not executed. As a result, the luminance of the frame buffer (310) becomes close to the ideal luminance even if the determination of whether or not the pixel is continuous is incorrect. Industrial applicability
以上のように、 本発明では、 1 素単位で保持している最も手前の占 有パターンを用いて輝度の演算を行うことでアンチエイ リアス処理を 1 回の描画で行うために、 従来の方式に比べて描画が高速であり、 かつ少 ないメモリでアンチエイ リアス処理を行うのに適している。  As described above, in the present invention, the anti-aliasing process is performed by one drawing by performing the brightness calculation using the foreground occupation pattern held in one element unit, so that the conventional method is used. It is faster to draw and is suitable for performing anti-aliasing with less memory.

Claims

請 求 の 範 囲 The scope of the claims
1 . 3次元画像処理装置において、  1. In a three-dimensional image processing device,
描画図形を構成する各画素について複数に分割した領域 (以後、 サブ ピクセル) の各々が当該図形の領域に含まれるか否かを表すパターン (以後、 占有パターン) を求めるサブピクセルパターン生成手段と、 3次元画像を描画する際に最も手前に描画される幽素の前記占有バタ 一ンを記憶する占有バタ一ン記 tS手段と  A sub-pixel pattern generating means for obtaining a pattern (hereinafter, an occupation pattern) indicating whether or not each of a plurality of divided regions (hereinafter, “sub-pixels”) is included in the region of the figure for each pixel constituting the drawing graphic; An occupancy pattern storage means for storing the occupancy pattern of the ghost drawn in the foreground when drawing a three-dimensional image;
を有することを特徴とする 3次元画像処理装置。 A three-dimensional image processing apparatus comprising:
2 . 3次元画像を描画する際に: ¾も乎前に描画される画素の輝度情報を 記憶する輝度記憶手段を有することを特徴とする請求の範囲第 1 ¾記載 の 3次元豳像処理装置。  2. When rendering a three-dimensional image: The three-dimensional image processing apparatus according to claim 1, further comprising: a luminance storage unit configured to store luminance information of a pixel to be rendered immediately before. .
3 . 前記サブピクセルが全て図形の領域に含まれる画素の内で、 3次元 画像を描画する際に最も手前に描幽される画素の奥行き情報を記憶する 奥行き情報記憶手段を有することを特徴とする請求の範囲第 1項記載の 3次元画像処理装置。  3. Depth information storage means for storing depth information of a pixel drawn in the foreground when drawing a three-dimensional image, among the pixels in which all of the sub-pixels are included in the graphic region. 3. The three-dimensional image processing apparatus according to claim 1, wherein:
4 . 描画対象となる画素の占有パターンと前記占有パターン記憶装置に 記憶されている同一座標の占有パターンとの比較を行い、 当該比較結果 に基づき、  4. The occupation pattern of the pixel to be drawn is compared with the occupation pattern of the same coordinates stored in the occupation pattern storage device, and based on the comparison result,
前記描画対象となる画素の輝度情報とフレームバッファ及び前記輝度 記憶装置に記憶された前記描画対象となる画素と同一座標の輝度情報を 用いて演算を行い、  An operation is performed using luminance information of the pixel to be rendered and luminance information of the same coordinates as the pixel to be rendered stored in the frame buffer and the luminance storage device,
当該演算の結果をフレームバッファに記憶させる画素比較演算部を有 することを特徴とする請求の範囲第 2項記載の 3次元画像処理装置。 3. The three-dimensional image processing device according to claim 2, further comprising a pixel comparison operation unit that stores a result of the operation in a frame buffer.
5 . 描画対象となる画素の輝度情報と前記輝度記憶装置に記憶されてい る同一座標の輝度情報との差分が予め定められた範囲内である場合は、 これから描画を行う画素の占有パターンと前記占有パターン記憶装置に 記憶している同一座標の占有バタ一ンとの合成を行い、 当該合成された 結果を前記占有パターン記憶装置に記憶させる画素比較演算部を有する ことを特徴とする請求の範囲第 2項記載の 3次元画像処理装置。 5. If the difference between the luminance information of the pixel to be drawn and the luminance information of the same coordinates stored in the luminance storage device is within a predetermined range, A pixel comparison operation unit that combines an occupation pattern of a pixel to be drawn and an occupation pattern of the same coordinates stored in the occupation pattern storage device, and stores the combined result in the occupation pattern storage device. 3. The three-dimensional image processing apparatus according to claim 2, comprising:
6 . 前記画棄比較演算部においては、 描画を行う画素について Z ソー ト (奥の画素から手前の画素の順序で描画) を行うことを特徴とする請求 の範囲第 1 項記載の 3次元処 ¾装置。 6. The three-dimensional processing according to claim 1, wherein the rejection comparison operation unit performs a Z sort (drawing in order from the back pixel to the front pixel) for the pixel to be drawn. ¾ Equipment.
PCT/JP1996/002199 1996-08-05 1996-08-05 Three-dimensional image processor WO1998006065A1 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
PCT/JP1996/002199 WO1998006065A1 (en) 1996-08-05 1996-08-05 Three-dimensional image processor

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
PCT/JP1996/002199 WO1998006065A1 (en) 1996-08-05 1996-08-05 Three-dimensional image processor

Publications (1)

Publication Number Publication Date
WO1998006065A1 true WO1998006065A1 (en) 1998-02-12

Family

ID=14153647

Family Applications (1)

Application Number Title Priority Date Filing Date
PCT/JP1996/002199 WO1998006065A1 (en) 1996-08-05 1996-08-05 Three-dimensional image processor

Country Status (1)

Country Link
WO (1) WO1998006065A1 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11345218A (en) * 1998-04-03 1999-12-14 Sony Corp Image processor and its method

Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS63113785A (en) * 1986-10-31 1988-05-18 Hitachi Ltd Graphic pattern displaying method
JPH04343185A (en) * 1990-10-30 1992-11-30 Sun Microsyst Inc Apparatus and method for generating graphic image

Patent Citations (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPS63113785A (en) * 1986-10-31 1988-05-18 Hitachi Ltd Graphic pattern displaying method
JPH04343185A (en) * 1990-10-30 1992-11-30 Sun Microsyst Inc Apparatus and method for generating graphic image

Non-Patent Citations (1)

* Cited by examiner, † Cited by third party
Title
NIKKEI CG, January 1988, TOSHIAKI KATO, "Method for Eliminating Aliasing Used for High-Quality Image Generation", p. 138-142. *

Cited By (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH11345218A (en) * 1998-04-03 1999-12-14 Sony Corp Image processor and its method
JP4505866B2 (en) * 1998-04-03 2010-07-21 ソニー株式会社 Image processing apparatus and video signal processing method

Similar Documents

Publication Publication Date Title
US6509897B1 (en) Method and system for providing implicit edge antialiasing
US6529207B1 (en) Identifying silhouette edges of objects to apply anti-aliasing
US6201545B1 (en) Method and apparatus for generating sub pixel masks in a three dimensional graphic processing system
US6104407A (en) Method and apparatus for processing fragment pixel information in a three-dimensional graphics processing system
US6456284B1 (en) Graphics processor, system and method for generating screen pixels in raster order utilizing a single interpolator
US6184903B1 (en) Apparatus and method for parallel rendering of image pixels
US6963346B2 (en) Method and system for efficiently using fewer blending units for antialiasing
JP4332934B2 (en) Anti-aliasing method and image processing apparatus using the same
JPH0727581B2 (en) Graphic processing device
JPH0224784A (en) Computer display device and method
US20040100474A1 (en) Apparatus for generating anti-aliased and stippled 3d lines, points and surfaces using multi-dimensional procedural texture coordinates
EP0952546B1 (en) Image color blending processor
EP1295256B1 (en) Method and system for image rendering with tiles
US6172680B1 (en) Method and apparatus for a three-dimensional graphics processing system including anti-aliasing
JP3037865B2 (en) 3D sprite drawing device
US8648874B2 (en) Method and system for providing edge antialiasing
WO1998006065A1 (en) Three-dimensional image processor
US5499324A (en) Graphic display apparatus with improved shading capabilities
EP0441490A2 (en) Apparatus and method of encoding control data in a computer graphics system
US6937251B2 (en) Method and system for improving color quality of three-dimensional rendered images
US20030028568A1 (en) System and method for a single-pass multiple tap filter
WO1999054847A1 (en) Three-dimensional image processor
US6859205B1 (en) Apparatus and method for drawing lines
JP3626709B2 (en) Anti-aliasing device
JP3739829B2 (en) Graphics equipment

Legal Events

Date Code Title Description
AK Designated states

Kind code of ref document: A1

Designated state(s): CA CN JP KR US

AL Designated countries for regional patents

Kind code of ref document: A1

Designated state(s): AT BE CH DE DK ES FR GB GR IE IT LU MC NL PT SE

DFPE Request for preliminary examination filed prior to expiration of 19th month from priority date (pct application filed before 20040101)
121 Ep: the epo has been informed by wipo that ep was designated in this application
122 Ep: pct application non-entry in european phase
NENP Non-entry into the national phase

Ref country code: CA