linux head tracking
-
<p>What’s the best way to set up BMS head tracking on linux? I’ll be using Ubuntu 22.04 LTS, which uses linux kernel 5.15 LTS.<br /><br />Thanks!</p>
-
<p>It depends on what headtracking device is gonna be used, but for freetrack/delan clip + webcam solutions opentrack with wine plugin is the way to go.<br />You might find few tips up there:<br /><a href=“https://forum.falcon-bms.com/topic/20392/unofficial-running-bms-on-linux-wine-with-opentrack-howto?_=1648141787760” target="blank">https://forum.falcon-bms.com/topic/20392/unofficial-running-bms-on-linux-wine-with-opentrack-howto?=1648141787760</a></p>
-
<p>@Xeno Thanks for the quick reply! I have TrackIR; BMS is designed to work with TrackIR, but I understand it’s hard to get Track IR working under linux. <br /><br />Is BMS designed to work with delan clip specifically? Or does BMS interpret delan clip head position input as Track IR input? Or as mouse input?</p>
-
<p>@tank2 <br />Freetrack/Delan Clip are supported via OpenTrack TrackIR protocol implementation. <br /></p>
-
@Xeno I’m using ubuntu 22.04 LTS linux and delanclip’s webcam/headset attachment. When I built opentrack from source using Xeno’s instructions, opentrack built successfully. With opentrack output set to Flightgear, I confirmed that head tracking was working with the open source flightgear simulation.
Problem: wine is not an option under the opentrack “Output” menu. The menu items are:
- Flightgear
- libevdev joystick receiver and
- UDP over network.
In his opentrack instructions Xeno mentioned an SDK_WINE flag, but did not say exactly how to use this flag, so I did not use it.
How can I build opentrack such that it has a wine output option?
Thanks
-
you’ll probably need to install the wine development packages for the wine output plugin to be built. I don’t know if the configure / cmake script picks them up automatically and it’s been a while since I compiled opentrack from source.
All the best,
Uwe
-
@hoover (I’m using ubuntu 22.04 LTS rather than mint, but it should be similar). My install list is what Xeno recommended for ubuntu/mint in his headtracking thread, with the exception that I removed lib32stdc+±7-dev (which is not in the ubuntu default repositories) and added g++ and clang instead.
The commands I used to install packages is below. Am I missing something? Thanks!
--------------- my commands to install packages prior to running opentrack -------------------
pkg --add-architecture i386
emacs-nox libprocps-dev unzip libc6-dev-i386 libqt5serialport5-dev libqt5webkit5-dev qttools5-dev libopencv-dev htop apt-file libeigen3-dev libevdev-dev
fonts-wine libwine:i386 libwine-dev:i386 libwine-development:i386 libwine-development-dev:i386 wine-devel-i386:i386 wine-development:i386 wine-stable:i386 wine-stable-dev:i386 wine-stable-i386:i386 wine32-development:i386 wine32-development-tools:i386 fonts-wine libwine libwine-dev libwine-development libwine-development-dev wine-devel-i386 wine-development wine-stable wine-stable-dev wine-stable-i386 wine32-development wine32-development-tools -
I run the Windows version of OpenTrack in the same prefix as BMS. Every other approach did not succeed. OpenTrack linux-native might work for other linux-native games, but it was not working with a wine game. Using Windows-OpenTrack’s default settings from the same prefix as BMS was issue-free.
Note that TrackIR’s camera does not work in linux, as the drivers are proprietary. I have heard that LinuxTrack will allow you to extract those drivers from the proprietary software’s binaries, but after hours of effort, I could not get LinuxTrack to work as it is a bit abandoned and utilizes very deprecated dependencies that created recursive headaches. You can substitute any IR camera (PS3Eye on eBay) for TIR’s and get the headset to work with OpenTrack.
Also note that using Proton makes this all extremely simple (though 4.36 is so-so in bugginess; 4.35 was as flawless as the Windows version of F4 has ever been). I posted the libraries that Proton includes in its official F4.0 Proton prefix in the other Linux thread. I think most Proton prefixes use the same libraries, so you can probably just copy-paste one to make a new wine prefix and use that, if you have any Steam games.
-
@PotatoPilot When I try running the opentrack windows exe under wine on Ubuntu 22.04LTS, opentrack can’t find my delanclip PS3 webcam. The CL Eye webcam calibration program that delanclip provides also cannot find my PS3 webcam, although it and the delanclip are plugged into USB2 ports on my computer.
How can I get opentrack to recognize my PS3 webcam?
Thanks
-
@tank2 said in linux head tracking:
@Xeno I’m using ubuntu 22.04 LTS linux and delanclip’s webcam/headset attachment. When I built opentrack from source using Xeno’s instructions, opentrack built successfully. With opentrack output set to Flightgear, I confirmed that head tracking was working with the open source flightgear simulation.
Problem: wine is not an option under the opentrack “Output” menu. The menu items are:
- Flightgear
- libevdev joystick receiver and
- UDP over network.
In his opentrack instructions Xeno mentioned an SDK_WINE flag, but did not say exactly how to use this flag, so I did not use it.
How can I build opentrack such that it has a wine output option?
Thanks
run ccmake from step “ccmake .”
set your preffered install path
change SDK_WINE from “OFF” to “ON”In order to do so:
- highlight CMAKE_INSTALL_PREFIX, press enter
edit path and press enter to accept - highlight SDK_WINE, press enter to toggle OFF -> ON
- press “c” to configure, then “g” to generate config
Then proceed with building
- make
- make install - this command has to be run as root (sudo) if your install prefix points outside your home dir.
-
Thanks, that worked! Here’s my detailed description of how to set up opentrack in the current version of Ubuntu, which is Ubuntu 22.04LTS
#install needed packages
time sudo apt install -y git cmake git qttools5-dev qtbase5-private-dev libprocps-dev libopencv-dev g++ subversion wine-development vim okular flightgear libeigen3-dev gcc-multilib g+±multilib wine32-development wine32-development-preloader wine32-development-tools cmake-curses-gui plocate#build opentrack from source
mkdir delanclipopentrack URL: https://github.com/opentrack/opentrack/releases/tag/opentrack-2022.1.1
cp opentrack-opentrack-2022.1.1.zip delanclip
unzip opentrack-opentrack-2022.1.1.zip
cd delanclip/opentrack-opentrack-2022.1.1
mkdir build
cd build
cmake …run the text menu configuration program ccmake
set the eigen3 path to /usr/include/eigen3
set windows sdk to ON
choose continue
choose generate
ccmake .
now compile and build
make
make installcd install/bin
./opentrack
in the opentrack gui, click the tool icon in the input section, then choose
Camera/Camera Settngs/Device to be your PS3 webcam, not an internal webcam
chose “Wine” under Output
then select the tool icon to the right and enter the path to the sims’
wine prefix
select “Start” and verify that the webcam is tracking the LED’s
and that raw tracker data and game data numbers change as the
LED fixture is moved around.
copy the delanclip profile to the opentrack config directory
cp ~/delanclip/DELANCLiP-Opentrack-Basic.ini ~/.config/opentrack-2.3
#if you use
sudo ./opentrack
to avoid setting permissions
the config directory will be /root/.config/opentrack-2.3
if running delanclip with a sim that uses wine, call wine as follows
WINEESYNC=1 wine <sim>