Sound not working on cocos2D JS v.3 + IntelXDK + Cordova

293 views Asked by At

I have a problem with the audio that is not working on Android or an emulator. But it is working on web apps. I have searched in Google but i can't find the solution.

Why does cc.audioEngine is not working while using Intel XDK ?

2

There are 2 answers

2
Randyka Yudhistira On BEST ANSWER

Instead using library of JS, you can build your own plugin of cordova to record / play audio on your android. Or search existing cordova plugin on github.

1
xmnboy On

It's not that the XDK is "not working" it's that the webview and/or webview requirements don't meet the requirements of your cc.audioEngine library. I'm no expert on cc.audioEngine, but it appears to require Web Audio. That is not supported in the standard webview that you find in the typical Android device. This is why we provide the Crosswalk for Android build option. It includes the modern HTML5 features and APIs you take for granted in your desktop browser.

Try building with Crosswalk and debugging with the Debug tab. Both of those use the Crosswalk webview.