JPH1145350A - Method and device for deciding collision of three-dimensional moving body and recording medium where collision decision program is recorded - Google Patents

Method and device for deciding collision of three-dimensional moving body and recording medium where collision decision program is recorded

Info

Publication number
JPH1145350A
JPH1145350A JP9199801A JP19980197A JPH1145350A JP H1145350 A JPH1145350 A JP H1145350A JP 9199801 A JP9199801 A JP 9199801A JP 19980197 A JP19980197 A JP 19980197A JP H1145350 A JPH1145350 A JP H1145350A
Authority
JP
Japan
Prior art keywords
collision
moving object
collision determination
determination
value
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.)
Pending
Application number
JP9199801A
Other languages
Japanese (ja)
Inventor
Hiroaki Yabe
博明 矢部
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.)
Sharp Corp
Original Assignee
Sharp Corp
Priority date (The priority date is an assumption and is not a legal conclusion. Google has not performed a legal analysis and makes no representation as to the accuracy of the date listed.)
Filing date
Publication date
Application filed by Sharp Corp filed Critical Sharp Corp
Priority to JP9199801A priority Critical patent/JPH1145350A/en
Publication of JPH1145350A publication Critical patent/JPH1145350A/en
Pending legal-status Critical Current

Links

Classifications

    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F2300/00Features of games using an electronically generated display having two or more dimensions, e.g. on a television screen, showing representations related to the game
    • A63F2300/60Methods for processing data by generating or executing the game program
    • A63F2300/64Methods for processing data by generating or executing the game program for computing dynamical parameters of game objects, e.g. motion determination or computation of frictional forces for a virtual car
    • AHUMAN NECESSITIES
    • A63SPORTS; GAMES; AMUSEMENTS
    • A63FCARD, BOARD, OR ROULETTE GAMES; INDOOR GAMES USING SMALL MOVING PLAYING BODIES; VIDEO GAMES; GAMES NOT OTHERWISE PROVIDED FOR
    • A63F2300/00Features of games using an electronically generated display having two or more dimensions, e.g. on a television screen, showing representations related to the game
    • A63F2300/60Methods for processing data by generating or executing the game program
    • A63F2300/64Methods for processing data by generating or executing the game program for computing dynamical parameters of game objects, e.g. motion determination or computation of frictional forces for a virtual car
    • A63F2300/643Methods for processing data by generating or executing the game program for computing dynamical parameters of game objects, e.g. motion determination or computation of frictional forces for a virtual car by determining the impact between objects, e.g. collision detection

Landscapes

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

Abstract

PROBLEM TO BE SOLVED: To provide a collision decision device for a three-dimensional moving body which can decide fast that arbitrary bodies collide against each other. SOLUTION: A coordinate converting means 1 converts local coordinates of respective bodies into world coordinates and stores the converted coordinates in a body coordinate storage means 2. A Z sorting means 3 stores the model numbers of the respective bodies in a space in a Z sort table storage means 4 according to a Z value stored in the body coordinate storage means 2. A moving path generating means 5 calculates the movement paths of object moving bodies of collision decision making from the stored coordinates in the body coordinate storage means 2. A collision decision means 6 decides that the moving body collides against another body within the Z value range wherein there is collision probability. An image generating means 7 generates a three- dimensional image according to the found data.

Description

【発明の詳細な説明】DETAILED DESCRIPTION OF THE INVENTION

【0001】[0001]

【発明の属する技術分野】本発明は、建築物の内部や宇
宙空間等をリアルタイム・ウォークスルーするようなV
R(バーチャル・リアリティ)装置で、視点等の移動物
体が、障害となる物体に衝突することを判定したり、ゲ
ームで移動物体同士の衝突を判定したりするための、3
次元移動物体の衝突判定装置、その衝突判定方法及びそ
の衝突判定プログラムを記録した記録媒体に関するもの
である。
BACKGROUND OF THE INVENTION 1. Field of the Invention The present invention relates to a virtual reality (V) system for real-time walk-through of the interior of a building or outer space.
An R (virtual reality) device is used to determine whether a moving object such as a viewpoint collides with an obstacle, or to determine a collision between moving objects in a game.
The present invention relates to a collision determination device for a three-dimensional moving object, a collision determination method thereof, and a recording medium on which a collision determination program is recorded.

【0002】[0002]

【従来の技術】VR(バーチャル・リアリティ)で用い
られるリアルタイム・ウォークスルーは、コンピュータ
で毎秒数フレームから数十フレーム生成される三次元画
像を、視点位置に応じてアニメーション表示する手法で
あり、建築物のプレゼンテーションやゲーム等の分野で
有効な技術となっている。自然なリアルタイム・ウォー
クスルーを実現するための方法の一つとして、壁等の現
実世界では通り抜けることができないものを判定する衝
突判定がある。この衝突判定はゲーム等に用いられてお
り、物体同士の衝突判定により、レースや格闘のシミュ
レーションが行われている。
2. Description of the Related Art Real-time walkthrough used in VR (Virtual Reality) is a technique for displaying an animation of a three-dimensional image generated from several frames to several tens of frames per second by a computer according to the viewpoint position. This technology is effective in the fields of presentation of objects and games. As one of the methods for realizing a natural real-time walk-through, there is a collision determination for determining a wall or the like that cannot pass through in the real world. The collision determination is used in a game or the like, and a simulation of a race or a fight is performed by determining the collision between objects.

【0003】[0003]

【発明が解決しようとする課題】一般的な衝突判定で
は、移動物体が三次元データで表される空間内を移動す
るときに、その移動経路が空間内のすべての障害物と交
差しないことを確認するため、移動毎に識別する処理を
行う。従って、衝突判定には、比較的長い処理時間を要
するし、また、空間内の物体数が増加すると、処理時間
が非常に長くなる欠点を持つ。
In a general collision determination, when a moving object moves in a space represented by three-dimensional data, it is determined that a moving path does not intersect with all obstacles in the space. For confirmation, a process of identifying each movement is performed. Accordingly, the collision determination requires a relatively long processing time, and the processing time becomes extremely long as the number of objects in the space increases.

【0004】そこで、例えば、特開平7−105409
号公報に開示されているように、移動経路を2次元に限
定することで、処理の高速化を計る手法がある。しか
し、上下方向の移動や回転する場合などでは、3次元空
間内を自由にリアルタイムウォークスルーすることがで
きない。
[0004] Therefore, for example, Japanese Patent Application Laid-Open No. 7-105409.
As disclosed in Japanese Unexamined Patent Publication, there is a method for speeding up processing by limiting the movement route to two dimensions. However, in the case of vertical movement or rotation, it is not possible to freely perform real-time walk-through in a three-dimensional space.

【0005】また、特開平8−241434号公報に
は、凹物体と凸物体の頂点との衝突判定を高速に行う手
法が開示されており、3次元空間における衝突判定をお
こなうものであるが、単に衝突の有無を検知するための
手法であり、移動物体と他の物体との衝突点とその衝突
角などの詳しい衝突情報を高速で処理することに関して
は記載されていない。より自然な、3次元グラフィック
スのアニメーションを作成するためには、単に物体同士
が衝突するかどうかを判定するだけでなく、衝突点や衝
突角を求める必要があるが、このような詳細な衝突情報
を処理するには、時間がかかる問題がある。
Japanese Patent Application Laid-Open No. Hei 8-241434 discloses a technique for performing a high-speed collision determination between a concave object and a vertex of a convex object. The method determines collision in a three-dimensional space. It is a technique for simply detecting the presence or absence of a collision, and does not disclose how to process detailed collision information such as a collision point between a moving object and another object and its collision angle at a high speed. In order to create a more natural 3D graphics animation, it is necessary not only to determine whether objects collide with each other, but also to determine the collision point and collision angle. There is a problem that processing information takes time.

【0006】本発明は、任意の物体同士の衝突判定を高
速に実行できる3次元移動物体の衝突判定装置、その衝
突判定方法及びその衝突判定プログラムを記録した記録
媒体を提供することを目的とする。また、本発明は、処
理速度が高速なため、単に衝突の有無を検知するだけで
なく、さらに詳しい衝突情報を高速処理して求めること
ができる3次元移動物体の衝突判定装置、その衝突判定
方法及びその衝突判定プログラムを記録した記録媒体を
提供することを目的とする。
SUMMARY OF THE INVENTION It is an object of the present invention to provide a three-dimensional moving object collision judging device, a collision judging method, and a recording medium on which the collision judging program is recorded, which can execute a collision judgment between arbitrary objects at high speed. . In addition, the present invention has a high processing speed, so that it is possible to not only detect the presence or absence of a collision but also to obtain more detailed collision information by high-speed processing and obtain the collision information. And a recording medium on which the collision determination program is recorded.

【0007】[0007]

【課題を解決するための手段】請求項1の発明は、移動
物体と他の物体との衝突判定をリアルタイムで行う三次
元移動物体の衝突判定装置において、空間内の物体のZ
値をZソートテーブル記憶手段に記憶するZソート手段
と、前記移動物体の移動経路を算出する移動経路生成手
段と、移動物体が衝突する可能性のあるZ値範囲をZソ
ート手段のZ値からあらかじめ設定し、該範囲内の物体
に対し、前記移動経路生成手段から算出された移動経路
から移動物体との衝突判定を行う衝突判定手段と、を備
えたことを特徴とする。
According to a first aspect of the present invention, there is provided an apparatus for judging a collision between a moving object and another object in real time.
Z sorting means for storing values in the Z sorting table storage means, moving path generating means for calculating the moving path of the moving object, and a Z value range in which the moving object may collide is determined from the Z value of the Z sorting means. And a collision determination unit configured to determine in advance a collision with a moving object based on the movement path calculated by the movement path generation unit for an object within the range.

【0008】請求項2の発明は、請求項1記載の三次元
移動物体の衝突判定装置であって、移動物体の速度に応
じて前記Z値範囲を設定することを特徴とする。
According to a second aspect of the present invention, there is provided the apparatus for judging a collision of a three-dimensional moving object according to the first aspect, wherein the Z value range is set according to the speed of the moving object.

【0009】請求項3の発明は、請求項1又は2記載の
三次元移動物体の衝突判定装置であって、前記衝突判定
手段は、簡易衝突判定手段と詳細衝突判定手段からな
り、簡易衝突判定手段によって、移動物体が衝突する可
能性を求め、衝突する可能性の高い物体についてのみ、
詳細衝突判定手段によって詳細に判定を行うことを特徴
とする。
According to a third aspect of the present invention, there is provided the collision determining apparatus for a three-dimensional moving object according to the first or second aspect, wherein the collision determining means comprises a simple collision determining means and a detailed collision determining means. By means, we determine the possibility of a moving object colliding, and only for objects that are likely to collide,
It is characterized in that the detailed collision determination means makes a detailed determination.

【0010】請求項4の発明は、請求項1又は2記載の
三次元移動物体の衝突判定装置であって、前記衝突判定
手段は、簡易衝突判定手段と詳細衝突判定手段からな
り、簡易衝突判定手段と詳細衝突判定手段の切り替えを
行う切り替え手段を備えたことを特徴とする。
According to a fourth aspect of the present invention, there is provided the collision determining apparatus for a three-dimensional moving object according to the first or second aspect, wherein the collision determining means includes a simple collision determining means and a detailed collision determining means. Switching means for switching between the means and the detailed collision determination means.

【0011】請求項5の発明は、移動物体と他の物体と
の衝突判定をリアルタイムで行う三次元移動物体の衝突
判定方法において、空間内の物体のZ値をZソートテー
ブル記憶手段に記憶し、前記移動物体の移動経路を算出
し、移動物体が衝突する可能性のあるZ値範囲をZソー
ト手段のZ値からあらかじめ設定し、該範囲内の物体に
対し衝突判定を行うことを特徴とする。
According to a fifth aspect of the present invention, in the method for judging a collision between a moving object and another object in real time, the Z value of the object in space is stored in a Z sort table storage means. Calculating a moving path of the moving object, presetting a Z value range in which the moving object may collide with the Z value of the Z sorting means, and performing collision determination on objects within the range. I do.

【0012】請求項6の発明は、請求項5記載の三次元
移動物体の衝突判定方法であって、移動物体の速度に応
じて前記Z値範囲を設定することを特徴とする。
A sixth aspect of the present invention is the method for judging a collision of a three-dimensional moving object according to the fifth aspect, wherein the Z value range is set according to the speed of the moving object.

【0013】請求項7の発明は、請求項5又は6記載の
三次元移動物体の衝突判定方法であって、前記衝突判定
は、簡易衝突判定によって、移動物体が衝突する可能性
を求め、衝突する可能性の高い物体についてのみ、詳細
衝突判定によって詳細に判定を行うことを特徴とする。
According to a seventh aspect of the present invention, there is provided the method for judging a collision of a three-dimensional moving object according to the fifth or sixth aspect, wherein the collision is determined by a simple collision judgment to determine the possibility of the moving object colliding. It is characterized in that a detailed collision determination is performed only for an object that is highly likely to be performed.

【0014】請求項8の発明は、請求項5又は6記載の
三次元移動物体の衝突判定方法であって、前記衝突判定
が、簡易衝突判定と詳細衝突判定のいずれでも行えるよ
うに切り替えを可能としたことを特徴とする。
According to an eighth aspect of the present invention, there is provided the collision determination method for a three-dimensional moving object according to the fifth or sixth aspect, wherein the collision determination can be switched so that the collision determination can be performed by either a simple collision determination or a detailed collision determination. It is characterized by having.

【0015】請求項9の発明は、移動物体と他の物体と
の衝突判定をリアルタイムで行う三次元移動物体の衝突
判定プログラムを記録した記録媒体において、空間内の
物体のZ値をZソートテーブル記憶手段に記憶し、前記
移動物体の移動経路を算出し、移動物体が衝突する可能
性のあるZ値範囲をZソート手段のZ値からあらかじめ
設定し、該範囲内の物体に対し衝突判定を行うことを特
徴とする。
According to a ninth aspect of the present invention, there is provided a recording medium storing a three-dimensional moving object collision judging program for judging a collision between a moving object and another object in real time. The moving path of the moving object is calculated in a storage means, a Z value range in which the moving object may collide is set in advance from the Z value of the Z sorting means, and a collision determination is performed on an object in the range. It is characterized by performing.

【0016】請求項10の発明は、請求項9記載の三次
元移動物体の衝突判定プログラムを記録した記録媒体で
あって、移動物体の速度に応じて前記Z値範囲を設定す
ることを特徴とする。
According to a tenth aspect of the present invention, there is provided a recording medium storing the three-dimensional moving object collision determination program according to the ninth aspect, wherein the Z value range is set according to the speed of the moving object. I do.

【0017】請求項11の発明は、請求項9又は10記
載の三次元移動物体の衝突判定プログラムを記録した記
録媒体であって、前記衝突判定は、簡易衝突判定によっ
て、移動物体が衝突する可能性を求め、衝突する可能性
の高い物体についてのみ、詳細衝突判定によって詳細に
判定を行うことを特徴とする。
According to an eleventh aspect of the present invention, there is provided a recording medium on which the program for judging a collision of a three-dimensional moving object according to the ninth or tenth aspect is recorded. Characteristic is determined, and a detailed collision determination is performed in detail only for an object that is likely to collide.

【0018】請求項12の発明は、請求項9又は10記
載の三次元移動物体の衝突判定プログラムを記録した記
録媒体であって、前記衝突判定が、簡易衝突判定と詳細
衝突判定のいずれでも行えるように切り替えを可能とし
たことを特徴とする。
According to a twelfth aspect of the present invention, there is provided a recording medium storing the three-dimensional moving object collision determination program according to the ninth or tenth aspect, wherein the collision determination can be performed by either a simple collision determination or a detailed collision determination. It is characterized by being able to switch as described above.

【0019】本発明では、3次元コンピュータグラフィ
ックスを生成するために、通常使われているZソートの
出力結果を用いて、移動物体が衝突する可能性のあるZ
値範囲をとることで、明らかに衝突しない物体との衝突
判定を行わない。そのため、衝突判定処理を高速化し、
全体の処理速度を高速にすることができる。本発明で
は、2次元空間に限定せずに、3次元空間内での衝突判
定を行うため、2次元空間のみならず、3次元空間内を
自由にリアルタイム・ウォークスルーしたり、任意の物
体同士の衝突判定を行うことができる。また、Zソート
の出力結果を利用する衝突判定を処理の重い詳細な衝突
判定と、処理の軽い簡易な衝突判定を用いることで、簡
易な衝突判定により明らかに衝突判定を行う必要のない
物体を排除することができ、結果として、詳細な衝突判
定を行う回数が減ることで、より高速に衝突判定を行う
ことができる。
According to the present invention, in order to generate three-dimensional computer graphics, the output result of a commonly used Z sort is used to generate a Z
By setting the value range, collision determination with an object that does not clearly collide is not performed. Therefore, the speed of the collision determination process is increased,
The overall processing speed can be increased. In the present invention, collision determination is performed not only in the two-dimensional space but also in the three-dimensional space. Therefore, not only the two-dimensional space but also the real-time walk-through in the three-dimensional space can be freely performed. Can be determined. In addition, the collision determination using the output result of the Z sort is performed by using a detailed collision determination with heavy processing and a simple collision determination with light processing, so that an object that does not need to make a collision determination clearly with a simple collision determination. The collision can be eliminated, and as a result, the number of times of performing detailed collision determination is reduced, so that the collision determination can be performed at higher speed.

【0020】[0020]

【発明の実施の形態】以下に、本発明の実施の形態につ
いて図面を参照して説明する。
Embodiments of the present invention will be described below with reference to the drawings.

【0021】<第1実施形態>図1は、本発明に係る3
次元移動物体の衝突判定装置の第1実施形態を示す機能
ブロック図である。この衝突判定装置は、座標変換手段
1と、物体座標記憶手段2と、Zソート手段3と、Zソ
ートテーブル記憶手段4と、移動経路生成手段5と、衝
突判定手段6と、画像生成手段7とからなる。
<First Embodiment> FIG. 1 shows a third embodiment according to the present invention.
It is a functional block diagram showing a 1st embodiment of a collision judging device of a three-dimensional moving object. This collision determination device includes a coordinate conversion unit 1, an object coordinate storage unit 2, a Z sort unit 3, a Z sort table storage unit 4, a movement route generation unit 5, a collision determination unit 6, an image generation unit 7, Consists of

【0022】座標変換手段1は、各物体のローカル座標
をワールド座標に変換し、変換された座標を物体座標記
憶手段2に格納する。各物体には、モデル番号が付けら
れており、モデル番号と物体とは一対一で対応してい
る。Zソート手段3は、空間内の各物体のモデル番号
を、物体座標記憶手段2に格納されているZ値に応じ
て、Zソートテーブル格納手段4に格納する。Zソート
テーブルには、インデックスがふられており、モデル番
号を格納することができる。例えば、各物体のZ値の最
小値を四捨五入したものをZソートテーブルのインデッ
クスとして、モデル番号を格納する。移動経路生成手段
5は、衝突判定を行う移動物体の移動経路を物体座標記
憶手段2の格納座標から算出する。衝突判定手段6は、
移動物体の他の物体との衝突判定、衝突点及び衝突角
を、移動経路、物体座標及びZ値の最小値から算出し、
移動後の位置を定めるとともに、衝突の判定を行う。画
像生成手段7は、求めたデータに基づいて3次元画像を
生成する。
The coordinate conversion means 1 converts the local coordinates of each object into world coordinates, and stores the converted coordinates in the object coordinate storage means 2. Each object is given a model number, and the model number and the object correspond one-to-one. The Z sort means 3 stores the model number of each object in the space in the Z sort table storage means 4 according to the Z value stored in the object coordinate storage means 2. The Z sort table is indexed and can store a model number. For example, a model number is stored by rounding the minimum value of the Z value of each object as an index of the Z sort table. The moving path generating means 5 calculates the moving path of the moving object to be subjected to the collision determination from the coordinates stored in the object coordinate storing means 2. The collision determination means 6
The collision determination of the moving object with another object, the collision point and the collision angle are calculated from the moving path, the object coordinates and the minimum value of the Z value,
The position after the movement is determined, and the collision is determined. The image generating means 7 generates a three-dimensional image based on the obtained data.

【0023】自分自身を中心として、前方のみに空間内
を移動するようなアプリケーションでは、各物体のZ値
の最小値を用いると、最小値がある値以上であれば、物
体が自分からある特定の距離以上離れていることが明ら
かなため、特に有効である。
In an application in which the object moves in the space only in front of itself, the minimum value of the Z value of each object can be used. It is particularly effective because it is clear that the distance is more than the distance of.

【0024】次に具体例により説明する。図2は、物体
が配置された3次元空間の例を示す説明図である。この
3次元空間には、図2に示すように、直方体物体が複数
配置され、移動物体(図では黒丸)との移動経路(図で
は矢印)の衝突判定を行う。この場合の、Zソートテー
ブルの例を図3に示す。図2の各物体に対し、Zソート
テーブルには、図3に示すように、各モデル番号が格納
される。
Next, a specific example will be described. FIG. 2 is an explanatory diagram illustrating an example of a three-dimensional space in which objects are arranged. In this three-dimensional space, as shown in FIG. 2, a plurality of rectangular parallelepiped objects are arranged, and collision determination of a moving path (arrow in the figure) with a moving object (black circle in the figure) is performed. FIG. 3 shows an example of the Z sort table in this case. As shown in FIG. 3, each model number is stored in the Z sort table for each object in FIG.

【0025】移動物体は、連続的に位置が変化するの
で、移動物体のZ値からある一定値以上遠く離れた物体
とは衝突しないため、Zソートテーブルで、Z値がある
範囲内の物体のみ(移動物体のZ値±δ、δは適当な
値)と衝突判定を行う。この衝突範囲は、図2に斜線で
示している。この衝突範囲にある物体(20、32、4
5、76)に対して、衝突判定を行えばよいので、判定
の回数を減らすことができる。結果としてシステム全体
の速度があがる。
Since the position of the moving object changes continuously, the moving object does not collide with an object farther than a certain value from the Z value of the moving object. (Z values of the moving object ± δ, δ are appropriate values) and collision determination. This collision range is indicated by oblique lines in FIG. Objects (20, 32, 4) in this collision area
5, 76), it is sufficient to make a collision determination, so that the number of determinations can be reduced. As a result, the speed of the entire system is increased.

【0026】移動物体と各物体との衝突判定は次のよう
に行う。図4は、直方体物体と移動物体の交点算出方法
を示す説明図であり、これを参照しながら説明をする。
2点P1,P2を結ぶ直線と直方体の交点を求める。簡
単にするため、図は2次元とする。図4(a)はワール
ド座標であり、直方体は頂点の一つを原点にしている。
e1,e2,e3(e3は図示せず)は直方体の辺ベク
トルを正規化したベクトルである。直方体内の各辺を規
定ベクトルに変換するM(M=〔e1,e2,e3〕)
を求め、各点を直方体内の座標(ローカル座標)に変換
するMTを求めて、図4(b)に示すように、ローカル
座標に変換する。点P1,P2は点P1a,P2aに、
ベクトルe1,e2,e3はベクトルe1a,e2a,
e3aに変換される。
The collision between a moving object and each object is determined as follows. FIG. 4 is an explanatory diagram showing a method of calculating an intersection between a rectangular parallelepiped object and a moving object, and the description will be given with reference to this figure.
The intersection of the straight line connecting the two points P1 and P2 and the rectangular parallelepiped is obtained. For simplicity, the figures are two-dimensional. FIG. 4A shows world coordinates, and a rectangular parallelepiped has one of its vertices as its origin.
e1, e2, and e3 (e3 is not shown) are vectors obtained by normalizing the side vectors of the rectangular parallelepiped. M for converting each side in a rectangular parallelepiped into a prescribed vector (M = [e1, e2, e3])
Asking, seeking M T for transforming each point on in the rectangular coordinates (local coordinates), as shown in FIG. 4 (b), it is converted to the local coordinate. Points P1 and P2 become points P1a and P2a,
Vectors e1, e2, e3 are vectors e1a, e2a,
e3a.

【0027】直方体の各辺の大きさをlx,ly,lz
とし、x=0,lx、y=0,ly、z=0,lzで交
点をPaを持つかどうかを求める。交点Paがあれ
ば、、交点Paとこれに対応する法線ベクトルnaを、
Mでワールド座標に変換し(図4(C))、交点Pと法
線nを求める。
The size of each side of the rectangular parallelepiped is lx, ly, lz
It is determined whether or not the intersection has Pa at x = 0, lx, y = 0, ly, z = 0, lz. If there is an intersection Pa, the intersection Pa and the corresponding normal vector na are calculated as follows:
The coordinates are converted into world coordinates by M (FIG. 4C), and an intersection P and a normal n are obtained.

【0028】つまり、移動物体の移動前の地点から、移
動前の地点に移動物体の速度を加えた地点への移動ベク
トルと、各物体との衝突点は、各物体の各辺を単位ベク
トルとするような変換を行った後、逆変換をして求める
ことができるということである。これを、Zソートテー
ブルのある範囲内の物体について行う。衝突判定手段6
では、このようにして、衝突するか否かの判定を行って
いる。ここでは、物体として直方体物体を用いたが、他
の形状との衝突判定を行う際にも、Zソートの結果を利
用することが有効であることは、明白である。
That is, the movement vector from the point before the movement of the moving object to the point obtained by adding the speed of the moving object to the point before the movement, and the collision point with each object are obtained by defining each side of each object as a unit vector. That is, after performing such a conversion, it can be obtained by performing an inverse conversion. This is performed for objects within a certain range of the Z sort table. Collision determination means 6
Thus, the determination as to whether or not a collision occurs is performed in this manner. Here, a rectangular parallelepiped object is used as the object, but it is clear that it is effective to use the result of Z-sorting when determining a collision with another shape.

【0029】上記実施形態においては、前述Zソートテ
ーブルから参照するときの範囲として、移動物体のZ値
±δとした。図5に示すように、このδを移動物体の速
度に応じて設定する値、すなわち移動物体の速度のZ値
とすると、移動物体の速度に応じて、Zソートテーブル
から参照する物体数を最小にすることができ、衝突判定
をより高速に実行する事ができる。衝突判定の計算誤差
等により、移動物体のZ値から移動物体のZ値+移動物
体の速度のZ値内の物体以外とも衝突する可能性もある
ため、Zソートテーブルから参照する範囲を、単なる速
度の加算だけでなく、移動物***置と速度によって定ま
るような、他の手法を用いても良い。
In the above-described embodiment, the Z value ± δ of the moving object is set as the range when referring to the Z sort table. As shown in FIG. 5, when δ is a value set according to the speed of the moving object, that is, a Z value of the speed of the moving object, the number of objects referred to from the Z sort table is minimized according to the speed of the moving object. And the collision determination can be performed at higher speed. Due to the calculation error of the collision determination and the like, there is a possibility that the object other than the object within the Z value of the moving object and the Z value of the speed of the moving object may collide with the Z value of the moving object. Not only the addition of the speed but also another method determined by the position and the speed of the moving object may be used.

【0030】<第2実施形態>Zソートテーブルから参
照された物体と、移動物体の移動ベクトルとの交点を求
める際に、例えば、衝突の有無だけを判定するような簡
易衝突判定を行った後に、衝突点及び衝突角を求める詳
細衝突判定を行うことで、衝突判定をより高速に行うこ
とができる。このときの、機能ブロック図を図6に示
す。この第2実施形態である衝突判定装置は、図1の衝
突判定装置6の替わりに、簡易衝突判定手段8と、詳細
衝突判定手段9を備えたものである。
<Second Embodiment> When obtaining the intersection between the object referred to from the Z sort table and the movement vector of the moving object, for example, after performing a simple collision determination for determining only the presence or absence of a collision, By performing the detailed collision determination for obtaining the collision point and the collision angle, the collision determination can be performed at a higher speed. FIG. 6 shows a functional block diagram at this time. The collision determination device according to the second embodiment includes a simple collision determination unit 8 and a detailed collision determination unit 9 instead of the collision determination device 6 in FIG.

【0031】簡易衝突判定手段8は、例えば、移動後の
地点が、他の物体内に含まれるかどうかを判定する。図
7に、この簡易衝突判定を示す説明図を示す。図7は、
簡単にするために2次元にしている。ここで、Pは移動
物体の移動ベクトルであり、E1,E2,E3,E4は
直方体の辺ベクトルである。
The simple collision determining means 8 determines, for example, whether the point after the movement is included in another object. FIG. 7 is an explanatory diagram showing the simple collision determination. FIG.
It is two-dimensional for simplicity. Here, P is a movement vector of a moving object, and E1, E2, E3, and E4 are side vectors of a rectangular parallelepiped.

【0032】ある点が直方体の中にあるか否かを調べる
には、まず、直方体内の1点を原点に平行移動して考え
る(図7(a)参照)。判定を行う直方体物体を隣りあ
う3つの面からなる、互いに向かい合う2つの部分に分
け、各部分の内側にあるかどうかを判定する(図7
(b)、(c)参照)。この簡易衝突判定手段8によっ
て衝突が確実になった物体を、例えば、詳細衝突判定手
段9として図4のような方法で判定を行う。図7のよう
な処理を行う簡易衝突判定手段は、図4のような詳細衝
突判定手段の約100倍で動作し、システム全体の速度
をより高速にすることができる。
In order to check whether or not a point is in a rectangular parallelepiped, first, one point in the rectangular parallelepiped is translated in parallel to the origin (see FIG. 7A). The rectangular parallelepiped object to be determined is divided into two opposing portions each including three adjacent surfaces, and it is determined whether the object is inside each portion (FIG. 7).
(See (b) and (c)). The object whose collision has been surely determined by the simple collision determination means 8 is determined by, for example, the detailed collision determination means 9 by a method as shown in FIG. The simple collision determination means that performs the processing as shown in FIG. 7 operates at about 100 times the detailed collision determination means as in FIG. 4, and can increase the speed of the entire system.

【0033】当然のことながら、簡易衝突判定として、
衝突の有無だけを求める判定ではなく、衝突確率を求め
る判定を用いてもよい。また、衝突判定を簡易衝突判定
と詳細衝突判定の2つだけでなく、3つ以上の衝突判定
を組み合わせても良い。
As a matter of course, as a simple collision judgment,
Instead of determining only the presence / absence of a collision, a determination of determining a collision probability may be used. Further, the collision determination may be not only two of the simple collision determination and the detailed collision determination, but may be a combination of three or more collision determinations.

【0034】<第3実施形態>また、切り替え手段10
を用いることで、簡易衝突判定手段8のみを用いたり、
詳細衝突判定手段9のみを用いることもできる。図8
は、本発明に係る3次元移動物体の衝突判定装置の第3
実施形態を示す機能ブロック図である。例えば、簡易衝
突判定手段8として処理速度は速いが、必ずしも精度が
良くない手段を用いるときなど、システム全体の処理速
度に余裕があれば、詳細衝突判定手段9のみを用いた
り、システム全体の負荷が高いときは、簡易衝突判定手
段8のみを用いて、衝突点や衝突角を、例えば、ある一
定値で代用したり、乱数などを用いて代用してもよい。
当然ながら、簡易衝突判定手段8と詳細衝突判定手段9
を用いて、前述のような動作をさせることも可能であ
る。
<Third Embodiment> The switching means 10
By using only the simple collision determination means 8,
Only the detailed collision determination means 9 can be used. FIG.
Is a third example of the three-dimensional moving object collision determination device according to the present invention.
It is a functional block diagram showing an embodiment. For example, when the processing speed of the simple collision determination unit 8 is high, but the accuracy is not always high, if there is a margin in the processing speed of the entire system, only the detailed collision determination unit 9 may be used, or the load of the entire system may be reduced. When the value is high, the collision point and the collision angle may be substituted by, for example, a certain fixed value, or by using a random number or the like, using only the simple collision determination means 8.
Naturally, the simple collision judging means 8 and the detailed collision judging means 9
The above-described operation can be performed by using.

【0035】[0035]

【発明の効果】請求項1、5及び9の発明によれば、移
動物体が衝突する可能性のあるZ値範囲をZソート手段
のZ値からあらかじめ設定し、その範囲内の物体に対し
衝突判定を行うので、空間内の全物体との衝突判定を行
わずに、移動物体のZ値近辺の物体のみとの衝突判定を
行う。したがって、空間内の物体数にかかわらず、衝突
判定を高速化することが可能である。通常、リアルタイ
ムに3次元コンピュータグラフィックを生成する装置に
は、Zソートを行う手段が備えられているため、本方式
では、新たに装置全体の負荷を増やすことなく、衝突判
定の高速化を行うことができる。
According to the first, fifth and ninth aspects of the present invention, a Z value range in which a moving object may collide is set in advance from the Z value of the Z sorting means, and the object within the range is collided. Since the determination is performed, the collision determination is performed only with the object near the Z value of the moving object without performing the collision determination with all the objects in the space. Therefore, it is possible to speed up the collision determination regardless of the number of objects in the space. Usually, a device for generating a three-dimensional computer graphic in real time is provided with a means for performing Z-sorting. Therefore, in this method, it is possible to speed up collision determination without newly increasing the load on the entire device. Can be.

【0036】請求項2、6及び10の発明においては、
Z値範囲を移動物体の移動速度に応じて変えることで、
参照するZソートデータの数を最低限に減少させること
ができるので、より高速に衝突判定を行うことができ
る。
In the invention of claims 2, 6 and 10,
By changing the Z value range according to the moving speed of the moving object,
Since the number of the Z sort data to be referred to can be reduced to the minimum, the collision determination can be performed at higher speed.

【0037】請求項3、7及び11の発明においては、
Zソートの出力結果を利用する衝突判定を処理の重い詳
細な衝突判定と、処理の軽い簡易な衝突判定を用いるこ
とで、簡易な衝突判定により明らかに衝突判定を行う必
要のない物体を排除することができ、結果として、詳細
な衝突判定を行う回数が減ることで、より高速に衝突判
定を行うことができる。
In the third, seventh and eleventh aspects of the present invention,
By using a detailed collision judgment with heavy processing and a simple collision judgment with light processing for collision judgment using the output result of Z sort, objects that do not need to make a collision judgment clearly by simple collision judgment are eliminated. As a result, the number of times of performing detailed collision determination is reduced, so that the collision determination can be performed at higher speed.

【0038】請求項4、8及び12の発明においては、
詳細な衝突判定と、簡易な衝突判定とを必要に応じて切
り替えることができるため、例えば、精度の低い簡易な
衝突判定手段を用いて処理を行って、装置全体の処理に
余裕があるときには、必要な物体に対して詳細な衝突判
定を行うことができる。そして、装置全体の処理時間を
短縮し、処理の高速化を図ることができる。
In the invention of claims 4, 8 and 12,
Since the detailed collision determination and the simple collision determination can be switched as necessary, for example, when processing is performed using a simple collision determination unit with low accuracy, when there is room in the processing of the entire apparatus, Detailed collision determination can be performed for a necessary object. Then, the processing time of the entire apparatus can be reduced, and the processing can be speeded up.

【図面の簡単な説明】[Brief description of the drawings]

【図1】本発明に係る3次元移動物体の衝突判定装置の
第1実施形態を示す機能ブロック図である。
FIG. 1 is a functional block diagram showing a first embodiment of a three-dimensional moving object collision determination device according to the present invention.

【図2】物体が配置された3次元空間の例を示す説明図
である。
FIG. 2 is an explanatory diagram illustrating an example of a three-dimensional space in which objects are arranged.

【図3】Zソートテーブルの例を示す説明図である。FIG. 3 is an explanatory diagram illustrating an example of a Z sort table.

【図4】直方体物体と移動物体の交点算出方法を示す説
明図である。
FIG. 4 is an explanatory diagram showing a method of calculating an intersection between a rectangular parallelepiped object and a moving object.

【図5】移動速度による参照範囲を表した3次元空間の
例を示す説明図である。
FIG. 5 is an explanatory diagram showing an example of a three-dimensional space representing a reference range based on a moving speed.

【図6】本発明に係る3次元移動物体の衝突判定装置の
第2実施形態を示す機能ブロック図である。
FIG. 6 is a functional block diagram illustrating a second embodiment of the three-dimensional moving object collision determination device according to the present invention.

【図7】簡易衝突判定を示す説明図である。FIG. 7 is an explanatory diagram showing simple collision determination.

【図8】本発明に係る3次元移動物体の衝突判定装置の
第3実施形態を示す機能ブロック図である。
FIG. 8 is a functional block diagram showing a third embodiment of the three-dimensional moving object collision determination device according to the present invention.

【符号の説明】[Explanation of symbols]

1 座標変換手段 2 物体座標記憶手段 3 Zソート手段 4 Zソートテーブル記憶手段 5 移動経路生成手段 6 衝突判定手段 7 画像生成手段 8 簡易衝突判定手段 9 詳細衝突判定手段 10 切り替え手段 DESCRIPTION OF SYMBOLS 1 Coordinate conversion means 2 Object coordinate storage means 3 Z sort means 4 Z sort table storage means 5 Moving path generation means 6 Collision judgment means 7 Image generation means 8 Simple collision judgment means 9 Detailed collision judgment means 10 Switching means

Claims (12)

【特許請求の範囲】[Claims] 【請求項1】 移動物体と他の物体との衝突判定をリア
ルタイムで行う三次元移動物体の衝突判定装置におい
て、 空間内の物体のZ値をZソートテーブル記憶手段に記憶
するZソート手段と、 前記移動物体の移動経路を算出する移動経路生成手段
と、 移動物体が衝突する可能性のあるZ値範囲をZソート手
段のZ値からあらかじめ設定し、該範囲内の物体に対
し、前記移動経路生成手段から算出された移動経路から
移動物体との衝突判定を行う衝突判定手段と、を備えた
ことを特徴とする三次元移動物体の衝突判定装置。
1. A three-dimensional moving object collision judging device for judging a collision between a moving object and another object in real time, comprising: a Z sorting means for storing a Z value of an object in space in a Z sort table storing means; Moving path generating means for calculating a moving path of the moving object; and a Z value range in which the moving object may collide is set in advance from the Z value of the Z sorting means. A collision determination unit configured to determine a collision with the moving object based on the movement route calculated by the generation unit.
【請求項2】 移動物体の速度に応じて前記Z値範囲を
設定することを特徴とする請求項1記載の三次元移動物
体の衝突判定装置。
2. The apparatus according to claim 1, wherein the Z value range is set according to the speed of the moving object.
【請求項3】 前記衝突判定手段は、簡易衝突判定手段
と詳細衝突判定手段からなり、 簡易衝突判定手段によって、移動物体が衝突する可能性
を求め、衝突する可能性の高い物体についてのみ、詳細
衝突判定手段によって詳細に判定を行うことを特徴とす
る請求項1又は2記載の三次元移動物体の衝突判定装
置。
3. The collision judging means comprises a simple collision judging means and a detailed collision judging means. The simple collision judging means obtains a possibility of a moving object colliding, and determines only details of an object having a high possibility of colliding. The apparatus according to claim 1, wherein the collision determination unit makes a detailed determination.
【請求項4】 前記衝突判定手段は、簡易衝突判定手段
と詳細衝突判定手段からなり、 簡易衝突判定手段と詳細衝突判定手段の切り替えを行う
切り替え手段を備えたことを特徴とする請求項1又は2
記載の三次元移動物体の衝突判定装置。
4. The apparatus according to claim 1, wherein said collision determination means comprises a simple collision determination means and a detailed collision determination means, and further comprises switching means for switching between the simple collision determination means and the detailed collision determination means. 2
3. The collision determination device for a three-dimensional moving object according to claim 1.
【請求項5】 移動物体と他の物体との衝突判定をリア
ルタイムで行う三次元移動物体の衝突判定方法におい
て、 空間内の物体のZ値をZソートテーブル記憶手段に記憶
し、前記移動物体の移動経路を算出し、移動物体が衝突
する可能性のあるZ値範囲をZソート手段のZ値からあ
らかじめ設定し、該範囲内の物体に対し衝突判定を行う
ことを特徴とする三次元移動物体の衝突判定方法。
5. A method for judging a collision between a moving object and another object in real time, wherein a Z value of an object in space is stored in a Z sort table storage means, A three-dimensional moving object, wherein a moving path is calculated, a Z value range in which the moving object may collide is set in advance from the Z value of the Z sorting means, and collision is determined for objects within the range. Collision determination method.
【請求項6】 移動物体の速度に応じて前記Z値範囲を
設定することを特徴とする請求項5記載の三次元移動物
体の衝突判定方法。
6. The method according to claim 5, wherein the Z value range is set according to the speed of the moving object.
【請求項7】 前記衝突判定は、簡易衝突判定によっ
て、移動物体が衝突する可能性を求め、衝突する可能性
の高い物体についてのみ、詳細衝突判定によって詳細に
判定を行うことを特徴とする請求項5又は6記載の三次
元移動物体の衝突判定方法。
7. The collision determination method according to claim 1, wherein the possibility of collision of the moving object is obtained by a simple collision determination, and only the object having a high possibility of collision is determined in detail by a detailed collision determination. Item 7. The method for judging collision of a three-dimensional moving object according to item 5 or 6.
【請求項8】 前記衝突判定が、簡易衝突判定と詳細衝
突判定のいずれでも行えるように切り替えを可能とした
ことを特徴とする請求項5又は6記載の三次元移動物体
の衝突判定方法。
8. The method for determining a collision of a three-dimensional moving object according to claim 5, wherein switching can be performed so that the collision determination can be performed by either a simple collision determination or a detailed collision determination.
【請求項9】 移動物体と他の物体との衝突判定をリア
ルタイムで行う三次元移動物体の衝突判定プログラムを
記録した記録媒体において、 空間内の物体のZ値をZソートテーブル記憶手段に記憶
し、前記移動物体の移動経路を算出し、移動物体が衝突
する可能性のあるZ値範囲をZソート手段のZ値からあ
らかじめ設定し、該範囲内の物体に対し衝突判定を行う
ことを特徴とする三次元移動物体の衝突判定プログラム
を記録した記録媒体。
9. A storage medium storing a three-dimensional moving object collision determination program for determining a collision between a moving object and another object in real time, wherein the Z value of the object in space is stored in a Z sort table storage means. Calculating a moving path of the moving object, presetting a Z value range in which the moving object may collide with the Z value of the Z sorting means, and performing collision determination on objects within the range. Recording medium storing a three-dimensional moving object collision determination program.
【請求項10】 移動物体の速度に応じて前記Z値範囲
を設定することを特徴とする請求項9記載の三次元移動
物体の衝突判定プログラムを記録した記録媒体。
10. The recording medium according to claim 9, wherein the Z value range is set according to the speed of the moving object.
【請求項11】 前記衝突判定は、簡易衝突判定によっ
て、移動物体が衝突する可能性を求め、衝突する可能性
の高い物体についてのみ、詳細衝突判定によって詳細に
判定を行うことを特徴とする請求項9又は10記載の三
次元移動物体の衝突判定プログラムを記録した記録媒
体。
11. The collision determination device according to claim 1, wherein the possibility of collision of the moving object is determined by a simple collision determination, and a detailed collision determination is performed only for an object having a high possibility of collision. Item 11. A recording medium on which the program for judging collision of a three-dimensional moving object according to Item 9 or 10 is recorded.
【請求項12】 前記衝突判定が、簡易衝突判定と詳細
衝突判定のいずれでも行えるように切り替えを可能とし
たことを特徴とする請求項9又は10記載の三次元移動
物体の衝突判定プログラムを記録した記録媒体。
12. The three-dimensional moving object collision determination program according to claim 9, wherein the collision determination can be switched so as to perform either a simple collision determination or a detailed collision determination. Recording medium.
JP9199801A 1997-07-25 1997-07-25 Method and device for deciding collision of three-dimensional moving body and recording medium where collision decision program is recorded Pending JPH1145350A (en)

Priority Applications (1)

Application Number Priority Date Filing Date Title
JP9199801A JPH1145350A (en) 1997-07-25 1997-07-25 Method and device for deciding collision of three-dimensional moving body and recording medium where collision decision program is recorded

Applications Claiming Priority (1)

Application Number Priority Date Filing Date Title
JP9199801A JPH1145350A (en) 1997-07-25 1997-07-25 Method and device for deciding collision of three-dimensional moving body and recording medium where collision decision program is recorded

Publications (1)

Publication Number Publication Date
JPH1145350A true JPH1145350A (en) 1999-02-16

Family

ID=16413863

Family Applications (1)

Application Number Title Priority Date Filing Date
JP9199801A Pending JPH1145350A (en) 1997-07-25 1997-07-25 Method and device for deciding collision of three-dimensional moving body and recording medium where collision decision program is recorded

Country Status (1)

Country Link
JP (1) JPH1145350A (en)

Cited By (3)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002092650A (en) * 2000-09-14 2002-03-29 Namco Ltd Hit checking method between objects and game device
KR100888475B1 (en) * 2007-02-02 2009-03-12 삼성전자주식회사 Method and apparatus for detecting model collision
KR101013784B1 (en) * 2009-08-31 2011-02-14 이화여자대학교 산학협력단 Hybrid parrallel continuous collision detection using cpu and gpu

Cited By (5)

* Cited by examiner, † Cited by third party
Publication number Priority date Publication date Assignee Title
JP2002092650A (en) * 2000-09-14 2002-03-29 Namco Ltd Hit checking method between objects and game device
JP4510257B2 (en) * 2000-09-14 2010-07-21 株式会社バンダイナムコゲームス Method for checking hit between objects and game device
KR100888475B1 (en) * 2007-02-02 2009-03-12 삼성전자주식회사 Method and apparatus for detecting model collision
US8130220B2 (en) 2007-02-02 2012-03-06 Samsung Electronics Co., Ltd. Method, medium and apparatus detecting model collisions
KR101013784B1 (en) * 2009-08-31 2011-02-14 이화여자대학교 산학협력단 Hybrid parrallel continuous collision detection using cpu and gpu

Similar Documents

Publication Publication Date Title
US6489955B1 (en) Ray intersection reduction using directionally classified target lists
US20010012018A1 (en) Occlusion culling for complex transparent scenes in computer generated graphics
CN103236079B (en) Improved three-dimensional model voxelization-based inner sphere construction method
US6734853B2 (en) Method of using view frustrum culling for scaleable collision detection
GB2226937A (en) Image display
JP5695746B2 (en) Mipmap level selection method and texture mapping system using the same
US6359629B1 (en) Backface primitives culling
WO2004090838A1 (en) Simulator and information storage medium
WO2022040472A1 (en) System and method for accelerated ray tracing
EP3958216A2 (en) System and method for accelerated ray tracing with asynchronous operation and ray transformation
CN110322539A (en) Threedimensional model cutting process display methods, device and the electronic equipment of three-dimension object
JPH1145350A (en) Method and device for deciding collision of three-dimensional moving body and recording medium where collision decision program is recorded
US20240046549A1 (en) Ray tracing method and apparatus based on attention for dynamic scenes
JP3844405B2 (en) GAME DEVICE AND INFORMATION STORAGE MEDIUM
JP4003898B2 (en) Image generating apparatus and information storage medium
US10896510B2 (en) Image processing apparatus, image processing method, and program
Weller et al. Kinetic Separation Lists for Continuous Collision Detection of Deformable Objects.
JP4101677B2 (en) Motion simulation device
JP2962747B2 (en) Collision detection system
JPH08315181A (en) Method and device for judging collision
JP2001273523A (en) Device and method for reducing three-dimensional data
Fahn et al. Efficient time-interrupted and time-continuous collision detection among polyhedral objects in arbitrary motion
Sajo et al. Controlling the Accuracy and Efficiency of Collision Detection in 2d Games using Hitboxes
CN115393549A (en) Collision detection method and system and electronic equipment
JPH09259303A (en) Simulation device and collision judgement method