What does UnityARAlignment mean in Unity ARKit Plugins?

﹥>﹥吖頭↗ 提交于 2019-12-11 13:26:48

问题


UnityARAlignment

public enum UnityARAlignment
{
    UnityARAlignmentGravity,
    UnityARAlignmentGravityAndHeading,
    UnityARAlignmentCamera
}

As picture show, there are three options in Start Alignment. I want to know that what is the use of each option? What is their performance? I can't find the relevant information online.


回答1:


They are not documented yet but are ported based on ARConfiguration.WorldAlignment enum in ARKit. The UnityARAlignmentGravity, UnityARAlignmentGravityAndHeading and UnityARAlignmentCamera enum values are mapped to Apple's ARKit gravity, gravityAndHeading and camera respectively.

From the Apple doc, below are short definition for them. Click on each one to read more about them. This mostly has nothing to do with performance but instead helps configure the orientation of the camera or compass.

  • UnityARAlignment enum is equivalent to ARConfiguration.WorldAlignment - Options for how ARKit constructs a scene coordinate system based on real-world device motion.

  • UnityARAlignmentGravity - The coordinate system's y-axis is parallel to gravity, and its origin is the initial position of the device.

  • UnityARAlignmentGravityAndHeading - The coordinate system's y-axis is parallel to gravity, its x- and z-axes are oriented to compass heading, and its origin is the initial position of the device.

  • UnityARAlignmentCamera - The scene coordinate system is locked to match the orientation of the camera.



来源:https://stackoverflow.com/questions/50716817/what-does-unityaralignment-mean-in-unity-arkit-plugins

标签
易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!