Closed Reda-S closed 6 years ago
I've started an implementation for this.
Hopefully it will not take long; there is a C++ implementation for WebAudio (https://github.com/LabSound/LabSound). It has to be adapted to work in an APPX container (hopefully already done at the fork I made in https://github.com/Almost-Done/LabSound) and JavaScript projections must be written for the WebAudio APIs to hook them to the C++ implementation.
Thanks Cristi
Hello Cristi,
I am still interested in the spatial sound feature, will you have a chance to check it out again?
Regards, Reda
The implementation in develop/audio does not work on the OS version currently running on the HoloLens (RS1). It runs just fine on the latest version of windows (RS3). On RS1 it throws and "illegal instruction exception" which I have to investigate (most probably a CRT incompatibility).
Hi Cristi,
Will your audio solution, as is, work on the recent HoloLens RS4 update preview?
Thanks, Reda
It should. I haven't tried RS4 yet, but it works on RS3. Try the audio sample from the audio branch. I've given up development for RS1 and I've been waiting for RS4 to make progress on features that have split over time (audio, WebVR, MRC headset support)
I wasn't able to make the audio sample run on RS4, it is always giving an "illegal instruction" exception on the following line (19): AudioContext::AudioContext() { m_context = lab::MakeAudioContext(); }
Very frustrating since I can't repro it. I did get "illegal instruction" when running RS1, but not anymore with RS4.
I dropped RS1 as target version for the projects, merged with master and pushed the changes out to develop/audio. Do you mind trying one more time and if you still get the crash I'll wrap the audio engine in a WinRT component instead of the current static library. I guess there's a STL incompatibility somewhere between HoloJsHost and the audio library.
It turns out the sound library was compiling with the AVX switch which the Intel CPU in the HoloLens does not support. I removed the AVX switch and pushed a fix. I believe it should work now.
I am still getting the same "illegal instruction" error with latest develop/audio update.
Did you clean the solution and rebuild? The last change I pushed was just a static library change (no code changes) and VS might not have rebuilt the project. Also please try both the Release and Debug versions.
@Almost-Done I have tried cleaning the solution and rebuilding it, downloading the GitHub audio branch from scratch, I have even installed VS on a different PC maybe something is cached somewhere since it is working for you, and I have tried to run it on a different HoloLens. But the Debug version is still giving the illegal instruction error.
Just before giving up, I tried the Release version and it is working! 👍 👍 👍
I'm so sorry for the trouble. It was my mistake as I forgot to take out the AVX flag from the Debug configuration. Thank you for your persistence!
Now that you got it to at least run, you will most probably encounter other issues. Please submit any issues you find along the way. The WebAudio implementation is not complete on the script side; however it is complete on the C++ side so it's just a matter of creating projections.
Thanks a lot Cristi, I am just happy that it's working. I will submit any issues that may arise. Thank you again for all your support.
Hi Cristi,
Since the RS4 update has been released for everyone, can we merge the develop/audio branch to master and maybe we can finally close this issue too?
Thanks
Thank you for reminding me. It is now merged.
We have been working on a solution that needs placing sounds in 3 dimensional space, it would be great to have spatial sound directly from HoloJS.