- Joined
- Mar 16, 2016
- Messages
- 41
- Reaction score
- 15
- First Language
- Hebrew
- Primarily Uses
Hey guys, I want to get the duration (play length) of a sound effect which is being played.
I've looked into:
I tried printing to console fields from WebAudio class, like totalTime, loopLength etc, but it seems like the WebAudio is still not fully populated in these functions, and all I get is null or undefined values (however, printing the buffer to console I can see the values populated, I guess this happens later).
I've been banging my head for a while now! How can I access the actual Web Audio data?
I've looked into:
JavaScript:
AudioManager.playSe
AudioManager.createBuffer
AudioManager.updateBufferParameters
I tried printing to console fields from WebAudio class, like totalTime, loopLength etc, but it seems like the WebAudio is still not fully populated in these functions, and all I get is null or undefined values (however, printing the buffer to console I can see the values populated, I guess this happens later).
I've been banging my head for a while now! How can I access the actual Web Audio data?