02-29-2012 09:53 PM
Can you play audio clips in your WebWorks app on a Playbook? I've tried the standard HTML5 audio player, and it does not work well. Let me point you to some public code to demonstrate. Try opening this in your Playbook browser:
On normal browsers, this works fine. You click some links to get a "click" sound. But on the Playbook 2.0 browser, I see the following misbehavior:
Anyone know of a workaround for this audio behavior?
I've opened a case in RIM's JIRA (TABLET-501) but it's probably not visible to the public.
03-05-2012 10:36 AM
Yes, HTML5 audio does work in a WebWorks app on PlayBook.
Note: the sample you provided make use of "mouseover" events, which may not behave as expected on touch-screen devices like the PlayBook (where there is no 'over' events). The "whoosh" sound effect appears to be tied to the mouseover event.
Try this test page?
Note: not all audio codecs are supported by the Tablet OS web engine (e.g. OGG format is currently not available but is on the roadmap).
03-05-2012 11:20 PM
I've noticed this is a problem too.
I'm not sure what the audio type is, but videos on Comedy Central will play audio fine in the browser, but will NOT play audio if you visit the page within a webworks apps.
If you want to try it for yourself, sideload the app at http://opensourcebb.com/2012/03/tablet-tv-playbook
03-06-2012 08:48 AM
WebWorks apps need to white list any external domains used to access remote content. if the audio files exist on a different domain than that of the paget they are being played from, they will not play from within a WebWorks app unless you have both domains whitelisted in the config.xml file.
03-06-2012 10:45 PM
Thanks for responding. I think you misunderstood the problem I am experiencing in the original link. The audio demo does indeed have a mouseover demo, but it also has "click" demos (tap on the "click" links). Please try the click demos with your Playbook. You will find that even with the "click" sounds, the Playbook plays the audio incorrectly.
I tried the test page you provided. The difference with that test page is that it only has longer audio samples. The problem I am describing has to do with short sound clips, such as those for sound effects. I tried the exact same <audio> tags as in that page, and saw the same problems if I used shorter audio files.
The Playbook can handle HTML5 audio in static media demos. But it cannot correctly handle short audio clips. Its inability to correctly play sound effects -- such as those used for games -- severely cripple the Playbook as a Webworks platform.
06-10-2012 10:29 PM
@cwong15 Did you ever get anywhere with this? I have created a new thread here with my findings and what I've tried to do to get around this.
Basically I have found that you can a) reload the sound after it has been played the first time, b)create a new instance of the sound every time.
Neither of theses are ideal. Solution a) causes a lag while the sound is loaded and solution b) causes a new instance of the sound taking up more memory each time.
This seems to be an issue with the playbook. I've seen this behavior in the browser as well as webworks. I'm surprised to find little information on this problem.
06-20-2012 10:37 PM
Nope, I had no luck finding any workaround. I ended up abandoning my project.
The JIRA issue I filed on this in February is still in "triage" status, so I guess nothing is happening any time soon. In case you're interested, the issue is: TABLET-501