Thread: boresite?
View Single Post
  #6  
Old 10-09-2007, 09:47 AM
JMOwens JMOwens is offline
Member
 
Join Date: Jun 2007
Location: Providence, RI
Posts: 34
Hi farshizzo,
My explanatory question above still stand, but in addition...it doesn't work! I keep getting the error:
AttributeError: 'VizSensor' object has no attribute 'preTrans'

Here's my code, which as near as I can tell follows both your example and the code in the <link>.preTrans help file:

view = viz.MainView
#Link viewpoint with tracker, initialize boresite
if keyControl == 1: #If you're using the tracker
headTrack = viz.add('tracker.dls')
viz.link(headTrack, view) #Link the sensor to the view.
headTrack.preTrans(0,-.15,.14) #Boresite function - translates the viewpoint from the tracker position to eyepoint position
viz.eyeheight(0.0) #This is to compensate for vizard's intrinsic eyeheight of 2m
viz.ipd(eyeohd/100.0) #Set ipd from input above

Additionally, I've tried (had been using) viz.addSensor('intersense') - that doesn't work either, but are these commands redundant? Thanks.
Reply With Quote