![]() |
|
#1
|
|||
|
|||
Here is the proper way to setup PPT and Intersense head tracking in Vizard 3.0. If you are not using Vizard 3.0, download it.
Code:
import viz viz.go() PORT_PPT = 0 #Com port number. Zero to search through COM1 to COM4 headPosSensor = viz.add('vizppt.dls') PORT_INTERSENSE = 0 #Com port number. Zero to search through COM1 to COM4 headOriSensor = viz.add('intersense.dls') headCombined = viz.mergeLinkable( headPosSensor, headOriSensor ) # Link hybrid head sensor to view and don't offset by eyeheight headLink = viz.link(headCombined, viz.MainView, dstFlag = viz.LINK_POS_RAW) #add world viz.add('court.ive')
__________________
Paul Elliott WorldViz LLC |
#2
|
|||
|
|||
Simplicity is a virtue. This works for me.
Code:
from viz import * go() room = add('gallery.ive') pos = add('vizppt.dls') ori = add('intersense.dls') tracker() def onKeyDown(key): if key == 'r': pos.reset() ori.reset() if key == '1': eyeheight(1.8) if key == '2': eyeheight(0) if key == '3': eyeheight(4) callback(KEYDOWN_EVENT,onKeyDown) you hit 'r' it makes it 1.8m. Also, you can change the eyeheight to whatever you want using the viz.eyeheight(height) command. After that hitting 'r' will reset the eyeheight to whatever 'height' is. |
![]() |
Thread Tools | |
Display Modes | Rate This Thread |
|
|