Vibrate to Sound iphone - iphone

I am working on the video application. and My phone is on vibration or silent and I play the video then sound of video does not play. But I want to play sound even phone is on silent or vibration. So please let me know is it possible? If yes then How? please provide me sample source code.
Thanks

IOS doesnt give your app that kind of control.
When the user turned ios to silent all apps are silent.

Related

is it possible to play AppleMusics inside my app? If yes then how can i play this?

I'm beginner to iOS development. I want to play AppleMusic inside my app. please let me know is it possible or not?
If it is possible then please suggest me how can i play this.
I found this Link but i don't know wether it play music with iPhone default player or AVPlayer?
It is possible with music kit. Check out https://developer.apple.com/musickit/, but the users will need to have an apple music account.

how to play background music while recording voice?

friends
Now I'm developing iPhone Recorder App.
I can easily record my voice with sample code.
I want to record background music with my voice.
For example,When I click "Record" button,background music plays
Then I sing a song.
In this case,I should record background music with my voice.
But,If I did like that,I can't record anything.
What's wrong?
To do this,what should I do?
Please help me..
Thanks.
I'm not familiar with programming for the iPhone but I can imagine there would be a limitation to what you like to achieve IF you intend to make this work without using headphones/headset. It just might be that the OS wont let you play music and record at the same time because the recording would result in an echo because of the background music.
That said, I'm sure an experienced iPhone programmer is able to tell you exactly how this would work.
Good luck and I hope my suggestion helps you out.
friends
I solved this problem by using OpenAL.
Thanks for all your effet.

MPMoviePlayerController Streaming Video won't play Audio

I'm streaming video to my app with MPMoviePlayerController, works great in Simulator and my device, but one of my beta testers devices won't play the audio. Audio controls won't appear, and instead, show the following image:
Any idea what is going on? Thanks in advance!!
The beta testers phone was on vibrate... dummy.

How to allow ipod music to play while my app is running?

I'm using SimpleAudioEngine to play my sounds and I was wondering if there is anyway to check if iPod music is playing when the app is launched. If so, I want it to continue playing. I'm starting to think it may be called the simple engine for a reason as it doesn't allow features like this, where AVAudioEngine does...
Thanks :)
You should check out the official Audio Session Programming Guide and make sure that you are setting the correct session category. You will want to pick the category that allows your audio to mix with the iPod audio.

How can I lower the volume of iPod audio while my app plays a sound

I'm trying to reproduce the functionality of built-in Mail application when a new message arrives while you are listening to iPod music.
What happens with the Mail app is:
iPod's volume lowers a bit
Mail app plays a short sound and vibration
iPod's volume goes back to normal
I know how to play a sound and cause vibration, what I don't know is how to lower iPod's volume and restore it after my sound plays.
How can I reproduce this same functionality in my app with SDK 2.2? I know third party apps can't run in the background. My users will play the iPod then have my app in the foreground.
See my answer to that other question of yours ;)
[[MPMusicPlayerController iPodMusicPlayer] setVolume:x.y]
where you change x.y through a timer or as one-off. In OS3, of course.
Have you tried simply playing the sound? I suspect this is automatic functionality on the part of the SDK.
edit: according to this question, you can fade the ipod sound out but not back in.
(I'm surprised this functionality isn't automatic and default behaviour. But then I've always found the elegance of the apple APIs to be inversely proportional to the elegance of the interface :-)
This is not possible with iPhone SDK 2.2.1 or earlier. If you need this functionality please submit a bug to apple. I've submitted one but duplicates indicate interest so it might help promote this issue.
[[MPMusicPlayerController iPodMusicPlayer] setVolume:x.y] this will affect your ipod music player volume (allowed values are 0.0 to 1.0)
i hope vibration not allowed in ipod. if device have an option for vibration then we can do