Giter Site home page Giter Site logo

linecode / qtm-connect-for-unreal Goto Github PK

View Code? Open in Web Editor NEW

This project forked from qualisys/qtm-connect-for-unreal

0.0 1.0 0.0 476.43 MB

Unreal plugin for real-time streaming from Qualisys Track Manager

C++ 89.05% C 0.07% C# 7.20% Batchfile 3.67%

qtm-connect-for-unreal's Introduction

QTM Connect for Unreal

QTM Connect for Unreal is an Unreal plugin that supports streaming of skeleton, rigid body, marker, force and timecode data between Qualisys Track Manager and Unreal Engine.

Installation of the plugin

Note that the pre-built dll's for each version can be found here:

  • UE 5.0EA
  • UE 4.27
  • UE 4.26
  • UE 4.25
  • UE 4.24
  • Note: Support for UE4.23 and below is also available but prebuilt binaries are currently not updated from lastest commits.
  • Note: If the plugin should be used in a unsupported Unreal Engine version then put it in the Unreal project folder\Plugins and rebuild project.
  1. Copy the directory .\Prebuilt\Qualisys to C:\Program Files\Epic Games\UE_4.xx\Engine\Plugins.
    • Optional: Copy .\Example Project to C:\Users\<user>\Documents\Unreal Projects
  2. Start Unreal and create a project.
    • Optional: Open Project QualisysAvatar from step 1.
  3. The plugin should appear in the plugin window as "QTM Connect For Unreal". Click Enable and restart Unreal to get it activated.

How to use the QTM Connect LiveLink plugin

Start live link source

  1. Start QTM in preview mode or file mode being sure there is a skeleton to stream. An example qtm file including a skeleton is provided in .\Example Project
  2. Enable LiveLink and QTMConnectLiveLink in Unreal under Edit->Plugins.
  3. Go to Window->Live Link, click Add->QTM Connect LiveLink
  4. Enter the QTM IP address and port and click Create.

Stream skeleton data

  1. If the Skeleton of the Skeletal Mesh that you wish to animate matches the skeleton data being streamed from QTM (same bone names and hierarchy), then skip steps 5-7.
  2. In the Content Browser, click Add New->Blueprint Class and expand All Classes and search for QualisysLiveLinkRetargetAsset, and click Select.
  3. Double-click the retarget asset and go to Details->Bone Mapping and expand the Bone Mapping variable.
  4. In the right column, fill in the names of the Skeleton bones that best correspond to the QTM skeleton bones seen in the left column. If there is no corresponding bone or the bone name already matches the QTM bone name, leave it as "None".
  5. In the Content Browser, go to the Skeletal Mesh that you wish to animate and Right-click->Create->Anim Blueprint. Give it a name and then double click on it.
  6. Right-click anywhere in the animation graph and search for the Live Link Pose node.
  7. Enter the subject name (the name of the skeleton being streamed from QTM), and connect the output pose to the input pose of the Final Animation Pose node.
  8. Click on the Live Link Pose node and go to Details->Retarget->Retarget Asset and select the retarget asset you created in step 5, or choose the QualisysLiveLinkRetargetAsset if you skipped steps 5-7.
  9. Click Compile, and you should see the mesh moving in the preview window.
  10. Drag the animation blueprint you created in step 8 into your scene, then click Play.

Stream rigid body data

  1. Select your actor and Add Component Live Link Controller.
  2. Enter the rigid body name as subject name and LiveLinkTransformRole as role.

Stream force data

  1. Each force plate is a livelink subject with the basic role.
  2. The force subject contains the following 9 properties in order. (Force X, Force Y, Force Z, Moment X, Moment Y, Moment Z, Application Point X, Application Point Y, Application Point Z)

Note: Avoid mixing the LiveLink plugin data with the QualisysClient plugin. Synchronization of data might differ.

How to use the QualisysClient Actor object and QualisysRigidBody ActorComponent object

  1. The QualisysClient object is available in the UE4 Modes panel. This object handles the data streaming between QTM and Unreal.
  2. Drag and drop the QualisysClient object in the world.
  3. Select the QualisysClient instance and edit it's properties. (IP address of the machine running QTM, and stream rate (StreamRate of 0 will stream data as quick as possible).
  4. Add a Qualisys RigidBody component to a object in the World Outliner pane.
  5. Make sure the object is set to moveable.
  6. Set the RigidBody name to the name of the RigidBody in QTM.
  7. Play scene. It will automatically try and connect to QTM and receive 6DOF data.
  8. Use DebugDrawing setting in QualisysClient to display all labeled trajectories as spheres and all rigid bodies as cubes.

Note: To connect position of a component to position of a labeled trajectory use the QualisysTrajectory ActorComponent.

Video tutorials

  1. Streaming tutorial video
  2. Bone mapping tutorial video
  3. How to import a Qualisys Track Manager exported FBX

Supported Unreal Build Platforms

  • Windows 64bit

qtm-connect-for-unreal's People

Contributors

ccstfn avatar emilrosenquist avatar helmesjo avatar henrik-norgren avatar mlveggo avatar nilzilch avatar nyqvistatwork avatar thingvold avatar ulvs avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.