swift - 低端设备支持 ARKit 吗?

标签 swift arkit

在 Apple 演示中,他们表示如果不支持 ARWorldTrackingConfiguration,我们可以使用较小的 AROrientationTrackingConfiguration(以前称为 ARSessionConfiguration)。

但是当我在 A8 设备(iPad mini 4)上尝试此操作时,是否让 ARWorldTrackingConfiguration() 失败并没有什么区别。跟踪根本不起作用。

if ARWorldTrackingConfiguration.isSupported {
    let configuration = ARWorldTrackingConfiguration()
    sceneView.session.run(configuration)
}
else {
    sceneView.session.run(AROrientationTrackingConfiguration())
}

如果A8不支持ARKit,那么支持AROrientationTrackingConfiguration()还有什么意义呢?

最佳答案

所有 ARKit 仅支持 A9 及以上版本,包括 AROrientationTrackingConfiguration。正如他们在 ARKit docs 顶部所说...

Important ARKit requires an iOS device with an A9 or later processor.

To make your app available only on devices supporting ARKit, use the arkit key in the UIRequiredDeviceCapabilities section of your app's Info.plist. If augmented reality is a secondary feature of your app, use the isSupported property to determine whether the current device supports the session configuration you want to use.

因此,您确实可以制作仅在部分 iOS 11 设备上可用的 iOS 11 应用。要求 UIRequiredDeviceCapability 中的某些内容会使 App Store 不会在您不支持的设备上提供您的应用程序,并使 iTunes 拒绝安装该应用程序。

(是的,苹果似乎花了一点时间才把他们的故事讲清楚。回到 WWDC,他们似乎会在较小的设备上支持 3DOF 跟踪,但现在你甚至需要 A9。)


那么现在 AROrientationTrackingConfiguration 的意义何在?

对于某些类型的应用,当当前条件不允许 6DOF 时,从世界跟踪 (6DOF) 回退到仅方向跟踪 (3DOF) 可能是有意义的。对于将虚拟对象放在 table 上的应用程序来说,这没有多大意义,但如果你只是将太空入侵者放在空中供玩家射击,或者使用 AR 在天空上覆盖星座,那么失去 6DOF 并不会造成影响。不要这么破坏体验。

关于swift - 低端设备支持 ARKit 吗?,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/46014284/

相关文章:

ios - 将 View Controller 放入导航堆栈然后弹出不会释放内存并导致内存泄漏

ios - 为什么 ARFaceAnchor 和 ARImageAnchor 是唯一符合协议(protocol) ARTrackable 的 anchor 类型?

ios - ARKIT:使用 PanGesture 移动对象(正确方式)

ios - Storyboard Segues 的命名约定

ios - “文本”不可用 : APIs deprecated as of iOS7. .. 如何从 alert.textFields[0] 获取文本值?

swift - 如何从 api 返回已解析的 JSON?

swift - ARKit – 使用世界射线而不是屏幕点进行光线转换

ios - 点击扫描平面时如何将 3D 对象添加到引用图像?

swift - 快速捕获列表自身

ios - 预期返回 'UITableViewCell' 的函数中缺少返回值