Origin Anchor for Private Test Meshes

Origin anchors are now provided for private meshes. Use origin anchors to place private meshes in your Unity scene and align your virtual content with your private scans.

The workflow for generating and using origin anchors is as follows:

  1. Niantic Wayfarer

    a. Make a Private Scan and upload to the Lightship developer portal. For more details see Creating Private VPS Locations.

    b. Niantic processes the scan and makes a mesh download available on the portal in a couple hours.

  2. Lightship Portal

    a. Download your Private Mesh from the Lightship Portal. The download now includes an Origin Anchor for the mesh (a base64 string) contained in a separate .b64 file in the mesh zipfile. Open the .b64 file in a text editor to access the anchor string. Note that the anchor string is generated each time you download, however previously downloaded anchor strings for the same mesh are still valid and can still be used as long as the private scan is still valid.

  3. Unity Editor

    a. Deserialize the anchor string into a Wayspot Anchor payload:

     `payload = WayspotAnchorPayload.Deserialize(origin_anchor_b64String)`

    b. Treat the deserialized payload as an existing WayspotAnchorPayload. See the documentation, instructions, and example (WayspotAnchors example scene in ARDK-Examples) for more details.

    c. Once restored, the origin anchor aligns the mesh origin to the world, so the mesh can be placed on top of the anchor.

  4. On Device

    a. In your application provide the Origin Anchor to Wayspot Anchor APIs.

    b. The Origin Anchor is resolved on device, aligning the mesh in AR.


See also MattMurton’s plugin for easier importing of Draco meshes into Unity: VPS private mesh (Draco) importer

Special thanks to Kyle McCandless for working on this!


Thanks for posting this, it’s exactly the type of documentation i needed to get my project to work :ok_hand:

1 Like

I was able to successfully use the b64 string to localize the origin anchor on a private VPS. However, the position that I’m getting from the anchor is 0,0,0 and it doesn’t seem to line up with where it is supposed to be . Is there an example to localize the origin and attach a mesh to it ?

Hi Eyal_Erez,

I asked some folks here at Niantic, and one possibility might be that the anchor is starting at 0,0,0 but then getting a position update after the anchor gets resolved. To check for a position update, you should subscribe to both the anchor’s StatusCodeUpdated and TransformUpdated events, and look for TransformUpdated event(s) after the anchor status becomes Success. See more details on this here: Using WayspotAnchorService — Niantic Lightship Augmented Reality Developer Kit release-2.3 documentation

Note that there’s also a TrackingStateUpdated event on an anchor, but if you’re using ARDK 2.2 or 2.3, there’s an issue where that event doesn’t trigger, so you can’t use that to get anchor position updates.

Hi to all!
I have a problem with the downloaded .zip
I can find the .b64 file
In zip I have:
I have .FBX model , .JPEG texture and Json with the following content:(for example)


How I can restore the origin anchor when running on the device?