Hi, I am working on webxr with babylon js, placing anchors in real world using hit-test and anchor system. But when I place anchors(Arrows) very close to camera it is moving with camera. It doesn’t get anchored to surface in this case. I tried to solve by using pickRay and skybox still I get same result.
Can you please confirm if this is a limitation related to ARCore?
The “wandering” typically occurs when an arrow is placed before AR tracking has detected a stable surface near the camera. At very close range (<30–40 cm), hit-test rays often return noisy results because there isn’t enough geometry mapped yet. Anchors created at those poses can therefore drift or wander.
If the headset is moving the anchors as it updates the tracked surfaces then there’s not much we can do about it. Is that what you’re describing?
If you post a link to a playground example that shows the issue (to make sure we’re on the same page), I’ll be happy to investigate! The WebXR playgrounds from the docs may be a good starting point.
Hi, I am currently testing with a android phone. Please find link of the the working example - https://webxr-babylon.web.app
Steps to test:
Enter AR
select arrow
enter immersive-ar
Once detecting environment finishes you can start placing arrows
Test Scenarios:(problems I am facing)
Place arrow very close to camera like on desk/laptop, it moves if we move camera
When we place arrow on surface and arm chair we can see the offset on position, example if we tap on table, we can see arrow is added however when we move towards it we can see offset in position of the arrow
can you please take a look at the behavour, and let me know your thoughts. Thanks!
I tested it on my VR headset and the anchors don’t drift at all, so the drifiting is most likely being caused by the phones themselves, especially since it’s still an experimental feature.