Re: Zeiss headtracker input/trackIR output?
Posted: Mon Sep 16, 2013 3:45 pm
Would really liek to know why its not workign but that game has no demo :/
The Number One Resource For Stereoscopic 3D Excitement!
https://www.mtbs3d.com/phpbb/
Code: Select all
def update():
global yaw
yaw = math.degrees(cinemizer.yaw) * ratio
global pitch
pitch = math.degrees(cinemizer.pitch) * ratio
global roll
roll = math.degrees(cinemizer.roll) * ratio
if starting:
maxAngle = math.radians(180)
axisRange = math.radians(360)
ratio = axisRange / maxAngle
centerYaw = -230
centerPitch = 0
centerRoll = 0
yaw = 0
pitch = 0
roll = 0
cinemizer.update += update
vJoy[0].x = math.degrees(yaw - centerYaw)
vJoy[0].y = math.degrees(pitch - centerPitch)
vJoy[0].z = math.degrees(roll - centerRoll)
diagnostics.watch(vJoy[0].x)
diagnostics.watch(vJoy[0].y)
diagnostics.watch(vJoy[0].z)
diagnostics.watch(cinemizer.yaw)
diagnostics.watch(cinemizer.pitch)
diagnostics.watch(cinemizer.roll)
diagnostics.watch(ratio)
diagnostics.watch(yaw)
diagnostics.watch(pitch)
diagnostics.watch(roll)
diagnostics.watch(centerYaw)
diagnostics.watch(centerPitch)
diagnostics.watch(centerRoll)
if (keyboard.getPressed(Key.Y)):
centerYaw = yaw
centerPitch = pitch
centerRoll = roll