Skip to content

Commit 6869390

Browse files
author
Jared Bienz
committed
Final docs ready for Release 1.0.0
1 parent 0f91b27 commit 6869390

File tree

6 files changed

+44
-11
lines changed

6 files changed

+44
-11
lines changed
-52.9 KB
Loading
-54.2 KB
Loading
-66.7 KB
Loading
-43.8 KB
Loading
-67.2 KB
Loading

README.md

Lines changed: 44 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -1,48 +1,81 @@
11
# Spatial Alignment for Unity
2+
23
This reference architecture includes many helpful components for aligning and keeping virtual objects aligned with the physical world.
34

5+
46
### Release 1.0
7+
58
Release 1.0 contains the following capabilities:
69

7-
##### Spatial Frames
8-
*Spatial Frames* represent "islands" in the real world. They have a position and a rotation and are designed to hold objects. They also have unique IDs and can be available from the moment the application loads (even before they're found in the real world). This simplifies application logic because objects can be loaded up front and automatically aligned when the frame is found.
10+
11+
#### Spatial Frames
12+
13+
*Spatial Frames* represent "islands" in the real world. They have a position and a rotation and are designed to hold objects. They also have unique IDs and are available from the moment the application loads (even before they're found in the real world). This simplifies application logic because objects can be loaded up front and automatically aligned when the frame is found.
914

1015
![](External/ReadMeImages/Align-FramesAndStrategies.png)
1116

17+
1218
##### Alignment Strategies
13-
Each *Spatial Frame* has an *Alignment Strategy*. The strategy is what moves the frame and keeps it aligned in the physical world. Alignment Strategies are "plugins", and developers can easily create their own strategies. Applications are free to mix and match various strategies in the same application.
19+
20+
Each *Spatial Frame* has an *Alignment Strategy*. The strategy is what moves the frame and keeps it aligned in the physical world. Alignment Strategies are "plugins", and developers can easily create their own strategies. Developers are also free to mix and match various strategies in the same application.
1421

1522
![](External/ReadMeImages/Align-MixStrategies.png)
1623

17-
Alignment Strategies provide information about their state (e.g. whether they've been found) and their accuracy (maximum drift in meters). Applications can then use this information to make intelligent decisions about the best frames to use contain objects. In fact, one of the included strategies is a *Multi-Parent* strategy that allows objects to automatically "hop" parent frames based on their state and accuracy.
24+
Alignment Strategies provide information about their state (e.g. whether they've been found) and their accuracy (maximum drift in meters). Applications can use this information to make intelligent decisions about which frames are best to contain which objects. In fact, one of the included alignment strategies is a *Multi-Parent* strategy that allows objects to automatically "hop" parent frames based on their state and accuracy.
1825

1926
![](External/ReadMeImages/Align-ParentHopping.png)
2027

21-
##### Refinement
22-
Two of the greatest challenges with spatial alignment are:
28+
29+
#### Refinement
30+
31+
Two of the biggest challenges that accompany spatial alignment are:
2332

2433
1. Initial placement (and rotation) of objects to match up with the physical world
2534
2. Accounting for drift that accumulates over distance (a challenge that is present in all large-scale tracking systems)
2635

27-
This reference architecture includes components to help address both. To help with accurate alignment, an extensible system of *Refinement Controllers* is provided. Version 1.0 there includes one refinement controller called **RayRefinement**. **RayRefinement** aligns a virtual model and a physical space by selecting corresponding origin points and directions.
36+
This reference architecture includes components to help address both. To help with accurate alignment, an extensible system of *Refinement Controllers* is provided. Version 1.0 includes one refinement controller called **RayRefinement**. **RayRefinement** aligns a virtual model to a physical place by selecting corresponding origin points and directions.
2837

2938
![](External/ReadMeImages/Align-RayRefine.gif)
3039

3140
To help compensate for drift, *Multi-Parent* alignment offers the ability to apply different positional and rotational offsets at each parent.
3241

3342
![](External/ReadMeImages/Align-Refine.png)
3443

35-
This ability can be combined with a *Refinement Controller* to bring large-scale models back into alignment when viewed from different locations.
44+
The offset ability can be used together with a *Refinement Controller* to bring large-scale models back into alignment when viewed from different locations.
3645

37-
The video below demonstrates using **RayRefinement** to align a [Matterport 3D](https://matterport.com/) scan of a building and keep that scan in alignment.
46+
The video below demonstrates using **RayRefinement** to align a [Matterport 3D](https://matterport.com/) scan of a building with the actual building and keep that scan in alignment from different locations.
3847

3948
[![](External/ReadMeImages/Align-MPScanVideo.jpg)](https://youtu.be/IINWbBeIRL0)
4049

41-
##### Persistence
4250

51+
#### Persistence
52+
53+
Applications that leverage spatial alignment generate a notable amount of configuration data:
54+
55+
- All of the Frames and their IDs
56+
- All of the configuration settings for each Alignment Strategy
57+
- Relationships between Frames (e.g. Multi-Parent alignment)
58+
- Position, Rotation and Scale offsets
59+
- State requirements (e.g. Resolved, Tracking)
60+
- Accuracy requirements
61+
- etc.
62+
63+
To help applications save all of this data, every component in the architecture is serializable. In fact, the included class **JsonStore** can be used to serialize an entire alignment "graph" into json, which can then be loaded back the next time the application runs.
64+
65+
![](External/ReadMeImages/Align-Persistence.png)
66+
67+
68+
#### Examples
69+
70+
Release 1.0 includes the following example scenes:
71+
72+
- **SA-MultiParent** - Demonstrates "hopping" between multiple parent spheres in the scene.
73+
- **SA-Persistence** - Demonstrates saving an entire "graph" of frames and their strategies into memory then loading them back into the scene.
74+
- **SA-Refinement** - Demonstrates using **RayRefinement** to place a multi-colored cube in a room.
75+
- **SA-RefinementBuilding** - Demonstrates using **RayRefinement** to align a Matterport 3D scan to room. (This example is shown in the video above).
4376

44-
##### Examples
4577

78+
### Contributing
4679

4780
This project has adopted the [Microsoft Open Source Code of Conduct](https://opensource.microsoft.com/codeofconduct/).
4881
For more information see the [Code of Conduct FAQ](https://opensource.microsoft.com/codeofconduct/faq/) or contact [[email protected]](mailto:[email protected]) with any additional questions or comments.

0 commit comments

Comments
 (0)