The Meta Mouse is an input method that enables a computer mouse to be used in a three-dimensional AR environment. When using the Meta Mouse, a special mouse cursor will be visible in the application window which allows you to interact with 3D elements in the Unity scene. This feature can be added to your scene by importing the MetaInputModule prefab.

When the Meta Mouse is active, it locks the mouse position in Windows and uses the real mouse’s input to drive the virtual Meta Mouse. As this functionality can confuse novice users, the Meta Mouse is disabled by default when creating a new scene. To toggle it on or off, press F8.

Meta Mouse Event System

The Event System is a Unity component which is used by the Meta Mouse to control how Meta Mouse events are emitted to GameObjects within your scene.

Unity Event System

Meta Input Module

The Meta Input Module allows you to configure general settings for Meta Mouse interactions. It inherits from the Unity Standalone Input Module. Please refer to this corresponding Unity documentation for any behavior not covered within this section.

Meta Mouse Meta Input Module

The following properties are provided by the Meta Mouse Input Module:

  • Horizontal Axis - The name of the horizontal input axis from the InputManager.
  • Vertical Axis - The name of the vertical input axis from the InputManager.
  • Submit Button - The name of the submit action binding from the InputManager.
  • Cancel Button - The name of the cancel action binding from the InputManager.
  • Input Actions Per Second - Number of input device inputs (e.g. from a keyboard or controller) allowed per second (see the Unity Standalone Input Module docs).
  • Repeat Delay - Delay in seconds before the limitation of the number of input actions per second specified by the input’s repeat rate takes effect (see the corresponding Unity documentation).
  • Force Module Active - Force this module to be active (see the corresponding Unity documentation).

Within the Meta Input Module component, the Meta Mouse Config section allows you to configure additional settings:

Meta Mouse Config

These properties control the following behaviors:

  • Sensitivity - The mouse’s input sensitivity, similar to Windows’ pointer speed setting.
  • Float Distance - The distance from the camera (i.e. depth) at which the Meta Mouse floats when it is not hovering over a UI element.
  • Distance Damp - The damping factor which controls the rate at which the Meta Mouse moves from its current depth to the depth of the UI element which it has hovered over (or the opposite).
  • Enable On Start - Whether the Meta Mouse is enabled on application launch.

Getting Started

To use the Meta Mouse, you must add the MetaInputModule prefab to your scene. This can be found in the Assets/MetaSDK/Meta/Mouse/Prefabs folder.

MetaMouse Prefab

The Meta Mouse is designed to work with Unity’s UI System. In order for UI Canvases to be clickable, they should be configured to use ‘World Space’ as the render mode. No event camera is necessary.

The physical mouse may then be used to interact with the Unity UI components (e.g. Buttons) in the scene. When the Meta Mouse cursor is over a UI element, it will move toward or away from the user to match the UI element’s depth. For more information see the Unity Canvas.

Example Scene

An example scene that demonstrates the features of the Meta Mouse can be found in your project, under Assets/MetaSDK/MetaExamples/SDK/MouseCubeInteraction.unity.

This example scene demonstrates a simple cube. Use F8 to enable/disable the Meta Mouse. If the mouse is moved over the cube, the blue mouse cursor will become visible.