Since you mention CanvasViewerOptions
, I assume your code is using the lower layers (not HTML3DElement
). If that is the case, and you are calling loadModel
yourself, then one option that works today is to pass in an option to disable the MSFT_audio_emitter
glTF extension:
viewer.loadModel(source, {
pluginOptions: {
gltf: {
extensionOptions: {
MSFT_audio_emitter: {
enabled: false,
},
},
},
},
});
This is very new and somewhat still in flux, but you can inherit from ViewerElement
and specify a different class that inherits from Viewer
if you want to subclass it as well. You can also override ViewerElement._createViewer
to customize the viewer creation process. From there, Viewer
and ViewerElement
both expose a number of protected properties and functions that let you heavily customize many aspects of the viewer. For example, there is a protected function to load a model, which allows you to load many models at the same time if this is what makes sense for your scenario. You also of course have full access to the scene and can directly manipulate it in whatever way makes sense (for example, adding primitive shapes like cubes or spheres, etc.). This part of the Viewer is a new, advanced use case, and is not fully fleshed out, so it’s not documented yet, but a lot is possible (and in fact others are already building on it in this way!).