viromedia / virocore

ViroCore cross-platform AR/VR renderer
MIT License
364 stars 108 forks source link

PBR not working with .glb models #294

Open ryancrunchi opened 5 years ago

ryancrunchi commented 5 years ago

Environment

Please provide the following information about your environment:

  1. OS: MacOS 10.14.5
  2. Version: ViroCore 1.14
  3. Device(s): Samsung Galaxy S9 Android 8.0.0, One+ 6 Android 9.0.0

Description

We are using glb models in our app and we can't manage to enable PBR on these models. We are working with our own models as well as samples from here : https://github.com/KhronosGroup/glTF-Sample-Models/tree/master/2.0 like Boom Box and Flight Helmet.

We have an iOS version, using a 3rd party lib to load glb models, where everything is working fine. On Android, the reflections on 3D objets are not visible. For example : iOS iOS

Android Android

The same goes for Flight Helmet and our own models. When logging the object's nodes hierarchy, the materials are indeed using PHYSICALLY_BASED lighting model, but the appearance is obviously not PBR.

node [name] chrome (55)
    - [geometry] com.viro.core.Geometry@a4d7e92
        - [material] PHYSICALLY_BASED

We have also tested with AmbientLight as well as OmniLight added to the scene, but nothing has changed.

The issue may be related to https://github.com/viromedia/virocore/issues/288.

radvani commented 5 years ago

Hi @ryancrunchi, we believe we've fixed this problem, but we haven't yet released the patch. I'll test today with your boom box model to see if our fix works. We'll also update you shortly on the release date.

radvani commented 5 years ago

Hi @ryancrunchi, I've confirmed we've fixed the issue (see image below). I will get back to you on a release date later today. If this is urgent and you need a hot-fix, send us an email at support@viromedia.com and I'll get that to you.

IMG_4957