• Home
  • Guides
  • API Documentation
WLT documentation has moved.

We are publishing both conceptual docs and API references on docs.microsoft.com. For conceptual docs, please visit our new landing page. For API references, please visit the Core WLT section of the dot net API explorer and related pages. Existing content will remain here but will not be updated further.

  • API Documentation
  • Reference
  • Microsoft.MixedReality.WorldLocking.Core
  • AlignmentManager
Search Results for

    Show / Hide Table of Contents
    • Reference
      • Microsoft.MixedReality.WorldLocking.ASA
        • IBinder
        • IBindingOracle
        • ILocalPeg
        • IPublisher
        • LocalPegAndProperties
        • PublisherASA
        • PublisherReadiness
        • ReadinessStatus
        • SpacePinASA
        • SpacePinASA.KeyValPair
        • SpacePinBinder
        • SpacePinBinderFile
        • SpacePinCloudBinding
      • Microsoft.MixedReality.WorldLocking.ASA.Examples
        • ActionCube
        • ActionPublish
        • PlatformMenuSelector
        • ScreenSpacer
        • SpacePinASAManipulation
        • Startup
      • Microsoft.MixedReality.WorldLocking.Core
        • AdjustLocationDelegate
        • AdjustStateDelegate
        • AlignmentManager
        • AlignSubtree
        • AnchorManager
        • AnchorManager.SpongyAnchorWithId
        • AnchorManagerARCore
        • AnchorManagerNull
        • AnchorManagerWSA
        • AnchorSettings
        • AnchorSettings.AnchorSubsystem
        • AttachmentPoint
        • AttachmentPointStateType
        • Diagnostics
        • Diagnostics.Record
        • DiagnosticsSettings
        • Fragment
        • HeadPoseTrackerCamera
        • HeadPoseTrackerXR
        • IAlignmentManager
        • IAnchorManager
        • IAttachmentPoint
        • IAttachmentPointManager
        • IFragmentManager
        • IHeadPoseTracker
        • IOrientable
        • IOrienter
        • LinkageSettings
        • ManagerSettings
        • Orienter
        • Orienter.WeightedRotation
        • OrienterThreeBody
        • PoseExtensions
        • PostAlignmentLoadedDelegate
        • RefitNotificationDelegate
        • ResourceMirror
        • ResourceMirror.CompareToResource<ItemType, ResourceType>
        • ResourceMirror.CreateResource<ItemType, ResourceType>
        • ResourceMirror.DestroyResource<ResourceType>
        • ResourceMirror.UpdateResource<ItemType, ResourceType>
        • SharedDiagnosticsSettings
        • SharedManagerSettings
        • SpacePin
        • SpacePin.ModelPositionSourceEnum
        • SpacePinOrientable
        • SpongyAnchor
        • SpongyAnchorARCore
        • SpongyAnchorARF
        • SpongyAnchorNull
        • SpongyAnchorWSA
        • SpongyAnchorXR
        • TransformExtensions
        • WorldLockingContext
        • WorldLockingManager
      • Microsoft.MixedReality.WorldLocking.Core.ResourceMirrorHelper
        • IdPair<IdType, T>
      • Microsoft.MixedReality.WorldLocking.Core.Triangulator
        • Interpolant
        • ITriangulator
        • SimpleTriangulator
      • Microsoft.MixedReality.WorldLocking.Examples
        • AlignmentControl
        • CircleCam
        • DashboardCommand
        • DashboardUI
        • FallOut
        • ManipulationEndedDelegate
        • ManipulationStartedDelegate
        • PhysicsBeamSample
        • PinManipulator
        • RayPins
        • SpacePinManipulation
        • SpacePinOrientableManipulation
      • Microsoft.MixedReality.WorldLocking.Tools
        • AdjusterBase
        • AdjusterFixed
        • AdjusterMoving
        • AnchorGraphVisual
        • ConnectingLine
        • FrameVisual
        • FrozenAnchorVisual
        • FrozenSpatialMapping
        • FrozenSpatialMapping.QualityType
        • FrozenTapToAdd
        • SimpleConsole
        • SimpleSprite
        • SpacePinMeshVisualizer
        • SpacePinPercentageVisualizer
        • SpongyAnchorVisual
        • StatusToText
        • ToggleWorldAnchor
        • WorldAnchorAdapter
        • WorldLockingSetup

    Class AlignmentManager

    Unity level implementation of aligning Unity's coordinate system
    with a discrete finite set of markers in the real world.

    Inheritance
    Object
    AlignmentManager
    Implements
    IAlignmentManager
    Inherited Members
    Object.ToString()
    Object.Equals(Object)
    Object.Equals(Object, Object)
    Object.ReferenceEquals(Object, Object)
    Object.GetHashCode()
    Object.GetType()
    Object.MemberwiseClone()
    Namespace: Microsoft.MixedReality.WorldLocking.Core
    Assembly: cs.temp.dll.dll
    Syntax
    public class AlignmentManager : IAlignmentManager
    Remarks

    In addition to anchoring the otherwise arbitrary WorldLocked coordinate space to this set of correspondences, this addresses the tracker-scale issue, whereby due to tracker error, traversing a known distance in the real world traverses a different distance in Unity space. This means that, given a large object of length L meters in Unity space, starting at one end and walking L meters will not end up at the other end of the object, but only within +- 10% of L. Use of this service gives fairly exact correspondence at alignment points, and by interpolation gives fairly accurate correspondence within the convex set of alignment points. Note that no extrapolation is done, so outside the convex set of alignment points results, particularly with respect to scale compensation, will be less accurate.

    Constructors

    AlignmentManager(WorldLockingManager)

    Constructor, binds to a specific WorldLockingManager. Also registers for scene loading events.

    Declaration
    public AlignmentManager(WorldLockingManager manager)
    Parameters
    Type Name Description
    WorldLockingManager manager

    WorldLocking manager which owns this sub-manager.

    Properties

    NeedSave

    Declaration
    public bool NeedSave { get; }
    Property Value
    Type Description
    Boolean

    PinnedFromLocked

    The pose to insert into the camera's hierarchy above the WorldLocking Adjustment transform (if any).

    Declaration
    public Pose PinnedFromLocked { get; }
    Property Value
    Type Description
    Pose

    SaveFileName

    File to save to and load from.

    Declaration
    public string SaveFileName { get; set; }
    Property Value
    Type Description
    String
    Remarks

    May optionally contain subpath. For optimal portability, use forward slashes, e.g. "myPath/myFile.myExt". May NOT be an absolute path (e.g. "/myPath.txt" or "c:/myPath.txt" are NOT allowed and will be ignored.) Application can check validity of path using static AlignmentManager.IsValidSavePath(string). Defaults to "Persistence/Alignment.fwb".

    Methods

    AddAlignmentAnchor(String, Pose, Pose)

    Declaration
    public AnchorId AddAlignmentAnchor(string uniqueName, Pose virtualPose, Pose lockedPose)
    Parameters
    Type Name Description
    String uniqueName
    Pose virtualPose
    Pose lockedPose
    Returns
    Type Description
    AnchorId

    ClearAlignmentAnchors()

    Declaration
    public void ClearAlignmentAnchors()

    ComputePinnedPose(Pose)

    Do the weighted average of all active reference poses to get an alignment pose.

    Declaration
    public void ComputePinnedPose(Pose lockedHeadPose)
    Parameters
    Type Name Description
    Pose lockedHeadPose

    Dispose()

    Dispose of internals on shutdown.

    Declaration
    public void Dispose()

    Finalize()

    Dispose of internals on shutdown.

    Declaration
    protected void Finalize()

    GetAlignmentPose(AnchorId, out Pose)

    Declaration
    public bool GetAlignmentPose(AnchorId anchorId, out Pose lockedPose)
    Parameters
    Type Name Description
    AnchorId anchorId
    Pose lockedPose
    Returns
    Type Description
    Boolean

    IsValidSavePath(String)

    Check validity of a save/load path. Any path not passing this test will be ignored without error.

    Declaration
    public static bool IsValidSavePath(string filePath)
    Parameters
    Type Name Description
    String filePath

    The path to test.

    Returns
    Type Description
    Boolean

    True if a valid path.

    Load()

    Load the database and issue notification if loaded.

    Declaration
    public bool Load()
    Returns
    Type Description
    Boolean

    True if loaded.

    RegisterForLoad(PostAlignmentLoadedDelegate)

    Register for notification after any successful loads.

    Declaration
    public void RegisterForLoad(PostAlignmentLoadedDelegate del)
    Parameters
    Type Name Description
    PostAlignmentLoadedDelegate del

    Delegate to call after successful load.

    Remarks

    Registration holds until a corresponding call to UnregisterForLoad(PostAlignmentLoadedDelegate).

    RemoveAlignmentAnchor(AnchorId)

    Declaration
    public bool RemoveAlignmentAnchor(AnchorId anchorId)
    Parameters
    Type Name Description
    AnchorId anchorId
    Returns
    Type Description
    Boolean

    RestoreAlignmentAnchor(String, Pose)

    Declaration
    public AnchorId RestoreAlignmentAnchor(string uniqueName, Pose virtualPose)
    Parameters
    Type Name Description
    String uniqueName
    Pose virtualPose
    Returns
    Type Description
    AnchorId

    Save()

    Explicitly save the database.

    Declaration
    public bool Save()
    Returns
    Type Description
    Boolean

    True if successfully saved.

    SendAlignmentAnchors()

    Declaration
    public void SendAlignmentAnchors()

    UnregisterForLoad(PostAlignmentLoadedDelegate)

    Un-register for post load notifications, after registration via RegisterForLoad(PostAlignmentLoadedDelegate).

    Declaration
    public void UnregisterForLoad(PostAlignmentLoadedDelegate del)
    Parameters
    Type Name Description
    PostAlignmentLoadedDelegate del

    The delegate to unregister.

    Events

    OnTriangulationBuilt

    Declaration
    public event EventHandler<ITriangulator> OnTriangulationBuilt
    Event Type
    Type Description
    EventHandler<ITriangulator>

    Implements

    IAlignmentManager
    In This Article
    • Constructors
      • AlignmentManager(WorldLockingManager)
    • Properties
      • NeedSave
      • PinnedFromLocked
      • SaveFileName
    • Methods
      • AddAlignmentAnchor(String, Pose, Pose)
      • ClearAlignmentAnchors()
      • ComputePinnedPose(Pose)
      • Dispose()
      • Finalize()
      • GetAlignmentPose(AnchorId, out Pose)
      • IsValidSavePath(String)
      • Load()
      • RegisterForLoad(PostAlignmentLoadedDelegate)
      • RemoveAlignmentAnchor(AnchorId)
      • RestoreAlignmentAnchor(String, Pose)
      • Save()
      • SendAlignmentAnchors()
      • UnregisterForLoad(PostAlignmentLoadedDelegate)
    • Events
      • OnTriangulationBuilt
    • Implements
    Back to top Generated by DocFX