model-viewer: Wall placement not working on Scene-Viewer mode

Description

Is enable_vertical_placement too much experimental? I’m currently using this with some objects on an intent without the need of model-viewer, but I realized the same problems occurs if I’m opening through the AR button on a model-viewer element. There’s an example on my glitch page, but basically the following does not work:

<model-viewer 
  src="https://cdn.glitch.com/36cb8393-65c6-408d-a538-055ada20431b/Astronaut.glb?1542147958948"
  ar
  ar-modes="scene-viewer"
  ar-placement="wall"
></model-viewer>

I know it’s not model-viewer related, but i feel like it’s the best place to ask for an issue about scene-viewer.

Live Demo

https://thirsty-befitting-trollius.glitch.me https://glitch.com/edit/#!/thirsty-befitting-trollius

Version

  • model-viewer: v1.6.0

Browser Affected

  • Chrome, version: 90.0.4430.66
  • Edge
  • Firefox
  • IE
  • Safari

OS

  • Android
  • iOS
  • Linux
  • MacOS
  • Windows

AR

  • WebXR
  • SceneViewer
  • QuickLook

About this issue

  • Original URL
  • State: closed
  • Created 3 years ago
  • Reactions: 1
  • Comments: 17 (8 by maintainers)

Most upvoted comments

Retesting with Google app v 12.19.11.29.arm64 Vertical placement looks fixed! ✅

I can now go into SceneViewer from ar_only , ar_preferred , or 3d_preferred (and then open in AR). No crashes. The model loads and can be placed in the scene.

It looks like, for vertical placement, SceneViewer is now only using the floor-placement with t-bar controls (not sure what else to call them)? The t-bar controls are super helpful for instances where walls have no detail to track to. But on detailed walls, it looks like it’s not attempting to place on the vertical plane. I thought it used to, and only fall back to t-bar mode if it couldn’t find enough detail in the vertical plane?

That said, once placed on a detailed wall, I can move right into it, without keeping the floor in view, and it keeps tracking to the detailed vertical plane. So that’s cool.

Thanks for the fix @timmmeh !

Ok I have another patch going in for this, as I said it looked like couple of different issues here, wasn’t sure which one was the most egregious so I focused on the vertical-placement first, but it turns out both issues would cause the same error but for different reasons.

Added a fix for issue with Vertical Placement in Scene Viewer which should be out in the next release. However, found a couple issue that might produce similar behavior not specifically vertical-placement issues though.

Public Service Announcement: It looks like yet another bug is currently rolling out in Scene Viewer that is causing wall-placement sessions to crash at 100%. It’s already been fixed, but that’ll take time to roll out as well, so there’s probably 1-2 weeks of broken wall placement. I’m as frustrated as you are! Again, I’d highly encourage switching to WebXR mode to avoid this and future issues.

There’s definitely an issue particular to Vertical placement in SceneViewer.

These tickets all appear to be related:

#2154 , #2255 , #2264

@AdrianAtGoogle confirms there will be a fix in ‘the next release’ of Google App (where SceneViewer resides, I think): https://github.com/google/model-viewer/issues/2264#issuecomment-830242892

Not knowing when or which the next release is, I can confirm that as of May 3, I’m still seeing issues with vertical placement in SceneViewer.

The below glitch demos switching the same model from ‘floor’ to ‘wall’: https://modelviewer-sceneviewer-arplacement.glitch.me/

Floor placement in SceneViewer, for me, is working fine 100% of the time.

Switching to Wall placement introduces a range of different results. Sometimes it works fine, as intended, and the object is placed on the wall. Sometimes SceneViewer starts and immediately crashes out. Sometimes SceneViewer hangs on the animated hand icon and Google App is non responsive. Sometimes SceneViewer throws an error and says ‘Object could not be loaded’. All these outcomes happen when viewing the exact same model in the exact same space.

I’m seeing this with:

  • Chrome: 90.0.4430.91
  • Google App: 12.15.9.29.arm64
  • Android: 11
  • On May 3

Thanks for the additional repro, I’ve been seeing this too and can repro it pretty consistently, I’m currently focused on tracking it down.

On Mon, May 10, 2021 at 3:32 AM Miles Green @.***> wrote:

@AdrianAtGoogle https://github.com/AdrianAtGoogle

I imagine you have this all well in hand, but thought I’d provide a small update in case it helps build a picture:

I’m now running Google App v 12.16.13.29.arm64

I’m still seeing issues with SceneViewer vertical placement.

I updated this demo: https://modelviewer-sceneviewer-arplacement.glitch.me/

To test opening Scene Viewer with direct intent links, rather than via ModelViewer. I also tried opening those intents initially to Scene Viewer’s 3D mode, rather than straight to AR, to see if that might help.

When opening the intent directly to SceneViewer AR mode, it crashes most of the time. This is either in the form of an immediate crash and quit back to the web page before model is even seen in AR, or sometimes, still during the scanning phase, before seeing model, it’ll hang and Google App becomes unresponsive.

When going to 3D mode first, the model loads fine. Then selecting ‘View in your space’ and entering AR mode, it still crashes. Maybe slightly less than going straight to AR. Crashes are similar to above - either immediately as AR mode stars, or hangs during scanning process.

On the occasions it does work, it works well. The model placement and controls are all working great.

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://github.com/google/model-viewer/issues/2303#issuecomment-836529696, or unsubscribe https://github.com/notifications/unsubscribe-auth/ABZY3MRMCUPZDAD2EZPHXSLTM6Y5TANCNFSM43IAK3CA .

It seems there are a few failures mentioned across those tickets; as I understand it they are (at least):

  1. vertical placement issue, cause unknown
  2. early placement -> no model
  3. early placement -> crash

Where “early placement” means getting an AR anchor before the model is loaded (i.e. the waving hand disappears before the spinner does) - issues 2 and 3 generally only happen when sceneviewer is launched directly into AR with mode=ar_preferred or ar_only.

Issue 2 was the one that I posted about last week. A NaN was sneaking through, causing the model to get placed with an invalid transform. This week’s release of the Google app for android should have the fix.

Issue 3 seems to only happen on certain devices, and only on android 11. It is a crash in ARCore that has been fixed at tip and will be in the next ARCore release (which is in progress, TBD unknown).

Issue 1 I know nothing about yet, except that it isn’t directly related to 2 or 3.