Currently experimenting with integrating FMOD into a WebXR experience, but I’m hitting a roadblock when trying to update the listener attributes. According to the documentation, all I should need to call this from JavaScript is the listener ID and then the attributes, which I am doing currently
function update(listenerAttributes) {
gSystem.setListenerAttributes(0, listenerAttributes);
CHECK_RESULT(gSystem.update());
}
But when I try to run this, I get an emscripten binding error saying that this function expects 3 arguments, not 2.
If I look into the Chrome debug tools I can see the types expected for each argument are (int, emscripten::val, emscripten::val). I also notice on the page for FMOD_3D_ATTRIBUTES there is a vague disclaimer for JavaScript that reads “Not all fields are currently supported or may not work as expected at this time.” I’m unsure if that’s related though (and it would help to know specifically what part of it is actually supported/not supported or doesn’t work as expected).
UPDATE: It seems if I just pass 0
as the third argument it begins working without any noticeable issue. Regardless, I’d still like to know exactly what it’s expecting there.