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

Program, information storage medium, and image generation system Download PDF

Info

Publication number
JP4749131B2
JP4749131B2 JP2005336048A JP2005336048A JP4749131B2 JP 4749131 B2 JP4749131 B2 JP 4749131B2 JP 2005336048 A JP2005336048 A JP 2005336048A JP 2005336048 A JP2005336048 A JP 2005336048A JP 4749131 B2 JP4749131 B2 JP 4749131B2
Authority
JP
Japan
Prior art keywords
illumination
texture
target object
illuminated area
moving
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.)
Active
Application number
JP2005336048A
Other languages
Japanese (ja)
Other versions
JP2007141080A (en
Inventor
隆 今給黎
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.)
Namco Ltd
Bandai Namco Entertainment Inc
Original Assignee
Namco Ltd
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 Ltd, Namco Bandai Games Inc filed Critical Namco Ltd
Priority to JP2005336048A priority Critical patent/JP4749131B2/en
Publication of JP2007141080A publication Critical patent/JP2007141080A/en
Application granted granted Critical
Publication of JP4749131B2 publication Critical patent/JP4749131B2/en
Active legal-status Critical Current
Anticipated expiration legal-status Critical

Links

Landscapes

  • Image Generation (AREA)

Description

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

従来より、仮想的な3次元空間であるオブジェクト空間内の仮想カメラ(所与の視点)から見える画像を生成する画像生成システムが知られており、いわゆる仮想現実を体験できるものとして人気が高い。レーシングゲームを楽しむことができる画像生成システムを例にとれば、プレーヤはプレーヤ移動体を操作してオブジェクト空間内で走行させ、他のプレーヤやコンピュータが操作する敵移動体と競争することで3次元ゲームを楽しむ。   2. Description of the Related Art Conventionally, an image generation system that generates an image that can be viewed from a virtual camera (a given viewpoint) in an object space that is a virtual three-dimensional space is known, and is popular as a device that can experience so-called virtual reality. Taking an image generation system capable of enjoying a racing game as an example, a player operates a player moving body to run in the object space, and competes with other moving bodies operated by other players and computers, so that the three-dimensional Enjoy the game.

このような画像生成システムでは、プレーヤの仮想現実感の向上のためによりリアルな画像を生成することが重要な技術的課題になっている。このため夜間走行のシーンでは、移動体からのライトによる照明などについても、よりリアルに表現できることが望まれる。
特許3254195号公報
In such an image generation system, it is an important technical problem to generate a more realistic image in order to improve the player's virtual reality. For this reason, it is desirable that the night driving scene can be more realistically expressed with respect to the illumination by the light from the moving body.
Japanese Patent No. 3254195

本発明は上記事情に鑑みてなされたものであり、その目的は、移動体からの照明等をリアルに表現することができるプログラム、情報記憶媒体及び画像生成システムを提供することにある。   The present invention has been made in view of the above circumstances, and an object thereof is to provide a program, an information storage medium, and an image generation system that can realistically express illumination from a moving body.

(1)本発明は、オブジェクト空間を所与の視点から見た画像を生成するための画像生成システムであって、前記オブジェクト空間内を移動する照明源となる移動体オブジェクトのモデルデータと、移動体オブジェクトから照明を受ける照明対象オブジェクトのモデルデータとを記憶するモデルデータ記憶部と、前記移動体オブジェクト及び前記照明対象オブジェクトを前記オブジェクト空間に対して設定するオブジェクト空間設定部と、前記移動体オブジェクトから照射される照明光の照明パターンを設定した照明パターンテクスチャを記憶するテクスチャ記憶部と、前記移動体オブジェクトに対して設定した投影中心からの前記照明光の広がりを表す射影マトリクスを用いて、前記照明対象オブジェクトのモデルデータに含まれる頂点座標に対応する前記照明パターンテクスチャ用のテクスチャ座標を演算するテクスチャ座標演算部と、求められたテクスチャ座標に基づいて、前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定する被照明領域設定部と、前記被照明領域の設定情報に基づいて、前記照明対象オブジェクトに対して前記照明光を反映させる照明処理を行う照明処理部と、を含む画像生成システムに関係する。また本発明は、上記各部としてコンピュータを機能させるプログラム及び該プログラムを記憶する情報記憶媒体に関係する。   (1) The present invention is an image generation system for generating an image of an object space viewed from a given viewpoint, and includes model data of a moving object that serves as an illumination source that moves in the object space, and movement A model data storage unit that stores model data of a lighting target object that receives illumination from a body object, an object space setting unit that sets the moving body object and the lighting target object with respect to the object space, and the mobile object Using a texture storage unit that stores an illumination pattern texture in which an illumination pattern of illumination light emitted from the projection object is stored, and a projection matrix that represents a spread of the illumination light from the projection center set for the moving object, Vertex locus included in the model data of the object to be illuminated A texture coordinate calculation unit that calculates texture coordinates for the illumination pattern texture corresponding to the illumination pattern texture, and texture mapping the illumination pattern texture to the illumination target object based on the obtained texture coordinates, An image generation system comprising: an illuminated area setting unit that sets an illumination area; and an illumination processing unit that performs illumination processing that reflects the illumination light on the illumination target object based on setting information of the illuminated area Related to. The present invention also relates to a program that causes a computer to function as each of the above-described units and an information storage medium that stores the program.

本発明によれば、移動体オブジェクトの移動によって照明源の位置が変動するが、その変動した位置に応じて照明対象オブジェクトに対して被照明領域が設定される。すなわち本発明によれば、照明源の移動に応じた被照明領域を設定することで移動体からの照明をリアルに背景等に反映させた画像を生成することができる。   According to the present invention, the position of the illumination source varies due to the movement of the moving object, and the illuminated area is set for the illumination target object according to the varied position. That is, according to the present invention, it is possible to generate an image that realistically reflects the illumination from the moving body on the background or the like by setting the illuminated area according to the movement of the illumination source.

(2)また本発明の画像生成システム、プログラム及び情報記憶媒体では、前記オブジェクトデータ記憶部が、複数種類の移動体オブジェクトのオブジェクトデータを記憶し、前記オブジェクト空間設定部が、前記複数種類の移動体オブジェクトのうち1種類以上を前記オブジェクト空間に設定し、前記テクスチャ記憶部が、前記移動体オブジェクトの種類に応じて異なる複数の照明パターンテクスチャを記憶し、前記被照明領域設定部が、前記移動体オブジェクトの種類に応じた照明パターンテクスチャを前記照明対象オブジェクトにテクスチャマッピングして前記移動体オブジェクトの種類に応じた被照明領域を設定するようにしてもよい。このようにすれば、移動体の種類毎に照明パターンを変えているので、移動体の種類に応じた照明の効果を背景等に反映させたリアルな表現を行うことができる。   (2) In the image generation system, the program, and the information storage medium of the present invention, the object data storage unit stores object data of a plurality of types of moving objects, and the object space setting unit includes the plurality of types of movements. One or more types of body objects are set in the object space, the texture storage unit stores a plurality of illumination pattern textures that differ depending on the type of the moving body object, and the illuminated region setting unit is configured to move the object An illumination pattern texture corresponding to the type of the body object may be texture-mapped to the illumination target object, and an illuminated area corresponding to the type of the moving body object may be set. In this way, since the illumination pattern is changed for each type of moving body, it is possible to perform realistic expression reflecting the effect of illumination according to the type of moving body on the background or the like.

(3)また本発明の画像生成システム、プログラム及び情報記憶媒体では、前記オブジェクトデータ記憶部が、複数種類の移動体オブジェクトのオブジェクトデータを記憶し、前記オブジェクト空間設定部が、前記複数種類の移動体オブジェクトのうち1種類以上を前記オブジェクト空間に設定し、前記テクスチャ座標演算部が、前記移動体オブジェクトの種類に応じて異なる射影マトリクスを用いて前記テクスチャ座標を演算し、前記被照明領域設定部が、求められたテクスチャ座標に基づいて、前記移動体オブジェクトの種類に応じた被照明領域を前記照明対象オブジェクトに対して設定するようにしてもよい。このようにすれば、移動体の種類毎に射影マトリクスを変えているので、移動体の種類に応じて照明光の影響を受ける範囲を変化させたリアルな表現を行うことができる。   (3) In the image generation system, the program, and the information storage medium of the present invention, the object data storage unit stores object data of a plurality of types of mobile objects, and the object space setting unit includes the plurality of types of movements. One or more types of body objects are set in the object space, and the texture coordinate calculation unit calculates the texture coordinates using a different projection matrix depending on the type of the moving object, and the illuminated region setting unit However, an illuminated area corresponding to the type of the moving object may be set for the illumination target object based on the obtained texture coordinates. In this way, since the projection matrix is changed for each type of moving body, it is possible to perform realistic expression in which the range affected by the illumination light is changed according to the type of moving body.

(4)また本発明の画像生成システム、プログラム及び情報記憶媒体では、前記テクスチャ記憶部が、前記オブジェクト空間で発生するイベントの種類に応じて異なる複数の照明パターンテクスチャを記憶し、前記被照明領域設定部が、前記イベントの種類に応じた照明パターンテクスチャを前記照明対象オブジェクトにテクスチャマッピングして前記イベントの種類に応じた被照明領域を前記照明対象オブジェクトに対して設定するようにしてもよい。このようにすれば、イベントに応じて照明のパターンを変化させることで、例えば、照明の故障イベントなどに対応したリアルな表現を行うことができる。   (4) In the image generation system, the program, and the information storage medium of the present invention, the texture storage unit stores a plurality of illumination pattern textures that differ depending on the type of event that occurs in the object space, and the illuminated area The setting unit may texture-map an illumination pattern texture corresponding to the type of the event to the illumination target object, and set an illuminated area corresponding to the event type for the illumination target object. In this way, by changing the illumination pattern according to the event, for example, realistic expression corresponding to a failure event of illumination can be performed.

(5)また本発明の画像生成システム、プログラム及び情報記憶媒体では、前記テクスチャ座標演算部が、前記オブジェクト空間で発生するイベントの種類に応じて異なる射影マトリクスを用いて前記テクスチャ座標を演算し、前記被照明領域設定部が、求められたテクスチャ座標に基づいて、前記イベントの種類に応じた被照明領域を前記照明対象オブジェクトに対して設定するようにしてもよい。このようにすれば、イベントに応じて射影マトリクスを変化させることで、例えば、照明の故障イベントなどに対応したリアルな表現を行うことができる。   (5) In the image generation system, the program, and the information storage medium of the present invention, the texture coordinate calculation unit calculates the texture coordinates using a different projection matrix according to the type of event that occurs in the object space, The illuminated area setting unit may set an illuminated area corresponding to the type of event for the illumination target object based on the obtained texture coordinates. In this way, by changing the projection matrix according to the event, it is possible to perform realistic expression corresponding to, for example, a lighting failure event.

(6)また本発明の画像生成システム、プログラム及び情報記憶媒体では、前記照明処理部が、前記照明対象オブジェクトを構成する頂点に対して予め設定された前記照明光に対する影響度パラメータに基づいて、前記照明対象オブジェクトのモデルデータに基づき得られる色を調整する処理を照明処理として行うようにしてもよい。このようにすれば、影響度の大きさに応じて色を調整するだけで照明対象オブジェクトに対して照明源オブジェクトから受ける光の影響を反映させることができる。   (6) Moreover, in the image generation system, the program, and the information storage medium of the present invention, the illumination processing unit is based on an influence parameter with respect to the illumination light set in advance with respect to the vertex constituting the illumination target object. You may make it perform the process which adjusts the color obtained based on the model data of the said illumination target object as an illumination process. In this way, it is possible to reflect the influence of light received from the illumination source object on the illumination target object simply by adjusting the color according to the magnitude of the influence degree.

以下、本実施形態について説明する。なお、以下に説明する本実施形態は、特許請求の範囲に記載された本発明の内容を不当に限定するものではない。また本実施形態で説明される構成の全てが、本発明の必須構成要件であるとは限らない。   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の構成要素(各部)の一部を省略した構成としてもよい。   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 of a player object (an example of a moving object, a player character operated by the player), and functions thereof are a lever, a button, a steering, a microphone, and a touch panel display. Alternatively, it can be realized by a housing or the like. The storage unit 170 serves as a work area for the processing unit 100, the communication unit 196, and the like, and its function can be realized by a RAM (VRAM) or the like.

情報記憶媒体180(コンピュータにより読み取り可能な媒体)は、プログラムやデータなどを格納するものであり、その機能は、光ディスク(CD、DVD)、光磁気ディスク(MO)、磁気ディスク、ハードディスク、磁気テープ、或いはメモリ(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), magneto-optical disk (MO), magnetic disk, hard disk, and magnetic tape. Alternatively, it can be realized by a memory (ROM). 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 processing 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, touch panel display, HMD (head mounted 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. 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 this 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内の主記憶部172をワーク領域として各種処理を行う。処理部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 main storage unit 172 in 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軸回りでの回転角度)でオブジェクトを配置する。特に本実施形態では、記憶部170のオブジェクトデータ記憶部176にオブジェクト空間内を移動する照明源オブジェクト(移動体オブジェクト)のオブジェクトデータと、照明源オブジェクトから照明を受ける照明対象オブジェクトのオブジェクトデータとが記憶されており、これらのオブジェクトをオブジェクト空間に配置する処理を行う。   The object space setting unit 110 is an object composed of various objects (polygons, free-form surfaces, subdivision surfaces, etc.) representing display objects such as characters, buildings, stadiums, cars, trees, pillars, walls, and maps (terrain). ) Is set in the object space. In other words, the position and rotation angle of the object in the world coordinate system (synonymous with direction and direction) are determined, and the rotation angle (rotation angle around the X, Y, and Z axes) is determined at that position (X, Y, Z). Arrange objects. In particular, in the present embodiment, object data of an illumination source object (moving object) that moves in the object space and object data of an illumination target object that receives illumination from the illumination source object are stored in the object data storage unit 176 of the storage unit 170. A process for arranging these objects in the object space is performed.

移動・動作処理部112は、オブジェクト(キャラクタ、車、電車又は飛行機等)の移動・動作演算(移動・動作シミュレーション)を行う。すなわち操作部160によりプレーヤが入力した操作データや、プログラム(移動・動作アルゴリズム)や、各種データ(モーションデータ)などに基づいて、オブジェクトをオブジェクト空間内で移動させたり、オブジェクトを動作(モーション、アニメーション)させたりする処理を行う。具体的には、オブジェクトの移動情報(位置、回転角度、速度、或いは加速度)や動作情報(オブジェクトを構成する各パーツの位置、或いは回転角度)を、1フレーム(1/60秒)毎に順次求めるシミュレーション処理を行う。なおフレームは、オブジェクトの移動・動作処理(シミュレーション処理)や画像生成処理を行う時間の単位である。特に本実施形態では、操作部160によりプレーヤが入力した操作データなどに基づいて、照明源オブジェクト(移動体オブジェクト)をオブジェクト空間内で移動させる処理を行う。   The movement / motion processing unit 112 performs a movement / motion calculation (movement / motion simulation) of an object (character, car, train, airplane, etc.). That is, 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, the object is moved in the object space, or the object is moved (motion, animation). ) Process. Specifically, object movement information (position, rotation angle, speed, or acceleration) and motion information (position or rotation angle of each part that constitutes the object) are sequentially transmitted every frame (1/60 seconds). Perform the required simulation process. A frame is a unit of time for performing object movement / motion processing (simulation processing) and image generation processing. In particular, in the present embodiment, processing for moving the illumination source object (moving object) in the object space is performed based on operation data input by the player through the operation unit 160.

仮想カメラ制御部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, processing for controlling the position (X, Y, Z) or rotation angle (rotation angle about the X, Y, Z axis) of the virtual camera (processing for controlling the viewpoint position, the line-of-sight direction or the angle of view) I do.

例えば仮想カメラによりオブジェクト(例えばキャラクタ、ボール、車)を後方から撮影する場合には、オブジェクトの位置又は回転の変化に仮想カメラが追従するように、仮想カメラの位置又は回転角度(仮想カメラの向き)を制御する。この場合には、移動・動作処理部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. When there are a plurality of virtual cameras (viewpoints), the above control process is performed for each virtual camera.

描画部120は、処理部100で行われる種々の処理(ゲーム処理)の結果に基づいて描画処理を行い、これにより画像を生成し、表示部190に出力する。いわゆる3次元ゲーム画像を生成する場合には、まずオブジェクト(モデル)の各頂点の頂点データ(頂点の位置座標、テクスチャ座標、色データ、法線ベクトル或いはα値等)を含むオブジェクトデータ(モデルデータ)が入力され、入力されたオブジェクトデータに含まれる頂点データに基づいて、頂点処理(頂点シェーダによるシェーディング)が行われる。なお頂点処理を行うに際して、必要に応じてポリゴンを再分割するための頂点生成処理(テッセレーション、曲面分割、ポリゴン分割)を行うようにしてもよい。頂点処理では、頂点処理プログラム(頂点シェーダプログラム、第1のシェーダプログラム)に従って、頂点の移動処理や、座標変換(ワールド座標変換、カメラ座標変換)、クリッピング処理、あるいは透視変換等のジオメトリ処理が行われ、その処理結果に基づいて、オブジェクトを構成する頂点群について与えられた頂点データを変更(更新、調整)する。そして、頂点処理後の頂点データに基づいてラスタライズ(走査変換)が行われ、ポリゴン(プリミティブ)の面とピクセルとが対応づけられる。そしてラスタライズに続いて、画像を構成するピクセル(表示画面を構成するフラグメント)を描画するピクセル処理(ピクセルシェーダによるシェーディング、フラグメント処理)が行われる。ピクセル処理では、ピクセル処理プログラム(ピクセルシェーダプログラム、第2のシェーダプログラム)に従って、テクスチャの読出し(テクスチャマッピング)、色データの設定/変更、半透明合成、アンチエイリアス等の各種処理を行って、画像を構成するピクセルの最終的な描画色を決定し、透視変換されたオブジェクトの描画色を描画バッファ174(ピクセル単位で画像情報を記憶できるバッファ。VRAM、レンダリングターゲット)に出力(描画)する。すなわち、ピクセル処理では、画像情報(色、法線、輝度、α値等)をピクセル単位で設定あるいは変更するパーピクセル処理を行う。これにより、オブジェクト空間内において仮想カメラ(所与の視点)から見える画像が生成される。なお、仮想カメラ(視点)が複数存在する場合には、それぞれの仮想カメラから見える画像を分割画像として1画面に表示できるように画像を生成することができる。   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. When generating a so-called three-dimensional game image, first, object data (model data) including vertex data (vertex position coordinates, texture coordinates, color data, normal vector, α value, etc.) of each vertex of the object (model) ) Is input, and vertex processing (shading by a vertex shader) is performed based on the vertex data included in the input object data. When performing the vertex processing, vertex generation processing (tessellation, curved surface division, polygon division) for re-dividing the polygon may be performed as necessary. In the vertex processing, according to the vertex processing program (vertex shader program, first shader program), vertex movement processing, coordinate conversion (world coordinate conversion, camera coordinate conversion), clipping processing, perspective processing, and other geometric processing are performed. On the basis of the processing result, the vertex data given to the vertex group constituting the object is changed (updated or adjusted). Then, rasterization (scan conversion) is performed based on the vertex data after the vertex processing, and the surface of the polygon (primitive) is associated with the pixel. Subsequent to rasterization, pixel processing (shading or fragment processing by a pixel shader) for drawing pixels (fragments forming a display screen) constituting an image is performed. In pixel processing, according to a pixel processing program (pixel shader program, second shader program), various processes such as texture reading (texture mapping), color data setting / change, translucent composition, anti-aliasing, etc. are performed, and an image is processed. The final drawing color of the constituent pixels is determined, and the drawing color of the perspective-transformed object is output (drawn) to the drawing buffer 174 (a buffer capable of storing image information in units of pixels; VRAM, rendering target). That is, in pixel processing, per-pixel processing for setting or changing image information (color, normal, luminance, α value, etc.) in units of pixels is performed. Thereby, an image that can be seen from the virtual camera (given viewpoint) in the object space is generated. Note that when there are a plurality of virtual cameras (viewpoints), an image can be generated so that an image seen from each virtual camera can be displayed as a divided image on one screen.

なお頂点処理やピクセル処理は、シェーディング言語によって記述されたシェーダプログラムによって、ポリゴン(プリミティブ)の描画処理をプログラム可能にするハードウェア、いわゆるプログラマブルシェーダ(頂点シェーダやピクセルシェーダ)により実現される。プログラマブルシェーダでは、頂点単位の処理やピクセル単位の処理がプログラム可能になることで描画処理内容の自由度が高く、従来のハードウェアによる固定的な描画処理に比べて表現力を大幅に向上させることができる。   The vertex processing and pixel processing are realized by hardware that enables polygon (primitive) drawing processing to be programmed by a shader program written in a shading language, so-called programmable shaders (vertex shaders and pixel shaders). Programmable shaders can be programmed with vertex-level processing and pixel-level processing, so that the degree of freedom of drawing processing is high, and expressive power is greatly improved compared to conventional hardware-based fixed drawing processing. Can do.

そして描画部120は、オブジェクトを描画する際に、ジオメトリ処理、テクスチャマッピング、隠面消去処理、αブレンディング等を行う。   The drawing unit 120 performs geometry processing, texture mapping, hidden surface removal processing, α blending, and the like when drawing an object.

ジオメトリ処理では、オブジェクトに対して、座標変換、クリッピング処理、透視投影変換、或いは光源計算等の処理が行われる。そして、ジオメトリ処理後(透視投影変換後)のオブジェクトデータ(オブジェクトの頂点の位置座標、テクスチャ座標、色データ(輝度データ)、法線ベクトル、或いはα値等)は、主記憶部172に保存される。   In the geometry processing, processing such as coordinate conversion, clipping processing, perspective projection conversion, or light source calculation is performed on the object. Then, object data (positional coordinates of object vertices, texture coordinates, color data (luminance data), normal vector, α value, etc.) after geometry processing (after perspective projection conversion) is stored in the main storage unit 172. The

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

隠面消去処理としては、描画ピクセルのZ値(奥行き情報)が格納されるZバッファ(奥行きバッファ)を用いたZバッファ法(奥行き比較法、Zテスト)による隠面消去処理を行うことができる。すなわちオブジェクトのプリミティブに対応する描画ピクセルを描画する際に、Zバッファに格納されるZ値を参照する。そして参照されたZバッファのZ値と、プリミティブの描画ピクセルでのZ値とを比較し、描画ピクセルでのZ値が、仮想カメラから見て手前側となるZ値(例えば小さなZ値)である場合には、その描画ピクセルの描画処理を行うとともにZバッファのZ値を新たなZ値に更新する。   As the hidden surface removal processing, hidden surface removal processing can be performed by a Z buffer method (depth comparison method, Z test) using a Z buffer (depth buffer) in which Z values (depth information) of drawing pixels are stored. . That is, when drawing pixels corresponding to the primitive of the object are drawn, the Z value stored in the Z buffer is referred to. Then, the Z value of the referenced Z buffer is compared with the Z value at the drawing pixel of the primitive, and the Z value at the drawing pixel is a Z value (for example, a small Z value) on the near side when viewed from the virtual camera. In some cases, the drawing process of the drawing pixel is performed and the Z value of the Z buffer is updated to a new Z value.

αブレンディング(α合成)は、α値(A値)に基づく半透明合成処理(通常αブレンディング、加算αブレンディング又は減算αブレンディング等)のことである。   α blending (α synthesis) is a translucent synthesis process (usually α blending, addition α blending, subtraction α blending, or the like) based on an α value (A value).

なお、α値は、各ピクセル(テクセル、ドット)に関連づけて記憶できる情報であり、例えば色情報以外のプラスアルファの情報である。α値は、マスク情報、半透明度(透明度、不透明度と等価)、バンプ情報などとして使用できる。   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 mask information, translucency (equivalent to transparency and opacity), bump information, and the like.

さらに本実施形態では描画部120が、テクスチャ座標演算部122、被照明領域設定部124、照明処理部126とを含む。   Further, in the present embodiment, the drawing unit 120 includes a texture coordinate calculation unit 122, an illuminated area setting unit 124, and an illumination processing unit 126.

テクスチャ座標演算部122は、照明源オブジェクト(オブジェクト空間内を移動する移動体オブジェクト)に対して設定した投影中心(カメラ中心、代表点、基準点)からの照明光の広がりを表す射影マトリクスを用いて求められる変換マトリクスによって、照明対象オブジェクトのオブジェクトデータに含まれる頂点座標に対応する照明パターンテクスチャ用のテクスチャ座標を演算する。具体的には、ワールドマトリクス(第1のマトリクス)、ビューマトリクス(第2のマトリクス)、射影マトリクス(第3のマトリクス)、及び座標中心をずらして、かつ値域を正規化するための補正マトリクス(第4のマトリクス)からなる変換マトリクスと頂点座標とを乗算する処理をおこなって、頂点座標をテクスチャ座標に変換する。これにより、照明源オブジェクトと照明対象オブジェクトとの相対的な位置関係に応じたテクスチャ座標が求められる。   The texture coordinate calculation unit 122 uses a projection matrix representing the spread of illumination light from the projection center (camera center, representative point, reference point) set for the illumination source object (moving object moving in the object space). The texture coordinates for the illumination pattern texture corresponding to the vertex coordinates included in the object data of the illumination target object are calculated by the conversion matrix obtained in this way. Specifically, a world matrix (first matrix), a view matrix (second matrix), a projection matrix (third matrix), and a correction matrix for shifting the coordinate center and normalizing the range ( A process of multiplying the conversion matrix comprising the fourth matrix) and the vertex coordinates is performed to convert the vertex coordinates into texture coordinates. As a result, texture coordinates corresponding to the relative positional relationship between the illumination source object and the illumination target object are obtained.

被照明領域設定部124は、テクスチャ座標演算部122により求められたテクスチャ座標に基づいて、照明対象オブジェクトに照明パターンテクスチャをテクスチャマッピングすることにより照明対象オブジェクトに対して被照明領域を設定する処理を行う。具体的には、テクスチャ記憶部176には、照明源オブジェクトから照射される照明光の照明パターンに応じてテクセルの値(輝度値)を変化させた照明パターンテクスチャが記憶されており、テクスチャ座標に基づいてサンプリングされるテクセルデータ(パラメータ)を照明対象オブジェクトに対応づけることにより照明対象オブジェクトには照明パターンに応じた被照明対象領域が設定される。   The illuminated area setting unit 124 performs processing for setting an illuminated area for the illumination target object by texture mapping the illumination pattern texture to the illumination target object based on the texture coordinates obtained by the texture coordinate calculation unit 122. Do. Specifically, the texture storage unit 176 stores an illumination pattern texture in which the value of the texel (luminance value) is changed according to the illumination pattern of the illumination light emitted from the illumination source object, and the texture coordinates are stored in the texture coordinates. By associating the texel data (parameters) sampled based on the illumination target object, the illumination target area corresponding to the illumination pattern is set in the illumination target object.

照明処理部126は、被照明領域の設定情報に基づいて、照明対象オブジェクトに対して照明源オブジェクトからの照明光を反映させる照明処理を行う。具体的には、照明対象オブジェクトに対して設定された被照明領域以外の領域について照明対象オブジェクトのオブジェクトデータに基づき得られる色を影響度パラメータに応じて暗い色に変更する照明処理を行う。   The illumination processing unit 126 performs an illumination process for reflecting the illumination light from the illumination source object on the illumination target object based on the setting information of the illuminated area. Specifically, an illumination process is performed in which the color obtained based on the object data of the illumination target object is changed to a dark color according to the influence degree parameter for an area other than the illuminated area set for the illumination target object.

影響度パラメータは、照明源オブジェクトから受ける照明光の影響度を表すパラメータであって、オブジェクトデータ記憶部176に格納されている照明対象オブジェクトのオブジェクトデータにおいて照明対象オブジェクトを構成する頂点に対応づけられているパラメータである。この影響度パラメータは、α値(A値)により設定することができ、例えば、頂点α値として各頂点に直接対応づけられていてもよいし、頂点に対応づけられたテクスチャ座標よりサンプリングされるデカールテクスチャ(模様テクスチャ)のテクセルのα値によって間接的に対応づけられていてもよい。また影響度パラメータは、頂点に直接対応づけられた頂点α値とデカールテクスチャのテクセルに設定されたα値との乗算結果により求められるようにしてもよい。   The influence degree parameter is a parameter representing the influence degree of the illumination light received from the illumination source object, and is associated with the vertex constituting the illumination target object in the object data of the illumination target object stored in the object data storage unit 176. Parameter. The influence parameter can be set by an α value (A value). For example, the influence parameter may be directly associated with each vertex as a vertex α value, or sampled from texture coordinates associated with the vertex. It may be indirectly associated with the texel α value of the decal texture (pattern texture). Further, the influence parameter may be obtained from a multiplication result of the vertex α value directly associated with the vertex and the α value set in the texel of the decal texture.

またオブジェクトデータ記憶部176には、照明対象オブジェクトのオブジェクトデータにおいて照明対象オブジェクトを構成する複数の頂点の各頂点に対して、照明源オブジェクトから受ける照明光を反映した色が対応づけられている。この「照明光を反映した色」は、例えば、頂点色(ディフューズ)として各頂点に直接対応づけられていてもよいし、頂点に対応づけられたテクスチャ座標よりサンプリングされるデカールテクスチャ(模様テクスチャ)のテクセルの色によって間接的に対応づけられていてもよい。また「照明光を反映した色」は、頂点に直接対応づけられた頂点色とデカールテクスチャのテクセルに設定された色との乗算結果により求められるようにしてもよい。   Further, in the object data storage unit 176, a color reflecting illumination light received from the illumination source object is associated with each vertex of the plurality of vertices constituting the illumination target object in the object data of the illumination target object. This “color reflecting illumination light” may be directly associated with each vertex as a vertex color (diffuse), for example, or a decal texture (pattern texture) sampled from the texture coordinates associated with the vertex. ) May be indirectly associated with the color of the texel. Further, the “color reflecting illumination light” may be obtained from the result of multiplication of the vertex color directly associated with the vertex and the color set in the texel of the decal texture.

また照明対象オブジェクトが、照明源オブジェクトとは異なる他の照明源(例えば、街灯)からの照明光を受けている第1の領域と、他の照明源からの照明光を受けていない第2の領域とを含む場合には、オブジェクトデータ記憶部176に格納される照明対象オブジェクトのオブジェクトデータでは、第1の領域を構成する頂点に対して、照明源オブジェクトから受ける照明光と他の照明源から受ける照明光とを反映した色を対応づけておき、第2の領域を構成する頂点に対して、前記照明源オブジェクトからの照明光を反映した色が対応付けられておくことができる。特にこのような場合には、照明対象オブジェクトのオブジェクトデータでは、第2の領域を構成する頂点に対して、第1の領域を構成する頂点よりも照明源オブジェクトからの照明光の影響が大きくなるように影響度パラメータが対応づけておくことが好ましい。   The illumination target object has a first area that receives illumination light from another illumination source (for example, a streetlight) different from the illumination source object, and a second area that does not receive illumination light from another illumination source. In the object data of the object to be illuminated stored in the object data storage unit 176, the illumination light received from the illumination source object and other illumination sources with respect to the vertex constituting the first area are included. A color reflecting the illumination light to be received is associated, and a color reflecting the illumination light from the illumination source object can be associated with a vertex constituting the second region. Particularly in such a case, in the object data of the illumination target object, the influence of the illumination light from the illumination source object is greater on the vertices constituting the second area than on the vertices constituting the first area. Thus, it is preferable that the influence degree parameters are associated with each other.

なお照明処理では、被照明領域について照明対象オブジェクトのオブジェクトデータに基づき得られる色を影響度パラメータに応じて明るい色に変更するようにしてもよいし、被照明領域及びそれ以外の領域の双方について照明対象オブジェクトのオブジェクトデータに基づき得られる色を影響度パラメータに応じて調整するようにしてもよい。   In the illumination process, the color obtained based on the object data of the illumination target object for the illuminated area may be changed to a bright color according to the influence parameter, or for both the illuminated area and other areas. You may make it adjust the color obtained based on the object data of a lighting target object according to an influence parameter.

音生成部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.1 被照明領域の設定手法
本実施の形態では、図2に示すように、オブジェクト空間内を移動する照明源となる電車の車両オブジェクトOB1(照明源オブジェクト、移動体オブジェクト)からの照明光を受ける線路のコースオブジェクトOB2(照明対象オブジェクト)に対して照明パターンをテクスチャ化したテクスチャTEX(照明パターンテクスチャ)を投影マッピングすることで車両オブジェクトOB1の移動に応じた被照明領域をコースオブジェクトOB2に対して設定する手法を採用する。
2. 2. Technique of this Embodiment 2.1 Illuminated Area Setting Technique In this embodiment, as shown in FIG. 2, a train vehicle object OB1 (illumination source object, moving object) that serves as an illumination source that moves in the object space ) To be illuminated according to the movement of the vehicle object OB1 by projecting and mapping the texture TEX (illumination pattern texture) obtained by textured the illumination pattern on the course object OB2 (illumination target object) of the track that receives illumination light from Is used for the course object OB2.

具体的には、まず図3に示すように照明の明るさに応じて内側から外側に向かってテクセル値が連続的に変化したパターンを照明パターンとして設定したテクスチャTEX(照明パターンテクスチャ)を用意する。このテクスチャTEXでは、照明領域と非照明領域とが設定され、各領域に応じてテクセルに照明の明るさパラメータLが設定されている。図4に示すように、明るさパラメータLは、照明領域のうち照明光が強い領域R1がL=1に設定され、その内側から外側に向かって領域R2では0<L<1の範囲で連続的に明るさパラメータLが変化するように設定されている。また非照明領域では、明るさパラメータLが0に設定される。なお明るさパラメータLは、テクセルのRGB成分の各色成分の輝度値あるいはテクセルのα値として設定することができ、先に述べたようなテクセルの設定とは異なる設定をしてもよい。   Specifically, first, as shown in FIG. 3, a texture TEX (illumination pattern texture) is prepared in which a pattern in which texel values continuously change from the inside toward the outside according to the brightness of the illumination is set as the illumination pattern. . In this texture TEX, an illumination area and a non-illumination area are set, and an illumination brightness parameter L is set in the texel according to each area. As shown in FIG. 4, the brightness parameter L is set to L = 1 in the illumination area where the illumination light is strong, and is continuously set in the range of 0 <L <1 in the area R2 from the inside toward the outside. Thus, the brightness parameter L is set to change. In the non-illuminated area, the brightness parameter L is set to zero. The brightness parameter L can be set as the luminance value of each color component of the RGB components of the texel or the α value of the texel, and may be set differently from the setting of the texel as described above.

そして、このテクスチャTEXを図5に示すように照明源となる電車を模した車両オブジェクトOB1の予め定められた位置を投影中心とする仮想カメラVC2(第2の仮想カメラ)から射影することにより線路を模したコースオブジェクトOB2の各頂点の位置とテクセルの位置とを対応づけるようにテクスチャ座標を求めている。また本実施形態の手法では、仮想カメラVC2が車両オブジェクトOB1の正面下向きに設置されており、仮想カメラVC2の投影中心からの照明光がコースオブジェクトOB2に向けて広がって照射されている様子を表現している。すなわちテクスチャTEXのテクスチャマッピング対象領域を仮想カメラVC2の画角内に存在する頂点(図5の例では、頂点V1〜V5)の座標がテクスチャ座標に変換される。このようにして本実施形態では、テクスチャTEXに照明パターンとして設定した明るさパラメータLがコースオブジェクトOB2の頂点に対応づけられることにより、コースオブジェクトOB2の一部の領域について明るさパラメータLが0<L≦1に設定され、その領域が車両オブジェクトOB1からの照明光を受けている被照明領域として設定される。なお、図5中の仮想カメラVC1(第1の仮想カメラ)は描画対象となるオブジェクト空間のシーンを撮影(ビューボリューム内のオブジェクトをスクリーンに透視投影)するためのカメラである。   Then, the texture TEX is projected from a virtual camera VC2 (second virtual camera) whose projection center is a predetermined position of a vehicle object OB1 that imitates a train serving as an illumination source as shown in FIG. The texture coordinates are obtained so that the positions of the vertices and the positions of the vertices of the course object OB2 imitating Further, in the method of the present embodiment, the virtual camera VC2 is installed in the front downward direction of the vehicle object OB1, and the illumination light from the projection center of the virtual camera VC2 is spread and irradiated toward the course object OB2. is doing. That is, the coordinates of the vertices (the vertices V1 to V5 in the example of FIG. 5) in which the texture mapping target area of the texture TEX exists within the angle of view of the virtual camera VC2 are converted into texture coordinates. In this way, in the present embodiment, the brightness parameter L set as the illumination pattern in the texture TEX is associated with the vertex of the course object OB2, so that the brightness parameter L for a part of the course object OB2 is 0 < L ≦ 1 is set, and the area is set as an illuminated area that receives illumination light from the vehicle object OB1. Note that the virtual camera VC1 (first virtual camera) in FIG. 5 is a camera for photographing a scene in the object space to be rendered (perspectively projecting an object in the view volume onto the screen).

ここで本実施形態では、テクスチャTEX用のテクスチャ座標の求め方として、頂点座標を所定の変換マトリクスを用いてテクスチャ座標に変換する手法を採用している。例えば、コースオブジェクトOB2のオブジェクトデータに含まれる各頂点の座標値をローカル座標系(モデル座標系)の座標値からワールド座標系の座標値へ変換するワールドマトリクスWと、仮想カメラVC1の投影中心を原点とするビュー座標系(視点座標系)への変換を行うビューマトリクスVと、照明源の投影中心からの照明光の広がり(投影中心からの距離に応じたテクスチャ画像の拡大率)を表す射影マトリクスPと、各マトリクスW,V,Pによって得られたテクスチャ座標の座標系の中心(原点)をずらすとともに値域を正規化(−1〜1を0〜1に正規化)するための行列要素を含む補正マトリクスとを用意して、これらの各マトリクスに基づいて、コースオブジェクトOB2の頂点座標をテクスチャ座標に変換するための変換マトリクスmを求めることができる。   Here, in the present embodiment, as a method for obtaining the texture coordinates for the texture TEX, a method of converting the vertex coordinates into the texture coordinates using a predetermined conversion matrix is adopted. For example, the world matrix W for converting the coordinate value of each vertex included in the object data of the course object OB2 from the coordinate value of the local coordinate system (model coordinate system) to the coordinate value of the world coordinate system, and the projection center of the virtual camera VC1. A view matrix V that performs conversion to a view coordinate system (viewpoint coordinate system) that is the origin, and a projection that represents the spread of illumination light from the projection center of the illumination source (the enlargement ratio of the texture image according to the distance from the projection center) Matrix elements for shifting the center (origin) of the coordinate system of the texture coordinate obtained by the matrix P and each matrix W, V, P and normalizing the range (normalizing −1 to 1 to 0 to 1) Are prepared, and the vertex coordinates of the course object OB2 are converted into texture coordinates based on these matrices. It can be obtained in the transformation matrix m.

ここで射影マトリクスPは、テクスチャTEXに設定される照明パターンに応じて変化させることができる。例えば、車両オブジェクトOB1として複数のオブジェクトデータが用意されている場合には、オブジェクト毎に異なるテクスチャTEXが対応づけられるとともに、対応づけられたテクスチャTEXに応じた射影マトリクスPを用いて変換マトリクスmを得ることができる。この場合、各射影マトリクスPでは互いに画角等が異なるように各行列要素が設定される。このようにすれば、車両毎の照明パターンがテクスチャTEXで用意されるとともに、車両毎の照明の広がりが射影マトリクスPで用意されるため、車両毎に背景等を照らす様子が違う画像を生成することができる。また車両オブジェクトOB1がコースオブジェクトOB2上を移動している時にライトの一部が故障するようなイベントが発生した場合に、その故障後の照明パターンを設定したテクスチャTEXを用意しておいて、マッピング対象のテクスチャTEXを切り替えるようにしてもよい。このようにすれば、発生したイベントの種類に応じた被照明領域をコースオブジェクトOB2に対して設定することができる。   Here, the projection matrix P can be changed according to the illumination pattern set in the texture TEX. For example, when a plurality of object data is prepared as the vehicle object OB1, different textures TEX are associated with each object, and the conversion matrix m is calculated using the projection matrix P corresponding to the associated texture TEX. Obtainable. In this case, each matrix element is set so that the angle of view and the like are different from each other in each projection matrix P. In this way, the illumination pattern for each vehicle is prepared with the texture TEX, and the illumination spread for each vehicle is prepared with the projection matrix P, so that an image with a different appearance of illuminating the background or the like is generated for each vehicle. be able to. In addition, when an event occurs in which a part of the light breaks down while the vehicle object OB1 is moving on the course object OB2, a texture TEX in which an illumination pattern after the failure is set is prepared and mapped. The target texture TEX may be switched. In this way, an illuminated area corresponding to the type of event that has occurred can be set for the course object OB2.

なおオブジェクトの種類に応じてテクスチャTEXのみを変更するようにしてもよいし、オブジェクトの種類に応じて射影マトリクスPのみを変更するようにしてもよいし、オブジェクトの種類に応じてテクスチャTEXと射影マトリクスPの双方を変更するようにしてもよい。またイベントの種類に応じてテクスチャTEXのみを変更するようにしてもよいし、イベントの種類に応じて射影マトリクスPのみを変更するようにしてもよいし、イベントの種類に応じてテクスチャTEXと射影マトリクスPの双方を変更するようにしてもよい。またオブジェクトの種類やイベントの種類に応じてテクスチャTEXや射影マトリクスPを変更する場合には、複数種類のオブジェクトや複数種類のイベントに個別のテクスチャTEXや個別の射影マトリクスPが対応づけられていてもよいし、複数種類のオブジェクトや複数種類のイベントの一部に対して共通のテクスチャTEXや共通の射影マトリクスPが対応づけられていてもよい。また複数種類のオブジェクトや複数種類のイベントをグループ分けしておき、グループ毎にテクスチャTEXや射影マトリクスPが対応づけられていてもよい。   Only the texture TEX may be changed according to the type of the object, only the projection matrix P may be changed according to the type of the object, or the texture TEX and the projection may be changed according to the type of the object. Both of the matrix P may be changed. Further, only the texture TEX may be changed according to the event type, only the projection matrix P may be changed according to the event type, or the texture TEX and the projection may be changed according to the event type. Both of the matrix P may be changed. When the texture TEX and the projection matrix P are changed according to the object type and the event type, the individual texture TEX and the individual projection matrix P are associated with a plurality of types of objects and a plurality of types of events. Alternatively, a common texture TEX or a common projection matrix P may be associated with a plurality of types of objects or a part of a plurality of types of events. A plurality of types of objects and a plurality of types of events may be grouped, and a texture TEX and a projection matrix P may be associated with each group.

また上記手法では、予め仮想カメラVC2を正面下向きに向けて車両オブジェクトOB1内の投影中心に設置した場合を説明したが、これに限定されない。例えば、図6に示すように、仮想カメラVC2が車両オブジェクトOB1の真正面を向くように設置して、仮想カメラVC2の投影中心から照明光が広がって照射される様子を表現するようにしてもよい。この場合、仮想カメラVC2の投影中心からの距離Dに応じて照明光がある距離範囲を照らす様子を表現するため、閾値パラメータとして距離Dthを設定するようにしてもよい。この場合、テクスチャTEXのテクスチャマッピング対象領域を仮想カメラVC2の画角内であって、かつ仮想カメラVC2の投影中心から距離DがDthの範囲に存在する頂点(図5の例では、頂点V2〜V5)の座標がテクスチャ座標に変換される。   In the above method, the case has been described in which the virtual camera VC2 is installed in advance at the projection center in the vehicle object OB1 with the front facing downward, but the present invention is not limited to this. For example, as shown in FIG. 6, the virtual camera VC2 may be installed so as to face the front of the vehicle object OB1, and the illumination light may be spread and irradiated from the projection center of the virtual camera VC2. . In this case, the distance Dth may be set as a threshold parameter in order to express a state in which the illumination light illuminates a certain distance range according to the distance D from the projection center of the virtual camera VC2. In this case, the texture mapping target area of the texture TEX is within the angle of view of the virtual camera VC2 and the vertex D exists in the range of the distance D from the projection center of the virtual camera VC2 (vertex V2 in the example of FIG. 5). The coordinates of V5) are converted into texture coordinates.

また、仮想カメラVC2の投影中心から距離Dthの範囲にある頂点をテクスチャTEXのマッピング対象の頂点とする場合だけでなく、例えば、仮想カメラVC2の画角内に存在する全ての頂点をテクスチャTEXのマッピング対象の頂点としておき、各頂点に対応づけられたテクスチャTEXのテクセルに設定される明るさパラメータLを仮想カメラVC2の投影中心からの距離Dに応じて減衰させる補正を行って、ある距離範囲(補正後の明るさパラメータL´が0<L´≦1となった範囲)にだけ照明光が届いている様子を表現してもよい。   Further, not only when vertices within the distance Dth from the projection center of the virtual camera VC2 are used as vertices to be mapped by the texture TEX, for example, all vertices existing within the angle of view of the virtual camera VC2 are displayed. A certain distance range is obtained by correcting the brightness parameter L set in the texel of the texture TEX associated with each vertex according to the distance D from the projection center of the virtual camera VC2 as a vertex to be mapped. A state in which the illumination light reaches only in a range where the corrected brightness parameter L ′ satisfies 0 <L ′ ≦ 1 may be expressed.

2.2 照明処理の手法
本実施形態では、オブジェクト空間内を移動する車両オブジェクトOB1からの照明を受ける照明対象のコースオブジェクトOB2のオブジェクトデータに車両オブジェクトOB1からの照明に対する影響度を設定して、コースオブジェクトOB2の色をオブジェクトデータに予め設定した影響度に応じて調整する照明処理の手法を採用する。
2.2 Method of Illumination Processing In this embodiment, the degree of influence on the illumination from the vehicle object OB1 is set in the object data of the illumination target course object OB2 that receives illumination from the vehicle object OB1 moving in the object space. A method of illumination processing is adopted in which the color of the course object OB2 is adjusted according to the influence degree set in advance in the object data.

具体的には、コースオブジェクトOB2のオブジェクトデータの構築段階で以下のような設定を行う。まず図7に示すように、コースオブジェクトOB2の全領域が車両オブジェクトOB1からの照明で照らされている場合を想定して、車両オブジェクトOB1の照明光の色を反映させた色を各頂点の色として設定する。   Specifically, the following settings are made at the construction stage of the object data of the course object OB2. First, as shown in FIG. 7, assuming that the entire area of the course object OB2 is illuminated by the illumination from the vehicle object OB1, the color reflecting the color of the illumination light of the vehicle object OB1 is the color of each vertex. Set as.

次に、図8に示すように、車両オブジェクトOB1からの照明を一切受けていない場合を想定して、コースオブジェクトOB2の本来の色を各頂点の色として設定する。なお図8では、予め車両オブジェクトOB1以外の照明源として街灯の照明を受けている領域については、その街灯の照明光を反映した色を頂点の色として設定している。また図8では、街灯の照明を予め受けている領域(元々明るい領域)と街灯の照明を受けていない領域(元々暗い場所)とで車両オブジェクトOB1の照明光に対する影響度が異なるように影響度パラメータを設定している。この影響度パラメータは、街灯の照明を受けている領域のほうが街灯の照明を受けていない領域よりも影響度が小さくなるようにしている。すなわち元々暗い場所は照明の影響を受けやすく、元々明るい場所は照明の影響を受けにくいという現象を影響度パラメータとして設定している。そしてこの影響度パラメータは、頂点のα値(A値)として設定される。   Next, as shown in FIG. 8, assuming that no illumination is received from the vehicle object OB1, the original color of the course object OB2 is set as the color of each vertex. In FIG. 8, the color reflecting the illumination light of the street lamp is set as the vertex color for the area that has been previously illuminated by the street lamp as an illumination source other than the vehicle object OB1. Further, in FIG. 8, the degree of influence is different so that the degree of influence on the illumination light of the vehicle object OB1 differs between the area that has been previously illuminated with the streetlight (originally bright area) and the area that has not been illuminated with the streetlight (originally dark place). The parameter is set. This influence parameter is set so that the influence is smaller in the area receiving the streetlight than in the area not receiving the streetlight. That is, the influence parameter is set such that a dark place is easily affected by illumination and a bright place is hardly affected by illumination. This influence parameter is set as the α value (A value) of the vertex.

そして最終的には、図7に示すように設定した車両オブジェクトOB1からの照明光を受けた場合の色と、図8に示すように設定した車両オブジェクトOB1からの照明光を受けていない場合の色と、コースオブジェクトOB2の元々の色の明るさに応じて決めた車両オブジェクトOB1の照明光に対する影響度に応じてコースオブジェクトOB2の各頂点の色を決定し、図9に示すように、車両オブジェクトOB1からの照明光を受けた場合の色と車両オブジェクトOB1からの照明光を受けていない場合の色とをブレンドした色を各頂点の色としてオブジェクトデータを構築する。   Finally, the color when the illumination light is received from the vehicle object OB1 set as shown in FIG. 7 and the illumination light from the vehicle object OB1 set as shown in FIG. 8 are not received. The color of each vertex of the course object OB2 is determined according to the color and the degree of influence of the vehicle object OB1 on the illumination light determined according to the brightness of the original color of the course object OB2, and as shown in FIG. Object data is constructed with the color obtained by blending the color when receiving illumination light from the object OB1 and the color when not receiving illumination light from the vehicle object OB1 as the color of each vertex.

このように予め頂点に対して設定しておいた色を利用して本実施形態では、以下のように車両オブジェクトOB1からの照明を受けた場合の照明処理を行う。   In this embodiment, using the color set in advance for the vertex as described above, the illumination process when the illumination from the vehicle object OB1 is received is performed as follows.

まず、車両オブジェクトOB1が通過するコースオブジェクトOB2の各領域において車両オブジェクトOB1を照明源とする照明光の影響度が図10に示すように設定されている場合を考える。図10では、コースオブジェクトOB2の一部の領域S1(第1の領域)が他の照明源(街灯)からの照明を予め受けている領域として設定されており、それ以外の領域S2(第2の領域)については、影響度パラメータAがA=A1(例えば、0<<A1≦1)に設定されている。ここでA1は車両オブジェクトOB1からの照明光の影響が大きいことを表す値として設定される。また他の照明源からの照明を受けている領域S1では、内側から外側にかけて街灯による照明の影響が小さくなることを考慮して、内側では影響度パラメータAがA=A2(例えば、0≦A2<<1)に設定され、内側から外側に向かって影響度パラメータAがA2からA1に連続的に変化するように設定されている。ここでA2は車両オブジェクトOB1からの照明光の影響が小さいことを表す値として設定される。   First, consider a case where the influence of illumination light using the vehicle object OB1 as an illumination source is set as shown in FIG. 10 in each region of the course object OB2 through which the vehicle object OB1 passes. In FIG. 10, a partial area S1 (first area) of the course object OB2 is set as an area that receives illumination from another illumination source (streetlight) in advance, and the other area S2 (second area) ), The influence parameter A is set to A = A1 (for example, 0 << A1 ≦ 1). Here, A1 is set as a value indicating that the influence of the illumination light from the vehicle object OB1 is large. In the area S1 receiving illumination from another illumination source, the influence parameter A is A = A2 (for example, 0 ≦ A2) on the inner side, considering that the influence of the lighting by the street lamp decreases from the inner side to the outer side. << 1), and the influence parameter A is set so as to continuously change from A2 to A1 from the inside to the outside. Here, A2 is set as a value indicating that the influence of the illumination light from the vehicle object OB1 is small.

このような状況において車両オブジェクトOB1はコースオブジェクトOB2を照明光で照らしながら図11のようにコースオブジェクトOB2の上を移動し、車両オブジェクトOB1の移動に応じて被照明領域S0が設定される。被照明領域S0は、先に述べた手法でテクスチャTEXがコースオブジェクトOB2に投影マッピングすることにより、テクスチャTEXのテクセルに対応づけられた明るさパラメータLに基づいて領域指定パラメータLTが設定されて、この領域指定パラメータLTにより被照明領域とそれ以外の領域とが画定される。この領域指定パラメータLTは、テクスチャTEXが投影マッピングされた領域については、LT=1−Lを設定し、それ以外の領域については、LT=1を固定的に設定している。すなわち、被照明領域S0では、車両オブジェクトOB1の照明光が強く当たっている領域ではLT=0となり、その領域から照明が当たっていない領域(LT=1の領域)に向けてLTが0<LT<1の範囲で連続的に変化する。   In such a situation, the vehicle object OB1 moves on the course object OB2 as shown in FIG. 11 while illuminating the course object OB2 with illumination light, and the illuminated area S0 is set according to the movement of the vehicle object OB1. In the illuminated area S0, the texture designation TEX is set on the basis of the brightness parameter L associated with the texel of the texture TEX by projecting and mapping the texture TEX onto the course object OB2 by the method described above. The illuminated area and other areas are defined by the area designation parameter LT. As the region designation parameter LT, LT = 1-L is set for a region where the texture TEX is projected and mapped, and LT = 1 is fixedly set for other regions. That is, in the illuminated area S0, LT = 0 in the area where the illumination light of the vehicle object OB1 is strongly irradiated, and LT is 0 <LT toward the area where the illumination is not illuminated (area where LT = 1). It changes continuously in the range of <1.

このように被照明領域S0とそれ以外の領域が設定されたコースオブジェクトOB2を描画する際に、オブジェクトデータに基づき得られる色RGB(m)を、以下のような調整式(1)により調整してコースオブジェクトOB2の色RGB(o)を設定する。このような調整をすることによって、例えば、図12に示すような仮想カメラVC1から見える視界画像が生成される。なお「オブジェクトデータに基づき得られる色RGB(m)」は、オブジェクトの頂点色であってもよいし、オブジェクトにテクスチャマッピングされるデカールテクスチャのテクセルの色であってもよいし、頂点色とデカールテクスチャのテクセルの色との乗算結果であってもよい。   Thus, when drawing the course object OB2 in which the illuminated area S0 and other areas are set, the color RGB (m) obtained based on the object data is adjusted by the following adjustment formula (1). The color RGB (o) of the course object OB2 is set. By performing such adjustment, for example, a view field image that can be seen from the virtual camera VC1 as shown in FIG. 12 is generated. The “color RGB (m) obtained based on the object data” may be the vertex color of the object, the texel color of the decal texture mapped to the object, or the vertex color and the decal. The result may be a multiplication result of the texture texel color.

RGB(o)=RGB(m)*(A*(1−LT)+(1−A)) (1)
具体的には、各領域S0〜S2については、以下のような色に調整される。
RGB (o) = RGB (m) * (A * (1-LT) + (1-A)) (1)
Specifically, the areas S0 to S2 are adjusted to the following colors.

まず図11に示す被照明領域S0のLT=0の領域(OB1からの照明光が強く当たっている領域)については、RGB(o)=RGB(m)となり、コースオブジェクトOB2のオブジェクトデータに基づき得られる色がその領域を描画するための色として設定される。   First, for the area of LT = 0 in the illuminated area S0 shown in FIG. 11 (area where the illumination light from OB1 is strongly irradiated), RGB (o) = RGB (m), which is based on the object data of the course object OB2. The obtained color is set as a color for drawing the area.

また図11に示す被照明領域S0の0<LT<1の領域(OB1からの照明光が徐々に減衰していく領域)については、RGB(o)=RGB(m)*(1−A*LT)となり、コースオブジェクトOB2のオブジェクトデータに基づき得られる色を、コースオブジェクトOB2の頂点毎に設定しておいた影響度パラメータA(α値)とテクスチャTEXの投影マッピングにより設定した領域指定パラメータLT(=1−L)との乗算値に応じて暗くした色(輝度を下げた色)がその領域を描画するための色として設定される。   Further, for the region of 0 <LT <1 in the illuminated region S0 shown in FIG. 11 (region where the illumination light from OB1 gradually attenuates), RGB (o) = RGB (m) * (1-A * LT), and the color obtained based on the object data of the course object OB2 is an area designation parameter LT set by the projection mapping of the influence parameter A (α value) set for each vertex of the course object OB2 and the texture TEX. A darkened color (a color with reduced brightness) is set as a color for drawing the area in accordance with a multiplication value of (= 1−L).

また図11に示す領域S1、S2のうちLT=1の領域(被照明領域S0以外の領域、OB1からの照明光を受けていない領域))については、RGB(o)=RGB(m)*(1−A)となり、コースオブジェクトOB2のオブジェクトデータに基づき得られる色を、コースオブジェクトOB2の頂点毎に設定しておいた影響度パラメータA(α値)に応じて暗くした色(輝度を下げた色)がその領域を描画するための色として設定される。   Further, among the regions S1 and S2 shown in FIG. 11, the region of LT = 1 (the region other than the illuminated region S0, the region not receiving illumination light from OB1) is RGB (o) = RGB (m) *. (1-A), and the color obtained based on the object data of the course object OB2 is darkened according to the influence parameter A (α value) set for each vertex of the course object OB2 (the brightness is lowered) Color) is set as a color for drawing the area.

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

まず車両オブジェクトOB1の位置を演算する(ステップS10)。これにより車両オブジェクトOB1に設定される仮想カメラVC2の投影中心の位置が決定される。   First, the position of the vehicle object OB1 is calculated (step S10). Thereby, the position of the projection center of the virtual camera VC2 set to the vehicle object OB1 is determined.

次に、車両オブジェクトの種類に応じた射影マトリクスPを用いて投影マッピング用の変換マトリクスmを演算する(ステップS11)。そして投影マッピングの対象となるコースオブジェクトOB2のオブジェクトデータを読み出す(ステップS12)。このオブジェクトデータには、頂点座標、頂点色、頂点α値、デカールテクスチャのテクスチャ座標などが含まれている。頂点色は、車両オブジェクトOB1からの照明光を反映させた色が設定される。頂点α値には、車両オブジェクトOB1からの照明光に対する影響度パラメータが設定される。デカールテクスチャは、上記実施形態の例では、線路のレールや枕木を表現した画像である。   Next, a conversion matrix m for projection mapping is calculated using the projection matrix P corresponding to the type of vehicle object (step S11). Then, the object data of the course object OB2 that is the target of projection mapping is read (step S12). This object data includes vertex coordinates, vertex colors, vertex α values, decal texture texture coordinates, and the like. As the vertex color, a color reflecting illumination light from the vehicle object OB1 is set. In the vertex α value, an influence parameter for illumination light from the vehicle object OB1 is set. In the example of the above embodiment, the decal texture is an image representing rails of railroad tracks or sleepers.

次に、コースオブジェクトOB2のオブジェクトデータから得た頂点座標をステップS11で求めた変換マトリクスmを用いて投影マッピング用のテクスチャ座標に変換する(ステップS13)。なおステップS13で行うマトリクス変換は、描画プロセッサの頂点シェーダ(頂点処理ユニット)により行われる。なおステップS13で行うマトリクス変換は、描画プロセッサのピクセルシェーダ(ピクセル処理ユニット)で行わせるようにしてもよい。   Next, the vertex coordinates obtained from the object data of the course object OB2 are converted into texture coordinates for projection mapping using the conversion matrix m obtained in step S11 (step S13). Note that the matrix conversion performed in step S13 is performed by a vertex shader (vertex processing unit) of the drawing processor. The matrix conversion performed in step S13 may be performed by a pixel shader (pixel processing unit) of the drawing processor.

続いて、テクスチャ座標に基づいてテクスチャデータ(テクセル値)をサンプリングしてコースオブジェクトOB2に対して照明パターンを設定したテクスチャTEXを投影マッピングして被照明領域を設定する(ステップS14)。   Subsequently, the texture data (texel value) is sampled based on the texture coordinates, and the texture TEX in which the illumination pattern is set on the course object OB2 is projected and mapped to set the illuminated area (step S14).

そして被照明領域の設定情報である領域指定パラメータ(LT=1−L)とオブジェクトデータから得た影響度パラメータ(A)に応じてコースオブジェクトOB2の各領域(被照明領域とそれ以外の領域)の色を決定する(ステップS15)。例えば、被照明領域についてはコースオブジェクトOB2のオブジェクトデータに基づき得られる色をそのまま、あるいは領域指定パラメータに応じて減色して、その領域を描画するための色として設定し、被照明領域以外の領域については、影響度パラメータに応じて減色して、その領域を描画するための色として設定する。なおステップS14で行うテクスチャデータのサンプリングやステップS15で行うオブジェクトの描画色の決定は、描画プロセッサのピクセルシェーダ(ピクセル処理ユニット)により行われる。   And each area (illuminated area and other areas) of the course object OB2 according to the area designation parameter (LT = 1-L) which is the setting information of the illuminated area and the influence parameter (A) obtained from the object data Is determined (step S15). For example, for the illuminated area, the color obtained based on the object data of the course object OB2 is set as it is as the color for drawing the area as it is or by reducing the color according to the area designation parameter. Is reduced according to the influence parameter and set as a color for drawing the area. The sampling of texture data performed in step S14 and the drawing color of the object performed in step S15 are performed by a pixel shader (pixel processing unit) of the rendering processor.

最終的には、求めた色データ(RGBの各色成分の輝度値データ)と位置データ(座標データ)とに基づいて、コースオブジェクトOB2を描画する(ステップS16)。   Finally, the course object OB2 is drawn based on the obtained color data (luminance value data of each color component of RGB) and position data (coordinate data) (step S16).

4.ハードウェア構成
図14に本実施形態を実現できるハードウェア構成の例を示す。メインプロセッサ900は、DVD982(情報記憶媒体。CDでもよい。)に格納されたプログラム、通信インターフェース990を介してダウンロードされたプログラム、或いはROM950に格納されたプログラムなどに基づき動作し、ゲーム処理、画像処理、音処理などを実行する。コプロセッサ902は、メインプロセッサ900の処理を補助するものであり、マトリクス演算(ベクトル演算)を高速に実行する。例えばオブジェクトを移動させたり動作(モーション)させる物理シミュレーションに、マトリクス演算処理が必要な場合には、メインプロセッサ900上で動作するプログラムが、その処理をコプロセッサ902に指示(依頼)する。
4). Hardware Configuration FIG. 14 shows an example of a hardware configuration capable of realizing this embodiment. The main processor 900 operates based on a program stored in a DVD 982 (information storage medium, which may be a CD), a program downloaded via the communication interface 990, a program stored in the ROM 950, or the like. Perform processing, sound processing, etc. 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 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 a programmable shader such as a vertex shader or a pixel shader is installed, the vertex data is created / changed (updated) and the drawing color of a pixel (or fragment) is determined according to the shader program. 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転送を制御する。DVDドライブ980(CDドライブでもよい。)は、プログラム、画像データ、或いは音データなどが格納されるDVD982(CDでもよい。)にアクセスする。通信インターフェース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 DVD drive 980 (may be a CD drive) accesses a DVD 982 (may be a CD) 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).

なお本実施形態の各部(各手段)の処理は、その全てをハードウェアのみにより実現してもよいし、情報記憶媒体に格納されるプログラムや通信インターフェースを介して配信されるプログラムにより実現してもよい。或いは、ハードウェアとプログラムの両方により実現してもよい。   The processing of each unit (each unit) in this 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. Also good. 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 part of this embodiment is realized by both hardware and a program, a program for causing the hardware (computer) to function as each part of this 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.

なお本発明は、上記実施形態で説明したものに限らず、種々の変形実施が可能である。例えば、明細書又は図面中の記載において広義や同義な用語として引用された用語は、明細書又は図面中の他の記載においても広義や同義な用語に置き換えることができる。また接触痕跡の表現手法も、本実施形態で説明したものに限定されず、これらと均等な手法も本発明の範囲に含まれる。   The present invention is not limited to that described in the above embodiment, and various modifications can be made. For example, terms cited as broad or synonymous terms in the description in the specification or drawings can be replaced with broad or synonymous terms in other descriptions in the specification or drawings. Further, the method of expressing the contact trace is not limited to that described in the present embodiment, and a method equivalent to these is also included in the scope of the present invention.

また上記実施形態では、コースオブジェクトに移動照明源からの照明光を反映させる例を説明したが、例えば、コースオブジェクト以外の背景オブジェクトに対して同様の照明処理を行うようにしてもよい。また照明対象オブジェクトはオブジェクト空間に固定的に配置される固定物オブジェクトに限られず、オブジェクト空間内を移動する移動体オブジェクトであってもよい。   Moreover, although the example which reflects the illumination light from a moving illumination source on a course object was demonstrated in the said embodiment, you may make it perform the same illumination process with respect to background objects other than a course object, for example. The illumination target object is not limited to a fixed object that is fixedly arranged in the object space, and may be a moving object that moves in the object space.

また上記実施形態では、コースオブジェクトのオブジェクトデータに移動照明源からの照明を受けた場合の明るい色を予め設定して、被照明領域以外の領域をオブジェクトデータに予め設定した影響度に応じて色を暗くするという照明処理の手法を採用していたが、コースオブジェクトのオブジェクトデータに移動照明源からの照明を受けていない場合の暗い色を予め設定して、被照明領域をオブジェクトデータに予め設定した影響度に応じて色を明るくするようにしてもよい。またコースオブジェクトのオブジェクトデータに移動照明源からの照明を受けた場合の明るい色とその照明を受けていない場合の暗い色との中間的な明るさの色を予め設定しておき、被照明領域についてはオブジェクトデータに予め設定した影響度に応じて色を明るくし、被照明領域以外の領域についてはオブジェクトデータに予め設定した影響に応じて色を暗くするように調整してもよい。   Further, in the above embodiment, a bright color when the illumination from the moving illumination source is received in the object data of the course object is set in advance, and the area other than the illuminated area is colored according to the influence degree set in advance in the object data. Although the lighting processing method was used to darken the object, the dark object color was set in advance in the object data of the course object, and the illuminated area was preset in the object data. The color may be brightened according to the degree of influence. In addition, in the object data of the course object, an intermediate brightness color between a bright color when receiving illumination from a moving illumination source and a dark color when not receiving the illumination is set in advance. The color may be adjusted to lighten according to the degree of influence set in advance in the object data, and the area other than the illuminated area may be adjusted to darken according to the influence set in advance in the object data.

また上記実施形態では電車の車両のライトが線路を照らす場合を例に説明したが、本実施形態の手法は、車のライトが道路や他の車を照らす場合などや、プレーヤキャラクタが装備した懐中電灯や松明で背景等が照らされる場合にも適用できる。また予め街灯などの他の照明源により背景等が照らされる場合、他の照明源が、オブジェクト空間内を移動するようなものであってもよく、この場合には、背景等に予め設定する影響度パラメータが動的に求められるような処理を行ってもよい。また、例えば車のライトによる照明を表現する場合、ロービームとハイビームとによって投影マッピング用の仮想カメラVC2の向き(視線方向)が変わるように変換マトリクスmを求めるようにしてもよい。   Further, in the above embodiment, the case where the train vehicle light illuminates the track has been described as an example. However, the method of this embodiment can be applied to the case where the car light illuminates a road or another vehicle, or the pocket that the player character is equipped with. It can also be applied when the background is illuminated by electric lights or torches. In addition, when the background or the like is illuminated in advance by another illumination source such as a streetlight, the other illumination source may be moved in the object space. Processing in which the degree parameter is dynamically obtained may be performed. For example, when expressing illumination by a car light, the conversion matrix m may be obtained so that the direction (line-of-sight direction) of the virtual camera VC2 for projection mapping changes depending on the low beam and the high beam.

また本発明は種々のゲーム(レーシングゲーム、格闘ゲーム、シューティングゲーム、ロボット対戦ゲーム、スポーツゲーム、競争ゲーム、ロールプレイングゲーム、音楽演奏ゲーム、ダンスゲーム等)に適用できる。また本発明は、業務用ゲームシステム、家庭用ゲームシステム、多数のプレーヤが参加する大型アトラクションシステム、シミュレータ、マルチメディア端末、ゲーム画像を生成するシステムボード、携帯電話等の種々の画像生成システムに適用できる。   The present invention can be applied to various games (racing game, fighting game, shooting game, robot battle game, sports game, competition game, role playing game, music playing game, dance game, etc.). 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 a game image, and a mobile phone. it can.

本実施形態の画像生成システムの機能ブロック図。The functional block diagram of the image generation system of this embodiment. 本実施形態の手法を説明するための図。The figure for demonstrating the method of this embodiment. 本実施形態の手法で用いられるテクスチャ画像。A texture image used in the method of this embodiment. 本実施形態の手法で用いられるテクスチャ画像の説明図。Explanatory drawing of the texture image used with the method of this embodiment. 本実施形態の手法を説明するための図。The figure for demonstrating the method of this embodiment. 本実施形態の手法を説明するための図。The figure for demonstrating the method of this embodiment. 本実施形態の手法で用いられるオブジェクトデータの説明図。Explanatory drawing of the object data used with the method of this embodiment. 本実施形態の手法で用いられるオブジェクトデータの説明図。Explanatory drawing of the object data used with the method of this embodiment. 本実施形態の手法で用いられるオブジェクトデータの説明図。Explanatory drawing of the object data used with the method of this embodiment. 本実施形態の手法を説明するための図。The figure for demonstrating the method of this embodiment. 本実施形態の手法を説明するための図。The figure for demonstrating the method of this embodiment. 本実施形態の手法を用いて描かれた画像。The image drawn using the method of this embodiment. 本実施形態の処理の例を示すフローチャート。The flowchart which shows the example of the process of this embodiment. ハードウェア構成の例。An example of a hardware configuration.

符号の説明Explanation of symbols

OB1 車両オブジェクト(照明源オブジェクト、移動体オブジェクト)、
OB2 コースオブジェクト(照明対象オブジェクト)、
100 処理部、110 オブジェクト空間設定部、112 移動・動作処理部、
114 仮想カメラ制御部、120 描画部、122 テクスチャ座標演算部、
124 照明処理部、160 操作部、170 記憶部、172 主記憶部、
174 描画バッファ、176 オブジェクトデータ記憶部、
178 テクスチャ記憶部、180 情報記憶媒体、190 表示部、
192 音出力部、194 携帯型情報記憶装置、196 通信部、
OB1 vehicle object (light source object, moving object),
OB2 Course object (lighting object),
100 processing unit, 110 object space setting unit, 112 movement / motion processing unit,
114 virtual camera control unit, 120 drawing unit, 122 texture coordinate calculation unit,
124 Illumination processing unit, 160 operation unit, 170 storage unit, 172 main storage unit,
174 Drawing buffer, 176 Object data storage unit,
178 texture storage unit, 180 information storage medium, 190 display unit,
192 sound output unit, 194 portable information storage device, 196 communication unit,

Claims (13)

オブジェクト空間を所与の視点から見た画像を生成するためのプログラムであって、A program for generating an image of an object space viewed from a given viewpoint,
前記オブジェクト空間内を移動する照明源となる移動体オブジェクトのオブジェクトデータと、移動体オブジェクトから照明を受ける照明対象オブジェクトのオブジェクトデータとを記憶するオブジェクトデータ記憶部と、An object data storage unit that stores object data of a moving object that is an illumination source that moves in the object space, and object data of an illumination target object that receives illumination from the moving object;
前記移動体オブジェクト及び前記照明対象オブジェクトを前記オブジェクト空間に対して設定するオブジェクト空間設定部と、An object space setting unit for setting the moving object and the illumination target object with respect to the object space;
前記移動体オブジェクトから照射される照明光の照明パターンを設定した照明パターンテクスチャを記憶するテクスチャ記憶部と、A texture storage unit for storing an illumination pattern texture in which an illumination pattern of illumination light emitted from the moving object is set;
前記移動体オブジェクトに対して設定した投影中心からの前記照明光の広がりを表す射影マトリクスを用いて、前記照明対象オブジェクトのオブジェクトデータに含まれる頂点座標に対応する前記照明パターンテクスチャ用のテクスチャ座標を演算するテクスチャ座標演算部と、Using a projection matrix that represents the spread of the illumination light from the projection center set for the moving object, texture coordinates for the illumination pattern texture corresponding to vertex coordinates included in the object data of the illumination target object are obtained. A texture coordinate calculation unit to be calculated;
求められたテクスチャ座標に基づいて、前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定する被照明領域設定部と、Based on the obtained texture coordinates, the illumination pattern texture is texture-mapped to the illumination target object, and an illuminated area setting unit that sets an illumination area for the illumination target object;
前記被照明領域の設定情報に基づいて、前記照明対象オブジェクトに対して前記照明光を反映させる照明処理を行う照明処理部として、As an illumination processing unit that performs illumination processing that reflects the illumination light on the illumination target object based on the setting information of the illuminated area,
コンピュータを機能させ、Make the computer work,
前記オブジェクトデータ記憶部が、The object data storage unit
複数種類の移動体オブジェクトのオブジェクトデータを記憶し、Stores object data of multiple types of mobile objects,
前記オブジェクト空間設定部が、The object space setting unit
前記複数種類の移動体オブジェクトのうち1種類以上を前記オブジェクト空間に設定し、One or more types of the plurality of types of moving objects are set in the object space,
前記テクスチャ座標演算部が、The texture coordinate calculation unit is
前記移動体オブジェクトの種類に応じて異なる射影マトリクスを用いて前記テクスチャ座標を演算し、The texture coordinates are calculated using a different projection matrix depending on the type of the moving object,
前記被照明領域設定部が、The illuminated area setting unit includes:
求められたテクスチャ座標に基づいて、前記移動体オブジェクトの種類に応じた被照明領域を前記照明対象オブジェクトに対して設定することを特徴とするプログラム。A program for setting an illuminated area corresponding to a type of the moving object for the illumination target object based on the obtained texture coordinates.
オブジェクト空間を所与の視点から見た画像を生成するためのプログラムであって、A program for generating an image of an object space viewed from a given viewpoint,
前記オブジェクト空間内を移動する照明源となる移動体オブジェクトのオブジェクトデータと、移動体オブジェクトから照明を受ける照明対象オブジェクトのオブジェクトデータとを記憶するオブジェクトデータ記憶部と、An object data storage unit that stores object data of a moving object that is an illumination source that moves in the object space, and object data of an illumination target object that receives illumination from the moving object;
前記移動体オブジェクト及び前記照明対象オブジェクトを前記オブジェクト空間に対して設定するオブジェクト空間設定部と、An object space setting unit for setting the moving object and the illumination target object with respect to the object space;
前記移動体オブジェクトから照射される照明光の照明パターンを設定した照明パターンテクスチャを記憶するテクスチャ記憶部と、A texture storage unit for storing an illumination pattern texture in which an illumination pattern of illumination light emitted from the moving object is set;
前記移動体オブジェクトに対して設定した投影中心からの前記照明光の広がりを表す射影マトリクスを用いて、前記照明対象オブジェクトのオブジェクトデータに含まれる頂点座標に対応する前記照明パターンテクスチャ用のテクスチャ座標を演算するテクスチャ座標演算部と、Using a projection matrix that represents the spread of the illumination light from the projection center set for the moving object, texture coordinates for the illumination pattern texture corresponding to vertex coordinates included in the object data of the illumination target object are obtained. A texture coordinate calculation unit to be calculated;
求められたテクスチャ座標に基づいて、前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定する被照明領域設定部と、Based on the obtained texture coordinates, the illumination pattern texture is texture-mapped to the illumination target object, and an illuminated area setting unit that sets an illumination area for the illumination target object;
前記被照明領域の設定情報に基づいて、前記照明対象オブジェクトに対して前記照明光を反映させる照明処理を行う照明処理部として、As an illumination processing unit that performs illumination processing that reflects the illumination light on the illumination target object based on the setting information of the illuminated area,
コンピュータを機能させ、Make the computer work,
前記テクスチャ座標演算部が、The texture coordinate calculation unit is
前記オブジェクト空間で発生するイベントの種類に応じて異なる射影マトリクスを用いて前記テクスチャ座標を演算し、Calculating the texture coordinates using different projection matrices depending on the type of event occurring in the object space;
前記被照明領域設定部が、The illuminated area setting unit includes:
求められたテクスチャ座標に基づいて、前記イベントの種類に応じた被照明領域を前記照明対象オブジェクトに対して設定することを特徴とするプログラム。A program for setting an illuminated area corresponding to the type of event for the illumination target object based on the obtained texture coordinates.
オブジェクト空間を所与の視点から見た画像を生成するためのプログラムであって、A program for generating an image of an object space viewed from a given viewpoint,
前記オブジェクト空間内を移動する照明源となる移動体オブジェクトのオブジェクトデータと、移動体オブジェクトから照明を受ける照明対象オブジェクトのオブジェクトデータとを記憶するオブジェクトデータ記憶部と、An object data storage unit that stores object data of a moving object that is an illumination source that moves in the object space, and object data of an illumination target object that receives illumination from the moving object;
前記移動体オブジェクト及び前記照明対象オブジェクトを前記オブジェクト空間に対して設定するオブジェクト空間設定部と、An object space setting unit for setting the moving object and the illumination target object with respect to the object space;
前記移動体オブジェクトから照射される照明光の照明パターンを設定した照明パターンテクスチャを記憶するテクスチャ記憶部と、A texture storage unit for storing an illumination pattern texture in which an illumination pattern of illumination light emitted from the moving object is set;
前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定する被照明領域設定部と、An illuminated area setting unit configured to texture-map the illumination pattern texture to an illumination target object and set an illuminated area for the illumination target object;
前記被照明領域の設定情報に基づいて、前記照明対象オブジェクトに対して前記照明光を反映させる照明処理を行う照明処理部として、As an illumination processing unit that performs illumination processing that reflects the illumination light on the illumination target object based on the setting information of the illuminated area,
コンピュータを機能させ、Make the computer work,
前記オブジェクトデータ記憶部が、The object data storage unit
複数種類の移動体オブジェクトのオブジェクトデータを記憶し、Stores object data of multiple types of mobile objects,
前記オブジェクト空間設定部が、The object space setting unit
前記複数種類の移動体オブジェクトのうち1種類以上を前記オブジェクト空間に設定し、One or more types of the plurality of types of moving objects are set in the object space,
前記テクスチャ記憶部が、The texture storage unit
前記移動体オブジェクトの種類に応じて異なる複数の照明パターンテクスチャを記憶し、Storing a plurality of different illumination pattern textures depending on the type of the moving object,
前記被照明領域設定部が、The illuminated area setting unit includes:
前記移動体オブジェクトの種類に応じた照明パターンテクスチャを前記照明対象オブジェクトにテクスチャマッピングして前記移動体オブジェクトの種類に応じた被照明領域を設定することを特徴とするプログラム。A program characterized in that an illumination pattern texture corresponding to the type of the moving object is texture-mapped to the object to be illuminated and an illuminated area corresponding to the type of the moving object is set.
オブジェクト空間を所与の視点から見た画像を生成するためのプログラムであって、A program for generating an image of an object space viewed from a given viewpoint,
前記オブジェクト空間内を移動する照明源となる移動体オブジェクトのオブジェクトデータと、移動体オブジェクトから照明を受ける照明対象オブジェクトのオブジェクトデータとを記憶するオブジェクトデータ記憶部と、An object data storage unit that stores object data of a moving object that is an illumination source that moves in the object space, and object data of an illumination target object that receives illumination from the moving object;
前記移動体オブジェクト及び前記照明対象オブジェクトを前記オブジェクト空間に対して設定するオブジェクト空間設定部と、An object space setting unit for setting the moving object and the illumination target object with respect to the object space;
前記移動体オブジェクトから照射される照明光の照明パターンを設定した照明パターンテクスチャを記憶するテクスチャ記憶部と、A texture storage unit for storing an illumination pattern texture in which an illumination pattern of illumination light emitted from the moving object is set;
前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定する被照明領域設定部と、An illuminated area setting unit configured to texture-map the illumination pattern texture to an illumination target object and set an illuminated area for the illumination target object;
前記被照明領域の設定情報に基づいて、前記照明対象オブジェクトに対して前記照明光を反映させる照明処理を行う照明処理部として、As an illumination processing unit that performs illumination processing that reflects the illumination light on the illumination target object based on the setting information of the illuminated area,
コンピュータを機能させ、Make the computer work,
前記テクスチャ記憶部が、The texture storage unit
前記オブジェクト空間で発生するイベントの種類に応じて異なる複数の照明パターンテクスチャを記憶し、Storing a plurality of different illumination pattern textures depending on the type of event occurring in the object space;
前記被照明領域設定部が、The illuminated area setting unit includes:
前記イベントの種類に応じた照明パターンテクスチャを前記照明対象オブジェクトにテクスチャマッピングして前記イベントの種類に応じた被照明領域を前記照明対象オブジェクトに対して設定することを特徴とするプログラム。A program characterized in that an illumination pattern texture corresponding to the type of event is texture-mapped to the illumination target object, and an illuminated area corresponding to the event type is set for the illumination target object.
オブジェクト空間を所与の視点から見た画像を生成するためのプログラムであって、A program for generating an image of an object space viewed from a given viewpoint,
前記オブジェクト空間内を移動する照明源となる移動体オブジェクトのオブジェクトデータと、移動体オブジェクトから照明を受ける照明対象オブジェクトのオブジェクトデータとを記憶するオブジェクトデータ記憶部と、An object data storage unit that stores object data of a moving object that is an illumination source that moves in the object space, and object data of an illumination target object that receives illumination from the moving object;
前記移動体オブジェクト及び前記照明対象オブジェクトを前記オブジェクト空間に対して設定するオブジェクト空間設定部と、An object space setting unit for setting the moving object and the illumination target object with respect to the object space;
前記移動体オブジェクトから照射される照明光の照明パターンを設定した照明パターンテクスチャを記憶するテクスチャ記憶部と、A texture storage unit for storing an illumination pattern texture in which an illumination pattern of illumination light emitted from the moving object is set;
前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定する被照明領域設定部と、An illuminated area setting unit configured to texture-map the illumination pattern texture to an illumination target object and set an illuminated area for the illumination target object;
前記被照明領域の設定情報に基づいて、前記照明対象オブジェクトに対して前記照明光を反映させる照明処理を行う照明処理部として、As an illumination processing unit that performs illumination processing that reflects the illumination light on the illumination target object based on the setting information of the illuminated area,
コンピュータを機能させ、Make the computer work,
前記照明処理部が、The illumination processing unit
前記照明対象オブジェクトを構成する頂点に対して予め設定された前記照明光に対する影響度パラメータに基づいて、前記照明対象オブジェクトのオブジェクトデータに基づき得られる色を調整する処理を照明処理として行うことを特徴とするプログラム。A process of adjusting a color obtained based on object data of the illumination target object is performed as an illumination process based on an influence parameter with respect to the illumination light set in advance with respect to the vertex constituting the illumination target object. Program.
請求項3〜5のいずれかにおいて、In any one of Claims 3-5,
前記移動体オブジェクトに対して設定した投影中心からの前記照明光の広がりを表す射影マトリクスを用いて、前記照明対象オブジェクトのオブジェクトデータに含まれる頂点座標に対応する前記照明パターンテクスチャ用のテクスチャ座標を演算するテクスチャ座標演算部として、コンピュータを更に機能させ、Using a projection matrix that represents the spread of the illumination light from the projection center set for the moving object, texture coordinates for the illumination pattern texture corresponding to vertex coordinates included in the object data of the illumination target object are obtained. As a texture coordinate calculation unit to calculate, let the computer further function,
前記被照明領域設定部が、The illuminated area setting unit includes:
求められたテクスチャ座標に基づいて、前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定することを特徴とするプログラム。A program characterized in that, based on the obtained texture coordinates, the illumination pattern texture is texture-mapped to an illumination target object, and an illuminated area is set for the illumination target object.
コンピュータにより読取可能な情報記憶媒体であって、請求項1〜のいずれかに記載のプログラムを記憶することを特徴とする情報記憶媒体。 An information storage medium readable by a computer, wherein the program according to any one of claims 1 to 6 is stored. オブジェクト空間を所与の視点から見た画像を生成するための画像生成システムであって、An image generation system for generating an image of an object space viewed from a given viewpoint,
前記オブジェクト空間内を移動する照明源となる移動体オブジェクトのオブジェクトデータと、移動体オブジェクトから照明を受ける照明対象オブジェクトのオブジェクトデータとを記憶するオブジェクトデータ記憶部と、An object data storage unit that stores object data of a moving object that is an illumination source that moves in the object space, and object data of an illumination target object that receives illumination from the moving object;
前記移動体オブジェクト及び前記照明対象オブジェクトを前記オブジェクト空間に対して設定するオブジェクト空間設定部と、An object space setting unit for setting the moving object and the illumination target object with respect to the object space;
前記移動体オブジェクトから照射される照明光の照明パターンを設定した照明パターンテクスチャを記憶するテクスチャ記憶部と、A texture storage unit for storing an illumination pattern texture in which an illumination pattern of illumination light emitted from the moving object is set;
前記移動体オブジェクトに対して設定した投影中心からの前記照明光の広がりを表す射影マトリクスを用いて、前記照明対象オブジェクトのオブジェクトデータに含まれる頂点座標に対応する前記照明パターンテクスチャ用のテクスチャ座標を演算するテクスチャ座標演算部と、Using a projection matrix that represents the spread of the illumination light from the projection center set for the moving object, texture coordinates for the illumination pattern texture corresponding to vertex coordinates included in the object data of the illumination target object are obtained. A texture coordinate calculation unit to be calculated;
求められたテクスチャ座標に基づいて、前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定する被照明領域設定部と、Based on the obtained texture coordinates, the illumination pattern texture is texture-mapped to the illumination target object, and an illuminated area setting unit that sets an illumination area for the illumination target object;
前記被照明領域の設定情報に基づいて、前記照明対象オブジェクトに対して前記照明光を反映させる照明処理を行う照明処理部と、を含み、An illumination processing unit that performs illumination processing for reflecting the illumination light on the illumination target object based on the setting information of the illuminated area, and
前記オブジェクトデータ記憶部が、The object data storage unit
複数種類の移動体オブジェクトのオブジェクトデータを記憶し、Stores object data of multiple types of mobile objects,
前記オブジェクト空間設定部が、The object space setting unit
前記複数種類の移動体オブジェクトのうち1種類以上を前記オブジェクト空間に設定し、One or more types of the plurality of types of moving objects are set in the object space,
前記テクスチャ座標演算部が、The texture coordinate calculation unit is
前記移動体オブジェクトの種類に応じて異なる射影マトリクスを用いて前記テクスチャ座標を演算し、The texture coordinates are calculated using a different projection matrix depending on the type of the moving object,
前記被照明領域設定部が、The illuminated area setting unit includes:
求められたテクスチャ座標に基づいて、前記移動体オブジェクトの種類に応じた被照明領域を前記照明対象オブジェクトに対して設定することを特徴とする画像生成システム。An image generation system, wherein an illuminated area corresponding to a type of the moving object is set for the illumination target object based on the obtained texture coordinates.
オブジェクト空間を所与の視点から見た画像を生成するための画像生成システムであって、An image generation system for generating an image of an object space viewed from a given viewpoint,
前記オブジェクト空間内を移動する照明源となる移動体オブジェクトのオブジェクトデータと、移動体オブジェクトから照明を受ける照明対象オブジェクトのオブジェクトデータとを記憶するオブジェクトデータ記憶部と、An object data storage unit that stores object data of a moving object that is an illumination source that moves in the object space, and object data of an illumination target object that receives illumination from the moving object;
前記移動体オブジェクト及び前記照明対象オブジェクトを前記オブジェクト空間に対して設定するオブジェクト空間設定部と、An object space setting unit for setting the moving object and the illumination target object with respect to the object space;
前記移動体オブジェクトから照射される照明光の照明パターンを設定した照明パターンテクスチャを記憶するテクスチャ記憶部と、A texture storage unit for storing an illumination pattern texture in which an illumination pattern of illumination light emitted from the moving object is set;
前記移動体オブジェクトに対して設定した投影中心からの前記照明光の広がりを表す射影マトリクスを用いて、前記照明対象オブジェクトのオブジェクトデータに含まれる頂点座標に対応する前記照明パターンテクスチャ用のテクスチャ座標を演算するテクスチャ座標演算部と、Using a projection matrix that represents the spread of the illumination light from the projection center set for the moving object, texture coordinates for the illumination pattern texture corresponding to vertex coordinates included in the object data of the illumination target object are obtained. A texture coordinate calculation unit to be calculated;
求められたテクスチャ座標に基づいて、前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定する被照明領域設定部と、Based on the obtained texture coordinates, the illumination pattern texture is texture-mapped to the illumination target object, and an illuminated area setting unit that sets an illumination area for the illumination target object;
前記被照明領域の設定情報に基づいて、前記照明対象オブジェクトに対して前記照明光を反映させる照明処理を行う照明処理部と、を含み、An illumination processing unit that performs illumination processing for reflecting the illumination light on the illumination target object based on the setting information of the illuminated area, and
前記テクスチャ座標演算部が、The texture coordinate calculation unit is
前記オブジェクト空間で発生するイベントの種類に応じて異なる射影マトリクスを用いて前記テクスチャ座標を演算し、Calculating the texture coordinates using different projection matrices depending on the type of event occurring in the object space;
前記被照明領域設定部が、The illuminated area setting unit includes:
求められたテクスチャ座標に基づいて、前記イベントの種類に応じた被照明領域を前記照明対象オブジェクトに対して設定することを特徴とする画像生成システム。An image generation system, wherein an illuminated region corresponding to the type of event is set for the illumination target object based on the obtained texture coordinates.
オブジェクト空間を所与の視点から見た画像を生成するための画像生成システムであって、An image generation system for generating an image of an object space viewed from a given viewpoint,
前記オブジェクト空間内を移動する照明源となる移動体オブジェクトのオブジェクトデータと、移動体オブジェクトから照明を受ける照明対象オブジェクトのオブジェクトデータとを記憶するオブジェクトデータ記憶部と、An object data storage unit that stores object data of a moving object that is an illumination source that moves in the object space, and object data of an illumination target object that receives illumination from the moving object;
前記移動体オブジェクト及び前記照明対象オブジェクトを前記オブジェクト空間に対して設定するオブジェクト空間設定部と、An object space setting unit for setting the moving object and the illumination target object with respect to the object space;
前記移動体オブジェクトから照射される照明光の照明パターンを設定した照明パターンテクスチャを記憶するテクスチャ記憶部と、A texture storage unit for storing an illumination pattern texture in which an illumination pattern of illumination light emitted from the moving object is set;
前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定する被照明領域設定部と、An illuminated area setting unit configured to texture-map the illumination pattern texture to an illumination target object and set an illuminated area for the illumination target object;
前記被照明領域の設定情報に基づいて、前記照明対象オブジェクトに対して前記照明光を反映させる照明処理を行う照明処理部と、を含み、An illumination processing unit that performs illumination processing for reflecting the illumination light on the illumination target object based on the setting information of the illuminated area, and
前記オブジェクトデータ記憶部が、The object data storage unit
複数種類の移動体オブジェクトのオブジェクトデータを記憶し、Stores object data of multiple types of mobile objects,
前記オブジェクト空間設定部が、The object space setting unit
前記複数種類の移動体オブジェクトのうち1種類以上を前記オブジェクト空間に設定し、One or more types of the plurality of types of moving objects are set in the object space,
前記テクスチャ記憶部が、The texture storage unit
前記移動体オブジェクトの種類に応じて異なる複数の照明パターンテクスチャを記憶し、Storing a plurality of different illumination pattern textures depending on the type of the moving object,
前記被照明領域設定部が、The illuminated area setting unit includes:
前記移動体オブジェクトの種類に応じた照明パターンテクスチャを前記照明対象オブジェクトにテクスチャマッピングして前記移動体オブジェクトの種類に応じた被照明領域を設定することを特徴とする画像生成システム。An image generation system characterized in that an illumination pattern texture corresponding to a type of the moving object is texture-mapped to the object to be illuminated, and an illuminated area corresponding to the type of the moving object is set.
オブジェクト空間を所与の視点から見た画像を生成するための画像生成システムであって、An image generation system for generating an image of an object space viewed from a given viewpoint,
前記オブジェクト空間内を移動する照明源となる移動体オブジェクトのオブジェクトデータと、移動体オブジェクトから照明を受ける照明対象オブジェクトのオブジェクトデータとを記憶するオブジェクトデータ記憶部と、An object data storage unit that stores object data of a moving object that is an illumination source that moves in the object space, and object data of an illumination target object that receives illumination from the moving object;
前記移動体オブジェクト及び前記照明対象オブジェクトを前記オブジェクト空間に対して設定するオブジェクト空間設定部と、An object space setting unit for setting the moving object and the illumination target object with respect to the object space;
前記移動体オブジェクトから照射される照明光の照明パターンを設定した照明パターンテクスチャを記憶するテクスチャ記憶部と、A texture storage unit for storing an illumination pattern texture in which an illumination pattern of illumination light emitted from the moving object is set;
前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定する被照明領域設定部と、An illuminated area setting unit configured to texture-map the illumination pattern texture to an illumination target object and set an illuminated area for the illumination target object;
前記被照明領域の設定情報に基づいて、前記照明対象オブジェクトに対して前記照明光を反映させる照明処理を行う照明処理部と、を含み、An illumination processing unit that performs illumination processing for reflecting the illumination light on the illumination target object based on the setting information of the illuminated area, and
前記テクスチャ記憶部が、The texture storage unit
前記オブジェクト空間で発生するイベントの種類に応じて異なる複数の照明パターンテクスチャを記憶し、Storing a plurality of different illumination pattern textures depending on the type of event occurring in the object space;
前記被照明領域設定部が、The illuminated area setting unit includes:
前記イベントの種類に応じた照明パターンテクスチャを前記照明対象オブジェクトにテクスチャマッピングして前記イベントの種類に応じた被照明領域を前記照明対象オブジェクトに対して設定することを特徴とする画像生成システム。An image generation system characterized in that an illumination pattern texture corresponding to the event type is texture-mapped to the illumination target object, and an illuminated area corresponding to the event type is set for the illumination target object.
オブジェクト空間を所与の視点から見た画像を生成するための画像生成システムであって、An image generation system for generating an image of an object space viewed from a given viewpoint,
前記オブジェクト空間内を移動する照明源となる移動体オブジェクトのオブジェクトデータと、移動体オブジェクトから照明を受ける照明対象オブジェクトのオブジェクトデータとを記憶するオブジェクトデータ記憶部と、An object data storage unit that stores object data of a moving object that is an illumination source that moves in the object space, and object data of an illumination target object that receives illumination from the moving object;
前記移動体オブジェクト及び前記照明対象オブジェクトを前記オブジェクト空間に対して設定するオブジェクト空間設定部と、An object space setting unit for setting the moving object and the illumination target object with respect to the object space;
前記移動体オブジェクトから照射される照明光の照明パターンを設定した照明パターンテクスチャを記憶するテクスチャ記憶部と、A texture storage unit for storing an illumination pattern texture in which an illumination pattern of illumination light emitted from the moving object is set;
前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定する被照明領域設定部と、An illuminated area setting unit configured to texture-map the illumination pattern texture to an illumination target object and set an illuminated area for the illumination target object;
前記被照明領域の設定情報に基づいて、前記照明対象オブジェクトに対して前記照明光を反映させる照明処理を行う照明処理部と、を含み、An illumination processing unit that performs illumination processing for reflecting the illumination light on the illumination target object based on the setting information of the illuminated area, and
前記照明処理部が、The illumination processing unit
前記照明対象オブジェクトを構成する頂点に対して予め設定された前記照明光に対する影響度パラメータに基づいて、前記照明対象オブジェクトのオブジェクトデータに基づき得られる色を調整する処理を照明処理として行うことを特徴とする画像生成システム。A process of adjusting a color obtained based on object data of the illumination target object is performed as an illumination process based on an influence parameter with respect to the illumination light set in advance with respect to the vertex constituting the illumination target object. An image generation system.
請求項10〜12のいずれかにおいて、In any one of Claims 10-12,
前記移動体オブジェクトに対して設定した投影中心からの前記照明光の広がりを表す射影マトリクスを用いて、前記照明対象オブジェクトのオブジェクトデータに含まれる頂点座標に対応する前記照明パターンテクスチャ用のテクスチャ座標を演算するテクスチャ座標演算部を更に含み、Using a projection matrix that represents the spread of the illumination light from the projection center set for the moving object, texture coordinates for the illumination pattern texture corresponding to vertex coordinates included in the object data of the illumination target object are obtained. It further includes a texture coordinate calculation unit for calculating,
前記被照明領域設定部が、The illuminated area setting unit includes:
求められたテクスチャ座標に基づいて、前記照明パターンテクスチャを照明対象オブジェクトにテクスチャマッピングして前記照明対象オブジェクトに対して被照明領域を設定することを特徴とする画像生成システム。An image generation system, wherein the illumination pattern texture is texture-mapped to an illumination target object based on the obtained texture coordinates, and an illuminated area is set for the illumination target object.
JP2005336048A 2005-11-21 2005-11-21 Program, information storage medium, and image generation system Active JP4749131B2 (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2005336048A JP4749131B2 (en) 2005-11-21 2005-11-21 Program, information storage medium, and image generation system

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2005336048A JP4749131B2 (en) 2005-11-21 2005-11-21 Program, information storage medium, and image generation system

Publications (2)

Publication Number Publication Date
JP2007141080A JP2007141080A (en) 2007-06-07
JP4749131B2 true JP4749131B2 (en) 2011-08-17

Family

ID=38203839

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2005336048A Active JP4749131B2 (en) 2005-11-21 2005-11-21 Program, information storage medium, and image generation system

Country Status (1)

Country Link
JP (1) JP4749131B2 (en)

Family Cites Families (2)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JPH0757117A (en) * 1993-07-09 1995-03-03 Silicon Graphics Inc Forming method of index to texture map and computer control display system
JP3720890B2 (en) * 1995-12-12 2005-11-30 株式会社ルネサステクノロジ Image generation device

Also Published As

Publication number Publication date
JP2007141080A (en) 2007-06-07

Similar Documents

Publication Publication Date Title
JP4804122B2 (en) Program, texture data structure, information storage medium, and image generation system
US7479961B2 (en) Program, information storage medium, and image generation system
JP4651527B2 (en) Program, information storage medium, and image generation system
JP2001070633A (en) Image forming system and information recording medium
JP4824514B2 (en) Program, information storage medium, and image generation system
JP3280355B2 (en) Image generation system and information storage medium
JP2008027064A (en) Program, information recording medium, and image forming system
JP2007226572A (en) Program, information storage medium and image creation system
JP4743770B2 (en) Image generation system, program, and information storage medium
JP4754384B2 (en) Program, information recording medium, and image generation system
JP4827250B2 (en) Program, information storage medium, and image generation system
JP2006252426A (en) Program, information storage medium, and image generation system
JP4688648B2 (en) Program, information storage medium, and image generation system
US7710419B2 (en) Program, information storage medium, and image generation system
JP4861862B2 (en) Program, information storage medium, and image generation system
JP4528008B2 (en) Program, information storage medium, and image generation system
JP4488346B2 (en) Program, information storage medium, and image generation system
JP4632855B2 (en) Program, information storage medium, and image generation system
JP4749131B2 (en) Program, information storage medium, and image generation system
JP4574058B2 (en) Image generation system, program, and information storage medium
JP4592087B2 (en) Image generation system, program, and information storage medium
US7724255B2 (en) Program, information storage medium, and image generation system
JP4754385B2 (en) Program, information recording medium, and image generation system
JP4394211B2 (en) Image generation system and information storage medium
JP4782583B2 (en) Program, information storage medium, and image generation system

Legal Events

Date Code Title Description
A621 Written request for application examination

Free format text: JAPANESE INTERMEDIATE CODE: A621

Effective date: 20080825

A977 Report on retrieval

Free format text: JAPANESE INTERMEDIATE CODE: A971007

Effective date: 20101129

A131 Notification of reasons for refusal

Free format text: JAPANESE INTERMEDIATE CODE: A131

Effective date: 20101208

A521 Request for written amendment filed

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20110207

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: 20110511

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: 20110517

R150 Certificate of patent or registration of utility model

Ref document number: 4749131

Country of ref document: JP

Free format text: JAPANESE INTERMEDIATE CODE: R150

Free format text: JAPANESE INTERMEDIATE CODE: R150

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

Free format text: PAYMENT UNTIL: 20140527

Year of fee payment: 3

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

Free format text: PAYMENT UNTIL: 20140527

Year of fee payment: 3

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

S531 Written request for registration of change of domicile

Free format text: JAPANESE INTERMEDIATE CODE: R313531

S533 Written request for registration of change of name

Free format text: JAPANESE INTERMEDIATE CODE: R313533

R360 Written notification for declining of transfer of rights

Free format text: JAPANESE INTERMEDIATE CODE: R360

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R370 Written measure of declining of transfer procedure

Free format text: JAPANESE INTERMEDIATE CODE: R370

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

S531 Written request for registration of change of domicile

Free format text: JAPANESE INTERMEDIATE CODE: R313531

R350 Written notification of registration of transfer

Free format text: JAPANESE INTERMEDIATE CODE: R350

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250

R250 Receipt of annual fees

Free format text: JAPANESE INTERMEDIATE CODE: R250