Autodesk MotionBuilder: OptiTrack Insight VCS Plugin

Overview

This page provides instructions on how to use the OptiTrack MotionBuilder Virtual Camera Device (Insight VCS) plugin. The Virtual Camera device is specifically designed for creating a Virtual Camera in MotionBuilder. You can use the Insight VCS device with standard OptiTrack applications such as Motive, or you can use the device in "Universal" mode, which works with generic MotionBuilder Optical or RigidBody objects, allowing you to use the Insight VCS device with alternative motion capture systems that support optical or Rigid Body devices in MotionBuilder.

Before following the walkthrough below, please refer to Autodesk MotionBuilder Plugin page for initial steps for setting up motive and downloading the OptiTrack MotionBuilder plugin.

Motive Data Streaming Setup (Server)

First, you'll want to follow the instructions below to set up the data streaming settings in Motive. Once this is configured, Motive will be broadcasting tracking data onto a designated network interface where client applications can receive them.

Streaming Settings

  • Enable - Turn on the Enable setting at the top of the NatNet section.

  • Local Interface - Choose the desired IP network address from this dropdown to stream data over.

    • Loopback

      • This is the local computer IP address (127.0.0.1 or Localhost).

      • Used for streaming data locally on the PC you are running Motive on that does not interact with the LAN.

      • Good option for testing network issues.

    • 192.168.0.1x (typical, but may be different depending on which interface is used to establish a LAN connection)

      • This IP address is the interface of the LAN either by Wi-Fi or Ethernet.

      • This will be the same address the Client application will use to connect to Motive.

  • Transmission Type

    • For streaming over a Wi-Fi network, setting the Transmission Type to Unicast is strongly advised.

  • Select desired data types to stream under streaming options:

    • Rigid Bodies - Enabled (required).

    • Skeletons - Optional for Skeleton tracking.

    • Markers (Labeled, Unlabled, Asset) - Disabled for HMDs (advised).

    • Devices - Disabled.

  • Skeleton Coordinates

    • Set to Local.

  • Bone Naming Convention

    • When streaming Skeletons, set to FBX.

Additional Tips

  • For best results, it is advised to run Motive and MotionBuilder separately on different computers, so that they are not competing for processing resources.

  • When streaming the data over a Wi-Fi network, Unicast transmission must be used.

  • In order to stream data from the Edit mode, a capture-recording must be playing back in Motive.

  • For additional information on data streaming in general, read through the Data Streaming page.

MotionBuilder Setup (Client)

To get started, drag the OptiTrack Optical plugin from the Motion Builder Asset Browser tab > Devices into the Viewer window. This will create a dropdown menu called I/O Devices in the Navigator tab. Click the + button next to I/O Devices and select OptiTrack Optical. This will populate the plugin's settings tab if it hasn't already auto-populated from the drag and drop step from earlier.

Device Settings

  • Local address - IP address of the MotionBuilder computer. In situations where multiple network adapter cards are present, select the adapter that is on the same network as the Motive application.

    • 127.0.0.1

      • This is the local computer IP address (127.0.0.1 or Localhost).

      • Use this loopback address if Motive is running on the same machine as MotionBuilder.

    • 192.168.0.1x (typical, but may be different depending on which interface is used to establish a LAN connection)

      • This IP address is the interface of the LAN either by Wi-Fi or Ethernet.

      • Use this if Motive is running on a different computer, but on the same network as the MotionBuilder computer.

    • 169.xxx.x.xx

      • This address is assigned when a DHCP server could not be reached.

      • This address can be ignored for our application.

  • Server Address - IP address of computer that is running Motive

    • 127.0.0.1

      • Use this IP when both Motive and MotionBuilder are running on the same computer.

  • Server Type

    • Multicast (default) or Unicast

    • Must match what is selected in the Motive Streaming settings.

    • Multicast is default and recommended.

Once the above settings are input appropriately, you'll want to click the box next to Online. This indicate whether or not Motive is successfully streaming to MotionBuilder.

  • Online color indicator

    • Green - Connected and streaming.

    • Yellow - Connected but not streaming.

    • Red - Not connected or streaming.

  • Live

    • Indicates to MotionBuilder that data is coming from a live source (checked) or from a recorded take.

  • Recording

    • Indicates to MotionBuilder that data from this device should be recorded when MotionBuilder is recording.

  • Model Binding

    • Indicates the MotionBuilder Camera to be controlled by the tracking controller.

  • Device Information

    • Information about the status of the connection.

  • OptiTrack Connection

    • Indicates the data source is an OptiTrack server application.

  • Universal Connection

    • Indicates the data source is a generic MotionBuilder RigidBody.

  • Rigid Body ID

    • [OptiTrack Connection] Name of the OptiTrack server application’s Rigid Body to use for tracking.

  • Rigid Body

    • [Universal Connection] Name of the MotionBuilder RigidBody to use as a position/orientation source.

Insight VCS Features

The Virtual Camera also integrates into existing MotionBuilder camera control workflows, including spline/path/constraint animation and custom scripted behaviors.

Creating a Virtual Camera Device (OptiTrack Server)

First you'll need to create the "neutral" or "zero" orientation of a Rigid Body

The “neutral” or “zero” orientation of a Rigid Body is the orientation when it is created in Motive. This will be the camera’s neutral orientation. In addition, for correct interpretation into MotionBuilder’s coordinate system, it is important you align your Rigid Body with the correct axis and coordinate system convention as follows:

  • Point your tracking controller (e.g. VCS Pro) along physical volume -Z axis.

Step-By-Step

After correctly orienting your Rigid Body follow the steps below to continue with the setup:

  1. [Motive] Create a Rigid Body from your tracking controller’s markers.

  2. [OptiTrack Server App] Enable network streaming (make sure Rigid Body data is streaming).

  3. [MotionBuilder] Drag the OptiTrack Insight VCS device from the Motion Builder Asset Browser Panel into the Viewer or Navigator window.

  4. [Insight VCS Panel] Connect to an OptiTrack Server (e.g. Motive, Arena, TrackingTools) by clicking the “Online” checkbox. If the connection was successful and data is streaming from you OptiTrack server application, this box will change from Red to Green.

  5. [Insight VCS Panel] Create a new MotionBuilder camera using the Model Binding dropdown.

  6. [Insight VCS Panel] [Optional] If tracking more than one Rigid Body object in your OptiTrack server application, select the Rigid Body you wish to use as your tracking source using the Rigid Body ID dropdown on the CameraTracker device panel (Note: the camera tracker will automatically default to the first detected Rigid Body).

You should now see a standard MotionBuilder Camera moving within your 3D scene:

Creating a Virtual Camera Device (Universal Mode)

In Universal mode, a MotionBuilder Rigid Body is used to drive a camera position. This position/orientation information is merged with the VCS camera controls and applied to the camera's final state (position, lens settings, etc.). It is assumed the Rigid Body orientation matches the MotionBuilder default camera orientation (camera lens aimed down +X axis). For example, if streaming from Motive, create a Rigid Body in MotionBuilder from the optical data, with the camera lens aimed down +X in MotionBuilder.

Step-By-Step

  1. [MotionBuilder] Create a Rigid Body or a Marker. For a Marker:

    • Create a bone (or some rigid element) from the geometry your 6DOF system streams into MotionBuilder

    • Create a MotionBuilder "Marker" element, and make this new marker a child of the bone

    • This new “Marker” marker should now have the same 6DOF value as the bone

    • . Use this “Marker” in the VCS universal dropdown to drive the 6DOF data of the VCS.

  2. [Insight VCS Panel] Check the "Universal Connection" Radio.

  3. [Insight VCS Panel] Check "Online".

  4. [Insight VCS Panel] Create a new MotionBuilder camera binding using the Model Binding dropdown.

  5. [Insight VCS Panel] Select the Rigid Body you created in step 1 using the Rigid Body dropdown in the Universal Connection group box.

Limitations

  • The following VCS features/properties are unavailable when operating in Universal Mode:

  • Scale Rotation

  • Offset Rotation

Controllers

The Insight VCS plugin supports any DirectInput compatible joystick or USB device. Controllers can then be configured to perform actions or control the camera using Controller Profiles.

Controller Profiles

Virtual Camera controls are managed by a Control-to-Event mapping system called the Controller Profile. The controller profile is configured in the Controller Tab. The Insight VCS plugin allows you to create and swap between multiple controller profiles, allowing you to create any number of custom button/axis configurations depending upon the scene, particular move types, different physical VCS controllers or HID devices, etc. Profiles can be saved and then later swapped out using the Profile Dropdown. Profiles are saved into <VCS Mobu install folder>\Profiles folder.

The VCS plugin ships with 2 default profiles:

  • The 2 controller VCS Pro (<VCS Mobu install folder>\Profiles\VCSProDefault.xml).

  • The XBox based VCS Mini (<VCS Mobu install folder>\Profiles\VCSMiniDefault.xml).

When the Insight VCS plugin is first launched, it will attempt to detect any compatible controllers. It will then attempt to match the detected controllers with an existing Controller Profile, beginning with the last used ("preferred") profile.

Profile Setup

The VCS plugin supports 2 types of controller inputs and 2 types of actions:

Axis Inputs / Actions

  • Axis inputs are analog inputs and represent the range of values. This range has been scaled to [0, 1000]. Axis inputs can be assigned to Axis actions. PTZ operations (Pan, Tilt, Zoom) are good examples of typical Axis Actions.

Button Inputs / Actions

  • Button inputs are the button inputs on the controller. These are “one shot” events that occur when the button is pressed. Transport commands such as Play, Record, and Rewind are typical examples of “one shot” events.

Some Insight VCS controllers have a dial that is represented in the Axis list as a "Wheel". This is a special form of an axis, and can be used to modify existing actions, such as zoom speed, pan speed, and motion scale amount.

Typical Insight VCS Controller Map

Insight VCS Inputs/Action Settings

Action Parameters

Some actions have parameters that modify the way they operate. The following tables list the axis and button actions, and how the parameter value for that action is interpreted.

VCS Controller - Axis Actions

Curve Types

When mapping a controller thumbstick axis to an animatable camera parameter (pan, zoom), you have the option of specifying how the Insight VCS plugin should interpret controller axis movement as a standard animation curve. Instead of modifying the value over time, however, the motion curve modifies the value over the controller span, from neutral/center position (0) to maximum position (Max). The following diagram describes this relationship:

Button Actions

VCS Controller - Button Actions

Run Script Usage

When using the Run Script action to map button presses to MotionBuilder scripts, be sure to note the following:

  1. Scripts must be placed in the MotionBuilder scripts folder in order to be correctly located. For a typical MotionBuilder installation this folder is:

    • C:\Program Files\Autodesk\MotionBuilder 2014\bin\config\Scripts:

  2. The RunScript Param is the filename of the script, including the .py extension:

Virtual Camera Device Settings

The Insight VCS plugin has several properties that can be used to customize its behavior. These properties can be accessed in the same manner as any other MotionBuilder object property, such as from the Asset Browser or from MotionBuilder's Python scripting environment.

MotionBuilder Camera Settings

A MotionBuilder Camera controls how you see the 3D scene. MotionBuilder’s Camera object allow users the ability to model realworld cameras, including settings such as Focal length, aspect ratio, film format, etc.

Refer to the MotionBuilder documentation for more information on Camera Settings.

Last updated