Reputation: 446
I feel the documentation and the tutorials to the ArCore are not enough and I need to know how I can place an anchor in mid air without the need for surface detection. Most of the source code available on AR core seems to deal with placing objects after surface detection. I need to know how I can get a Session object, and place an anchor in the mid air as soon as the app opens. I'm currently using Sceneform on top of ARCore
Am I the only one to feel that the documentation available for ARCore is not enough?
Upvotes: 2
Views: 1546
Reputation: 615
Take a look at this Github issue: Can i place a anchor of the object in air instead of plane in ar-core android?
This example from the Github issue places an anchor straight in front of the camera 1m away:
mAnchors.add(session.createAnchor(
frame.getCamera().getDisplayOrientedPose()
.compose(Pose.makeTranslation(0, 0, -1f))
.extractTranslation()))
In the create Anchor documentation you see, that you only need a pose for creating an anchor.
Upvotes: 2