OpenXR support for Panda3D
Project description
panda3d-openxr
This module provides integration of OpenXR with Panda3D using pyopenxr
Note: The functionalities supported by this preliminary version are still very limited. Only rendering, camera tracking and hand tracking is supported. Pose, action and advanced rendering will ber added in future versions.
Requirements
This module requires Panda3D > 1.10.0, PyOpenGL > 3.0.0, pyopenxr > 1.1.0 and a compliant implementation of OpenXR. It supports Windows, Linux and macOS platforms.
Installation
From wheel
pip install panda3d-openxr
From source
git clone https://github.com/el-dee/panda3d-openxr
cd panda3d-openxr
python3 pip install .
Usage
To use panda3d-openvr, first import the p3dopenvr module in your application :
from p3dopenxr.p3dopenxr import P3DOpenXR
Then, once an instance of ShowBase is created, instanciate the VR interface and initialize it :
myvr = P3DOpenXR()
myvr.init()
Once done, the module will enable the VR application layer of OpenXR, create the left and right cameras (in case of Stereoscopic mode) and configure the rendering system to send the images of each eye to the VR compositor.
The module will create the following hierachy in the scenegraph :
- Traking space origin (tracking_space)
- HMD anchor (hmd_anchor)
- Left eye (left_eye_anchor)
- Right eye (right_eye_anchor)
- Left hand (left_hand_anchor)
- Right eye (right_hand_anchor)
The init method has a couple of parameters to configure :
* The near and far planes of the created cameras
* The framebuffer properties to create the rendering chain
Documentation
There is no documentation available yet...
Examples
All the examples are found under samples/ directory, to launch them simply go to their directory and run:
python3 main.py
Minimal
In minimal you can find a minimal setup that will draw a Panda avatar in front of you, and a (ugly) cube where your hands ought to be.
License and Acknowledgments
This library is licensed under the "Apache License Version 2.0", see the file LICENSE for the full text of the license.
This code is heavily based upon the hello_xr
example made by the Khronos Group, and ported to the Python Langage by "Christopher Bump", author of the PyOpenXR library.
Many thanks to them as without their work this library wouldn't exist at all.
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
File details
Details for the file panda3d_openxr-0.1.2.tar.gz
.
File metadata
- Download URL: panda3d_openxr-0.1.2.tar.gz
- Upload date:
- Size: 32.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.8.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 51d8085ef5b1d3ff1c0b0bb2335df7e8610c04e68ebe64b90fd6847e8fb129cc |
|
MD5 | 1f0068c80291cbed81ddd3e4bca00a48 |
|
BLAKE2b-256 | 48d9583c9b320cad1fff8d40f9a6127594f98a0f08cd53aea251341b594a16f6 |
File details
Details for the file panda3d_openxr-0.1.2-py3-none-any.whl
.
File metadata
- Download URL: panda3d_openxr-0.1.2-py3-none-any.whl
- Upload date:
- Size: 25.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/5.1.0 CPython/3.8.10
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 2b2b4a46b5d44019d57ee4c7d6d79800d2eded36e2087ecfadb22b8b33024979 |
|
MD5 | f2bea4a04e2b2e1a256c0e85cd3522a8 |
|
BLAKE2b-256 | bf5c656736aa00ec5e9ddbbcf0422de191e267f6bab25bb88befa5ff74eeb496 |