Re: Collision detection

New Message Reply Date view Thread view Subject view Author view

Mario Veraart (rioj7++at++fel.tno.nl)
Fri, 21 Mar 1997 21:28:40 +0100 (MET)


> I am loading a terrain file as a SCS object and a car model
> as a DCS object. And then update the car coordinate from
> network (sending only x,y coord info from other machine).
> The problem is that the car won't follow the terrain (it
> goes under or above the terrain), and I wonder if I can
> use collision detection function in performer to do the trick.
> Is there any example to follow? (The "driving.c" from the
> tutorial source shows the collision detection between
> viewer and the scene which I can't apply to my case.)

You can use the pfNodeIsectSegs function to determine the
height of the terrain at a certain (x,y) position.
Look at the itersection traversal chapter in the Programmers manual.

Mario
=======================================================================
List Archives, FAQ, FTP: http://www.sgi.com/Technology/Performer/
            Submissions: info-performer++at++sgi.com
        Admin. requests: info-performer-request++at++sgi.com


New Message Reply Date view Thread view Subject view Author view

This archive was generated by hypermail 2.0b2 on Mon Aug 10 1998 - 17:54:56 PDT

This message has been cleansed for anti-spam protection. Replace '++at++' in any mail addresses with the '@' symbol.