Unity package for creating experiences with Solipsist Stage.
NB: This package is in preview! Do not depend on the API for experiences in production!
The goal of the Stage platform is to provide creators with the tools to share their mixed reality creations with the world. Powered by Azure Spatial Anchors and built to run in the Azure cloud.
A fully-managed, hosted service is offered for those who are looking to start building without the technical overhead. See Solipsist Studios Homepage.
Self-hosting is always free!
- Support for Netcode for Game Objects networking package
- Serialize and deserialize objects attached to spatial anchors
- Android devices (API >= 8.0)
- Microsoft HoloLens 2
- WebXR coming soon!
Also probably works on iOS and Magic Leap, but is untested.
-
- Use the Microsoft Mixed Reality Feature Tool to install the following features:
- Azure Mixed Reality Services
- Azure Spatial Anchors SDK Core
- Azure Spatial Anchors SDK (Windows, iOS and/or Android)
- MRTK3
- MRTK Core Definitions
- MRTK Graphics Tools
- MRTK Input
- Platform Support
- Mixed Reality OpenXR Plugin
- Azure Mixed Reality Services
- Install Unity packages using Install from a Git URL for the following packages:
- WebSocket transport for Netcode for Game Objects
https://github.com/Unity-Technologies/multiplayer-community-contributions.git?path=/Transports/com.community.netcode.transport.websocket
- Add this package from a Git URL using the same process:
https://github.com/solipsist-studios/stage-unity.git
- WebSocket transport for Netcode for Game Objects
- Set up MRTK or other XR interaction packages according to their instructions
- Use the Microsoft Mixed Reality Feature Tool to install the following features:
-
Add necessary prefabs to scene
- Network Manager
- Azure Spatial Anchors Manager
-
Add calls to load / save spatial anchors
- Call the
AzureSpatialAnchorsManager.AzureSpatialAnchors.AddAnchor
function to persist an object - Subscribe to
AzureSpatialAnchorsManager.AzureSpatialAnchors.AnchorLocatedCallback
to be notified when an anchor is loaded
- Call the
-
Create a server configuration
- Under Assets, create a Resources folder, and in that folder create a
Solipsist Stage->Configuration
asset - Accept the default name,
StageConnectionConfig.asset
- Under Assets, create a Resources folder, and in that folder create a
-
Build the Unity project for the Dedicated Server/Linux platform
-
Add the contents of the build directory, excluding the
..._BurstDebugInformation_DoNotShip
folder, to a .tar.gz archive. -
Use the solx CLI tool to upload and launch your dedicated server
- Follow the steps to download and use the solx CLI tool.
- Open a command prompt
- Navigate to the folder where you have extracted the solx.exe file
- Run the following command
.\solx cat add --file "c:\path\to\your\linuxserver.tar.gz" --name <app-name>
Note that app-name
should contain only alphanumeric characters or '-'
1. When that completes, take note of the experience-id
that is generated
1. Run the following command
.\solx cat launch --experience-id 00000000-0000-0000-0000-000000000000
Replacing the experience-id with the one you copied from the previous step
- Build and deploy the Unity project to your client devices
Your Azure administrator can provide you with the values for the following steps
- In Unity, open the Assets/AzureSpatialAnchors.SDK/Resources/SpatialAnchorConfig.asset file
- In the inspector, select "Api Key" for Authentication Mode, and fill out each value under Credentials
- Open the StageConnectionConfig.asset file you created in an earlier step
- Change
Network Role
toClient
- Fill out the remaining values according to your server
- Change
- Build the project for your desired platform and run