Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Lidar Device Issue #17

Closed
Reality-Dev opened this issue Feb 1, 2021 · 6 comments · Fixed by #18
Closed

Lidar Device Issue #17

Reality-Dev opened this issue Feb 1, 2021 · 6 comments · Fixed by #18
Assignees
Labels
bug Something isn't working

Comments

@Reality-Dev
Copy link
Collaborator

Have you tried running this same project on a Lidar-enabled device?

I tried it on my iPad Pro 2020 and it did not perform well with locating planes.
It would fail to change orientation to match the new surface.

I also tried it with a prior version of the project, commit 88112e6, and it has the same issues.

I think this could have something to do with the raycasting, but sceneUnderstanding.options does not include .collisions, so it should not be affecting raycast results.

I did also use

self.debugOptions.insert(.showAnchorGeometry)

To make sure that planes were being detected, and they were.

@maxxfrazer
Copy link
Owner

I believe someone mentioned this to me on twitter a while ago, but I didn't have a LiDAR device to test with at the time.
I'll use my 12 pro to see if I can replicate and hopefully debug tomorrow. (i usually test things like this on my ipad, which doesn't have LiDAR).

Thanks for raising this and already trying out an older version + debugOptions

@maxxfrazer maxxfrazer added the bug Something isn't working label Feb 2, 2021
@maxxfrazer
Copy link
Owner

Just to let you know - I tried this out and see the same bug, sometimes it works fine, but most of the time doesn't

@Reality-Dev
Copy link
Collaborator Author

Hey Max! I just tested pull request #18 out on both a lidar-enabled (iPad Pro 2020) and a non-lidar-enabled (iPhone XS) device. It worked beautifully on both of them. Changing the raycast query target to only .existingPlaneGeometry for lidar-enabled devices worked very well. The focus entity changes orientation to match the surfaces now. Great work! Thank you for fixing this. Lidar detects surfaces much more quickly and up to 5 meters away so this was a huge improvement.

@Reality-Dev
Copy link
Collaborator Author

One small issue I noticed is that when changing between two vertical planes which are perpendicular to one another, the orientation change is not smooth, since the code only smooths out changes between horizontal, vertical and none orientations.

@maxxfrazer
Copy link
Owner

It also rotates the wrong way when it goes on the ceiling for me! But I think fixing those couple of pieces won't take much further adjusting 👍

@Reality-Dev
Copy link
Collaborator Author

Interesting! Good catch. Yes it sounds not too bad.

@maxxfrazer maxxfrazer linked a pull request Feb 4, 2021 that will close this issue
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants