Haptics Project

Course project for the Computer Haptics course (Computer Science 599.86 at the University of Calgary) I took in winter 2018.

Sadly I no longer have access to the Novint Falcon haptic devices used in this course so I cannot take screenshots or record videos demoing the haptic components of this project. Even worse, I can no longer run this project so I cannot get any new screenshots of it. Fortunately I have a screenshot and video from when I worked on this project but they’re both really low quality. Although haptics really are something you just have to feel yourself so screenshots and videos wouldn’t do it justice anyway.

Source code is self-hosted on my home Git-Gogs server which is only accessible from my home network.

Project Summary

Objective

Implement haptics within Unreal Engine 4 using CHAI3D as a driver.

Features

  • Haptic device controlled a sphere in the scene.
  • Forces were sent back to the haptic device allowing for haptic feedback.
  • Used the god object algorithm to keep the haptic cursor from pushing through an object.
    • One sphere directly controlled by the haptic device.
    • The other sphere would follow the haptic controlled sphere while obeying collisions.
    • Had a virtual “spring” connecting the two.
  • Used multiple threads for haptics to feel better.
  • Created a simple demo scene where you could push stuff around.

Challenges

  • First time using UE4 from a programing perspective.
  • Only had about a month to complete the entire project and I was working independently.
  • UE4’s build system took a while to figure out.
    • Changed my approach at least half a dozen times before finally figuring out how to not only get input from but also send information to the haptic device.
  • Despite the haptic sphere updating at 1000hz, the collision sphere was locked with the game’s framerate.
    • This was because UE4’s collisions were only being checked every frame and I was not skilled enough to figure out a way to fix this without rewriting the collision system on my separate thread.
    • Still felt somewhat okay and it was rather fun to throw around dynamic objects with haptic feedback.

Credits

Demo

Screenshot

Basically the final version except all the objects were made dynamic in the final scene and I added walls to keep the user from knocking stuff off into infinity.

UE4 generated icon for the project which somewhat shows off the final scene where everything except for the walls and floor was dynamic and could be thrown around with full haptics.

Video

This was for the milestone presentation where I only got the haptic device hooked up as a controller and was not getting any haptic forces back to the device.