5G-MAG / rt-xr-unity-player

XR Unity Player
https://5g-mag.github.io/Getting-Started/pages/xr-media-integration-in-5g/
Other
4 stars 1 forks source link

Phone camera is not rendering as background when the glTF scene contains a camera #51

Open nlsdvl opened 1 month ago

nlsdvl commented 1 month ago

When loading the sofa scene, when the floor is detected, the scene is instantiated as expected.

However if the scene contains one or more camera, it gets instantiated and effectively breaks AR:

@Etiennefaivredarcier what is the expected behavior for such a case ? I assume the camera node in the gltf document in this context is not forbidden by the spec, and the behavior in the specification is undefined, so it can be ignored.

It seems this was addressed for plane tracking in TrackableGeometric.cs, but the floor tracking implementation doesn't handle this case.

The issue exists potentially on all trackable types used to anchor a scene containing a camera. This could also be extracted/refactored to avoid redundancy.