r57zone / OpenVR-OpenTrack

OpenVR driver with OpenTrack support / OpenVR драйвер, с поддержкой OpenTrack
Other
181 stars 19 forks source link

Positional Tracking #2

Closed baseru closed 6 years ago

baseru commented 7 years ago

Can you add positional tracking and UDP Server for stream vr data?

r57zone commented 7 years ago

I added support for position tracking. Please check the correctness of the positional tracking sensitivity, and also whether x, y, z are being confused in the positioning.

The driver opens the UDP server 4242, you can simply send the structure to the UDP server to change the tracking or rotation values of the HMD.

C++ structure:

struct TOpenTrackPacket {
    double x;
    double y;
    double z;
    double yaw;
    double pitch;
    double roll;
}

Example of read data from OpenTrack (need change to send data).

Delphi stucture:

type TOpenTrackPacket = record
    x: double;
    y: double;
    z: double;
    yaw: double;
    pitch: double;
    roll: double;
end;

Example of read data from Razor IMU tracker (Arduino) and send to SteamVR driver.

r57zone commented 7 years ago

@umutbaser Could you test the new version?

baseru commented 7 years ago

I tested but there’s a strange problem if i try to use opentrack with my data opentrack is not reading my data but if i send my position and rotation data directly on 4242 Numbered port thats working clearly. Thanks a lot for helping.

r57zone commented 7 years ago

@umutbaser It is necessary to change the Output to UDP in OpenTrack and the IP address in the settings to 127.0.0.1.

baseru commented 7 years ago

Sorry i tried to say opentrack doesnt reading my values. I tried to change input port on the OpenTrack but it doesnt worked so i made a new server and i am sending the rotation data and position data directly to port:4242 and it is more better for my driver thanks for helping.