0

My application looks like this: An iOS tone generator (an introduction to AudioUnits) also generates some signal. I want to set the max volume when app has been started. How to do it? thx

phnmnn
  • 12,813
  • 11
  • 47
  • 64

2 Answers2

1

This should work:

float volume = 1.0f;
[[MPMusicPlayerController applicationMusicPlayer] setVolume:volume];
Vojtech Vrbka
  • 5,342
  • 6
  • 44
  • 63
0

You can do something like this:

[Music setVolume:0.3];
[Music play];

0.0 meaning volume off and 1.0 meaning max volume

iDev
  • 478
  • 1
  • 3
  • 24