2

I have been using Model Viewer to add WebAR onto my website, On Android the models looks good and functions properly using ARCore, but on iOS, when using ARKit, the model is blending into atmosphere which is not what I need,

How can I disable it using Model Viewer api? I couldn't find any references, apar from this one github issue, but when I use it, I get an error saying "Object requires newer version of iOS".

Image of Issue/Blending:

enter image description here

Andy Fedoroff
  • 26,838
  • 8
  • 85
  • 144

1 Answers1

1

You're seemingly talking about People Occlusion feature, not blending. Natively, when you're coding in Xcode, you are able to disable this feature using single line solution:

arView.renderOptions = [.disablePersonOcclusion]

In ARKit there's a type property called .personSegmentationWithDepth. This frame semantic specifies that any person ARKit detects in the camera feed should occlude virtual content, depending on the person's depth in the scene. Segmentation is a process of extracting Alpha channel. Segmentation with Depth gives you 2 extra channels to RGB palette – Alpha and ZDepth.

Both iOS an Android have new Depth API that can help you implementing occlusion. But for that you need to run definite iOS version (or Android version) on officially supported device.

In Android Studio, Unity or Vuforia there are different ways for turning occlusion off. Look, for example, at these drop-down options:

enter image description here

Andy Fedoroff
  • 26,838
  • 8
  • 85
  • 144