View Single Post
  #2  
Old 04-27-2010, 03:19 PM
Jeff Jeff is offline
WorldViz Team Member
 
Join Date: Aug 2008
Posts: 2,465
When viewpoint collision is enabled a collision event will be generated when the viewpoint collides with an object. Information about the collision, including position, is available.
Code:
import viz
viz.go()

gallery = viz.add('gallery.ive')

viz.collision(viz.ON)

def onCollision(info):
    print 'Collided at point',info.point

viz.callback(viz.COLLISION_EVENT, onCollision)
Reply With Quote