• Csaba Pinter's avatar
    ENH: Add functions to set VR physical geometry with matrix · ed74f20d
    Csaba Pinter authored
    - Get/SetPhysicalToWorldMatrix functions added to vtkOpenVRRenderWindow to handle the PhysicalTranslation etc. camera related geometry changes as a matrix
    - Refactored UpdateHMDMatrixPose code so that it is more understandable what happens under the hood when the camera is set. It works the very same way, but it is now better formalized and readable.
    Here's how setting the camera works:
    Scaling is applied through moving the camera closer to the focal point, because scaling of all actors is not feasible, and vtkCamera::ModelTransformMatrix is not supported throughout VTK (clipping issues etc.). To achieve this, a new coordinate system called NonScaledWorld is introduced. The relationship between Physical (in which the HMD pose is given by OpenVR) and NonScaledWorld is described by the PhysicalViewUp etc. member variables. After getting the HMD pose in Physical, those coordinates and axes are converted to the NonScaledWorld coordinate system, on which the PhysicalScaling trick of modifying the camera position is applied, resulting the World coordinate system.
    - Renamed incorrect distance variable to physical scale
    ed74f20d
Name
Last commit
Last update
.ExternalData Loading commit data...
.github Loading commit data...
Accelerators/Vtkm Loading commit data...
CMake Loading commit data...
Charts/Core Loading commit data...
Common Loading commit data...
Documentation Loading commit data...
Domains Loading commit data...
Examples Loading commit data...
Filters Loading commit data...
GUISupport Loading commit data...
Geovis Loading commit data...
IO Loading commit data...
Imaging Loading commit data...
Infovis Loading commit data...
Interaction Loading commit data...
Parallel Loading commit data...
Remote Loading commit data...
Rendering Loading commit data...
Testing Loading commit data...
ThirdParty Loading commit data...
Utilities Loading commit data...
Views Loading commit data...
Web Loading commit data...
Wrapping Loading commit data...
.gitattributes Loading commit data...
.gitignore Loading commit data...
.gitmodules Loading commit data...
.hooks-config.bash Loading commit data...
CMakeLists.txt Loading commit data...
CONTRIBUTING.md Loading commit data...
CTestConfig.cmake Loading commit data...
Copyright.txt Loading commit data...
README.md Loading commit data...
vtkBanner.gif Loading commit data...
vtkLogo.ico Loading commit data...