triad_openvr-master.zip

  • hzzzz2
    了解作者
  • C/C++
    开发工具
  • 69KB
    文件大小
  • zip
    文件格式
  • 0
    收藏次数
  • 1 积分
    下载积分
  • 0
    下载次数
  • 2020-08-31 04:08
    上传日期
获得htc Tracker的姿态信息,打印到控制台
triad_openvr-master.zip
  • triad_openvr-master
  • images
  • simple_xcoord_plot.png
    63.1KB
  • .gitignore
    19B
  • example_default.vrsettings
    3KB
  • README.md
    1.4KB
  • tracker_test.py
    619B
  • triad_openvr.py
    13.1KB
  • config.json
    644B
  • udp_emitter.py
    763B
  • controller_test.py
    622B
  • udp_receiver.cs
    1.6KB
内容介绍
# Triad OpenVR Python Wrapper This is an enhanced wrapper for the already excellent [pyopenvr library](https://github.com/cmbruns/pyopenvr) by [cmbruns](https://github.com/cmbruns). The goal of this library is to create easy to use python functions for any SteamVR tracked system. # Getting Started ```python import triad_openvr as vr import pylab as plt v = vr.triad_openvr() data = v.devices["controller_1"].sample(1000,250) plt.plot(data.time,data.x) plt.title('Controller X Coordinate') plt.xlabel('Time (seconds)') plt.ylabel('X Coordinate (meters)') ``` ![Example plot of captured data](images/simple_xcoord_plot.png "Example Plot") # Configuration file The goal is to identify devices by serial, in order to keep the same name for the same physical device. for maing it work, you just have to change serials and names in the 'config.json' file. Here is an example of config file : ``` { "devices":[ { "name": "hmd", "type": "HMD", "serial":"XXX-XXXXXXXX" }, { "name": "tracking_reference_1", "type": "Tracking Reference", "serial":"LHB-XXXXXXXX" }, { "name": "controller_1", "type": "Controller", "serial":"XXX-XXXXXXXX" }, { "name": "tracker_1", "type": "Tracker", "serial":"LHR-XXXXXXXX" } ] } ```
评论
    相关推荐