WorldViz User Forum

WorldViz User Forum (https://forum.worldviz.com/index.php)
-   Vizard (https://forum.worldviz.com/forumdisplay.php?f=17)
-   -   World/Origin Shifting and Rotation (https://forum.worldviz.com/showthread.php?t=2891)

byronhulcher 08-11-2010 07:41 AM

World/Origin Shifting and Rotation
 
Hello, I'm creating a project using Vizard 3.18 for human reaction testing. However, our lab is quite small, and we need to make maximum use of the space. To this end, I'm trying to shift the origin of our world within environment a few meters and rotate the x and z axes by approximately 45 degrees to take advantage of additional diagonal space. Is there an easy command to do this, or am I stuck applying this transformation to every object I add into the world?

byronhulcher 08-11-2010 07:49 AM

I've recently discovered the HMD.__init__ function within vizhmd.py which is extended by nvis.py, which my program is currently using to access the HMD. However, I'm not really sure how to use this to apply changes.

byronhulcher 08-11-2010 08:11 AM

Actually, I think I'm better off using the viz.link functions, if I'm reading the WorldViz documentation correctly. Does anyone have experience with these?

Jeff 08-11-2010 10:14 AM

Do you want to offset the viewpoint linked to tracking data? If so, take a look at the following code. Using the .postTrans and postEuler operators, the viewpoint is offset 1 meter in height and 45 degrees in yaw from the tracking data.
Code:

link = viz.link(tracker,viz.MainView)
link.postTrans([0,1,0])                   
link.postEuler([45,0,0])


c4am95 10-26-2010 01:48 PM

what if you're not using an HMD? i'm having a similar issue, but for testing purposes i can't use these methods to apply world transformation (there's no link). what could you do to rotate the world/translate the origin without the link?


All times are GMT -7. The time now is 12:57 AM.

Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Copyright 2002-2023 WorldViz LLC