Hello everyone.

The Mixed Reality Forums here are no longer being used or maintained.

There are a few other places we would like to direct you to for support, both from Microsoft and from the community.

The first way we want to connect with you is our mixed reality developer program, which you can sign up for at https://aka.ms/IWantMR.

For technical questions, please use Stack Overflow, and tag your questions using either hololens or windows-mixed-reality.

If you want to join in discussions, please do so in the HoloDevelopers Slack, which you can join by going to https://aka.ms/holodevelopers, or in our Microsoft Tech Communities forums at https://techcommunity.microsoft.com/t5/mixed-reality/ct-p/MicrosoftMixedReality.

And always feel free to hit us up on Twitter @MxdRealityDev.
Options

SpatialCoordinateSystem (C++)

I was wondering what your technique is for extracting the matrix for this translation? Based on msdn there is only one function here without properties to access the raw matrix. I haven't tried this yet but my thought is on applying its TryGetTransformTo to an Identity matrix and see what matrix it spits out.

http://www.redsprocketstudio.com/
Developer | Check out my new project blog

Tagged:

Comments

  • Options
    AmerAmerAmerAmer ✭✭✭
    edited February 2017

    I found what I was looking for. Anyone working on similar you need to use the spatialLocator class to create a frame of reference with a world matrix of your choosing, in this instance with origin of 0,0,0.

    Windows::Perception::Spatial::SpatialLocator ^ loc =Windows::Perception::Spatial::SpatialLocator::GetDefault();
    
    auto locReference = loc->CreateStationaryFrameOfReferenceAtCurrentLocation(Windows::Foundation::Numerics::float3(0, 0, 0), Windows::Foundation::Numerics::quaternion::identity());
    locReference->CoordinateSystem  is the coordinate system you can now trytransformTo() to world matrix of your choosing. 
    

    http://www.redsprocketstudio.com/
    Developer | Check out my new project blog

Sign In or Register to comment.