how to detect mic position on iPhone? - iphone

iPhone 4 has a mic on bottom-left, iPhone 3GS and earlier had a mic on bottom-right.
How can I detect where is the mic on iPhone? What function does that?

You will have to detect the specific model of device (e.g. "iPhone2,1", etc.) and do a table look-up from information you determine. And to future-proof the result, you may also have to have it look up the position of the mic from your web site, where you can keep a table updated with device types as Apple introduces new ones.

I would not use the method as said in the comment to your post. The minute the new iPad or iPod Touch is released with a front facing camera, your application is off.
Why not just use a method like in this post: Determine device (iPhone, iPod Touch) with iPhone SDK
The code (if you scroll a bit down) shows how to detect which version of iPod/iPhone/etc is running on.

Related

How to get touch point outside current app

I want to develop one iOS app. Is there any way to get the ui touch point when app in background. Like i want tap randomly in iOS device screen and my app will get correspond touch point accordingly.
Fortunately, this is not possible on iOS.

Is it possible to programmatically capture iPhone 5S slow motion video?

I couldn't find an answer to this question, and looking at Apples own apps like iMovie on iOS, the video picker does not offer a slow motion option on the iPhone 5S.
The image picker offers very little control over the video. If you are willing to dive deeper into the APIs you can use AVFoundation to capture your video and manipulate the camera properties as you see fit.
iOS 7 introduces a new AVCaptureDeviceFormat class that will give you the maximum and minimum supported frame-rates for the capture device, and you can use these to set a custom frame rate on the camera itself. I don't have an iPhone 5S to hand so I can't actually verify whether this API goes all the way down to 120FPS.

How can I determine programmatically that my app is running on an iPhone, iPad or iPhone 4?

I just finish my iPhone game using cocos2d. But before I put it on the AppStore, I'd like to make it work on iPad (which have a bigger screen) and iPhone 4 (which have a bigger resolution).
So, how can I determine programmatically that my app is running on an iPhone, iPad or iPhone 4, to be able to use the correct coordinates / images in my game?
Thanks for your help!
Between iPad and iPhone — Already answered many times.
Between iPhone and iPhone 4 — The size reported is still 320×480, so you don't need to change anything about the coordinates. Create an #2x alternative for the images if you need a high resolution UI image.

Movie, Image Editing, Mixing Audio in IPhone

I need to develop some sort of application featuring Editing Movie slices, Adding and editing images, Adding sound . recording movie, Adding effects, setting transitions between movie clips and images.
so is there any provision in SDK 3.0? I will use iPhone 3GS
Please Help Me.
Thanks
Unfortunately, there isn't a lot of support for a program like this on the iPhone yet. With the 3GS and OS 3.0, your program can let the user record a video and trim it, but everything after that is left to you to do from scratch. You get the filename of the recorded video, but there are no OS calls to even do something as simple as find out how many seconds of video there are.

iphone: Sending multitouch from the device to the simulator?

I need to record a video of a multitouch game I'm working on, and I'd like to record it from the simulator. My idea was to send touches from the device to the simulator (like this project does with the accelerometer). Just by googling I haven't found anything like that, but before I start implementing it I thought I'd ask here if anyone knows about an already existing solution.
Just to be clear, I do need full multitouch (up to 5 fingers). The pinch and drag that are available on the simulator are not enough.
Matt Gallagher has a writeup on synthesizing touch events, which might provide what you're looking for, although I've not tested it myself.
Check out iSimulate, it is an application/library pair that allows you to use to multi-touch (up to 5 fingers), the accelerometer, and the GPS in the iPhone Simulator. It takes only few minutes to integrate into your iPhone project.