Pack the classes and functions in FaustSensors.ts into a single class with static fields for simplifying injecting them to AudioWorklet thread.
Note that the enums will be compiled to plain numbers by TypeScript.
Move deviceorientation and devicemotion listeners to listenMotion method at AudioNode level, they are not called by default and suppose to be called by the host.
Adding some special code for iOS13+ to request permissions.
Example hosts: adding node.listenMotion() after a user gesture for supporting iOS13+
FaustSensors.ts
into a single class with static fields for simplifying injecting them to AudioWorklet thread.deviceorientation
anddevicemotion
listeners tolistenMotion
method at AudioNode level, they are not called by default and suppose to be called by the host.node.listenMotion()
after a user gesture for supporting iOS13+