(!arCoreApk.checkAvailability(this).isSupported()) { // Not supported - notify user! return } if (arCoreApk.requestInstall(this, true) == ArCoreApk.InstallStatus.INSTALL_REQUESTED)) { // Installation needed - activity will pause return } // Everything is ok to go! } Moble AR with ARCore - @ErikHellman, Øredev 2018
implementation 'com.google.ar:core:1.5.0' // Provides ArFragment, and other UX resources. implementation 'com.google.ar.sceneform.ux:sceneform-ux:1.5.1' // Alternatively, use ArSceneView without the UX dependency. implementation 'com.google.ar.sceneform:core:1.5.1' } Moble AR with ARCore - @ErikHellman, Øredev 2018
hitResult, plane, motionEvent -> // Create new anchor and node val anchor = hitResult.createAnchor() val anchorNode = AnchorNode(anchor) // Add to the scene anchorNode.setParent(arFragment.arSceneView.scene) // TODO Add content to the new anchor... } Moble AR with ARCore - @ErikHellman, Øredev 2018