ZdoHeadTracking - Head Tracking using TrackIR

⭐ — (5 endorsements) 📥 37 downloads 📌 v1.0 📅 12/31/2023
⚪ Last updated 2023

By zdo · Immersion

⬇ Download Mod Source: Nexus Mods ↗ 📅 Updated: 12/31/2023 📅 Created: 12/31/2023
⚠️ Install Order · 2 steps
1🛠️ MWSE — Morrowind Script Extender Download ↗
2🔧 MCP — Morrowind Code Patch Download ↗

Install in this order, then this mod last — most mods fail to load without their framework and dependencies in place.

🔍 Analysis

  • 🏆 #126 of 137 Immersion mods in this game by downloads

📋 About This Mod

Head tracking and head bobbing in Morrowind.

E3V2qdhKot0

At this stage, it only works with TrackIR.

Instruction.

  • []put on TrackIR device, start TrackIR software

    []download and install the mod

    []in mod folder, go to "TrackIR_reader"

    []open read.py

    []adjust file_path variable. Script will be writing data from TrackIR to this file. The file will be later read the Morrowind mod.

  • []after adjusting file_path, open the console and run "python read.py"

    []now values from TrackIR are being written to the file at "file_path"

    Stage 2.

    • []in Morrowind, open MCM and put the same file path, so mod will be reading data written by the Python script

      []after that, head tracking should be working automatically

      []you can adjust values in MCM to your liking

      FAQ.

      Q. Why writing to file?

      A. Better approach would be to use a shared memory, or something like UDP socket. But it would require more effort, so the first version is doing it via good old text file.

      Q. OpenTrack?

      A. Definitely is possible. What needs to be added is a way to communicate rotation/translation from OpenTrack to Morrowind mod.

      Since I have TrackIR, I do not use OpenTrack, therefore I am not really into working on it.

      But feel free to check out the code and add the implementation, it should be straightforward - to write 6 numbers to the text file utilizing existing logic of passing data from TrackIR.

      This mod does not work with OpenMW. Although, I made it working as a proof of concept this way:

      • []TrackIR is being read by FreePIE (check out images)

      • []FreePIE reports it to vJoy joystick (check out images)

      • []OpenMW cannot read vJoy because it is considered by libsdl "not a controller"

        []so, we use x360ce (Xbox 360 controller emulator) - we map each axis from vJoy to axis in x360ce (check out images)

        []in OpenMW, we need to modify "resources\vfs\scripts\omw\camera\head_bobbing.lua" to keep head bobbing working, and add to it the head tracking, similar to this:

          camera.setExtraYaw(input.getAxisValue(input. CONTROLLER_AXIS. RightX) (3. 1415 0. 8))

      camera.setExtraPitch(input.getAxisValue(input. CONTROLLER_AXIS. RightY) (3. 1415 0. 45))

      camera.setExtraRoll(camera.getExtraRoll() - input.getAxisValue(input. CONTROLLER_AXIS. LeftX) (3. 1415 0. 15))

      local offset = util.vector3(

      (input.getAxisValue(input. CONTROLLER_AXIS. TriggerLeft) - 0. 5) 2 30,

      (input.getAxisValue(input. CONTROLLER_AXIS. TriggerRight) - 0. 5) 2 * 5

📊 Mod Details

Game
Morrowind Mods
Author
zdo
Version
1.0
Downloads
37
Endorsements
5
Category
Immersion
Created
12/31/2023
Updated
12/31/2023

🔧 How to Install Morrowind Mods

Download from Nexus.

📖 Full step-by-step install guide for Morrowind →

Visit the official mod page for specific installation instructions for this mod.

🎮 Need cheat codes or console commands? Check ur gaming wiki for Morrowind commands, item IDs, and more.

Keep browsing — more Morrowind mods await

📋 All Morrowind Mods 🏆 Top 25 📂 More Immersion 👤 More by zdo 🔎 Similar Mods 🌐 Best Immersion (All Games) ⚠️ Fix Crashes & Errors 🔀 Check Compatibility ⚖️ Compare Mods 🆕 New Mods