JP2005078357A - Image processor and its method - Google Patents

Image processor and its method Download PDF

Info

Publication number
JP2005078357A
JP2005078357A JP2003307649A JP2003307649A JP2005078357A JP 2005078357 A JP2005078357 A JP 2005078357A JP 2003307649 A JP2003307649 A JP 2003307649A JP 2003307649 A JP2003307649 A JP 2003307649A JP 2005078357 A JP2005078357 A JP 2005078357A
Authority
JP
Japan
Prior art keywords
memory
cache
image processing
interface
pixel
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.)
Granted
Application number
JP2003307649A
Other languages
Japanese (ja)
Other versions
JP4419480B2 (en
Inventor
Tanio Nagasaki
多仁生 長崎
Seigo Iwasaki
誠吾 岩崎
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 JP2003307649A priority Critical patent/JP4419480B2/en
Publication of JP2005078357A publication Critical patent/JP2005078357A/en
Application granted granted Critical
Publication of JP4419480B2 publication Critical patent/JP4419480B2/en
Anticipated expiration legal-status Critical
Expired - Fee Related legal-status Critical Current

Links

Images

Abstract

<P>PROBLEM TO BE SOLVED: To provide an image processor and its method capable of avoiding increases in area and electric power, simplifying a memory access mechanism, reducing design load, and being independent of a memory system. <P>SOLUTION: A rasterization engine 32 accesses the memory through a memory interface 22. A cache system 324 is provided between a texture pixel engine which processes texture and pixel levels and the memory interface. The function of generating the true address in a way depending on an image memory architecture is divided between the method of a command that is independent of the image memory architecture and the method of delivering data, whereby the memory access of image processing is separated into a cache that does not depend on the image process memory architecture. <P>COPYRIGHT: (C)2005,JPO&NCIPI

Description

本発明は、モデルを単位図形の組み合わせによって表現し、スクリーン座標系の描画対象領域内にピクセルを発生し、メモリに対してレンダリング処理を行う画像処理装置およびその方法に関するものである。   The present invention relates to an image processing apparatus and method for expressing a model by a combination of unit graphics, generating pixels in a drawing target area of a screen coordinate system, and performing a rendering process on a memory.

昨今のコンピュータシステムにおける演算速度の向上や描画機能の強化とも相俟って、コンピュータ資源を用いて図形や画像の作成や処理を行う「コンピュータ・グラフィックス(CG)」技術が盛んに研究・開発され、さらに実用化されている。   Combined with improvements in computing speed and enhancement of drawing functions in recent computer systems, research and development of “computer graphics (CG)” technology that creates and processes graphics and images using computer resources is actively conducted. Has been put to practical use.

たとえば、3次元グラフィックスは、3次元オブジェクトが所定の光源によって照らされたときの光学現象を数学モデルで表現して、このモデルに基づいてオブジェクト表面に陰影や濃淡を付けたり、さらには模様を貼り付けたりして、よりリアルで3次元的な2次元高精細画像を生成するものである。
このようなコンピュータ・グラフィックスは、科学、工学、製造などの開発分野でのCAD/CAM、その他の各種応用分野においてますます盛んに利用されるようになってきている。
そして、近年、コンピュータ・グラフィックス技術は、携帯電話、携帯情報端末(Personal Digital Assistant:PDA)、カーナビゲーション子システム等に利用されている。
For example, in 3D graphics, optical phenomena when a 3D object is illuminated by a predetermined light source are expressed by a mathematical model, and the object surface is shaded or shaded based on this model. By pasting, a more realistic and three-dimensional two-dimensional high-definition image is generated.
Such computer graphics are increasingly used in CAD / CAM in development fields such as science, engineering and manufacturing, and in various other application fields.
In recent years, computer graphics technology has been used for mobile phones, personal digital assistants (PDAs), car navigation systems, and the like.

3次元グラフィックスは、一般には、フロントエンドとして位置づけられる「ジオメトリ・サブシステム」と、バックエンドとして位置づけられる「ラスタ・サブシステム」とにより構成される。   Three-dimensional graphics is generally composed of a “geometry subsystem” positioned as a front end and a “raster subsystem” positioned as a back end.

ジオメトリ・サブシステムとは、ディスプレイ・スクリーン上に表示する3次元オブジェクトの位置や姿勢などの幾何学的な演算処理を行う過程のことである。
ジオメトリ・サブシステムでは、一般にオブジェクトは多数のポリゴンの集合体として扱われ、ポリゴン単位で、「座標変換」、「クリッピング」、「光源計算」などの幾何学的な演算処理が行われる。
The geometry subsystem is a process of performing geometric calculation processing such as the position and orientation of a three-dimensional object displayed on a display screen.
In the geometry subsystem, an object is generally handled as a collection of a large number of polygons, and geometric calculation processing such as “coordinate transformation”, “clipping”, “light source calculation”, and the like is performed for each polygon.

一方、ラスタ・サブシステムは、オブジェクトを構成する各ピクセル(pixel)を塗りつぶす過程のことである。
ラスタライズ処理は、たとえばポリゴンの頂点毎に求められた画像パラメータを基にして、ポリゴン内部に含まれるすべてのピクセルの画像パラメータを補間することによって実現される。
ここで言う画像パラメータには、いわゆるRGB形式などで表される色(描画色)データ、奥行き方向の距離を表すz値などがある。
また、最近の高精細な3次元グラフィックス処理では、遠近感を醸し出すためのf(fog:霧)や、物体表面の素材感や模様を表現してリアリティを与えるテクスチャt(texture)なども、画像パラメータの1つとして含まれている。
On the other hand, the raster subsystem is a process of painting each pixel constituting an object.
The rasterization process is realized by interpolating the image parameters of all the pixels included in the polygon based on the image parameters obtained for each vertex of the polygon, for example.
The image parameters referred to here include color (drawing color) data expressed in a so-called RGB format and the like, a z value indicating a distance in the depth direction, and the like.
In addition, in recent high-definition 3D graphics processing, f (fog: fog) for creating a sense of perspective, texture t (texture) for expressing the texture and pattern of the object surface and providing reality, It is included as one of the image parameters.

ここで、ポリゴンの頂点情報からポリゴン内部のピクセルを発生する処理では、よくDDA(Digital Differential Analyzer)と呼ばれる線形補間手法を用いて実行される。
DDAプロセスでは、頂点情報からポリゴンの辺方向へのデータの傾きを求め、この傾きを用いて辺上のデータを算出した後、続いてラスタ走査方向(X方向)の傾きを算出し、この傾きから求めたパラメータの変化分を走査の開始点のパラメータ値に加えていくことで、内部のピクセルを発生していく。
Here, the process of generating the pixels inside the polygon from the vertex information of the polygon is often performed using a linear interpolation method called DDA (Digital Differential Analyzer).
In the DDA process, the inclination of the data in the side direction of the polygon is obtained from the vertex information, the data on the side is calculated using this inclination, and then the inclination in the raster scanning direction (X direction) is calculated. An internal pixel is generated by adding the change amount of the parameter obtained from the above to the parameter value of the scanning start point.

そして、3次元コンピュータグラフィックスでは、各ピクセルに対応する色を決定するときに、各ピクセルの色の計算をし、この計算した色の値を、当該ピクセルに対応するディスプレイバッファ(フレームバッファ)のアドレスに書き込むレンダリング(Rendering)処理を行う。
このようなレンダリング処理を行うために、ピクセルエンジン(描画エンジン)が設けられる。
In 3D computer graphics, when determining the color corresponding to each pixel, the color of each pixel is calculated, and the calculated color value is stored in a display buffer (frame buffer) corresponding to the pixel. Rendering processing to write to the address is performed.
In order to perform such rendering processing, a pixel engine (rendering engine) is provided.

3次元コンピュータグラフィックスにおける描画速度は、描画エンジンからフレームバッファへの書き込み速度に影響され、フレームバッファのアクセス速度が遅いと描画速度が低下することになる。
この課題を解消するために高価な高速メモリを大容量のフレームバッファに用いることはシステムの高価格化につながることから、安価な汎用メモリを用いることを前提として、キャッシュ機構をとる画像処理装置が提案されている(たとえば、特許文献1参照)。
The drawing speed in three-dimensional computer graphics is affected by the writing speed from the drawing engine to the frame buffer, and the drawing speed decreases when the access speed of the frame buffer is low.
In order to solve this problem, using an expensive high-speed memory for a large-capacity frame buffer leads to an increase in the price of the system. Therefore, on the premise that an inexpensive general-purpose memory is used, an image processing apparatus using a cache mechanism is proposed. It has been proposed (see, for example, Patent Document 1).

この特許文献1に記載された画像処理装置は、描画エンジンにより生成された画像データを一時的に先読み可能なFIFOメモリ等に一時蓄え、この先読み可能なFIFOメモリ等とフレームバッファとの間にキャッシュメモリを設け、先読み可能なFIFOメモリ等の内容をキャッシュメモリに先読みして、キャッシュメモリの読み書き制御を行う。
特開平9−212661号公報
The image processing apparatus described in Patent Document 1 temporarily stores image data generated by a drawing engine in a prefetchable FIFO memory or the like, and caches the prefetched FIFO memory or the like between the frame buffer and the frame buffer. A memory is provided, and the contents of the prefetchable FIFO memory and the like are prefetched into the cache memory, and read / write control of the cache memory is performed.
JP-A-9-212661

しかしながら、従来の3次元コンピュータグラフィックスにおいては、その機能を実現するために、専用のメモリシステムもしくはメモリシステムに依存(密着)したアーキテクチャ構成をとっていた。
汎用メモリ対応面でも、上記した特許文献1に記載されているように、汎用DRAMを前提としたキャッシュ機構がとられる状況であった。
However, in the conventional three-dimensional computer graphics, in order to realize the function, an exclusive memory system or an architecture configuration depending on (adhering to) the memory system has been adopted.
In terms of general-purpose memory compatibility, as described in Patent Document 1 described above, a cache mechanism based on a general-purpose DRAM is used.

一方、SOCのように、高集積化と多機能化に対応するため、IPに代表される高機能モジュールが3次元コンピュータグラフィックス(3DCG)機能にも要求される。このとき、従来手法の場合はメモリシステムが異なる場合、専用メモリを持ってIPとするか、もしくは異なるシステムメモリにあわせた再設計が必要となる。
専用メモリを付加させることは面積、電力の増大、メモリアクセス機構の複雑化を招く。再設計を行うことは、3次元コンピュータグラフィックス機能実現構造まで含めた設計負荷をもたらす。
このように、従来の3次元コンピュータグラフィックスに対応した画像処理アーキテクチャは、メモリアーキテクチャに依存して、メモリアーキテクチャから分離して構成することができず、IPに代表される高機能モジュール等のシステムに容易に適用することが困難であるという不利益があった。
On the other hand, high-function modules represented by IP are also required for three-dimensional computer graphics (3DCG) functions in order to cope with high integration and multi-function like SOC. At this time, in the case of the conventional method, when the memory system is different, it is necessary to use a dedicated memory as an IP or to redesign it to a different system memory.
Adding a dedicated memory causes an increase in area, power, and complexity of the memory access mechanism. Performing the redesign brings about a design load including a three-dimensional computer graphics function implementation structure.
As described above, the conventional image processing architecture corresponding to three-dimensional computer graphics cannot be configured separately from the memory architecture depending on the memory architecture, and is a system such as a high-function module represented by IP. There was the disadvantage that it was difficult to easily apply.

本発明は、かかる事情に鑑みてなされたものであり、その目的は、面積、電力の増大を抑止し、メモリアクセス機構の簡単化を図れ、設計負荷を軽減でき、メモリシステムに依存することなく、各種システムに容易に適応することが可能な画像処理装置およびその方法を提供することにある。   The present invention has been made in view of such circumstances, and its purpose is to suppress an increase in area and power, to simplify a memory access mechanism, to reduce a design load, and without depending on a memory system. Another object of the present invention is to provide an image processing apparatus and method that can be easily adapted to various systems.

上記目的を達成するため、本発明の第1の観点は、メモリに対するレンダリング処理を行う画像処理装置であって、描画すべきプリミティブに関する情報に基づいてピクセルデータを発生し、上記メモリに対するアクセスに関する情報として2次元座標を出力するピクセルエンジンと、上記ピクセルエンジンによるに2次元座標を受けて、ピクセルデータに対して当該2次元座標に相応する2次元構造をとり、上記メモリをアクセスするために2次元座標情報に相応したコマンドとデータに標準化したキャッシュコマンドを出力するキャッシュとを有する。   In order to achieve the above object, a first aspect of the present invention is an image processing apparatus that performs a rendering process on a memory, generates pixel data based on information on a primitive to be drawn, and information on access to the memory A pixel engine that outputs two-dimensional coordinates, and receives the two-dimensional coordinates from the pixel engine, takes a two-dimensional structure corresponding to the two-dimensional coordinates for the pixel data, and uses the two-dimensional to access the memory A command corresponding to the coordinate information and a cache for outputting a cache command standardized to data are provided.

好適には、上記キャッシュコマンドには、上記メモリの実アドレスに必要な汎用情報を含む。   Preferably, the cache command includes general information necessary for the real address of the memory.

好適には、上記キャッシュによるキャッシュコマンドを受けて上記メモリの実アドレスを生成するメモリインタフェースを、有する。   Preferably, it has a memory interface that receives a cache command from the cache and generates a real address of the memory.

好適には、上記キャッシュによるキャッシュコマンドを受けてメモリアーキテクチャに依存した上記メモリの実アドレスを生成するメモリインタフェースを、有する。   Preferably, it has a memory interface that receives a cache command from the cache and generates a real address of the memory depending on a memory architecture.

本発明の第2の観点は、メモリに対するレンダリング処理を行う画像処理装置であって、外部装置とのインタフェースを司る外部インタフェースと、上記メモリとのインタフェースを司るメモリインタフェースと、上記外部インタフェースを介して入力した描画すべきプリミティブに関する情報に基づいてピクセルデータを発生し、上記メモリに対するアクセスに関する情報として2次元座標を出力するピクセルエンジンと、上記ピクセルエンジンによるに2次元座標を受けて、ピクセルデータに対して当該2次元座標に相応する2次元構造をとり、上記メモリをアクセスするために2次元座標情報に相応したコマンドとデータに標準化したキャッシュコマンドを出力するキャッシュと、を有し、上記メモリインタフェースは、上記キャッシュによるキャッシュコマンドを受けて上記メモリの実アドレスを生成する。   According to a second aspect of the present invention, there is provided an image processing apparatus that performs a rendering process on a memory, an external interface that controls an interface with an external apparatus, a memory interface that controls an interface with the memory, and the external interface. Pixel data is generated based on the input information about the primitive to be drawn, and a pixel engine that outputs two-dimensional coordinates as information relating to access to the memory; receives the two-dimensional coordinates from the pixel engine; A memory having a two-dimensional structure corresponding to the two-dimensional coordinates and outputting a cache command standardized to data and a command corresponding to the two-dimensional coordinate information for accessing the memory. , Above cash In response to the Cash command to generate a real address of the memory.

本発明の第3の観点は、メモリに対するレンダリング処理を行う画像処理方法であって、描画すべきプリミティブに関する情報に基づいてピクセルデータを発生する第1のステップと、上記メモリに対するアクセスに関する情報として2次元座標を生成してキャッシュに与える第2のステップと、上記キャッシュにおいて、上記メモリをアクセスするために2次元座標情報に相応したコマンドとデータに標準化したキャッシュコマンドを出力する第3のステップとを有する。   According to a third aspect of the present invention, there is provided an image processing method for performing a rendering process on a memory, wherein a first step for generating pixel data based on information on a primitive to be drawn and information on access to the memory are 2 A second step of generating and providing a dimensional coordinate to the cache, and a third step of outputting a cache command standardized to data and a command corresponding to the two-dimensional coordinate information in order to access the memory in the cache. Have.

本発明によれば、ピクセルエンジンにおいて、たとえば各種データ(z,カラーなど)の描画すべきプリミティブに関する情報に基づいてピクセルデータが発生される。
ピクセルエンジンでは、メモリに対するアクセスに関する情報として2次元座標がキャッシュに対して出力される。
キャッシュでは、ピクセルエンジンによるに2次元座標を受けて、ピクセルデータに対して当該2次元座標に相応する2次元構造をとり、メモリをアクセスするために2次元座標情報に相応したコマンドとデータに標準化したキャッシュコマンドが出力される。
そして、メモリインタフェースにおいて、キャッシュによるキャッシュコマンドを受けてメモリアーキテクチャに依存したメモリの実アドレスが生成される。
According to the present invention, pixel data is generated in the pixel engine based on information on primitives to be drawn, for example, various data (z, color, etc.).
In the pixel engine, two-dimensional coordinates are output to the cache as information relating to access to the memory.
The cache receives two-dimensional coordinates from the pixel engine, takes a two-dimensional structure corresponding to the two-dimensional coordinates for the pixel data, and standardizes commands and data corresponding to the two-dimensional coordinate information to access the memory. Cache command is output.
The memory interface receives a cache command from the cache and generates a memory real address depending on the memory architecture.

本発明によれば、面積、電力の増大を抑止でき、メモリアクセス機構の簡単化を図れ、設計負荷を軽減できる利点がある。
その結果、従来はメモリアーキテクチャに依存して構成されていた画像処理、すなわち3次元コンピュータグラフィックスアーキテクチャをメモリから分離し、汎用SOCなどに使用するIPにした場合、メモリシステムに依存する機能ブロック仕様が標準化されているため、容易にシステムに順応した構成をとることが可能となる。
According to the present invention, there is an advantage that an increase in area and power can be suppressed, a memory access mechanism can be simplified, and a design load can be reduced.
As a result, when the image processing, which is conventionally configured depending on the memory architecture, that is, the three-dimensional computer graphics architecture is separated from the memory and used as an IP used for general-purpose SOCs, etc., the functional block specifications depending on the memory system Can be easily adapted to the system.

以下、本実施形態について添付図面に関連付けて説明する。
本実施形態においては、画像メモリアーキテクチャに依存して実アドレス生成を行う機能を、画像メモリアーキテクチャに非依存のコマンドの形式とデータで受け渡す形態で切りわけることにより、画像処理におけるメモリアクセスを画像処理メモリアーキテクチャに依存しないキャッシュに分離している。
これにより、従来はメモリアーキテクチャに依存して構成されていた画像処理、すなわち3次元コンピュータグラフィックスアーキテクチャをメモリから分離し、汎用SOCなどに使用するIPにした場合、メモリシステムに依存する機能ブロック仕様が標準化されているため、容易にシステムに順応した構成をとることが可能となっている。
Hereinafter, this embodiment will be described with reference to the accompanying drawings.
In the present embodiment, memory access in image processing is controlled by switching the function of performing real address generation depending on the image memory architecture in the form of command and data that is independent of the image memory architecture. Separated into a cache independent of processing memory architecture.
Thus, when image processing, which is conventionally configured depending on a memory architecture, that is, a three-dimensional computer graphics architecture is separated from a memory and used as an IP for general-purpose SOCs, etc., functional block specifications depending on the memory system Is standardized, it is possible to easily adopt a configuration adapted to the system.

図1は、本発明に係る画像処理装置の要部の一実施形態を示す構成図である。   FIG. 1 is a configuration diagram showing an embodiment of a main part of an image processing apparatus according to the present invention.

本画像処理装置10は、3次元コンピュータグラフィックスシステムに適用され、たとえば立体モデルを単位図形である三角形(ポリゴン)の組み合わせとして表現し、このポリゴンを描画することで表示画面の各画素の色を決定し、メモリに対するポリゴンレンダリング処理を行う。
また、3次元コンピュータグラフィックスシステムでは、平面上の位置を表現する(x,y)座標の他に、奥行きを表すz座標を用いて3次元物体を表し、この(x,y,z)の3つの座標で3次元空間の任意の一点を特定する。
The image processing apparatus 10 is applied to a three-dimensional computer graphics system. For example, a three-dimensional model is expressed as a combination of triangles (polygons) that are unit figures, and the colors of each pixel on the display screen are displayed by drawing the polygons. Determine and perform polygon rendering processing for the memory.
In the three-dimensional computer graphics system, in addition to the (x, y) coordinate representing the position on the plane, the z coordinate representing the depth is used to represent the three-dimensional object, and this (x, y, z) An arbitrary point in the three-dimensional space is specified by three coordinates.

本画像処理装置1は、図1に示すように、システム依存ブロック(System−depend block)2、およびコアブロック(Core block)3を主構成要素として有している。   As shown in FIG. 1, the image processing apparatus 1 includes a system-dependent block 2 and a core block 3 as main components.

システム依存ブロック2は、図1に示すように、外部インタフェースとしてのCPUインタフェース(BB)21およびメモリインタフェース(MEMIF)22により構成される。   As shown in FIG. 1, the system-dependent block 2 includes a CPU interface (BB) 21 and a memory interface (MEMIF) 22 as external interfaces.

CPUインタフェース21は、たとえばCPUバス4を介して図示しない上位装置としてのCPU(メインプロセッサ)に接続され、CPUとコアブロック3間、あるいはコアブロック3内の機能ブロック同士間のデータ授受等のインタフェース処理を行う。   The CPU interface 21 is connected to, for example, a CPU (main processor) as a host device (not shown) via the CPU bus 4, and is an interface such as data exchange between the CPU and the core block 3 or between functional blocks in the core block 3. Process.

メモリインタフェース22は、コアブロック3と図示しないメモリバスあるいはシステムバスを通して接続されるメモリ間のデータ授受等のインタフェース処理を行う。   The memory interface 22 performs interface processing such as data exchange between the core block 3 and a memory connected through a memory bus (not shown) or a system bus.

コアブロック3は、図2に示すように、ジオメトリエンジン(GE:Geometry Engine)31、およびラスタライゼーションエンジン(RE;Rasterization Engine)33により構成されている。   As illustrated in FIG. 2, the core block 3 includes a geometry engine (GE) 31 and a rasterization engine (RE) 33.

ジオメトリエンジン31は、たとえば図示しないCPUによりCPUバス4を転送され、CPUインタフェースを通して転送された、3次元座標、法線ベクトル、テクスチャ座標の各頂点データが入力されると、頂点データに対して、たとえば浮動少数点演算を行う。
代表的な演算としては、物体の変形やスクリーンへの投影などを行う座標変換の演算処理、ライティング(Lighting)の演算処理、クリッピング(Clipping)の演算処理がある。
ジオメトリエンジン31は、演算処理結果を、たとえばポリゴンレンダリングデータとして、CPUインタフェース21を通してラスタライゼーションエンジン32に転送する。
When the geometry engine 31 is transferred to the CPU bus 4 by a CPU (not shown), for example, and each vertex data of three-dimensional coordinates, normal vectors, and texture coordinates transferred through the CPU interface is input, For example, floating point arithmetic is performed.
Typical calculations include coordinate conversion calculation processing that performs deformation of an object, projection onto a screen, lighting calculation processing, and clipping calculation processing.
The geometry engine 31 transfers the calculation processing result to the rasterization engine 32 through the CPU interface 21 as, for example, polygon rendering data.

このポリゴンレンダリングデータは、ポリゴンの各3頂点の(x,y,z,R,G,B,α,s,t,q)のデータを含んでいる。
ここで、(x,y,z)データは、ポリゴンの頂点の3次元座標を示し、(R,G,B)データは、それぞれ当該3次元座標における赤、緑、青の輝度値を示している。
また、αはブレンド値(係数)を示している。
(s,t,q)データのうち、(s,t)は、対応するテクスチャの同次座標を示しており、qは同次項を示している。ここで、「s/q」および「t/q」に、それぞれテクスチャサイズUSIZEおよびVSIZEを乗じて、実際のテクスチャ座標データ(u,v)が得られる。
ラスタライゼーションエンジン32のメモリに記憶されたテクスチャデータへのアクセスは、テクスチャ座標データ(u,v)を用いて行われる。
すなわち、ポリゴンレンダリングデータは、三角形の各頂点の物理座標値と、それぞれの頂点の色とテクスチャデータである。
This polygon rendering data includes (x, y, z, R, G, B, α, s, t, q) data of each of the three vertices of the polygon.
Here, (x, y, z) data indicates the three-dimensional coordinates of the vertices of the polygon, and (R, G, B) data indicates the luminance values of red, green, and blue at the three-dimensional coordinates, respectively. Yes.
Α represents a blend value (coefficient).
Of the (s, t, q) data, (s, t) indicates the homogeneous coordinates of the corresponding texture, and q indicates the homogeneous term. Here, “s / q” and “t / q” are multiplied by the texture sizes USIZE and VSIZE, respectively, to obtain actual texture coordinate data (u, v).
Access to the texture data stored in the memory of the rasterization engine 32 is performed using the texture coordinate data (u, v).
That is, the polygon rendering data is a physical coordinate value of each vertex of the triangle, a color of each vertex, and texture data.

ラスタライゼーションエンジン32は、ジオメトリエンジン31によるポリゴンレンダリングデータを受けて、ラスタライゼーションに必要な各種データ(奥行き(Z),カラー(C)、テクスチャ座標など)の傾き等のDDAパラメータを算出し、算出した各種データをラスタライズし、テクスチャ座標のパースペクティブコレクション(Perspective Correction)を行い、テクスチャフィルタリングを行う。
テクスチャ座標のパースペクティブコレクション処理には、LOD(Level of Detail)計算によるミップマップ(MIPMAP)レベルの算出や、テクスチャアクセスのための(u,v)アドレス計算も含まれる。テクスチャフィルタリング処理においては、図示しないメモリから読み出されたデータと、(u,v)アドレスを算出した時に得る小数部を4近傍補間などのフィルタリング処理を行う。
ラスタライゼーションエンジン32は、次に、ピクセルレベルの処理を行う。この処理においては、フィルタリング後のテクスチャデータと、ラスタライズ後の各種データ(Z,C)を用いてピクセル単位の演算を行う。ここで行う処理には、ピクセルレベルでのライティングなどのピクセルオペレーションに加えて、アルファテスト、Z(奥行き)テスト、アルファブレンディング等の各種処理を行う。
そして、ラスタライゼーションエンジン32は、ピクセルレベルの処理における各種テストをパスしたピクセルデータを、メモリインタフェース22を通して外部のメモリに書き込む。
The rasterization engine 32 receives polygon rendering data from the geometry engine 31 and calculates DDA parameters such as inclinations of various data (depth (Z), color (C), texture coordinates, etc.) necessary for rasterization. The various data are rasterized, a perspective collection of texture coordinates (Perspective Correction) is performed, and texture filtering is performed.
The texture coordinate perspective collection processing includes calculation of a mipmap (MIPMAP) level by LOD (Level of Detail) calculation and calculation of (u, v) address for texture access. In the texture filtering process, a filtering process such as 4-neighbor interpolation is performed on the data read from the memory (not shown) and the decimal part obtained when the (u, v) address is calculated.
The rasterization engine 32 then performs pixel level processing. In this processing, calculation in units of pixels is performed using the texture data after filtering and the various data (Z, C) after rasterization. In this processing, in addition to pixel operations such as lighting at the pixel level, various processes such as an alpha test, a Z (depth) test, and alpha blending are performed.
The rasterization engine 32 writes pixel data that has passed various tests in pixel level processing to an external memory through the memory interface 22.

本実施形態におけるラスタライゼーションエンジン32は、メモリインタフェース22を通してメモリへのアクセスを行うが、上述した、テクスチャおよびピクセルレベルの処置を行うテクスチャ・ピクセルエンジンとメモリインタフェースとの間にキャッシュ機構を設けて、画像メモリアーキテクチャに依存して実アドレス生成を行う機能を、画像メモリアーキテクチャに非依存のコマンドの形式とデータで受け渡す形態で切りわけることにより、画像処理におけるメモリアクセスを画像処理メモリアーキテクチャに依存しないキャッシュに分離している。   The rasterization engine 32 in this embodiment accesses the memory through the memory interface 22, but a cache mechanism is provided between the texture pixel engine and the memory interface that perform the texture and pixel level processing described above, and The memory access in image processing does not depend on the image processing memory architecture by switching the function of generating real addresses depending on the image memory architecture in the form of command and data that is independent of the image memory architecture. Separated into cache.

具体的には、本実施形態におけるラスタライゼーションエンジン32は、
1)キャッシュ機構までのアドレスにおいて仮想2次元画面座標を扱う、
2)キャッシュからのメモリアクセスには上記内容によるコマンドとデータで標準化する、
3)実アドレスに必要な汎用情報(メモリ先頭アドレス等)もコマンドに収めることで標準化する。
4)実アドレス空間は専用の機構に切り分け、必要最小の実現規模で実現する、
という特徴的な構成を有する。
Specifically, the rasterization engine 32 in the present embodiment is
1) Handle virtual 2D screen coordinates at addresses up to the cache mechanism.
2) For memory access from the cache, standardize with commands and data according to the above contents.
3) Standardize general-purpose information (memory start address, etc.) required for real addresses by including them in commands.
4) The real address space is divided into dedicated mechanisms and is realized with the minimum necessary scale.
It has a characteristic configuration.

以下、この特徴的なキャッシュ機構を含むラスタライゼーションエンジン32のより具体的な構成について説明する。   Hereinafter, a more specific configuration of the rasterization engine 32 including this characteristic cache mechanism will be described.

図2は、本実施形態に係るラスタライゼーションエンジン32の具体的な構成例を示すブロック図である。
このラスタライゼーションエンジン32は、図2に示すように、線形補間演算のための初期設定演算ブロックとしてのDDA(Digital Differential Analizer) セットアップ回路321、線形補間処理ブロックとしてのトライアングルDDA回路322、テクスチャマップエンジン(TME)・ピクセルオペレーションエンジン(POE)(以下、TME_POEという)323、およびキャッシュシステム324を有する。
FIG. 2 is a block diagram showing a specific configuration example of the rasterization engine 32 according to the present embodiment.
As shown in FIG. 2, the rasterization engine 32 includes a DDA (Digital Differential Analizer) setup circuit 321 as an initial setting calculation block for linear interpolation calculation, a triangle DDA circuit 322 as a linear interpolation processing block, and a texture map engine. (TME) pixel operation engine (POE) (hereinafter referred to as TME_POE) 323 and cache system 324.

DDAセットアップ回路321は、後段のトライアングルDDA回路322において物理座標系上の三角形の各頂点の値を線形補間して、三角形の内部の各画素の色と深さ情報を求めるに先立ち、ポリゴンレンダリングデータS11が示す(z,R,G,B,α,s,t,q)データについて、三角形の辺と水平方向の差分などを求めるセットアップ演算を行う。
このセットアップ演算は、具体的には、開始点の値と終点の値と、開始点と終点との距離を用いて、単位長さ移動した場合における、求めようとしている値の変分を算出する。
DDAセットアップ回路321は、算出した変分データを含むプリミティブに関する情報としてのセットアップデータS321をトライアングルDDA回路322に出力する。
Prior to obtaining the color and depth information of each pixel inside the triangle by linearly interpolating the values of the vertices of the triangle on the physical coordinate system in the subsequent triangle DDA circuit 322, the DDA setup circuit 321 generates polygon rendering data. For the (z, R, G, B, α, s, t, q) data indicated by S11, a setup calculation is performed to find the difference between the sides of the triangle and the horizontal direction.
Specifically, this set-up calculation uses the start point value, end point value, and distance between the start point and end point to calculate the variation of the value to be obtained when the unit length is moved. .
The DDA setup circuit 321 outputs setup data S321 as information on the primitive including the calculated variation data to the triangle DDA circuit 322.

DDAセットアップ回路321の機能について図3に関連付けてさらに説明する。
上述したように、DDAセットアップ回路321の主な処理は、前段のジオメトリ処理を経て物理座標にまで落ちてきた各頂点における各種情報(色、テクスチャ座標)の与えられた三頂点P0(x0,y0)、P1(x1,y1)、P2(x2,y2)により構成される三角形内部で変分を求めて、後段の線形補間処理の基礎デ−タを算出することである。
三角形の描画はひとつひとつの画素の描画に集約されるが、そのために描画開始点における最初の値を求める必要がある。
最初の描画点における各種情報は、頂点からその最初の描画点までの水平距離に水平方向の変分を掛けた値と、垂直距離に垂直方向の変分を掛けた値を足し合わせたものとなる。いったん目的の三角形の内部の一つの整数格子上の値が求まれば、対象の三角形内部のその他の格子点における値は変分の整数倍で求めることが可能となる。
The function of the DDA setup circuit 321 will be further described with reference to FIG.
As described above, the main processing of the DDA setup circuit 321 is the three vertices P0 (x0, y0) given various information (color, texture coordinates) at each vertex that has fallen to the physical coordinates after the previous geometry processing. ), P1 (x1, y1), and P2 (x2, y2) to obtain the variation within the triangle, and calculate the basic data of the subsequent linear interpolation processing.
Triangular drawing is summarized into drawing of every pixel, and for this purpose, it is necessary to obtain the first value at the drawing start point.
Various information at the first drawing point is the sum of the value obtained by multiplying the horizontal distance from the vertex to the first drawing point by the horizontal variation and the value obtained by multiplying the vertical distance by the vertical variation. Become. Once the values on one integer grid inside the target triangle are found, the values at other grid points inside the target triangle can be found by integer multiples of the variation.

三角形の各頂点データは、たとえばx,y座標が16ビット、z座標が24ビット、RGBカラー値が各12ビット(=8+4)、s,t,qテクスチャ座標は各32ビット浮動少数値(IEEEフォーマット)等で構成される。   Each vertex data of the triangle is, for example, 16 bits for x and y coordinates, 24 bits for z coordinates, 12 bits for RGB color values (= 8 + 4), and 32 bits for s, t, q texture coordinates (IEEE). Format).

なお、このDDAセットアップ回路321は、従来のようにDSP構造ではなく、ASIC手法により実装している。
具体的には、図4に示すように、多段に配置したレジスタ3211−1〜3211−4間に複数の演算ユニットを並列に配置した演算ユニット群3212−1〜3212−3を挿入したフルデータパスロジック、換言すれば、同期パイプライン方式の時間並列構造として構成されている。
Note that the DDA setup circuit 321 is mounted by an ASIC technique instead of a DSP structure as in the prior art.
Specifically, as shown in FIG. 4, full data in which arithmetic unit groups 3212-1 to 2122-3 in which a plurality of arithmetic units are arranged in parallel are inserted between registers 3211-1 to 2112-4 arranged in multiple stages. It is configured as a path logic, in other words, a time parallel structure of a synchronous pipeline system.

トライアングルDDA回路322は、DDAセットアップ回路321から入力した変分データを含むプリミティブに関する情報としてのセットアップデータS321を基に、三角形内部の各画素における線形補間された(z,R,G,B,α,s,t,q)データを算出する。
トライアングルDDA回路322は、各画素の(x,y)データと、当該(x,y)座標における(z,R,G,B,α,s,t,q)データとを、DDAデータ(補間データ)S322としてTME_POE323に出力する。
The triangle DDA circuit 322 is linearly interpolated (z, R, G, B, α) in each pixel inside the triangle based on the setup data S321 as information regarding primitives including variation data input from the DDA setup circuit 321. , S, t, q) data is calculated.
The triangle DDA circuit 322 converts (x, y) data of each pixel and (z, R, G, B, α, s, t, q) data at the (x, y) coordinates into DDA data (interpolation). Data) Output to TME_POE 323 as S322.

すなわち、トライアングルDDA回路322は、ポリゴンの頂点毎に求められた画像パラメータに基づいてポリゴン内部に含まれるすべてのピクセルの画像パラメータを補間するラスタライズ処理(ラスタライゼーション:Rasterization)を行う。
具体的には、トライアングルDDA回路322は、各種データ(z,テクスチャ座標、カラーなど)をラスタライズする。
That is, the triangle DDA circuit 322 performs a rasterization process (rasterization) that interpolates the image parameters of all the pixels included in the polygon based on the image parameters obtained for each vertex of the polygon.
Specifically, the triangle DDA circuit 322 rasterizes various data (z, texture coordinates, color, etc.).

TME_POE323は、たとえばテクスチャブレンディング処理、アルファテスト、奥行き(デプス)テスト、アルファブレンディング処理、およびピクセルオペレーションを行う。ピクセルオペレーションにおいては、各種テストをパスしたピクセルデータを、キャッシュシステム324、メモリインタフェース22を通して外部のメモリに書き込む。   The TME_POE 323 performs, for example, a texture blending process, an alpha test, a depth (depth) test, an alpha blending process, and a pixel operation. In pixel operation, pixel data that passes various tests is written to an external memory through the cache system 324 and the memory interface 22.

以上のように、DDAセットアップ回路321、トライアングルDDA回路322、TME_POE323における所定処理を経て、最終的なメモリアクセスがピクセル(Pixel;Picture Cell Element) という描画画素単位になる。   As described above, after predetermined processing in the DDA setup circuit 321, the triangle DDA circuit 322, and the TME_POE 323, the final memory access becomes a drawing pixel unit called a pixel (Pixel; Picture Cell Element).

キャッシュシステム324は、テクスチャキャッシュ(Tキャッシュ)3241、カラーキャッシュ(Cキャッシュ)3242、およびデプスキャッシュ(Zキャッシュ)3242を有する。   The cache system 324 includes a texture cache (T cache) 3241, a color cache (C cache) 3242, and a depth cache (Z cache) 3242.

TME_POE323におけるブレンディングのためのテクスチャデータは、Tキャッシュ3241に配されたテクスチャ座標を通し、さらにメモリインタフェース22を介してアクセスされる。
TME_POE323におけるカラー/デプスオペレーションのためのカラーデータは、Cキャッシュ3242およひZキャッシュ3243に配された2次元のピクセル座標を通し、さらに、メモリインタフェース22を介してアクセスされる。
このように、本実施形態に係るTME_POE323においては、キャッシュシステムに基づく座標およびアドレスブロック(MEMIF)に依存する分離のメモリシステム、並びに、キャッシュシステム324とメモリインタフェース22間のインタフェースに依存するコマンドベースシステムを採用している。
Texture data for blending in the TME_POE 323 is accessed via the memory interface 22 through the texture coordinates arranged in the T cache 3241.
Color data for color / depth operation in the TME_POE 323 is accessed through the memory interface 22 through two-dimensional pixel coordinates arranged in the C cache 3242 and the Z cache 3243.
As described above, in TME_POE 323 according to the present embodiment, a separate memory system that depends on the coordinates and address blocks (MEMIF) based on the cache system, and a command-based system that depends on the interface between the cache system 324 and the memory interface 22 Is adopted.

なお、本実施形態において、TME_POE323におけるピクセルオペレーションにおける座標空間は、使用されるメモリシステムに依存しない。
キャッシュシステム324に基づく座標は、いかなるメモリシステムに対して構成することができる。
また、アドレスブロック(MEMIF)に依存するシステムは、キャッシュシステム324から分離可能である。
In the present embodiment, the coordinate space in the pixel operation in TME_POE 323 does not depend on the memory system used.
Coordinates based on the cache system 324 can be configured for any memory system.
A system that relies on an address block (MEMIF) can be separated from the cache system 324.

図5は、キャッシュシステム324のTME_POE334(RE)側とメモリアクセスブロックであるメモリインタフェース(MEMIF)22が分離した、コマンドベース・キャッシュデータアクセス構造を示す図である。   FIG. 5 is a diagram showing a command-based cache data access structure in which the TME_POE 334 (RE) side of the cache system 324 and the memory interface (MEMIF) 22 as a memory access block are separated.

図5に示すキャッシュコマンド(C・CMD)は、図6に示すように、たとえば1ビットのレジスタセットビット、複数ビットのキャッシュに配された座標、タグ(TAG)アドレス情報、ライン情報、1ビットのフィル(fill)/ライト(write)バックディレクション、複数ビットのライトバック用データマスクビットを含む。   The cache command (C / CMD) shown in FIG. 5 includes, for example, a 1-bit register set bit, coordinates arranged in a multi-bit cache, tag (TAG) address information, line information, 1 bit, as shown in FIG. Fill / write back direction, and a plurality of write back data mask bits.

この構造を用いることにより、ページ割り当てやバスプロトコルのようなアドレスフィーチャ依存のシステムは、メモリインタフェース(MEMIF)22にのみ搭載すればよい。
したがって、設計が容易で、低コストのシステムを構築できる。
By using this structure, an address feature dependent system such as page allocation or bus protocol need only be installed in the memory interface (MEMIF) 22.
Therefore, it is possible to construct a low-cost system that is easy to design.

以上のように、本実施形態にラスタライゼーションエンジン32におけるメモリアクセスは、カラー(C)をもつピクセルと、3次元奥行きをもつZと、テクスチャをもつTに分かれ、先ず実アドレスとは切り離された2次元座標系に対応したキャッシュ機構に対して行われる。   As described above, the memory access in the rasterization engine 32 in this embodiment is divided into pixels having color (C), Z having a three-dimensional depth, and T having a texture, and is first separated from a real address. This is performed for a cache mechanism corresponding to a two-dimensional coordinate system.

図7は、本実施形態におけるCキャッシュおよびZキャッシュの具体的なアクセス制御系を示す図である。
このアクセス制御系100は、POEコントローラ(POECTL)101、キャッシュラインタグ・フラグ部102、キャッシュライン103−1〜103−n(nはたとえば8,16,32・・・)、コントロールレジスタ(CTLREG)105、およびDMA104を有する。
なお、DMA104は、図1、図2のメモリインタフェース22に相当するものであり、システムに依存する部分である。
FIG. 7 is a diagram showing a specific access control system of the C cache and the Z cache in the present embodiment.
The access control system 100 includes a POE controller (POECTL) 101, a cache line tag / flag unit 102, cache lines 103-1 to 103-n (n is 8, 16, 32...), A control register (CTLREG). 105 and DMA 104.
The DMA 104 corresponds to the memory interface 22 in FIGS. 1 and 2 and is a system-dependent part.

このアクセス制御系100において、アクセス単位は1ピクセルであり、x,yの2次元座標で示す。1キャッシュライン103(−1〜−n)は128ビット/256ビットであり、ピクセルデータに対して2次元座標に相応する2次元構造をとる。
POEコントローラ(POECTL)101は、TME_POE33からのピクセルリード/ライト等に対応した制御を行う。
コントロールレジスタ(CTLREG)105は、キャッシュのピクセルフォーマットを確定し、キャッシュのアクセス属性(R/W,W)を確定する。
上述したように、実アドレス空間のアドレスはDMA105が行い、これらの設定はDMAコマンドで伝達される。
また、キャッシュラインタグ・フラグ部102におけるタグ/フラグは、キャッシュラインとメモリを2次元で結びつけ、また、キャッシュラインのステータスを示す。
たとえば、DMA105からは128ビットアクセス、POE33側からは最大32ビットアクセスが実現される。
In this access control system 100, the access unit is one pixel, which is indicated by two-dimensional coordinates of x and y. One cache line 103 (-1 to -n) is 128 bits / 256 bits, and takes a two-dimensional structure corresponding to two-dimensional coordinates for pixel data.
A POE controller (POECTL) 101 performs control corresponding to pixel read / write from the TME_POE 33.
The control register (CTLREG) 105 determines the cache pixel format and the cache access attributes (R / W, W).
As described above, the address of the real address space is set by the DMA 105, and these settings are transmitted by the DMA command.
The tag / flag in the cache line tag / flag unit 102 links the cache line and the memory two-dimensionally and indicates the status of the cache line.
For example, 128-bit access is realized from the DMA 105 and a maximum of 32-bit access is realized from the POE 33 side.

つぎに、C(カラー)/Z(奥行き/デプス)キャッシュの2次元(2D)マップ処理に一例について説明する。
この場合、2次元アドレスに対応するC/Zキャッシュのライン番号の算出、POE33のリード/ライト(R/W)参照時の参照位置を決定する。
ラインマップは、コントロールレジスタ104に示すレジスタ設定に応じて、ピクセルフォーマットにより異なる以下の3種類に分類される。
Next, an example will be described for two-dimensional (2D) map processing of a C (color) / Z (depth / depth) cache.
In this case, the C / Z cache line number corresponding to the two-dimensional address is calculated, and the reference position when the POE 33 is read / written (R / W) is determined.
The line map is classified into the following three types that differ depending on the pixel format in accordance with the register setting shown in the control register 104.

すなわち、
1)16ライン・・Cキャッシュにおける16ビットピクセルフォーマット、Zキャッシュにおける16ビットピクセルフォーマット、
2)8ライン(4×2)・・Cキャッシュにおける32ビットピクセルフォーマット、Zキャッシュにおける32ピクセルフォーマット、
3)8ライン(4×4)・・Cキャッシュにおける8ビットピクセルフォーマット、
の3種類である。
That is,
1) 16-bit pixel format in 16-line .C cache, 16-bit pixel format in Z-cache,
2) 8 lines (4 × 2) .. 32 bit pixel format in C cache, 32 pixel format in Z cache,
3) 8 lines (4 × 4) .. 8 bit pixel format in C cache,
There are three types.

ここで、C/Zキャッシュの16ラインの場合を例に具体的な処理について説明する。なお、8ライン(4×2)、8ライン(4×4)は16ラインの場合と同様に行われることから、本実施形態ではその詳細な説明は省略する。   Here, specific processing will be described by taking the case of 16 lines of C / Z cache as an example. Since 8 lines (4 × 2) and 8 lines (4 × 4) are performed in the same manner as in the case of 16 lines, detailed description thereof is omitted in this embodiment.

C/Zキャッシュの16ラインの場合、アクセス座標(アドレス)は、キャッシュサイズとなるように、4×2でブロックされる。このブロックアドレス(xb ,yb )と参照アドレス(xo ,yo )の関係は以下のようになる。
xb =xo >>2
yb =yo >>1
In the case of 16 lines in the C / Z cache, the access coordinates (address) are blocked at 4 × 2 so as to be the cache size. The relationship between the block address (xb, yb) and the reference address (xo, yo) is as follows.
xb = xo >> 2
yb = yo >> 1

このブロックアドレス(xb ,yb )について、タグNonumの算出は以下のようになる。
num=(xb &0X3)|((yb &0X3)<<2)
For this block address (xb, yb), the tag Nonum is calculated as follows.
num = (xb & 0X3) | ((yb & 0X3) << 2)

2次元座標値をアドレスとしている関係(DMA105によるメモリ参照物理アドレスのページアドレスはDMA105側で確定する)から、タグに保存されるアドレスはブロックアドレス(xb ,yb )の上位となる。
xtag =xb >>2
ytag =yb >>2
Since the two-dimensional coordinate value is an address (the page address of the memory reference physical address by the DMA 105 is determined on the DMA 105 side), the address stored in the tag is higher than the block address (xb, yb).
xtag = xb >> 2
ytag = yb >> 2

キャッシュビット参照は、タグアドレッシング後にこの値を比較して行われることになる。
この場合の参照座標入力との関係を図8に示す。
The cache bit reference is performed by comparing this value after tag addressing.
The relationship with reference coordinate input in this case is shown in FIG.

次に、C/Zキャッシュの16ラインの場合のピクセルデータの割り当てについて説明する。
1キャッシュライン128ビットデータについて、DMA105側とPOE33側の2次元8ピクセルの並びに対する割り付けについて説明すると、DMA側の128ビットのラインデータに対するピクセル割り付けは、図9に示す形となる。
なお、32ビットのピクセル出た割り付けはLSB側の16ビットとなる。
Next, pixel data allocation in the case of 16 lines in the C / Z cache will be described.
The assignment of one cache line 128-bit data to the two-dimensional 8-pixel arrangement on the DMA 105 side and the POE 33 side will be described. The pixel assignment for the 128-bit line data on the DMA side has the form shown in FIG.
The allocation of 32 bit pixels is 16 bits on the LSB side.

次に、C/Zキャッシュの16ラインの場合のスタンプアクセス(stamp access)について説明する。
POE33からのリード/ライト(R/W)参照は、16ビットの1スタンプ分1ピクセルで行われる。
参照は、その性質上、リード/ライト(R/W)のペアになるが。、処理の結果、書き込みが行われない場合は、無効(invalid)としてライト(write)が発行されなければならない。
スタンプ参照座標(xs0,ys0)(xs011ビット、ys011ビット)についてのスタンプ参照ブロックアドレス(xsb,ysb)は、次のように与えられる。
xsb=xso>>2
ysb=yso>>1
Next, stamp access (stamp access) in the case of 16 lines in the C / Z cache will be described.
The read / write (R / W) reference from the POE 33 is performed by one pixel for one 16-bit stamp.
The reference is a read / write (R / W) pair because of its nature. If writing is not performed as a result of the processing, write (write) must be issued as invalid.
The stamp reference block address (xsb, ysb) for the stamp reference coordinates (xs0, ys0) (xs011 bits, ys011 bits) is given as follows.
xsb = xso >> 2
ysb = yso >> 1

128ビット/line内でのスタンプ参照の関係は、スタンプ参照座標(xs0,ys0)のLSB側ビットを使い、図10に示すようになる。   The relationship of stamp reference within 128 bits / line is as shown in FIG. 10 using LSB side bits of stamp reference coordinates (xs0, ys0).

次に、本実施形態に係るメモリインタフェース(MEMIF)22について述べる。
上述したように、C/Zキャッシュののアクセスは汎用コマンドとして実システムとのアクセスを実現するメモリインタフェース(MEMIF)22とインタフェースされる(転送の整合が行われる)。Tキャッシュのアクセスは、同様な汎用コマンドとして実システムとのアクセスを実現すメモリインタフェース(MEMIF)22とインターフェースされる。
このようなメモリインタフェース(MEMIF)22は、SOCにおけるメモリアクセスのインタフェース(IF)仕様に合わせ、さらに2次元キャッシュ機構のメモリアクセス(キャッシュミス時)の特性を考慮した実アドレス構成を取り、3次元コンピュータグラフィックス(3DCG)のメモリシステム非依存のC/Z/Tのインターフェースを実現する。
Next, the memory interface (MEMIF) 22 according to the present embodiment will be described.
As described above, access to the C / Z cache is interfaced with the memory interface (MEMIF) 22 that realizes access to the real system as a general-purpose command (transfer matching is performed). The T-cache access is interfaced with a memory interface (MEMIF) 22 that realizes access to the real system as a similar general-purpose command.
Such a memory interface (MEMIF) 22 adopts a real address configuration in consideration of the characteristics of memory access (at the time of a cache miss) of the two-dimensional cache mechanism in accordance with the memory access interface (IF) specification in the SOC. A C / Z / T interface independent of a memory system of computer graphics (3DCG) is realized.

メモリインタフェース(MEMIF)22の機能仕様は、3DCG機能とは分離された仕様となり、C/Zの場合、たとえば対象SOCのバス仕様、SDRAM仕様に合わせたアドレスになるように汎用コマンドを処理する機能仕様が採用される。
メモリインタフェース(MEMIF)22の実メモリアドレスを実現するため汎用コマンドによる先頭アドレスとアドレス計算係数の設定が行われる。Tキャッシュについても同様に実現される。
本実施形態んおいて注目すべきは、最も規模が大きく複雑な3DCGは完全に分離され、対象システムの要求に合わせた機能ブロックを、3DCG機能ブロックから指定された仕様によるインターフェースにあわせ込むだけで実現している点である。したがって、他機能要求(他SOCなど)に対する対応は上記MEMIFに該当する設計だけで良い。
The function specification of the memory interface (MEMIF) 22 is a specification separated from the 3DCG function, and in the case of C / Z, for example, a function for processing general-purpose commands so as to have an address that matches the bus specification of the target SOC and the SDRAM specification. Specifications are adopted.
In order to realize a real memory address of the memory interface (MEMIF) 22, a head address and an address calculation coefficient are set by a general-purpose command. The same applies to the T-cache.
What should be noted in this embodiment is that the largest and most complicated 3DCG is completely separated, and the function block that matches the requirements of the target system is simply adjusted to the interface specified by the 3DCG function block. This is a realization. Therefore, only a design corresponding to the MEMIF needs to respond to other function requests (other SOC, etc.).

次に、上記構成による動作を説明する。   Next, the operation of the above configuration will be described.

まず、ジオメトリエンジン31において、たとえば図示しないCPUによりCPUバス4を転送され、CPUインタフェースを通して転送された、3次元座標、法線ベクトル、テクスチャぜひょうの各頂点データが入力されると、頂点データに対して、たとえば浮動少数点演算が行われる。たとえば、必要に応じて、グラフィックス描画等のデータは、メインプロセッサ11等において、座標変換、クリップ処理、ライティング処理等のジオメトリ処理が行われる。
そして、ジオメトリエンジン31の演算処理結果は、たとえばポリゴンレンダリングデータとして、CPUインタフェース21を通してラスタライゼーションエンジン32に転送される。
First, in the geometry engine 31, for example, when the CPU bus 4 is transferred by a CPU (not shown) and the vertex data of the three-dimensional coordinates, the normal vector, and the texture that are transferred through the CPU interface are input, On the other hand, for example, a floating-point operation is performed. For example, as necessary, data such as graphics drawing is subjected to geometry processing such as coordinate conversion, clip processing, and lighting processing in the main processor 11 or the like.
The calculation processing result of the geometry engine 31 is transferred to the rasterization engine 32 through the CPU interface 21 as polygon rendering data, for example.

ラスタライゼーションエンジン32においては、まず、DDAセットアップ回路321において、ポリゴンレンダリングデータに基づいて、三角形の辺と水平方向の差分などを示す変分データが生成される。
具体的には、開始点の値と終点の値、並びに、その間の距離を用いて、単位長さ移動した場合における、求めようとしている値の変化分である変分が算出され、変分データを含むセットアップデータS321としてトライアングルDDA回路322に出力される。
In the rasterization engine 32, first, the DDA setup circuit 321 generates variation data indicating the difference between the sides of the triangle and the horizontal direction based on the polygon rendering data.
Specifically, using the starting point value and the ending point value, and the distance between them, a variation that is a change in the value to be obtained when the unit length is moved is calculated, and the variation data Is output to the triangle DDA circuit 322 as setup data S321.

トライアングルDDA回路322においては、変分データを含むセットアップデータS321を用いて、、三角形内部の各画素における線形補間された(z,R,G,B,α,s,t,q)データが算出される。
そして、この算出された(z,R,G,B,α,s,t,q)データと、三角形の各頂点の(x,y)データとが、DDAデータS322として、トライアングルDDA回路322からTME_POE323に出力される。
すなわち、トライアングルDDA回路322においては、ポリゴンの頂点毎に求められた画像パラメータに基づいてポリゴン内部に含まれるすべてのピクセルの画像パラメータ(z,テクスチャ座標、カラーなど)を補間するラスタライズ処理が行われる。
In the triangle DDA circuit 322, linearly interpolated (z, R, G, B, α, s, t, q) data for each pixel inside the triangle is calculated using the setup data S321 including variation data. Is done.
The calculated (z, R, G, B, α, s, t, q) data and (x, y) data of each vertex of the triangle are used as DDA data S322 from the triangle DDA circuit 322. It is output to TME_POE 323.
That is, in the triangle DDA circuit 322, rasterization processing is performed for interpolating image parameters (z, texture coordinates, color, etc.) of all pixels included in the polygon based on the image parameters obtained for each vertex of the polygon. .

TME_POE323においては、たとえばテクスチャブレンディング処理、アルファテスト、奥行き(デプス)テスト、アルファブレンディング処理、およびピクセルオペレーションが行われる。そして、ピクセルオペレーションにおいては、各種テストをパスしたピクセルデータが、キャッシュシステム324、メモリインタフェース22を通して外部のメモリに書き込まれる。
TME_POE323におけるブレンディングのためのテクスチャデータは、Tキャッシュ3241に配されたテクスチャ座標を通し、さらにメモリインタフェース22を介してアクセスされる。
TME_POE323におけるカラー/デプスオペレーションのためのカラーデータは、Cキャッシュ3242およひZキャッシュ3243に配された2次元のピクセル座標を通し、さらに、メモリインタフェース22を介してアクセスされる。
In TME_POE 323, for example, a texture blending process, an alpha test, a depth (depth) test, an alpha blending process, and a pixel operation are performed. In the pixel operation, pixel data that passes various tests is written to an external memory through the cache system 324 and the memory interface 22.
Texture data for blending in the TME_POE 323 is accessed via the memory interface 22 through the texture coordinates arranged in the T cache 3241.
Color data for color / depth operation in the TME_POE 323 is accessed through the memory interface 22 through two-dimensional pixel coordinates arranged in the C cache 3242 and the Z cache 3243.

以上説明したように、本実施形態によれば、ラスタライゼーションエンジン32において、メモリインタフェース22を通してメモリへのアクセスを行うが、テクスチャおよびピクセルレベルの処置を行うテクスチャ・ピクセルエンジンとメモリインタフェースとの間にキャッシュシステム324を設けて、画像メモリアーキテクチャに依存して実アドレス生成を行う機能を、画像メモリアーキテクチャに非依存のコマンドの形式とデータで受け渡す形態で切りわけることにより、画像処理におけるメモリアクセスを画像処理メモリアーキテクチャに依存しないキャッシュに分離していることから、以下の効果を得ることができる。   As described above, according to the present embodiment, the rasterization engine 32 accesses the memory through the memory interface 22, but between the texture and pixel engine that performs texture and pixel level processing and the memory interface. A cache system 324 is provided, and the function of generating real addresses depending on the image memory architecture is divided into a command format independent of the image memory architecture and a form of passing data, thereby enabling memory access in image processing. Since the cache is independent of the image processing memory architecture, the following effects can be obtained.

すなわち、面積、電力の増大を抑止でき、メモリアクセス機構の簡単化を図れ、設計負荷を軽減できる利点がある。
その結果、従来はメモリアーキテクチャに依存して構成されていた画像処理、すなわち3次元コンピュータグラフィックスアーキテクチャをメモリから分離し、汎用SOCなどに使用するIPにした場合、メモリシステムに依存する機能ブロック仕様が標準化されているため、容易にシステムに順応した構成をとることが可能となる。
That is, there is an advantage that an increase in area and power can be suppressed, a memory access mechanism can be simplified, and a design load can be reduced.
As a result, when the image processing, which is conventionally configured depending on the memory architecture, that is, the three-dimensional computer graphics architecture is separated from the memory and used as an IP used for general-purpose SOCs, etc., the functional block specifications depending on the memory system Can be easily adapted to the system.

本発明に係る画像処理装置の要部の一実施形態を示す構成図である。It is a block diagram which shows one Embodiment of the principal part of the image processing apparatus which concerns on this invention. 本実施形態に係るコアブロックの構成例を示すブロック図である。It is a block diagram which shows the structural example of the core block which concerns on this embodiment. 本実施形態に係るトライアングルDDA回路の機能を説明するための図である。It is a figure for demonstrating the function of the triangle DDA circuit which concerns on this embodiment. 本実施形態に係るトライアングルDDA回路の要部構成を示すブロック図である。It is a block diagram which shows the principal part structure of the triangle DDA circuit which concerns on this embodiment. 本実施形態に係るキャッシュシステムのTME_POE(RE)側とメモリアクセスブロックであるメモリインタフェース(MEMIF)が分離した、コマンドベース・キャッシュデータアクセス構造を示す図である。It is a figure which shows the command base cache data access structure which the memory interface (MEMIF) which is a memory access block and TME_POE (RE) side of the cache system which concerns on this embodiment isolate | separated. 図5のキャッシュコマンド(C・CMD)構造例を示す図である。FIG. 6 is a diagram illustrating a structure example of a cache command (C / CMD) in FIG. 5. 本実施形態におけるCキャッシュおよびZキャッシュの具体的なアクセス制御系を示す図である。It is a figure which shows the specific access control system of C cache and Z cache in this embodiment. C/Zキャッシュ16ラインの場合の2次元マップ処理を示す図である。It is a figure which shows the two-dimensional map process in the case of C / Z cache 16 lines. C/Zキャッシュ16ラインの場合のDMA側のピクセル割り当てを示す図である。It is a figure which shows the pixel allocation by the side of DMA in the case of 16 lines of C / Z cache. C/Zキャッシュ16ラインの場合のスタンプ参照の関係の一例を示す図である。It is a figure which shows an example of the relationship of the stamp reference in the case of C / Z cache 16 lines.

符号の説明Explanation of symbols

1…画像処理装置、2…システム依存ブロック、21…CPUインタフェース(BB)、22…メモリインタフェース(MEMIF)、3…コアブロック、31…ジオメトリエンジン(GE)、32…ラスタライゼーションエンジン(RE)、321…トライアングルセットアップ回路、322…トライアングルDDA回路、323…テクスチャマップエンジン(TME)・ピクセルオペレーションエンジン(POE)(TME_POE)、324…キャッシュシステム。
DESCRIPTION OF SYMBOLS 1 ... Image processing apparatus, 2 ... System dependent block, 21 ... CPU interface (BB), 22 ... Memory interface (MEMIF), 3 ... Core block, 31 ... Geometry engine (GE), 32 ... Rasterization engine (RE), 321 ... Triangle setup circuit, 322 ... Triangle DDA circuit, 323 ... Texture map engine (TME) / Pixel operation engine (POE) (TME_POE), 324 ... Cache system.

Claims (12)

メモリに対するレンダリング処理を行う画像処理装置であって、
描画すべきプリミティブに関する情報に基づいてピクセルデータを発生し、上記メモリに対するアクセスに関する情報として2次元座標を出力するピクセルエンジンと、
上記ピクセルエンジンによるに2次元座標を受けて、ピクセルデータに対して当該2次元座標に相応する2次元構造をとり、上記メモリをアクセスするために2次元座標情報に相応したコマンドとデータに標準化したキャッシュコマンドを出力するキャッシュと
を有する画像処理装置。
An image processing apparatus that performs a rendering process on a memory,
A pixel engine that generates pixel data based on information about a primitive to be drawn and outputs two-dimensional coordinates as information about access to the memory;
The two-dimensional coordinates are received by the pixel engine, the two-dimensional structure corresponding to the two-dimensional coordinates is taken for the pixel data, and the commands and data corresponding to the two-dimensional coordinate information are standardized to access the memory. An image processing apparatus having a cache that outputs a cache command.
上記キャッシュコマンドには、上記メモリの実アドレスに必要な汎用情報を含む
請求項1記載の画像処理装置。
The image processing apparatus according to claim 1, wherein the cache command includes general-purpose information necessary for an actual address of the memory.
上記キャッシュによるキャッシュコマンドを受けて上記メモリの実アドレスを生成するメモリインタフェースを、有する
請求項1記載の画像処理装置。
The image processing apparatus according to claim 1, further comprising a memory interface that receives a cache command from the cache and generates a real address of the memory.
上記キャッシュによるキャッシュコマンドを受けてメモリアーキテクチャに依存した上記メモリの実アドレスを生成するメモリインタフェースを、有する
請求項1記載の画像処理装置。
The image processing apparatus according to claim 1, further comprising: a memory interface that receives a cache command from the cache and generates a real address of the memory depending on a memory architecture.
上記キャッシュによるキャッシュコマンドを受けて上記メモリの実アドレスを生成するメモリインタフェースを、有する
請求項2記載の画像処理装置。
The image processing apparatus according to claim 2, further comprising a memory interface that receives a cache command from the cache and generates a real address of the memory.
上記キャッシュによるキャッシュコマンドを受けてメモリアーキテクチャに依存した上記メモリの実アドレスを生成するメモリインタフェースを、有する
請求項3記載の画像処理装置。
The image processing apparatus according to claim 3, further comprising a memory interface that receives a cache command from the cache and generates a real address of the memory depending on a memory architecture.
メモリに対するレンダリング処理を行う画像処理装置であって、
外部装置とのインタフェースを司る外部インタフェースと、
上記メモリとのインタフェースを司るメモリインタフェースと、
上記外部インタフェースを介して入力した描画すべきプリミティブに関する情報に基づいてピクセルデータを発生し、上記メモリに対するアクセスに関する情報として2次元座標を出力するピクセルエンジンと、
上記ピクセルエンジンによるに2次元座標を受けて、ピクセルデータに対して当該2次元座標に相応する2次元構造をとり、上記メモリをアクセスするために2次元座標情報に相応したコマンドとデータに標準化したキャッシュコマンドを出力するキャッシュと、を有し、
上記メモリインタフェースは、上記キャッシュによるキャッシュコマンドを受けて上記メモリの実アドレスを生成する
画像処理装置。
An image processing apparatus that performs a rendering process on a memory,
An external interface that controls the interface with external devices;
A memory interface for controlling the interface with the memory;
A pixel engine that generates pixel data based on information about a primitive to be drawn input via the external interface, and outputs two-dimensional coordinates as information about access to the memory;
The two-dimensional coordinates are received by the pixel engine, the two-dimensional structure corresponding to the two-dimensional coordinates is taken for the pixel data, and the commands and data corresponding to the two-dimensional coordinate information are standardized to access the memory. A cache that outputs a cache command, and
The image processing apparatus, wherein the memory interface receives a cache command from the cache and generates a real address of the memory.
上記外部インタフェースと、上記メモリとのインタフェースを司るメモリインタフェースとは、システム依存ブロックを構成し、
上記ピクセルエンジンと上記キャッシュは、システムに非依存のコアブロックを構成する
請求項7記載の画像処理装置。
The external interface and the memory interface that controls the interface with the memory constitute a system-dependent block,
The image processing apparatus according to claim 7, wherein the pixel engine and the cache constitute a system-independent core block.
上記キャッシュコマンドには、上記メモリの実アドレスに必要な汎用情報を含む
請求項7記載の画像処理装置。
The image processing apparatus according to claim 7, wherein the cache command includes general-purpose information necessary for a real address of the memory.
上記キャッシュによるキャッシュコマンドを受けてメモリアーキテクチャに依存した上記メモリの実アドレスを生成するメモリインタフェースを、有する
請求項9記載の画像処理装置。
The image processing apparatus according to claim 9, further comprising: a memory interface that receives a cache command from the cache and generates a real address of the memory depending on a memory architecture.
メモリに対するレンダリング処理を行う画像処理方法であって、
描画すべきプリミティブに関する情報に基づいてピクセルデータを発生する第1のステップと、
上記メモリに対するアクセスに関する情報として2次元座標を生成してキャッシュに与える第2のステップと、
上記キャッシュにおいて、上記メモリをアクセスするために2次元座標情報に相応したコマンドとデータに標準化したキャッシュコマンドを出力する第3のステップと
を有する画像処理方法。
An image processing method for rendering a memory,
A first step of generating pixel data based on information about the primitive to be drawn;
A second step of generating two-dimensional coordinates as information relating to access to the memory and providing the same to a cache;
An image processing method comprising: a third step of outputting a cache command standardized to data and a command corresponding to two-dimensional coordinate information for accessing the memory in the cache.
上記キャッシュコマンドを受けてメモリアーキテクチャに依存した上記メモリの実アドレスを生成する第4のステップを、有する
請求項11記載の画像処理方法。
The image processing method according to claim 11, further comprising a fourth step of receiving the cache command and generating a real address of the memory depending on a memory architecture.
JP2003307649A 2003-08-29 2003-08-29 Image processing apparatus and method Expired - Fee Related JP4419480B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2003307649A JP4419480B2 (en) 2003-08-29 2003-08-29 Image processing apparatus and method

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2003307649A JP4419480B2 (en) 2003-08-29 2003-08-29 Image processing apparatus and method

Publications (2)

Publication Number Publication Date
JP2005078357A true JP2005078357A (en) 2005-03-24
JP4419480B2 JP4419480B2 (en) 2010-02-24

Family

ID=34410382

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2003307649A Expired - Fee Related JP4419480B2 (en) 2003-08-29 2003-08-29 Image processing apparatus and method

Country Status (1)

Country Link
JP (1) JP4419480B2 (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010515131A (en) * 2006-12-26 2010-05-06 ベイダファンジェンジトゥアンヨウシャンゴンシ Method and system for generating boundaries in the process of rasterizing vector graphics, and method for manufacturing the system

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2010515131A (en) * 2006-12-26 2010-05-06 ベイダファンジェンジトゥアンヨウシャンゴンシ Method and system for generating boundaries in the process of rasterizing vector graphics, and method for manufacturing the system

Also Published As

Publication number Publication date
JP4419480B2 (en) 2010-02-24

Similar Documents

Publication Publication Date Title
JP4598030B2 (en) Tile-based precision rasterization in graphics pipelines
EP3180773B1 (en) Bandwidth reduction using texture lookup by adaptive shading
US11113788B2 (en) Multi-space rendering with configurable transformation parameters
WO2014058554A2 (en) Multi-primitive graphics rendering pipeline
US7898549B1 (en) Faster clears for three-dimensional modeling applications
US7466322B1 (en) Clipping graphics primitives to the w=0 plane
US7310103B2 (en) Pipelined 2D viewport clip circuit
US7808512B1 (en) Bounding region accumulation for graphics rendering
US6859209B2 (en) Graphics data accumulation for improved multi-layer texture performance
US6975317B2 (en) Method for reduction of possible renderable graphics primitive shapes for rasterization
JP4532746B2 (en) Method and apparatus for stretch blitting using a 3D pipeline
KR100806345B1 (en) 3-dimensional graphics accelerator and method reading texture data
US6867778B2 (en) End point value correction when traversing an edge using a quantized slope value
US6850244B2 (en) Apparatus and method for gradient mapping in a graphics processing system
US6943791B2 (en) Z-slope test to optimize sample throughput
US6963342B2 (en) Arbitration scheme for efficient parallel processing
US7385604B1 (en) Fragment scattering
US6885375B2 (en) Stalling pipelines in large designs
JP4419480B2 (en) Image processing apparatus and method
US6900803B2 (en) Method for rasterizing graphics for optimal tiling performance
US6895458B2 (en) Opcode to turn around a bi-directional bus
JP2008502979A (en) Inverse texture mapping 3D graphics system
US6847372B2 (en) Magnified texture-mapped pixel performance in a single-pixel pipeline
US6831645B2 (en) System and method for performing font operations when background color is transparent
US6847368B2 (en) Graphics system with a buddy / quad mode for faster writes

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20060817

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20090810

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20090825

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20091016

TRDD Decision of grant or rejection written
A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

Effective date: 20091110

A01 Written decision to grant a patent or to grant a registration (utility model)

Free format text: JAPANESE INTERMEDIATE CODE: A01

A61 First payment of annual fees (during grant procedure)

Free format text: JAPANESE INTERMEDIATE CODE: A61

Effective date: 20091123

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20121211

Year of fee payment: 3

FPAY Renewal fee payment (event date is renewal date of database)

Free format text: PAYMENT UNTIL: 20121211

Year of fee payment: 3

LAPS Cancellation because of no payment of annual fees