USB Devices User Guide

Vortex® Studio supports multiples types of devices, as long as the proper modules are in the application setup.

Note Plugging in a USB device (such as a mouse or gamepad) to the computer does not require you to restart the Editor or Player. This action is sometimes referred to as hot swapping or hot plugging.

Some devices require extensions to be added either in the content or in the application setup. In some cases, the extensions are added in the application without any user intervention.

Vortex Studio supports USB gamepads that use the Microsoft DirectInput or XInput interfaces. We recommend to always use the XInput interface.

In some previous versions, it was required to add Joystick extensions directly in the content (i.e., in a mechanism) and make the connections from the buttons to the proper fields. This implementation is still supported, but it is also possible to simply add a joystick module to your application setup. The module detects connected gamepads and adds the extensions to your application.

Mapping the devices to the content needs to be done within the Vortex Studio Player, using the Control Presets tab.

When detecting devices, the associated extension will be named according to the information retrieved from the Windows API. Names of the device extensions include the host name of the machine and the process ID to easily debug a simulator with multiples nodes.

DirectInput Devices

DirectInput is a device protocol supported by Microsoft. When such a device is detected, an extension will be created for it.

The extension name will reflect the name seen in the Devices and Printers page in Windows, with an index starting at 0, incrementing per similar devices.

The following example shows a Microsoft Windows Devices and Printers page against the Vortex Studio Player's Content Debugger. No asset was loaded, however the module detected the following devices:

  • Two Logitech F310 gamepads with their switch set to DirectInput (showing up as Logitech Dual Action),
  • One Logitech F710 gamepad set to DirectInput (showing up as Logitech Cordless RumblePad 2)
  • One Microsoft Xbox 360 Controller.

The DeviceID information is displayed in the Content Debugger tab, with the following format: device name + index + hostname + PID.

XInput Devices

XInput is another device protocol supported by Microsoft, with more gameplay features than DirectInput. When such a device is detected, an extension will be created for it.

Since the XInput Protocol provides less information than DirectInput, the device will not contain the names seen in Windows; devices are described as "XInput Controller" followed by an index.

If the device is a wheel, it will show up as "XInput Wheel"; the name is based on the XInput subtype.

In the example below, the same gamepads as above were used, but their switch was set to XInput.

Upgrading Joysticks from Content to Control Presets

Vortex Studio supports using USB joysticks by adding the joystick extension to your scene or mechanism. With the introduction of the control presets, users now have the option to remove the joystick extension from their content.

One control interface can be used with multiple different devices including a USB joystick device. The mapping between control interface and devices is done from the Vortex Studio Player Control Presets tab.

To replace a joystick in your content with a joystick in a Vortex Studio Player control preset:

  1. Create a Control Interface document in Vortex Studio Editor. It should match the inputs present on your VxJoystickExtension.
    • If you were using any 'ToggleButton', it must be replaced with the actual button combined with a script to hold the button state changes in your mechanism. Refer to Python Scripting documentation.
  2. Add the newly created control interface to your current mechanism containing the VxJoystickExtension.
  3. Right-click on the control interface entry in the Explorer panel and select Link from the context menu.
  4. Link the inputs of the control interface with the fields that your current joystick was connected to. Save your mechanism.
  5. Follow the instructions for creating preset mappings for your control interface document in Vortex Studio Player.

3Dconnexion SpaceNavigator Mouse Integration

Vortex Studio supports 3Dconnexion's SpaceNavigator 3D mouse as a manipulator.

To use a SpaceNavigator 3D mouse:

  • Download and install the drivers from the 3Dconnexion's web site.
  • Add the "Space Navigator Manipulator" extension to the desired application node (should have a graphics module) in the setup document.
  • Start your simulator with the modified setup.

See also 3Dconnexion SpaceNavigator Mouse Mappings

Joystick Controlled Point

A Joystick Controlled Point is a content extension that handles joystick (gamepad) events, and outputs a world transform matrix. It allows you to move a point in 3D space through gamepad controls.

A common use case for this extension is to control a viewpoint or a camera.

Note To function properly, this extension requires the gamepad to be in DirectInput interface.

To add the extension in the Vortex Studio Editor and connect it to a camera:

  1. In the Toolbox, select Input Devices. Double-click Joystick Controlled to add it to your scene or mechanism.
  2. In a Connection Editor, connect the Joystick Controlled Point's Outputs > World Transform to the Inputs > Parent Transform of a Cameras Extensions.

The extension exposes four parameters which allow you to pre-select four movement speeds (Very Low Speed, Low Speed, Default Speed, High Speed) which are mapped to the four basic buttons on the gamepad. Each parameter include a linear speed (in meters per second) used for the move controls and an angular speed in (degrees per second) used for the tilt and pan.

Pressing the corresponding button on the gamepad will change the linear and angular speeds while moving the point with the other gamepad controls.

The Joystick Controlled Point can be controlled using the following gamepad mapping in DirectInput mode.


1

Up and down: Move forward/back
Left and right: Move sideways
2
Up and down: Tilt
Left and right: Pan
3
Reset button: Switches to Default Speed while resetting the yaw to 0.0 and the pitch to its initial value. It will also move the point back to the origin.
4
Left button (X): Very Low Speed
5
Top button (Y): High Speed
6
Right button (B): Default Speed
7
Bottom button (A): Low Speed
8
Right blade (RB): Move up
9
Left blade (LB): Move up
10
Right trigger (RT): Move down
11
Left trigger (LT): Move down

Note Keyframes and the Joystick Controlled Point When an application saves and subsequently restores a key frame, traditionally all extensions gets their "state" (all of its inputs, outputs and parameters) restored to the values saved in the key frame.The Joystick Controlled Point is an exception to this. It will not be restored and will keep its current position and speed settings.