Skip to content

Dynamically set elevation when hiding/showing meshes? #5045

@jmbattle0

Description

@jmbattle0

Hello again,

I am working on a digital piano model viewer tool for my company's website.

One of the instruments is sold as a "slab type" digital piano, consisting of just the main keyboard unit. However, separate stand and pedal accessories can also be purchased

I have prepared the .glb file such that the main mesh is the upper part of the digital piano itself. There are also meshes for the stand accessory and pedal accessory, which can be purchased separately. My goal is to model the slab digital piano, stand, and pedals all together, in the same .glb file. Then by default, show just the main mesh, but add checkboxes to show/hide the music rest, stand, and pedal meshes.

Here is an example:
https://www.kawai-global.com/3dtest/?model=ES60&finish=B

The problem I encounter is that, when the stand and pedals are hidden using the onscreen UI, the elevation of the main slab part is not updated, so it remains floating in mid-air (and does not cast a shadow). Moreover, when entering AR mode, the main slab part is again floating in mid-air, and not grounded to the floor. This AR issue only occurs on my Android phone, there is no problems with displaying the model in AR on my iPhone/iPad.

How can I force modelviewer to set the elevation of the main unit mesh accordingly when the stand/pedal meshes are hidden?

Many thanks!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions