03-31-2011 06:06 AM
My app plays sounds when a user presses a button, it has a settings screen so a user can change the volume of a sound using:
sTransform.volume = volume;
My question is, when the user changes the var 'volume' do I need to change anything in the tablet API to increase volume? O r will changing it using sound transform work just fine? And do I need to allow 'play_audio' in the xml permissions?
03-31-2011 06:20 AM
I believe you need to add permissions for play_audio. This page also suggests that to change volume you need permissions for that too, and should be using qnx.media.MediaControl.
I've done playing audio though, but not changing volumes.
03-31-2011 06:26 AM
04-01-2011 09:20 AM
Changing the soundTransform will work fine, and you don't need any special permission to do so.
You should include play_audio, however, if you're playing sound.
There are two ways to control volume... the system setting (which you can affect with the physical up/down volume buttons) and the transform in Flash. The system setting requires the special permission, but the transform does not. Obviously if the user has set the system volume to the minimum, you won't hear your sound even if the transform volume is at max. (And that's probably just what the user wants.)