Can you get realistic meshing in XR Simulation - and if not more questions about the real meshing

Using the simulated environments in the editor for testing AR - the meshes “created” don’t really appear to simulate how the actual meshing works when on device -
A) is there a way to make is to that the simulated meshing simulates the real meshing? - i guess not
B) is there a description anywhere of what the real meshing will actually look like - is the mesh divided into chunks - if so what size are the chiunks - are they cubes etc?
Thanks!

In a broad sense, the Meshing subsystem works the same on both XR Simulation and devices: it generates a mesh based on the geometry that is provided by the platform.

I’m guessing the differences you’re observing are that our simulation environments are composed of very basic geometry (cubes, etc), whereas devices will be scanning real world geometry and will likely return much more complex meshes.

You can create your own simulation environments if you wish to test more complex geometry in XR Simulation: XR Simulation environments | AR Foundation | 6.1.0-pre.5

is there a description anywhere of what the real meshing will actually look like - is the mesh divided into chunks - if so what size are the chiunks - are they cubes etc?

AR Foundation does not implement AR functionality, so this can vary depending on what platform you’re developing for. However, for the most part, I would say that the platforms we support do not divide meshes into chunks. In terms of general 3D stuff, meshes are comprised of triangles, not cubes: Unity - Scripting API: Mesh

Hello,
is there any guide showing how to use “Meshing” in “XR Simulator” at all?
This feature is described as supported, but documentation is very short on that.

I tried to use “Factory” environment from “SimulationEnvironments”. I added few more planes and cubes and attached SimulatedMeshClassification component and set classification type.

The point is that when I try to call SetClassificationEnabled on XRMeshSubsystem then I’m getting: “EntryPointNotFoundException: UnityARKit_MeshProvider_SetClassificationEnabled” (in Unity Editor its not a surprise).

So general question: what does it mean that “Meshing” is supported in “XR Simulator”?
What should I expect to see when opening “Classification Meshes” scene from “AR Foundation Samples” project?


Thanks for any help

@mwalus You have the ClassificationMeshes scene open, which is only supported on ARKit. On XR Simulation, you can use the NormalMeshes scene and expect to see mesh faces highlighted in different colors depending on how the mesh face is oriented.

Each scene in the samples project is documented in our README: GitHub - Unity-Technologies/arfoundation-samples: Example content for Unity projects based on AR Foundation

1 Like

Thanks for info @jstan-unity .

1 Like