[go: up one dir, main page]

JP2013061898A - Program, information storage medium, image generation device, and server - Google Patents

Program, information storage medium, image generation device, and server Download PDF

Info

Publication number
JP2013061898A
JP2013061898A JP2011201389A JP2011201389A JP2013061898A JP 2013061898 A JP2013061898 A JP 2013061898A JP 2011201389 A JP2011201389 A JP 2011201389A JP 2011201389 A JP2011201389 A JP 2011201389A JP 2013061898 A JP2013061898 A JP 2013061898A
Authority
JP
Japan
Prior art keywords
image
pixel
information
primitive
processing
Prior art date
Legal status (The legal status is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the status listed.)
Withdrawn
Application number
JP2011201389A
Other languages
Japanese (ja)
Inventor
Hiroyuki Muta
廣之 無田
Motohisa Ishii
源久 石井
Current Assignee (The listed assignees may be inaccurate. Google has not performed a legal analysis and makes no representation or warranty as to the accuracy of the list.)
Bandai Namco Entertainment Inc
Original Assignee
Namco Bandai Games Inc
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Namco Bandai Games Inc filed Critical Namco Bandai Games Inc
Priority to JP2011201389A priority Critical patent/JP2013061898A/en
Publication of JP2013061898A publication Critical patent/JP2013061898A/en
Withdrawn legal-status Critical Current

Links

Images

Landscapes

  • Processing Or Creating Images (AREA)
  • Image Generation (AREA)

Abstract

【課題】少ない処理負荷で、違和感の少ない立体視画像を生成することが可能なプログラム、情報記憶媒体、画像生成装置及びサーバを提供すること。
【解決手段】第1の画像と第2の画像に基づき、立体視画像を生成する処理を行う場合に、第1の画像生成部が、スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの情報を記憶させる処理を行い、第2の画像生成部が、ピクセル処理前に、第2の画像の画素毎に、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、前記ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う。
【選択図】図14
An object of the present invention is to provide a program, an information storage medium, an image generation device, and a server capable of generating a stereoscopic image with a small processing load and less discomfort.
When performing processing for generating a stereoscopic image based on a first image and a second image, a first image generation unit applies the first image to each pixel of a specific buffer corresponding to a screen. Process for storing the information of the foremost primitive to the virtual camera of the second camera, and the second image generation unit can divert from the first image for each pixel of the second image before pixel processing A process for determining whether or not image information of a pixel exists is performed. When there is image information of a divertable pixel from the first image, instead of the pixel processing, the pixel information of the first image A process of diverting the image information to the image information of the pixels of the second image is performed.
[Selection] Figure 14

Description

本発明は、プログラム、情報記憶媒体、画像生成装置及びサーバに関する。   The present invention relates to a program, an information storage medium, an image generation device, and a server.

従来から、立体視を実現する画像生成装置が知られている(例えば、特許文献1)。例えば、2眼式の画像生成システムでは、左眼用画像と右眼用画像を生成する。そして、立体視用の眼鏡や、視差バリア或いはレンチキュラ等の光学素子を用いて、観察者の左眼には左眼用画像のみが見え、右眼には右眼用画像のみが見えるようにすることで、立体視を実現する。また、N眼式の画像生成装置では、N個の異なる視点における画像から立体視画像を生成する。   2. Description of the Related Art Conventionally, an image generation apparatus that realizes stereoscopic viewing is known (for example, Patent Document 1). For example, in a twin-lens image generation system, a left-eye image and a right-eye image are generated. Then, using stereoscopic glasses or an optical element such as a parallax barrier or lenticular, the left eye of the observer can only see the image for the left eye, and the right eye can see only the image for the right eye. In this way, stereoscopic viewing is realized. In addition, the N-eye image generation apparatus generates a stereoscopic image from images at N different viewpoints.

例えば、従来技術では、シェーディング計算をN個の異なるビューについて1回だけ実行し、シェーディングされた色を、すべてのビューについて再利用するような処理を行う点が記載されている(引用文献1の0019段落等)。   For example, the prior art describes that shading calculation is executed only once for N different views, and processing is performed such that the shaded color is reused for all views (see Reference 1). 0019 paragraph).

特開2007−514230号公報JP 2007-514230 A

しかし、特許文献1に示すような従来技術では、どの画素の色をどのようにして再利用しているのか不明であるので、N個の視点(ビュー)に基づき生成される画像は不正確であり、生成される立体視画像に違和感があった。   However, in the conventional technique as shown in Patent Document 1, it is unclear how and which pixel color is reused, so that an image generated based on N viewpoints (views) is inaccurate. There was a sense of incongruity in the generated stereoscopic image.

また、通常、画像生成処理過程において、ピクセル処理は非常に処理負荷が高いので、N個の視点に基づく各画像において、全画素の画像情報を求めるピクセル処理を行う場合、全体として処理負荷が高くなってしまう。さらには、時間をかけて正確に画像を生成したとしても、反射光成分が多いハイライト部分においては、ハイライトの位置や形状が左右画像で異なることから、その部分の立体感に違和感が生じることがある。これは、自然現象としても起こりうることであるが、映像制作時にこれらを軽減できれば、違和感のない見やすい立体視映像を作成できる。   In general, in the image generation process, pixel processing has a very high processing load. Therefore, when performing pixel processing for obtaining image information of all pixels in each image based on N viewpoints, the processing load is high as a whole. turn into. Furthermore, even if an image is generated accurately over time, in the highlight part with many reflected light components, the position and shape of the highlight differ between the left and right images, so that the three-dimensional feeling of that part is uncomfortable. Sometimes. This may occur as a natural phenomenon, but if these can be reduced at the time of video production, it is possible to create an easy-to-see stereoscopic video without a sense of incongruity.

本発明は、以上の課題に鑑みてなされたものであり、その目的は、少ない処理負荷で、違和感の少ない立体視画像を生成することが可能なプログラム、情報記憶媒体、画像生成装置及びサーバを提供することにある。   The present invention has been made in view of the above problems, and an object of the present invention is to provide a program, an information storage medium, an image generation apparatus, and a server that can generate a stereoscopic image with a small processing load and a little uncomfortable feeling. It is to provide.

(1)本発明は、仮想3次元空間にプリミティブを配置し、立体視画像を生成する処理を行うプログラムであって、前記仮想3次元空間において第1の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第1の画像を生成する処理を行う第1の画像生成部と、前記仮想3次元空間において第2の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第2の画像を生成する処理を行う第2の画像生成部と、第1の画像と第2の画像に基づき、立体視画像を生成する処理を行う立体視画像生成部として、コンピュータを機能させ、前記第1の画像生成部が、スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの情報を記憶させる処理を行い、前記第2の画像生成部が、前記ピクセル処理前に、第2の画像の画素毎に、プリミティブの情報と前記特定バッファの画素のプリミティブの情報とを比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、前記ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行うプログラムに関する。また、本発明は、上記プログラムを記憶した情報記憶媒体に関係する。   (1) The present invention is a program for performing a process of arranging a primitive in a virtual three-dimensional space and generating a stereoscopic image, and perspectively projecting the primitive on a screen based on a first virtual camera in the virtual three-dimensional space A first image generation unit that performs processing for generating a first image by performing vertex processing to be converted and pixel processing for obtaining image information of each pixel, and a second virtual in the virtual three-dimensional space A second image generation unit that performs processing for generating a second image by performing vertex processing for perspective projection conversion of a primitive to a screen based on a camera and pixel processing for obtaining image information of each pixel; Based on the first image and the second image, the computer functions as a stereoscopic image generation unit that performs a process of generating a stereoscopic image, and the first image generation unit includes: Each pixel of the specific buffer corresponding to the clean performs processing for storing the information of the foremost primitive for the first virtual camera, and the second image generation unit performs the processing before the pixel processing. Whether or not there is image information of a divertable pixel from the first image by performing processing for comparing the primitive information and the primitive information of the pixel of the specific buffer for each pixel of the second image. In the case where there is image information of a pixel that can be diverted from the first image, the image information of the pixel of the first image is changed to the pixel information of the second image instead of the pixel processing. The present invention relates to a program for performing processing to be used for image information. The present invention also relates to an information storage medium storing the above program.

ここで、特定バッファとは、画像に関する属性情報を画素単位で記憶可能なバッファであり、例えば、ステンシルバッファである。また、第1の画像から流用可能な画素数は、1つでもよいし複数でもよい。また、流用する処理とは、例えば、第1の画像の画素の画像情報を第2の画像の画素の画像情報としてフレームバッファ等に記憶させる処理、第1の画像から、当該画素を複数サンプリング(抽出)し、それらを合成(平均化、加重平均化、等)した画像情報を第2の画像の画素の画像情報としてフレームバッファ等に記憶させる処理等である。   Here, the specific buffer is a buffer capable of storing attribute information regarding an image in units of pixels, for example, a stencil buffer. Further, the number of pixels that can be diverted from the first image may be one or plural. The diverting process is, for example, a process of storing image information of a pixel of the first image in a frame buffer or the like as image information of a pixel of the second image, and sampling a plurality of the pixels from the first image ( Extraction) and combining the image information (averaged, weighted average, etc.) into a frame buffer or the like as image information of the pixels of the second image.

また、「プリミティブの情報」は、プリミティブの識別情報、プリミティブの仮想3次元空間の位置座標、プリミティブの奥行き情報の少なくとも1つを含む。   The “primitive information” includes at least one of primitive identification information, primitive three-dimensional space position coordinates, and primitive depth information.

本発明によれば、ピクセル処理前に、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行うので、第2の画像生成処理において画素のピクセル処理を省略することができ処理負荷を軽減させることができる。また、本発明は、第1の画像の当該画素の画像情報を流用することによって、例えばハイライト領域などにおいて、違和感の少ない立体視画像を生成することができる。また、本発明は、第2の画像の画素毎に、プリミティブの情報と特定バッファの画素のプリミティブの情報とを比較する処理を行うことによって、流用すべき画素か否かを適確に判断することができる。   According to the present invention, before pixel processing, a process is performed to determine whether there is divertable pixel image information from the first image, and divertable pixel image information exists from the first image. In this case, instead of pixel processing, the image information of the pixel of the first image is used for the image information of the pixel of the second image. Therefore, the pixel processing of the pixel in the second image generation processing is performed. Can be omitted, and the processing load can be reduced. In addition, according to the present invention, it is possible to generate a stereoscopic image with less sense of incongruity in, for example, a highlight area by using the image information of the pixel of the first image. In addition, the present invention appropriately determines whether or not the pixel is to be diverted by performing processing for comparing the primitive information and the primitive information of the pixel of the specific buffer for each pixel of the second image. be able to.

(2)本発明のプログラム、情報記憶媒体は、前記第1の画像生成部が、スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの識別情報を記憶させる処理を行い、前記第2の画像生成部が、前記ピクセル処理前に、第2の画像の画素毎に、プリミティブの識別情報と前記特定バッファの画素のプリミティブの識別情報とを比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行うようにしてもよい。   (2) In the program and the information storage medium of the present invention, the first image generation unit has, in each pixel of the specific buffer corresponding to the screen, identification information of a primitive that is in the forefront with respect to the first virtual camera And the second image generation unit compares the primitive identification information with the primitive identification information of the pixels of the specific buffer for each pixel of the second image before the pixel processing. By performing the processing, it may be possible to perform processing for determining whether there is image information of divertable pixels from the first image.

本発明は、第2の画像の画素毎に、プリミティブの識別情報と特定バッファの画素のプリミティブの識別情報とを比較する処理を行うことによって、流用すべき画素か否かを適確に判断することができる。   In the present invention, for each pixel of the second image, a process of comparing the primitive identification information with the primitive identification information of the pixel of the specific buffer is performed, thereby appropriately determining whether or not the pixel is to be diverted. be able to.

(3)本発明のプログラム、情報記憶媒体は、前記第1の画像生成部が、スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの前記仮想3次元空間の位置座標を記憶させる処理を行い、前記第2の画像生成部が、前記ピクセル処理前に、第2の画像の画素毎に、プリミティブの仮想3次元空間の位置座標と前記特定バッファの画素の仮想3次元空間の位置座標とを比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行うようにしてもよい。   (3) In the program and the information storage medium of the present invention, the first image generation unit is configured such that the virtual image of the primitive at the forefront with respect to the first virtual camera is displayed on each pixel of the specific buffer corresponding to the screen. A process of storing the position coordinates of the three-dimensional space is performed, and the second image generation unit performs the primitive three-dimensional position coordinates of the primitive and the specific buffer for each pixel of the second image before the pixel processing. A process of comparing whether or not there is image information of a divertable pixel from the first image may be performed by performing a process of comparing the position coordinates of the pixel in the virtual three-dimensional space.

本発明は、プリミティブの仮想3次元空間の位置座標と特定バッファの画素の仮想3次元空間の位置座標とを比較する処理を行うことによって、流用すべき画素か否かを適確に判断することができる。   The present invention appropriately determines whether or not a pixel is to be diverted by performing a process of comparing the position coordinates of a primitive virtual three-dimensional space with the position coordinates of a specific buffer pixel in the virtual three-dimensional space. Can do.

(4)本発明のプログラム、情報記憶媒体は、前記第1の画像生成部が、スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの奥行き情報を記憶させる処理を行い、前記第2の画像生成部が、前記ピクセル処理前に、第2の画像の画素毎に、プリミティブの仮想3次元空間の位置座標と、前記第1の仮想カメラ及び前記第2の仮想カメラの仮想カメラ情報及び前記特定バッファの画素の奥行き情報に基づき算出された仮想3次元空間の位置座標と、を比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行うようにしてもよい。   (4) According to the program and the information storage medium of the present invention, the first image generation unit has the depth information of the primitive located at the forefront with respect to the first virtual camera in each pixel of the specific buffer corresponding to the screen. And the second image generation unit, for each pixel of the second image, the position coordinates of the primitive virtual three-dimensional space, the first virtual camera, and the Pixels that can be diverted from the first image by performing a process of comparing the virtual camera information of the second virtual camera and the position coordinates of the virtual three-dimensional space calculated based on the depth information of the pixels of the specific buffer Processing for determining whether or not the image information exists may be performed.

第1の仮想カメラ及び第2の仮想カメラの仮想カメラ情報とは、第1の仮想カメラ及び第2の仮想カメラを制御するための基準となる基準仮想カメラ(センターカメラ)の仮想カメラ情報(例えば、基準仮想カメラの視点位置、方向、画角)と、そこからの各カメラの相対位置を決定できる情報(例えば、左右カメラの間隔など)してもよいし、第1の仮想カメラの仮想カメラ情報(例えば、第1の仮想カメラの視点位置、方向、画角)、及び、第2の仮想カメラの仮想カメラ情報(例えば、第2の仮想カメラの視点位置、方向、画角)としてもよい。   The virtual camera information of the first virtual camera and the second virtual camera is virtual camera information (for example, a reference virtual camera (center camera) serving as a reference for controlling the first virtual camera and the second virtual camera). , The viewpoint position, direction, and angle of view of the reference virtual camera) and information (for example, the interval between the left and right cameras) that can determine the relative position of each camera from there, or the virtual camera of the first virtual camera Information (for example, the viewpoint position, direction, and angle of view of the first virtual camera) and virtual camera information of the second virtual camera (for example, viewpoint position, direction, and angle of view of the second virtual camera) may be used. .

本発明は、プリミティブの仮想3次元空間の位置座標と、前記第1の仮想カメラ及び前記第2の仮想カメラの仮想カメラ情報及び前記特定バッファの画素の奥行き情報に基づき算出された仮想3次元空間の位置座標と、を比較する処理を行うことによって、流用すべき画素か否かを適確に判断することができる。   The present invention provides a virtual three-dimensional space calculated based on a position coordinate of a primitive virtual three-dimensional space, virtual camera information of the first virtual camera and the second virtual camera, and pixel depth information of the specific buffer. It is possible to accurately determine whether or not the pixel is to be diverted by performing a process of comparing the position coordinates.

また、本発明は、特定バッファの各画素に、第1の仮想カメラに対して最前面にあるプリミティブの奥行き情報を記憶させる処理を行うので、プリミティブの仮想3次元空間の位置座標を記憶するよりも記憶する容量が少なくて済み、記憶容量を節約することができる。   In addition, since the present invention performs processing for storing the depth information of the foremost primitive with respect to the first virtual camera in each pixel of the specific buffer, the position coordinates of the primitive in the virtual three-dimensional space are stored. However, the storage capacity is small, and the storage capacity can be saved.

(5)本発明のプログラム、情報記憶媒体は、前記第2の画像生成部が、プリミティブの情報と前記特定バッファの画素のプリミティブの情報とが同じ場合に、第1の画像から流用可能な画素の画像情報が存在すると判定する処理を行い、前記特定バッファの当該画素に対応する第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行うようにしてもよい。   (5) The program and the information storage medium according to the present invention are such that the second image generation unit can divert pixels from the first image when the primitive information and the primitive information of the pixels of the specific buffer are the same. The image information of the pixel of the first image corresponding to the pixel of the specific buffer is used as the image information of the pixel of the second image. May be.

本発明によれば、プリミティブの情報と特定バッファの画素のプリミティブの情報とが同じ場合に、第1の画像から流用可能な画素の画像情報が存在すると判定する処理を行うので、簡易に、第1の画像から流用可能な画素の画像情報が存在するか否かを判定することができる。   According to the present invention, when the primitive information and the primitive information of the pixel of the specific buffer are the same, it is determined that there is image information of a divertable pixel from the first image. It is possible to determine whether there is image information of divertable pixels from one image.

(6)本発明のプログラム、情報記憶媒体は、前記第2の画像生成部が、第2の画像の画素毎に、前記第1の仮想カメラ及び前記第2の仮想カメラの仮想カメラ情報及び第2の画像の画素の奥行き情報に基づいて、前記特定バッファの探索領域を決定し、プリミティブの情報と探索領域内の画素のプリミティブの情報とを比較する処理を行うようにしてもよい。   (6) In the program and the information storage medium of the present invention, the second image generation unit includes the first virtual camera and the virtual camera information of the second virtual camera and the second virtual camera for each pixel of the second image. The search area of the specific buffer may be determined based on the depth information of the pixels of the second image, and processing for comparing the primitive information and the primitive information of the pixels in the search area may be performed.

本発明によれば、探索領域内の画素を比較対象にするので、比較対象を減らすことができ、処理負荷を軽減することができる。また、本発明は、第1の仮想カメラ及び第2の仮想カメラの仮想カメラ情報及び第2の画像の画素の奥行き情報に基づいて、特定バッファの探索領域を決定するので、正確に探索領域を決定することができる。   According to the present invention, since the pixels in the search area are to be compared, the number of comparison objects can be reduced, and the processing load can be reduced. Further, according to the present invention, the search area of the specific buffer is determined based on the virtual camera information of the first virtual camera and the second virtual camera and the depth information of the pixel of the second image. Can be determined.

(7)本発明のプログラム、情報記憶媒体は、前記立体視画像生成部が、第1〜第N(N≧3)の仮想カメラに基づいて、立体視画像を生成する場合に、前記第1の画像生成部が、第1の仮想カメラに基づき、前記頂点処理と前記ピクセル処理とを行うことによって、第1の画像を生成する処理を行い、前記特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの情報を記憶させる処理を行い、前記第2の画像生成部が、前記頂点処理と前記ピクセル処理とを、第2〜第Nの仮想カメラ毎に行うことによって、第2〜第Nの各画像を生成する処理を行い、前記第2の画像生成部が、第2〜第Nの各画像において、画素毎に、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、前記ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、画像の画素の画像情報に流用する処理を行うようにしてもよい。   (7) The program and the information storage medium of the present invention may be configured such that the stereoscopic image generation unit generates the stereoscopic image based on the first to Nth (N ≧ 3) virtual cameras. The image generation unit performs a process of generating a first image by performing the vertex process and the pixel process based on the first virtual camera, and each pixel of the specific buffer is subjected to the first process. A process of storing information on the foremost primitive for the virtual camera is performed, and the second image generation unit performs the vertex process and the pixel process for each of the second to Nth virtual cameras. The second image generation unit performs processing for generating each of the second to Nth images, and the second image generation unit, for each pixel of the second to Nth images, uses a pixel that can be diverted from the first image. Perform processing to determine whether image information exists, If there is image information of a pixel that can be diverted from the image of the image, instead of the pixel processing, a process of diverting the image information of the pixel of the first image to the image information of the pixel of the image is performed. Also good.

本発明によれば、第2〜第Nの各画像において、画素毎に、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、前記ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、画像の画素の画像情報とする処理を行うので、流用した画素のピクセル処理を省略することができ処理負荷を軽減させることができる。また、第1の画像の当該画素の画像情報を流用することによって、違和感の少ない立体視画像を生成することができる。   According to the present invention, in each of the second to Nth images, a process for determining whether there is image information of a divertable pixel from the first image for each pixel is performed. When there is image information of a divertable pixel, instead of the pixel processing, the image information of the pixel of the first image is processed as image information of the pixel of the image, so the pixel of the diverted pixel Processing can be omitted and the processing load can be reduced. In addition, by diverting the image information of the pixel of the first image, it is possible to generate a stereoscopic image with little discomfort.

(8)本発明のプログラム、情報記憶媒体は、前記第1の画像生成部が、前記第1の画像を加工する処理を行い、前記第2の画像生成部が、前記第2の画像を加工する処理を行い、前記立体視画像生成部が、加工された第1の画像と、加工された第2の画像とに基づいて、立体視画像を生成する処理を行うようにしてもよい。   (8) In the program and the information storage medium of the present invention, the first image generation unit performs processing for processing the first image, and the second image generation unit processes the second image. The stereoscopic image generation unit may perform a process of generating a stereoscopic image based on the processed first image and the processed second image.

ここで、加工処理とは、例えば、エフェクト処理等である。本発明によれば、第1、第2の画像間において異なる加工処理を行う場合において、加工処理を行う前の第1の画像の画素の画像情報を流用することによって、違和感の少ない立体視画像を生成することができる。   Here, the processing process is, for example, an effect process. According to the present invention, when different processing is performed between the first and second images, a stereoscopic image with less discomfort can be obtained by diverting the image information of the pixels of the first image before performing the processing. Can be generated.

(9)本発明のプログラム、情報記憶媒体は、前記画像情報を、色情報、法線情報、奥行き情報、半透明情報の少なくとも1つとしてもよい。   (9) In the program and information storage medium of the present invention, the image information may be at least one of color information, normal line information, depth information, and translucent information.

(10)本発明は、仮想3次元空間にプリミティブを配置し、立体視画像を生成する処理を行う画像生成装置であって、前記仮想3次元空間において第1の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第1の画像を生成する処理を行う第1の画像生成部と、前記仮想3次元空間において第2の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第2の画像を生成する処理を行う第2の画像生成部と、第1の画像と第2の画像に基づき、立体視画像を生成する処理を行う立体視画像生成部と、を含み、前記第1の画像生成部が、スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの情報を記憶させる処理を行い、前記第2の画像生成部が、前記ピクセル処理前に、第2の画像の画素毎に、プリミティブの情報と前記特定バッファの画素のプリミティブの情報とを比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、前記ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う画像生成装置に関する。   (10) The present invention is an image generation apparatus that performs processing for generating a stereoscopic image by arranging a primitive in a virtual three-dimensional space, and the primitive is displayed on a screen based on a first virtual camera in the virtual three-dimensional space. A first image generation unit that performs processing for generating a first image by performing vertex processing for perspective projection conversion and pixel processing for obtaining image information of each pixel; and second processing in the virtual three-dimensional space. A second image generation unit that performs a process of generating a second image by performing a vertex process for perspective projection conversion of a primitive to a screen based on the virtual camera and a pixel process for obtaining image information of each pixel; A stereoscopic image generation unit that performs a process of generating a stereoscopic image based on the first image and the second image, wherein the first image generation unit corresponds to a screen Each pixel of the specific buffer is configured to store information on the foremost primitive for the first virtual camera, and the second image generation unit performs the second image before the pixel processing. A process for determining whether there is image information of divertable pixels from the first image by performing a process of comparing primitive information and primitive information of pixels of the specific buffer for each pixel When there is image information of a divertable pixel from the first image, the image information of the pixel of the first image is changed to the image information of the pixel of the second image instead of the pixel processing. The present invention relates to an image generation apparatus that performs processing to be diverted.

(11)本発明は、仮想3次元空間にプリミティブを配置し、立体視画像を生成する処理を行うサーバであって、前記仮想3次元空間において第1の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第1の画像を生成する処理を行う第1の画像生成部と、前記仮想3次元空間において第2の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第2の画像を生成する処理を行う第2の画像生成部と、第1の画像と第2の画像に基づき、立体視画像を生成する処理を行う立体視画像生成部と、を含み、前記第1の画像生成部が、スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの情報を記憶させる処理を行い、前記第2の画像生成部が、前記ピクセル処理前に、第2の画像の画素毎に、プリミティブの情報と前記特定バッファの画素のプリミティブの情報とを比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、前記ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行うサーバに関する。   (11) The present invention is a server that performs processing for arranging a primitive in a virtual three-dimensional space and generating a stereoscopic image, and perspectively projects the primitive on a screen based on a first virtual camera in the virtual three-dimensional space. A first image generation unit that performs processing for generating a first image by performing vertex processing to be converted and pixel processing for obtaining image information of each pixel, and a second virtual in the virtual three-dimensional space A second image generation unit that performs processing for generating a second image by performing vertex processing for perspective projection conversion of a primitive to a screen based on a camera and pixel processing for obtaining image information of each pixel; A stereoscopic image generation unit that performs a process of generating a stereoscopic image based on the first image and the second image, wherein the first image generation unit corresponds to a screen. Each pixel of the buffer performs processing for storing the information of the foremost primitive for the first virtual camera, and the second image generation unit performs pixel processing of the second image before the pixel processing. Each time, a process for comparing the primitive information and the primitive information of the pixel of the specific buffer is performed to determine whether there is diverted pixel image information from the first image. When there is image information of a pixel that can be diverted from the first image, the image information of the pixel of the first image is diverted to the image information of the pixel of the second image instead of the pixel processing. It relates to a server that performs processing.

本実施形態の画像生成装置の機能ブロック図の例。The example of a functional block diagram of the image generation device of this embodiment. 本実施形態の立体視画像生成処理の説明図。Explanatory drawing of the stereoscopic vision image generation process of this embodiment. 図3(A)(B)は、本実施形態の立体視画像の説明図。3A and 3B are explanatory diagrams of stereoscopic images according to the present embodiment. 典型的なレンダリングパイプラインのフローチャート図。FIG. 3 is a flowchart diagram of an exemplary rendering pipeline. プリミティブの説明図。Explanatory drawing of a primitive. 第1の画像(左眼用画像)の生成処理の説明図。Explanatory drawing of the production | generation process of a 1st image (image for left eyes). 図7(A)は、スクリーン40の説明図。図7(B)は、特定バッファ175の説明図。FIG. 7A is an explanatory diagram of the screen 40. FIG. 7B is an explanatory diagram of the specific buffer 175. 第1の画像(左眼用画像)のレンダリングパイプラインのフローチャート図。The flowchart figure of the rendering pipeline of the 1st image (image for left eyes). 第2の画像(右眼用画像)の生成処理の説明図。Explanatory drawing of the production | generation process of a 2nd image (image for right eyes). 画素の流用に関する処理の説明図。Explanatory drawing of the process regarding diversion of a pixel. 画素の流用に関する処理の説明図。Explanatory drawing of the process regarding diversion of a pixel. 画素の流用に関する処理の説明図。Explanatory drawing of the process regarding diversion of a pixel. 画素の流用に関する処理の説明図。Explanatory drawing of the process regarding diversion of a pixel. 第2の画像(右眼用画像)のレンダリングパイプラインのフローチャート図。The flowchart figure of the rendering pipeline of the 2nd image (image for right eyes). 3個以上の仮想カメラに基づく立体視画像の説明図。Explanatory drawing of the stereoscopic vision image based on three or more virtual cameras. 本実施形態のサーバの機能ブロック図の例。The example of the functional block diagram of the server of this embodiment.

以下、本実施形態について説明する。なお、以下に説明する本実施形態は、特許請求の範囲に記載された本発明の内容を不当に限定するものではない。また本実施形態で説明される構成の全てが、本発明の必須構成要件であるとは限らない。   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に本実施の形態の画像生成装置10(コンピュータ、画像生成システム、端末、携帯端末、ゲーム装置、携帯電話、スマートフォン)の機能ブロック図の一例を示す。なお、本実施形態の画像生成装置10は図1の構成要素(各部)の一部を省略した構成としてもよい。
1. Configuration FIG. 1 shows an example of a functional block diagram of an image generation apparatus 10 (computer, image generation system, terminal, mobile terminal, game device, mobile phone, smartphone) of the present embodiment. Note that the image generation apparatus 10 of the present embodiment may have a configuration in which some of the components (each unit) in FIG. 1 are omitted.

操作部160(入力部)は、観察者(プレーヤ)が操作情報(入力情報)を入力するためのものであり、ユーザの操作情報を処理部100に出力する。操作部160の機能は、ボタン、方向キー(十字キー)、方向入力可能なコントロールスティック(アナログキー)、レバー、キーボード、マウス、タッチパネル型ディスプレイ、加速度センサや傾きセンサ、カメラ等を内蔵するコントローラなどのハードウェアにより実現することができる。   The operation unit 160 (input unit) is used by an observer (player) to input operation information (input information), and outputs user operation information to the processing unit 100. The function of the operation unit 160 includes a button, a direction key (cross key), a control stick (analog key) capable of inputting a direction, a lever, a keyboard, a mouse, a touch panel display, an acceleration sensor, a tilt sensor, a controller with a built-in camera, etc. It can be realized by hardware.

記憶部170は、処理部100や通信部196などのワーク領域となるもので、その機能はRAM(VRAM)などにより実現できる。そして、本実施形態の記憶部170は、ワーク領域として使用される主記憶部172と、画像が記憶されるフレームバッファ174と、特定バッファ175(例えば、ステンシルバッファ)、オブジェクトのモデルデータが記憶されるオブジェクトデータ記憶部176と、各オブジェクトデータ用のテクスチャが記憶されるテクスチャ記憶部178と、オブジェクトの画像の生成処理時にZ値が記憶されるZバッファ179とを含む。なお、これらの一部を省略する構成としてもよい。   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. The storage unit 170 of the present embodiment stores a main storage unit 172 used as a work area, a frame buffer 174 for storing images, a specific buffer 175 (for example, a stencil buffer), and object model data. An object data storage unit 176, a texture storage unit 178 for storing textures for each object data, and a Z buffer 179 for storing Z values at the time of object image generation processing. Note that some of these may be omitted.

なお、フレームバッファ174は、第1のフレームバッファ174a(左眼用フレームバッファ)と、第2のフレームバッファ174b(右眼用フレームバッファ)とを含む。また、テクスチャ記憶部178は、第1のテクスチャバッファ178a(左眼用テクスチャバッファ)と、第2のテクスチャバッファ178b(右眼用テクスチャバッファ)とを含む。また、Zバッファ179は、第1のZバッファ179a(左眼用Zバッファ)と、第2のZバッファ179b(右眼用Zバッファ)とを含む。   The frame buffer 174 includes a first frame buffer 174a (left eye frame buffer) and a second frame buffer 174b (right eye frame buffer). The texture storage unit 178 also includes a first texture buffer 178a (left eye texture buffer) and a second texture buffer 178b (right eye texture buffer). The Z buffer 179 includes a first Z buffer 179a (left eye Z buffer) and a second Z buffer 179b (right eye Z buffer).

情報記憶媒体180(コンピュータにより読み取り可能な媒体)は、プログラムやデータなどを格納するものであり、その機能は、光ディスク(CD、DVD)、光磁気ディスク(MO)、磁気ディスク、ハードディスク、磁気テープ、或いはメモリ(ROM)などにより実現できる。処理部100は、情報記憶媒体180に格納されるプログラム(データ)に基づいて本実施形態の種々の処理を行う。情報記憶媒体180には、本実施形態の処理部100の各部としてコンピュータを機能させるためのプログラム(各部の処理をコンピュータに実行させるためのプログラム)を記憶することができる。   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. The information storage medium 180 can store a program for causing a computer to function as each unit of the processing unit 100 according to the present embodiment (a program for causing a computer to execute the processing of each unit).

表示部190は、本実施形態により生成された画像(仮想3次元空間を所与の視点から見た画像)を出力するものであり、その機能は、CRT、LCD、或いはタッチパネル型ディスプレイなどにより実現できる。   The display unit 190 outputs an image (an image obtained by viewing the virtual three-dimensional space from a given viewpoint) generated according to the present embodiment, and the function is realized by a CRT, LCD, touch panel display, or the like. it can.

本実施形態の表示部190は、立体視画像を表示する。例えば、裸眼方式では、表示部190は、有限個の画素からなるLCDの前面又は背面に、パララックスバリアやレンチキュラ等の光学素子が配置される。例えば、垂直バリアまたは垂直レンチキュラによる2眼式の場合には、表示部190に、1枚(1フレーム)の第1の画像(左眼用画像)を表示するための表示領域と、1枚の右眼用画像を表示するための表示領域とが、短冊状に第1の短冊画像表示領域(左眼用短冊画像表示領域)及び第2の短冊画像表示領域(右眼用短冊画像表示領域)として交互に配置されている。パララックスバリアが配置される場合、その隙間からは、観察者の左眼には左眼用短冊画像表示領域に表示される左眼用短冊画像、右眼には右眼用短冊画像表示領域に表示される右眼用短冊画像のみが見えるようになっている。また、レンチキュラが配置される場合、各短冊集合画像に対応したレンズの光屈折効果により、観察者の左眼には左眼用短冊画像表示領域に表示される左眼用短冊画像、右眼には右眼用短冊画像表示領域に表示される右眼用短冊画像のみが見えるようになっている。また、偏光眼鏡方式では、表示部190の奇数ラインと偶数ラインに偏光方向の異なる偏光フィルタ(例えば、左円偏光を透過する偏光フィルタと、右円偏光を透過する偏光フィルタ)が交互に配置され、表示部190の奇数ラインと偶数ラインに第1の画像(左眼用画像)と第2の画像(右眼用画像)を交互に表示し、これを偏光眼鏡(例えば、左眼に左円偏光を透過する偏光フィルタ、右眼に右円偏光を透過する偏光フィルタを付けた眼鏡)で見ることで立体視を実現する。また、ページフリップ方式では、表示部190に第1の画像(左眼用画像)と第2の画像(右眼用画像)を所定時間毎(例えば、1/120秒毎)に交互に表示する。そして、この表示の切り替えに連動して液晶シャッター付きの眼鏡の左眼、右眼の液晶シャッターを交互に開閉することで、立体視を実現する。   The display unit 190 of the present embodiment displays a stereoscopic image. For example, in the naked eye method, the display unit 190 includes optical elements such as a parallax barrier and a lenticular on the front or back of an LCD composed of a finite number of pixels. For example, in the case of a two-lens system using a vertical barrier or a vertical lenticular, a display area for displaying one (one frame) first image (left-eye image) on the display unit 190 and one sheet The display area for displaying the right-eye image is a strip-shaped first strip image display area (left-eye strip image display area) and second strip image display area (right-eye strip image display area). Are arranged alternately. When a parallax barrier is placed, the left eye strip image displayed in the left eye strip image display area is displayed on the left eye of the observer, and the right eye strip image display area is displayed on the right eye. Only the displayed right eye strip image is visible. When the lenticular is arranged, the left eye strip image displayed in the left eye strip image display area is displayed on the left eye of the observer and the right eye due to the photorefractive effect of the lens corresponding to each strip aggregate image. Only the strip image for the right eye displayed in the strip image display area for the right eye is visible. Further, in the polarizing glasses method, polarizing filters having different polarization directions (for example, a polarizing filter that transmits left circularly polarized light and a polarizing filter that transmits right circularly polarized light) are alternately arranged on the odd and even lines of the display unit 190. The first image (the left eye image) and the second image (the right eye image) are alternately displayed on the odd-numbered line and the even-numbered line of the display unit 190, and this is displayed with polarized glasses (for example, the left circle on the left eye). Stereoscopic viewing is realized by viewing with a polarizing filter that transmits polarized light and glasses with a polarizing filter that transmits right circularly polarized light in the right eye. In the page flip method, the display unit 190 alternately displays the first image (left-eye image) and the second image (right-eye image) every predetermined time (for example, every 1/120 second). . In conjunction with the switching of the display, the left and right liquid crystal shutters of the glasses with the liquid crystal shutter are alternately opened and closed to realize stereoscopic viewing.

通信部196は他の画像生成装置10やサーバとの間で通信を行うための各種制御を行うものであり、その機能は、各種プロセッサ又は通信用ASICなどのハードウェアや、プログラムなどにより実現できる。   The communication unit 196 performs various controls for communicating with other image generation apparatuses 10 and servers, and the functions can be realized by hardware such as various processors or communication ASICs, programs, and the like. .

なお、サーバ20が有する情報記憶媒体280や記憶部270に記憶されている本実施形態の各部としてコンピュータを機能させるためのプログラムやデータを、ネットワークを介して受信し、受信したプログラムやデータを情報記憶媒体180や記憶部170に記憶してもよい。このようにプログラムやデータを受信してゲームシステムを機能させる場合も本発明の範囲内に含む。   In addition, the program and data for functioning a computer as each part of this embodiment memorize | stored in the information storage medium 280 and the memory | storage part 270 which the server 20 has are received via a network, and the received program and data are information. You may memorize | store in the storage medium 180 or the memory | storage part 170. FIG. The case where the game system is functioned by receiving the program or data as described above is also included in the scope of the present invention.

処理部100(プロセッサ)は、操作部160からの操作データ、通信部196を介して受信したデータやプログラムなどに基づいて、ゲーム処理、画像生成処理、音生成処理などの処理を行う。ここで、ゲーム処理としては、ゲーム開始条件が満たされた場合にゲームを開始する処理、ゲームを進行させる処理、ゲーム結果を演算する処理、或いはゲーム終了条件が満たされた場合にゲームを終了する処理などがある。この処理部100は主記憶部172をワーク領域として各種処理を行う。処理部100の機能は各種プロセッサ(CPU、DSP等)、ASIC(ゲートアレイ等)などのハードウェアや、プログラムにより実現できる。   The processing unit 100 (processor) performs processing such as game processing, image generation processing, and sound generation processing based on operation data from the operation unit 160, data and programs received via the communication unit 196, and the like. 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 calculating a game result, or a game is ended when a game end condition is satisfied. There is processing. The processing unit 100 performs various processes using the main storage unit 172 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、仮想カメラ制御部118、通信制御部119、画像生成部120、音生成部130を含む。   The processing unit 100 includes an object space setting unit 110, a movement / motion processing unit 112, a virtual camera control unit 118, a communication control unit 119, an image generation unit 120, and a sound generation unit 130.

オブジェクト空間設定部110は、オブジェクト(キャラクタ、移動体)、建物、球場、車、樹木、柱、壁、マップ(地形)などの表示物を表す各種オブジェクト(ポリゴン、自由曲面又はサブディビジョンサーフェスなどのプリミティブで構成されるオブジェクト)を仮想3次元空間(オブジェクト空間、ワールド座標系)に配置設定する処理を行う。つまり、プリミティブを仮想3次元空間に配置する処理を行う。例えば、ワールド座標系でのオブジェクトの位置や回転角度(向き、方向と同義であり、例えば、ワールド座標系でのX、Y、Z軸の各軸の正方向からみて時計回りに回る場合における回転角度)を決定し、その位置(X、Y、Z)にその回転角度(X、Y、Z軸回りでの回転角度)でオブジェクトを配置する。   The object space setting unit 110 includes various objects (polygons, free-form surfaces, subdivision surfaces, etc.) representing display objects such as objects (characters, moving objects), buildings, stadiums, cars, trees, pillars, walls, maps (terrain). A process of placing and setting an object composed of primitives) in a virtual three-dimensional space (object space, world coordinate system) is performed. That is, a process for arranging the primitive in the virtual three-dimensional space is performed. For example, the position and rotation angle (synonymous with the direction and direction of the object in the world coordinate system, for example, rotation when rotating clockwise when viewed from the positive direction of each axis of the X, Y, and Z axes in the world coordinate system. The angle is determined, and the object is arranged at the position (X, Y, Z) at the rotation angle (rotation angle about the X, Y, Z axis).

移動・動作処理部112は、オブジェクト(移動体、キャラクタ等)の移動・動作演算(移動・動作シミュレーション)を行う。すなわち操作部160により観察者(プレーヤ)が入力した操作データや、プログラム(移動・動作アルゴリズム)や、各種データ(モーションデータ)、物理法則などに基づいて、オブジェクトを仮想3次元空間(オブジェクト空間、ワールド座標系)内で移動させたり、オブジェクトを動作(モーション、アニメーション)させたりする処理を行う。具体的には、オブジェクトの移動情報(位置、回転角度、速度、或いは加速度)や動作情報(オブジェクトを構成する各パーツの位置、或いは回転角度)を、1フレーム(例えば、1/60秒又は1/30秒等)毎に順次求めるシミュレーション処理を行う。なお、フレームは、オブジェクトの移動・動作処理(シミュレーション処理)や画像生成処理を行う時間の単位である。   The movement / motion processing unit 112 performs movement / motion calculation (movement / motion simulation) of an object (moving body, character, etc.). That is, based on operation data input by the observer (player) through the operation unit 160, a program (movement / motion algorithm), various data (motion data), physical laws, and the like, an object is represented in a virtual three-dimensional space (object space, It moves within the world coordinate system) and moves the object (motion, animation). Specifically, object movement information (position, rotation angle, speed, or acceleration) and motion information (position or rotation angle of each part constituting the object) are stored in one frame (for example, 1/60 second or 1 / 30 seconds, etc.) The simulation process is sequentially obtained every time. A frame is a unit of time for performing object movement / motion processing (simulation processing) and image generation processing.

また移動・動作処理部112は、ネットワークを介して接続された他の画像生成装置10から通信部196を介して受信したオブジェクト(他のプレーヤに対応するオブジェクト)の移動情報や動作情報に基づき当該オブジェクトの移動情報や動作情報を更新する処理を行うようにしてもよい。   In addition, the movement / motion processing unit 112 is based on movement information and motion information of an object (an object corresponding to another player) received from another image generation apparatus 10 connected via a network via the communication unit 196. You may make it perform the process which updates the movement information and action information of an object.

また、移動・動作処理部112は、他の画像生成装置から通信部196を介して受信した操作データ等に基づき、当該オブジェクトの移動・動作演算を行うようにしてもよい。   In addition, the movement / motion processing unit 112 may perform the movement / motion calculation of the object based on operation data received from another image generation apparatus via the communication unit 196.

仮想カメラ制御部118は、仮想3次元空間内の所与(任意)の視点から見える画像を生成するための仮想カメラ(視点)の制御処理を行う。具体的には、操作部160によりプレーヤが入力した操作データ或いはプログラム(移動・動作アルゴリズム)等に基づいて、ワールド座標系における仮想カメラの位置(X、Y、Z)又は光軸の方向(例えば、X、Y、Z軸の各軸の負方向からみて時計回りに回る場合における回転角度等)を制御する処理を行う。要するに、視点位置、仮想カメラの向き、画角を制御する処理を行う。   The virtual camera control unit 118 performs a virtual camera (viewpoint) control process for generating an image that can be seen from a given (arbitrary) viewpoint in the virtual three-dimensional space. Specifically, based on operation data or a program (movement / motion algorithm) input by the player through the operation unit 160, the position (X, Y, Z) of the virtual camera in the world coordinate system or the direction of the optical axis (for example, , X, Y, and Z axes, a rotation angle when rotating clockwise as viewed from the negative direction is performed. In short, processing for controlling the viewpoint position, the orientation of the virtual camera, and the angle of view is performed.

また、2眼式の立体視方式により立体視画像を表示する場合には、仮想カメラ制御部118は、第1の仮想カメラ(左眼用仮想カメラ)VCL、第2の仮想カメラ(右眼用仮想カメラ)VCRそれぞれの位置、向き及び画角を制御する。また、仮想カメラ制御部118は、第1の仮想カメラと第2の仮想カメラを設定するための基準となる基準仮想カメラ(センターカメラ)VCCの制御を行い、基準仮想カメラVCCの位置、向き及び第1、第2の仮想カメラ間の距離情報に基づいて、第1、第2の仮想カメラの位置、向きを制御するようにしてもよい。   When displaying a stereoscopic image by a two-eye stereoscopic method, the virtual camera control unit 118 includes a first virtual camera (left-eye virtual camera) VCL and a second virtual camera (for right-eye). Virtual camera) Controls the position, orientation and angle of view of each VCR. Further, the virtual camera control unit 118 controls the reference virtual camera (center camera) VCC serving as a reference for setting the first virtual camera and the second virtual camera, and the position, orientation, and The positions and orientations of the first and second virtual cameras may be controlled based on the distance information between the first and second virtual cameras.

つまり、仮想カメラ制御部118は、第1、第2の仮想カメラVCL、VCRそれぞれの仮想カメラ情報(位置、向き、画角の少なくとも1つ)を制御する。また、仮想カメラ制御部118は、基準仮想カメラVCCの(位置、向き、画角の少なくとも1つ)を制御する。   That is, the virtual camera control unit 118 controls virtual camera information (at least one of position, orientation, and angle of view) of each of the first and second virtual cameras VCL and VCR. Further, the virtual camera control unit 118 controls (at least one of position, orientation, and angle of view) of the reference virtual camera VCC.

通信制御部119は、他の画像生成装置又はサーバ20とネットワークを介して相互にデータを送受信する処理を行う。   The communication control unit 119 performs processing for transmitting / receiving data to / from another image generation apparatus or the server 20 via the network.

なお、本実施形態の画像生成装置10では、通信制御で必要となるネットワーク情報をサーバから取得し、管理する処理等を行うようにしてもよい。例えば、画像生成装置10は、各画像生成装置10に個別に付与される画像生成装置10の識別情報(オンラインゲームに参加できる画像生成装置10を識別するために個別に付与されたデータ、ID)と、画像生成装置10の識別情報に対応付けられたパケットの送信先を指定する宛先情報(IPアドレスなど)とを取得し、管理する処理を行うようにしてもよい。   Note that the image generation apparatus 10 according to the present embodiment may perform processing for acquiring and managing network information necessary for communication control from a server. For example, the image generation device 10 has the identification information of the image generation device 10 that is individually assigned to each image generation device 10 (data and ID individually assigned to identify the image generation device 10 that can participate in the online game). And destination information (such as an IP address) that specifies a transmission destination of a packet associated with the identification information of the image generation apparatus 10 may be acquired and managed.

通信制御部119は、他の画像生成装置又はサーバ20に送信するパケットを生成する処理、パケット送信先の画像生成装置10のIPアドレスやポート番号を指定する処理、受信したパケットに含まれるデータを記憶部170に保存する処理、受信したパケットを解析する処理、その他のパケットの送受信に関する制御処理等を行う。   The communication control unit 119 performs processing for generating a packet to be transmitted to another image generation device or the server 20, processing for specifying the IP address and port number of the image generation device 10 that is a packet transmission destination, and data included in the received packet. Processing to be stored in the storage unit 170, processing to analyze received packets, control processing related to transmission / reception of other packets, and the like are performed.

また、本実施形態の通信制御部119は、他の画像生成装置10、又はサーバ20においての接続が確立されてから接続が切断されるまで、データを所定周期(例えば、1秒周期で)互いに送受信する処理を行うようにしてもよい。ここで、画像生成装置10で送受信されるデータは、操作部(入力部)の操作情報(入力情報)としてもよいし、各画像生成装置10の操作対象のオブジェクト(機体、移動体)の位置情報、移動情報としてもよい。   In addition, the communication control unit 119 according to the present embodiment exchanges data with each other in a predetermined cycle (for example, in a cycle of 1 second) until the connection is disconnected after the connection in the other image generation apparatus 10 or the server 20 is established. You may make it perform the process which transmits / receives. Here, the data transmitted / received by the image generation device 10 may be operation information (input information) of the operation unit (input unit), or a position of an object (machine or moving body) to be operated by each image generation device 10. It is good also as information and movement information.

また、本実施形態の通信制御部119は、他の画像生成装置(第2の画像生成装置)又はサーバ20から送信されたパケットを受信すると、受信したパケットを解析し、パケットに含まれる他の画像生成装置の操作対象のオブジェクトの位置情報などのデータを記憶部に記憶する処理を行う。   In addition, when the communication control unit 119 of the present embodiment receives a packet transmitted from another image generation device (second image generation device) or the server 20, the communication control unit 119 analyzes the received packet, and receives other packets included in the packet. A process of storing data such as position information of an operation target object of the image generation apparatus in a storage unit is performed.

また、複数の画像生成装置10で構成されるネットワークシステムの場合は、複数の画像生成装置10間でデータの送受信を行いながらオンラインゲームを実行するピア・ツー・ピア(いわゆるP2P)方式としてもよいし、サーバ20を介して各画像生成装置10がデータ(情報)の送受信を行いながらオンラインゲームを実行するクライアント・サーバ方式によるものであってもよい。また、本実施形態のネットワークシステムでは、有線通信のみならず無線通信でデータを送受信してもよい。   In the case of a network system composed of a plurality of image generation apparatuses 10, a peer-to-peer (so-called P2P) system that executes an online game while transmitting and receiving data between the plurality of image generation apparatuses 10 may be adopted. In addition, the client / server system may be used in which each image generation apparatus 10 executes an online game while transmitting and receiving data (information) via the server 20. In the network system of the present embodiment, data may be transmitted / received not only by wired communication but also by wireless communication.

例えば、本実施形態の通信制御部119は、サーバ20に対して操作情報を送信し、サーバ20において生成される立体視画像の画像データ(表示データ)等を受信するようにしてもよい。   For example, the communication control unit 119 of this embodiment may transmit operation information to the server 20 and receive image data (display data) of a stereoscopic image generated in the server 20.

画像生成部120は、処理部100で行われる種々の処理の結果に基づいて描画処理を行い、これにより画像を生成し、表示部190に出力する。   The image generation unit 120 performs drawing processing based on the results of various processes performed by the processing unit 100, thereby generating an image and outputting the image to the display unit 190.

画像生成部120は、いわゆる3次元画像を生成する場合には、まずオブジェクトの各頂点の頂点データ(頂点の位置座標、テクスチャ座標、色データ、法線ベクトル或いはα値等)を含むオブジェクトデータ(モデルデータ)が入力され、入力されたオブジェクトデータに含まれる頂点データに基づいて、頂点処理(頂点シェーダによるシェーディング)が行われる。なお頂点処理を行うに際して、必要に応じてポリゴンを再分割するための頂点生成処理(テッセレーション、曲面分割、ポリゴン分割)を行うようにしてもよい。   In the case of generating a so-called three-dimensional image, the image generation unit 120 first includes object data including vertex data (vertex position coordinates, texture coordinates, color data, normal vector, α value, etc.) of each vertex of the object. Model data) 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.

頂点処理では、頂点処理プログラム(頂点シェーダプログラム、第1のシェーダプログラム)に従って、頂点の移動処理や、座標変換、例えばワールド座標変換、視野変換(カメラ座標変換)、クリッピング処理、射影変換(透視変換、投影変換)、ビューポート変換(スクリーン座標変換)、光源計算等のジオメトリ処理が行われ、その処理結果に基づいて、オブジェクトを構成する頂点群について与えられた頂点データを変更(更新、調整)する。ジオメトリ処理後のオブジェクトデータ(オブジェクトの頂点の位置座標、テクスチャ座標、色データ(輝度データ)、法線ベクトル、或いはα値等)は、オブジェクトデータ記憶部176に保存される。   In the vertex processing, according to the vertex processing program (vertex shader program, first shader program), vertex movement processing, coordinate transformation, for example, world coordinate transformation, visual field transformation (camera coordinate transformation), clipping processing, projective transformation (perspective transformation) , Projection conversion), viewport conversion (screen coordinate conversion), light source calculation, and other geometric processing are performed, and based on the processing results, the vertex data given to the vertex group constituting the object is changed (updated, adjusted). To do. Object data after the geometry processing (position coordinates of object vertices, texture coordinates, color data (luminance data), normal vector, α value, etc.) is stored in the object data storage unit 176.

そして、頂点処理後の頂点データに基づいてラスタライズ(走査変換)が行われ、プリミティブ(ポリゴン)の面とピクセルとが対応づけられる。そしてラスタライズに続いて、画像を構成するピクセル(表示画面を構成するフラグメント)を描画するピクセル処理(ピクセルシェーダによるシェーディング、フラグメント処理)が行われる。   Then, rasterization (scan conversion) is performed based on the vertex data after the vertex processing, and the surface of the primitive (polygon) 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.

ピクセル処理では、ピクセル処理プログラム(ピクセルシェーダプログラム、第2のシェーダプログラム)に従って、テクスチャの読出し(テクスチャマッピング)、色データの設定/変更、半透明合成、アンチエイリアス等の各種処理を行って、画像を構成するピクセルの最終的な描画色を決定し(画像を構成する各画素の画像情報を求め)、透視変換されたオブジェクトの描画色などの画像情報をフレームバッファ174(ピクセル単位で画像情報を記憶できるバッファ。VRAM)に出力(描画)する。すなわち、ピクセル処理では、画像情報(色情報(R、G、Bの各輝度情報)、法線情報、奥行き情報(深度情報)、半透明情報(α値)等)をピクセル単位で設定あるいは変更するパーピクセル処理を行う。これにより、仮想3次元空間(オブジェクト空間)内において仮想カメラ(所与の視点)から見える画像が生成される。   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 pixel constituting the image is determined (image information of each pixel constituting the image is obtained), and the image information such as the drawing color of the perspective-transformed object is stored in the frame buffer 174 (image information is stored in pixel units). Output (drawing) to a VRAM. That is, in pixel processing, image information (color information (R, G, B luminance information), normal information, depth information (depth information), translucent information (α value), etc.) is set or changed in units of pixels. Perform per-pixel processing. Thereby, an image that can be seen from the virtual camera (given viewpoint) in the virtual three-dimensional space (object space) is generated.

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

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

αブレンディング(α合成)は、α値(A値)に基づく半透明合成処理(通常αブレンディング、加算αブレンディング又は減算αブレンディング等)のことである。例えば、通常αブレンディングでは、α値を合成の強さ(合成率、合成割合)として線形補間を行うことにより2つの色を合成した色を求める処理を行う。なお、α値は、各ピクセル(テクセル、ドット)に関連づけて記憶できる情報であり、例えばRGBの各色成分の輝度を表す色情報以外のプラスアルファの情報(半透明情報)である。α値は、マスク情報、半透明度(透明度、不透明度と等価)、バンプ情報などとして使用できる。   α blending (α synthesis) is a translucent synthesis process (usually α blending, addition α blending, subtraction α blending, or the like) based on an α value (A value). For example, in normal α blending, a process for obtaining a color obtained by combining two colors by performing linear interpolation using the α value as the intensity of synthesis (synthesis rate, synthesis rate). The α value is information that can be stored in association with each pixel (texel, dot), and is, for example, plus alpha information (translucent information) other than color information representing the luminance of each color component of RGB. The α value can be used as mask information, translucency (equivalent to transparency and opacity), bump information, and the like.

特に本実施形態の画像生成部120は、第1の画像生成部124と第2の画像生成部126、立体視画像生成部128とを含む。   In particular, the image generation unit 120 of the present embodiment includes a first image generation unit 124, a second image generation unit 126, and a stereoscopic image generation unit 128.

第1の画像生成部124(左眼用画像生成部)は、仮想3次元空間(ワールド座標系、オブジェクト空間)において、第1の仮想カメラ(左眼用仮想カメラVCL)から見える第1の画像(左眼用画像)の各画素の画像情報(色情報、法線情報、深度情報、半透明情報の少なくとも1つ)を、第1のバッファ(例えば、第1のフレームバッファ174a、第1のテクスチャバッファ178a、第1のZバッファ179a)に記憶させる処理を行う。   The first image generation unit 124 (left-eye image generation unit) is a first image that can be seen from the first virtual camera (left-eye virtual camera VCL) in a virtual three-dimensional space (world coordinate system, object space). The image information (at least one of color information, normal line information, depth information, and translucent information) of each pixel of the (left-eye image) is stored in a first buffer (for example, the first frame buffer 174a, the first frame Processing to be stored in the texture buffer 178a and the first Z buffer 179a) is performed.

特に本実施形態の第1の画像生成部124は、仮想3次元空間において第1の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第1の画像を生成する処理を行う。   In particular, the first image generation unit 124 according to the present embodiment performs vertex processing for perspective projection conversion of a primitive onto a screen based on a first virtual camera in a virtual three-dimensional space, and pixel processing for obtaining image information of each pixel. By performing, the process which produces | generates a 1st image is performed.

また、第1の画像生成部124は、スクリーンに対応する特定バッファの各画素に、第1の仮想カメラに対して最前面にあるプリミティブの情報(例えば、プリミティブの識別情報、プリミティブの仮想3次元空間の位置座標、プリミティブの奥行き情報、等)を記憶させる処理を行う。   In addition, the first image generation unit 124 stores information on the primitive that is in the forefront with respect to the first virtual camera (for example, primitive identification information, virtual three-dimensional primitive) for each pixel of the specific buffer corresponding to the screen. (Spatial position coordinates, primitive depth information, etc.) are stored.

例えば、第1の画像生成部124は、スクリーンに対応する特定バッファの各画素に、第1の仮想カメラに対して最前面にあるプリミティブの識別情報(プリミティブの番号i)及び仮想3次元空間の位置座標(ワールド座標値)の少なくとも一方を記憶させる処理を行う。例えば、第1の画像生成部214は、Zバッファ179aの更新時に、スクリーンに対応する特定バッファの各画素に、第1の仮想カメラに対して最前面にあるプリミティブの識別情報(プリミティブの番号i)及び仮想3次元空間の位置座標(ワールド座標)の少なくとも一方を記憶させる処理を行う。   For example, the first image generation unit 124 adds, to each pixel of the specific buffer corresponding to the screen, the identification information (primitive number i) of the primitive that is in the forefront with respect to the first virtual camera and the virtual three-dimensional space. Processing for storing at least one of position coordinates (world coordinate values) is performed. For example, when the Z buffer 179a is updated, the first image generation unit 214 assigns each pixel of the specific buffer corresponding to the screen to the identification information (primitive number i of the primitive) that is in the forefront with respect to the first virtual camera. ) And at least one of the position coordinates (world coordinates) of the virtual three-dimensional space is stored.

また、第1の画像生成部124は、スクリーンに対応する特定バッファの各画素に、第1の仮想カメラに対して最前面にあるプリミティブの奥行き情報(Z値)を記憶させる処理を行うようにしてもよい。この場合、特定バッファ175に記憶される奥行き情報は、第1のZバッファ179aの奥行き情報と一致する内容となる。   In addition, the first image generation unit 124 performs processing for storing the depth information (Z value) of the foremost primitive for the first virtual camera in each pixel of the specific buffer corresponding to the screen. May be. In this case, the depth information stored in the specific buffer 175 is the same content as the depth information of the first Z buffer 179a.

また、第1の画像生成部124は、第1の画像を加工する処理を行う。例えば、第1の画像を第1のテクスチャバッファ178aに格納し、エフェクト処理等を行った最終的な画像を、第1のフレームバッファ174aに格納するようにしてもよい。   In addition, the first image generation unit 124 performs processing for processing the first image. For example, the first image may be stored in the first texture buffer 178a, and the final image subjected to effect processing or the like may be stored in the first frame buffer 174a.

また、第2の画像生成部126(右眼用画像生成部)は、仮想3次元空間において、第2の仮想カメラ(右眼用仮想カメラVCR)から見える第2の画像(右眼用画像)の各画素の画像情報を、第2のバッファ(例えば、第2のフレームバッファ174b、第2のテクスチャバッファ178b、第2のZバッファ179b)に記憶させる処理を行う。   Further, the second image generation unit 126 (right-eye image generation unit) is a second image (right-eye image) that can be seen from the second virtual camera (right-eye virtual camera VCR) in the virtual three-dimensional space. The image information of each pixel is stored in a second buffer (for example, the second frame buffer 174b, the second texture buffer 178b, and the second Z buffer 179b).

特に、本実施形態の第2の画像生成部126は、仮想3次元空間において第2の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第2の画像を生成する処理を行う。   In particular, the second image generation unit 126 of the present embodiment includes a vertex process that performs perspective projection conversion of a primitive onto a screen based on a second virtual camera in a virtual three-dimensional space, a pixel process that obtains image information of each pixel, To generate a second image.

また、第2の画像生成部126は、ピクセル処理前に、第2の画像の画素毎に、プリミティブの情報と前記特定バッファの画素のプリミティブの情報とを比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う。   In addition, the second image generation unit 126 performs a process of comparing the primitive information and the primitive information of the pixels of the specific buffer for each pixel of the second image before the pixel processing. If the image information of the divertable pixel exists from the first image, and the image information of the divertable pixel exists from the first image, the first image is used instead of the pixel processing. A process of diverting the image information of the pixel of the image to the image information of the pixel of the second image is performed.

例えば、第2の画像生成部126は、ピクセル処理前に、第2の画像の画素毎に、プリミティブの識別情報と特定バッファの画素のプリミティブの識別情報とを比較する処理、及び、プリミティブの仮想3次元空間の位置座標と特定バッファの画素のプリミティブの仮想3次元空間の位置座標とを比較する処理、の少なくとも一方を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う。   For example, the second image generation unit 126 compares the primitive identification information with the primitive identification information of the pixels of the specific buffer for each pixel of the second image before pixel processing, and the primitive virtual By performing at least one of the process of comparing the position coordinates in the three-dimensional space and the position coordinates in the virtual three-dimensional space of the primitive of the pixel of the specific buffer, there is image information of the divertable pixels from the first image. When there is image information of a divertable pixel from the first image, the image information of the pixel of the first image is used as the second image instead of the pixel processing. The processing is applied to the image information of the pixels.

また、第2の画像生成部126は、ピクセル処理前に、第2の画像の画素毎に、プリミティブの仮想3次元空間の位置座標と、第1の仮想カメラ及び第2の仮想カメラの仮想カメラ情報及び特定バッファの画素の奥行き情報に基づき算出された仮想3次元空間の位置座標と、を比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行うようにしてもよい。   In addition, the second image generation unit 126 determines the position coordinates of the primitive virtual three-dimensional space and the virtual cameras of the first virtual camera and the second virtual camera for each pixel of the second image before pixel processing. Whether or not there is image information of a divertable pixel from the first image by performing a process of comparing the position coordinates of the virtual three-dimensional space calculated based on the information and the depth information of the pixel of the specific buffer It is also possible to perform a process for determining the above.

また、第1の画像から流用可能な画素の画像情報は1つでもよいし、複数でもよい。また、第2の画像の画素の画像情報に流用する処理とは、例えば、第1の画像の画素の画像情報を第2の画像の画素の画像情報として第2のバッファに記憶させる処理、第1の画像から、当該画素を複数サンプリングし、それらを合成(平均化、加重平均化、等)した画像情報を第2の画像の画素の画像情報として第2のバッファに記憶させる処理である。   Also, the image information of pixels that can be diverted from the first image may be one or plural. Also, the process of diverting the image information of the pixels of the second image is, for example, the process of storing the image information of the pixels of the first image in the second buffer as the image information of the pixels of the second image, In this process, a plurality of pixels are sampled from one image, and image information obtained by combining (averaging, weighted averaging, etc.) the pixels is stored in the second buffer as image information of the pixels of the second image.

また、第2の画像生成部126は、プリミティブの情報と特定バッファの画素のプリミティブの情報とが同じ場合に、第1の画像から流用可能な画素の画像情報が存在すると判定する処理を行い、特定バッファの当該画素に対応する第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う。つまり、特定バッファの当該画素と同じ位置座標にある第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う。   Further, the second image generation unit 126 performs a process of determining that divertable pixel image information exists from the first image when the primitive information and the primitive information of the pixel of the specific buffer are the same, A process of diverting the image information of the pixel of the first image corresponding to the pixel of the specific buffer to the image information of the pixel of the second image is performed. That is, a process of diverting the image information of the pixel of the first image at the same position coordinate as the pixel of the specific buffer to the image information of the pixel of the second image is performed.

例えば、第2の画像生成部126は、プリミティブの識別情報と特定バッファの画素のプリミティブの識別情報とが同じ場合に、第1の画像から流用可能な画素の画像情報が存在すると判定する処理を行い、特定バッファの当該画素に対応する第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う。つまり、特定バッファの当該画素と同じ位置座標にある第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う。   For example, the second image generation unit 126 performs a process of determining that there is image information of a divertable pixel from the first image when the primitive identification information and the primitive identification information of the pixel in the specific buffer are the same. And processing for diverting the image information of the pixel of the first image corresponding to the pixel of the specific buffer to the image information of the pixel of the second image. That is, a process of diverting the image information of the pixel of the first image at the same position coordinate as the pixel of the specific buffer to the image information of the pixel of the second image is performed.

また、第2の画像生成部126は、プリミティブの仮想3次元空間の位置座標と特定バッファの画素のプリミティブの仮想3次元空間の位置座標とが同じ場合に、第1の画像から流用可能な画素の画像情報が存在すると判定する処理を行い、特定バッファの当該画素に対応する第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う。つまり、特定バッファの当該画素と同じ位置座標にある第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う。   In addition, the second image generation unit 126 can divert pixels from the first image when the position coordinates of the primitive virtual three-dimensional space and the position coordinates of the primitive pixel of the specific buffer are the same. The image information of the pixel of the first image corresponding to the pixel of the specific buffer is used as the image information of the pixel of the second image. That is, a process of diverting the image information of the pixel of the first image at the same position coordinate as the pixel of the specific buffer to the image information of the pixel of the second image is performed.

また、第2の画像生成部126は、第2の画像の画素毎に、第1の仮想カメラ及び第2の仮想カメラの仮想カメラ情報及び第2の画像の画素の奥行き情報に基づいて、特定バッファの探索領域を決定し、プリミティブの情報と探索領域内の画素のプリミティブの情報とを比較する処理を行う。   Further, the second image generation unit 126 specifies, for each pixel of the second image, based on the virtual camera information of the first virtual camera and the second virtual camera and the depth information of the pixel of the second image. A search area of the buffer is determined, and processing for comparing primitive information with primitive information of pixels in the search area is performed.

例えば、第2の画像生成部126は、プリミティブの識別情報と探索領域内の画素のプリミティブの識別情報とを比較する処理、及び、プリミティブの仮想3次元空間の位置座標と探索領域内の画素のプリミティブの仮想3次元空間の位置座標とを比較する処理、の少なくとも一方を行う。   For example, the second image generation unit 126 compares the primitive identification information with the primitive identification information of the pixels in the search area, and the position coordinates of the primitive in the virtual three-dimensional space and the pixels in the search area. At least one of processing for comparing the position coordinates of the primitive in the virtual three-dimensional space is performed.

例えば、特定バッファの探索領域は、第2の画像の処理対象の画素と同じ行で、連続して配置される2画素分の領域とする。   For example, the search area of the specific buffer is an area for two pixels that are continuously arranged in the same row as the pixel to be processed of the second image.

例えば、探索領域において、第2の画像の処理対象の画素のプリミティブの識別情報が同じ画素が存在する場合、及び/又は、第2の画像の処理対象の画素のプリミティブの仮想3次元空間の位置座標が同じ画素が存在する場合に、同じであると判断された探索領域の画素に対応する(同じであると判断された探索領域の画素と同じ位置座標にある)第1の画像の画素の画像情報(例えば、色情報)を、第2の画像の処理対象の画素の画像情報(例えば、色情報)に流用する。   For example, in the search area, when there is a pixel having the same identification information of the primitive of the pixel to be processed in the second image and / or the position of the primitive of the pixel to be processed in the second image in the virtual three-dimensional space If there is a pixel with the same coordinate, the pixel of the first image corresponding to the pixel of the search area determined to be the same (at the same position coordinate as the pixel of the search area determined to be the same) The image information (for example, color information) is diverted to the image information (for example, color information) of the processing target pixel of the second image.

また、探索領域内の全ての画素が、第2の画像の処理対象の画素のプリミティブの識別情報と同じ場合、及び/又は、第2の画像の処理対象の画素のプリミティブの仮想3次元空間の位置座標と同じ場合は、探索領域内の全画素に対応する第1の画像の画素群の画像情報(例えば、色情報)をサンプリングし、サンプリングを行った画像情報を元に何らかの演算(平均化、加重平均化、等)を行って、第2の画像の画素の画像情報に流用する処理を行うようにしてもよい。   In addition, when all the pixels in the search area are the same as the identification information of the primitive of the pixel to be processed in the second image, and / or in the virtual three-dimensional space of the primitive of the pixel to be processed in the second image If the position coordinates are the same, the image information (for example, color information) of the pixel group of the first image corresponding to all the pixels in the search region is sampled, and some calculation (averaging) is performed based on the sampled image information. , Weighted averaging, etc.) may be performed to apply the processing to the image information of the pixels of the second image.

なお、立体視画像生成部128が、第1〜第N(N≧3)の仮想カメラに基づいて、立体視画像を生成する場合には、第2の画像生成部126は、第2〜第Nの各画像において、画素毎に、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、画像の画素の画像情報に流用する処理を行う。   When the stereoscopic image generation unit 128 generates a stereoscopic image based on the first to Nth (N ≧ 3) virtual cameras, the second image generation unit 126 includes the second to second images. In each of the N images, for each pixel, processing for determining whether there is image information of a divertable pixel from the first image is performed, and there is image information of a divertable pixel from the first image. In such a case, instead of pixel processing, a process of diverting the image information of the pixel of the first image to the image information of the pixel of the image is performed.

また、第2の画像生成部126は、第2の画像を加工する処理を行う。例えば、第2の画像を第2のテクスチャバッファ178bに格納し、エフェクト処理等を行った最終的な画像を、第2のフレームバッファ174bに格納するようにしてもよい。   In addition, the second image generation unit 126 performs processing for processing the second image. For example, the second image may be stored in the second texture buffer 178b, and the final image subjected to effect processing or the like may be stored in the second frame buffer 174b.

立体視画像生成部128は、第1の画像と第2の画像とに基づいて、立体視画像を生成する処理を行う。つまり、立体視画像生成部128は、立体視の方式(裸眼方式、偏光眼鏡方式、ページフリップ方式等)に応じて、第1の画像と第2の画像から、インターリーブ処理を行い立体視画像を生成する。例えば、立体視画像生成部128は、第1の画像と第2の画像とを合成した結合画像を生成する処理や、所定周期で第1の画像、第2の画像の切り替え処理等を行う。また、立体視画像生成部128は、短冊状に第1の画像と第2の画像とを交互に配置させる処理、奇数ライン、偶数ラインに第1の画像と第2の画像とを交互に配置させる処理等を行う。   The stereoscopic image generation unit 128 performs processing for generating a stereoscopic image based on the first image and the second image. That is, the stereoscopic image generation unit 128 performs interleaving processing from the first image and the second image according to the stereoscopic method (naked eye method, polarized glasses method, page flip method, etc.) to generate a stereoscopic image. Generate. For example, the stereoscopic image generation unit 128 performs processing for generating a combined image obtained by combining the first image and the second image, switching processing for the first image and the second image at a predetermined cycle, and the like. In addition, the stereoscopic image generation unit 128 performs processing of alternately arranging the first image and the second image in a strip shape, and alternately arranging the first image and the second image on odd lines and even lines. To perform the processing.

音生成部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.

また、音生成部130は、オブジェクトの位置に応じて音像定位が変化する音を生成してもよい。   The sound generation unit 130 may generate a sound whose sound image localization changes according to the position of the object.

2.立体視画像の生成処理の概要
立体視用画像を生成する手法の概要について、図2を用いて説明する。図2に示すように、2眼式の立体視方式で立体視画像を生成する場合は、観察者(プレーヤ)の両眼の幅に対応する距離だけ離れた左眼用仮想カメラVCLと右眼用仮想カメラVCRを仮想3次元空間(オブジェクト空間、ワールド座標系)に配置設定する。そして、左眼用仮想カメラVCLに対応して左眼用ビューボリュームVVLが設定され、右眼用仮想カメラVCRに対応して右眼用ビューボリュームVVRが設定される。
2. Overview of Stereoscopic Image Generation Processing An overview of a method for generating a stereoscopic image will be described with reference to FIG. As shown in FIG. 2, when a stereoscopic image is generated by the binocular stereoscopic method, the left-eye virtual camera VCL and the right eye separated by a distance corresponding to the width of both eyes of the observer (player). The virtual camera VCR is set in a virtual three-dimensional space (object space, world coordinate system). Then, a left-eye view volume VVL is set corresponding to the left-eye virtual camera VCL, and a right-eye view volume VVR is set corresponding to the right-eye virtual camera VCR.

左眼用、右眼用ビューボリュームVVL、VVRは、左眼用、右眼用仮想カメラVCL、VCRの位置、向き、画角及びスクリーン(投影面)40の位置によって上下左右の構成面が決定される視錐台の領域である。スクリーン40は、表示部190の画面に対応する面であり、観察者の視点位置に相当する左眼用、右眼用仮想カメラVCL、VCRの位置及び向きと、観察者の視点位置と表示部190の画面との位置関係とに基づき設定される。なお、図2において、NPLは左眼用ビューボリュームVVLのニアクリップ面、FPLは左眼用ビューボリュームVVLのファークリップ面であり、NPRは右眼用ビューボリュームVVRのニアクリップ面、FPRは右眼用ビューボリュームVVRのファークリップ面である。   The left and right view volumes VVL and VVR have upper, lower, left, and right constituent planes determined by the positions, orientations, angles of view, and screen (projection plane) 40 for the left and right virtual cameras VCL and VCR. This is the area of the viewing frustum. The screen 40 is a surface corresponding to the screen of the display unit 190, and the positions and orientations of the left-eye and right-eye virtual cameras VCL and VCR corresponding to the observer's viewpoint position, the observer's viewpoint position, and the display part. It is set based on the positional relationship with the 190 screen. In FIG. 2, NPL is the near clip plane of the left-eye view volume VVL, FPL is the far-clip plane of the left-eye view volume VVL, NPR is the near-clip plane of the right-eye view volume VVR, and FPR is the right It is a far clip surface of an eye view volume VVR.

左眼用仮想カメラVCLから見える画像である左眼用画像(第1の画像)は、左眼用ビューボリュームVVL内に存在するオブジェクトを構成するプリミティブ(ポリゴン)をスクリーン40に透視投影して描画することで生成される。同様に、右眼用仮想カメラVCRから見える画像である右眼用画像(第2の画像)は、右眼用ビューボリュームVVR内に存在するオブジェクトを構成するプリミティブ(ポリゴン)をスクリーン40に透視投影して描画することで生成される。   The left-eye image (first image) that can be seen from the left-eye virtual camera VCL is drawn by perspectively projecting primitives (polygons) constituting objects existing in the left-eye view volume VVL onto the screen 40. To be generated. Similarly, the right-eye image (second image) that is an image that can be seen from the right-eye virtual camera VCR is a perspective projection of primitives (polygons) that constitute objects existing in the right-eye view volume VVR onto the screen 40. And generated by drawing.

ここで、仮想3次元空間においてプリミティブがスクリーン40上に位置する場合には、左眼用画像でのプリミティブの描画位置と右眼用画像でのプリミティブの描画位置は一致し、プリミティブの画像の視差は無くなる。つまり、スクリーン40は、スクリーン40に位置するプリミティブが描画された画像の視差がなくなる面である。この場合、観察者からはプリミティブが表示部190の画面上に存在するように見える。   Here, when the primitive is positioned on the screen 40 in the virtual three-dimensional space, the drawing position of the primitive in the left-eye image matches the drawing position of the primitive in the right-eye image, and the parallax of the primitive image Will disappear. That is, the screen 40 is a surface where the parallax of the image on which the primitive located on the screen 40 is drawn is eliminated. In this case, it seems to the viewer that the primitive exists on the screen of the display unit 190.

また、プリミティブが、スクリーン40よりも左眼用、右眼用仮想カメラVCL、VCRからみて手前側のエリア(スクリーン40とニアクリップ面NPL、NPRに挟まれたエリア)である第1のエリアAR1に位置する場合には、図3(A)に示すように、左眼用画像でのプリミティブPTLの描画位置は、右眼用画像でのプリミティブPTRの描画位置に対して右側にずれ、観察者からはプリミティブが表示部190の画面よりも手前側に飛び出しているように見える。また、プリミティブが、スクリーン40よりも左眼用、右眼用仮想カメラVCL、VCRからみて奥側のエリア(スクリーン40とファークリップ面FPL、FPRに挟まれたエリア)である第2のエリアAR2に位置する場合には、図3(B)に示すように、左眼用画像でのプリミティブPTLの描画位置は、右眼用画像でのプリミティブPTRの描画位置に対して左側にずれ、観察者からはプリミティブが表示部190の画面よりも奥側に引っ込んでいるように見える。   Further, the first area AR1 in which the primitive is an area on the near side as viewed from the left-eye and right-eye virtual cameras VCL and VCR from the screen 40 (an area sandwiched between the screen 40 and the near clip planes NPL and NPR). 3A, the drawing position of the primitive PTL in the left-eye image is shifted to the right with respect to the drawing position of the primitive PTR in the right-eye image. From the above, it appears that the primitives are popping out from the screen of the display unit 190. Further, the second area AR2 in which the primitive is an area behind the screen 40 from the left and right eye virtual cameras VCL and VCR (an area between the screen 40 and the far clip surfaces FPL and FPR). 3B, the drawing position of the primitive PTL in the left-eye image is shifted to the left with respect to the drawing position of the primitive PTR in the right-eye image. From the above, it appears that the primitive is retracted to the back of the screen of the display unit 190.

3.典型的なレンダリングパイプラインの説明
次に、典型的なレンダリングパイプラインRPによる画像の生成処理について、図4を用いて説明する。例えば、レンダリングパイプラインRPで、画像を生成する場合には、まず、オブジェクトを構成する各プリミティブの各頂点の頂点データ(頂点の位置座標、テクスチャ座標、色データ、法線ベクトル、α値等)、プリミティブデータ(プリミティブの番号等)が入力され(ステップS11)、入力された頂点データ、プリミティブデータに基づいて、ジオメトリ変換(広義には、頂点処理)が行われる(ステップS12)。
3. Description of Typical Rendering Pipeline Next, image generation processing by a typical rendering pipeline RP will be described with reference to FIG. For example, when generating an image in the rendering pipeline RP, first, vertex data of each vertex of each primitive constituting the object (vertex position coordinates, texture coordinates, color data, normal vector, α value, etc.) Primitive data (primitive number, etc.) is input (step S11), and geometry conversion (vertex processing in a broad sense) is performed based on the input vertex data and primitive data (step S12).

そして、ジオメトリ変換後(頂点処理後)の頂点データに基づいて、クリッピング、ラスタライズ(走査変換)が行われる(ステップS13)。つまり、プリミティブの面とピクセルとが対応づけられる。   Then, clipping and rasterization (scan conversion) are performed based on the vertex data after the geometry conversion (after the vertex processing) (step S13). That is, the surface of the primitive is associated with the pixel.

次に、描画ピクセルのZ値(奥行き情報)が格納されるZバッファ179(奥行きバッファ)を用いたZテスト(Zバッファ法、奥行き比較法)による隠面消去処理を行う(ステップS14)。   Next, hidden surface removal processing is performed by a Z test (Z buffer method, depth comparison method) using a Z buffer 179 (depth buffer) in which the Z value (depth information) of the drawing pixel is stored (step S14).

そして、画像を構成するピクセルを描画するピクセルレンダリング処理(広義には、ピクセル処理)、ライティング処理が行われる(ステップS16)。なお、ピクセルレンダリング(ステップS16)では、テクスチャの読出し(テクスチャマッピング)、テクスチャサンプリングを行い(ステップS15)、画像を構成するピクセルの最終的な描画色を決定してもよい。   Then, pixel rendering processing (pixel processing in a broad sense) for rendering pixels constituting the image and lighting processing are performed (step S16). In pixel rendering (step S16), texture reading (texture mapping) and texture sampling may be performed (step S15) to determine the final drawing color of the pixels constituting the image.

そして、ピクセルの色情報をフレームバッファ(描画バッファ)174に出力(描画)する処理、プリミティブに対応する描画ピクセルを描画する際に、Zバッファ179にZ値を格納する処理を行う(ステップS17)。   Then, a process for outputting (drawing) pixel color information to the frame buffer (drawing buffer) 174, and a process for storing the Z value in the Z buffer 179 when drawing the drawing pixel corresponding to the primitive (step S17). .

例えば、従来の2眼式の立体視画像の生成する場合、まず、レンダリングパイプラインRPで、仮想3次元空間内の左眼用仮想カメラから見える画像である左眼用画像を左眼用フレームバッファ174aに描画し、その後、レンダリングパイプラインRPで、仮想3次元空間内の右眼用仮想カメラから見える画像である右眼用画像を右眼用フレームバッファ174bに描画していた。つまり、左眼用画像と右眼用画像とにおいて、2回のピクセルレンダリング(ピクセル処理)を行うことが必要であったので、非常に処理負荷が高くなるという問題があった。   For example, when generating a conventional binocular stereoscopic image, first, an image for the left eye, which is an image seen from the virtual camera for the left eye in the virtual three-dimensional space, is displayed in the frame buffer for the left eye using the rendering pipeline RP. Then, the image for the right eye, which is an image that can be seen from the virtual camera for the right eye in the virtual three-dimensional space, is drawn in the frame buffer for the right eye 174b by the rendering pipeline RP. In other words, since it is necessary to perform pixel rendering (pixel processing) twice for the left-eye image and the right-eye image, there is a problem that the processing load becomes very high.

4.本実施形態の処理の手法
そこで、本実施形態では、第1のフレームバッファ174a(左眼用フレームバッファ)に左眼用画像(第1の画像の一例)を描画した後に、左目用画像の画素の色情報を、右眼用画像(第2の画像の一例)に描画する画素の色として流用可能か否かを判定する処理を行い、左眼用画像の描画した画素の色情報を右眼用画像の画素の色として流用可能と判断した場合には、左眼用画像の描画した当該画素の色情報を、右眼用画像の画素の色として流用する処理を行う手法を採用する。
4). Therefore, in the present embodiment, after rendering the left-eye image (an example of the first image) in the first frame buffer 174a (left-eye frame buffer), the pixels of the left-eye image To determine whether or not the color information of the right eye can be diverted as the color of the pixel drawn in the right eye image (an example of the second image), and the color information of the pixel drawn in the left eye image is used as the right eye When it is determined that the color of the pixel of the image for use can be diverted, a method is adopted in which the color information of the pixel drawn in the image for the left eye is used as the color of the pixel of the image for the right eye.

例えば、左眼用画像を生成する際に、スクリーン40に対応する特定バッファ175(例えば、ステンシルバッファ)の各画素に、左眼用仮想カメラVCLに対して最前面にあるプリミティブの番号i(識別情報)及びワールド座標値(仮想3次元空間の位置座標)の少なくとも一方を記憶させる処理を行う。   For example, when generating the image for the left eye, each pixel of the specific buffer 175 (for example, the stencil buffer) corresponding to the screen 40 has the number i (identification) of the primitive on the forefront with respect to the virtual camera VCL for the left eye. Information) and at least one of world coordinate values (positional coordinates in the virtual three-dimensional space) is stored.

そして、右眼用画像を生成する場合には、ピクセル処理前に、第2の画像の画素毎に、プリミティブの番号iと特定バッファ175のプリミティブの番号iとを比較する処理、及び、プリミティブのワールド座標値と特定バッファ175のプリミティブのワールド座標値とを比較する処理、の少なくとも一方を行うことによって、第1の画像から流用可能な画素の色情報(R、G、B)の画素が存在するか否かを判定する処理を行う。そして、第1の画像から流用可能な画素の色情報が存在する場合に、ピクセル処理の替わりに、第1の画像から当該画素の色情報(R、G、B)を、第2の画像の画素の色情報(R、G、B)に流用する処理を行う。   When the right-eye image is generated, a process of comparing the primitive number i with the primitive number i of the specific buffer 175 for each pixel of the second image before pixel processing, By performing at least one of the process of comparing the world coordinate value and the world coordinate value of the primitive in the specific buffer 175, there is a pixel of color information (R, G, B) that can be diverted from the first image. The process which determines whether to do is performed. Then, when there is color information of a divertable pixel from the first image, the color information (R, G, B) of the pixel from the first image is replaced by the second image instead of pixel processing. Processing to be applied to pixel color information (R, G, B) is performed.

このようにすれば、例えば、右眼用画像の画像生成処理において、ピクセル処理を省略することができ、処理負荷を軽減させることができる。また、第1の画像から画素の色情報を流用することによって、例えばハイライト領域等においては、違和感の少ない立体視画像を生成することができる。以下、本実施形態の処理の詳細について説明する。   In this way, for example, pixel processing can be omitted in the image generation processing of the right eye image, and the processing load can be reduced. In addition, by diverting pixel color information from the first image, it is possible to generate a stereoscopic image with less discomfort in, for example, a highlight area. Hereinafter, the details of the processing of this embodiment will be described.

4−1.準備
まず、右眼用画像、左眼用画像の各画像を生成する際に、ワールド座標変換処理、スクリーン座標変換処理をそれぞれ行う。
4-1. Preparation First, when generating the right eye image and the left eye image, world coordinate conversion processing and screen coordinate conversion processing are performed.

そして、右眼用画像、左眼用画像の各画像を生成する際は、ワールド座標変換後のプリミティブ(ポリゴン)の各頂点の頂点座標Vp(x、y、z)を格納するための頂点バッファVBを用意する。頂点バッファVBには、頂点座標Vpのほかに、各頂点の色情報(R、G、Bの各色値)、各頂点の法線(x、y、z)、各頂点のテクスチャ座標(U、V)を格納してもよい。   When generating the right eye image and the left eye image, the vertex buffer for storing the vertex coordinates Vp (x, y, z) of each vertex of the primitive (polygon) after world coordinate conversion. Prepare VB. In the vertex buffer VB, in addition to the vertex coordinates Vp, color information (R, G, B color values) of each vertex, normals (x, y, z) of each vertex, texture coordinates (U, V) may be stored.

また、右眼用画像、左眼用画像の各画像を生成する際は、ワールド座標系における各プリミティブの位置座標Wp(Wx、Wy、Wz)、及び、図5に示すように、各プリミティブのプリミティブ番号i(インデックス)を保持する。なお、プリミティブ番号iは、各プリミティブを識別可能な識別情報であり整数値が割り振られる。   Further, when generating the right eye image and the left eye image, the position coordinates Wp (Wx, Wy, Wz) of each primitive in the world coordinate system, and as shown in FIG. Holds the primitive number i (index). The primitive number i is identification information that can identify each primitive, and is assigned an integer value.

また、記憶部170の記憶領域に、スクリーン40(画面、投影面)のサイズ(解像度)と同一サイズの特定バッファ175(例えば、ステンシルバッファ)を予め確保しておく。例えば、スクリーン40のサイズが640×480である場合、特定バッファ175も640×480のサイズとなる。   A specific buffer 175 (for example, a stencil buffer) having the same size as the size (resolution) of the screen 40 (screen, projection plane) is secured in advance in the storage area of the storage unit 170. For example, when the size of the screen 40 is 640 × 480, the specific buffer 175 has a size of 640 × 480.

4−2.第1の画像(左眼用画像)の生成処理の説明
多眼式の立体視画像を生成する場合において、まず初めに生成する画像を第1の画像とする。なお、本実施形態では、左眼用画像を第1の画像としている。
4-2. Description of Generation Process of First Image (Left Eye Image) When generating a multi-view stereoscopic image, an image to be generated first is assumed to be a first image. In the present embodiment, the left-eye image is the first image.

左眼用画像の生成処理では、図6に示すように、左眼用仮想カメラVCLに基づき頂点処理、ラスタライズ後、スクリーン座標系40(2次元座標)のピクセルの位置座標P(x、y)と同じ位置座標にある特定バッファ175(例えば、ステンシルバッファ)のピクセルの位置座標P(x、y)に、ビューボリュームVVL内であって左眼用仮想カメラVCLに対して最前面にあるプリミティブの番号i(「プリミティブの情報」の一例)とワールド座標系における位置座標Wp(Wx、Wy、Wz)(「プリミティブの情報」の一例)とを記憶させる処理を行う。つまり、(x、y)の2次元配列に、プリミティブ番号iとワールド座標値とを記憶させる。なお、本実施形態では、Zバッファの更新時に、特定バッファ175にプリミティブ番号iとワールド座標値とを上書きすることによって、左眼用仮想カメラVCLに対して最前面にあるプリミティブの番号iと、ワールド座標値Wp(Wx、Wy、Wz)とを記憶させる処理を行う。   In the left-eye image generation processing, as shown in FIG. 6, after the vertex processing and rasterization based on the left-eye virtual camera VCL, the pixel position coordinates P (x, y) in the screen coordinate system 40 (two-dimensional coordinates). The position coordinate P (x, y) of the pixel of the specific buffer 175 (for example, stencil buffer) at the same position coordinate as the position of the primitive that is in the foreground in the view volume VVL and that is in front of the virtual camera VCL for the left eye The number i (an example of “primitive information”) and a position coordinate Wp (Wx, Wy, Wz) in the world coordinate system (an example of “primitive information”) are stored. That is, the primitive number i and the world coordinate value are stored in a two-dimensional array (x, y). In the present embodiment, when the Z buffer is updated, the primitive number i and the world coordinate value are overwritten in the specific buffer 175, whereby the primitive number i in the forefront with respect to the left-eye virtual camera VCL, Processing for storing the world coordinate values Wp (Wx, Wy, Wz) is performed.

なお、スクリーン座標系40のピクセルの位置座標P(x、y)と同じ位置座標にある特定バッファ175のピクセルの位置座標P(x、y)に、プリミティブ番号iのみを記憶させるようにしてもよいし、プリミティブのワールド座標系における位置座標Wp(Wx、Wy、Wz)のみを記憶させるようにしてもよい。   Note that only the primitive number i may be stored in the pixel position coordinate P (x, y) of the specific buffer 175 at the same position coordinate as the pixel position coordinate P (x, y) of the screen coordinate system 40. Alternatively, only the position coordinates Wp (Wx, Wy, Wz) of the primitive in the world coordinate system may be stored.

具体的には、図6に示すように、左眼用画像を生成する場合において、左眼用仮想カメラVCLに基づいて、プリミティブPT1(プリミティブ番号=1)をスクリーン40(投影面)に透視投影変換(広義には、頂点処理)を行い、その後、ラスタライズを行う。そして、ラスタライズ、ピクセル処理後、図7に示すように、スクリーン座標系40の画素の位置座標P1(x1、y1)と同じ特定バッファ175の画素の位置座標P1(x1、y1)に、プリミティブPT1のワールド座標系座標値Wp1(Wx1、Wy1、Wz1)とプリミティブPT1の番号「1」を格納する。   Specifically, as shown in FIG. 6, when generating the left-eye image, the primitive PT1 (primitive number = 1) is perspective-projected on the screen 40 (projection plane) based on the left-eye virtual camera VCL. Conversion (vertex processing in a broad sense) is performed, and then rasterization is performed. Then, after rasterization and pixel processing, as shown in FIG. 7, the primitive PT1 is set to the pixel position coordinate P1 (x1, y1) of the specific buffer 175 that is the same as the pixel position coordinate P1 (x1, y1) of the screen coordinate system 40. The world coordinate system coordinate value Wp1 (Wx1, Wy1, Wz1) and the number “1” of the primitive PT1 are stored.

つまり、フレームバッファ174aに左眼用画像が描画されると、特定バッファ175において、スクリーン座標の各画素の位置座標P(x、y)と、描画されたプリミティブ(左眼用仮想カメラVCLから見て最前面のプリミティブ)の番号、ワールド座標値Wp(Wx、Wy、Wz)とが、対応付けられることになる。   That is, when the image for the left eye is drawn in the frame buffer 174a, the position coordinates P (x, y) of each pixel of the screen coordinates and the drawn primitive (viewed from the left-eye virtual camera VCL) are displayed in the specific buffer 175. The number of the frontmost primitive) and the world coordinate value Wp (Wx, Wy, Wz) are associated with each other.

また、本実施形態では、左眼用画像で見えているプリミティブのリストを作成する処理を行う。つまり、ビューボリュームVVL内であって、左眼用仮想カメラVCLから見て最前面のプリミティブの番号をリスト化する。   In the present embodiment, a process for creating a list of primitives visible in the left-eye image is performed. That is, the number of the foremost primitive in the view volume VVL as viewed from the left-eye virtual camera VCL is listed.

図8は、左眼用画像のレンダリングパイプラインRP1(第1のレンダリングパイプライン)の処理の流れを示すフローチャートである。   FIG. 8 is a flowchart showing a processing flow of the rendering pipeline RP1 (first rendering pipeline) for the image for the left eye.

例えば、レンダリングパイプラインRP1で、左眼用画像を生成する場合には、まずプリミティブの各頂点の頂点データ、プリミティブデータが入力され(ステップS21)、入力された頂点データ、プリミティブデータに基づいて、ジオメトリ変換(広義には、「頂点処理」)が行われる。つまり、左眼用仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理を行う(ステップS22)。   For example, when generating an image for the left eye in the rendering pipeline RP1, first, vertex data and primitive data of each vertex of the primitive are input (step S21), and based on the input vertex data and primitive data, Geometry conversion (“vertex processing” in a broad sense) is performed. That is, vertex processing is performed for perspective projection conversion of the primitive onto the screen based on the left-eye virtual camera (step S22).

そして、ジオメトリ変換後の頂点データに基づいて、クリッピング、ラスタライズ(走査変換)が行われる(ステップS23)。つまり、プリミティブの面とピクセルとが対応づけられる。   Then, clipping and rasterization (scanning conversion) are performed based on the vertex data after the geometry conversion (step S23). That is, the surface of the primitive is associated with the pixel.

次に、描画ピクセルのZ値が格納されるZバッファ179aを用いたZテストによる隠面消去処理を行う(ステップS24)。   Next, a hidden surface removal process is performed by a Z test using the Z buffer 179a in which the Z value of the drawing pixel is stored (step S24).

そして、ピクセルレンダリング(画像を構成する各画素の画像情報を求めるピクセル処理)、ライティング処理が行われる(ステップS26)。なお、ピクセルレンダリング(ステップS26)では、テクスチャの読出し(テクスチャマッピング)等を行い、テクスチャサンプリングを行い(ステップS25)、画像を構成するピクセルの最終的な描画色を決定してもよい。   Then, pixel rendering (pixel processing for obtaining image information of each pixel constituting the image) and lighting processing are performed (step S26). In pixel rendering (step S26), texture reading (texture mapping) or the like may be performed, texture sampling may be performed (step S25), and a final drawing color of pixels constituting the image may be determined.

そして、特定バッファ(例えば、ステンシルバッファ)の各画素に、プリミティブのプリミティブ番号とワールド座標値を保存(記憶)させる処理を行う(ステップS27)。   Then, a process of storing (storing) the primitive primitive number and the world coordinate value in each pixel of a specific buffer (for example, stencil buffer) is performed (step S27).

そして、各画素の描画色を左眼用フレームバッファ(第1のフレームバッファ174a)に出力(描画)する処理、左眼Zバッファ(第1のZバッファ179a)にZ値を格納する処理を行う(ステップS28)。以上で処理が終了する。   Then, processing for outputting (drawing) the drawing color of each pixel to the left-eye frame buffer (first frame buffer 174a) and processing for storing the Z value in the left-eye Z buffer (first Z buffer 179a) are performed. (Step S28). The process ends here.

4−3.第2の画像(右眼用画像)の生成処理の説明
第2の画像の生成処理について説明する。第2の画像は、第1の画像が生成された後に生成する。なお、本実施形態では、右眼用画像を第2の画像としている。
4-3. Description of Generation Process of Second Image (Right Eye Image) The second image generation process will be described. The second image is generated after the first image is generated. In the present embodiment, the right-eye image is the second image.

まず、右眼用画像を生成する場合には、左眼用画像で見えているプリミティブから優先してシェーダ(頂点シェーダ、頂点処理)に送るように制御する。つまり、左眼用画像に描画されるプリミティブは右眼用仮想カメラVCRから見て最前面に配置されている可能性が高く、演算量を削減できるからである。   First, when generating an image for the right eye, control is performed so as to send the image to a shader (vertex shader, vertex processing) in preference to the primitive visible in the image for the left eye. That is, the primitive drawn in the left-eye image is highly likely to be placed in the foreground when viewed from the right-eye virtual camera VCR, and the amount of calculation can be reduced.

そして、本実施形態では、右眼用仮想カメラVCRに基づき、頂点処理及びラスタライズを行い、ラスタライズ後、右眼用画像のピクセル処理の前に、画素毎に、プリミティブ番号iと特定バッファ175(例えば、ステンシルバッファ)の画素のプリミティブ番号iとを比較する処理、プリミティブのワールド座標値と特定バッファ175の画素のプリミティブのワールド座標値とを比較する処理、の少なくとも一方を行うことによって、左眼用画像(フレームバッファ174a)から流用できる画素の色情報が存在するか否かを判定し、流用できる画素の色情報が存在する場合には、当該画素の色情報を、右眼用画像の画素の色情報として、第2のフレームバッファ174bに記憶させる処理を行う。つまり、右眼用画像の全画素について、描画色を決定する前に、特定バッファ175を参照して、左眼用画像から流用できる色があるか否かを判断する。   In this embodiment, vertex processing and rasterization are performed based on the right-eye virtual camera VCR, and after rasterization, before pixel processing of the right-eye image, for each pixel, a primitive number i and a specific buffer 175 (for example, , A process for comparing the primitive number i of the pixel of the stencil buffer) and a process of comparing the world coordinate value of the primitive and the world coordinate value of the primitive of the pixel of the specific buffer 175 for the left eye It is determined whether there is color information of a pixel that can be diverted from the image (frame buffer 174a), and when there is color information of a divertable pixel, the color information of the pixel is converted to the pixel information of the right eye image. A process of storing the color information in the second frame buffer 174b is performed. That is, before determining the drawing color for all pixels of the right-eye image, the specific buffer 175 is referenced to determine whether there is a color that can be diverted from the left-eye image.

そして、左目用画像から流用可能な画素の色情報が存在する場合には、流用可能な画素の色情報を、第2の画素の色情報として、右眼用フレームバッファ(フレームバッファ174b)に記憶させる処理を行う。   If there is color information of the divertable pixel from the left-eye image, the divertable pixel color information is stored in the right-eye frame buffer (frame buffer 174b) as the second pixel color information. To perform the process.

具体的には、図9に示すように、右眼用画像を生成する場合において、右眼用仮想カメラVCRに基づいて、プリミティブPT1(プリミティブ番号=1)をスクリーン40(投影面)に透視投影変換(広義には、頂点処理)を行い、その後、ラスタライズを行う。例えば、スクリーン40の画素P2(x2、y2)に描画されるプリミティブPT1のワールド座標値はWp1(Wx1、Wy1、Wz1)である。   Specifically, as shown in FIG. 9, when generating the right-eye image, the primitive PT1 (primitive number = 1) is perspective-projected on the screen 40 (projection surface) based on the right-eye virtual camera VCR. Conversion (vertex processing in a broad sense) is performed, and then rasterization is performed. For example, the world coordinate value of the primitive PT1 drawn on the pixel P2 (x2, y2) of the screen 40 is Wp1 (Wx1, Wy1, Wz1).

すると、右眼用画像の処理対象の画素の位置座標P2(x2、y2)と同じプリミティブ番号、ワールド座標値を格納している画素を、特定バッファ175から探索する。つまり、右眼用画像の処理対象の画素の位置座標P2(x2、y2)と同じプリミティブ番号i=1であって、ワールド座標値Wp1(Wx1、Wy1、Wz1)である画素を、特定バッファ175から探索する。このようにすれば、左眼用画像から流用できる画素の画像情報が存在するか否かをより正確に判定することができるからである。   Then, the specific buffer 175 is searched for a pixel that stores the same primitive number and world coordinate value as the position coordinate P2 (x2, y2) of the pixel to be processed of the right-eye image. That is, the pixel having the same primitive number i = 1 as the position coordinate P2 (x2, y2) of the pixel to be processed of the right-eye image and the world coordinate value Wp1 (Wx1, Wy1, Wz1) is specified buffer 175. Search from. This is because it is possible to more accurately determine whether there is pixel image information that can be diverted from the left-eye image.

例えば、図10に示すように、特定バッファ175において、プリミティブ番号i=1であって、ワールド座標値Wp1(Wx1、Wy1、Wz1)である画素P1(x1、y1)が存在する場合には、左目用画像から流用できる画素の色情報が存在すると判定する。一方、特定バッファ175において、プリミティブ番号i=1であって、ワールド座標値Wp1(Wx1、Wy1、Wz1)である画素が存在しない場合には、左目用画像から流用できる画素の色情報が存在しないと判定する。   For example, as shown in FIG. 10, in the specific buffer 175, when the primitive number i = 1 and the pixel P1 (x1, y1) having the world coordinate value Wp1 (Wx1, Wy1, Wz1) exists, It is determined that there is pixel color information that can be diverted from the left-eye image. On the other hand, in the specific buffer 175, when there is no pixel having the primitive number i = 1 and the world coordinate value Wp1 (Wx1, Wy1, Wz1), there is no color information of a pixel that can be diverted from the left-eye image. Is determined.

なお、特定バッファ175において、プリミティブ番号iのみを比較対象としてもよい。つまり、右眼用画像の処理対象の画素の位置座標P2(x2、y2)と同じプリミティブ番号i=1を格納している画素を、特定バッファ175から探索する。例えば、特定バッファ175において、プリミティブ番号i=1である画素P1(x1、y1)が存在する場合には、左目用画像から流用できる画素の色情報が存在すると判定し、特定バッファ175において、プリミティブ番号i=1である画素が存在しない場合には、左目用画像から流用できる画素の色情報が存在しないと判定する。このようにすれば、比較対象がプリミティブ番号iのみであるので、処理負荷を軽減することができる。例えば、ローポリゴン(詳細度レベルの低いオブジェクトを構成するプリミティブ、所定数以下のプリミティブ数で構成されるオブジェクト)については、プリミティブ番号iで比較するようにしてもよい。   In the specific buffer 175, only the primitive number i may be compared. That is, the specific buffer 175 is searched for a pixel storing the same primitive number i = 1 as the position coordinate P2 (x2, y2) of the pixel to be processed of the right-eye image. For example, if there is a pixel P1 (x1, y1) having a primitive number i = 1 in the specific buffer 175, it is determined that there is color information of a pixel that can be diverted from the left-eye image. When there is no pixel with the number i = 1, it is determined that there is no color information of a pixel that can be diverted from the left-eye image. In this way, since the comparison target is only the primitive number i, the processing load can be reduced. For example, low polygons (primitives constituting an object with a low level of detail, objects consisting of a predetermined number of primitives or less) may be compared with the primitive number i.

また、特定バッファ175において、プリミティブのワールド座標値のみを比較対象としてもよい。つまり、右眼用画像の処理対象の画素の位置座標P2(x2、y2)と同じプリミティブのワールド座標値Wp1(Wx1、Wy1、Wz1)を格納している画素を、特定バッファ175から探索する。例えば、特定バッファ175において、プリミティブのワールド座標値Wp1(Wx1、Wy1、Wz1)である画素P1(x1、y1)が存在する場合には、左目用画像から流用できる画素の色情報が存在すると判定し、特定バッファ175において、プリミティブのワールド座標値Wp1(Wx1、Wy1、Wz1)である画素が存在しない場合には、左目用画像から流用できる画素の色情報が存在しないと判定する。このようにすれば、左目用画像から流用できる画素の画像情報が存在するか否かの判定を、プリミティブ番号iのみを比較対象とするよりも正確に行うことができる。例えば、ハイポリゴン(詳細度レベルの高いオブジェクトを構成するプリミティブ、所定数以上のプリミティブ数で構成されるオブジェクト)については、ワールド座標値、或いは、ワールド座標値及びプリミティブ番号で比較するようにしてもよい。   Further, in the specific buffer 175, only the world coordinate value of the primitive may be compared. That is, the specific buffer 175 is searched for a pixel storing the world coordinate value Wp1 (Wx1, Wy1, Wz1) of the same primitive as the position coordinate P2 (x2, y2) of the pixel to be processed of the right-eye image. For example, in the specific buffer 175, when there is a pixel P1 (x1, y1) that is the world coordinate value Wp1 (Wx1, Wy1, Wz1) of the primitive, it is determined that there is color information of a pixel that can be diverted from the left-eye image. In the specific buffer 175, when there is no pixel having the primitive world coordinate value Wp1 (Wx1, Wy1, Wz1), it is determined that there is no color information of a pixel that can be diverted from the left-eye image. In this way, it is possible to more accurately determine whether there is image information of pixels that can be diverted from the left-eye image, compared with only the primitive number i as a comparison target. For example, high polygons (primitives constituting objects with a high level of detail, objects consisting of a predetermined number or more of primitives) may be compared using world coordinate values or world coordinate values and primitive numbers. Good.

また、本実施形態では、探索処理を簡易なものとするために、右眼用画像の処理対象の画素P2(x2、y2)のZ値(Zバッファ179b(右眼用Zバッファ)のZ値)と、第1、第2の仮想カメラ情報に基づいて、特定バッファ175に探索領域Bを決定し、特定バッファ175探索領域B内の各画素を、左目用画像から流用できる画素の画像情報が存在するか否かの判定対象としてもよい。   In the present embodiment, in order to simplify the search process, the Z value of the pixel P2 (x2, y2) to be processed of the right eye image (Z value of the Z buffer 179b (the right eye Z buffer)). ), The search area B is determined in the specific buffer 175 based on the first and second virtual camera information, and the image information of the pixels that can divert each pixel in the specific buffer 175 search area B from the left-eye image is obtained. It may be determined whether or not it exists.

例えば、探索領域Bは次のように決定する。まず、図2に示すように、左眼用仮想カメラVCLと右眼用仮想カメラVCRを設定するための基準となる基準仮想カメラ(センターカメラ)VCCの視点31、画角θC、右眼用画像の処理対象の画素P2(x2、y2)のZ値(奥行き情報、右眼用視点座標系でのZ値)に基づいて、図10に示すように、探索領域Bを決定する。   For example, the search area B is determined as follows. First, as shown in FIG. 2, the viewpoint 31, the angle of view θC, the right-eye image of the reference virtual camera (center camera) VCC serving as a reference for setting the left-eye virtual camera VCL and the right-eye virtual camera VCR. As shown in FIG. 10, the search region B is determined based on the Z value (depth information, Z value in the right-eye viewpoint coordinate system) of the pixel P2 (x2, y2) to be processed.

具体的には、右眼用画像を生成する際に、ラスタライズされたプリミティブの描画対象の画素の位置座標をPnとし、つまり、右眼用画像の処理対象の画素の位置座標をPnとし、基準仮想カメラ(センターカメラ)VCCの視点31、画角θC、右眼用画像の処理対象の画素PnのZ値に基づき、図11に示すように、位置座標Pnの特定バッファ175上の参照点Qnを求める。そして、参照点Qnに最も近い2画素Ka、Kbを探索領域Bとして決定する。   Specifically, when generating the image for the right eye, the position coordinate of the pixel to be rendered of the rasterized primitive is Pn, that is, the position coordinate of the pixel to be processed of the right eye image is Pn, and the reference Based on the viewpoint 31 of the virtual camera (center camera) VCC, the angle of view θC, and the Z value of the pixel Pn to be processed of the right-eye image, as shown in FIG. 11, the reference point Qn on the specific buffer 175 of the position coordinate Pn Ask for. Then, the two pixels Ka and Kb closest to the reference point Qn are determined as the search region B.

なお、左眼用仮想カメラVCLの視点30L、画角θL、右眼用仮想カメラVCRの視点30R、画角θR、及び、右眼用画像のZ値(視点座標系でのZ値)に基づいて探索領域Bを決定してもよい。   Note that the viewpoint 30L and the angle of view θL of the virtual camera VCL for the left eye, the viewpoint 30R and the angle of view θR of the virtual camera VCR for the right eye, and the Z value (Z value in the viewpoint coordinate system) of the image for the right eye. The search area B may be determined.

なお、本実施形態の探索領域Bは、2画素分の連続した領域としているが、探索領域Bは1画素、又は3以上の複数の画素からなる領域としてもよい。   In addition, although the search area B of this embodiment is a continuous area for two pixels, the search area B may be a single pixel or a region composed of three or more pixels.

また、通常、左眼用仮想カメラVCLの視点30Lと、右眼用仮想カメラVCRの視点30Rは、ワールド座標系において平行に配置されるので、本実施形態では、図10に示すように、右眼用画像の処理対象の画素P2(x2、y2)と同一の行(ライン)であるn行目において探索領域Bが決定される。   Further, since the viewpoint 30L of the left-eye virtual camera VCL and the viewpoint 30R of the right-eye virtual camera VCR are usually arranged in parallel in the world coordinate system, in this embodiment, as shown in FIG. The search region B is determined in the nth row, which is the same row (line) as the pixel P2 (x2, y2) to be processed of the eye image.

そして、図10に示すように、特定バッファ175のn行目の2画素分の領域(画素P1、P3)を探索領域Bとして決定された場合、右眼用画像の処理対象の画素P2(x2、y2)のプリミティブ番号i=1と、探索領域B内の各画素P1、P3のプリミティブ番号とを比較する処理を行い、右眼用画像の処理対象の画素P2(x2、y2)のワールド座標値Wp1(Wx1、Wy1、Wz1)と、探索領域B内の各画素P1、P3のワールド座標値とを比較する処理を行う。   Then, as shown in FIG. 10, when the region (pixels P1, P3) for the second pixel in the nth row of the specific buffer 175 is determined as the search region B, the pixel P2 (x2) to be processed in the right-eye image , Y2) is compared with the primitive number i = 1 of each pixel P1, P3 in the search area B, and the world coordinates of the pixel P2 (x2, y2) to be processed of the right-eye image A process of comparing the value Wp1 (Wx1, Wy1, Wz1) with the world coordinate values of the pixels P1, P3 in the search region B is performed.

そして、右眼用画像の処理対象の画素P2(x2、y2)のプリミティブ番号及びワールド座標値の少なくとも一方が、探索領域B内に存在する場合に、左目用画像の画素の色情報を流用できると判定する。   Then, when at least one of the primitive number and the world coordinate value of the pixel P2 (x2, y2) to be processed of the right-eye image exists in the search area B, the color information of the pixel of the left-eye image can be diverted. Is determined.

例えば、図10に示すように、特定バッファ175の探索領域Bの画素P1(x1、y1)のプリミティブ番号iは「1」、ワールド座標値はWx1、Wy1、Wz1であり、特定バッファ175の探索領域Bの画素P3(x3、y3)のプリミティブ番号iは「3」、ワールド座標値はWx3、Wy3、Wz3である場合、右眼用画像の処理対象の画素P2(x2、y2)のプリミティブ番号i=1とワールド座標値Wp1(Wx1、Wy1、Wz1)とが同じ画素P1(x1、y1)=(Wx1、Wy1、Wz1、1)が、特定バッファ175の探索領域B内に存在する。したがって、左目用画像の画素P1の色情報を、右眼用画像の処理対象の画素P2(x2、y2)の色情報として流用できると判定する。そして、図12に示すように、特定バッファ175の画素P1(x1、y1)と同じ位置座標にある左眼用画像の画素P1(x1、y1)の色情報(R、G、B)を、右眼用画像の画素P2(x2、y2)の色情報(R、G、B)として、右眼用フレームバッファ174bに格納する処理を行う。つまり、左眼用フレームバッファ174aの画素P1(x1、y1)の色情報を、右眼用フレームバッファ174bの画素P2(x2、y2)の色情報として流用する処理を行う。   For example, as shown in FIG. 10, the primitive number i of the pixel P1 (x1, y1) in the search area B of the specific buffer 175 is “1”, the world coordinate values are Wx1, Wy1, Wz1, and the search of the specific buffer 175 is performed. When the primitive number i of the pixel P3 (x3, y3) in the region B is “3” and the world coordinate values are Wx3, Wy3, Wz3, the primitive number of the pixel P2 (x2, y2) to be processed of the right-eye image A pixel P1 (x1, y1) = (Wx1, Wy1, Wz1, 1) having the same i = 1 and the world coordinate value Wp1 (Wx1, Wy1, Wz1) is present in the search region B of the specific buffer 175. Therefore, it is determined that the color information of the pixel P1 of the left-eye image can be used as the color information of the processing target pixel P2 (x2, y2) of the right-eye image. Then, as shown in FIG. 12, the color information (R, G, B) of the pixel P1 (x1, y1) of the image for the left eye at the same position coordinates as the pixel P1 (x1, y1) of the specific buffer 175 is obtained. Processing for storing the color information (R, G, B) of the pixel P2 (x2, y2) of the right-eye image in the right-eye frame buffer 174b is performed. That is, a process of diverting the color information of the pixel P1 (x1, y1) of the left eye frame buffer 174a as the color information of the pixel P2 (x2, y2) of the right eye frame buffer 174b is performed.

なお、特定バッファ175(或いは、探索領域B)において、右眼用画像の処理対象の画素のプリミティブ番号及びワールド座標値と同じ画素が存在しない場合は、左目用画像から流用できる画素の色情報が存在しないと判定する。   In the specific buffer 175 (or search area B), when there is no pixel that is the same as the primitive number and world coordinate value of the pixel to be processed of the right-eye image, the color information of the pixel that can be diverted from the left-eye image is displayed. Judge that it does not exist.

例えば、図13に示すように、右眼用画像の処理対象の画素P2(x2、y2)のプリミティブ番号i=2、ワールド座標値Wp2(Wx2、Wy2、Wz2)であった場合において、特定バッファ175(或いは、探索領域B)において、プリミティブ番号i=2、ワールド座標値Wp2(Wx2、Wy2、Wz2)の画素が存在しない場合には、左目用画像から流用できる画素の色情報が存在しないと判定し、右眼用画像の画素P2について通常のピクセル処理を行い、画素P2の描画色を求める処理を行う。つまり、右眼用画像の画素P2について、プリミティブの頂点色、テクスチャ画像の色に基づき、最終的な描画色を決定するための演算処理を行う。   For example, as shown in FIG. 13, when the primitive number i = 2 of the pixel P2 (x2, y2) to be processed of the right-eye image and the world coordinate value Wp2 (Wx2, Wy2, Wz2), the specific buffer In 175 (or search area B), when there is no pixel with primitive number i = 2 and world coordinate value Wp2 (Wx2, Wy2, Wz2), there is no color information of a pixel that can be diverted from the left-eye image. Determination is performed, normal pixel processing is performed on the pixel P2 of the image for the right eye, and processing for obtaining the drawing color of the pixel P2 is performed. That is, for the pixel P2 of the image for the right eye, a calculation process for determining the final drawing color is performed based on the vertex color of the primitive and the color of the texture image.

なお、本実施形態では、右眼用画像の処理対象の画素Pnのプリミティブ番号、ワールド座標値と同じとみなされる画素が特定バッファに複数存在する場合には、当該複数の画素をサンプリングし、それらを合成(平均化、等)して、色情報を流用するようにしてもよい。例えば、図11に示すように、探索領域Bの画素Pa、Pbの各中心点Ka、Kbのうち、参照点Qnに最も近い画素Kaを、右眼用画像に流用する画素として決定してもよい。要するに、ポイントサンプリング方式によって、右眼用画像に流用する画素を決定してもよい。また、図11に示すように、探索領域Bの画素Pa、Pbの各中心点Ka、Kbと参照点Qnの距離に基づいて、画素Pa、Pbの色情報を加重平均して流用してもよい。要するに、バイリニアフィルタに基づき、探索領域Bの複数の画素Pa、Pbの色情報を、右眼用画像の画像情報として流用してもよい。   In the present embodiment, when there are a plurality of pixels in the specific buffer that are considered to be the same as the primitive number and the world coordinate value of the pixel Pn to be processed in the right-eye image, the plurality of pixels are sampled, May be combined (averaged, etc.) to use the color information. For example, as shown in FIG. 11, among the center points Ka and Kb of the pixels Pa and Pb in the search area B, the pixel Ka closest to the reference point Qn is determined as a pixel to be used for the right-eye image. Good. In short, the pixels to be used for the right-eye image may be determined by the point sampling method. Further, as shown in FIG. 11, the color information of the pixels Pa and Pb may be diverted and used based on the distance between the center points Ka and Kb of the pixels Pa and Pb in the search area B and the reference point Qn. Good. In short, based on the bilinear filter, the color information of the plurality of pixels Pa and Pb in the search area B may be used as the image information of the right eye image.

以上のように、本実施形態では、右眼用画像のピクセル処理を省略することができる。また、左目用画像の画素の色情報を、右眼用画像の画素の色情報に流用することによって、違和感の少ない立体視画像を生成することができる。   As described above, in the present embodiment, pixel processing of the right eye image can be omitted. Further, by diverting the color information of the pixel of the left-eye image to the color information of the pixel of the right-eye image, it is possible to generate a stereoscopic image with less sense of discomfort.

図14は、第2の画像(右眼用画像)のレンダリングパイプラインRP2(第2のレンダリングパイプライン)の処理の流れを示すフローチャートである。   FIG. 14 is a flowchart illustrating a processing flow of the rendering pipeline RP2 (second rendering pipeline) of the second image (right-eye image).

例えば、レンダリングパイプラインRP2で、右眼用画像を生成する場合には、まずプリミティブの各頂点の頂点データ、プリミティブデータが入力され(ステップS31)、入力された頂点データ、プリミティブデータに基づいて、ジオメトリ変換(広義には、「頂点処理」)が行われる(ステップS32)。   For example, when generating an image for the right eye in the rendering pipeline RP2, first, vertex data and primitive data of each vertex of the primitive are input (step S31). Based on the input vertex data and primitive data, Geometry conversion (“vertex processing” in a broad sense) is performed (step S32).

そして、ジオメトリ変換後の頂点データに基づいて、クリッピング、ラスタライズが行われる(ステップS33)。つまり、プリミティブの面とピクセルとが対応づけられる。   Then, clipping and rasterization are performed based on the vertex data after the geometry conversion (step S33). That is, the surface of the primitive is associated with the pixel.

次に、センターカメラの画角、視点、右眼用の仮想カメラのZ値(奥行き値)に基づいて、特定バッファ(例えば、ステンシルバッファ)の探索領域を決定する(ステップS34)。   Next, a search area of a specific buffer (for example, stencil buffer) is determined based on the angle of view of the center camera, the viewpoint, and the Z value (depth value) of the virtual camera for the right eye (step S34).

そして、特定バッファの探索領域にプリミティブのワールド座標値及びプリミティブ番号の少なくとも一方が同じ画素が存在するか否かを判断する(ステップS35)。   Then, it is determined whether or not there is a pixel in which at least one of the primitive world coordinate value and the primitive number exists in the search area of the specific buffer (step S35).

特定バッファの探索領域に、プリミティブのワールド座標値及びプリミティブ番号の少なくとも一方が同じ画素が存在する場合には(ステップS35のY)、当該画素と同じ位置座標にある左眼用のフレームバッファ174aの画素の色情報を流用する(ステップS36)。   If a pixel having at least one of the primitive world coordinate value and the primitive number is present in the search area of the specific buffer (Y in step S35), the left eye frame buffer 174a at the same position coordinate as the pixel is stored. The pixel color information is used (step S36).

特定バッファの探索領域に、プリミティブのワールド座標値及びプリミティブ番号の少なくとも一方が同じ画素が存在しない場合には(ステップS35のN)、描画ピクセルのZ値が格納されるZバッファ179を用いたZテストによる隠面消去処理を行う(ステップS37)。   When there is no pixel having the same at least one of the primitive world coordinate value and the primitive number in the search area of the specific buffer (N in step S35), the Z buffer 179 that stores the Z value of the drawing pixel is used. A hidden surface removal process by a test is performed (step S37).

そして、画像を構成する各画素のピクセルレンダリング処理(広義には、ピクセル処理)、ライティング処理が行われる(ステップS39)。なお、ピクセルレンダリング(ステップS39)では、テクスチャの読出し(テクスチャマッピング)等を行い、テクスチャサンプリングを行い(ステップS38)、画像を構成するピクセルの最終的な描画色を決定してもよい。   Then, pixel rendering processing (pixel processing in a broad sense) and lighting processing of each pixel constituting the image are performed (step S39). In the pixel rendering (step S39), texture reading (texture mapping) or the like may be performed, texture sampling may be performed (step S38), and the final drawing color of the pixels constituting the image may be determined.

そして、ステップS36、S39の後、透視変換されたプリミティブの描画色を右眼用フレームバッファ174bに出力(描画)する処理、右眼用Zバッファ179bにZ値を格納する処理を行う(ステップS40)。以上で処理が終了する。   Then, after steps S36 and S39, a process of outputting (drawing) the drawing color of the perspective-converted primitive to the right eye frame buffer 174b and a process of storing the Z value in the right eye Z buffer 179b are performed (step S40). ). The process ends here.

5.応用例
5.1 流用する画像情報の応用例
本実施形態では、右眼用画像の画素毎に、左眼用画像から流用可能な画素の色情報が存在するか否かを判定する処理を行い、左眼用画像から流用可能な画素の色情報が存在する場合に、左眼用画像の画素の色情報を、右眼用画像の画素の色情報に流用する処理例について説明したが、色情報だけでなく、輝度情報、半透明情報、法線情報、奥行き情報に流用するようにしてもよい。
5. Application Example 5.1 Application Example of Diverted Image Information In this embodiment, for each pixel of the right eye image, a process is performed to determine whether or not color information of a divertable pixel exists from the left eye image. In the above description, the color information of the pixel of the left-eye image is used as the color information of the pixel of the right-eye image when there is color information of the pixel that can be diverted from the left-eye image. Not only information but also luminance information, translucent information, normal information, and depth information may be used.

例えば、グレースケール画像の立体視の場合において、本実施形態では、右眼用画像の画素毎に、左眼用画像から流用可能な画素の輝度情報が存在するか否かを判定する処理を行い、左眼用画像から流用可能な画素の輝度情報が存在する場合に、左眼用画像の画素の輝度情報を、右眼用画像の画素の輝度情報に流用してもよい。左眼用画像から流用可能な画素の輝度情報が存在するか否かを判定する処理は、上述したように、右眼用画像生成時のプリミティブ番号、ワールド座標値、特定バッファ175(例えば、ステンシルバッファ)のプリミティブ番号、ワールド座標値を比較することによって行えばよい。このようにすれば、右眼用画像、左眼用画像で、同一のプリミティブ、同一のワールド座標値にあるプリミティブに対して、同じ輝度で画像を生成することができ、違和感の少ない立体視画像を生成することができる。   For example, in the case of stereoscopic viewing of a grayscale image, in the present embodiment, for each pixel of the right eye image, a process is performed to determine whether there is luminance information of a divertable pixel from the left eye image. When there is luminance information of pixels that can be diverted from the left-eye image, the luminance information of pixels of the left-eye image may be diverted to luminance information of pixels of the right-eye image. As described above, the process for determining whether there is luminance information of a divertable pixel from the left-eye image includes the primitive number, the world coordinate value, and the specific buffer 175 (for example, the stencil) at the time of generating the right-eye image. This may be done by comparing the primitive number of the buffer) and the world coordinate value. In this way, the right eye image and the left eye image can be generated with the same brightness for the same primitive and the primitive with the same world coordinate value, and a stereoscopic image with less discomfort. Can be generated.

つまり、本実施形態では、右眼用画像の画素毎に、左眼用画像から流用可能な画素の半透明情報(α値)が存在するか否かを判定する処理を行い、左眼用画像から流用可能な画素の半透明情報が存在する場合に、左眼用画像の画素の半透明情報を、右眼用画像の画素の半透明情報に流用してもよい。左眼用画像から流用可能な画素の半透明情報が存在するか否かを判定する処理は、上述したように、右眼用画像生成時のプリミティブ番号、ワールド座標値、特定バッファ175のプリミティブ番号、ワールド座標値を比較することによって行えばよい。このようにすれば、右眼用画像、左眼用画像で、同一のプリミティブ、同一のワールド座標値にあるプリミティブに対して、同じ合成割合で半透明合成処理等を行うことができ、違和感の少ない立体視画像を生成することができる。   That is, in the present embodiment, for each pixel of the right eye image, a process for determining whether there is translucent information (α value) of divertable pixels from the left eye image is performed, and the left eye image When there is translucent information of pixels that can be diverted from the left, the translucent information of the pixels of the left eye image may be diverted to the translucent information of the pixels of the right eye image. As described above, the process of determining whether there is translucent pixel information that can be diverted from the left-eye image includes the primitive number, the world coordinate value, and the primitive number of the specific buffer 175 when the right-eye image is generated. This can be done by comparing the world coordinate values. In this way, in the right eye image and the left eye image, it is possible to perform translucent synthesis processing or the like on the same primitive and the primitive at the same world coordinate value at the same synthesis ratio. A few stereoscopic images can be generated.

また、本実施形態では、右眼用画像の画素毎に、左眼用画像から流用可能な画素の法線情報(法線ベクトル)が存在するか否かを判定する処理を行い、左眼用画像から流用可能な画素の法線情報が存在する場合に、左眼用画像の画素の法線情報を、右眼用画像の画素の法線情報に流用してもよい。左眼用画像から流用可能な画素の法線情報が存在するか否かを判定する処理は、上述したように、右眼用画像生成時のプリミティブ番号、ワールド座標値、特定バッファ175のプリミティブ番号、ワールド座標値を比較することによって行えばよい。このようにすれば、右眼用画像、左眼用画像で、同一のプリミティブ、同一のワールド座標値にあるプリミティブに対して、同じ法線情報で光沢の計算、法線マッピングなど種々の処理が行うことができ、違和感の少ない立体視画像を生成することができる。   Further, in the present embodiment, for each pixel of the right eye image, processing for determining whether or not there is normal information (normal vector) of a divertable pixel from the left eye image is performed, and the left eye image When there is normal line information of pixels that can be diverted from the image, the normal line information of pixels of the left eye image may be diverted to the normal line information of pixels of the right eye image. As described above, the processing for determining whether there is normal pixel information that can be diverted from the left-eye image includes the primitive number, the world coordinate value, and the primitive number of the specific buffer 175 when the right-eye image is generated. This can be done by comparing the world coordinate values. In this way, the right eye image and the left eye image can be subjected to various processes such as gloss calculation and normal mapping with the same normal information for the same primitive and the primitive at the same world coordinate value. Therefore, it is possible to generate a stereoscopic image with less sense of discomfort.

また、本実施形態では、右眼用画像の画素毎に、左眼用画像から流用可能な画素の奥行き情報(深度情報)が存在するか否かを判定する処理を行い、左眼用画像から流用可能な画素の奥行き情報が存在する場合に、左眼用画像の画素の奥行き情報を、右眼用画像の画素の奥行き情報に流用してもよい。左眼用画像から流用可能な画素の奥行き情報が存在するか否かを判定する処理は、上述したように、右眼用画像生成時のプリミティブ番号、ワールド座標値、特定バッファ175のプリミティブ番号、ワールド座標値を比較することによって行えばよい。このようにすれば、右眼用画像、左眼用画像で、同一のプリミティブ、同一のワールド座標値にあるプリミティブに対して、同じ奥行き情報で種々の処理が行うことができ、違和感の少ない立体視画像を生成することができる。   Further, in the present embodiment, for each pixel of the right eye image, a process for determining whether there is depth information (depth information) of a divertable pixel from the left eye image is performed. When there is depth information of divertable pixels, the depth information of the pixels of the left eye image may be diverted to the depth information of the pixels of the right eye image. As described above, the process for determining whether there is depth information of a divertable pixel from the left-eye image includes the primitive number, the world coordinate value, the primitive number of the specific buffer 175 at the time of generating the right-eye image, This can be done by comparing the world coordinate values. In this way, in the right-eye image and the left-eye image, various processing can be performed on the same primitive and the primitive at the same world coordinate value with the same depth information, and the stereoscopic image with less uncomfortable feeling. A visual image can be generated.

5.2 仮想カメラの応用例
本実施形態では、左眼用画像を初めに生成し、右眼用画像を後に生成する例について説明したが、右眼用画像を第1の画像として初めに生成し、左眼用画像を第2の画像として後に生成してもよい。
5.2 Application example of virtual camera In this embodiment, an example in which an image for the left eye is generated first and an image for the right eye is generated later has been described. However, an image for the right eye is first generated as the first image. However, the left-eye image may be generated later as the second image.

また、本実施形態では、2つの視点(右眼、左眼)に基づく立体視画像の生成処理について説明したが、3つ以上の視点に基づく立体視画像を生成してもよい。例えば、初めに生成する仮想カメラの画像を第1の画像として、特定バッファ175(例えば、ステンシルバッファ)に当該仮想カメラから見て最前面にあるプリミティブのワールド座標値とプリミティブ番号を格納し、他の視点の画像(第2の画像〜第Nの画像(Nは3以上の整数))を生成する場合には、特定バッファ175を参照し、画素毎に、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画その画像情報が存在する場合に、第1の画像の当該画素の画像情報を、画像の画素の画像情報に流用するようにしてもよい。   In the present embodiment, the stereoscopic image generation process based on two viewpoints (right eye and left eye) has been described, but a stereoscopic image based on three or more viewpoints may be generated. For example, the first generated virtual camera image is used as the first image, and the world coordinate value and primitive number of the foremost primitive as viewed from the virtual camera are stored in the specific buffer 175 (for example, stencil buffer). When generating images of the second viewpoint (second image to Nth image (N is an integer of 3 or more)), the specific buffer 175 is referred to and pixels that can be diverted from the first image for each pixel. If the image information that can be diverted from the first image exists, the image information of the pixel of the first image is changed to the image information of the pixel of the image. You may make it divert to image information.

例えば、図15に示すように、仮想カメラVC1〜VC5の5つの多眼式の立体視画像を生成する場合には、まず、第1のレンダリングパイプラインRP1によって、中心の仮想カメラVC3に基づいて、画像を生成する。そして、他の仮想カメラVC1、VC2、VC4、VC5の画像を生成する場合には、第2のレンダリングパイプラインRP2に基づいて画像を生成する。つまり、仮想カメラVC1、VC2、VC4、VC5に基づく画像を生成する場合には、VC3に基づいて生成された画像の色情報を流用できるか否かを判断し、流用できる場合には、当該画素の色情報を流用するようにする。   For example, as shown in FIG. 15, when generating five multi-view stereoscopic images of the virtual cameras VC1 to VC5, first, based on the central virtual camera VC3 by the first rendering pipeline RP1. , Generate an image. Then, when generating images of the other virtual cameras VC1, VC2, VC4, and VC5, the images are generated based on the second rendering pipeline RP2. That is, when generating an image based on the virtual cameras VC1, VC2, VC4, and VC5, it is determined whether or not the color information of the image generated based on VC3 can be diverted. Use the color information.

5.3 Zテストを省略させる処理
本実施形態では、左眼用画像の画素の色情報を、右眼用画像の処理対象の画素Pnの色情報として流用した場合には、当該右眼用画像の画素PnのZバッファ179bのZ値を最大値に設定してもよい。つまり、当該右眼用画像の画素PnのZバッファ179bのZ値を最大値に設定することによって、Zテストにおいて、画素Pnを常に右眼用仮想カメラから見て最前面にある画素とすることができ、ピクセル処理を省略させることができ、処理負荷を軽減することができる。例えば、左眼用仮想カメラVCLに対して最前面にあるプリミティブは、右眼用カメラVCRに対しても最前面にあるという仮定が成り立つ場合において、立体視画像を生成する場合には、処理負荷が軽減されて有効である。
5.3 Processing for omitting the Z test In this embodiment, when the color information of the pixel of the left-eye image is used as the color information of the pixel Pn to be processed of the right-eye image, the right-eye image The Z value of the Z buffer 179b of the pixel Pn may be set to the maximum value. That is, by setting the Z value of the Z buffer 179b of the pixel Pn of the right-eye image to the maximum value, in the Z test, the pixel Pn is always the foremost pixel when viewed from the right-eye virtual camera. The pixel processing can be omitted, and the processing load can be reduced. For example, if it is assumed that the primitive that is in the forefront with respect to the left-eye virtual camera VCL is also in the forefront with respect to the right-eye camera VCR, a processing load is required when generating a stereoscopic image. Is reduced and effective.

5.4 加工処理の例
本実施形態では、第1のレンダリングパイプラインRP1によって生成された左眼用画像(第1の画像)を加工する処理を行い、第2のレンダリングパイプラインRP2によって生成された右眼用画像(第2の画像)を加工する処理を行い、加工された第1、第2の画像に基づいて、立体視画像を生成する処理を行うようにしてもよい。
5.4 Example of Processing Processing In the present embodiment, processing for processing the left eye image (first image) generated by the first rendering pipeline RP1 is performed, and the processing is performed by the second rendering pipeline RP2. Alternatively, a process for processing the right-eye image (second image) may be performed, and a process for generating a stereoscopic image may be performed based on the processed first and second images.

例えば、第1のレンダリングパイプラインRP1によって生成された左眼用画像を第1のテクスチャバッファ178aに格納し、第2のレンダリングパイプラインRP2によって生成された右眼用画像を第2のテクスチャバッファ178bに格納する。   For example, the image for the left eye generated by the first rendering pipeline RP1 is stored in the first texture buffer 178a, and the image for the right eye generated by the second rendering pipeline RP2 is stored in the second texture buffer 178b. To store.

そして、各テクスチャバッファ178a、178bに格納されたテクスチャ画像それぞれに対して、独立したエフェクト処理などの特殊な加工処理を施す。このようにすれば、処理負荷を軽減しながら、右眼用画像、左眼用画像で異なるような加工処理を施すことが適切である場合には、違和感の少なく、意図した光沢感を適度に保った立体視画像を生成することができる。   Then, each texture image stored in each texture buffer 178a, 178b is subjected to special processing such as independent effect processing. In this way, when it is appropriate to apply different processing to the right eye image and the left eye image while reducing the processing load, there is little discomfort and the intended glossiness is moderately adjusted. A maintained stereoscopic image can be generated.

5.5 特定バッファに奥行き情報を記憶させる例
本実施形態では、スクリーンに対応する特定バッファの各画素に、左眼用仮想カメラ(第1の仮想カメラ)VCLに対して最前面にあるプリミティブの奥行き情報(「プリミティブの情報」の一例)を記憶させる処理を行うようにしてもよい。特定バッファ175に記憶される奥行き情報(左眼用視点座標系でのZ値)は、第1のZバッファ179aの奥行き情報と一致する内容となる。なお、第1のZバッファ179aを、特定バッファの一例として使用してもよい。奥行き情報は、仮想3次元空間の位置座標よりもデータ量が少ないので、記憶容量を節約することができるからである。
5.5 Example of Storing Depth Information in Specific Buffer In this embodiment, each pixel of the specific buffer corresponding to the screen has a primitive on the forefront with respect to the left-eye virtual camera (first virtual camera) VCL. Processing for storing depth information (an example of “primitive information”) may be performed. The depth information (Z value in the left-eye viewpoint coordinate system) stored in the specific buffer 175 is the same content as the depth information in the first Z buffer 179a. Note that the first Z buffer 179a may be used as an example of a specific buffer. This is because the depth information has a smaller amount of data than the position coordinates in the virtual three-dimensional space, so that the storage capacity can be saved.

そして、特定バッファに奥行き情報を記憶した場合には、右眼用画像のピクセル処理前に、右眼用画像(第2の画像)の画素毎に、プリミティブの仮想3次元空間の位置座標と、左眼用仮想カメラVCL及び右眼用仮想カメラVCRの仮想カメラ情報及び特定バッファの画素の奥行き情報(Z値)に基づき算出された仮想3次元空間の位置座標と、を比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行う。   When the depth information is stored in the specific buffer, before the pixel processing of the right eye image, for each pixel of the right eye image (second image), the position coordinates of the primitive virtual three-dimensional space, A process of comparing the virtual camera information of the left-eye virtual camera VCL and the right-eye virtual camera VCR and the position coordinates of the virtual three-dimensional space calculated based on the depth information (Z value) of the pixel of the specific buffer. Thus, processing for determining whether there is image information of divertable pixels from the first image is performed.

例えば、「左眼用仮想カメラVCLの視点30L及び右眼用仮想カメラVCRの視点30R」及び、特定バッファに記憶された各画素の奥行き情報(Z値)に基づき、左眼用仮想カメラVCLに対して最前面にあるプリミティブのワールド座標値Wp(Wx、Wy、Wz)を求める。そして、右眼用画像の処理対象の画素のワールド座標値と、求めたワールド座標値Wp(左眼用仮想カメラVCLに対して最前面にあるプリミティブのワールド座標値Wp)とを比較し、左眼用画像から流用できる画素の色情報が存在するか否かを判定する。この方法では、記憶容量が少なくてすむ代わりに、計算負荷は増えるので、計算負荷よりも記憶容量の方を削減したい場合に用いると良い。   For example, based on the “viewpoint 30L of the left-eye virtual camera VCL and the viewpoint 30R of the right-eye virtual camera VCR” and the depth information (Z value) of each pixel stored in the specific buffer, the left-eye virtual camera VCL On the other hand, the world coordinate value Wp (Wx, Wy, Wz) of the primitive at the forefront is obtained. Then, the world coordinate value of the pixel to be processed of the image for the right eye is compared with the obtained world coordinate value Wp (the world coordinate value Wp of the primitive in the forefront with respect to the left-eye virtual camera VCL). It is determined whether there is pixel color information that can be diverted from the eye image. In this method, instead of reducing the storage capacity, the calculation load increases. Therefore, it is preferable to use it when it is desired to reduce the storage capacity rather than the calculation load.

6.サーバ
また、本実施形態では、クライアント・サーバ方式のサーバ20に適用してもよい。つまり、サーバ20が、画像生成装置10(端末)で行う一部の処理(例えば、処理部100の少なくとも1つの処理)を行うようにしてもよい。
6). Server In the present embodiment, the present invention may be applied to a server 20 of a client / server system. That is, the server 20 may perform a part of processing (for example, at least one processing of the processing unit 100) performed by the image generation apparatus 10 (terminal).

例えば、サーバ20が、ネットワーク(例えば、インターネット)を介して複数の画像生成装置10A〜10Cと接続され、サーバ20が、画像生成装置10から入力情報を受信する。そして、サーバ20が、受信した第1、第2、第3の入力情報に基づいて画像を生成し、生成した画像を画像生成装置10に送信してもよい。   For example, the server 20 is connected to the plurality of image generation apparatuses 10 </ b> A to 10 </ b> C via a network (for example, the Internet), and the server 20 receives input information from the image generation apparatus 10. Then, the server 20 may generate an image based on the received first, second, and third input information, and transmit the generated image to the image generation apparatus 10.

図16は、サーバ20の機能ブロック図の例を示す。なお本実施形態のサーバ20は図16の構成要素(各部)の一部を省略した構成としてもよい。   FIG. 16 shows an example of a functional block diagram of the server 20. Note that the server 20 of the present embodiment may have a configuration in which some of the components (each unit) in FIG. 16 are omitted.

記憶部270は、処理部200や通信部296などのワーク領域となるもので、その機能はRAM(VRAM)などにより実現できる。そして、本実施形態の記憶部270は、ワーク領域として使用される主記憶部272と、画像が記憶されるフレームバッファ274と、特定バッファ275(例えば、ステンシルバッファ)、オブジェクトのモデルデータが記憶されるオブジェクトデータ記憶部276と、各オブジェクトデータ用のテクスチャが記憶されるテクスチャ記憶部278と、オブジェクトの画像の生成処理時にZ値が記憶されるZバッファ279とを含む。なお、これらの一部を省略する構成としてもよい。   The storage unit 270 serves as a work area for the processing unit 200, the communication unit 296, and the like, and its function can be realized by a RAM (VRAM) or the like. The storage unit 270 of the present embodiment stores a main storage unit 272 used as a work area, a frame buffer 274 for storing images, a specific buffer 275 (for example, a stencil buffer), and object model data. An object data storage unit 276, a texture storage unit 278 for storing textures for each object data, and a Z buffer 279 for storing Z values during object image generation processing. Note that some of these may be omitted.

なお、フレームバッファ274は、第1のフレームバッファ274a(左眼用フレームバッファ)と、第2のフレームバッファ274b(右眼用フレームバッファ)とを含む。また、テクスチャ記憶部178は、第1のテクスチャバッファ278a(左眼用テクスチャバッファ)と、第2のテクスチャバッファ278b(右眼用テクスチャバッファ)とを含む。また、Zバッファ179は、第1のZバッファ279a(左眼用Zバッファ)と、第2のZバッファ279b(右眼用Zバッファ)とを含む。   The frame buffer 274 includes a first frame buffer 274a (a left-eye frame buffer) and a second frame buffer 274b (a right-eye frame buffer). The texture storage unit 178 includes a first texture buffer 278a (left eye texture buffer) and a second texture buffer 278b (right eye texture buffer). The Z buffer 179 includes a first Z buffer 279a (left eye Z buffer) and a second Z buffer 279b (right eye Z buffer).

情報記憶媒体280(コンピュータにより読み取り可能な媒体)は、プログラムやデータなどを格納するものであり、その機能は、光ディスク(CD、DVD)、光磁気ディスク(MO)、磁気ディスク、ハードディスク、磁気テープ、或いはメモリ(ROM)などにより実現できる。処理部200は、情報記憶媒体280に格納されるプログラム(データ)に基づいて本実施形態の種々の処理を行う。情報記憶媒体280には、本実施形態の各部としてコンピュータを機能させるためのプログラム(各部の処理をコンピュータに実行させるためのプログラム)を記憶することができる。   The information storage medium 280 (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 200 performs various processes of the present embodiment based on a program (data) stored in the information storage medium 280. The information storage medium 280 can store a program for causing a computer to function as each unit of the present embodiment (a program for causing a computer to execute the processing of each unit).

通信部296は外部(例えば画像生成装置10、他のサーバ)との間で通信を行うための各種制御を行うものであり、その機能は、各種プロセッサ又は通信用ASICなどのハードウェアや、プログラムなどにより実現できる。   The communication unit 296 performs various controls for communicating with the outside (for example, the image generation apparatus 10 and other servers), and functions thereof are hardware such as various processors or communication ASICs, and a program. It can be realized by.

なお、他のサーバが有する情報記憶媒体や記憶部に記憶されている本実施形態の各部としてコンピュータを機能させるためのプログラムやデータを、ネットワークを介して受信し、受信したプログラムやデータを情報記憶媒体280や記憶部270に記憶してもよい。このようにプログラムやデータを受信して画像生成装置10を機能させる場合も本発明の範囲内に含む。   In addition, the program and data for functioning a computer as each part of this embodiment memorize | stored in the information storage medium and memory | storage part which another server has are received via a network, and the received program and data are stored in information. You may memorize | store in the medium 280 or the memory | storage part 270. The case where the image generating apparatus 10 is made to function by receiving the program or data as described above is also included in the scope of the present invention.

処理部200(プロセッサ)は、受信したデータやプログラムなどに基づいて、ゲーム処理、画像生成処理、音処理などの処理を行う。   The processing unit 200 (processor) performs processing such as game processing, image generation processing, and sound processing based on the received data and programs.

この処理部200は記憶部270内の主記憶部271をワーク領域として各種処理を行う。処理部200の機能は各種プロセッサ(CPU、DSP等)、ASIC(ゲートアレイ等)などのハードウェアや、プログラムにより実現できる。   The processing unit 200 performs various processes using the main storage unit 271 in the storage unit 270 as a work area. The functions of the processing unit 200 can be realized by hardware such as various processors (CPU, DSP, etc.), ASIC (gate array, etc.), and programs.

処理部200は、オブジェクト空間設定部210、移動・動作処理部212、仮想カメラ制御部218、通信制御部219、画像生成部220、音生成部230を含む。   The processing unit 200 includes an object space setting unit 210, a movement / motion processing unit 212, a virtual camera control unit 218, a communication control unit 219, an image generation unit 220, and a sound generation unit 230.

オブジェクト空間設定部210は、オブジェクト(キャラクタ、移動体)、建物、球場、車、樹木、柱、壁、マップ(地形)などの表示物を表す各種オブジェクト(ポリゴン、自由曲面又はサブディビジョンサーフェスなどのプリミティブで構成されるオブジェクト)を仮想3次元空間(オブジェクト空間)に配置設定する処理を行う。例えば、オブジェクト空間設定部210は、画像生成装置10のオブジェクト空間設定部110と同様な処理を行う。   The object space setting unit 210 includes various objects (polygons, free-form surfaces, subdivision surfaces, etc.) representing display objects such as objects (characters, moving objects), buildings, stadiums, cars, trees, pillars, walls, maps (terrain). A process of placing and setting an object composed of primitives) in a virtual three-dimensional space (object space) is performed. For example, the object space setting unit 210 performs the same processing as the object space setting unit 110 of the image generation device 10.

移動・動作処理部212は、オブジェクト(移動体、キャラクタ等)の移動・動作演算(移動・動作シミュレーション)を行う。移動・動作処理部212は、画像生成装置10からネットワークを介して受信した操作データ等に基づき、当該オブジェクトの移動・動作演算を行うようにしてもよい。例えば、移動・動作処理部212は、画像生成装置10の移動・動作処理部112と同様な処理を行う。   The movement / motion processing unit 212 performs a movement / motion calculation (movement / motion simulation) of an object (moving body, character, etc.). The movement / motion processing unit 212 may perform movement / motion calculation of the object based on operation data received from the image generation apparatus 10 via the network. For example, the movement / motion processing unit 212 performs the same processing as the movement / motion processing unit 112 of the image generation apparatus 10.

仮想カメラ制御部218は、仮想3次元空間内の所与(任意)の視点から見える画像を生成するための仮想カメラ(視点)の制御処理を行う。例えば、仮想カメラ制御部218は、画像生成装置10の仮想カメラ制御部118と同様な処理を行う。   The virtual camera control unit 218 performs a virtual camera (viewpoint) control process for generating an image that can be viewed from a given (arbitrary) viewpoint in the virtual three-dimensional space. For example, the virtual camera control unit 218 performs the same processing as the virtual camera control unit 118 of the image generation apparatus 10.

通信制御部219は、画像生成装置10又は他のサーバ20とネットワークを介して相互にデータを送受信する処理を行う。   The communication control unit 219 performs processing for transmitting / receiving data to / from the image generation apparatus 10 or another server 20 via the network.

なお、本実施形態のサーバ20は、通信制御で必要となるネットワーク情報を画像生成装置10に送信してもよい。なお、例えば、サーバ20は、各端末に個別に付与される端末の識別情報と、端末の識別情報に対応付けられたパケットの送信先を指定する宛先情報を管理する。   Note that the server 20 of the present embodiment may transmit network information necessary for communication control to the image generation apparatus 10. For example, the server 20 manages terminal identification information given to each terminal individually, and destination information that designates a transmission destination of a packet associated with the terminal identification information.

サーバ20の通信制御部219は、画像生成装置10に送信するパケットを生成する処理、パケット送信先の端末のIPアドレスやポート番号を指定する処理、受信したパケットに含まれるデータを記憶部270に保存する処理、受信したパケットを解析する処理、その他のパケットの送受信に関する制御処理等を行う。   The communication control unit 219 of the server 20 generates a packet to be transmitted to the image generation apparatus 10, a process for designating the IP address and port number of a packet transmission destination terminal, and data included in the received packet in the storage unit 270. Processing to save, processing to analyze received packets, control processing related to transmission / reception of other packets, and the like are performed.

また、本実施形態の通信制御部219は、端末と接続が確立されてから接続が切断されるまで、データを所定周期(例えば、1秒周期で)互いに送受信する処理を行う。ここで、画像生成装置10から送信されるデータは、画像生成装置10の操作部160からの操作情報としてもよいし、各画像生成装置10の操作対象のオブジェクト(キャラクタ、移動体)の位置情報、移動情報としてもよい。   In addition, the communication control unit 219 according to the present embodiment performs a process of transmitting and receiving data to and from each other for a predetermined period (for example, every one second) from when the connection with the terminal is established until the connection is disconnected. Here, the data transmitted from the image generation device 10 may be operation information from the operation unit 160 of the image generation device 10 or position information of objects (characters, moving objects) to be operated by the image generation devices 10. It is good also as movement information.

また、本実施形態の通信制御部219は、画像生成装置10から送信されたパケットを受信すると、受信したパケットを解析し、パケットに含まれる他の端末の操作対象のオブジェクトの位置情報などのデータを主記憶部272に記憶する処理を行う。   In addition, when the communication control unit 219 of the present embodiment receives a packet transmitted from the image generation apparatus 10, the communication control unit 219 analyzes the received packet and includes data such as position information of an operation target object of another terminal included in the packet. Is stored in the main storage unit 272.

また、本実施形態の通信制御部219は、第1〜第Nの仮想カメラに基づき生成された各画像の画像データ(例えば、2眼式の場合、第1の画像データ、第2の画像データ)、或いは、立体視画像データを、ネットワークを介して、画像生成装置10に送信するようにしてもよい。   In addition, the communication control unit 219 according to the present embodiment is configured so that the image data of each image generated based on the first to Nth virtual cameras (for example, in the case of a twin-lens type, the first image data and the second image data). Alternatively, the stereoscopic image data may be transmitted to the image generation apparatus 10 via a network.

画像生成部220は、処理部200で行われる種々の処理の結果に基づいて描画処理を行い、これにより画像を生成する。画像生成部220の処理は、画像生成装置10の画像生成部120と同様な処理を行う。   The image generation unit 220 performs a drawing process based on the results of various processes performed by the processing unit 200, thereby generating an image. The process of the image generation unit 220 performs the same process as that of the image generation unit 120 of the image generation apparatus 10.

特に本実施形態の画像生成部220は、第1の画像生成部224と第2の画像生成部226、立体視画像生成部228とを含む。   In particular, the image generation unit 220 of the present embodiment includes a first image generation unit 224, a second image generation unit 226, and a stereoscopic image generation unit 228.

第1の画像生成部224は、画像生成装置10の第1の画像生成部124と同様な処理を行う。   The first image generation unit 224 performs the same processing as that of the first image generation unit 124 of the image generation apparatus 10.

例えば、第1の画像生成部224(左眼用画像生成部)は、仮想3次元空間(ワールド座標系、オブジェクト空間)において、第1の仮想カメラ(左眼用仮想カメラVCL)から見える第1の画像(左眼用画像)の各画素の画像情報(色情報、法線情報、深度情報、半透明情報の少なくとも1つ)を、第1のバッファ(例えば、第1のフレームバッファ274a、第1のテクスチャバッファ278a、第1のZバッファ279a)に記憶させる処理を行う。   For example, the first image generation unit 224 (left-eye image generation unit) is the first visible from the first virtual camera (left-eye virtual camera VCL) in the virtual three-dimensional space (world coordinate system, object space). Image information (at least one of color information, normal line information, depth information, and translucent information) of each pixel of the image (image for left eye) of the first buffer (for example, the first frame buffer 274a, 1 texture buffer 278a and first Z buffer 279a).

特に本実施形態の第1の画像生成部224は、仮想3次元空間において第1の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第1の画像を生成する処理を行う。   In particular, the first image generation unit 224 of the present embodiment performs vertex processing for perspective projection conversion of a primitive onto a screen based on a first virtual camera in a virtual three-dimensional space, and pixel processing for obtaining image information of each pixel. By performing, the process which produces | generates a 1st image is performed.

また、第1の画像生成部224は、スクリーンに対応する特定バッファ275(例えば、ステンシルバッファ)の各画素に、第1の仮想カメラに対して最前面にあるプリミティブの情報を記憶させる処理を行う。   In addition, the first image generation unit 224 performs processing for storing the information of the primitive on the forefront with respect to the first virtual camera in each pixel of the specific buffer 275 (for example, stencil buffer) corresponding to the screen. .

また、第1の画像生成部224は、第1の画像を加工する処理を行う。例えば、第1の画像第1のテクスチャバッファ278aに格納し、エフェクト処理等を行った最終的な画像を、第1のフレームバッファ274aに格納するようにしてもよい。   In addition, the first image generation unit 224 performs processing for processing the first image. For example, the first image may be stored in the first texture buffer 278a and the final image subjected to effect processing or the like may be stored in the first frame buffer 274a.

第2の画像生成部226は、画像生成装置10の第2の画像生成部126と同様な処理を行う。   The second image generation unit 226 performs the same processing as the second image generation unit 126 of the image generation apparatus 10.

つまり、第2の画像生成部226(右眼用画像生成部)は、仮想3次元空間において、第2の仮想カメラ(右眼用仮想カメラVCR)から見える第2の画像(右眼用画像)の各画素の画像情報を、第2のバッファ(例えば、第2のフレームバッファ274a、第2のテクスチャバッファ278b、第2のZバッファ279b)に記憶させる処理を行う。   That is, the second image generation unit 226 (right-eye image generation unit) is a second image (right-eye image) that can be seen from the second virtual camera (right-eye virtual camera VCR) in the virtual three-dimensional space. The image information of each pixel is stored in a second buffer (for example, the second frame buffer 274a, the second texture buffer 278b, and the second Z buffer 279b).

特に本実施形態の第2の画像生成部226は、仮想3次元空間において第2の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第2の画像を生成する処理を行う。   In particular, the second image generation unit 226 of the present embodiment performs vertex processing for perspective projection conversion of a primitive onto a screen based on a second virtual camera in a virtual three-dimensional space, and pixel processing for obtaining image information of each pixel. By performing, the process which produces | generates a 2nd image is performed.

また、第2の画像生成部226は、ピクセル処理前に、第2の画像の画素毎に、プリミティブの情報と特定バッファの画素のプリミティブの情報とを比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う。   In addition, the second image generation unit 226 performs a process of comparing the primitive information and the primitive information of the pixels of the specific buffer for each pixel of the second image before the pixel processing, thereby performing the first image processing. A process for determining whether there is image information of a divertable pixel from the image is performed, and when there is image information of a divertable pixel from the first image, the first image is used instead of the pixel processing. The image information of the pixel is used as the image information of the pixel of the second image.

例えば、第2の画像生成部226は、プリミティブの識別情報と特定バッファの画素のプリミティブの識別情報とが同じ場合に、第1の画像から流用可能な画素の画像情報が存在すると判定する処理を行い、特定バッファの当該画素に対応する第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う。また、第2の画像生成部226は、プリミティブの仮想3次元空間の位置座標と特定バッファの画素のプリミティブの仮想3次元空間の位置座標とが同じ場合に、第1の画像から流用可能な画素の画像情報が存在すると判定する処理を行い、特定バッファの当該画素に対応する第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行う。   For example, the second image generation unit 226 performs a process of determining that there is image information of a divertable pixel from the first image when the primitive identification information and the primitive identification information of the pixel of the specific buffer are the same. And processing for diverting the image information of the pixel of the first image corresponding to the pixel of the specific buffer to the image information of the pixel of the second image. In addition, the second image generation unit 226 can use a pixel that can be diverted from the first image when the position coordinate of the primitive virtual three-dimensional space and the position coordinate of the primitive three-dimensional space of the pixel of the specific buffer are the same. The image information of the pixel of the first image corresponding to the pixel of the specific buffer is used as the image information of the pixel of the second image.

また、第2の画像生成部226は、第2の画像の画素毎に、第1の仮想カメラ及び第2の仮想カメラの仮想カメラ情報及び第2の画像の画素の奥行き情報に基づいて、特定バッファの探索領域を決定し、プリミティブの識別情報と探索領域内の画素のプリミティブの識別情報とを比較する処理、及び、プリミティブの仮想3次元空間の位置座標と探索領域内の画素のプリミティブの仮想3次元空間の位置座標とを比較する処理、の少なくとも一方を行う。探索領域は、画像生成装置10の第2の画像生成部126と同様な処理で決定すればよい。   In addition, the second image generation unit 226 specifies for each pixel of the second image based on the virtual camera information of the first virtual camera and the second virtual camera and the depth information of the pixels of the second image. Processing for determining a search area of the buffer, comparing the identification information of the primitive with the identification information of the primitive of the pixel in the search area, and the position coordinates of the primitive in the virtual three-dimensional space and the virtual of the primitive of the pixel in the search area At least one of processing for comparing the position coordinates in the three-dimensional space is performed. What is necessary is just to determine a search area | region by the process similar to the 2nd image generation part 126 of the image generation apparatus 10. FIG.

なお、立体視画像生成部228が、第1〜第N(N≧3)の仮想カメラに基づいて、立体視画像を生成する場合には、第2の画像生成部226は、第2〜第Nの各画像において、画素毎に、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、画像の画素の画像情報とする処理を行う。   When the stereoscopic image generation unit 228 generates a stereoscopic image based on the first to Nth (N ≧ 3) virtual cameras, the second image generation unit 226 includes the second to second images. In each of the N images, for each pixel, processing for determining whether there is image information of a divertable pixel from the first image is performed, and there is image information of a divertable pixel from the first image. In this case, instead of the pixel processing, the image information of the pixel of the first image is used as the image information of the pixel of the image.

また、第2の画像生成部226は、第2の画像を加工する処理を行う。例えば、第2の画像第2のテクスチャバッファ278bに格納し、エフェクト処理等を行った最終的な画像を、第2のフレームバッファ274bに格納するようにしてもよい。   In addition, the second image generation unit 226 performs processing for processing the second image. For example, the final image that has been stored in the second texture buffer 278b and subjected to the effect processing or the like may be stored in the second frame buffer 274b.

立体視画像生成部228は、第1の画像と第2の画像とに基づいて、立体視画像を生成する処理を行う。立体視画像生成部228は、立体視画像生成部128と同様な処理を行う。   The stereoscopic image generation unit 228 performs processing for generating a stereoscopic image based on the first image and the second image. The stereoscopic image generation unit 228 performs the same processing as the stereoscopic image generation unit 128.

音生成部230は、処理部100で行われる種々の処理の結果に基づいて音処理を行う。   The sound generation unit 230 performs sound processing based on the results of various processes performed by the processing unit 100.

7.その他
本発明は、家庭用ゲームシステム、業務用ゲームシステム等の種々のゲームシステムの立体視画像の生成処理に適用できる。
7). Others The present invention can be applied to a stereoscopic image generation process of various game systems such as a home game system and an arcade game system.

なお、本発明は、上記実施形態で説明したものに限らず、種々の変形実施が可能である。例えば、明細書又は図面中の記載において広義や同義な用語として引用された用語は、明細書又は図面中の他の記載においても広義や同義な用語に置き換えることができる。   The present invention is not limited to the one 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.

本発明は、実施の形態で説明した構成と実質的に同一の構成(例えば、機能、方法及び結果が同一の構成、あるいは目的及び効果が同一の構成)を含む。また、本発明は、実施の形態で説明した構成の本質的でない部分を置き換えた構成を含む。また、本発明は、実施の形態で説明した構成と同一の作用効果を奏する構成又は同一の目的を達成することができる構成を含む。また、本発明は、実施の形態で説明した構成に公知技術を付加した構成を含む。なお、本実施形態で説明した実施例は、自由に組み合わせることができる。   The present invention includes configurations that are substantially the same as the configurations described in the embodiments (for example, configurations that have the same functions, methods, and results, or configurations that have the same objects and effects). In addition, the invention includes a configuration in which a non-essential part of the configuration described in the embodiment is replaced. In addition, the present invention includes a configuration that exhibits the same operational effects as the configuration described in the embodiment or a configuration that can achieve the same object. Further, the invention includes a configuration in which a known technique is added to the configuration described in the embodiment. Note that the examples described in this embodiment can be freely combined.

100 処理部、110 オブジェクト空間設定部、112 移動・動作処理部、
118 仮想カメラ制御部、119 通信制御部、120 画像生成部、
124 第1の画像生成部、126 第2の画像生成部、128 立体視画像生成部、
130 音生成部、160 操作部、170 記憶部、172 主記憶部、
174 フレームバッファ、174a 第1のフレームバッファ、
174b 第2のフレームバッファ、175 特定バッファ、
176 オブジェクトデータ記憶部、178 テクスチャ記憶部、
178a 第1のテクスチャバッファ、178b 第2のテクスチャバッファ、
179 Zバッファ、179a 第1のZバッファ、179b 第2のZバッファ、
180 情報記憶媒体、190 表示部、192 音出力部、196 通信部、
200 処理部、210 オブジェクト空間設定部、212 移動・動作処理部、
218 仮想カメラ制御部、219 通信制御部、220 画像生成部、
224 第1の画像生成部、226 第2の画像生成部、228 立体視画像生成部、
230 音生成部、270 記憶部、272 主記憶部、
274 フレームバッファ、274a 第1のフレームバッファ、
274b 第2のフレームバッファ、275 特定バッファ、
276 オブジェクトデータ記憶部、278 テクスチャ記憶部、
278a 第1のテクスチャバッファ、278b 第2のテクスチャバッファ、
279 Zバッファ、279a 第1のZバッファ、279b 第2のZバッファ、
280 情報記憶媒体、296 通信部、
10 端末、20 サーバ、40 スクリーン
100 processing unit, 110 object space setting unit, 112 movement / motion processing unit,
118 virtual camera control unit, 119 communication control unit, 120 image generation unit,
124 first image generation unit, 126 second image generation unit, 128 stereoscopic image generation unit,
130 sound generation unit, 160 operation unit, 170 storage unit, 172 main storage unit,
174 frame buffer, 174a first frame buffer,
174b second frame buffer, 175 specific buffer,
176 Object data storage unit, 178 Texture storage unit,
178a first texture buffer, 178b second texture buffer,
179 Z buffer, 179a first Z buffer, 179b second Z buffer,
180 information storage medium, 190 display unit, 192 sound output unit, 196 communication unit,
200 processing unit, 210 object space setting unit, 212 movement / motion processing unit,
218 virtual camera control unit, 219 communication control unit, 220 image generation unit,
224 first image generation unit, 226 second image generation unit, 228 stereoscopic image generation unit,
230 sound generator, 270 storage, 272 main storage,
274 frame buffer, 274a first frame buffer,
274b second frame buffer, 275 specific buffer,
276 Object data storage unit, 278 Texture storage unit,
278a first texture buffer, 278b second texture buffer,
279 Z buffer, 279a first Z buffer, 279b second Z buffer,
280 information storage medium, 296 communication unit,
10 terminals, 20 servers, 40 screens

Claims (12)

仮想3次元空間にプリミティブを配置し、立体視画像を生成する処理を行うプログラムであって、
前記仮想3次元空間において第1の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第1の画像を生成する処理を行う第1の画像生成部と、
前記仮想3次元空間において第2の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第2の画像を生成する処理を行う第2の画像生成部と、
第1の画像と第2の画像に基づき、立体視画像を生成する処理を行う立体視画像生成部として、コンピュータを機能させ、
前記第1の画像生成部が、
スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの情報を記憶させる処理を行い、
前記第2の画像生成部が、
前記ピクセル処理前に、第2の画像の画素毎に、プリミティブの情報と前記特定バッファの画素のプリミティブの情報とを比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、
第1の画像から流用可能な画素の画像情報が存在する場合に、前記ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行うことを特徴とするプログラム。
A program that arranges primitives in a virtual three-dimensional space and performs a process of generating a stereoscopic image,
In the virtual three-dimensional space, a process of generating a first image by performing a vertex process for perspective projection conversion of a primitive to a screen based on a first virtual camera and a pixel process for obtaining image information of each pixel. A first image generation unit to perform;
In the virtual three-dimensional space, a process of generating a second image by performing a vertex process for perspective projection conversion of a primitive to a screen based on a second virtual camera and a pixel process for obtaining image information of each pixel. A second image generation unit to perform;
Based on the first image and the second image, the computer functions as a stereoscopic image generation unit that performs a process of generating a stereoscopic image,
The first image generation unit
A process of storing the information of the primitive in the forefront with respect to the first virtual camera in each pixel of the specific buffer corresponding to the screen,
The second image generation unit
Prior to the pixel processing, by performing processing for comparing the primitive information and the primitive information of the pixels of the specific buffer for each pixel of the second image, image information of the divertable pixels from the first image Process to determine whether or not exists,
When there is image information of a pixel that can be diverted from the first image, instead of the pixel processing, the image information of the pixel of the first image is diverted to the image information of the pixel of the second image The program characterized by performing.
請求項1において、
前記第1の画像生成部が、
スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの識別情報を記憶させる処理を行い、
前記第2の画像生成部が、
前記ピクセル処理前に、第2の画像の画素毎に、プリミティブの識別情報と前記特定バッファの画素のプリミティブの識別情報とを比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行うことを特徴とするプログラム。
In claim 1,
The first image generation unit
A process of storing identification information of a primitive on the forefront with respect to the first virtual camera in each pixel of a specific buffer corresponding to the screen,
The second image generation unit
Before the pixel processing, for each pixel of the second image, a process of comparing the primitive identification information with the primitive identification information of the pixel of the specific buffer is performed, so that pixels that can be diverted from the first image are compared. A program for performing a process of determining whether image information exists.
請求項1又は2において、
前記第1の画像生成部が、
スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの前記仮想3次元空間の位置座標を記憶させる処理を行い、
前記第2の画像生成部が、
前記ピクセル処理前に、第2の画像の画素毎に、プリミティブの仮想3次元空間の位置座標と前記特定バッファの画素の仮想3次元空間の位置座標とを比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行うことを特徴とするプログラム。
In claim 1 or 2,
The first image generation unit
A process of storing the position coordinates in the virtual three-dimensional space of the primitive on the forefront with respect to the first virtual camera in each pixel of the specific buffer corresponding to the screen,
The second image generation unit
Before the pixel processing, for each pixel of the second image, a process of comparing the position coordinate of the primitive virtual three-dimensional space with the position coordinate of the pixel of the specific buffer in the virtual three-dimensional space is performed. A program for performing a process of determining whether there is image information of divertable pixels from an image of
請求項1〜3のいずれかおいて、
前記第1の画像生成部が、
スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの奥行き情報を記憶させる処理を行い、
前記第2の画像生成部が、
前記ピクセル処理前に、第2の画像の画素毎に、プリミティブの仮想3次元空間の位置座標と、前記第1の仮想カメラ及び前記第2の仮想カメラの仮想カメラ情報及び前記特定バッファの画素の奥行き情報に基づき算出された仮想3次元空間の位置座標と、を比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行うことを特徴とするプログラム。
In any one of Claims 1-3,
The first image generation unit
A process of storing depth information of the foremost primitive for the first virtual camera in each pixel of the specific buffer corresponding to the screen,
The second image generation unit
Before the pixel processing, for each pixel of the second image, the position coordinates of the primitive virtual three-dimensional space, the virtual camera information of the first virtual camera and the second virtual camera, and the pixel of the specific buffer A process for determining whether there is image information of divertable pixels from the first image by performing a process of comparing the position coordinates of the virtual three-dimensional space calculated based on the depth information. A program characterized by
請求項1〜4のいずれかにおいて、
前記第2の画像生成部が、
プリミティブの情報と前記特定バッファの画素のプリミティブの情報とが同じ場合に、第1の画像から流用可能な画素の画像情報が存在すると判定する処理を行い、前記特定バッファの当該画素に対応する第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行うことを特徴とするプログラム。
In any one of Claims 1-4,
The second image generation unit
When the primitive information and the primitive information of the pixel of the specific buffer are the same, a process of determining that there is image information of a divertable pixel from the first image is performed, and a process corresponding to the pixel of the specific buffer is performed. A program that performs processing for diverting image information of a pixel of one image to image information of a pixel of a second image.
請求項1〜5のいずれかにおいて、
前記第2の画像生成部が、
第2の画像の画素毎に、前記第1の仮想カメラ及び前記第2の仮想カメラの仮想カメラ情報及び第2の画像の画素の奥行き情報に基づいて、前記特定バッファの探索領域を決定し、プリミティブの情報と探索領域内の画素のプリミティブの情報とを比較する処理を行うことを特徴とするプログラム。
In any one of Claims 1-5,
The second image generation unit
For each pixel of the second image, based on the virtual camera information of the first virtual camera and the second virtual camera and the depth information of the pixels of the second image, the search area of the specific buffer is determined, A program for performing processing for comparing primitive information and primitive information of pixels in a search area.
請求項1〜6のいずれかにおいて、
前記立体視画像生成部が、第1〜第N(N≧3)の仮想カメラに基づいて、立体視画像を生成する場合に、
前記第1の画像生成部が、
第1の仮想カメラに基づき、前記頂点処理と前記ピクセル処理とを行うことによって、第1の画像を生成する処理を行い、前記特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの情報を記憶させる処理を行い、
前記第2の画像生成部が、
前記頂点処理と前記ピクセル処理とを、第2〜第Nの仮想カメラ毎に行うことによって、第2〜第Nの各画像を生成する処理を行い、
前記第2の画像生成部が、
第2〜第Nの各画像において、画素毎に、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、第1の画像から流用可能な画素の画像情報が存在する場合に、前記ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、画像の画素の画像情報に流用する処理を行うことを特徴とするプログラム。
In any one of Claims 1-6,
When the stereoscopic image generation unit generates a stereoscopic image based on the first to Nth (N ≧ 3) virtual cameras,
The first image generation unit
Based on the first virtual camera, the vertex processing and the pixel processing are performed to generate a first image, and each pixel of the specific buffer is loaded with respect to the first virtual camera. Perform the process of storing the information of the primitive on the front,
The second image generation unit
By performing the vertex processing and the pixel processing for each of the second to Nth virtual cameras, the second to Nth images are generated,
The second image generation unit
In each of the second to Nth images, for each pixel, a process for determining whether there is image information of a divertable pixel from the first image is performed, and an image of the divertable pixel from the first image A program characterized in that, when information exists, a process of diverting image information of the pixel of the first image to image information of a pixel of the image instead of the pixel processing.
請求項1〜7のいずれかにおいて、
前記第1の画像生成部が、
前記第1の画像を加工する処理を行い、
前記第2の画像生成部が、
前記第2の画像を加工する処理を行い、
前記立体視画像生成部が、
加工された第1の画像と、加工された第2の画像とに基づいて、立体視画像を生成する処理を行うことを特徴とするプログラム。
In any one of Claims 1-7,
The first image generation unit
Processing to process the first image;
The second image generation unit
Processing to process the second image;
The stereoscopic image generating unit is
A program for performing a process of generating a stereoscopic image based on a processed first image and a processed second image.
請求項1〜8のいずれかにおいて、
前記画像情報は、色情報、法線情報、奥行き情報、半透明情報の少なくとも1つであることを特徴とするプログラム。
In any one of Claims 1-8,
The image information is at least one of color information, normal information, depth information, and translucent information.
コンピュータ読み取り可能な情報記憶媒体であって、請求項1〜9のいずれかのプログラムを記憶したことを特徴とする情報記憶媒体。   A computer-readable information storage medium, wherein the program according to any one of claims 1 to 9 is stored. 仮想3次元空間にプリミティブを配置し、立体視画像を生成する処理を行う画像生成装置であって、
前記仮想3次元空間において第1の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第1の画像を生成する処理を行う第1の画像生成部と、
前記仮想3次元空間において第2の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第2の画像を生成する処理を行う第2の画像生成部と、
第1の画像と第2の画像に基づき、立体視画像を生成する処理を行う立体視画像生成部と、を含み、
前記第1の画像生成部が、
スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの情報を記憶させる処理を行い、
前記第2の画像生成部が、
前記ピクセル処理前に、第2の画像の画素毎に、プリミティブの情報と前記特定バッファの画素のプリミティブの情報とを比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、
第1の画像から流用可能な画素の画像情報が存在する場合に、前記ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行うことを特徴とする画像生成装置。
An image generation apparatus that performs a process of arranging a primitive in a virtual three-dimensional space and generating a stereoscopic image,
In the virtual three-dimensional space, a process of generating a first image by performing a vertex process for perspective projection conversion of a primitive to a screen based on a first virtual camera and a pixel process for obtaining image information of each pixel. A first image generation unit to perform;
In the virtual three-dimensional space, a process of generating a second image by performing a vertex process for perspective projection conversion of a primitive to a screen based on a second virtual camera and a pixel process for obtaining image information of each pixel. A second image generation unit to perform;
A stereoscopic image generation unit that performs processing for generating a stereoscopic image based on the first image and the second image,
The first image generation unit
A process of storing the information of the primitive in the forefront with respect to the first virtual camera in each pixel of the specific buffer corresponding to the screen,
The second image generation unit
Prior to the pixel processing, by performing processing for comparing the primitive information and the primitive information of the pixels of the specific buffer for each pixel of the second image, image information of the divertable pixels from the first image Process to determine whether or not exists,
When there is image information of a pixel that can be diverted from the first image, instead of the pixel processing, the image information of the pixel of the first image is diverted to the image information of the pixel of the second image An image generating apparatus characterized by
仮想3次元空間にプリミティブを配置し、立体視画像を生成する処理を行うサーバであって、
前記仮想3次元空間において第1の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第1の画像を生成する処理を行う第1の画像生成部と、
前記仮想3次元空間において第2の仮想カメラに基づきプリミティブをスクリーンに透視投影変換する頂点処理と、各画素の画像情報を求めるピクセル処理と、を行うことによって、第2の画像を生成する処理を行う第2の画像生成部と、
第1の画像と第2の画像に基づき、立体視画像を生成する処理を行う立体視画像生成部と、を含み、
前記第1の画像生成部が、
スクリーンに対応する特定バッファの各画素に、前記第1の仮想カメラに対して最前面にあるプリミティブの情報を記憶させる処理を行い、
前記第2の画像生成部が、
前記ピクセル処理前に、第2の画像の画素毎に、プリミティブの情報と前記特定バッファの画素のプリミティブの情報とを比較する処理を行うことによって、第1の画像から流用可能な画素の画像情報が存在するか否かを判定する処理を行い、
第1の画像から流用可能な画素の画像情報が存在する場合に、前記ピクセル処理の替わりに、第1の画像の当該画素の画像情報を、第2の画像の画素の画像情報に流用する処理を行うことを特徴とするサーバ。
A server that performs a process of arranging a primitive in a virtual three-dimensional space and generating a stereoscopic image,
In the virtual three-dimensional space, a process of generating a first image by performing a vertex process for perspective projection conversion of a primitive to a screen based on a first virtual camera and a pixel process for obtaining image information of each pixel. A first image generation unit to perform;
In the virtual three-dimensional space, a process of generating a second image by performing a vertex process for perspective projection conversion of a primitive to a screen based on a second virtual camera and a pixel process for obtaining image information of each pixel. A second image generation unit to perform;
A stereoscopic image generation unit that performs processing for generating a stereoscopic image based on the first image and the second image,
The first image generation unit
A process of storing the information of the primitive in the forefront with respect to the first virtual camera in each pixel of the specific buffer corresponding to the screen,
The second image generation unit
Prior to the pixel processing, by performing processing for comparing the primitive information and the primitive information of the pixels of the specific buffer for each pixel of the second image, image information of the divertable pixels from the first image Process to determine whether or not exists,
When there is image information of a pixel that can be diverted from the first image, instead of the pixel processing, the image information of the pixel of the first image is diverted to the image information of the pixel of the second image A server characterized by performing
JP2011201389A 2011-09-15 2011-09-15 Program, information storage medium, image generation device, and server Withdrawn JP2013061898A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP2011201389A JP2013061898A (en) 2011-09-15 2011-09-15 Program, information storage medium, image generation device, and server

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP2011201389A JP2013061898A (en) 2011-09-15 2011-09-15 Program, information storage medium, image generation device, and server

Publications (1)

Publication Number Publication Date
JP2013061898A true JP2013061898A (en) 2013-04-04

Family

ID=48186495

Family Applications (1)

Application Number Title Priority Date Filing Date
JP2011201389A Withdrawn JP2013061898A (en) 2011-09-15 2011-09-15 Program, information storage medium, image generation device, and server

Country Status (1)

Country Link
JP (1) JP2013061898A (en)

Similar Documents

Publication Publication Date Title
US7528830B2 (en) System and method for rendering 3-D images on a 3-D image display screen
US9106906B2 (en) Image generation system, image generation method, and information storage medium
Didyk et al. Adaptive Image-space Stereo View Synthesis.
US20120306860A1 (en) Image generation system, image generation method, and information storage medium
US20070103465A1 (en) Computer graphics processor and method for rendering 3-d scenes on a 3-d image display screen
CN110517356A (en) Realize system, the method and apparatus of the three-dimensional enhanced reality of multi-channel video fusion
US7675513B2 (en) System and method for displaying stereo images
TWI713358B (en) Accelerated occlusion computation
CN109510975B (en) Video image extraction method, device and system
JP4982862B2 (en) Program, information storage medium, and image generation system
CN106688231A (en) Stereo image recording and playback
GB2546720B (en) Method of and apparatus for graphics processing
CN103327357A (en) Three-dimensional picture presenting method and device
CN116109793A (en) Edge detection and smoothing for virtual object rendering
JP5766540B2 (en) Program and game system
JP5620202B2 (en) Program, information storage medium, and image generation system
JP2012234411A (en) Image generation device, image generation system, image generation program and image generation method
JP3858851B2 (en) 3D graphics display device
JP2013061898A (en) Program, information storage medium, image generation device, and server
JP2009064355A (en) Program, information storage medium, and image producing system
JP5817135B2 (en) Three-dimensional image processing apparatus, program thereof and storage medium thereof
CN113115018A (en) Self-adaptive display method and display equipment for image
Hübner et al. Single-pass multi-view rendering
Trapp et al. Interactive Stereo Rendering for Non-planar Projections of 3D Virtual Environments-With a Comparison of Image-and Geometry-based Approaches
JP5701637B2 (en) Program and image generation system

Legal Events

Date Code Title Description
RD07 Notification of extinguishment of power of attorney

Free format text: JAPANESE INTERMEDIATE CODE: A7427

Effective date: 20140619

A521 Written amendment

Free format text: JAPANESE INTERMEDIATE CODE: A523

Effective date: 20140811

A300 Withdrawal of application because of no request for examination

Free format text: JAPANESE INTERMEDIATE CODE: A300

Effective date: 20141202