JP2006252292A - Program, information storage medium and image generation system - Google Patents

Program, information storage medium and image generation system Download PDF

Info

Publication number
JP2006252292A
JP2006252292A JP2005069378A JP2005069378A JP2006252292A JP 2006252292 A JP2006252292 A JP 2006252292A JP 2005069378 A JP2005069378 A JP 2005069378A JP 2005069378 A JP2005069378 A JP 2005069378A JP 2006252292 A JP2006252292 A JP 2006252292A
Authority
JP
Japan
Prior art keywords
rank
buffer
value
model
unit
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.)
Withdrawn
Application number
JP2005069378A
Other languages
Japanese (ja)
Inventor
Shigeru Kikko
繁 橘高
Yoshiyuki Matsumoto
欣之 松本
Takashi Imakire
隆 今給黎
Junichi Terada
順一 寺田
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.)
Bandai Namco Entertainment Inc
Original Assignee
Namco Bandai Games 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 Namco Bandai Games Inc filed Critical Namco Bandai Games Inc
Priority to JP2005069378A priority Critical patent/JP2006252292A/en
Publication of JP2006252292A publication Critical patent/JP2006252292A/en
Withdrawn legal-status Critical Current

Links

Abstract

<P>PROBLEM TO BE SOLVED: To provide a program, an information storage medium and an image generation system for performing the flexible control of hidden-surface elimination. <P>SOLUTION: This image generation system is provided with a rank information storage part for storing rank information for setting the rank of the plotting sequence of a plurality of model objects, a Z buffer for storing the Z value of each pixel and a plotting part for successively plotting the plurality of model objects while referring to the Z value of the Z buffer from the model object whose plotting sequence rank is low to the model object whose plotting sequence rank is high in a plotting sequence following the rank information. The plotting part clears the Z value of the Z buffer generated by plotting the model object in the Kth plotting sequence rank, and plots the model object in the Lth plotting sequence rank whose rank is higher than the Kth plotting sequence rank. <P>COPYRIGHT: (C)2006,JPO&NCIPI

Description

本発明は、プログラム、情報記憶媒体及び画像生成システムに関する。   The present invention relates to a program, an information storage medium, and an image generation system.

従来より、キャラクタなどのオブジェクトが配置設定されるオブジェクト空間内(仮想的な3次元空間)において仮想カメラ(所与の視点)から見える画像を生成する画像生成システム(ゲームシステム)が知られており、いわゆる仮想現実を体験できるものとして人気が高い。ロールプレイングゲーム(RPG)を楽しむことができる画像生成システムを例にとれば、プレイヤは、自身の分身であるキャラクタ(広義にはモデルオブジェクト)を操作してオブジェクト空間内のマップ上で移動させて、敵キャラクタと対戦したり、他のキャラクタと対話したり、様々な町を訪れたりすることでゲームを楽しむ。   Conventionally, an image generation system (game system) that generates an image that can be viewed from a virtual camera (a given viewpoint) in an object space (virtual three-dimensional space) in which an object such as a character is set is known. It is popular as a place to experience so-called virtual reality. Taking an image generation system that can enjoy a role-playing game (RPG) as an example, a player operates a character (a model object in a broad sense), which is his or her own character, and moves it on a map in the object space. Enjoy the game by playing against enemy characters, interacting with other characters, and visiting various towns.

このような画像生成システムでは、Zバッファを用いたZバッファ法により隠面消去を行うのが一般的である。   In such an image generation system, the hidden surface removal is generally performed by a Z buffer method using a Z buffer.

ところが、ゲームの種類によっては、このようなZバッファ法により一律に隠面消去を行うと、キャラクタ同士が重なり合って見えてしまう不具合画像が生成されてしまうことが判明した。例えば、従来の2次元ゲームの手法を踏襲し、戦闘シーンにおいて1本の基準ライン上で自キャラクタを移動させて敵キャラクタと対戦させるようなゲーム等においては、キャラクタ同士が重なり合って見えてしまう不具合画像が頻繁に生成されるおそれがある。
特開2004−73241号公報
However, it has been found that, depending on the type of game, when the hidden surface removal is uniformly performed by such a Z-buffer method, a defect image is generated in which characters appear to overlap each other. For example, in a game that follows the conventional two-dimensional game technique and moves the player's character on a single reference line in a battle scene to play against an enemy character, the characters appear to overlap each other. Images may be generated frequently.
JP 2004-73241 A

本発明は、以上のような課題に鑑みてなされたものであり、その目的とするところは、隠面消去の柔軟な制御を可能にするプログラム、情報記憶媒体及び画像生成システムを提供することにある。   The present invention has been made in view of the above problems, and an object thereof is to provide a program, an information storage medium, and an image generation system that enable flexible control of hidden surface removal. is there.

本発明は、画像を生成する画像生成システムであって、複数のモデルオブジェクトの描画順序のランクを設定するためのランク情報を記憶するランク情報記憶部と、各画素のZ値を記憶するZバッファと、前記ランク情報に従った描画順序で、描画順序ランクの低いモデルオブジェクトから描画順序ランクの高いモデルオブジェクトへと、前記ZバッファのZ値を参照しながら前記複数のモデルオブジェクトを順次描画する描画部とを含み、前記描画部は、第Kの描画順序ランクのモデルオブジェクトを描画することで生成された前記ZバッファのZ値をクリアした後に、前記第Kの描画順序ランクよりもランクが高い第Lの描画順序ランク(K、Lは、1≦K<N、1<L≦N、K<Lとなる任意の整数)のモデルオブジェクトを描画する画像生成システムに関係する。また本発明は、上記各部としてコンピュータを機能させるプログラムに関係する。また本発明は、コンピュータ読み取り可能な情報記憶媒体であって、上記各部としてコンピュータを機能させるプログラムを記憶(記録)した情報記憶媒体に関係する。   The present invention is an image generation system that generates an image, and includes a rank information storage unit that stores rank information for setting the rank of a drawing order of a plurality of model objects, and a Z buffer that stores a Z value of each pixel. A drawing in which the plurality of model objects are sequentially drawn from a model object having a low drawing order rank to a model object having a high drawing order rank, with reference to the Z value of the Z buffer, in the drawing order according to the rank information. The drawing unit has a higher rank than the Kth drawing order rank after clearing the Z value of the Z buffer generated by drawing the model object having the Kth drawing order rank. Draw model objects of the Lth drawing order rank (K and L are arbitrary integers satisfying 1 ≦ K <N, 1 <L ≦ N, and K <L). Relating to an image generation system. The present invention also relates to a program that causes a computer to function as each of the above-described units. The present invention also relates to a computer-readable information storage medium that stores (records) a program that causes a computer to function as each unit.

本発明によれば、ランク情報に基づいて、描画順序ランクの低いモデルオブジェクトから描画順序ランクの高いモデルオブジェクトへと複数のモデルオブジェクトが描画される。そして、第Kの描画順序ランクのモデルオブジェクトを描画することで生成されたZバッファのZ値をクリアした後に、ランクが高い第Lの描画順序ランクのモデルオブジェクトが描画される。このようにすれば、第Kの描画順序ランクのモデルオブジェクトと第Lの描画順序ランクのモデルオブジェクトの配置位置が同一であったり、近い場合などであっても、第Lの描画順序ランクのモデルオブジェクトの方が手前側に見える画像を生成できるようになる。また各モデルオブジェクト内においては、Zバッファを用いて適正な隠面消去処理が行われるようになる。従って、隠面消去の柔軟な制御を可能にする画像生成システム等を提供できる。   According to the present invention, based on rank information, a plurality of model objects are drawn from a model object with a low drawing order rank to a model object with a high drawing order rank. Then, after clearing the Z value of the Z buffer generated by drawing the model object having the Kth drawing order rank, the model object having the Lth drawing order rank having a higher rank is drawn. In this way, even if the arrangement position of the model object of the Kth drawing order rank and the model object of the Lth drawing order rank is the same or close, the model of the Lth drawing order rank It becomes possible to generate an image in which the object is seen on the front side. In each model object, an appropriate hidden surface removal process is performed using a Z buffer. Accordingly, it is possible to provide an image generation system or the like that enables flexible control of hidden surface removal.

なおZバッファのZ値のクリアとは、例えばZ値を無限遠を表す値に設定すること(Z値を削除すること)を意味する。例えば仮想カメラから見て奥側になるほどZ値が小さくなるシステムでは、Z=0に設定することでZバッファのZ値をクリアできる。また仮想カメラから見て奥側になるほどZ値が大きくなるシステムでは、Z=無限大に設定することでZバッファのZ値をクリアできる。   Note that clearing the Z value of the Z buffer means, for example, setting the Z value to a value representing infinity (deleting the Z value). For example, in a system in which the Z value decreases with increasing distance from the virtual camera, the Z value in the Z buffer can be cleared by setting Z = 0. In a system in which the Z value increases toward the back as viewed from the virtual camera, the Z value in the Z buffer can be cleared by setting Z = infinity.

また本発明に係る画像生成システム、プログラム及び情報記憶媒体では、前記描画部は、前記複数のモデルオブジェクトを描画する前に背景オブジェクトを描画し、前記背景オブジェクトの描画により生成された前記ZバッファのZ値をワークバッファにコピーしておき、前記第Kの描画順序ランクのモデルオブジェクトを描画することで生成された前記ZバッファのZ値を、前記ワークバッファに合成し、合成後に、前記ZバッファのZ値をクリアするようにしてもよい。   In the image generation system, the program, and the information storage medium according to the present invention, the drawing unit draws a background object before drawing the plurality of model objects, and stores the Z buffer generated by drawing the background object. The Z value is copied to the work buffer, and the Z value of the Z buffer generated by drawing the model object of the Kth drawing order rank is combined with the work buffer. The Z value may be cleared.

このようにすれば、背景オブジェクトの描画によりZバッファに生成されたZ値が、Zバッファのクリア処理により消失してしまう事態を防止できる。   In this way, it is possible to prevent the Z value generated in the Z buffer by drawing the background object from being lost due to the Z buffer clear process.

また本発明に係る画像生成システム、プログラム及び情報記憶媒体では、前記描画部は、全ての前記複数のモデルオブジェクトの描画完了後に、前記ワークバッファに生成されたZ値を前記Zバッファにコピーし、前記ZバッファにコピーされたZ値に基づいて、前記複数のモデルオブジェクトよりも視点から見て手前側に配置されるオブジェクトの描画処理、及びZ値を用いたフィルタ処理の少なくとも一方を行うようにしてもよい。   In the image generation system, the program, and the information storage medium according to the present invention, the drawing unit copies the Z value generated in the work buffer to the Z buffer after the drawing of all the plurality of model objects is completed, Based on the Z value copied to the Z buffer, at least one of drawing processing of an object arranged on the near side as viewed from the viewpoint of the plurality of model objects and filtering processing using the Z value are performed. May be.

このようにすれば、Zバッファに最終的に生成されたZ値に基づいて、手前側のオブジェクトの適正な描画処理を行ったり、フィルタ処理を行うことが可能になる。   In this way, it is possible to perform an appropriate drawing process or a filter process on the near object based on the Z value finally generated in the Z buffer.

また本発明に係る画像生成システム、プログラム及び情報記憶媒体では、前記描画部は、前記第Kの描画順序ランクに複数のモデルオブジェクトが属している場合に、前記ZバッファのZ値を参照しながら前記第Kの描画順序ランクに属している複数のモデルオブジェクトを描画し、描画後に前記ZバッファのZ値をクリアし、クリア後に前記第Lの描画順序ランクのモデルオブジェクトを描画するようにしてもよい。   In the image generation system, the program, and the information storage medium according to the present invention, the drawing unit refers to the Z value of the Z buffer when a plurality of model objects belong to the Kth drawing order rank. A plurality of model objects belonging to the Kth drawing order rank are drawn, the Z value of the Z buffer is cleared after drawing, and the model object of the Lth drawing order rank is drawn after clearing. Good.

このようにすれば、同一の描画順序ランクに属する複数のモデルオブジェクトについては、Zバッファを用いて適正に隠面消去されてその画像が生成されるようになるため、生成される画像のバラエティ度を増すことができる。   In this way, for a plurality of model objects belonging to the same drawing order rank, the hidden surface is appropriately erased using the Z buffer and the image is generated, so the variety degree of the generated image Can be increased.

また本発明に係る画像生成システム、プログラム及び情報記憶媒体では、各描画順序ランクに属しているモデルオブジェクトの少なくとも個数情報を設定するためのリンク情報を記憶するリンク情報記憶部を含み(リンク情報記憶部としてコンピュータを機能させ)、前記描画部は、前記リンク情報に基づいて、前記第Kの描画順序ランクに属している複数のモデルオブジェクトを描画するようにしてもよい。   In addition, the image generation system, the program, and the information storage medium according to the present invention include a link information storage unit that stores link information for setting at least the number information of model objects belonging to each drawing order rank (link information storage). And the drawing unit may draw a plurality of model objects belonging to the Kth drawing order rank based on the link information.

このようにすれば、同一の描画順序ランクに属する複数のモデルオブジェクトの個数をリンク情報に基づいて判断しながら、これらの複数のモデルオブジェクトの適切な描画処理を実現できるようになる。   In this way, it is possible to realize appropriate drawing processing of the plurality of model objects while determining the number of the plurality of model objects belonging to the same drawing order rank based on the link information.

また本発明に係る画像生成システム、プログラム及び情報記憶媒体では、操作部からの操作情報に基づいて、複数のモデルオブジェクトを移動フィールド上の基準ライン上で移動・動作させる制御を行う移動・動作処理部を含むようにしてもよい(移動・動作処理部としてコンピュータを機能させるようにしてもよい)。   In the image generation system, the program, and the information storage medium according to the present invention, a movement / motion process for performing control for moving / moving a plurality of model objects on the reference line on the movement field based on operation information from the operation unit. May be included (the computer may function as a movement / operation processing unit).

以下、本実施形態について説明する。なお、以下に説明する本実施形態は、特許請求の範囲に記載された本発明の内容を不当に限定するものではない。また本実施形態で説明される構成の全てが、本発明の必須構成要件であるとは限らない。   Hereinafter, this embodiment will be described. In addition, this embodiment demonstrated below does not unduly limit the content of this invention described in the claim. In addition, all the configurations described in the present embodiment are not necessarily essential configuration requirements of the present invention.

1.構成
図1に本実施形態の画像生成システム(ゲームシステム)の機能ブロック図の例を示す。なお本実施形態の画像生成システムは図1の構成要素(各部)の一部を省略した構成としてもよい。
1. Configuration FIG. 1 shows an example of a functional block diagram of an image generation system (game system) of the present embodiment. Note that the image generation system of the present embodiment may have a configuration in which some of the components (each unit) in FIG. 1 are omitted.

操作部160は、プレイヤが操作データを入力するためのものであり、その機能は、レバー、ボタン、ステアリング、マイク、タッチパネル型ディスプレイ、或いは筺体などにより実現できる。記憶部170は、処理部100や通信部196などのワーク領域やメインメモリとなるものであり、その機能はRAM(VRAM)などにより実現できる。   The operation unit 160 is for a player to input operation data, and the function can be realized by a lever, a button, a steering, a microphone, a touch panel display, or a housing. The storage unit 170 is a work area such as the processing unit 100 or the communication unit 196 or a main memory, and its function can be realized by a RAM (VRAM) or the like.

情報記憶媒体180(コンピュータにより読み取り可能な媒体)は、プログラムやデータなどを格納するものであり、その機能は、光ディスク(CD、DVD)、ハードディスク、メモリーカード、メモリーカセット、磁気ディスク、或いはメモリ(ROM)などにより実現できる。処理部100は、情報記憶媒体180に格納されているプログラム(データ)に基づいて本実施形態の種々の処理を行う。即ち情報記憶媒体180には、本実施形態の各部としてコンピュータを機能させるためのプログラム(各部の処理手順をコンピュータに実行させるためのプログラム)が記憶される。   The information storage medium 180 (computer-readable medium) stores programs, data, and the like, and functions as an optical disk (CD, DVD), hard disk, memory card, memory cassette, magnetic disk, or memory ( ROM) or the like. The processing unit 100 performs various processes of the present embodiment based on a program (data) stored in the information storage medium 180. That is, the information storage medium 180 stores a program for causing a computer to function as each unit of the present embodiment (a program for causing a computer to execute the processing procedure of each unit).

表示部190は、本実施形態により生成された画像を出力するものであり、その機能は、CRT、LCD(液晶表示装置)、タッチパネル型ディスプレイ、或いはHMD(ヘッドマウントディスプレイ)などにより実現できる。音出力部192は、本実施形態により生成された音を出力するものであり、その機能は、スピーカ、或いはヘッドフォンなどにより実現できる。   The display unit 190 outputs an image generated according to the present embodiment, and its function can be realized by a CRT, LCD (Liquid Crystal Display), touch panel display, HMD (Head Mount Display), or the like. The sound output unit 192 outputs the sound generated by the present embodiment, and its function can be realized by a speaker, headphones, or the like.

携帯型情報記憶装置194は、プレイヤの個人データやゲームのセーブデータなどが記憶されるものであり、この携帯型情報記憶装置194としては、メモリカードや携帯型ゲーム装置などがある。通信部196は外部(例えばホスト装置や他の画像生成システム)との間で通信を行うための各種制御を行うものであり、その機能は、各種プロセッサ又は通信用ASICなどのハードウェアや、プログラムなどにより実現できる。   The portable information storage device 194 stores player personal data, game save data, and the like, and examples of the portable information storage device 194 include a memory card and a portable game device. The communication unit 196 performs various controls for communicating with the outside (for example, a host device or other image generation system), and functions thereof are hardware such as various processors or communication ASICs, programs, and the like. It can be realized by.

なお本実施形態の各部としてコンピュータを機能させるためのプログラム(データ)は、ホスト装置(サーバ)が有する情報記憶媒体からネットワーク及び通信部196を介して情報記憶媒体180(記憶部170)に配信してもよい。このようなホスト装置(サーバ)の情報記憶媒体の使用も本発明の範囲内に含めることができる。   Note that a program (data) for causing a computer to function as each unit of the present embodiment is distributed from the information storage medium of the host device (server) to the information storage medium 180 (storage unit 170) via the network and communication unit 196. May be. Use of the information storage medium of such a host device (server) can also be included in the scope of the present invention.

処理部100(プロセッサ)は、操作部160からの操作データやプログラムなどに基づいて、ゲーム処理、画像生成処理、或いは音生成処理などの処理を行う。ここでゲーム処理としては、ゲーム開始条件が満たされた場合にゲームを開始する処理、ゲームを進行させる処理、キャラクタやマップなどのオブジェクトを配置する処理、オブジェクトを表示する処理、ゲーム結果を演算する処理、或いはゲーム終了条件が満たされた場合にゲームを終了する処理などがある。この処理部100は記憶部170をワーク領域として各種処理を行う。処理部100の機能は各種プロセッサ(CPU、DSP等)、ASIC(ゲートアレイ等)などのハードウェアや、プログラムにより実現できる。   The processing unit 100 (processor) performs processing such as game processing, image generation processing, or sound generation processing based on operation data and programs from the operation unit 160. Here, as the game process, a process for starting a game when a game start condition is satisfied, a process for advancing the game, a process for placing an object such as a character or a map, a process for displaying an object, and a game result are calculated. There is a process or a process of ending a game when a game end condition is satisfied. The processing unit 100 performs various processes using the storage unit 170 as a work area. The functions of the processing unit 100 can be realized by hardware such as various processors (CPU, DSP, etc.), ASIC (gate array, etc.), and programs.

処理部100は、オブジェクト空間設定部110、移動・動作処理部112、仮想カメラ制御部114、描画部120、音生成部130を含む。なおこれらの一部を省略する構成としてもよい。   The processing unit 100 includes an object space setting unit 110, a movement / motion processing unit 112, a virtual camera control unit 114, a drawing unit 120, and a sound generation unit 130. Note that some of these may be omitted.

オブジェクト空間設定部110は、キャラクタ、車、戦車、建物、樹木、柱、壁、マップ(地形)などの表示物を表す各種オブジェクト(ポリゴン、自由曲面又はサブディビジョンサーフェスなどのプリミティブ面で構成されるオブジェクト)をオブジェクト空間に配置設定する処理を行う。即ちワールド座標系でのオブジェクト(モデルオブジェクト)の位置や回転角度(向き、方向と同義)を決定し、その位置(X、Y、Z)にその回転角度(X、Y、Z軸回りでの回転角度)でオブジェクトを配置する。   The object space setting unit 110 includes various objects (primitive surfaces such as polygons, free-form surfaces, and subdivision surfaces) representing display objects such as characters, cars, tanks, buildings, trees, columns, walls, and maps (terrain). (Object) is set in the object space. That is, the position and rotation angle (synonymous with direction and direction) of the object (model object) in the world coordinate system are determined, and the rotation angle (X, Y, Z axis around the position (X, Y, Z)) is determined. Arrange objects at (rotation angle).

移動・動作処理部112は、オブジェクト(キャラクタ、車、又は飛行機等)の移動・動作演算(移動・動作シミュレーション)を行う。即ち操作部160によりプレイヤが入力した操作データや、プログラム(移動・動作アルゴリズム)や、各種データ(モーションデータ)などに基づいて、オブジェクト(移動オブジェクト)をオブジェクト空間内で移動させたり、オブジェクトを動作(モーション、アニメーション)させる処理を行う。具体的には、オブジェクトの移動情報(位置、回転角度、速度、或いは加速度)や動作情報(各パーツオブジェクトの位置、或いは回転角度)を、1フレーム毎(1/60秒)に順次求めるシミュレーション処理を行う。なおフレーム(フレームレート)は、オブジェクトの移動・動作処理(シミュレーション処理)や画像生成処理を行う時間の単位である。   The movement / motion processing unit 112 performs a movement / motion calculation (movement / motion simulation) of an object (such as a character, a car, or an airplane). That is, an object (moving object) is moved in the object space or an object is moved based on operation data input by the player through the operation unit 160, a program (movement / motion algorithm), various data (motion data), or the like. Perform processing (motion, animation). Specifically, simulation processing for sequentially obtaining object movement information (position, rotation angle, speed, or acceleration) and motion information (position or rotation angle of each part object) every frame (1/60 seconds) I do. The frame (frame rate) is a unit of time for performing object movement / motion processing (simulation processing) and image generation processing.

また本実施形態では、移動・動作処理部112(移動処理部)は、操作部160からの操作情報に基づいて、複数のモデルオブジェクト(キャラクタ)を移動フィールド(移動マップ、ゲームフィールド)上の基準ライン(移動ライン)上で移動させたり、動作させる制御を行う。例えばプレイヤが操作部160により左移動を指示すると、モデルオブジェクトは基準ライン上で左に移動し、右移動を指示すると右に移動する。またプレイヤが操作部160により攻撃を指示すると、自身が操作するモデルオブジェクト(自キャラクタ)が敵のモデルオブジェクト(敵キャラクタ)に対して攻撃する動作を行う。   In the present embodiment, the movement / motion processing unit 112 (movement processing unit) determines a plurality of model objects (characters) as a reference on a movement field (movement map, game field) based on operation information from the operation unit 160. Control to move or operate on the line (moving line). For example, when the player instructs the left movement by the operation unit 160, the model object moves to the left on the reference line, and when the player instructs the right movement, the model object moves to the right. When the player instructs an attack using the operation unit 160, the model object (self character) operated by the player performs an action of attacking the enemy model object (enemy character).

仮想カメラ制御部114は、オブジェクト空間内の所与(任意)の視点から見える画像を生成するための仮想カメラ(視点)の制御処理を行う。具体的には、仮想カメラの位置(X、Y、Z)又は回転角度(X、Y、Z軸回りでの回転角度)を制御する処理(視点位置や視線方向を制御する処理)を行う。   The virtual camera control unit 114 performs a virtual camera (viewpoint) control process for generating an image viewed from a given (arbitrary) viewpoint in the object space. Specifically, a process for controlling the position (X, Y, Z) or the rotation angle (rotation angle about the X, Y, Z axes) of the virtual camera (process for controlling the viewpoint position and the line-of-sight direction) is performed.

例えば仮想カメラによりオブジェクト(例えばキャラクタ、ボール、車)を後方から撮影する場合には、オブジェクトの位置又は回転の変化に仮想カメラが追従するように、仮想カメラの位置又は回転角度(仮想カメラの向き)を制御する。この場合には、移動・動作処理部112で得られたオブジェクトの位置、回転角度又は速度などの情報に基づいて、仮想カメラを制御できる。或いは、仮想カメラを、予め決められた回転角度で回転させたり、予め決められた移動経路で移動させる制御を行ってもよい。この場合には、仮想カメラの位置(移動経路)又は回転角度を特定するための仮想カメラデータに基づいて仮想カメラを制御する。   For example, when an object (eg, character, ball, car) is photographed from behind using a virtual camera, the position or rotation angle of the virtual camera (the direction of the virtual camera is set so that the virtual camera follows changes in the position or rotation of the object. ) To control. In this case, the virtual camera can be controlled based on information such as the position, rotation angle, or speed of the object obtained by the movement / motion processing unit 112. Alternatively, the virtual camera may be controlled to rotate at a predetermined rotation angle or to move along a predetermined movement path. In this case, the virtual camera is controlled based on the virtual camera data for specifying the position (movement path) or rotation angle of the virtual camera.

描画部120は、処理部100で行われる種々の処理(ゲーム処理)の結果に基づいて描画処理を行い、これにより画像を生成し、表示部190に出力する。いわゆる3次元ゲーム画像を生成する場合には、まず、座標変換(ワールド座標変換、カメラ座標変換)、クリッピング処理、或いは透視変換等のジオメトリ処理が行われ、その処理結果に基づいて、描画データ(プリミティブ面の頂点の位置座標、テクスチャ座標、色データ、法線ベクトル或いはα値等)が作成される。そして、この描画データ(プリミティブ面データ)に基づいて、透視変換後(ジオメトリ処理後)のオブジェクト(1又は複数プリミティブ面)を描画バッファ172(フレームバッファ、ワークバッファなどのピクセル単位で画像情報を記憶できるバッファ。VRAM)に描画する。これにより、オブジェクト空間内において仮想カメラ(所与の視点)から見える画像が生成される。なお描画部120での描画処理は、いわゆるピクセルシェーダーや頂点シェーダーにより実現してもよい。   The drawing unit 120 performs drawing processing based on the results of various processing (game processing) performed by the processing unit 100, thereby generating an image and outputting the image to the display unit 190. In the case of generating a so-called three-dimensional game image, first, geometric processing such as coordinate transformation (world coordinate transformation, camera coordinate transformation), clipping processing, or perspective transformation is performed, and drawing data ( The position coordinates, texture coordinates, color data, normal vector, α value, etc.) of the vertexes of the primitive surface are created. Then, based on the drawing data (primitive surface data), the object (one or a plurality of primitive surfaces) after the perspective transformation (after the geometry processing) is stored in the drawing buffer 172 (frame buffer, work buffer, etc.) in pixel units. Can be drawn in a VRAM). Thereby, an image that can be seen from the virtual camera (given viewpoint) in the object space is generated. Note that the drawing process in the drawing unit 120 may be realized by a so-called pixel shader or vertex shader.

描画部120は、テクスチャマッピング処理や隠面消去処理やαブレンディング処理を行うことができる。   The drawing unit 120 can perform texture mapping processing, hidden surface removal processing, and α blending processing.

ここでテクスチャマッピング処理は、テクスチャ記憶部174に記憶されるテクスチャ(テクセル値)をオブジェクトにマッピングする処理である。具体的には、オブジェクト(プリミティブ面)の頂点に設定(付与)されるテクスチャ座標等を用いてテクスチャ記憶部174からテクスチャ(色、α値などの表面プロパティ)を読み出す。そして、2次元の画像又はパターンであるテクスチャをオブジェクトにマッピングする。この場合に、ピクセルとテクセルとを対応づける処理やバイリニア補間(テクセル補間)などを行う。   Here, the texture mapping process is a process of mapping a texture (texel value) stored in the texture storage unit 174 to an object. Specifically, the texture (surface properties such as color and α value) is read from the texture storage unit 174 using the texture coordinates set (given) at the vertices of the object (primitive surface). Then, a texture that is a two-dimensional image or pattern is mapped to the object. In this case, processing for associating pixels and texels, bilinear interpolation (texel interpolation), and the like are performed.

また隠面消去処理は、例えば、各ピクセルのZ値(奥行き情報)が格納されているZバッファ176(奥行きバッファ)を用いるZバッファ法(奥行き比較法、Zテスト)により実現される。即ちオブジェクトのプリミティブ面の各ピクセルを描画する際に、Zバッファ176に格納されているZ値(カメラ座標系でのZ値)を参照する。そして参照されたZバッファ176のZ値と、プリミティブ面の描画対象ピクセルでのZ値とを比較し、描画対象ピクセルでのZ値が、仮想カメラから見て手前側となるZ値(例えば大きなZ値)である場合には、そのピクセルの描画処理を行うと共にZバッファ176のZ値を新たなZ値に更新する。   The hidden surface removal processing is realized by, for example, a Z buffer method (depth comparison method, Z test) using a Z buffer 176 (depth buffer) in which the Z value (depth information) of each pixel is stored. That is, when drawing each pixel of the primitive surface of the object, the Z value (Z value in the camera coordinate system) stored in the Z buffer 176 is referred to. Then, the Z value of the referenced Z buffer 176 is compared with the Z value at the drawing target pixel on the primitive surface, and the Z value at the drawing target pixel is the front side when viewed from the virtual camera (for example, a large value) Z value), the drawing process for the pixel is performed and the Z value in the Z buffer 176 is updated to a new Z value.

またαブレンディング処理は、α値(A値)に基づいて行う処理であり、通常αブレンディング、加算αブレンディング或いは減算αブレンディングなどがある。例えば通常αブレンディングの場合には下式の処理を行う。   The α blending process is a process performed based on the α value (A value), and includes normal α blending, addition α blending, subtraction α blending, and the like. For example, in the case of normal α blending, the following processing is performed.

Q=(1−α)×R1+α×R2
Q=(1−α)×G1+α×G2
Q=(1−α)×B1+α×B2
一方、加算αブレンディングの場合には下式の処理を行う。
R Q = (1−α) × R 1 + α × R 2
G Q = (1−α) × G 1 + α × G 2
B Q = (1−α) × B 1 + α × B 2
On the other hand, in the case of addition α blending, the following processing is performed.

Q=R1+α×R2
Q=G1+α×G2
Q=B1+α×B2
また、減算αブレンディングの場合には下式の処理を行う。
R Q = R 1 + α × R 2
G Q = G 1 + α × G 2
B Q = B 1 + α × B 2
In the case of subtractive α blending, the following processing is performed.

Q=R1−α×R2
Q=G1−α×G2
Q=B1−α×B2
ここで、R1、G1、B1は、描画バッファ172(フレームバッファ)に既に描画されている画像(元画像)のRGB成分であり、R2、G2、B2は、描画バッファ172に描画すべき画像のRGB成分である。また、RQ、GQ、BQは、αブレンディングにより得られる画像のRGB成分である。なおα値は、各ピクセル(テクセル、ドット)に関連づけて記憶できる情報であり、例えば色情報以外のプラスアルファの情報である。α値は、半透明度(透明度、不透明度と等価)情報、マスク情報、或いはバンプ情報などとして使用できる。
R Q = R 1 −α × R 2
G Q = G 1 −α × G 2
B Q = B 1 −α × B 2
Here, R 1 , G 1 , and B 1 are RGB components of an image (original image) already drawn in the drawing buffer 172 (frame buffer), and R 2 , G 2 , and B 2 are drawing buffers 172. Are RGB components of the image to be drawn. R Q , G Q , and B Q are RGB components of an image obtained by α blending. The α value is information that can be stored in association with each pixel (texel, dot), for example, plus alpha information other than color information. The α value can be used as translucency (equivalent to transparency and opacity) information, mask information, or bump information.

そして本実施形態では、記憶部170のランク情報記憶部177が、モデルオブジェクト(複数のパーツオブジェクトにより構成されるオブジェクト)の描画順序のランクを設定(指定)するためのランク情報を記憶する。またリンク情報記憶部178が、各描画順序ランクに属している(登録されている)モデルオブジェクトの少なくとも個数情報を設定するためのリンク情報を記憶する。   In the present embodiment, the rank information storage unit 177 of the storage unit 170 stores rank information for setting (designating) the rank of the drawing order of model objects (objects composed of a plurality of part objects). The link information storage unit 178 stores link information for setting at least the number information of model objects belonging to (registered) each drawing order rank.

描画部120は、ランク情報記憶部177に記憶されるランク情報に応じた描画順序で、描画順序ランクの低いモデルオブジェクトから描画順序ランクの高いモデルオブジェクトへと、複数のモデルオブジェクトをフレームバッファ(描画バッファ172の中の1つのバッファ)等に描画する。この際に、Zバッファ176のZ値を参照してZバッファ法により隠面消去を行う。例えば描画部120は、RANK=0の描画順序ランクのモデルオブジェクトを描画し、次にRANK=1のモデルオブジェクトを描画し、次にRANK=2のモデルオブジェクトを描画する。なお同一の描画順序ランクに属するモデルオブジェクトが複数存在する場合には、それらの複数のモデルオブジェクトを描画した後に、次の描画順序ランクのモデルオブジェクトを描画する。   The drawing unit 120 uses a frame buffer (drawing) to draw a plurality of model objects from a model object with a low drawing order rank to a model object with a high drawing order rank in a drawing order according to the rank information stored in the rank information storage unit 177. Drawing is performed in one buffer in the buffer 172). At this time, hidden surface removal is performed by the Z buffer method with reference to the Z value of the Z buffer 176. For example, the drawing unit 120 draws a model object having a drawing order rank of RANK = 0, then draws a model object of RANK = 1, and then draws a model object of RANK = 2. If there are a plurality of model objects belonging to the same drawing order rank, after drawing the plurality of model objects, the model object of the next drawing order rank is drawn.

そして描画部120は、例えば第Kの描画順序ランクのモデルオブジェクトを描画することで生成されたZバッファ176のZ値をクリアした後(初期化した後)に、第Kの描画順序ランクよりもランクが高い第Lの描画順序ランク(K、Lは、1≦K<N、1<L≦N、K<Lとなる任意の整数)のモデルオブジェクトを描画する。例えばRANK=0のモデルオブジェクトを描画することで生成されたZバッファ176のZ値をクリアした後に、RANK=1のモデルオブジェクトを描画する。またRANK=1のモデルオブジェクトを描画することで生成されたZバッファ176のZ値をクリアした後に、RANK=2のモデルオブジェクトを描画する。   Then, the drawing unit 120 clears the Z value of the Z buffer 176 generated by, for example, drawing the model object of the Kth drawing order rank (after initialization), and then, more than the Kth drawing order rank. A model object of the Lth drawing order rank (K, L is an arbitrary integer satisfying 1 ≦ K <N, 1 <L ≦ N, and K <L) having a higher rank is drawn. For example, after clearing the Z value of the Z buffer 176 generated by drawing the model object with RANK = 0, the model object with RANK = 1 is drawn. Further, after clearing the Z value of the Z buffer 176 generated by drawing the model object of RANK = 1, the model object of RANK = 2 is drawn.

更に具体的には描画部120は、複数のモデルオブジェクトを描画する前にその背景オブジェクトを描画し、背景オブジェクトの描画により生成されたZバッファ176のZ値をワークバッファ(描画バッファ172の中の1つのバッファ)にコピー(退避)しておく。そして第Kの描画順序ランクのモデルオブジェクトを描画することで生成されたZバッファ176のZ値を、ワークバッファに合成し(書き込み)、合成後にZバッファ176のZ値をクリアする。例えばRANK=0のモデルオブジェクトを描画し、描画により生成されたZバッファ176のZ値をワークバッファに合成する。即ち背景オブジェクトの描画によりワークバッファに生成されたZ値のプレーンと、RANK=0のモデルオブジェクトの描画により生成されたZバッファ176のZ値のプレーンとを合成する。そして合成後にZバッファ176をクリアする。次に、RANK=1のモデルオブジェクトを描画し、描画により生成されたZバッファ176のZ値をワークバッファに合成し、合成後にZバッファ176をクリアする。   More specifically, the drawing unit 120 draws a background object before drawing a plurality of model objects, and uses the Z value of the Z buffer 176 generated by drawing the background object as a work buffer (in the drawing buffer 172). It is copied (saved) in one buffer). Then, the Z value of the Z buffer 176 generated by drawing the model object of the Kth drawing order rank is combined (written) in the work buffer, and the Z value of the Z buffer 176 is cleared after the combining. For example, a model object with RANK = 0 is drawn, and the Z value of the Z buffer 176 generated by the drawing is combined with the work buffer. That is, the Z value plane generated in the work buffer by drawing the background object and the Z value plane of the Z buffer 176 generated by drawing the model object with RANK = 0 are combined. Then, the Z buffer 176 is cleared after the composition. Next, a model object of RANK = 1 is drawn, the Z value of the Z buffer 176 generated by the drawing is combined with the work buffer, and the Z buffer 176 is cleared after the combination.

なお複数のモデルオブジェクトを描画する前に描画する背景オブジェクトは、モデルオブジェクトよりも視点から見て奥側のオブジェクトや、移動フィールド(地面)を構成するオブジェクトなどである。即ち例えばモデルオブジェクトに半透明処理が必要である場合に、モデルオブジェクトよりも奥側に書かれる可能性があるオブジェクトである。   A background object to be drawn before drawing a plurality of model objects is an object on the back side as viewed from the viewpoint of the model object, an object constituting a moving field (ground), or the like. That is, for example, when a semi-transparent process is required for a model object, the object may be written behind the model object.

また描画部120は、全ての複数のモデルオブジェクト(描画順序ランクが設定される全てのモデルオブジェクト)の描画完了後に、ワークバッファに生成されたZ値をZバッファ176にコピーする。そしてZバッファ176にコピーされたZ値に基づいて、モデルオブジェクトよりも視点から見て手前側に配置されるオブジェクト(例えば木等)の描画処理を行う。或いは、Zバッファに格納されたZ値を用いたフィルタ処理(被写界深度、グレア、フォグのフィルタ等)を行う。この場合のフィルタ処理は、描画部120が含むフィルタ処理部122により行われる。   The drawing unit 120 copies the Z value generated in the work buffer to the Z buffer 176 after drawing of all the plurality of model objects (all model objects for which the drawing order rank is set) is completed. Then, based on the Z value copied to the Z buffer 176, drawing processing of an object (for example, a tree) arranged on the near side as viewed from the viewpoint of the model object is performed. Alternatively, filter processing (depth of field, glare, fog filter, etc.) using the Z value stored in the Z buffer is performed. The filter processing in this case is performed by the filter processing unit 122 included in the drawing unit 120.

音生成部130は、処理部100で行われる種々の処理の結果に基づいて音処理を行い、BGM、効果音、又は音声などのゲーム音を生成し、音出力部192に出力する。   The sound generation unit 130 performs sound processing based on the results of various processes performed by the processing unit 100, generates game sounds such as BGM, sound effects, or sounds, and outputs the game sounds to the sound output unit 192.

なお、本実施形態の画像生成システムは、1人のプレイヤのみがプレイできるシングルプレイヤモード専用のシステムにしてもよいし、複数のプレイヤがプレイできるマルチプレイヤモードも備えるシステムにしてもよい。また複数のプレイヤがプレイする場合に、これらの複数のプレイヤに提供するゲーム画像やゲーム音を、1つの端末を用いて生成してもよいし、ネットワーク(伝送ライン、通信回線)などで接続された複数の端末(ゲーム機、携帯電話)を用いて分散処理により生成してもよい。   Note that the image generation system of the present embodiment may be a system dedicated to the single player mode in which only one player can play, or may be a system having a multiplayer mode in which a plurality of players can play. Further, when a plurality of players play, game images and game sounds to be provided to the plurality of players may be generated using one terminal, or connected via a network (transmission line, communication line) or the like. Alternatively, it may be generated by distributed processing using a plurality of terminals (game machine, mobile phone).

2.本実施形態の手法
次に本実施形態の手法について図面を用いて説明する。
2. Next, the method of this embodiment will be described with reference to the drawings.

2.1 モデルオブジェクト同士が重なり合う不具合
ロールプレイングゲームや格闘ゲームなどでは、従来の2次元ゲームの移動制御システムを踏襲するものがある。例えば図2(A)では、モデルオブジェクトOB1、OB2(狭義にはキャラクタ)は、基準ラインBL(移動ライン)上で移動する。具体的には第1のプレイヤの操作により、OB1は基準ラインBL上で左右に移動し、第2のプレイヤ又はコンピュータの操作により、OB2は基準ラインBL上で左右に移動する。そしてOB1、OB2が接近して、プレイヤが攻撃操作を行うと、OB1、OB2間での戦闘が行われる。なお基準ラインBLは例えばワールド座標系でのZWが一定となるライン(例えばZW=0)である。但し、基準ラインBLはZWが一定とならないラインであってもよいし、直線のみならず、曲線であってもよい。
2.1 Problems in which model objects overlap each other Some role-playing games and fighting games follow a conventional two-dimensional game movement control system. For example, in FIG. 2A, model objects OB1 and OB2 (characters in a narrow sense) move on a reference line BL (movement line). Specifically, OB1 moves to the left and right on the reference line BL by the operation of the first player, and OB2 moves to the left and right on the reference line BL by the operation of the second player or computer. And if OB1 and OB2 approach and a player performs attack operation, the battle between OB1 and OB2 will be performed. The reference line BL is a line (for example, ZW = 0) in which the ZW in the world coordinate system is constant, for example. However, the reference line BL may be a line in which ZW is not constant, or may be a curved line as well as a straight line.

通常の3次元ゲームでは、モデルオブジェクトOB1、OB2が移動フィールド(地面、マップ、ゲーム空間)上で自由な方向に移動できる移動制御システムを採用するのが一般的である。しかしながら、この移動制御システムでは、OB1、OB2の移動の自由度が高すぎて、プレイヤが操作に混乱するおそれがある。   In a normal three-dimensional game, it is common to employ a movement control system in which model objects OB1 and OB2 can move in a free direction on a movement field (ground, map, game space). However, in this movement control system, the degree of freedom of movement of OB1 and OB2 is too high, and the player may be confused by the operation.

この点、図2(A)のような移動制御システムによれば、モデルオブジェクトOB1、OB2の移動の自由度が、左右方向(XW軸上の方向)だけであるため、プレイヤの操作を簡素化できる。特に従来の2次元ゲームの移動制御システムに慣れているプレイヤにとっては、3次元ゲームであっても図2(A)のような移動制御システムを踏襲している方が望ましい。   In this regard, according to the movement control system as shown in FIG. 2A, since the degree of freedom of movement of the model objects OB1 and OB2 is only in the horizontal direction (direction on the XW axis), the operation of the player is simplified. it can. In particular, it is desirable for a player who is accustomed to a conventional two-dimensional game movement control system to follow the movement control system as shown in FIG. 2A even for a three-dimensional game.

ところが図2(A)の移動制御システムでは、モデルオブジェクトOB1、OB2が同一位置に配置(同一のXW、ZW座標)されたり、接近した場合に、図3に示すように、OB1、OB2のポリゴン同士が交差して重なり合ってしまう不具合が生じる。例えば通常の3次元ゲームの移動制御システムでは、各モデルオブジェクトOB1、OB2には、その形状が簡素化されたヒットボックスが設定されている。そして、これらのヒットボックス間のヒットチェック処理が行われ、OB1、OB2が同一位置に配置されることが許容されないため、図3のような不具合は生じない。   However, in the movement control system of FIG. 2A, when the model objects OB1 and OB2 are arranged at the same position (same XW and ZW coordinates) or approach each other, as shown in FIG. 3, the polygons of OB1 and OB2 There is a problem that the two cross each other and overlap each other. For example, in a normal three-dimensional game movement control system, each model object OB1, OB2 has a hit box with a simplified shape. Then, hit check processing between these hit boxes is performed, and OB1 and OB2 are not allowed to be arranged at the same position, so that the problem as shown in FIG. 3 does not occur.

しかしながら図2(A)の移動制御システムでは、モデルオブジェクトOB1、OB2が同一位置に配置されることが許容される場合もある。特に複数のモデルオブジェクト(キャラクタ)がパーティを組む場合には、これらの複数のモデルオブジェクトが同一位置に配置される場合が多いため、図3のような不具合が頻繁に生じる。   However, in the movement control system of FIG. 2A, it may be permitted that the model objects OB1 and OB2 are arranged at the same position. In particular, when a plurality of model objects (characters) form a party, the plurality of model objects are often arranged at the same position, so that a problem as shown in FIG. 3 frequently occurs.

この場合、図2(A)の移動制御システムにおいてこのような不具合を解消する1つの手法として、図2(B)のようにモデルオブジェクトOB1、OB2のZWをずらしてしまう手法も考えられる。例えば図2(B)ではモデルオブジェクトOB1のZWを負の方向にずらし、OB2のZWを正の方向にずらしている。   In this case, as one method for solving such a problem in the movement control system of FIG. 2A, a method of shifting the ZW of the model objects OB1 and OB2 as shown in FIG. For example, in FIG. 2B, the ZW of the model object OB1 is shifted in the negative direction, and the ZW of OB2 is shifted in the positive direction.

しかしながら図2(B)の手法では、モデルオブジェクトOB1とOB2のパースペクティブ(perspective)が異なったものになってしまう。即ち図2(B)に示すように仮想カメラVCの視点位置のZWが正となり且つ視線方向がZWの負の方向を向いている場合には、仮想カメラVC(視点)から見て、OB1が小さく見え、OB2が大きく見えてしまう。特に味方の複数のモデルオブジェクトがパーティを組んで同一位置に並んでいる場合には、図2(B)の手法ではこれらのモデルオブジェクトが異なった大きさに見えてしまい、見栄えが悪くなってしまう。   However, in the method of FIG. 2B, the perspectives of the model objects OB1 and OB2 are different. That is, as shown in FIG. 2B, when ZW at the viewpoint position of the virtual camera VC is positive and the line-of-sight direction is in the negative direction of ZW, OB1 is viewed from the virtual camera VC (viewpoint). It looks small and OB2 looks big. In particular, when a plurality of model objects on a team form a party and are lined up at the same position, the method of FIG. 2 (B) makes these model objects look different sizes and looks bad. .

2.2 ランク情報に基づく描画
そこで本実施形態では複数のモデルオブジェクトの描画順序のランクを設定(指定、判断)するためのランク情報RANKの概念を導入している。例えば図4では最も低いRANK=0(広義には第Kの描画順序ランク)にはモデルオブジェクトOB1が属しており、RANK=0よりも描画順序ランクが高いRANK=1(広義には第Lの描画順序ランク)にはOB2が属している。また次のRANK=2には複数のモデルオブジェクトOB3、OB4が属しており、RANK=3にはOB5、OB6、OB7が属し、RANK=4にはOB8、OB9が属している。
2.2 Drawing Based on Rank Information Accordingly, in this embodiment, the concept of rank information RANK for setting (designating and determining) the rank of the drawing order of a plurality of model objects is introduced. For example, in FIG. 4, the model object OB1 belongs to the lowest RANK = 0 (Kth drawing order rank in a broad sense), and RANK = 1 (Lth in a broad sense) has a higher drawing order rank than RANK = 0. OB2 belongs to (drawing order rank). A plurality of model objects OB3 and OB4 belong to the next RANK = 2, OB5, OB6, and OB7 belong to RANK = 3, and OB8 and OB9 belong to RANK = 4.

また図4においてリンク情報LINKは、各描画順序ランクに属しているモデルオブジェクトの少なくとも個数情報を設定(指定、判断)するための情報である。RANKは、モデルオブジェクトを登録することができるボックスのようなものに相当し、各RANK内には、LINKに相当する1又は複数のモデルオブジェクトを登録することができる。例えば図4では、RANK=0にはLINK=0であるOB1が登録されている。またRANK=1にはLINK=0であるOB2が登録されている。またRANK=2にはLINK=0であるOB3と、LINK=1であるOB4が登録されている。各RANKに設定されているLINKを参照することで、各RANKに属しているモデルオブジェクトの個数情報を知ることができる。なおランク情報やリンク情報の形態は図4に示すものに限定されず、種々の変形実施が可能である。   In FIG. 4, link information LINK is information for setting (designating or determining) at least the number information of model objects belonging to each drawing order rank. RANK corresponds to a box that can register model objects, and one or more model objects corresponding to LINK can be registered in each RANK. For example, in FIG. 4, RAN with LINK = 0 is registered in RANK = 0. In RANK = 1, OB2 with LINK = 0 is registered. In RANK = 2, OB3 with LINK = 0 and OB4 with LINK = 1 are registered. By referring to the LINK set in each RANK, it is possible to know the number information of the model objects belonging to each RANK. The form of rank information and link information is not limited to that shown in FIG. 4 and various modifications can be made.

本実施形態では、ランク情報RANKに応じた描画順序で、描画順序ランクの低いモデルオブジェクトから描画順序の高いモデルオブジェクトへと、モデルオブジェクトが描画される。例えば図4では、まずRANK=0のOB1が描画され、次にRANK=1のOB2が描画される。そしてRANK=2のOB3、OB4が描画され、次にRANK=3のOB5、OB6、OB7が描画される。次にRANK=4のOB8、OB9が描画される。なお同一ランク内における複数のモデルオブジェクトの描画順序は任意である。例えばRANK=3におけるOB5、OB6、OB7の描画順序は任意である。   In the present embodiment, model objects are drawn from a model object with a low drawing order rank to a model object with a high drawing order in a drawing order according to the rank information RANK. For example, in FIG. 4, OB1 with RANK = 0 is first drawn, and then OB2 with RANK = 1 is drawn. Then, OB3 and OB4 with RANK = 2 are drawn, and then OB5, OB6 and OB7 with RANK = 3 are drawn. Next, OB8 and OB9 of RANK = 4 are drawn. Note that the drawing order of a plurality of model objects within the same rank is arbitrary. For example, the drawing order of OB5, OB6, and OB7 when RANK = 3 is arbitrary.

そして本実施形態では、第Kの描画順序ランクのモデルオブジェクトを描画することで生成されたZバッファのZ値をクリアした後に、第Kの描画順序ランクよりもランクが高い第Lの描画順序ランクのモデルオブジェクトが描画される。例えば図5に示すように、RANK=0(第Kの描画順序ランク)のOB1を描画することで生成されたZバッファのZ値をクリアした後に、次のRANK=1(第Lの描画順序ランク)のOB2が描画される。例えば仮想カメラから見て遠いほどZ値(カメラ座標系)が小さくなるシステムでは、ZバッファのZ値をZ=0にすることで、Zバッファをクリアできる。一方、仮想カメラから見て遠いほどZ値が大きくなるシステムでは、ZバッファのZ値をZ=無限大に設定することで、Zバッファをクリアできる。   In this embodiment, after clearing the Z value of the Z buffer generated by drawing the model object of the Kth drawing order rank, the Lth drawing order rank that is higher than the Kth drawing order rank. The model object is drawn. For example, as shown in FIG. 5, after clearing the Z value of the Z buffer generated by drawing OB1 with RANK = 0 (Kth drawing order rank), the next RANK = 1 (Lth drawing order). OB2 of (rank) is drawn. For example, in a system in which the Z value (camera coordinate system) decreases as the distance from the virtual camera increases, the Z buffer can be cleared by setting the Z value of the Z buffer to Z = 0. On the other hand, in a system in which the Z value increases with increasing distance from the virtual camera, the Z buffer can be cleared by setting the Z value of the Z buffer to Z = infinity.

更に具体的には本実施形態では図6のA1に示すように、複数のモデルオブジェクトを描画する前に背景オブジェクト(遠景、移動フィールドのオブジェクト)を描画し、背景オブジェクトの描画により生成されたZバッファのZ値をワークバッファにコピー(退避)しておく。そしてA2に示すように、RANK=0(第Kの描画順序ランク)のOB1を描画することで生成されたZバッファのZ値を、ワークバッファに合成する。ここで、ワークバッファへのZ値の合成は、モデルオブジェクトの描画により更新されたZ値(Z値が更新された領域)だけを、ワークバッファ上において更新することで実現できる。   More specifically, in the present embodiment, as indicated by A1 in FIG. 6, a Z object generated by drawing a background object (distant view, moving field object) before drawing a plurality of model objects and drawing the background object. The Z value of the buffer is copied (saved) to the work buffer. Then, as shown at A2, the Z value of the Z buffer generated by drawing OB1 with RANK = 0 (Kth drawing order rank) is combined with the work buffer. Here, the synthesis of the Z value in the work buffer can be realized by updating only the Z value updated by drawing the model object (the area in which the Z value has been updated) on the work buffer.

次にA3に示すように、ワークバッファへの合成後にZバッファのZ値をクリアする。そしてA4に示すように、ZバッファのZ値のクリア後に次のRANK=1(第Lの描画順序ランク)のOB2を描画し、この描画により生成されたZバッファのZ値をワークバッファに合成する。そして合成後にZバッファのZ値をクリアし、次のRANK=2のOB3、OB4を描画する。   Next, as indicated by A3, the Z value of the Z buffer is cleared after the composition to the work buffer. Then, as shown in A4, after clearing the Z value of the Z buffer, OB2 of the next RANK = 1 (Lth drawing order rank) is drawn, and the Z value of the Z buffer generated by this drawing is combined with the work buffer. To do. Then, after the composition, the Z value of the Z buffer is cleared, and the next RANK = 2 OB3 and OB4 are drawn.

そして、RANKが設定された全てのモデルオブジェクトOB1〜OB9の描画完了後に、ワークバッファに生成されたZ値をZバッファにコピーして書き戻す。そしてZバッファにコピーされたZ値に基づいて、複数のモデルオブジェクトよりも視点から見て手前側に配置されるオブジェクトの描画処理を行う。或いはZ値を用いたフィルタ処理を行う。   Then, after drawing of all the model objects OB1 to OB9 for which RANK is set, the Z value generated in the work buffer is copied and written back to the Z buffer. Then, based on the Z value copied to the Z buffer, a drawing process is performed for an object arranged on the near side as viewed from the viewpoint of the plurality of model objects. Alternatively, filter processing using the Z value is performed.

この場合のフィルタ処理としては、Z値(Zプレーン)をα値(αプレーン)に変換し、この変換により得られたα値に基づくフィルタ処理などが考えられる。例えば、変換により得られたα値に基づいて、元画像(透視変換後のオブジェクトを描画することで得られる画像)と、そのぼかし画像をαブレンディングすることで、被写界深度のフィルタ処理を実現できる。また、変換により得られたα値に基づいて、元画像とフォグ色(所与の色)を合成することで、フォグのフィルタ処理を実現できる。なおZ値を色情報に変換し、この変換により得られた色情報に基づくフィルタ処理を行ってもよい。またZ値をα値や色情報に変換する処理は、Z値をカラールックアップテーブルCLUTのインデックス番号に設定し、CLUTを用いたインデクッスカラー・テクスチャマッピングを行うことで実現できる。   As a filter process in this case, a Z value (Z plane) is converted into an α value (α plane), and a filter process based on the α value obtained by this conversion can be considered. For example, based on the α value obtained by the conversion, the original image (the image obtained by drawing the object after the perspective conversion) and the blurred image are α-blended, so that the depth-of-field filtering process is performed. realizable. Also, fog filtering processing can be realized by combining the original image and the fog color (given color) based on the α value obtained by the conversion. Note that the Z value may be converted into color information, and filter processing based on the color information obtained by this conversion may be performed. The process of converting the Z value into the α value or the color information can be realized by setting the Z value to the index number of the color lookup table CLUT and performing index color / texture mapping using the CLUT.

図7に本実施形態の手法により生成された画像の例を示す。図7に示すように本実施形態の手法によれば、モデルオブジェクトOB1、OB2が同一位置(ほぼ同一位置)に配置されていたとしても、これらが適正に隠面消去されて表示されるようになり、図3の不具合を解消できる。   FIG. 7 shows an example of an image generated by the method of this embodiment. As shown in FIG. 7, according to the method of the present embodiment, even if the model objects OB1 and OB2 are arranged at the same position (substantially the same position), they are properly erased and displayed. Thus, the problem of FIG. 3 can be solved.

即ち図7では、OB1はRANK=0に属し、OB2はRANK=1に属しており、OB2の方が描画順序ランクが高く設定されている。従って、OB1が描画された後に、Zバッファがクリアされて、その後にOB2が描画されるようになる。このため、たとえOB1、OB2が同一位置(同一のXW、ZW座標)に配置されていたとしても、常にOB2の方が手前側に表示されるようになり、OB1とOB2が重なり合って見える不具合を解消できる。従って図2(A)のような移動制御システムにおいても、不具合の無い画像を生成できる。特にOB1、OB2が味方同士でパーティを組む場合には、図7においてOB1、OB2が同一方向を向き、同一位置(ほぼ同一位置)に配置される場合が多いが、このような場合にも本実施形態の手法によれば不具合の発生を効果的に防止できる。   That is, in FIG. 7, OB1 belongs to RANK = 0, OB2 belongs to RANK = 1, and OB2 has a higher drawing order rank. Therefore, after OB1 is drawn, the Z buffer is cleared and OB2 is drawn after that. For this reason, even if OB1 and OB2 are arranged at the same position (same XW and ZW coordinates), OB2 is always displayed on the near side, and OB1 and OB2 appear to overlap each other. Can be resolved. Therefore, even in the movement control system as shown in FIG. In particular, when OB1 and OB2 form a party with each other, in many cases, OB1 and OB2 face the same direction and are arranged at the same position (substantially the same position) in FIG. According to the method of the embodiment, the occurrence of defects can be effectively prevented.

また図2(B)のようにOB1、OB2のZWずらして配置する手法では、図2(B)のように仮想カメラVCが配置されている場合に、OB1、OB2のパースペクティブが異なってしまい、OB1が小さく見え、OB2が大きく見えてしまうという問題点がある。   2B, the perspectives of OB1 and OB2 are different when the virtual camera VC is arranged as shown in FIG. 2B. There is a problem that OB1 appears small and OB2 appears large.

これに対して本実施形態の手法によれば、OB1、OB2のZWをずらさなくても済む。従って図7に示すように、OB1、OB2が同一位置(ほぼ同一位置)に配置されていたとしても、これらのOB1、OB2のパースペクティブは同じになる。従って、OB1が小さく見え、OB2が大きく見えてしまうという不具合の発生も防止できる。なお本実施形態でのモデルオブジェクトの移動制御手法は図2(A)の手法に限定されない。例えばZWが一定にならない基準ライン上でモデルオブジェクトを移動させる制御を行ったり、基準ラインに制限されることなくモデルオブジェクトを移動させる制御を行うようにしてもよい。   On the other hand, according to the method of the present embodiment, it is not necessary to shift the ZW of OB1 and OB2. Accordingly, as shown in FIG. 7, even if OB1 and OB2 are arranged at the same position (substantially the same position), the perspectives of these OB1 and OB2 are the same. Therefore, it is possible to prevent a problem that OB1 looks small and OB2 appears large. Note that the model object movement control method in the present embodiment is not limited to the method shown in FIG. For example, control for moving the model object on a reference line where ZW is not constant may be performed, or control for moving the model object without being limited to the reference line may be performed.

また本実施形態ではランク情報RANKに基づいて、モデルオブジェクトの描画順序ランクが制御される。従って例えば図8に示すように、図7とは逆にOB1の方を手前側に表示し、OB2の方を奥側に表示することも容易に制御できる。即ち図4ではOB1はRANK=0に設定され、OB2はRANK=1に設定されているため、図7のような画像が表示されている。これに対して、OB2をRANK=0に設定し、OB1をRANK=1に設定すれば、図8のような画像が表示されるようになる。   In the present embodiment, the drawing order rank of the model object is controlled based on the rank information RANK. Therefore, for example, as shown in FIG. 8, it is possible to easily control the display of OB1 on the front side and the display of OB2 on the back side, contrary to FIG. That is, in FIG. 4, since OB1 is set to RANK = 0 and OB2 is set to RANK = 1, an image as shown in FIG. 7 is displayed. On the other hand, if OB2 is set to RANK = 0 and OB1 is set to RANK = 1, an image as shown in FIG. 8 is displayed.

例えば複数のモデルオブジェクトがパーティを組んで敵と対戦する場合には、特殊技などの効果的な技を繰り出すモデルオブジェクトを目立たせて表示することが望ましい。本実施形態ではランク情報RANKという概念を導入しているため、このような表示制御も容易に行うことができる。例えばOB2が特殊技を繰り出す場合には、OB2のRANKを高い値に設定すれば、図7に示すようにOB2が手前側に表示されるようになる。これにより、OB2の繰り出す特殊技をプレイヤに効果的に見せることが可能になる。一方、OB1が特殊技を繰り出す場合には、OB1のRANKを高い値に設定すれば、図8に示すようにOB1が手前側に表示されるようになる。これにより、OB1の繰り出す特殊技をプレイヤに効果的に見せることが可能になる。   For example, when a plurality of model objects form a party and fight against an enemy, it is desirable to make the model objects that perform effective techniques such as special techniques stand out. In this embodiment, since the concept of rank information RANK is introduced, such display control can be easily performed. For example, when OB2 takes out a special technique, if RAN of OB2 is set to a high value, OB2 is displayed on the near side as shown in FIG. This makes it possible to effectively show the player the special technique that OB2 delivers. On the other hand, when OB1 takes out a special technique, if RAN of OB1 is set to a high value, OB1 is displayed on the near side as shown in FIG. This makes it possible to effectively show the player the special technique that OB1 delivers.

また本実施形態の手法によれば、図9に示すように、2つのみならず3つ以上のモデルオブジェクトを同一位置に配置した場合にも、不具合の無い画像を生成できる。例えば図9では、OB1がRANK=0、OB2がRANK=1、OB3がRANK=2に設定される。従って、OB1が最も奥側に表示され、OB3が最も手前側に表示され、OB2がその間に表示されるようになる。このように、3つ以上のモデルオブジェクトを配置する場合に、図2(B)のような手法を採用すると、これらのモデルオブジェクトの大きさの違いが更に目立ってしまう事態が生じるが、本実施形態によればこのような事態を防止できる。   Further, according to the method of the present embodiment, as shown in FIG. 9, even when not only two but also three or more model objects are arranged at the same position, an image having no defect can be generated. For example, in FIG. 9, OB1 is set to RANK = 0, OB2 is set to RANK = 1, and OB3 is set to RANK = 2. Therefore, OB1 is displayed on the farthest side, OB3 is displayed on the foremost side, and OB2 is displayed in the meantime. As described above, when three or more model objects are arranged, if the method as shown in FIG. 2B is adopted, a situation in which the difference in size of these model objects becomes more noticeable occurs. According to the embodiment, such a situation can be prevented.

また本実施形態によれば図6で説明したように、背景の描画により生成されたZ値をワークバッファに退避しておき、各モデルオブジェクトを生成することで得られるZ値をこのワークバッファに合成し、最終的にワークバッファに生成されたZ値をZバッファにコピーして戻す手法を採用している。従って、このコピー後の最終的なZバッファのZ値を用いることで、モデルオブジェクトの描画後に描画されるオブジェクトの適正な隠面消去処理が可能になる。また、コピー後のZバッファのZ値を用いて、適正なフィルタ処理を行うことも可能になる。   Further, according to the present embodiment, as described with reference to FIG. 6, the Z value generated by drawing the background is saved in the work buffer, and the Z value obtained by generating each model object is stored in this work buffer. A method is employed in which the Z values synthesized and finally generated in the work buffer are copied back to the Z buffer. Therefore, by using the Z value of the final Z buffer after copying, it is possible to perform an appropriate hidden surface erasing process on the object drawn after the model object is drawn. It is also possible to perform appropriate filter processing using the Z value of the Z buffer after copying.

即ち本実施形態では、モデルオブジェクトを描画する毎にZバッファをクリアしている。従って、ZバッファのZ値をワークバッファにコピーして退避する手法を採用しないと、モデルオブジェクトの描画後に描画されるオブジェクトの適正な隠面消去処理や、ZバッファのZ値を用いた適正なフィルタ処理を実現できない事態が生じるおそれがあるが、図6の手法を採用すればこのような事態を防止できる。   That is, in this embodiment, the Z buffer is cleared every time a model object is drawn. Therefore, if the method of copying and saving the Z value of the Z buffer to the work buffer is not adopted, an appropriate hidden surface removal process of the object drawn after the drawing of the model object, or an appropriate value using the Z value of the Z buffer is used. Although there is a possibility that a situation where the filter processing cannot be realized may occur, such a situation can be prevented if the method of FIG. 6 is adopted.

また本実施形態によれば、同一のRANK(第Kの描画順序ランク)に複数のモデルオブジェクトを所属(登録)させることができるため、図10のような画像を生成することも可能になる。即ち図4、図10では、モデルオブジェクトOB3、OB4が同一のRANK=2に属している。この場合には、Zバッファを参照しながらこれらのOB3、OB4を描画し、その後にZバッファのZ値をクリアする。そしてZバッファのクリア後に、次のRANK=3のOB5、OB6、OB7を描画するようにする。   Further, according to the present embodiment, since a plurality of model objects can belong (register) to the same RANK (Kth drawing order rank), an image as shown in FIG. 10 can be generated. That is, in FIGS. 4 and 10, the model objects OB3 and OB4 belong to the same RANK = 2. In this case, these OB3 and OB4 are drawn with reference to the Z buffer, and then the Z value of the Z buffer is cleared. After the Z buffer is cleared, the next RAN = 3 OB5, OB6, and OB7 are drawn.

このように同一のRANKへの複数のモデルオブジェクトの所属を許容すれば、更に多彩な画像表現が可能になる。例えばモデルオブジェクト(キャラクタ)同士が戦闘する場面においては、図7のようにOB2がOB1の常に手前に見えるような画像を生成するよりも、これらが重なって表示される画像を生成する方が望ましい場合がある。   In this way, by allowing a plurality of model objects to belong to the same RANK, more various image representations are possible. For example, in a scene where model objects (characters) battle each other, it is preferable to generate an image in which these objects are displayed in an overlapping manner, rather than generating an image in which OB2 is always visible in front of OB1, as shown in FIG. There is a case.

このような場合でも、本実施形態によれば、OB3、OB4を同一のRANKに登録することで、図10のようにOB3、OB4が重なって表示される画像を生成できるようになる。この図10の表示によれば、OB3とOB4があたかも腕等を組んで戦っているかのように見える画像を生成できる。また例えばOB3、OB4が武器を所持しているような場合に、これらの武器間の隠面消去が適正に行われるようになる。従って、自然でリアルな画像を生成できると共に生成される画像のバラエティ度を増すことができる。   Even in such a case, according to the present embodiment, by registering OB3 and OB4 in the same RANK, it is possible to generate an image in which OB3 and OB4 are overlapped as shown in FIG. According to the display of FIG. 10, it is possible to generate an image that looks as if OB3 and OB4 are fighting with arms crossed. Further, for example, when OB3 and OB4 have weapons, hidden surface elimination between these weapons is appropriately performed. Therefore, a natural and realistic image can be generated and the variety of the generated image can be increased.

なお、同一のRANKに複数のモデルオブジェクトが属している場合には、図4に示すようなリンク情報LINKに基づいて、これらの複数のモデルオブジェクトを描画すればよい。即ちLINKに基づいて、当該RANKにおいて描画する必要があるモデルオブジェクトの個数を判断する。そしてその個数のモデルオブジェクトの描画が完了した後に、ZバッファのZ値をクリアし、次のRANKのモデルオブジェクトを描画すればよい。また図10に示すような画像を生成する場合等においては、図2(B)のようにモデルオブジェクトのZ値を少しだけずらす手法を採用することも可能である。   When a plurality of model objects belong to the same RANK, the plurality of model objects may be drawn based on the link information LINK as shown in FIG. That is, the number of model objects that need to be drawn in the RANK is determined based on the LINK. Then, after the drawing of the number of model objects is completed, the Z value of the Z buffer is cleared, and the next RANK model object is drawn. Further, when generating an image as shown in FIG. 10, it is possible to employ a method of slightly shifting the Z value of the model object as shown in FIG.

2.3 詳細な処理例
次に本実施形態の詳細な処理例を図11のフローチャートを用いて説明する。
2.3 Detailed Processing Example Next, a detailed processing example of this embodiment will be described with reference to the flowchart of FIG.

まず背景オブジェクト(キャラクタよりも奥側のオブジェクト)を描画する(ステップS1)。この背景オブジェクトとしては、空や山などの遠景オブジェクトや、地面等の移動フィールドオブジェクト(マップオブジェクト)などがある。そして図6のA1で説明したようにZバッファのZ値をワークバッファにコピーして退避する(ステップS2)。   First, a background object (an object behind the character) is drawn (step S1). Examples of the background object include a distant view object such as a sky and a mountain, and a moving field object (map object) such as the ground. Then, as described in A1 of FIG. 6, the Z value of the Z buffer is copied to the work buffer and saved (step S2).

次にRANK=0に設定し(ステップS3)、ZバッファのZ値をクリアする(ステップS4)。またLINK=0に設定する(ステップS5)。   Next, RANK = 0 is set (step S3), and the Z value of the Z buffer is cleared (step S4). Further, LINK = 0 is set (step S5).

次に、現在のLINKのキャラクタ(モデルオブジェクト)を描画する(ステップS6)。例えば図4のようにLINKが設定されている場合には、RANK=0のOB1が描画される。そして描画後に、LINKをLINK+1にインクリメントする(ステップS7)。   Next, the current LINK character (model object) is drawn (step S6). For example, when LINK is set as shown in FIG. 4, OB1 with RANK = 0 is drawn. Then, after drawing, LINK is incremented to LINK + 1 (step S7).

次にRANK内の全てのキャラクタの描画が完了したか否かを判断し(ステップS8)、完了していない場合にはステップS6の処理に戻り、キャラクタの個数分だけステップS6〜S8の処理を繰り返す。例えば図4においてRANK=2の場合にはステップS6〜S8の処理が2回繰り返され、RANK=3の場合には3回繰り返される。   Next, it is determined whether or not drawing of all characters in the rank has been completed (step S8). If not completed, the process returns to step S6, and the processes of steps S6 to S8 are performed for the number of characters. repeat. For example, in FIG. 4, when RANK = 2, the processes of steps S6 to S8 are repeated twice, and when RANK = 3, the processes are repeated three times.

RANK内の全てのキャラクタの描画が完了すると、図6のA2、A4で説明したように、現在のZバッファの内容とワークバッファの内容を合成する(ステップS9)。そしてRANKをRANK+1にインクリメントする(ステップS10)。   When drawing of all characters in RANK is completed, the contents of the current Z buffer and the contents of the work buffer are synthesized as described in A2 and A4 of FIG. 6 (step S9). Then, RANK is incremented to RANK + 1 (step S10).

次に全てのRANKについての描画が完了したか否かを判断し(ステップS11)、完了していない場合にはステップS4の処理に戻る。そして全てのRANKについての描画が完了するまで、ステップS4〜S11の処理を繰り返す。   Next, it is determined whether or not drawing for all ranks has been completed (step S11). If not completed, the process returns to step S4. Then, the processes in steps S4 to S11 are repeated until drawing for all ranks is completed.

全てのRANKについての描画が完了すると、図6のA5で説明したように、ワークバッファのZ値をZバッファにコピー(上書き)する(ステップS12)。そして、キャラクタよりも手前側のオブジェクトである背景オブジェクトを描画する(ステップS13)。そして、必要であれば、ZバッファのZ値を用いたフィルタ処理を行う(ステップS14)。   When drawing for all ranks is completed, the Z value of the work buffer is copied (overwritten) to the Z buffer as described in A5 of FIG. 6 (step S12). Then, a background object that is an object on the near side of the character is drawn (step S13). Then, if necessary, filter processing using the Z value of the Z buffer is performed (step S14).

3.ハードウェア構成
図13に本実施形態を実現できるハードウェア構成の例を示す。メインプロセッサ900は、CD982(情報記憶媒体)に格納されたプログラム、通信インターフェース990を介してダウンロードされたプログラム、或いはROM950に格納されたプログラムなどに基づき動作し、ゲーム処理、画像処理、音処理などを実行する。コプロセッサ902は、メインプロセッサ900の処理を補助するものであり、マトリクス演算(ベクトル演算)を高速に実行する。例えばオブジェクトを移動させたり動作(モーション)させる物理シミュレーションに、マトリクス演算処理が必要な場合には、メインプロセッサ900上で動作するプログラムが、その処理をコプロセッサ902に指示(依頼)する。
3. Hardware Configuration FIG. 13 shows an example of a hardware configuration that can realize this embodiment. The main processor 900 operates based on a program stored in a CD 982 (information storage medium), a program downloaded via the communication interface 990, a program stored in the ROM 950, or the like, and includes game processing, image processing, sound processing, and the like. Execute. The coprocessor 902 assists the processing of the main processor 900, and executes matrix operation (vector operation) at high speed. For example, when a matrix calculation process is required for a physical simulation for moving or moving an object, a program operating on the main processor 900 instructs (requests) the process to the coprocessor 902.

ジオメトリプロセッサ904は、メインプロセッサ900上で動作するプログラムからの指示に基づいて、座標変換、透視変換、光源計算、曲面生成などのジオメトリ処理を行うものであり、マトリクス演算を高速に実行する。データ伸張プロセッサ906は、圧縮された画像データや音データのデコード処理を行ったり、メインプロセッサ900のデコード処理をアクセラレートする。これにより、オープニング画面やゲーム画面において、MPEG方式等で圧縮された動画像を表示できる。   The geometry processor 904 performs geometry processing such as coordinate conversion, perspective conversion, light source calculation, and curved surface generation based on an instruction from a program operating on the main processor 900, and executes matrix calculation at high speed. The data decompression processor 906 performs decoding processing of the compressed image data and sound data and accelerates the decoding processing of the main processor 900. Thereby, a moving image compressed by the MPEG method or the like can be displayed on the opening screen or the game screen.

描画プロセッサ910は、ポリゴンや曲面などのプリミティブ面で構成されるオブジェクトの描画(レンダリング)処理を実行する。オブジェクトの描画の際には、メインプロセッサ900は、DMAコントローラ970を利用して、描画データを描画プロセッサ910に渡すと共に、必要であればテクスチャ記憶部924にテクスチャを転送する。すると描画プロセッサ910は、描画データやテクスチャに基づいて、Zバッファなどを利用した隠面消去を行いながら、オブジェクトをフレームバッファ922に描画する。また描画プロセッサ910は、αブレンディング(半透明処理)、デプスキューイング、ミップマッピング、フォグ処理、バイリニア・フィルタリング、トライリニア・フィルタリング、アンチエイリアシング、シェーディング処理なども行う。1フレーム分の画像がフレームバッファ922に書き込まれるとその画像はディスプレイ912に表示される。   The drawing processor 910 executes drawing (rendering) processing of an object composed of primitive surfaces such as polygons and curved surfaces. When drawing an object, the main processor 900 uses the DMA controller 970 to pass the drawing data to the drawing processor 910 and, if necessary, transfers the texture to the texture storage unit 924. Then, the drawing processor 910 draws the object in the frame buffer 922 while performing hidden surface removal using a Z buffer or the like based on the drawing data and texture. The drawing processor 910 also performs α blending (translucent processing), depth cueing, mip mapping, fog processing, bilinear filtering, trilinear filtering, anti-aliasing, shading processing, and the like. When an image for one frame is written in the frame buffer 922, the image is displayed on the display 912.

サウンドプロセッサ930は、多チャンネルのADPCM音源などを内蔵し、BGM、効果音、音声などのゲーム音を生成し、スピーカ932を介して出力する。ゲームコントローラ942やメモリカード944からのデータはシリアルインターフェース940を介して入力される。   The sound processor 930 includes a multi-channel ADPCM sound source and the like, generates game sounds such as BGM, sound effects, and sounds, and outputs them through the speaker 932. Data from the game controller 942 and the memory card 944 is input via the serial interface 940.

ROM950にはシステムプログラムなどが格納されている。業務用ゲームシステムの場合にはROM950が情報記憶媒体として機能し、ROM950に各種プログラムが格納されている。なおROM950の代わりにハードディスクを利用してもよい。RAM960は各種プロセッサの作業領域となる。DMAコントローラ970は、プロセッサ、メモリ間でのDMA転送を制御する。CDドライブ980は、プログラム、画像データ、或いは音データなどが格納されているCD982にアクセスする。通信インターフェース990はネットワーク(通信回線、高速シリアルバス)を介して外部との間でデータ転送を行う。   The ROM 950 stores system programs and the like. In the case of an arcade game system, the ROM 950 functions as an information storage medium, and various programs are stored in the ROM 950. A hard disk may be used instead of the ROM 950. The RAM 960 is a work area for various processors. The DMA controller 970 controls DMA transfer between the processor and the memory. The CD drive 980 accesses a CD 982 in which programs, image data, sound data, and the like are stored. The communication interface 990 performs data transfer with the outside via a network (communication line, high-speed serial bus).

なお本実施形態の各部(各手段)の処理は、その全てをハードウェアのみにより実現してもよいし、情報記憶媒体に格納されているプログラムや通信インターフェースを介して配信されるプログラムにより実現してもよい。或いは、ハードウェアとプログラムの両方により実現してもよい。   Note that the processing of each unit (each unit) in the present embodiment may be realized entirely by hardware, or may be realized by a program stored in an information storage medium or a program distributed via a communication interface. May be. Alternatively, it may be realized by both hardware and a program.

そして本実施形態の各部の処理をハードウェアとプログラムの両方により実現する場合には、情報記憶媒体には、ハードウェア(コンピュータ)を本実施形態の各部として機能させるためのプログラムが格納されている。より具体的には、上記プログラムが、ハードウェアである各プロセッサ902、904、906、910、930に処理を指示すると共に、必要であればデータを渡す。そして、各プロセッサ902、904、906、910、930は、その指示と渡されたデータとに基づいて本発明の各部の処理を実現する。   When the processing of each unit of the present embodiment is realized by both hardware and a program, a program for causing the hardware (computer) to function as each unit of the present embodiment is stored in the information storage medium. . More specifically, the program instructs the processors 902, 904, 906, 910, and 930, which are hardware, and passes data if necessary. Each processor 902, 904, 906, 910, 930 realizes the processing of each unit of the present invention based on the instruction and the passed data.

なお、上記のように本実施形態について詳細に説明したが、本発明の新規事項および効果から実体的に逸脱しない多くの変形が可能であることは当業者には容易に理解できるであろう。従って、このような変形例はすべて本発明の範囲に含まれるものとする。例えば、明細書又は図面において、少なくとも一度、より広義または同義な異なる用語(描画バッファ、モデルオブジェクト等)と共に記載された用語(フレームバッファ・ワークバッファ、キャラクタ等)は、明細書又は図面のいかなる箇所においても、その異なる用語に置き換えることができる。   Although the present embodiment has been described in detail as described above, it will be easily understood by those skilled in the art that many modifications can be made without departing from the novel matters and effects of the present invention. Accordingly, all such modifications are intended to be included in the scope of the present invention. For example, a term (frame buffer, work buffer, character, etc.) written together with a different term (drawing buffer, model object, etc.) more broadly or synonymously at least once in the specification or drawing is used anywhere in the specification or drawing. Can also be replaced by the different terms.

また、ランク情報、リンク情報の形態や、モデルオブジェクトの描画手法や、モデルオブジェクトへのランクの設定手法や、Zバッファの更新・クリア手法なども、本実施形態で説明したものに限定されず、これらと均等な手法も本発明の範囲に含まれる。例えば図6のA1、A2、A4、A5の処理を行わない手法を採用することも可能である。   Also, the form of rank information, link information, drawing method of model object, setting method of rank to model object, update / clearing method of Z buffer, etc. are not limited to those described in this embodiment, Techniques equivalent to these are also included in the scope of the present invention. For example, it is possible to adopt a method that does not perform the processing of A1, A2, A4, and A5 in FIG.

また本発明は種々のゲームに適用できる。また本発明は、業務用ゲームシステム、家庭用ゲームシステム、多数のプレイヤが参加する大型アトラクションシステム、シミュレータ、マルチメディア端末、ゲーム画像を生成するシステムボード、携帯電話等の種々の画像生成システムに適用できる。   The present invention can be applied to various games. Further, the present invention is applied to various image generation systems such as a business game system, a home game system, a large attraction system in which a large number of players participate, a simulator, a multimedia terminal, a system board for generating game images, and a mobile phone. it can.

本実施形態の画像生成システムの機能ブロック図の例。The example of a functional block diagram of the image generation system of this embodiment. 図2(A)(B)は移動制御手法やその不具合を解消する手法の説明図。2A and 2B are explanatory diagrams of a movement control method and a method for solving the problem. 従来の手法での不具合画像の例。The example of the malfunction image by the conventional method. 本実施形態のランク情報、リンク情報の説明図。Explanatory drawing of the rank information of this embodiment, and link information. 本実施形態の手法の説明図。Explanatory drawing of the method of this embodiment. 本実施形態の手法の詳細例の説明図。Explanatory drawing of the detailed example of the method of this embodiment. 本実施形態により生成された画像の例。The example of the image produced | generated by this embodiment. 本実施形態により生成された画像の例。The example of the image produced | generated by this embodiment. 本実施形態により生成された画像の例。The example of the image produced | generated by this embodiment. 本実施形態により生成された画像の例。The example of the image produced | generated by this embodiment. 本実施形態の処理の詳細例。The detailed example of the process of this embodiment. 本実施形態の処理の詳細例。The detailed example of the process of this embodiment. ハードウェア構成例。Hardware configuration example.

符号の説明Explanation of symbols

OB1〜OB9 モデルオブジェクト
100 処理部、110 オブジェクト空間設定部、112 移動・動作処理部、
114 仮想カメラ制御部、120 描画部、122 フィルタ処理部、
130 音生成部、160 操作部、170 記憶部、172 描画バッファ、
174 テクスチャ記憶部、176 Zバッファ、177 ランク情報記憶部、
178 リンク情報記憶部、180 情報記憶媒体、190 表示部、
192 音出力部、194 携帯型情報記憶装置、196 通信部
OB1 to OB9 model object 100 processing unit, 110 object space setting unit, 112 movement / motion processing unit,
114 virtual camera control unit, 120 drawing unit, 122 filter processing unit,
130 sound generation unit, 160 operation unit, 170 storage unit, 172 drawing buffer,
174 texture storage unit, 176 Z buffer, 177 rank information storage unit,
178 Link information storage unit, 180 information storage medium, 190 display unit,
192 sound output unit, 194 portable information storage device, 196 communication unit

Claims (8)

画像を生成するためのプログラムであって、
複数のモデルオブジェクトの描画順序のランクを設定するためのランク情報を記憶するランク情報記憶部と、
各画素のZ値を記憶するZバッファと、
前記ランク情報に従った描画順序で、描画順序ランクの低いモデルオブジェクトから描画順序ランクの高いモデルオブジェクトへと、前記ZバッファのZ値を参照しながら前記複数のモデルオブジェクトを順次描画する描画部として、
コンピュータを機能させ、
前記描画部は、
第Kの描画順序ランクのモデルオブジェクトを描画することで生成された前記ZバッファのZ値をクリアした後に、前記第Kの描画順序ランクよりもランクが高い第Lの描画順序ランク(K、Lは、1≦K<N、1<L≦N、K<Lとなる任意の整数)のモデルオブジェクトを描画することを特徴とするプログラム。
A program for generating an image,
A rank information storage unit that stores rank information for setting the rank of the drawing order of a plurality of model objects;
A Z buffer for storing the Z value of each pixel;
As a drawing unit that sequentially draws the plurality of model objects from a model object having a low drawing order rank to a model object having a high drawing order rank in the drawing order according to the rank information, with reference to the Z value of the Z buffer. ,
Make the computer work,
The drawing unit
After clearing the Z value of the Z buffer generated by drawing the model object of the Kth drawing order rank, the Lth drawing order rank (K, L) having a higher rank than the Kth drawing order rank Is a program that draws a model object of 1 ≦ K <N, 1 <L ≦ N, and K <L.
請求項1において、
前記描画部は、
前記複数のモデルオブジェクトを描画する前に背景オブジェクトを描画し、前記背景オブジェクトの描画により生成された前記ZバッファのZ値をワークバッファにコピーしておき、
前記第Kの描画順序ランクのモデルオブジェクトを描画することで生成された前記ZバッファのZ値を、前記ワークバッファに合成し、合成後に前記ZバッファのZ値をクリアすることを特徴とするプログラム。
In claim 1,
The drawing unit
Draw a background object before drawing the plurality of model objects, copy the Z value of the Z buffer generated by drawing the background object to a work buffer,
A program characterized in that the Z value of the Z buffer generated by drawing the model object of the Kth drawing order rank is combined with the work buffer, and the Z value of the Z buffer is cleared after the combining. .
請求項2において、
前記描画部は、
全ての前記複数のモデルオブジェクトの描画完了後に、前記ワークバッファに生成されたZ値を前記Zバッファにコピーし、
前記ZバッファにコピーされたZ値に基づいて、前記複数のモデルオブジェクトよりも視点から見て手前側に配置されるオブジェクトの描画処理、及びZ値を用いたフィルタ処理の少なくとも一方を行うことを特徴とするプログラム。
In claim 2,
The drawing unit
After the drawing of all the plurality of model objects is completed, the Z value generated in the work buffer is copied to the Z buffer,
Based on the Z value copied to the Z buffer, at least one of drawing processing of an object arranged closer to the viewpoint than the plurality of model objects and filtering processing using the Z value is performed. A featured program.
請求項1乃至3のいずれかにおいて、
前記描画部は、
前記第Kの描画順序ランクに複数のモデルオブジェクトが属している場合に、前記ZバッファのZ値を参照しながら前記第Kの描画順序ランクに属している複数のモデルオブジェクトを描画し、描画後に前記ZバッファのZ値をクリアし、クリア後に前記第Lの描画順序ランクのモデルオブジェクトを描画することを特徴とするプログラム。
In any one of Claims 1 thru | or 3,
The drawing unit
When a plurality of model objects belong to the Kth drawing order rank, a plurality of model objects belonging to the Kth drawing order rank are drawn with reference to the Z value of the Z buffer, and after drawing A program that clears the Z value of the Z buffer and draws the model object of the Lth drawing order rank after clearing.
請求項4において、
各描画順序ランクに属しているモデルオブジェクトの少なくとも個数情報を設定するためのリンク情報を記憶するリンク情報記憶部として、
コンピュータを機能させ、
前記描画部は、
前記リンク情報に基づいて、前記第Kの描画順序ランクに属している複数のモデルオブジェクトを描画することを特徴とするプログラム。
In claim 4,
As a link information storage unit for storing link information for setting at least the number information of model objects belonging to each drawing order rank,
Make the computer work,
The drawing unit
A program for drawing a plurality of model objects belonging to the Kth drawing order rank based on the link information.
請求項1乃至5のいずれかにおいて、
操作部からの操作情報に基づいて、複数のモデルオブジェクトを移動フィールド上の基準ライン上で移動・動作させる制御を行う移動・動作処理部として、
コンピュータを機能させることを特徴とするプログラム。
In any one of Claims 1 thru | or 5,
Based on operation information from the operation unit, as a movement / motion processing unit that performs control to move / operate multiple model objects on the reference line on the movement field,
A program characterized by causing a computer to function.
コンピュータ読み取り可能な情報記憶媒体であって、請求項1乃至6のいずれかのプログラムを記憶したことを特徴とする情報記憶媒体。   A computer-readable information storage medium, wherein the program according to any one of claims 1 to 6 is stored. 画像を生成する画像生成システムであって、
複数のモデルオブジェクトの描画順序のランクを設定するためのランク情報を記憶するランク情報記憶部と、
各画素のZ値を記憶するZバッファと、
前記ランク情報に従った描画順序で、描画順序ランクの低いモデルオブジェクトから描画順序ランクの高いモデルオブジェクトへと、前記ZバッファのZ値を参照しながら前記複数のモデルオブジェクトを順次描画する描画部とを含み、
前記描画部は、
第Kの描画順序ランクのモデルオブジェクトを描画することで生成された前記ZバッファのZ値をクリアした後に、前記第Kの描画順序ランクよりもランクが高い第Lの描画順序ランク(K、Lは、1≦K<N、1<L≦N、K<Lとなる任意の整数)のモデルオブジェクトを描画することを特徴とする画像生成システム。
An image generation system for generating an image,
A rank information storage unit that stores rank information for setting the rank of the drawing order of a plurality of model objects;
A Z buffer for storing the Z value of each pixel;
A drawing unit that sequentially draws the plurality of model objects in a drawing order according to the rank information from a model object having a low drawing order rank to a model object having a high drawing order rank while referring to a Z value of the Z buffer; Including
The drawing unit
After clearing the Z value of the Z buffer generated by drawing the model object of the Kth drawing order rank, the Lth drawing order rank (K, L) having a higher rank than the Kth drawing order rank Is a model object of 1 ≦ K <N, 1 <L ≦ N, and K <L.
JP2005069378A 2005-03-11 2005-03-11 Program, information storage medium and image generation system Withdrawn JP2006252292A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2005069378A JP2006252292A (en) 2005-03-11 2005-03-11 Program, information storage medium and image generation system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2005069378A JP2006252292A (en) 2005-03-11 2005-03-11 Program, information storage medium and image generation system

Publications (1)

Publication Number Publication Date
JP2006252292A true JP2006252292A (en) 2006-09-21

Family

ID=37092714

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2005069378A Withdrawn JP2006252292A (en) 2005-03-11 2005-03-11 Program, information storage medium and image generation system

Country Status (1)

Country Link
JP (1) JP2006252292A (en)

Cited By (1)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2012161102A1 (en) * 2011-05-25 2012-11-29 Square Enix Holdings Co., Ltd. Rendering control apparatus, control method thereof, recording medium, rendering server, and rendering system

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
WO2012161102A1 (en) * 2011-05-25 2012-11-29 Square Enix Holdings Co., Ltd. Rendering control apparatus, control method thereof, recording medium, rendering server, and rendering system
JP2012245347A (en) * 2011-05-25 2012-12-13 Square Enix Holdings Co Ltd Rendering control apparatus, control method of the same, program, recording medium, rendering server, and rendering system
CN103098099A (en) * 2011-05-25 2013-05-08 史克威尔·艾尼克斯控股公司 Rendering control apparatus, control method thereof, recording medium, rendering server, and rendering system
US8698813B2 (en) 2011-05-25 2014-04-15 Kabushiki Kaisha Square Enix Rendering control apparatus, control method thereof, recording medium, rendering server, and rendering system
US9649561B2 (en) 2011-05-25 2017-05-16 Square Enix Holidings Co., Ltd. Rendering control apparatus, control method thereof, recording medium, rendering server, and rendering system

Similar Documents

Publication Publication Date Title
JP4771821B2 (en) Program, information storage medium, and image generation system
JP4412715B2 (en) Program, information storage medium, and image generation system
JP2006195882A (en) Program, information storage medium and image generation system
JP4804122B2 (en) Program, texture data structure, information storage medium, and image generation system
JP4305903B2 (en) Image generation system, program, and information storage medium
JP4502678B2 (en) Program, information storage medium, and image generation system
JP3280355B2 (en) Image generation system and information storage medium
JP4743770B2 (en) Image generation system, program, and information storage medium
JP2006252426A (en) Program, information storage medium, and image generation system
JP4651204B2 (en) Image generation system, program, and information storage medium
JP5253118B2 (en) Image generation system, program, and information storage medium
JP4913399B2 (en) Program, information storage medium, and image generation system
JP4632855B2 (en) Program, information storage medium, and image generation system
JP4528008B2 (en) Program, information storage medium, and image generation system
JP4187192B2 (en) Image generation system, program, and information storage medium
JP2006268103A (en) Program, information storage medium, model data structure, and image generation system
JP4698701B2 (en) Image generation system, program, and information storage medium
JP2006252292A (en) Program, information storage medium and image generation system
JP4476040B2 (en) Program, information storage medium, and image generation system
JP2008077406A (en) Image generation system, program, and information storage medium
JP4680670B2 (en) Program, information storage medium, and image generation system
JP2006252291A (en) Program, information storage medium and image generation system
JP4521811B2 (en) Program, information storage medium, and image generation system
JP4794597B2 (en) Image generation system, program, and information storage medium
JP2008310377A (en) Image generation system, program and information storage medium

Legal Events

Date Code Title Description
A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20080513