Lofelt / NiceVibrations

🎮 🚀 Nice Vibrations and Lofelt Studio SDK source code repository
MIT License
131 stars 17 forks source link

Audio&Haptic synchronicity managment #26

Open butterl opened 1 year ago

butterl commented 1 year ago

From the project you share, seems only here talking about the rule of syncing in Audio & haptic, or I missed something? https://github.com/Lofelt/NiceVibrations/blob/main/clip-players/src/lib.rs#L25

In Android, Audio service and vibration service not running in same context, that means :

  1. play a short feedback like ui button, the sound&haptic is not easy to find the time gap
  2. in inputmethod scenario,the user input triggerd sound&haptic is easily to feel the gap
  3. play a long song/streaming & haptic , without realtime sync like video&audio, the time gap may easily to feel

From the IOS example,seems you are useing a standard audio API and not using any synchronicity between audio and haptic in SDK ?